wages/backend/src
jtricerolph e447d48e37 Make the AI insight's prompt instructions editable via Settings
Split the system prompt into an editable part (persona/focus/tone/
format — what the briefing prioritises and how strict its length is)
and a fixed structural appendix (how the Manual Context and Recent
Previous Insights sections get interpreted, which map directly to
conditional data the code assembles, not just prose — kept safe from
being accidentally edited away).

New ai_insights_prompt_instructions config key, a
GET /api/ai-insights/default-prompt endpoint so the Settings UI can
pre-fill/reset to the built-in default, and a textarea in the AI
Insights settings card.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-25 11:09:44 +00:00
..
jobs Make the AI insight's prompt instructions editable via Settings 2026-07-25 11:09:44 +00:00
lib Migrate rota sync from /api/v2/schedules to /api/v2/rosters/on/{date} 2026-07-25 10:01:35 +00:00
routes Make the AI insight's prompt instructions editable via Settings 2026-07-25 11:09:44 +00:00
auth.js Initial scaffold: wages app 2026-07-23 09:03:52 +00:00
db.js Make the AI insight's prompt instructions editable via Settings 2026-07-25 11:09:44 +00:00
index.js Add AI cost insights dashboard; rota-informed forecast method 2026-07-24 20:43:18 +00:00
ip-check.js Initial scaffold: wages app 2026-07-23 09:03:52 +00:00