Agents: per-agent prompt appendix concatenated to skill at dispatch #51
Labels
No labels
area:agents
area:dashboard
area:database
area:design
area:design-review
area:flows
area:infra
area:meta
area:security
area:sessions
area:webhook
area:workdir
security
type:bug
type:chore
type:meta
type:user-story
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
charles/claude-hooks#51
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
User story
As a maintainer, I want each agent instance to optionally carry a
prompt_appendix(stored in SQLite, editable later via the dashboard) that's concatenated to the base skill template at dispatch time, so that I can specialisedev-frontendwith "focus on Svelte / TypeScript patterns" orreviewer-securitywith "weight auth / crypto / secrets regressions heavily" without editingskills/*.mdand breaking every other instance of the same type.Context
Skills in
skills/*.mdare the contract — reviewable, git-versioned, shared across all instances of a type. Per-instance tuning is a separate concern and should not pollute the shared skill files.Acceptance criteria
Dispatch-time concatenation
loadSkill(<name>)returns the base template, append the instance'sprompt_appendixif non-empty, separated by a clear heading:system_promptstays as today (type-level fromagents.json). Only the per-task skill gets the appendix.Cache semantics
skillCacheinsrc/webhook-handlers.tsor whereverloadSkilllives) keys on skill name only. The appendix is applied after cache lookup, per dispatch. No cache invalidation needed when editing an appendix through the dashboard.Tests
buildPromptForDispatch(instance, skillName, vars)— base-only when appendix is empty; concat'd output when appendix set; appendix goes after the base body with the heading separator.review) also receive the appendix.Dashboard integration point
Out of scope
{{pr_number}}) — appendix is plain text; if we need templating later, add it behind an opt-in flag.References
skills/*.md.Dependencies
main(after A1 lands).