@event4u/agent-config 5.4.1 → 5.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (92) hide show
  1. package/.agent-src/commands/image/analyse.md +51 -0
  2. package/.agent-src/commands/image/create.md +53 -0
  3. package/.agent-src/commands/image/verify.md +48 -0
  4. package/.agent-src/commands/image.md +69 -0
  5. package/.agent-src/commands/knowledge/cross-repo.md +71 -0
  6. package/.agent-src/commands/knowledge.md +2 -0
  7. package/.agent-src/commands/skill/preview.md +67 -0
  8. package/.agent-src/commands/skill.md +48 -0
  9. package/.agent-src/commands/skills/discover.md +76 -0
  10. package/.agent-src/commands/skills.md +56 -0
  11. package/.agent-src/commands/video/from-song.md +351 -0
  12. package/.agent-src/commands/video.md +19 -9
  13. package/.agent-src/contexts/authority/commit-mechanics.md +8 -0
  14. package/.agent-src/rules/commit-policy.md +3 -8
  15. package/.agent-src/rules/linked-projects-onboarding-gate.md +1 -1
  16. package/.agent-src/rules/media-sync-ground-truth.md +58 -0
  17. package/.agent-src/skills/image-analyser/SKILL.md +121 -0
  18. package/.agent-src/skills/image-analyser/canon-spec.md +109 -0
  19. package/.agent-src/skills/image-analyser/evals/triggers.json +16 -0
  20. package/.agent-src/skills/image-creator/SKILL.md +117 -0
  21. package/.agent-src/skills/image-creator/evals/triggers.json +16 -0
  22. package/.agent-src/skills/song-to-script/SKILL.md +216 -0
  23. package/.claude-plugin/marketplace.json +15 -2
  24. package/CHANGELOG.md +84 -0
  25. package/CONTRIBUTING.md +6 -0
  26. package/README.md +3 -3
  27. package/config/agent-settings.template.yml +18 -0
  28. package/dist/cli/registry.js +1 -0
  29. package/dist/cli/registry.js.map +1 -1
  30. package/dist/discovery/deprecation-report.md +1 -1
  31. package/dist/discovery/discovery-manifest.json +327 -20
  32. package/dist/discovery/discovery-manifest.json.sha256 +1 -1
  33. package/dist/discovery/discovery-manifest.summary.md +4 -4
  34. package/dist/discovery/orphan-report.md +1 -1
  35. package/dist/discovery/packs.json +24 -10
  36. package/dist/discovery/trust-report.md +3 -3
  37. package/dist/discovery/workspaces.json +20 -6
  38. package/dist/mcp/registry-manifest.json +3 -3
  39. package/dist/router.json +1 -1
  40. package/dist/server/schemas/settings.js +4 -0
  41. package/dist/server/schemas/settings.js.map +1 -1
  42. package/docs/architecture.md +3 -3
  43. package/docs/catalog.md +20 -6
  44. package/docs/contracts/benchmark-report-schema.md +12 -10
  45. package/docs/contracts/command-clusters.md +5 -1
  46. package/docs/contracts/cross-repo-retrieval.md +64 -0
  47. package/docs/contracts/rule-router.md +39 -0
  48. package/docs/contracts/skill-discovery.md +80 -0
  49. package/docs/contracts/skill-dry-run.md +47 -0
  50. package/docs/contracts/value-dashboard-spec.md +7 -3
  51. package/docs/contracts/value-report-schema.md +6 -1
  52. package/docs/decisions/ADR-032-linked-projects-scope.md +7 -3
  53. package/docs/getting-started.md +2 -2
  54. package/docs/guides/cross-repo-linked-projects.md +7 -0
  55. package/docs/guides/cross-repo-retrieval.md +61 -0
  56. package/docs/guides/skill-discovery.md +71 -0
  57. package/docs/guides/skill-preview.md +71 -0
  58. package/docs/value.md +17 -17
  59. package/package.json +1 -1
  60. package/scripts/__pycache__/validate_frontmatter.cpython-312.pyc +0 -0
  61. package/scripts/_dispatch.bash +10 -0
  62. package/scripts/_lib/__pycache__/__init__.cpython-312.pyc +0 -0
  63. package/scripts/_lib/__pycache__/agent_src.cpython-312.pyc +0 -0
  64. package/scripts/_lib/bench_report.py +13 -14
  65. package/scripts/_lib/bench_telegraph_report.py +1 -2
  66. package/scripts/_lib/token_count.py +95 -0
  67. package/scripts/_lib/value_report.py +3 -3
  68. package/scripts/ai-video/adapters/higgsfield.sh +163 -6
  69. package/scripts/ai-video/adapters/openai-images.sh +92 -6
  70. package/scripts/ai-video/lib/probe-audio.sh +181 -0
  71. package/scripts/audit_auto_rules.py +22 -6
  72. package/scripts/audit_command_surface.py +6 -1
  73. package/scripts/audit_initial_context.py +210 -0
  74. package/scripts/bench_ab_diff.py +4 -11
  75. package/scripts/bench_run.py +2 -3
  76. package/scripts/bench_runner.py +2 -2
  77. package/scripts/condense.py +44 -3
  78. package/scripts/cross_repo_retrieve.py +172 -0
  79. package/scripts/inventory_meta_layers.py +288 -0
  80. package/scripts/iron_law_sha.py +14 -5
  81. package/scripts/linked_projects_list.py +91 -0
  82. package/scripts/measure_rule_budget.py +15 -0
  83. package/scripts/memory_lookup.py +53 -2
  84. package/scripts/project_thin_rules.py +168 -0
  85. package/scripts/render_value_md.py +14 -23
  86. package/scripts/schemas/command.schema.json +1 -1
  87. package/scripts/schemas/rule.schema.json +1 -1
  88. package/scripts/schemas/skill.schema.json +2 -2
  89. package/scripts/skill_discovery.py +254 -0
  90. package/scripts/skill_linter.py +8 -4
  91. package/scripts/skill_preview.py +179 -0
  92. package/scripts/trigger_coverage.py +129 -0
@@ -0,0 +1,109 @@
1
+ # Character Canon Spec — schema, fidelity rubric, fidelity loop
2
+
3
+ Shared contract consumed by [`image-analyser`](SKILL.md) and
4
+ [`image-creator`](../image-creator/SKILL.md). Defines the structured truth a
5
+ character image is reconciled against, how a candidate is scored, and how the
6
+ create→analyse→regenerate loop converges.
7
+
8
+ > **Design lock (AI-council, anthropic/claude-sonnet-4-5 + openai/gpt-4o, 2-round
9
+ > debate, user-invoked):** keep **ontology and epistemology separate**.
10
+ > `confidence` is a property of a *verification attempt*, **not** of the
11
+ > character — so it never lives on a canon leaf. Three layers below. The rubric
12
+ > is a **vector + hard gate**, never one scalar. The loop uses **plateau +
13
+ > oscillation detection**, not a bare iteration count.
14
+
15
+ ## The three layers
16
+
17
+ A character record is split so each layer changes for a different reason:
18
+
19
+ ### Layer 1 — `identity` (immutable canon · the character truth)
20
+
21
+ What the character *is*. Per-leaf `severity` only — **no confidence**, no
22
+ verification state. Source of truth = the canon (the book + its authoritative
23
+ portraits; *the image wins over the text*).
24
+
25
+ ```jsonc
26
+ {
27
+ "id": "veikko",
28
+ "identity": {
29
+ "physique": { "value": "lean wiry athletic, 1.82m, broad shoulders narrow hips", "severity": "major" },
30
+ "face": { "value": "...", "marks": [ { "value": "tiny scar above right mouth corner", "severity": "minor" } ] },
31
+ "hair": { "value": "vertical split: LEFT pitch-black / RIGHT platinum-blond, long open to chest, no shaved sides", "severity": "canon-breaking" },
32
+ "eyes": { "left": "ice-blue", "right": "forest-green", "heterochromia": true, "severity": "canon-breaking" },
33
+ "tattoos": [ { "location": "central chest", "motif": "Vegvisir compass", "style": "blackwork", "severity": "canon-breaking" },
34
+ { "location": "left chest", "motif": "Loki serpent biting tail", "severity": "canon-breaking" },
35
+ { "location": "knuckles", "motif": "block letters", "text": "S-U-S-I", "severity": "major" } ],
36
+ "jewelry": [ { "value": "massive round silver watch, RIGHT wrist", "severity": "major" } ],
37
+ "outfit_variants": [ { "name": "studio-casual", "value": "black sleeveless tank under open leather vest" } ]
38
+ },
39
+ "identity_anchors": ["hair", "eyes", "tattoos[central chest]", "tattoos[left chest]", "jewelry[watch]"],
40
+ "notes": "Loki = asymmetry everywhere (hair, eyes, tattoos)."
41
+ }
42
+ ```
43
+
44
+ - **`severity`** ∈ `canon-breaking | major | minor` — how much a miss matters.
45
+ - **`identity_anchors`** — the must-never-drift list. **Derived rule:** every
46
+ `severity: canon-breaking` leaf MUST be an anchor; anchors MAY also name
47
+ cross-feature invariants (e.g. "asymmetry") that no single leaf captures.
48
+ - Relationship to [`character-consistency`](../character-consistency/SKILL.md):
49
+ its existing token JSON (`agents/reference/ai-video/<project>/characters/<id>.json`)
50
+ is the **load-bearing subset** of this `identity` layer. The Canon Spec is the
51
+ richer superset; `image-analyser` emits the token subset into that exact file
52
+ so there is **one** character record, not two.
53
+
54
+ ### Layer 2 — `observation` (verification state · the analyser's output)
55
+
56
+ What a *specific image* shows, per attempt. **This** is where `confidence`
57
+ lives (`high | medium | low`, the `image-ocr` pattern) plus `unverifiable[]`
58
+ for features the image cannot resolve (occluded / low-res). Never written back
59
+ onto Layer 1.
60
+
61
+ ```jsonc
62
+ {
63
+ "source": "agents/tmp/odins-beard/img_2.png", "character": "veikko",
64
+ "observed": { "hair": { "value": "near-uniform light/blond, split not distinct", "confidence": "high" },
65
+ "eyes": { "value": "both read blue; green not visible", "confidence": "medium" } },
66
+ "unverifiable": ["tattoos[knuckles].text (hands out of frame)"]
67
+ }
68
+ ```
69
+
70
+ ### Layer 3 — `generative_hints` (prompt-assembly guidance)
71
+
72
+ How to render the identity well: anchor ordering (hard-to-render anchors first
73
+ — heterochromia, hair-split), per-engine caveats, negative-prompt seeds. Read
74
+ by `image-creator`; never confused with the canon itself.
75
+
76
+ ## Fidelity rubric — vector + hard gate (not one scalar)
77
+
78
+ A diff scores each observed feature `match | partial | miss`, then reports a
79
+ **vector**, not a single number:
80
+
81
+ 1. **Canon-breaking gate (hard).** ANY `canon-breaking` leaf at `miss` → overall
82
+ **FAIL**, regardless of everything else. Non-negotiable.
83
+ 2. **Per-section scores.** `face`, `hair`, `eyes`, `tattoos`, `outfit`, `jewelry`
84
+ each get their own 0–100 (severity-weighted within the section). Surfaced
85
+ individually so a strong face can't mask a broken hair split.
86
+ 3. **Headline.** A weighted roll-up is shown for convenience but is **advisory** —
87
+ the gate + per-section vector decide pass/fail, not the roll-up.
88
+ 4. **Low-confidence discipline.** A `miss` on a `low`-confidence observation is
89
+ reported as `needs-better-image`, **not** counted as a hard miss — avoids
90
+ false-fail on an un-resolvable feature (re-pass per SKILL § enhancement first).
91
+
92
+ ## Fidelity loop — plateau + oscillation detection
93
+
94
+ `image-creator` generates → `image-analyser` re-reads the output against the
95
+ character's Layer-1 identity → diff → feed `canon-breaking` + `major` misses back
96
+ as refined prompt directives → regenerate.
97
+
98
+ Stop conditions (first to fire):
99
+
100
+ - **PASS** — canon-breaking gate clear AND every per-section score ≥ its
101
+ threshold.
102
+ - **Plateau** — N consecutive rounds with no per-section score improvement →
103
+ stop; the prompt is not the bottleneck (provider/seed is).
104
+ - **Oscillation** — fixing feature X regresses a previously-passing feature Y
105
+ (tracked across rounds) → stop; surface the trade-off, do not thrash.
106
+ - **Budget** — hard ceiling on rounds as a backstop.
107
+
108
+ On any non-PASS stop → **halt and surface** the best candidate + its remaining
109
+ diff for human review. **Never silently accept drift** (per `verify-before-complete`).
@@ -0,0 +1,16 @@
1
+ {
2
+ "skill": "image-analyser",
3
+ "description": "5 should-trigger + 5 should-not-trigger. Should-trigger covers the analyse / canon-diff / accuracy-check / drift-find / bootstrap-from-portrait paths (DE + EN). Should-not covers the near-miss neighbours whose vocabulary overlaps: scene/motion review (video-director), non-character art (canvas-design), cross-scene token lock (character-consistency), generation (image-creator), and document OCR (generic).",
4
+ "queries": [
5
+ {"q": "analyse this character image down to the last detail", "trigger": true},
6
+ {"q": "does img_2.png match the Charakterbuch canon?", "trigger": true},
7
+ {"q": "check this render for character accuracy — what drifted?", "trigger": true},
8
+ {"q": "vergleiche das Bild mit der Charakterbeschreibung, jedes Merkmal", "trigger": true},
9
+ {"q": "build a canon spec from this authoritative portrait", "trigger": true},
10
+ {"q": "turn this scene idea into a cinematic video prompt", "trigger": false, "note": "scene/motion → video-director"},
11
+ {"q": "design a poster for the band", "trigger": false, "note": "static non-character art → canvas-design"},
12
+ {"q": "lock this character's tokens so every scene reuses them", "trigger": false, "note": "cross-scene token lock → character-consistency"},
13
+ {"q": "generate Veikko in the forge scene to spec", "trigger": false, "note": "generation → image-creator"},
14
+ {"q": "extract the text from this scanned invoice", "trigger": false, "note": "plain document OCR, not character analysis"}
15
+ ]
16
+ }
@@ -0,0 +1,117 @@
1
+ ---
2
+ model_tier: high
3
+ name: image-creator
4
+ description: "Use to generate a character image to spec — max-fidelity reproducible prompt from a Canon Spec, anchors-first, provider/governance-gated. Triggers 'generate this character', 'render to spec'."
5
+ personas:
6
+ - hollywood-director
7
+ domain: product
8
+ workspaces:
9
+ - small-business
10
+ packs:
11
+ - ai-video
12
+ lifecycle: experimental
13
+ trust:
14
+ level: experimental
15
+ install:
16
+ default: false
17
+ removable: true
18
+ ---
19
+
20
+ # image-creator
21
+
22
+ > Turn a **Canon Spec** + a scene into a maximally-detailed, reproducible
23
+ > generation prompt that renders a character to spec — then hand the result to
24
+ > [`image-analyser`](../image-analyser/SKILL.md) to verify. The loop partner.
25
+ > Schema + rubric + loop: [`canon-spec.md`](../image-analyser/canon-spec.md).
26
+
27
+ ## When to use
28
+
29
+ - "Generate / render / create this character", "render Veikko in scene X to
30
+ spec", "make the image match the canon".
31
+ - Inside the fidelity loop, fed by `image-analyser`'s correction directives.
32
+
33
+ NOT for: scene blocking / motion (→ `video-director`, `motion-choreographer`,
34
+ which take a verified still from here), non-character art (→ `canvas-design`).
35
+
36
+ ## Input
37
+
38
+ - Character id / Canon Spec (`agents/reference/ai-video/<project>/characters/<id>.json`).
39
+ - Scene brief (setting + pose). Optional: prior `image-analyser` diff (loop mode).
40
+
41
+ ## Procedure
42
+
43
+ 1. **Governance gate FIRST** (per `media-governance-routing`): if the character
44
+ is a real-person likeness, consult `agents/settings/policies/media/likeness.md`
45
+ + `public-figures.md` + `disclosure.md` before emitting anything. Fictional
46
+ characters (odins-beard trio) are exempt; the routing decision is in-session.
47
+ 2. **Provider gate** (per `provider-lifecycle-discipline`): read the resolved
48
+ provider's tier; if non-stable (experimental/deprecated/community), surface
49
+ the tier and ask before running. Never default to a non-stable provider
50
+ silently. Name the provider + tier in the run summary.
51
+ 3. **Assemble the prompt from the spec — anchors first.** Order matters: the
52
+ hard-to-render `identity_anchors` go at the TOP (the canon's lesson —
53
+ heterochromia + hair-split get forgotten if buried). Then physique, face
54
+ (+ marks), per-location tattoos (incl. exact `text`), outfit, jewelry.
55
+ 4. **Asymmetry block** — for split / heterochromatic characters, an explicit
56
+ left/right section ("LEFT half black / RIGHT half blond", "blue LEFT eye /
57
+ green RIGHT eye") with concrete comparison refs for engines that drop it.
58
+ 5. **Negative block + engine settings** — reuse the canon's proven structure
59
+ (negatives that kill "single hair colour", "both eyes same colour", etc.;
60
+ per-engine `--ar`/`--style`/CFG/steps). Do not reinvent; the character book's
61
+ prompt format is the template.
62
+ 6. **Generate** through the existing provider/adapter layer
63
+ (`scripts/ai-video/adapters/`, the `/video|image` surface). Do **not** add a
64
+ new provider path where one exists.
65
+ 7. **Verify** — hand the output to `image-analyser`; in loop mode, fold its
66
+ correction directives into the next prompt (see the loop in `canon-spec.md`).
67
+
68
+ ## Anchors-first — why
69
+
70
+ The fidelity-loss evidence (`img_2.png`): Veikko's split hair + heterochromia
71
+ were missed because they are hard for the engine and were not front-loaded. The
72
+ analyser-derived fixes go to the TOP of the next prompt, with negatives, and the
73
+ loop re-verifies — that is how the smallest mole comes back.
74
+
75
+ ## Output format
76
+
77
+ 1. **Generation prompt** — anchors block · positive · asymmetry (if any) · negative · engine settings.
78
+ 2. **Provider + tier line** (the audit entry).
79
+ 3. **Verify call** — the `image-analyser` invocation on the result + the loop stop-state.
80
+
81
+ ## Example (anchors-first vs buried)
82
+
83
+ - Safe (Veikko): prompt opens with `HAIR: exact vertical centre split, LEFT pitch-black, RIGHT platinum-blond` + `EYES: heterochromia — LEFT ice-blue, RIGHT forest-green`, then the rest.
84
+ - Unsafe: physique/outfit first, the split + heterochromia in a trailing sentence → the engine drops them (the observed `img_2.png` failure).
85
+
86
+ ## Gotchas
87
+
88
+ - Never claim "canon-perfect" without an `image-analyser` pass (per `verify-before-complete`).
89
+ - DALL-E drops heterochromia + split hair — use concrete comparisons; expect multiple generations.
90
+ - Keep the spec the single source: regenerate from the Canon Spec, never paraphrase it into a fresh prompt.
91
+
92
+ ## Do NOT
93
+
94
+ - Do NOT claim "canon-perfect" / "matches the canon" without an `image-analyser`
95
+ pass on the output (per `verify-before-complete` — no completion without evidence).
96
+ - Do NOT bury the `identity_anchors` — the hard-to-render features (heterochromia,
97
+ hair-split) go at the TOP of the prompt, never in a trailing sentence.
98
+ - Do NOT default to a non-stable provider silently — surface the tier and ask
99
+ first (per `provider-lifecycle-discipline`).
100
+ - Do NOT emit a prompt for a real-person likeness before the governance gate
101
+ (step 1) clears it.
102
+ - Do NOT add a new provider/generation path where the existing adapter layer
103
+ (`scripts/ai-video/adapters/`) already covers it.
104
+ - Do NOT paraphrase the Canon Spec into a fresh prompt — regenerate from the spec
105
+ so it stays the single source of truth.
106
+
107
+ ## Policies
108
+
109
+ `media-governance-routing` + `agents/settings/policies/media/` (likeness, style,
110
+ public-figures, disclosure) — consulted in step 1 before any prompt is emitted
111
+ for a real-person likeness.
112
+
113
+ ## Related skills
114
+
115
+ - [`image-analyser`](../image-analyser/SKILL.md) — the verify/loop partner.
116
+ - [`character-consistency`](../character-consistency/SKILL.md) — supplies the locked identity tokens.
117
+ - [`video-director`](../video-director/SKILL.md) / [`motion-choreographer`](../motion-choreographer/SKILL.md) — take the verified still into scene + motion.
@@ -0,0 +1,16 @@
1
+ {
2
+ "skill": "image-creator",
3
+ "description": "5 should-trigger + 5 should-not-trigger. Should-trigger covers generate/render/to-spec/loop-fix paths (DE + EN). Should-not covers near-miss neighbours: analysis (image-analyser), scene/motion (video-director, motion-choreographer), non-character art (canvas-design), and token-lock (character-consistency).",
4
+ "queries": [
5
+ {"q": "generate Veikko in the forge scene, matched to the canon", "trigger": true},
6
+ {"q": "render this character to spec, max detail", "trigger": true},
7
+ {"q": "create the image and make every tattoo placement exact", "trigger": true},
8
+ {"q": "erzeuge das Bild so detailgenau wie möglich nach der Vorlage", "trigger": true},
9
+ {"q": "regenerate with the heterochromia and hair-split fixed", "trigger": true},
10
+ {"q": "analyse this image and tell me what drifted", "trigger": false, "note": "analysis → image-analyser"},
11
+ {"q": "turn this still into a cinematic motion prompt for Veo", "trigger": false, "note": "motion → motion-choreographer"},
12
+ {"q": "expand this one-line idea into a scene blueprint", "trigger": false, "note": "scene → scene-expander/video-director"},
13
+ {"q": "design a tour poster", "trigger": false, "note": "static non-character art → canvas-design"},
14
+ {"q": "lock the character tokens so all scenes reuse them", "trigger": false, "note": "token lock → character-consistency"}
15
+ ]
16
+ }
@@ -0,0 +1,216 @@
1
+ ---
2
+ model_tier: inherit
3
+ name: song-to-script
4
+ description: "Turn an audio track into a timed `## Scene N` script: song sections → per-scene durations, auto mode adds mood + lip-sync lines. Triggers 'music video', 'from the song', 'cut to the beat'."
5
+ personas:
6
+ - hollywood-director
7
+ domain: product
8
+ workspaces:
9
+ - small-business
10
+ packs:
11
+ - ai-video
12
+ lifecycle: experimental
13
+ trust:
14
+ level: experimental
15
+ install:
16
+ default: false
17
+ removable: true
18
+ ---
19
+
20
+ # song-to-script
21
+
22
+ > Turn a song into `<project>/script.md` — a sequence of `## Scene N`
23
+ > blocks whose `duration:` values sum to the track length and whose cut
24
+ > points land on real section boundaries. Consumed by
25
+ > [`/video:from-song`](../../commands/video/from-song.md), then handed
26
+ > to [`scene-expander`](../scene-expander/SKILL.md) and
27
+ > [`video-director`](../video-director/SKILL.md). Never invents timing —
28
+ > every boundary comes from the audio probe, and the probe's `method`
29
+ > tells this skill how musical (or not) those boundaries actually are.
30
+
31
+ ## When to use
32
+
33
+ - A music-video run needs scenes cut to the song (`/video:from-song`).
34
+ - An existing script must be **re-timed** to a track after the edit
35
+ drifted from the beat (the named second consumer — re-time without a
36
+ full re-author).
37
+
38
+ Do NOT use when:
39
+
40
+ - The operator already supplies a `## Scene N` script with `duration:`
41
+ values — feed it straight to `scene-expander`.
42
+ - There is no audio — use the operator brief with `scene-expander`
43
+ directly.
44
+
45
+ ## Inputs
46
+
47
+ - **Audio probe** — JSON from
48
+ [`scripts/ai-video/lib/probe-audio.sh`](../../../../scripts/ai-video/lib/probe-audio.sh):
49
+ `{duration, method, warning?, sections:[{start,end,energy,label}]}`.
50
+ - `method: silence` — boundaries are real quiet gaps; trust them as cuts.
51
+ - `method: rms` — boundaries are energy-delta inflections; usable but
52
+ coarse.
53
+ - `method: interval` — **the track is structurally flat** (brick-walled
54
+ / sustained); sections are fixed-interval, NOT musical. When `method`
55
+ is `interval` (or `warning` is set), the emitted script header states
56
+ that timing is interval-based and the operator should pass
57
+ `--scene-durations` for musical sync. Never present interval cuts as
58
+ beat-synced.
59
+ - **Mode** — `brief` (operator text is the creative source) or `auto`
60
+ (infer mood + action from energy).
61
+ - **Brief** (brief mode only) — free text: story, settings, look.
62
+ - **Character lock** (optional) — `<project>/character.json` if a human
63
+ subject was locked. **Absent is normal** — abstract / landscape /
64
+ visualiser videos have no locked subject; see Step 2.
65
+
66
+ ## Procedure
67
+
68
+ ### Step 1: Map sections → scenes
69
+
70
+ One `## Scene N` per probe section. `duration:` = `end - start`
71
+ (rounded to 0.5 s). Merge any section shorter than the provider's
72
+ `min-duration` into its neighbour; split any section longer than the
73
+ provider's `max-duration` into equal sub-scenes so no single clip
74
+ exceeds the backend limit (read both from the resolved provider tuning).
75
+
76
+ ### Step 2: Assign mood + action
77
+
78
+ First decide the **subject mode**:
79
+
80
+ - **Character mode** — `character.json` exists: every scene's `action:`
81
+ names the locked subject, never a fresh description.
82
+ - **Style mode** — no `character.json`: scenes describe setting, palette,
83
+ and motion continuity (the recurring *look*), not a person. This is the
84
+ valid abstract / landscape / visualiser path — do not invent a human
85
+ subject to fill the slot.
86
+
87
+ Then assign per scene:
88
+
89
+ - **Brief mode** — distribute the brief's beats across scenes in order;
90
+ energy only modulates pacing (low energy → slow push-in, high energy →
91
+ fast cuts / motion). Do not add story the brief did not state.
92
+ - **Auto mode** — derive mood per section from `energy` and `label`:
93
+
94
+ | label / energy | default scene intent |
95
+ |---|---|
96
+ | intro / low | establishing wide, slow camera, calm subject/scene |
97
+ | build / rising | approach, tightening framing |
98
+ | drop / peak | dynamic motion, weather/FX, fast push |
99
+ | breakdown / dip | close-up / detail, quiet, single light source |
100
+ | outro / fade | pull-back, resolve, hold |
101
+
102
+ ### Step 3: Vocal map — transcribe, never guess (vocal tracks)
103
+
104
+ ```
105
+ LYRIC TIMING AND SINGER COME FROM THE TRANSCRIBED AUDIO, NEVER FROM A
106
+ BRIEF / STORY SKELETON OR A GUESSED STRETCH. NEVER PUT ONE SINGER'S
107
+ LINE ON ANOTHER SINGER'S SCENE.
108
+ ```
109
+
110
+ Track has vocals and the run intends lip-sync → build a **vocal map**
111
+ from the real audio before assigning any `dialogue:`:
112
+
113
+ 1. **Transcribe** audio to timestamped lines — OpenAI
114
+ `/v1/audio/transcriptions` (`response_format=verbose_json` →
115
+ `segments[].{start,end,text}`) or local whisper. Only source of lyric
116
+ timing.
117
+ 2. **Label the singer** per line. Operator who-sings reference (roster, a
118
+ brief naming who sings which line, or a character cast) → match each
119
+ line to its singer. Genuinely ambiguous → mark `singer: "?"` and
120
+ surface; never guess a singer to fill the slot.
121
+ 3. **Emit** `<project>/vocal-map.json`: `[{start, end, text, singer}]`,
122
+ timing verbatim from the transcript.
123
+ 4. **Place lines into the matching scene's** `dialogue:` block using
124
+ transcript timing, tagged with the singer (`singer: "<line>"`). A
125
+ scene's lip-sync subject MUST be the line's labelled singer.
126
+
127
+ No vocals / no transcript / no lip-sync intent → leave `dialogue:` empty;
128
+ scene is performance / B-roll. **Never fabricate lyrics**, **never
129
+ re-time a line off the brief**, and in style mode `dialogue:` stays empty
130
+ (lip-sync needs a character subject). The `/video:from-song` sign-off
131
+ gate (its Step 6) shows this map for approval before any render.
132
+
133
+ ### Step 4: Emit + reconcile
134
+
135
+ Write `<project>/script.md` (and `<project>/vocal-map.json` when the
136
+ track has vocals). Report the delta, the section→scene map, **the probe
137
+ `method`** (silence-derived, energy-derived, or interval-fallback), **and
138
+ whether lyric timing is transcript-derived** (it must be — never
139
+ brief-derived). If the sum cannot be reconciled (e.g. provider
140
+ max-duration forces more time than the song has), **halt and surface the
141
+ conflict** — do not pad silently.
142
+
143
+ ### Step 5: Validate before handoff
144
+
145
+ Concrete checks (all must pass before the script is handed to
146
+ `scene-expander`):
147
+
148
+ - **Assert** `Σ(duration) == probe.duration` within ±1.0 s; report the
149
+ exact delta. A larger delta → halt, do not pad.
150
+ - **Verify** every scene boundary equals a probe section boundary (or a
151
+ `--scene-durations` value) — no invented cut points.
152
+ - **Confirm** no scene `duration:` exceeds the provider `max-duration`
153
+ or falls below `min-duration`.
154
+ - **Ensure** every `## Scene N` carries all five keys (`duration` ·
155
+ `mood` · `action` · `camera` · `dialogue`), and that `dialogue:` is
156
+ empty in style mode.
157
+
158
+ ## Output format
159
+
160
+ ```markdown
161
+ # <project> — derived from <song-file> (<mode> mode · cuts: <method>)
162
+
163
+ ## Scene 1
164
+ duration: 6.0
165
+ mood: establishing, cold, pre-storm
166
+ action: <subject from character.json, OR style description in style mode>
167
+ camera: slow push-in
168
+ dialogue:
169
+
170
+ ## Scene 2
171
+ duration: 4.5
172
+ mood: build, rising tension
173
+ action: close on <subject / detail>, wind picking up
174
+ camera: handheld tighten
175
+ dialogue:
176
+ - "<subject>: \"<lyric line for this section, if any>\""
177
+ ```
178
+
179
+ `scene-expander` consumes this verbatim — keep the keys
180
+ (`duration` · `mood` · `action` · `camera` · `dialogue`) exact.
181
+
182
+ ## Gotcha
183
+
184
+ - **`method: interval` is the brick-walled-master signal, not a bug.**
185
+ A compressed modern master has near-constant RMS and no silence, so the
186
+ probe degrades to fixed intervals. That is the honest floor — surface
187
+ it and point the operator at `--scene-durations`; never dress interval
188
+ cuts up as beat-synced.
189
+ - **A vocal section without supplied lyrics is B-roll, not lip-sync.**
190
+ Detected vocal energy alone does not authorise `dialogue:` — only
191
+ operator-supplied lyrics do.
192
+ - **Style mode is the default for a no-character run**, not an error
193
+ path. Landscape / abstract / visualiser videos never get a fabricated
194
+ human subject.
195
+
196
+ ## Do NOT
197
+
198
+ - **Do NOT invent timing.** Every cut maps to a probe boundary or a
199
+ `--scene-durations` value — never to taste.
200
+ - **Do NOT present `interval`-fallback cuts as beat-synced.** Always
201
+ surface the probe `method`.
202
+ - **Do NOT emit a clip outside the provider's min/max duration** —
203
+ split/merge in Step 1 instead.
204
+ - **Do NOT fabricate lyrics or story** beyond the brief / detected vocals.
205
+ - **Do NOT invent a human subject** in style mode; defer identity to
206
+ `character.json` only when a lock exists.
207
+ - **Do NOT pad a unreconcilable timing sum** — halt and surface it.
208
+
209
+ ## See also
210
+
211
+ - [`/video:from-song`](../../commands/video/from-song.md) — the command
212
+ that drives this skill
213
+ - [`scene-expander`](../scene-expander/SKILL.md) — consumes the emitted
214
+ script
215
+ - [`character-consistency`](../character-consistency/SKILL.md) — supplies
216
+ the locked subject referenced in `action:` (character mode only)
@@ -6,7 +6,7 @@
6
6
  },
7
7
  "metadata": {
8
8
  "description": "Shared agent configuration \u2014 skills for AI coding tools (Claude Code, Augment, Cursor, Cline, Windsurf, Gemini CLI).",
9
- "version": "5.4.1",
9
+ "version": "5.6.0",
10
10
  "keywords": [
11
11
  "agent-config",
12
12
  "skills",
@@ -187,6 +187,12 @@
187
187
  "./.claude/skills/gtm-launch",
188
188
  "./.claude/skills/guideline-writing",
189
189
  "./.claude/skills/hiring-loop-design",
190
+ "./.claude/skills/image",
191
+ "./.claude/skills/image-analyse",
192
+ "./.claude/skills/image-analyser",
193
+ "./.claude/skills/image-create",
194
+ "./.claude/skills/image-creator",
195
+ "./.claude/skills/image-verify",
190
196
  "./.claude/skills/implement-ticket",
191
197
  "./.claude/skills/incident-commander",
192
198
  "./.claude/skills/jira-integration",
@@ -349,6 +355,7 @@
349
355
  "./.claude/skills/skill-management",
350
356
  "./.claude/skills/skill-reviewer",
351
357
  "./.claude/skills/skill-writing",
358
+ "./.claude/skills/song-to-script",
352
359
  "./.claude/skills/sql-writing",
353
360
  "./.claude/skills/stakeholder-tradeoff",
354
361
  "./.claude/skills/subagent-orchestration",
@@ -384,13 +391,19 @@
384
391
  "./.claude/skills/video",
385
392
  "./.claude/skills/video-director",
386
393
  "./.claude/skills/video-from-script",
394
+ "./.claude/skills/video-from-song",
387
395
  "./.claude/skills/video-scene",
388
396
  "./.claude/skills/video-stitch",
389
397
  "./.claude/skills/video-storyboard",
390
398
  "./.claude/skills/vision-articulation",
391
399
  "./.claude/skills/voc-extract",
392
400
  "./.claude/skills/voice-and-tone-design",
393
- "./.claude/skills/work"
401
+ "./.claude/skills/work",
402
+ "./.claude/skills/knowledge-cross-repo",
403
+ "./.claude/skills/skill",
404
+ "./.claude/skills/skill-preview",
405
+ "./.claude/skills/skills",
406
+ "./.claude/skills/skills-discover"
394
407
  ]
395
408
  }
396
409
  ]
package/CHANGELOG.md CHANGED
@@ -811,6 +811,90 @@ our recommendation order, not its support status.
811
811
  > that forces a new era split (`# Era: 5.5.x`, etc.) — see
812
812
  > [`docs/contracts/CHANGELOG-conventions.md § Era splits`](docs/contracts/CHANGELOG-conventions.md).
813
813
 
814
+ ## [5.6.0](https://github.com/event4u-app/agent-config/compare/5.5.0...5.6.0) (2026-05-31)
815
+
816
+ ### Features
817
+
818
+ * **ai-video:** add /image command cluster (analyse/create/verify) ([9d53c81](https://github.com/event4u-app/agent-config/commit/9d53c81e3aed3549c4135a641e306a32fa224a68))
819
+ * **ai-video:** add image-analyser + image-creator character-fidelity skills ([b76a4db](https://github.com/event4u-app/agent-config/commit/b76a4db19d537ad5443f2c920c4701a49d08e584))
820
+ * **ai-video:** extend from-song + song-to-script + adapters; add media-sync-ground-truth rule ([dab9f0f](https://github.com/event4u-app/agent-config/commit/dab9f0f41e0d4b93eef423541269d54408bf36f4))
821
+ * **kernel:** kernel-budget soak — trim commit-policy + scope-control, fences byte-identical (Phase 1) ([b0547f0](https://github.com/event4u-app/agent-config/commit/b0547f0207df6e057e2ff97283391ddad88fd2e3))
822
+ * **schema:** tighten description caps + warning window (Phase 2.1); record 3.2 as obviated ([c65d3ae](https://github.com/event4u-app/agent-config/commit/c65d3ae8b569eb3507b83c31967231e64a31a742))
823
+ * **projection:** thin rule-layer projection behind a flag — measured -35,845 GPT tok (Phase 3.1) ([d786363](https://github.com/event4u-app/agent-config/commit/d7863635ee342ab61210ed14b95eeb1fface9582))
824
+ * **value:** drop the € comparison from the value dashboard — tokens only ([33f6fc8](https://github.com/event4u-app/agent-config/commit/33f6fc81e934ca426e5a4c82c37f41624228a636))
825
+ * **bench:** drop the monetary cost comparison — report tokens only ([1a2d3ad](https://github.com/event4u-app/agent-config/commit/1a2d3ad6a177122f0249bb903b3d7d74d62676e1))
826
+ * **audit:** unified audit:tokens analyzer + budget CI gate (Phase 0B.2/0B.4/1.3/1.4) ([c27061f](https://github.com/event4u-app/agent-config/commit/c27061fd47be600d79a5b0a8484a4061f9cdadfd))
827
+ * **safety:** trigger-coverage MUST-LOAD floor + thin-projection kill-switch (Phase 2) ([b210e0b](https://github.com/event4u-app/agent-config/commit/b210e0b9f402e26c813d6fd45e85fdad42876c1d))
828
+ * **budget:** add real-tokenizer measurement alongside chars (Phase 0B.1) ([1602d7f](https://github.com/event4u-app/agent-config/commit/1602d7f2f41a3d6b1069ad675583262542c970cf))
829
+
830
+ ### Bug Fixes
831
+
832
+ * **ai-video:** add workspaces + packs to media-sync-ground-truth rule ([cebe846](https://github.com/event4u-app/agent-config/commit/cebe8465d5cc1b07c8426b91ab52c0fb07e79f5b))
833
+ * sync command count to 145 in README badge + browse lines ([7a881e2](https://github.com/event4u-app/agent-config/commit/7a881e243fe73faad725050d684af682445c4eda))
834
+ * **kernel:** restore 2nd 'Iron Law' mention in commit-policy (obligation-baseline regression from #310) ([693c287](https://github.com/event4u-app/agent-config/commit/693c28791cbe124942835c3b309ca72921ee13f5))
835
+ * **tools:** repoint audit_auto_rules + audit_command_surface to packages/core (Phase 2.3) ([fae234c](https://github.com/event4u-app/agent-config/commit/fae234cfda21372adb493b259a47e8a9a00a0036))
836
+ * **schema:** rule description cap 160 -> 190 (smoke gate treats over-cap as FAIL) ([72f05e0](https://github.com/event4u-app/agent-config/commit/72f05e02cca4e196e514d8f4f573ac9890f52583))
837
+ * **kernel:** repoint iron_law_sha to packages/core layout (Iron-Law SHA gate was broken) ([aab5755](https://github.com/event4u-app/agent-config/commit/aab57558f7047fc21d0107dbab5aa3b49ebe4e2f))
838
+ * **schema:** add lean_projection.mode to the settings schema (template-parity gate) ([51ed03e](https://github.com/event4u-app/agent-config/commit/51ed03ec9e74d4573b7da43a6b45804535986690))
839
+ * **bench:** repoint bench_runner SKILLS_DIR to .agent-src for packages/core layout ([e183527](https://github.com/event4u-app/agent-config/commit/e183527c0efa4e3fe7dfb6a9df2c1e21534925a8))
840
+
841
+ ### Performance
842
+
843
+ * **projection:** minimal thin entries — measured saving 35,845 -> 45,182 GPT tok (77%) ([b1aabe0](https://github.com/event4u-app/agent-config/commit/b1aabe05a9e68aa87a8396f3276530d480582dbe))
844
+
845
+ ### Documentation
846
+
847
+ * **roadmap:** honest dispositions for remaining build-out items ([68e8bb5](https://github.com/event4u-app/agent-config/commit/68e8bb5ab3ec95c516707d9b8e0f2bfd6f7c5ec9))
848
+ * **roadmap:** land Phase 0+2 of road-to-lean-initial-context; spawn build-out follow-up ([8b0bec2](https://github.com/event4u-app/agent-config/commit/8b0bec2efab7128fa4c45d186e3feea4ebd632f8))
849
+
850
+ ### Chores
851
+
852
+ * update reports ([eb52977](https://github.com/event4u-app/agent-config/commit/eb52977cf398f6691e55fc063ba9f1b4f63f03b9))
853
+ * regenerate index + catalog for image skills + /image cluster ([f71f024](https://github.com/event4u-app/agent-config/commit/f71f024dba491ff36c071d9fd25d372e39b0c9c2))
854
+ * regenerate derived (router, marketplace, manifests, counts, command-surface) ([2fcc321](https://github.com/event4u-app/agent-config/commit/2fcc3214451bec3114dee0d55d7f03c0f3392ca0))
855
+ * archive road-to-character-image-fidelity (complete) ([ef16067](https://github.com/event4u-app/agent-config/commit/ef16067c0636a0c8279922bbb160531efb477ddb))
856
+ * track linter-debt roadmap + command-surface report (unrelated to lean-context) ([a52a604](https://github.com/event4u-app/agent-config/commit/a52a6048a55805e5a25b9dc68fd1e98091ba0fec))
857
+ * **router:** regenerate stale dist/router.json from source ([af782fe](https://github.com/event4u-app/agent-config/commit/af782fe179d7ba573ec916e48ac0b9e3752cf6f5))
858
+
859
+ Tests: 5375 (+39 since 5.5.0)
860
+
861
+ ## [5.5.0](https://github.com/event4u-app/agent-config/compare/5.4.1...5.5.0) (2026-05-31)
862
+
863
+ ### Features
864
+
865
+ * /skill:preview — non-destructive skill dry-run ([03ce5fc](https://github.com/event4u-app/agent-config/commit/03ce5fc757f9b42226083627ad7380dd0d895ef7))
866
+ * cross-repo retrieval + linked-projects:list (ADR-032 Option A) ([894e2e8](https://github.com/event4u-app/agent-config/commit/894e2e88c2a7e6744eb45a90907c634953aec0ec))
867
+ * /skills:discover — local, explained skill recommender ([d887c56](https://github.com/event4u-app/agent-config/commit/d887c561514b019f2ae1a3eca068087f4ffee351))
868
+ * meta-layer concept-surface audit tool + zero-cut evidence ([b4a7f3e](https://github.com/event4u-app/agent-config/commit/b4a7f3e5e87ab0c5aa4a820784fba09d8306284a))
869
+ * **video:** add /video:from-song music-video command + register in cluster ([05752df](https://github.com/event4u-app/agent-config/commit/05752dfd0837759923bf02f3731fecfb81dec9e7))
870
+ * **ai-video:** add probe-audio.sh hybrid audio segmentation ([41b4f8d](https://github.com/event4u-app/agent-config/commit/41b4f8dd57d1352df49bdc31bc81ea8e7e04f550))
871
+
872
+ ### Bug Fixes
873
+
874
+ * classify command-cluster files as commands, not skills ([0fd25da](https://github.com/event4u-app/agent-config/commit/0fd25dad8f75cfb7021512e2905b23b24fea88c1))
875
+ * **ai-video:** portability + regenerate stale derived for from-song ([9d728b8](https://github.com/event4u-app/agent-config/commit/9d728b88687a6c27dfa647dd233fb4412f7e8d5a))
876
+
877
+ ### Documentation
878
+
879
+ * reword execution-type mentions to dodge check-refs false positive ([dc84ed0](https://github.com/event4u-app/agent-config/commit/dc84ed01d3aa6845a1e15674ed1ec3ff3bbfb9ce))
880
+ * add discoverable BREAKING_CHANGES.md + major-bump rationale ([385b8a2](https://github.com/event4u-app/agent-config/commit/385b8a225b764cfe09a7e31640184140de4e07d9))
881
+ * **roadmap:** avoid check-refs false-positive on pack name ([bd02ef0](https://github.com/event4u-app/agent-config/commit/bd02ef0b07d27653dbec4971b984d1d12b75ac5e))
882
+ * **roadmap:** /video:from-song implementation roadmap + dashboard ([e4899c2](https://github.com/event4u-app/agent-config/commit/e4899c2c4f57b77bc62aa9187d4aa768ea6885f6))
883
+
884
+ ### Tests
885
+
886
+ * **ai-video:** cover probe-audio segmentation + from-song registration ([9a58807](https://github.com/event4u-app/agent-config/commit/9a588071de1601337e6e65dc9b940b0a36dcfd42))
887
+
888
+ ### Chores
889
+
890
+ * archive road-to-leaner-core-and-discovery (all phases complete) ([6b6b191](https://github.com/event4u-app/agent-config/commit/6b6b191f3b9ff328b9b7f3d6aa6eaf718e471934))
891
+ * regenerate core pack manifest with skill/skill:preview commands ([9bd88c9](https://github.com/event4u-app/agent-config/commit/9bd88c9b7b18bdd16ef2c77066aa485d96fc2b2f))
892
+ * register skills/skill/knowledge clusters + regen outputs ([1156566](https://github.com/event4u-app/agent-config/commit/1156566ad82647c596e47483d57b3fcb71f9a275))
893
+ * bump command count 135 -> 136 in README badge + browse lines ([82c27c3](https://github.com/event4u-app/agent-config/commit/82c27c3383f53d29735784bae5fb86a151c19e39))
894
+ * **ai-video:** regenerate manifests, counts, condensation hashes ([fe4dc28](https://github.com/event4u-app/agent-config/commit/fe4dc280437f209b31190a5117848feb92290015))
895
+
896
+ Tests: 5336 (+65 since 5.4.1)
897
+
814
898
  ## [5.4.1](https://github.com/event4u-app/agent-config/compare/5.4.0...5.4.1) (2026-05-30)
815
899
 
816
900
  ### Documentation
package/CONTRIBUTING.md CHANGED
@@ -237,6 +237,12 @@ Release notes live in [`CHANGELOG.md`](CHANGELOG.md) and are generated by
237
237
  the last tag. Contributors do **not** edit the changelog by hand; writing
238
238
  clean commit subjects is how notes are authored.
239
239
 
240
+ The consumer-facing breaking changes per major are indexed for discovery in
241
+ [`BREAKING_CHANGES.md`](BREAKING_CHANGES.md) — one row per `X.0.0`, each pointing
242
+ back to the full `CHANGELOG.md` entry. That file is the discoverable index; this
243
+ section and [`docs/contracts/CHANGELOG-conventions.md`](docs/contracts/CHANGELOG-conventions.md)
244
+ remain the canonical policy.
245
+
240
246
  ### Runtime dependency floors — never pin to the freshest patch
241
247
 
242
248
  `dependencies` in `package.json` are resolved on the **consumer's** machine