incitaciones 0.3.1 → 0.4.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 (20) hide show
  1. package/content/distilled/agent-value-alignment/SKILL.md +63 -0
  2. package/content/distilled/agent-value-alignment/references/examples.md +46 -0
  3. package/content/distilled/agent-value-alignment/references/integration.md +73 -0
  4. package/content/distilled/agent-value-alignment/references/layer-1-value.md +62 -0
  5. package/content/distilled/agent-value-alignment/references/layer-2-governance.md +74 -0
  6. package/content/distilled/agent-value-alignment/references/layer-3-runtime-prompt.md +68 -0
  7. package/content/distilled/agent-value-alignment/references/layer-4-infrastructure.md +58 -0
  8. package/content/distilled/agent-value-alignment/references/report-template.md +113 -0
  9. package/content/manifest.json +207 -1
  10. package/package.json +1 -1
  11. package/pi-package/prompts/agent-value-alignment.md +10 -0
  12. package/pi-package/skills/agent-value-alignment/SKILL.md +69 -0
  13. package/pi-package/skills/agent-value-alignment/references/examples.md +46 -0
  14. package/pi-package/skills/agent-value-alignment/references/integration.md +73 -0
  15. package/pi-package/skills/agent-value-alignment/references/layer-1-value.md +62 -0
  16. package/pi-package/skills/agent-value-alignment/references/layer-2-governance.md +74 -0
  17. package/pi-package/skills/agent-value-alignment/references/layer-3-runtime-prompt.md +68 -0
  18. package/pi-package/skills/agent-value-alignment/references/layer-4-infrastructure.md +58 -0
  19. package/pi-package/skills/agent-value-alignment/references/report-template.md +113 -0
  20. package/scripts/generate-pi-resources.mjs +122 -1
@@ -1,7 +1,212 @@
1
1
  {
2
- "version": "2026-07-29",
2
+ "version": "2026-07-31",
3
3
  "schema_version": "1.1",
4
4
  "prompts": [
5
+ {
6
+ "name": "agent-value-alignment",
7
+ "type": "task",
8
+ "title": "Agent Value Alignment",
9
+ "description": "Audit or establish the closed loop that anchors an AI agent's behavior to its intended value across four layers — Value, Governance, Runtime Prompt, Infrastructure — bound by a shared vocabulary and traceability matrix; detects goal drift and value drift before lagging metrics confirm them",
10
+ "source": "content/prompt-task-agent-value-alignment.md",
11
+ "distilled": "content/distilled/agent-value-alignment/SKILL.md",
12
+ "skill_format": "progressive-disclosure",
13
+ "tags": [
14
+ "agents",
15
+ "alignment",
16
+ "value-delivery",
17
+ "prompt-engineering",
18
+ "governance",
19
+ "goal-drift",
20
+ "diagnostician",
21
+ "review"
22
+ ],
23
+ "bundles": [
24
+ "reviews"
25
+ ],
26
+ "eval": {
27
+ "task_types": [
28
+ "review",
29
+ "alignment",
30
+ "agents",
31
+ "governance"
32
+ ],
33
+ "success_signals": [
34
+ "falsifiable_value_proposition_present",
35
+ "kill_criteria_signed_with_owner",
36
+ "goal_sandwich_pattern_verified",
37
+ "value_focused_eval_suite_present",
38
+ "traceability_matrix_complete",
39
+ "integration_invariant_checked",
40
+ "layer_specific_gaps_cited_with_locations",
41
+ "final_verdict_present"
42
+ ],
43
+ "failure_signals": [
44
+ "unfalsifiable_value_proposition_accepted",
45
+ "output_correctness_eval_mistaken_for_value_eval",
46
+ "unsigned_kill_criteria_accepted",
47
+ "governance_decision_without_prompt_clause_not_flagged",
48
+ "prompt_clause_without_eval_test_not_flagged",
49
+ "drift_assumed_absent_without_evidence",
50
+ "findings_without_specific_locations",
51
+ "fixes_implemented_during_audit_session"
52
+ ],
53
+ "stages": [
54
+ {
55
+ "name": "setup",
56
+ "hints": [
57
+ "target",
58
+ "mode",
59
+ "audit",
60
+ "establish",
61
+ "collect artifacts"
62
+ ]
63
+ },
64
+ {
65
+ "name": "layer-1-value",
66
+ "hints": [
67
+ "references/layer-1-value.md",
68
+ "falsifiable",
69
+ "kill criteria",
70
+ "leading indicator"
71
+ ]
72
+ },
73
+ {
74
+ "name": "layer-2-governance",
75
+ "hints": [
76
+ "references/layer-2-governance.md",
77
+ "BSD",
78
+ "agent charter",
79
+ "scope gate",
80
+ "BADR"
81
+ ]
82
+ },
83
+ {
84
+ "name": "layer-3-runtime-prompt",
85
+ "hints": [
86
+ "references/layer-3-runtime-prompt.md",
87
+ "goal sandwich",
88
+ "scope fence",
89
+ "eval",
90
+ "llm-as-judge"
91
+ ]
92
+ },
93
+ {
94
+ "name": "layer-4-infrastructure",
95
+ "hints": [
96
+ "references/layer-4-infrastructure.md",
97
+ "checkpointing",
98
+ "memory",
99
+ "HITL",
100
+ "decay dashboard"
101
+ ]
102
+ },
103
+ {
104
+ "name": "integration",
105
+ "hints": [
106
+ "references/integration.md",
107
+ "vocabulary",
108
+ "traceability",
109
+ "verbatim propagation",
110
+ "invariant"
111
+ ]
112
+ },
113
+ {
114
+ "name": "report",
115
+ "hints": [
116
+ "references/report-template.md",
117
+ "final report",
118
+ "verdict"
119
+ ]
120
+ }
121
+ ],
122
+ "references": [
123
+ {
124
+ "id": "layer-1-value",
125
+ "path": "content/distilled/agent-value-alignment/references/layer-1-value.md",
126
+ "purpose": "layer-rubric",
127
+ "stage": "layer-1-value",
128
+ "optional": true,
129
+ "aliases": [
130
+ "references/layer-1-value.md",
131
+ "layer-1-value.md",
132
+ "layer 1"
133
+ ]
134
+ },
135
+ {
136
+ "id": "layer-2-governance",
137
+ "path": "content/distilled/agent-value-alignment/references/layer-2-governance.md",
138
+ "purpose": "layer-rubric",
139
+ "stage": "layer-2-governance",
140
+ "optional": true,
141
+ "aliases": [
142
+ "references/layer-2-governance.md",
143
+ "layer-2-governance.md",
144
+ "layer 2"
145
+ ]
146
+ },
147
+ {
148
+ "id": "layer-3-runtime-prompt",
149
+ "path": "content/distilled/agent-value-alignment/references/layer-3-runtime-prompt.md",
150
+ "purpose": "layer-rubric",
151
+ "stage": "layer-3-runtime-prompt",
152
+ "optional": true,
153
+ "aliases": [
154
+ "references/layer-3-runtime-prompt.md",
155
+ "layer-3-runtime-prompt.md",
156
+ "layer 3"
157
+ ]
158
+ },
159
+ {
160
+ "id": "layer-4-infrastructure",
161
+ "path": "content/distilled/agent-value-alignment/references/layer-4-infrastructure.md",
162
+ "purpose": "layer-rubric",
163
+ "stage": "layer-4-infrastructure",
164
+ "optional": true,
165
+ "aliases": [
166
+ "references/layer-4-infrastructure.md",
167
+ "layer-4-infrastructure.md",
168
+ "layer 4"
169
+ ]
170
+ },
171
+ {
172
+ "id": "integration",
173
+ "path": "content/distilled/agent-value-alignment/references/integration.md",
174
+ "purpose": "integration-check",
175
+ "stage": "integration",
176
+ "optional": true,
177
+ "aliases": [
178
+ "references/integration.md",
179
+ "integration.md",
180
+ "integration"
181
+ ]
182
+ },
183
+ {
184
+ "id": "report-template",
185
+ "path": "content/distilled/agent-value-alignment/references/report-template.md",
186
+ "purpose": "output-template",
187
+ "stage": "report",
188
+ "optional": false,
189
+ "aliases": [
190
+ "references/report-template.md",
191
+ "report-template.md",
192
+ "report template"
193
+ ]
194
+ },
195
+ {
196
+ "id": "examples",
197
+ "path": "content/distilled/agent-value-alignment/references/examples.md",
198
+ "purpose": "examples",
199
+ "stage": "report",
200
+ "optional": true,
201
+ "aliases": [
202
+ "references/examples.md",
203
+ "examples.md",
204
+ "examples"
205
+ ]
206
+ }
207
+ ]
208
+ }
209
+ },
5
210
  {
6
211
  "name": "specification-review",
7
212
  "type": "task",
@@ -3584,6 +3789,7 @@
3584
3789
  "reviews": {
3585
3790
  "description": "Code, design, and research review processes",
3586
3791
  "prompts": [
3792
+ "agent-value-alignment",
3587
3793
  "code-review",
3588
3794
  "parallel-review",
3589
3795
  "optionality-review",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "incitaciones",
3
- "version": "0.3.1",
3
+ "version": "0.4.0",
4
4
  "description": "Reusable prompts and skills for CLI LLM tools, with native pi package support.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -0,0 +1,10 @@
1
+ ---
2
+ description: "Shortcut for the agent-value-alignment skill. Audit or establish the closed loop that anchors an AI agent's behavior to its intended value across four layers — Value, Governance, Runtime Prompt, Infrastructure — bound by a shared vocabulary and traceability matrix; detects goal drift and value drift before lagging metrics confirm them"
3
+ ---
4
+ <!-- installed-from: incitaciones -->
5
+
6
+ Use the installed `agent-value-alignment` skill for this task.
7
+
8
+ If the skill is not automatically loaded, invoke `/skill:agent-value-alignment` and follow it.
9
+
10
+ User context: $@
@@ -0,0 +1,69 @@
1
+ ---
2
+ name: agent-value-alignment
3
+ description: "Audit or establish the closed loop that anchors an AI agent's behavior to its intended value across four layers — Value, Governance, Runtime Prompt, Infrastructure — bound by a shared vocabulary and traceability matrix; detects goal drift and value drift before lagging metrics confirm them"
4
+ metadata:
5
+ installed-from: "incitaciones"
6
+ ---
7
+ # Agent Value Alignment
8
+
9
+ Audit or establish the closed loop that anchors an AI agent's (or tool's) behavior to its intended value. Operates across four layers — Value, Governance, Runtime Prompt, Infrastructure — bound by a shared vocabulary and traceability matrix.
10
+
11
+ The core thesis: **goal drift (agent) and value drift (team) are the same failure at different scales** — the absence of structured, repeatable mechanisms to anchor behavior to intent. The governing invariant is that *every governance decision must have a corresponding prompt clause, and every prompt clause a corresponding eval test*.
12
+
13
+ ## Setup
14
+
15
+ - Determine the **target**: the agent or tool being aligned.
16
+ - Determine the **mode**:
17
+ - **AUDIT** — evaluate an existing agent/tool against the four-layer framework; produce a gap report.
18
+ - **ESTABLISH** — stand up the artifacts for a new or un-governed agent/tool, following the one-week adoption sequence.
19
+ - If a value proposition, system prompt, eval suite, or behavioral spec already exists for the target, collect them before starting.
20
+
21
+ For **AUDIT** mode, each "Confirm" step is a check, not a gate: a missing or
22
+ failing artifact is recorded as a finding (not a blocker) — continue through
23
+ all layers before reporting. For **ESTABLISH** mode, follow the day-map below.
24
+
25
+ ## Procedure
26
+
27
+ 1. **Layer 1 — Value.** Confirm the target has a *falsifiable* value proposition (user segment + outcome + amount + timeframe + metric + baseline), kill criteria with a named owner, and a measurement plan distinguishing leading from lagging indicators. Read `references/layer-1-value.md`.
28
+ 2. **Layer 2 — Governance.** Confirm a Behavioral Specification Document (BSD) / Agent Charter defines authorized and prohibited behavior, escalation triggers, and success metrics; confirm scope gates and review ceremonies exist. Read `references/layer-2-governance.md`.
29
+ 3. **Layer 3 — Runtime Prompt.** Confirm the system prompt anchors the objective (Goal Sandwich), fences scope, encodes Minimal Footprint, includes drift-detection/self-check loops, and is verified by a value-focused eval suite (not output-correctness evals). Read `references/layer-3-runtime-prompt.md`.
30
+ 4. **Layer 4 — Infrastructure.** Confirm alignment-oriented checkpointing (not just fault tolerance), a deliberate memory architecture, HITL interrupts at irreversible boundaries, and drift observability. Read `references/layer-4-infrastructure.md`.
31
+ 5. **Integration.** Confirm the layers are bound: shared vocabulary document, verbatim propagation of the value proposition across system prompt + BSD + review agenda, traceability matrix linking each governance decision → prompt clause → eval test, and eval results feeding the review cadence. Read `references/integration.md`.
32
+ 6. **Report.** Use `references/report-template.md`. The verdict and
33
+ layer-status vocabulary (ALIGNED/PARTIAL/NOT_ALIGNED; 🟢/🟡/🔴) are defined
34
+ in the report template — size findings accordingly as you go, not just at
35
+ report time.
36
+
37
+ For **ESTABLISH** mode, the one-week sequence is distributed across the layer
38
+ references — each contains its own ESTABLISH days:
39
+
40
+ | Day | Artifact(s) | Reference |
41
+ |---|---|---|
42
+ | 1 | Falsifiable Value Proposition | `references/layer-1-value.md` |
43
+ | 2 | Kill Criteria + Agent Charter (+ BSD draft) | `references/layer-1-value.md`, `references/layer-2-governance.md` |
44
+ | 3 | Goal Sandwich system prompt | `references/layer-3-runtime-prompt.md` |
45
+ | 4 | 10 eval test cases | `references/layer-3-runtime-prompt.md` |
46
+ | 5 | Value Realization Review scheduled + decay dashboard | `references/layer-4-infrastructure.md` |
47
+
48
+ Produce the minimum viable artifact set day-by-day, then run steps 5–6 to
49
+ confirm the loop is closed.
50
+
51
+ If artifacts already exist but are incomplete or unfalsifiable (the common
52
+ partial-governance case), run **AUDIT** first to baseline the gaps, then
53
+ ESTABLISH the missing pieces — do not treat Day 1's "stop if the team cannot
54
+ agree on the VP" as blocking a retrofit of an existing vague VP.
55
+
56
+ ## Rules
57
+
58
+ - Drift is the default assumption. The burden of proof is on evidence that behavior is anchored to intent — not on evidence that it has drifted.
59
+ - Never accept a value proposition that cannot be falsified. "Help users be more productive" is a wish, not an objective.
60
+ - Never accept an eval suite that measures output correctness without also measuring outcome achievement ("did this help the user accomplish their goal?").
61
+ - Never accept kill criteria without a named decision owner and a specific threshold + date. Unsigned criteria are suggestions.
62
+ - Flag any governance decision with no corresponding prompt clause (not enforced), any prompt clause with no eval test (not verified), and any eval result not reviewed in governance (not acted upon).
63
+ - Cite the specific artifact and location for every finding. Do not fabricate gaps.
64
+ - This skill is advisory — it produces a report and recommended actions; it does not itself edit prompts, evals, or governance documents.
65
+ - Where sources disagree on facts (e.g., paper dates), follow the more authoritative citation and note the discrepancy.
66
+
67
+ ## Source
68
+
69
+ Derived from `content/research-synthesis-agent-value-alignment.md`, which synthesizes three source reports on value delivery verification, agentic alignment/checkpointing, and prompt engineering frameworks. Consult the synthesis for full citations, framework attributions, and worked examples.
@@ -0,0 +1,46 @@
1
+ # Agent Value Alignment — Worked Examples
2
+
3
+ Optional reference. Use these to calibrate severity ratings and report format. Two examples: a sample finding showing the severity rubric applied, and a sample completed layer-score table.
4
+
5
+ ## Example 1: A sample finding with severity rationale
6
+
7
+ A team is auditing "PRBot," an AI agent that reviews pull requests. They have a system prompt and an eval suite but no kill criteria and no BSD.
8
+
9
+ #### [L1-FINDING-002] [HIGH] — Kill Criteria Document: not present
10
+ - **Layer:** 1 — Value
11
+ - **What's wrong:** No kill criteria exist. The team has a falsifiable VP ("PRBot will reduce PR time-to-merge by 30% within 90 days, measured by median GitHub PR open→merge vs. the 90-day pre-deployment baseline") but no pre-committed stopping conditions.
12
+ - **Why it matters:** Without signed kill criteria, sunk-cost rationalization will keep the tool alive past its evidence threshold — the #1 value-level failure mode (root cause: rationalization under sunk cost). The VP is falsifiable but cannot be honestly *falsified* in practice.
13
+ - **Recommendation:** Author ≥3 kill criteria (metric + threshold + date + named owner + consequence) and have them signed by Product and Engineering leads before the next deployment. Owner: Product Manager. Due: 2026-08-14.
14
+ - **Invariant violated:** none directly (this is a Layer-1 gap, not an invariant break).
15
+ - **Severity rationale:** HIGH, not CRITICAL — a Layer-1 artifact is missing and the loop cannot close without it, but no irreversible-action boundary is unguarded and the invariant is not yet broken.
16
+
17
+ ## Example 2: A CRITICAL finding (invariant break)
18
+
19
+ #### [INT-FINDING-001] [CRITICAL] — Traceability gap: 3 BSD decisions have no prompt clause
20
+ - **Layer:** Integration
21
+ - **What's wrong:** The BSD prohibits storing PII (§3.2), requires confirmation before any external communication (§4.1), and limits file access to `/workspace/data/` (§3.1). The system prompt encodes the file-access limit (Scope Fence) but contains **no clause** for the PII prohibition or the external-communication confirmation requirement.
22
+ - **Why it matters:** Two governance decisions are unenforced at runtime. The agent could store PII or send external communications with no prompt-level constraint — a direct break of the governing invariant ("every governance decision must have a corresponding prompt clause"). One unguarded boundary (external communication) is irreversible.
23
+ - **Recommendation:** Add a Minimal Footprint clause and an explicit prohibition to the system prompt's Scope Fence for both behaviors; add eval cases that verify refusal/escalation on PII-storage and external-comm triggers. Owner: Agent Engineer. Due: immediately (blocks deployment).
24
+ - **Invariant violated:** enforcement (decision exists, no prompt clause).
25
+
26
+ ## Example 3: A completed layer-score table
27
+
28
+ For the same PRBot audit, after all layers reviewed:
29
+
30
+ | Layer | Status | Critical gaps |
31
+ |---|---|---|
32
+ | 1 — Value | 🟡 | 0 |
33
+ | 2 — Governance | 🔴 | 1 |
34
+ | 3 — Runtime Prompt | 🟢 | 0 |
35
+ | 4 — Infrastructure | 🟡 | 0 |
36
+ | Integration | 🔴 | 1 |
37
+
38
+ **Overall verdict:** NOT_ALIGNED
39
+
40
+ Rationale: Layer 2 is 🔴 because the BSD is missing entirely (a HIGH finding, but it escalates the layer to 🔴 since the loop cannot close without it — per the rubric, treat a missing foundational Layer-1/2 artifact as 🔴 for the layer). Integration is 🔴 due to the CRITICAL invariant break in Example 2. Layers 1 and 4 are 🟡 (failures with compensating controls: Layer 1 has no kill criteria but the VP is falsifiable; Layer 4 has observability but no decay dashboard yet). Layer 3 passes all checks.
41
+
42
+ ## Inter-rater calibration notes
43
+
44
+ - A missing BSD is HIGH as a finding but 🔴 as a layer status — the severity describes the finding; the layer status follows the rubric (≥1 CRITICAL → 🔴; any HIGH/MEDIUM → 🟡). Reconcile by treating a missing foundational Layer-1/2 artifact as 🔴 for the layer even when the finding itself is HIGH, because the loop cannot close without it.
45
+ - An unfalsifiable VP is always HIGH (never MEDIUM) — the rubric's "Layer-1 artifact missing/unfalsifiable" clause.
46
+ - A missing eval test for a prompt clause is CRITICAL only if the clause guards an irreversible action; otherwise MEDIUM (check fails, compensating control = the prompt clause itself exists and may be manually reviewed).
@@ -0,0 +1,73 @@
1
+ # Integration: Closing the Loop
2
+
3
+ **Question:** Are the four layers bound into one auditable system — or are they four separate piles of advice?
4
+
5
+ The governing invariant:
6
+
7
+ > **Every governance decision must have a corresponding prompt clause, and every prompt clause must have a corresponding eval test.** If a decision exists in the BSD but has no prompt clause, it is not enforced. If a prompt clause exists but has no eval test, it is not verified. If an eval test exists but is not reviewed in governance, it is not acted upon.
8
+
9
+ ## The vocabulary bridge
10
+
11
+ The most common integration failure is **vocabulary fragmentation**: the system prompt says "PRIMARY OBJECTIVE," the eval suite says "goal," the value realization review says "value delivery" — all referring to the same thing without anyone knowing it. When language is inconsistent, no behavioral observation can be traced to a governance decision, and no governance decision can be translated into a prompt change.
12
+
13
+ **Fix:** a shared vocabulary document mapping each concept across system prompt / eval / governance terms, plus a **traceability matrix** linking each governance decision → prompt clause → eval test ID.
14
+
15
+ | Concept | System prompt term | Eval term | Governance term |
16
+ |---|---|---|---|
17
+ | What the agent is trying to do | PRIMARY OBJECTIVE | goal | value proposition |
18
+ | What the agent is not allowed to do | PROHIBITED ACTIONS | scope violation | out of scope |
19
+ | When the agent should stop and ask | ESCALATION TRIGGER | escalation behavior | human oversight event |
20
+ | Whether the agent helped the user | OBJECTIVE CHECK | goal achievement score | value delivery |
21
+ | Agent doing something unintended | SCOPE BOUNDARY REACHED | behavioral regression | alignment gap |
22
+ | Agent gradually shifting behavior | DRIFT CHECK (inner-monologue) | regression in eval suite | behavioral drift |
23
+
24
+ ## Verbatim propagation of the value proposition
25
+
26
+ The value proposition statement must appear **verbatim** in three places:
27
+
28
+ 1. The system prompt — as the PRIMARY OBJECTIVE in the Goal Sandwich.
29
+ 2. The BSD — Section 1 (Purpose and Objective).
30
+ 3. The Value Realization Review agenda — read aloud at the opening of every review.
31
+
32
+ When the value proposition changes, all three must be updated together, the eval suite re-run, and a Value Realization Review scheduled to re-baseline. This creates a direct, auditable chain from governance commitment to runtime behavior.
33
+
34
+ ## Automated value reporting
35
+
36
+ Agents can be prompted to emit a structured JSON value report at the end of each task:
37
+
38
+ ```json
39
+ {
40
+ "task_id": "...",
41
+ "original_objective": "[restate]",
42
+ "goal_alignment": { "score": 1-5, "reasoning": "...", "gaps": "..." },
43
+ "scope_compliance": { "compliant": true/false, "violations": "...", "escalations": "..." },
44
+ "user_value_delivered": { "score": 1-5, "user_can_now": "..." },
45
+ "resource_usage": { "tools_called": N, "steps_taken": N, "footprint": "minimal|appropriate|excessive" },
46
+ "flags": { "requires_human_review": true/false, "reason": "..." }
47
+ }
48
+ ```
49
+
50
+ These fields map directly to eval dimensions, feeding the decay detection dashboard and providing evidence for Value Realization Reviews — closing the loop with minimal manual data collection.
51
+
52
+ ## The eval suite as the bridge
53
+
54
+ The eval suite is the load-bearing structure between Layers 2 and 3. It must be run:
55
+
56
+ - On every prompt change (before deployment).
57
+ - On every model update (before deployment).
58
+ - Weekly (as part of the decay dashboard).
59
+ - Before every Value Realization Review (as evidence).
60
+ - After every behavioral incident (to characterize the failure).
61
+
62
+ **Sprint-review gate:** do not demo new agent capabilities if eval pass rate has declined from the previous sprint without explanation.
63
+
64
+ **Value Realization Review question:** *is the relationship between eval pass rate and the primary value metric what we expected? If not, what does that tell us about our eval design?*
65
+
66
+ ## AUDIT checks (integration-specific)
67
+
68
+ - [ ] Shared vocabulary document exists and is used across all artifacts.
69
+ - [ ] Traceability matrix links every governance decision → prompt clause → eval test.
70
+ - [ ] Value proposition appears verbatim in system prompt, BSD §1, and review agenda.
71
+ - [ ] Eval suite runs on the five required triggers above.
72
+ - [ ] Eval results are reviewed in sprint reviews and Value Realization Reviews.
73
+ - [ ] (If applicable) automated value reports feed the decay dashboard.
@@ -0,0 +1,62 @@
1
+ # Layer 1 — Value: Defining and Verifying the Promise
2
+
3
+ **Question:** What value was promised, to whom, and how will we know if it was delivered?
4
+
5
+ ## The falsifiable value proposition
6
+
7
+ A value proposition is only useful if it can be proven false. The canonical structure:
8
+
9
+ > "[TOOL] will enable [USER SEGMENT] to [OUTCOME VERB] [OUTCOME OBJECT] by [AMOUNT] within [TIMEFRAME], as measured by [METRIC]."
10
+
11
+ Append **"compared to [BASELINE]"** as a falsifiability requirement — improvement is meaningless without a baseline.
12
+
13
+ If you cannot fill every slot, you have an aspiration, not a value proposition. Post-hoc rationalization ("we missed the metric but look at this other one") is the most common honesty failure.
14
+
15
+ ## Output vs. outcome vs. impact
16
+
17
+ - **Outputs** — what was built (within the team's control; always looks successful).
18
+ - **Outcomes** — what changed in user behavior.
19
+ - **Impact** — what changed at the business level.
20
+
21
+ Measure at all three. Outputs are leading indicators of outcomes; outcomes of impact. A tool with high output volume but low outcome change is in the **activity trap**.
22
+
23
+ ## Measurement disciplines
24
+
25
+ 1. **Resist Goodhart's Law.** When a measure becomes a target, it ceases to be a good measure. Four failure types: regressive, extremal, causal, adversarial (Cobra Effect). Counter: multiple metrics in healthy tension; metrics requiring genuine behavioral change; monitor trends not point values; audit when metrics move unexpectedly.
26
+ 2. **Leading before lagging.** A code assistant's "acceptance rate without modification" is *leading*; "PR cycle time reduction" is *lagging*. By the time lagging confirms failure, months are sunk.
27
+ 3. **Counterfactual measurement.** Gold standard = randomized controlled trial. Where infeasible: difference-in-differences, regression discontinuity, instrumental variables. Self-reported productivity gains are not evidence.
28
+
29
+ ## Frameworks (when to reach for which)
30
+
31
+ - **JTBD / ODI** (Ulwick/Christensen) — define value solution-free; 86% success vs. 17% industry avg.
32
+ - **Impact Mapping** (Adzic) — trace every deliverable → impact → goal; kills unmapped features.
33
+ - **Opportunity Solution Trees** (Torres) — outcome → opportunities → solutions → assumption tests.
34
+ - **HEART + GSM** (Google) — force multi-dimensional measurement; resists engagement over-indexing.
35
+ - **North Star Metric** — single leading indicator; not directly movable by the team.
36
+ - **OKRs** — outcome-based key results, quarterly, divorced from compensation.
37
+ - **Working Backwards / PR-FAQ** (Amazon) — articulate success + the hard questions before building.
38
+ - **Benefits Realization Management** (Jenner) — formal benefits register, independent verification.
39
+
40
+ ## Accountability
41
+
42
+ - **Kill criteria** — written *before* development; four components: metric, threshold, timeframe, consequence; named decision owner; signed. Unsigned/vague criteria are not criteria.
43
+ - **Independent evaluation** — the building team must not be the sole measurer (structural conflict of interest, not honesty).
44
+ - **Value realization reviews** — quarterly ceremony (distinct from sprint review/retro): restate VP → review evidence → gap analysis → causal analysis → explicit continue/pivot/kill.
45
+ - **Portfolio governance** — forces honest comparison across tools; sunsetting is a pre-committed plan, not a political judgment.
46
+
47
+ ## Activity trap diagnostic
48
+
49
+ Ask: *if this tool disappeared tomorrow, what would users lose?* If the honest answer is "not much," the tool is busy but not valuable.
50
+
51
+ ## AUDIT checks
52
+
53
+ - [ ] Falsifiable VP exists with all slots filled (including baseline).
54
+ - [ ] Kill criteria exist, are signed, pre-development, with named owner + specific threshold + date.
55
+ - [ ] Measurement plan tracks leading *and* lagging indicators.
56
+ - [ ] Value realization review is scheduled on a cadence shorter than the drift half-life.
57
+ - [ ] Evaluation is independent of the building team.
58
+
59
+ ## ESTABLISH (Day 1–2)
60
+
61
+ - Day 1 (2h): Write the falsifiable value proposition. *If the team cannot agree on the single sentence, the disagreement is the most important discovery — do not proceed.*
62
+ - Day 2 (1h): Write ≥3 kill criteria with specific numbers, dates, owners; sign them.
@@ -0,0 +1,74 @@
1
+ # Layer 2 — Governance: Specifying Authorized Behavior
2
+
3
+ **Question:** What behavior is authorized, prohibited, and escalated — and who reviews it?
4
+
5
+ ## Why agent governance is different
6
+
7
+ In traditional software, behavior = code; correct code ⇒ correct behavior. In agent systems, behavior emerges from code × model × prompts × tools × execution context — none fully specifiable in advance. Traditional governance (code review, automated tests, deploy gates) is necessary but insufficient. You need mechanisms that detect behavioral drift *even when the code is correct*.
8
+
9
+ ## Core artifacts
10
+
11
+ | Artifact | Purpose |
12
+ |---|---|
13
+ | **Behavioral Specification Document (BSD)** | Authoritative reference for *how* the agent should behave; source of truth for prompts, evals, audits. Covers: purpose, authorized behaviors, prohibited behaviors, escalation criteria, behavioral principles, success metrics, known limitations/edge cases. |
14
+ | **Agent Charter** | One-page "constitution" readable by non-technical stakeholders: purpose, scope, principles, prohibitions, escalation, success/failure criteria, governance. |
15
+ | **Kill Criteria Document** | Pre-committed stopping conditions, signed before development (see Layer 1). |
16
+ | **Behavioral ADRs (BADRs)** | Record of intent for significant behavioral decisions — context, decision, options, rationale, consequences, implementation. Distinguishes bug from feature when behavior is questioned. |
17
+ | **Falsifiable Value Proposition** | Propagates verbatim into BSD §1, system prompt, and review agenda (see Integration). |
18
+ | **Pre-mortem** | Imagine failure in advance; generate mitigations with owners. |
19
+
20
+ ## The "scope creep by proxy" anti-pattern
21
+
22
+ The signature governance failure for agents: capabilities expand through accumulation of *individually reasonable* changes — tool proliferation, edge-case capability expansion, behavioral drift from model updates, prompt accumulation. Each change is justified by a use case; the cumulative expansion was never approved. Hard to detect in real time.
23
+
24
+ **Countermeasure:** explicit scope gates at defined milestones — behavioral scope, tool access, data access, output scope reviews — with deviations either formally approved (via BADR) or rolled back.
25
+
26
+ ## Review ceremonies (augment traditional sprints)
27
+
28
+ - **Behavioral regression testing** at each sprint boundary — checks alignment, not just functional correctness.
29
+ - **Red-team reviews** at regular intervals — attempt to induce goal drift, specification gaming, scope violations.
30
+ - **Alignment reviews** by team members *not* in the recent sprint — external perspective catches gradual drift invisible to builders.
31
+ - **Incident post-mortems** that classify incidents as goal drift / specification gaming / scope violation, with prevention recommendations. Treat agent behavior incidents with the rigor of security incidents.
32
+
33
+ ## Open-source / distributed governance
34
+
35
+ Contributors carry different understandings of the objective; PR review is poorly suited to evaluating behavioral alignment. Best practices: versioned behavioral specs, behavioral contribution guidelines, behavioral CI/CD on every PR, designated *alignment maintainers* distinct from technical maintainers.
36
+
37
+ ## Multi-agent systems
38
+
39
+ If the target is a multi-agent system (orchestrator/worker hierarchies), the
40
+ single-agent checklists are necessary but not sufficient — drift can occur at
41
+ four levels invisible to per-agent review: **orchestrator drift** (task
42
+ decomposition diverges from the objective), **worker drift** (a worker
43
+ diverges from its sub-task), **coordination drift** (orchestrator–worker
44
+ interaction diverges), and **emergent drift** (collective behavior diverges
45
+ in ways not visible at the individual level).
46
+
47
+ **Additional AUDIT checks for multi-agent targets:**
48
+ - [ ] Every worker sub-task has an explicit, verifiable specification (not a
49
+ high-level instruction) and a defined success criterion.
50
+ - [ ] The orchestrator verifies worker results against the sub-task spec before
51
+ incorporating them.
52
+ - [ ] Cross-agent consistency checks exist (outputs of different workers are
53
+ consistent with each other and the overall objective).
54
+ - [ ] HITL review is configured at both orchestrator (task decomposition) and
55
+ worker (sub-task execution) levels.
56
+
57
+ See the synthesis §5.6 for the orchestrator/worker alignment patterns and the
58
+ multi-agent alignment prompts.
59
+
60
+ ## AUDIT checks
61
+
62
+ - [ ] BSD exists and is version-controlled with the same rigor as code.
63
+ - [ ] Agent Charter exists (≤1 page, readable by non-technical stakeholders).
64
+ - [ ] Prohibited behaviors are explicit (negation), not implicit.
65
+ - [ ] Escalation triggers are specific (not "when uncertain" but the 7 named triggers — see Layer 3).
66
+ - [ ] Scope gates exist at milestones; deviations require BADR.
67
+ - [ ] Behavioral regression tests run at sprint boundaries.
68
+ - [ ] Red-team reviews occur on a cadence.
69
+ - [ ] *(Multi-agent only)* Sub-task specs, result verification, and cross-agent
70
+ consistency checks exist (see Multi-agent systems above).
71
+
72
+ ## ESTABLISH (Day 2)
73
+
74
+ - Day 2 (1h): Write the Agent Charter (≤1 page). Draft the BSD (can be expanded later, but purpose/scope/prohibitions/escalation must exist from day one).
@@ -0,0 +1,68 @@
1
+ # Layer 3 — Runtime Prompt: Enforcing Alignment at Execution Time
2
+
3
+ **Question:** Do the runtime instructions actually anchor behavior to the objective — and are they verified?
4
+
5
+ ## The foundational constraint: lost in the middle
6
+
7
+ LLM performance follows a **U-shaped curve**: models attend well to the beginning (primacy) and end (recency) of context and systematically underweight the middle (Liu et al., 2023; TACL 2024). Context length *alone* degrades performance 13.9–85% even with perfect retrieval (Du et al., 2025). An objective stated once at the top of a long system prompt, after tool results accumulate, is buried in the middle and statistically underweighted. This is structural, not an intelligence failure.
8
+
9
+ ## Goal-anchoring patterns
10
+
11
+ | Pattern | Mechanism | Addresses |
12
+ |---|---|---|
13
+ | **Goal Sandwich** | Primary objective verbatim at top *and* bottom of system prompt | U-shaped attention |
14
+ | **Objective Echo** | Agent restates objective before each major action | Active retrieval vs. passive presence |
15
+ | **Scope Fence** | Explicit negation of prohibited actions | Implicit-scope unreliability |
16
+ | **Minimal Footprint Clause** | Resource/side-effect constraints | Instrumental convergence pressure |
17
+ | **Constitutional self-critique** | Critique-then-revise against stated principles (Bai et al., 2022) | Goal alignment at output time |
18
+ | **Persistent objective store** | Objective retrieved from outside the context window | Compression/summarization drift |
19
+
20
+ **Instruction hierarchy:** primary objective in first and last 5 lines; scope fence + minimal footprint early; operational detail in the (lower-attention) middle; constitutional critique principles near the end. Any constraint that must be reliably followed appears in the first or last 20% of the prompt.
21
+
22
+ **Critical failure mode:** placing safety/scope constraints only in the middle of a long prompt.
23
+
24
+ ## Drift detection and self-check loops
25
+
26
+ - **ReAct + alignment verification** — extend Thought → Action → Observation with OBJECTIVE/PROGRESS/ALIGNMENT/SCOPE checks before each action. (ReAct outperformed pure CoT by 34% on ALFWorld.) *Failure mode:* context accumulation; mitigate with observation compaction, step limits, periodic goal re-injection.
27
+ - **OODA self-correction** — Observe/Orient/Decide/Act as a continuous self-monitoring loop after each major action.
28
+ - **Uncertainty/escalation prompts** — structured decision rules forcing stop-and-ask on: ambiguity, scope uncertainty, irreversibility, unexpected state, conflicting instructions, high stakes, confidence below threshold. Implements Anthropic's Minimal Footprint Principle.
29
+
30
+ ## Eval design — the most important shift
31
+
32
+ From **output correctness** ("is the answer right?") to **outcome achievement** ("did this help the user accomplish their goal?"). A value-focused eval scores 0–4 (DID NOT HELP → FULLY ENABLED) and requires a gap analysis: what would reach Level 4?
33
+
34
+ **Judges:**
35
+ - **LLM-as-judge** (Zheng et al., 2023) — ~80% agreement with humans, matching human-human. *Mandatory mitigations:* evaluate pairwise in both orders (position bias); instruct against verbosity bias; **never use the same model as both agent and judge** (self-enhancement bias up to 25%).
36
+ - **G-Eval** (Liu et al., 2023) — chain-of-thought form-filling; generates evaluation steps before scoring.
37
+
38
+ **Behavioral regression tests** detect when a model/prompt/context change breaks previously-passing behavior. Require a golden dataset with ≥30% "failure class" examples (inputs that should trigger escalation/refusal/scope denial) — happy-path-only suites cannot detect regression in failure handling.
39
+
40
+ ## Meta-prompting for goal fidelity
41
+
42
+ - **Reflexion** (Shinn et al., 2023) — verbal self-reflection in an episodic buffer, prepended to retries; 91% pass@1 on HumanEval vs. GPT-4's prior 80%.
43
+ - **Self-consistency** (Wang et al., 2023) — sample multiple reasoning paths, select the most goal-aligned; +17.9% on GSM8K.
44
+ - **Checkpoint output prompts** — force the agent to emit current goal/state/confidence before each major action (auditable record).
45
+ - **Meta-alignment prompts** — agent generates its own task-specific checklist before beginning.
46
+
47
+ ## The alignment trade-off
48
+
49
+ - **RLHF / Constitutional AI** — embeds constraints in weights; robust to drift/injection; expensive, can be gamed if reward model is imperfect.
50
+ - **Prompt-based** — flexible, interpretable; subject to drift, overridable.
51
+
52
+ Production uses both: RLHF/CAI for foundational constraints, prompt-based for task-specific scope. The Claude model specification (principal hierarchy: Anthropic → operators → users → agent; Minimal Footprint, corrigibility, consistency) is the current state of the art.
53
+
54
+ ## AUDIT checks
55
+
56
+ - [ ] Objective appears verbatim at top *and* bottom (Goal Sandwich); identical wording.
57
+ - [ ] Prohibited actions are explicit negations, not implicit.
58
+ - [ ] Minimal Footprint clause present.
59
+ - [ ] Escalation triggers are the 7 named types, not "when uncertain."
60
+ - [ ] Eval suite measures outcome achievement, not just output correctness.
61
+ - [ ] Golden dataset includes ≥30% failure-class examples.
62
+ - [ ] LLM-as-judge uses a *different* model than the evaluated agent.
63
+ - [ ] Behavioral regression tests run on every prompt/model change.
64
+
65
+ ## ESTABLISH (Day 3–4)
66
+
67
+ - Day 3 (2h): Implement Goal Sandwich + Scope Fence (≥5 prohibited) + Minimal Footprint + Escalation Triggers. This is the minimum viable goal-anchoring prompt.
68
+ - Day 4 (3h): Write 10 eval cases — 5 happy-path, 3 scope-boundary, 2 drift. Run manually; fix failures before deploy.