@event4u/agent-config 1.20.0 → 1.22.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.
- package/.agent-src/commands/agents.md +1 -1
- package/.agent-src/commands/bug-fix.md +2 -1
- package/.agent-src/commands/bug-investigate.md +3 -2
- package/.agent-src/commands/challenge-me/vision.md +348 -0
- package/.agent-src/commands/challenge-me/with-docs.md +333 -0
- package/.agent-src/commands/challenge-me.md +61 -0
- package/.agent-src/commands/chat-history/import.md +60 -64
- package/.agent-src/commands/compress.md +12 -0
- package/.agent-src/commands/context/create.md +2 -2
- package/.agent-src/commands/context.md +1 -1
- package/.agent-src/commands/copilot-agents.md +1 -1
- package/.agent-src/commands/council/default.md +69 -10
- package/.agent-src/commands/council.md +1 -1
- package/.agent-src/commands/create-pr.md +7 -3
- package/.agent-src/commands/e2e-heal.md +1 -1
- package/.agent-src/commands/e2e-plan.md +1 -1
- package/.agent-src/commands/feature/dev.md +3 -3
- package/.agent-src/commands/feature.md +1 -1
- package/.agent-src/commands/fix/seeder.md +2 -2
- package/.agent-src/commands/fix.md +1 -1
- package/.agent-src/commands/grill-me.md +38 -0
- package/.agent-src/commands/jira-ticket.md +1 -1
- package/.agent-src/commands/judge/steps.md +1 -1
- package/.agent-src/commands/judge.md +2 -2
- package/.agent-src/commands/memory.md +1 -1
- package/.agent-src/commands/mode.md +5 -5
- package/.agent-src/commands/module.md +1 -1
- package/.agent-src/commands/onboard.md +4 -4
- package/.agent-src/commands/optimize/augmentignore.md +1 -1
- package/.agent-src/commands/optimize-prompt.md +61 -0
- package/.agent-src/commands/optimize.md +1 -1
- package/.agent-src/commands/override.md +1 -1
- package/.agent-src/commands/review-changes.md +1 -1
- package/.agent-src/commands/review-routing.md +1 -1
- package/.agent-src/commands/roadmap/ai-council.md +183 -0
- package/.agent-src/commands/roadmap/create.md +6 -1
- package/.agent-src/commands/roadmap/process-full.md +58 -0
- package/.agent-src/commands/roadmap/process-phase.md +69 -0
- package/.agent-src/commands/roadmap/process-step.md +57 -0
- package/.agent-src/commands/roadmap.md +45 -17
- package/.agent-src/commands/set-cost-profile.md +3 -3
- package/.agent-src/commands/sync-agent-settings.md +2 -2
- package/.agent-src/commands/tests/create.md +2 -2
- package/.agent-src/commands/tests.md +1 -1
- package/.agent-src/commands/threat-model.md +5 -4
- package/.agent-src/contexts/augment-infrastructure.md +1 -1
- package/.agent-src/contexts/authority/commit-mechanics.md +14 -1
- package/.agent-src/contexts/authority/destructive-mechanics.md +14 -1
- package/.agent-src/contexts/authority/scope-mechanics.md +5 -0
- package/.agent-src/contexts/communication/rules-auto/guidelines-mechanics.md +76 -0
- package/.agent-src/contexts/communication/rules-auto/slash-command-routing-policy-mechanics.md +54 -19
- package/.agent-src/contexts/communication/rules-auto/think-before-action-mechanics.md +98 -0
- package/.agent-src/contexts/communication/rules-auto/token-efficiency-mechanics.md +93 -0
- package/.agent-src/contexts/communication/rules-auto/user-interaction-mechanics.md +128 -5
- package/.agent-src/contexts/execution/autonomy-mechanics.md +44 -0
- package/.agent-src/contexts/execution/roadmap-process-loop.md +125 -0
- package/.agent-src/contexts/model-recommendations.md +2 -2
- package/.agent-src/contexts/override-system.md +1 -1
- package/.agent-src/contexts/skills-and-commands.md +1 -1
- package/.agent-src/personas/product-owner.md +2 -2
- package/.agent-src/personas/qa.md +1 -1
- package/.agent-src/rules/agent-authority.md +5 -6
- package/.agent-src/rules/agent-docs.md +11 -53
- package/.agent-src/rules/analysis-skill-routing.md +10 -40
- package/.agent-src/rules/architecture.md +6 -1
- package/.agent-src/rules/artifact-drafting-protocol.md +5 -0
- package/.agent-src/rules/artifact-engagement-recording.md +23 -59
- package/.agent-src/rules/ask-when-uncertain.md +24 -47
- package/.agent-src/rules/augment-portability.md +14 -62
- package/.agent-src/rules/augment-source-of-truth.md +10 -1
- package/.agent-src/rules/autonomous-execution.md +17 -98
- package/.agent-src/rules/capture-learnings.md +9 -80
- package/.agent-src/rules/cli-output-handling.md +12 -42
- package/.agent-src/rules/command-suggestion-policy.md +25 -73
- package/.agent-src/rules/commit-conventions.md +9 -58
- package/.agent-src/rules/commit-policy.md +16 -47
- package/.agent-src/rules/context-hygiene.md +5 -0
- package/.agent-src/rules/direct-answers.md +21 -50
- package/.agent-src/rules/docker-commands.md +11 -45
- package/.agent-src/rules/docs-sync.md +10 -56
- package/.agent-src/rules/downstream-changes.md +5 -0
- package/.agent-src/rules/e2e-testing.md +9 -44
- package/.agent-src/rules/guidelines.md +13 -75
- package/.agent-src/rules/improve-before-implement.md +11 -2
- package/.agent-src/rules/invite-challenge.md +71 -0
- package/.agent-src/rules/language-and-tone.md +41 -106
- package/.agent-src/rules/laravel-translations.md +11 -40
- package/.agent-src/rules/markdown-safe-codeblocks.md +4 -0
- package/.agent-src/rules/minimal-safe-diff.md +4 -0
- package/.agent-src/rules/missing-tool-handling.md +4 -0
- package/.agent-src/rules/model-recommendation.md +9 -61
- package/.agent-src/rules/no-attribution-footers.md +5 -0
- package/.agent-src/rules/no-cheap-questions.md +11 -27
- package/.agent-src/rules/no-council-references.md +76 -0
- package/.agent-src/rules/no-roadmap-references.md +7 -0
- package/.agent-src/rules/non-destructive-by-default.md +13 -43
- package/.agent-src/rules/onboarding-gate.md +9 -117
- package/.agent-src/rules/package-ci-checks.md +10 -37
- package/.agent-src/rules/php-coding.md +10 -55
- package/.agent-src/rules/preservation-guard.md +9 -0
- package/.agent-src/rules/review-routing-awareness.md +9 -97
- package/.agent-src/rules/reviewer-awareness.md +8 -83
- package/.agent-src/rules/roadmap-progress-sync.md +7 -170
- package/.agent-src/rules/role-mode-adherence.md +6 -2
- package/.agent-src/rules/rule-type-governance.md +8 -66
- package/.agent-src/rules/runtime-safety.md +5 -0
- package/.agent-src/rules/scope-control.md +17 -62
- package/.agent-src/rules/security-sensitive-stop.md +7 -1
- package/.agent-src/rules/size-enforcement.md +6 -1
- package/.agent-src/rules/skill-improvement-trigger.md +9 -49
- package/.agent-src/rules/skill-quality.md +7 -113
- package/.agent-src/rules/slash-command-routing-policy.md +11 -63
- package/.agent-src/rules/think-before-action.md +22 -87
- package/.agent-src/rules/token-efficiency.md +10 -74
- package/.agent-src/rules/token-optimizer-maintenance.md +68 -0
- package/.agent-src/rules/tool-safety.md +4 -0
- package/.agent-src/rules/ui-audit-gate.md +25 -61
- package/.agent-src/rules/upstream-proposal.md +9 -67
- package/.agent-src/rules/user-interaction.md +22 -108
- package/.agent-src/rules/verify-before-complete.md +1 -1
- package/.agent-src/skills/adversarial-review/SKILL.md +1 -0
- package/.agent-src/skills/agent-docs-writing/SKILL.md +1 -1
- package/.agent-src/skills/ai-council/SKILL.md +197 -8
- package/.agent-src/skills/analysis-autonomous-mode/SKILL.md +1 -1
- package/.agent-src/skills/analysis-skill-router/SKILL.md +3 -3
- package/.agent-src/skills/artisan-commands/SKILL.md +2 -2
- package/.agent-src/skills/authz-review/SKILL.md +1 -1
- package/.agent-src/skills/aws-infrastructure/SKILL.md +5 -5
- package/.agent-src/skills/blast-radius-analyzer/SKILL.md +8 -8
- package/.agent-src/skills/bug-analyzer/SKILL.md +6 -5
- package/.agent-src/skills/code-refactoring/SKILL.md +4 -4
- package/.agent-src/skills/code-review/SKILL.md +2 -2
- package/.agent-src/skills/command-writing/SKILL.md +11 -0
- package/.agent-src/skills/composer-packages/SKILL.md +2 -2
- package/.agent-src/skills/context-authoring/SKILL.md +11 -0
- package/.agent-src/skills/context-document/SKILL.md +1 -1
- package/.agent-src/skills/copilot-agents-optimization/SKILL.md +23 -0
- package/.agent-src/skills/copilot-config/SKILL.md +1 -1
- package/.agent-src/skills/dependency-upgrade/SKILL.md +2 -2
- package/.agent-src/skills/devcontainer/SKILL.md +2 -2
- package/.agent-src/skills/developer-like-execution/SKILL.md +1 -1
- package/.agent-src/skills/docker/SKILL.md +1 -1
- package/.agent-src/skills/dto-creator/SKILL.md +1 -1
- package/.agent-src/skills/estimate-ticket/SKILL.md +2 -2
- package/.agent-src/skills/fe-design/SKILL.md +4 -4
- package/.agent-src/skills/feature-planning/SKILL.md +5 -5
- package/.agent-src/skills/funnel-analysis/SKILL.md +1 -1
- package/.agent-src/skills/laravel/SKILL.md +1 -1
- package/.agent-src/skills/laravel-notifications/SKILL.md +5 -5
- package/.agent-src/skills/laravel-pennant/SKILL.md +1 -1
- package/.agent-src/skills/laravel-pulse/SKILL.md +4 -4
- package/.agent-src/skills/laravel-reverb/SKILL.md +2 -2
- package/.agent-src/skills/laravel-scheduling/SKILL.md +1 -1
- package/.agent-src/skills/migration-creator/SKILL.md +7 -7
- package/.agent-src/skills/multi-tenancy/SKILL.md +8 -8
- package/.agent-src/skills/performance-analysis/SKILL.md +3 -3
- package/.agent-src/skills/pest-testing/SKILL.md +6 -6
- package/.agent-src/skills/php-service/SKILL.md +2 -2
- package/.agent-src/skills/project-analysis-hypothesis-driven/SKILL.md +3 -3
- package/.agent-src/skills/project-analysis-react/SKILL.md +1 -1
- package/.agent-src/skills/project-analysis-symfony/SKILL.md +1 -1
- package/.agent-src/skills/project-analysis-zend-laminas/SKILL.md +2 -2
- package/.agent-src/skills/project-analyzer/SKILL.md +4 -4
- package/.agent-src/skills/prompt-optimizer/SKILL.md +108 -0
- package/.agent-src/skills/readme-reviewer/SKILL.md +1 -1
- package/.agent-src/skills/roadmap-management/SKILL.md +7 -7
- package/.agent-src/skills/rule-writing/SKILL.md +33 -0
- package/.agent-src/skills/sentry-integration/SKILL.md +1 -1
- package/.agent-src/skills/skill-writing/SKILL.md +14 -0
- package/.agent-src/skills/systematic-debugging/SKILL.md +22 -2
- package/.agent-src/skills/technical-specification/SKILL.md +58 -1
- package/.agent-src/skills/terraform/SKILL.md +2 -2
- package/.agent-src/skills/terragrunt/SKILL.md +8 -8
- package/.agent-src/skills/test-performance/SKILL.md +5 -5
- package/.agent-src/skills/threat-modeling/SKILL.md +3 -2
- package/.agent-src/skills/token-optimizer/SKILL.md +110 -0
- package/.agent-src/skills/universal-project-analysis/SKILL.md +1 -1
- package/.agent-src/templates/AGENTS.md +1 -1
- package/.agent-src/templates/agent-settings.md +35 -19
- package/.agent-src/templates/command.md +17 -1
- package/.agent-src/templates/contexts/tenant-boundaries.md +2 -2
- package/.agent-src/templates/contexts.md +1 -1
- package/.agent-src/templates/copilot-instructions.md +21 -0
- package/.agent-src/templates/copilot-review-instructions.md +76 -0
- package/.agent-src/templates/features.md +1 -1
- package/.agent-src/templates/roadmaps.md +10 -2
- package/.agent-src/templates/rule.md +129 -0
- package/.agent-src/templates/skill.md +17 -0
- package/.claude-plugin/marketplace.json +12 -2
- package/AGENTS.md +32 -5
- package/CHANGELOG.md +107 -3
- package/README.md +22 -21
- package/config/agent-settings.template.yml +66 -10
- package/config/gitignore-block.txt +7 -0
- package/docs/architecture.md +86 -5
- package/docs/catalog.md +16 -6
- package/docs/contracts/agent-memory-contract.md +1 -1
- package/docs/contracts/command-clusters.md +45 -1
- package/docs/contracts/context-paths.md +2 -1
- package/docs/contracts/file-ownership-matrix.json +354 -500
- package/docs/contracts/iron-law-overrides.txt +25 -0
- package/docs/contracts/kernel-membership.md +273 -0
- package/docs/contracts/load-context-schema.md +26 -11
- package/docs/contracts/pilot/agent-authority.md +24 -0
- package/docs/contracts/pilot/direct-answers.md +70 -0
- package/docs/contracts/pilot/language-and-tone.md +63 -0
- package/docs/contracts/rule-classification.md +170 -0
- package/docs/contracts/rule-router.md +153 -0
- package/docs/customization.md +17 -6
- package/docs/decisions/ADR-001-kernel-swap-deferred.md +109 -0
- package/docs/decisions/ADR-002-kernel-bucket-overrides.md +124 -0
- package/docs/decisions/ADR-003-flat-cluster-subs-and-colon-syntax.md +126 -0
- package/docs/decisions/ADR-rule-kernel-and-router.md +122 -0
- package/docs/getting-started.md +2 -2
- package/docs/guidelines/agent-infra/naming.md +1 -1
- package/docs/guidelines/agent-infra/roadmap-progress-mechanics.md +176 -0
- package/docs/guidelines/agent-infra/rule-type-governance.md +73 -0
- package/docs/guidelines/agent-infra/size-and-scope.md +13 -2
- package/docs/guidelines/agent-infra/skill-quality-checklist.md +119 -0
- package/docs/guidelines/augment-portability-patterns.md +68 -0
- package/docs/guidelines/php/php-coding-patterns.md +62 -0
- package/package.json +1 -1
- package/scripts/_p43_bodies.py +235 -0
- package/scripts/_p43_compress.py +118 -0
- package/scripts/_p4_migrate.py +199 -0
- package/scripts/_phase2_shim_helper.py +1 -1
- package/scripts/_pilot_council_question.py +57 -0
- package/scripts/_pilot_measure.py +53 -0
- package/scripts/ai_council/session.py +107 -5
- package/scripts/build_linear_digest.py +3 -5
- package/scripts/check_always_budget.py +39 -6
- package/scripts/check_compressed_paths.py +213 -0
- package/scripts/check_compression.py +15 -0
- package/scripts/check_context_paths.py +1 -0
- package/scripts/check_council_layout.py +105 -0
- package/scripts/check_council_references.py +145 -0
- package/scripts/check_portability.py +2 -0
- package/scripts/check_references.py +2 -0
- package/scripts/check_token_optimizer_freshness.py +131 -0
- package/scripts/compile_router.py +148 -0
- package/scripts/compress.py +219 -11
- package/scripts/council_cli.py +132 -11
- package/scripts/council_prune.py +81 -0
- package/scripts/count_token_optimizer_usage.sh +54 -0
- package/scripts/install.sh +44 -2
- package/scripts/iron_law_sha.py +98 -0
- package/scripts/lint_load_context.py +35 -5
- package/scripts/measure_rule_budget.py +314 -0
- package/scripts/migrate_command_suggestions.py +2 -2
- package/scripts/prototype_lint_contradictions.py +150 -0
- package/scripts/schemas/command.schema.json +5 -0
- package/scripts/schemas/rule.schema.json +60 -6
- package/scripts/schemas/skill.schema.json +5 -0
- package/scripts/skill_linter.py +197 -7
- package/scripts/smoke_path_resolution.py +93 -0
- package/scripts/validate_frontmatter.py +41 -1
- package/.agent-src/commands/roadmap/execute.md +0 -109
- package/.agent-src/contexts/communication/rules-auto/artifact-engagement-recording-mechanics.md +0 -72
- package/.agent-src/contexts/communication/rules-auto/augment-portability-mechanics.md +0 -79
- package/.agent-src/contexts/communication/rules-auto/cli-output-handling-mechanics.md +0 -87
- package/.agent-src/contexts/communication/rules-auto/command-suggestion-policy-mechanics.md +0 -62
- package/.agent-src/contexts/communication/rules-auto/docs-sync-mechanics.md +0 -78
- package/.agent-src/contexts/communication/rules-auto/package-ci-checks-mechanics.md +0 -85
- package/.agent-src/contexts/communication/rules-auto/review-routing-awareness-mechanics.md +0 -65
- package/.agent-src/contexts/communication/rules-auto/roadmap-progress-sync-mechanics.md +0 -78
- package/.agent-src/contexts/communication/rules-auto/ui-audit-gate-mechanics.md +0 -53
- /package/{docs → .agent-src/contexts}/contracts/artifact-engagement-flow.md +0 -0
- /package/{docs → .agent-src/contexts}/contracts/command-suggestion-flow.md +0 -0
|
@@ -0,0 +1,333 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: challenge-me:with-docs
|
|
3
|
+
cluster: challenge-me
|
|
4
|
+
sub: with-docs
|
|
5
|
+
description: "Doc-aware /challenge-me — 95%-confidence interview with session glossary vs CONTEXT.md, load-bearing claim-vs-code verification, optional CONTEXT.md patch + ADR candidates in the pitch."
|
|
6
|
+
disable-model-invocation: true
|
|
7
|
+
suggestion:
|
|
8
|
+
eligible: true
|
|
9
|
+
trigger_description: "challenge me against the docs, grill me with our context, grill me against the docs, grill me against CONTEXT.md, grill me with the project context, frag mich durch und prüf gegen CONTEXT.md, challenge plan with domain docs"
|
|
10
|
+
trigger_context: "user wants the seed challenged against existing project glossary, CONTEXT.md, or ADRs — not a greenfield interview"
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
# /challenge-me with-docs
|
|
14
|
+
|
|
15
|
+
> Same one-question-at-a-time interview as `/challenge-me vision`, plus:
|
|
16
|
+
> a **session glossary** against `CONTEXT.md`, **load-bearing claim-vs-code
|
|
17
|
+
> verification**, and an optional `CONTEXT.md` **patch** + **ADR candidates**
|
|
18
|
+
> appended to the final pitch. Nothing is written to disk — the pitch is
|
|
19
|
+
> the only artefact.
|
|
20
|
+
|
|
21
|
+
## Welcome
|
|
22
|
+
|
|
23
|
+
If the user invokes `/challenge-me with-docs` with no body, render once:
|
|
24
|
+
|
|
25
|
+
```
|
|
26
|
+
Drop the seed and I'll grill it against your project docs. Per turn:
|
|
27
|
+
one question, recommended answer. I'll surface glossary clashes vs
|
|
28
|
+
CONTEXT.md and verify load-bearing claims against the code. At the end
|
|
29
|
+
you get a pitch — plus an optional CONTEXT.md patch and ADR candidates
|
|
30
|
+
to copy / apply yourself.
|
|
31
|
+
|
|
32
|
+
Stop early any time by typing `!pitch` (or `!Vision pitchen`).
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
Skip the welcome if the user invokes `/challenge-me with-docs <seed>`
|
|
36
|
+
directly.
|
|
37
|
+
|
|
38
|
+
## When to use this instead of `vision`
|
|
39
|
+
|
|
40
|
+
| Condition | Pick |
|
|
41
|
+
|---|---|
|
|
42
|
+
| Project has no `CONTEXT.md` and no ADR dir | `vision` |
|
|
43
|
+
| Seed uses domain terms that may already be defined elsewhere | `with-docs` |
|
|
44
|
+
| User says "check against our docs" / "make sure it matches CONTEXT.md" | `with-docs` |
|
|
45
|
+
| User says "make sure this is consistent with the codebase" | `with-docs` |
|
|
46
|
+
| Greenfield brainstorm, no existing constraints to honour | `vision` |
|
|
47
|
+
|
|
48
|
+
If neither file exists and the user invoked `with-docs` anyway, fall
|
|
49
|
+
back gracefully to `vision`-style flow and skip the doc inventory; note
|
|
50
|
+
the absence in a single line at the end of Step 0.
|
|
51
|
+
|
|
52
|
+
## Stop condition, flags, pitch trigger
|
|
53
|
+
|
|
54
|
+
Inherits **verbatim** from [`vision.md`](vision.md):
|
|
55
|
+
|
|
56
|
+
- Default stop = the four 95%-conditions (AND, not OR).
|
|
57
|
+
- Load-bearing test = answer changes goal / scope / hard constraint / AC.
|
|
58
|
+
- `--until=95%` (default) · `--until=N` · `--keep-going`.
|
|
59
|
+
- Pitch trigger: `!pitch`, `/pitch`, or whole reply `pitch`.
|
|
60
|
+
- Step 1 question-block shape, Step 4 pitch validation.
|
|
61
|
+
|
|
62
|
+
The deltas below replace / extend Step 0, Step 1, Step 2, Step 4 and
|
|
63
|
+
Step 5. Steps 3 and 6 are unchanged.
|
|
64
|
+
|
|
65
|
+
## Steps
|
|
66
|
+
|
|
67
|
+
### Step 0 — Inspect (read-only doc inventory + codebase)
|
|
68
|
+
|
|
69
|
+
```
|
|
70
|
+
EXPLORE THE DOCS AND THE CODEBASE BEFORE THE FIRST QUESTION.
|
|
71
|
+
NEVER WRITE TO DISK IN STEP 0. NEVER ASK WHAT view / grep / codebase-retrieval ANSWERS.
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
1. **Read the seed** (same as `vision`).
|
|
75
|
+
2. **Doc inventory** — read-only:
|
|
76
|
+
- `view CONTEXT.md` if it exists; init empty **session glossary** in
|
|
77
|
+
agent state (in-memory only).
|
|
78
|
+
- `view CONTEXT-MAP.md` if it exists. If the seed touches > 1 listed
|
|
79
|
+
context, **ask once** (numbered options listing each context) which
|
|
80
|
+
to focus on; record the choice, do not re-ask.
|
|
81
|
+
- Autodetect ADR directory by listing `docs/adr/`, `docs/decisions/`,
|
|
82
|
+
`docs/architecture/decisions/`, `agents/decisions/`. Pick the
|
|
83
|
+
**most-recently-modified** non-empty dir; if none exist, default to
|
|
84
|
+
`docs/adr/` for the patch output (do **not** create the dir).
|
|
85
|
+
- If `agent state` already holds a session glossary from a prior
|
|
86
|
+
`/challenge-me with-docs` invocation **in this same chat**, load
|
|
87
|
+
it. Then re-read `CONTEXT.md` — any term in `CONTEXT.md` overrides
|
|
88
|
+
the session glossary (disk wins over draft). Emit a delta line if
|
|
89
|
+
non-zero: `Loaded N draft terms; CONTEXT.md already has X — carrying
|
|
90
|
+
forward the rest as drafts.`
|
|
91
|
+
3. **Codebase lookup** — same as `vision` Step 0.2 (existing routes,
|
|
92
|
+
model fields, conventions, feature flags).
|
|
93
|
+
4. **List the open dimensions** internally — same as `vision` Step 0.3.
|
|
94
|
+
|
|
95
|
+
### Step 1 — Glossary-aware questioning
|
|
96
|
+
|
|
97
|
+
Every question block runs an extra check **before** emit:
|
|
98
|
+
|
|
99
|
+
- **Glossary conflict** — does the seed (or a prior turn) use a term
|
|
100
|
+
that conflicts with the existing `CONTEXT.md` glossary, including a
|
|
101
|
+
case-insensitive match? → first question of the session is the
|
|
102
|
+
glossary disambiguation:
|
|
103
|
+
|
|
104
|
+
> Your `CONTEXT.md` defines **Account** as the billing entity. Your
|
|
105
|
+
> seed uses "account" for the logged-in person. Which is it?
|
|
106
|
+
> 1. **Match CONTEXT.md** — rename "account" in the plan to "user".
|
|
107
|
+
> 2. Override CONTEXT.md — the plan introduces a new meaning; we patch
|
|
108
|
+
> the glossary at pitch time.
|
|
109
|
+
> 3. Skip / not relevant.
|
|
110
|
+
|
|
111
|
+
- **Fuzzy / overloaded term** — propose a canonical term as option 1.
|
|
112
|
+
|
|
113
|
+
- **No glossary present** → skip the check; behave like `vision`.
|
|
114
|
+
|
|
115
|
+
The glossary check is itself **load-bearing only when the term flips an
|
|
116
|
+
AC or scope boundary OR when it conflicts with an existing CONTEXT.md
|
|
117
|
+
entry**. Pure naming preference with no conflict is closed silently
|
|
118
|
+
(same load-bearing test as `vision`, with the conflict-extension).
|
|
119
|
+
|
|
120
|
+
Otherwise the question-block shape, recommended-option rule, 3–4 option
|
|
121
|
+
cap, and `Why it matters` requirement are identical to
|
|
122
|
+
[`vision.md § Step 1`](vision.md#step-1-ask-one-question-per-turn).
|
|
123
|
+
|
|
124
|
+
### Step 2 — Apply the answer + session glossary (in-memory)
|
|
125
|
+
|
|
126
|
+
Adopt-the-answer rules are identical to
|
|
127
|
+
[`vision.md § Step 2`](vision.md#step-2-apply-the-answer).
|
|
128
|
+
|
|
129
|
+
When a term is resolved, write to **session glossary** (agent state
|
|
130
|
+
only). **Never write to disk in this step.** Every turn's reply ends
|
|
131
|
+
with a compact echo block when the glossary is non-empty:
|
|
132
|
+
|
|
133
|
+
```
|
|
134
|
+
**Session glossary (draft, not yet written):**
|
|
135
|
+
- **Cancellation** — refund + reversal, excludes disputes (turn 3)
|
|
136
|
+
- **Account** — maps to `User` entity (turn 5)
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
After the **fifth** session-glossary turn, condense the echo to:
|
|
140
|
+
|
|
141
|
+
```
|
|
142
|
+
**Session glossary (draft):** N terms · M ADR candidates — see pitch for full list.
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
If the session glossary is empty, omit the echo block entirely.
|
|
146
|
+
|
|
147
|
+
### Step 3 — Re-score and continue
|
|
148
|
+
|
|
149
|
+
Identical to [`vision.md § Step 3`](vision.md#step-3-re-score-and-continue).
|
|
150
|
+
|
|
151
|
+
### Step 3.5 — ADR candidate check (no write)
|
|
152
|
+
|
|
153
|
+
After each branch closes, run the three-test on the resolution:
|
|
154
|
+
|
|
155
|
+
1. **Hard-to-reverse** — would unwinding it require code or schema rollback?
|
|
156
|
+
2. **Surprising-without-context** — would a future contributor read the
|
|
157
|
+
choice and ask "why this and not the obvious alternative?"
|
|
158
|
+
3. **Result of a real trade-off** — were the rejected options realistic?
|
|
159
|
+
|
|
160
|
+
If **all three** pass, append the candidate to an in-memory ADR-candidate
|
|
161
|
+
list. Do **not** ask, do **not** write. Surfaces only in Step 5.
|
|
162
|
+
|
|
163
|
+
### Step 4 — Validate before pitching
|
|
164
|
+
|
|
165
|
+
Identical to [`vision.md § Step 4`](vision.md#step-4-validate-before-pitching),
|
|
166
|
+
plus:
|
|
167
|
+
|
|
168
|
+
- Pitch uses the **canonical glossary spelling** for every term in the
|
|
169
|
+
session glossary.
|
|
170
|
+
- The `CONTEXT.md` patch block is **always** appended when the session
|
|
171
|
+
glossary is non-empty — agent has no signal whether the user already
|
|
172
|
+
applied a previous patch in-chat. The patch block carries a header
|
|
173
|
+
the user reads before applying (see Step 5).
|
|
174
|
+
|
|
175
|
+
### Step 5 — Emit the pitch with optional doc patches
|
|
176
|
+
|
|
177
|
+
Emit the same fenced Markdown pitch as `vision`, then append up to two
|
|
178
|
+
optional sections **inside** the same outer four-backtick fence:
|
|
179
|
+
|
|
180
|
+
`````markdown
|
|
181
|
+
````markdown
|
|
182
|
+
# <one-line vision title>
|
|
183
|
+
|
|
184
|
+
**Goal:** <verb + object + observable result>
|
|
185
|
+
|
|
186
|
+
**In scope:**
|
|
187
|
+
- <bullet>
|
|
188
|
+
|
|
189
|
+
**Out of scope:**
|
|
190
|
+
- <bullet>
|
|
191
|
+
|
|
192
|
+
**Constraints (hard):**
|
|
193
|
+
- <bullet>
|
|
194
|
+
|
|
195
|
+
**Acceptance criteria:**
|
|
196
|
+
1. <observable, testable>
|
|
197
|
+
|
|
198
|
+
**Open assumptions:**
|
|
199
|
+
- assumes: <line>
|
|
200
|
+
|
|
201
|
+
**Recommended next step:** <one sentence — e.g. "/work \"<pitch goal>\"" >.
|
|
202
|
+
|
|
203
|
+
---
|
|
204
|
+
|
|
205
|
+
**CONTEXT.md patch (apply via `patch -p1` or your IDE's Apply Patch — only
|
|
206
|
+
if you haven't already merged these terms):**
|
|
207
|
+
|
|
208
|
+
```diff
|
|
209
|
+
@@ ... @@
|
|
210
|
+
+ ## Cancellation
|
|
211
|
+
+ Refund + reversal, excludes disputes.
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
**ADR candidate(s) — apply only if useful:**
|
|
215
|
+
- `docs/adr/0007-cancellation-semantics.md` — captures the soft-vs-hard
|
|
216
|
+
delete decision (hard-to-reverse · surprising · real-tradeoff).
|
|
217
|
+
|
|
218
|
+
**Glossary touched this session:** Cancellation, Account, Refund (3 terms).
|
|
219
|
+
````
|
|
220
|
+
`````
|
|
221
|
+
|
|
222
|
+
The outer fence uses **five backticks** so the inner four-backtick fence
|
|
223
|
+
(which itself contains a triple-backtick diff) stays literal when the
|
|
224
|
+
user copies the whole block.
|
|
225
|
+
|
|
226
|
+
Omission rules:
|
|
227
|
+
|
|
228
|
+
- Session glossary empty → omit the `CONTEXT.md patch`, `Glossary touched`,
|
|
229
|
+
and the preceding `---` separator entirely.
|
|
230
|
+
- No ADR candidate qualified → omit the `ADR candidate(s)` section.
|
|
231
|
+
- Both empty → pitch is identical to a `vision` pitch.
|
|
232
|
+
|
|
233
|
+
### Step 6 — Hand back
|
|
234
|
+
|
|
235
|
+
Identical to [`vision.md § Step 6`](vision.md#step-6-hand-back). Never
|
|
236
|
+
auto-write the patches, never auto-invoke `/work`.
|
|
237
|
+
|
|
238
|
+
## Code-vs-claim guard (gated)
|
|
239
|
+
|
|
240
|
+
When the user states "X is implemented as Y" AND the claim is
|
|
241
|
+
**load-bearing** (would change an AC, scope boundary, or hard
|
|
242
|
+
constraint), agent runs `view` / `grep` / `codebase-retrieval` to
|
|
243
|
+
verify. Mismatch → single question block:
|
|
244
|
+
|
|
245
|
+
> Your seed says X works via Y. The code (`path/to/file.php:123`) shows
|
|
246
|
+
> it via Z. Which is right?
|
|
247
|
+
> 1. **Code is right, my seed was wrong** — recommended.
|
|
248
|
+
> 2. Seed is right, code is stale — separate fix needed.
|
|
249
|
+
> 3. Both — they're both real paths.
|
|
250
|
+
|
|
251
|
+
Non-load-bearing claims (cosmetic, naming, internal style) — agent
|
|
252
|
+
trusts the user's statement, no lookup. This gate keeps verification
|
|
253
|
+
cost O(load-bearing-decisions), not O(every-statement).
|
|
254
|
+
|
|
255
|
+
## Output format
|
|
256
|
+
|
|
257
|
+
1. **Per-turn question block** — one numbered question with a
|
|
258
|
+
recommended option, until 95% or pitch trigger.
|
|
259
|
+
2. **Session-glossary echo** — appended every turn while the glossary is
|
|
260
|
+
non-empty (full list in turns 1–5, condensed line from turn 6 on).
|
|
261
|
+
3. **Final pitch** — a single copyable five-backtick fenced block
|
|
262
|
+
(Step 5 shape) holding the standard pitch + optional `CONTEXT.md`
|
|
263
|
+
patch + optional ADR candidates.
|
|
264
|
+
|
|
265
|
+
## Examples
|
|
266
|
+
|
|
267
|
+
```
|
|
268
|
+
/challenge-me with-docs
|
|
269
|
+
/challenge-me with-docs Add a per-tenant rate limit on the public API
|
|
270
|
+
/challenge-me with-docs --until=5 Migrate cancellations from soft-delete to hard-delete
|
|
271
|
+
/challenge-me with-docs --keep-going Re-architect the notifications pipeline
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
## Gotchas
|
|
275
|
+
|
|
276
|
+
- Inherits every gotcha from
|
|
277
|
+
[`vision.md § Gotchas`](vision.md#gotchas) — confidence inflation,
|
|
278
|
+
recommendation drift, stacked questions, too many options.
|
|
279
|
+
- **Glossary clutter** — if the agent echoes the full session glossary
|
|
280
|
+
past turn 5 the reply gets noisy. Condense per Step 2.
|
|
281
|
+
- **Patch redundancy** — agent has no signal whether the user already
|
|
282
|
+
applied a previous in-chat `CONTEXT.md` patch. Always emit the patch
|
|
283
|
+
with the "only if you haven't already merged these terms" header so
|
|
284
|
+
the user can dedupe.
|
|
285
|
+
- **ADR over-eager** — the three-test (hard-to-reverse · surprising ·
|
|
286
|
+
real-tradeoff) is the gate. A pure naming choice or a default that
|
|
287
|
+
could flip without rollback is **not** an ADR candidate.
|
|
288
|
+
- **Multi-context confusion** — if `CONTEXT-MAP.md` lists multiple
|
|
289
|
+
contexts and the seed touches several, ask **once** in Step 0; never
|
|
290
|
+
re-ask which context to focus on.
|
|
291
|
+
|
|
292
|
+
## Rules
|
|
293
|
+
|
|
294
|
+
- Inherits every rule from [`vision.md § Rules`](vision.md#rules) —
|
|
295
|
+
one question per turn, no auto-execution, no file writes, codebase
|
|
296
|
+
first, welcome once, mirror the user's language.
|
|
297
|
+
- **No file writes** — even though this variant produces glossary
|
|
298
|
+
patches and ADR candidates, those go **into the pitch block** for the
|
|
299
|
+
user to apply. Agent never writes `CONTEXT.md` or any `docs/adr/*`
|
|
300
|
+
file itself, per `non-destructive-by-default`.
|
|
301
|
+
- **Two-gate verification** — the glossary check fires on AC-flipping
|
|
302
|
+
terms OR `CONTEXT.md` conflicts; the code-vs-claim check fires only
|
|
303
|
+
on load-bearing claims. Non-load-bearing trivia → no lookup, no
|
|
304
|
+
question.
|
|
305
|
+
- **Session glossary persists within a chat** — a second
|
|
306
|
+
`/challenge-me with-docs` invocation in the same chat inherits draft
|
|
307
|
+
terms; disk state (`CONTEXT.md`) overrides drafts on every Step 0.
|
|
308
|
+
|
|
309
|
+
## Do NOT
|
|
310
|
+
|
|
311
|
+
- Inherits every prohibition from
|
|
312
|
+
[`vision.md § Do NOT`](vision.md#do-not).
|
|
313
|
+
- Do NOT write to `CONTEXT.md` directly — emit the diff in the pitch.
|
|
314
|
+
- Do NOT create files in `docs/adr/` — emit the path + rationale in the
|
|
315
|
+
pitch and let the user create the file.
|
|
316
|
+
- Do NOT verify every user statement — only load-bearing claims trigger
|
|
317
|
+
the code-vs-claim guard.
|
|
318
|
+
- Do NOT echo the full session glossary past turn 5 — condense.
|
|
319
|
+
|
|
320
|
+
## See also
|
|
321
|
+
|
|
322
|
+
- [`/challenge-me vision`](vision.md) — sibling without doc inventory,
|
|
323
|
+
glossary check, or claim verification.
|
|
324
|
+
- [`/refine-prompt`](../refine-prompt.md) — one-shot prompt scoring.
|
|
325
|
+
- [`/refine-ticket`](../refine-ticket.md) — ticket reconstruction.
|
|
326
|
+
- [`ask-when-uncertain`](../../rules/ask-when-uncertain.md) — the
|
|
327
|
+
one-question-per-turn Iron Law.
|
|
328
|
+
- [`non-destructive-by-default`](../../rules/non-destructive-by-default.md)
|
|
329
|
+
— why the patches live in the pitch block, not on disk.
|
|
330
|
+
- Inspiration: `mattpocock/skills/skills/engineering/grill-with-docs/SKILL.md`
|
|
331
|
+
— same intent (interview against domain docs), restructured to honour
|
|
332
|
+
the project's non-destructive floor (session glossary in-memory,
|
|
333
|
+
patches emitted as copyable diffs in the pitch).
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: challenge-me
|
|
3
|
+
description: Challenge-me orchestrator — routes to vision, with-docs
|
|
4
|
+
cluster: challenge-me
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
suggestion:
|
|
7
|
+
eligible: true
|
|
8
|
+
trigger_description: "challenge me on this plan, grill me, grill me on this, grill me on this plan, grill me through this, grill me until it's clear, grill me hard, frag mich durch, dreh mich durch die Mangel, challenge against existing docs/glossary"
|
|
9
|
+
trigger_context: "user has a fuzzy plan/idea/feature draft and wants it sharpened interactively rather than reconstructed in one shot — also reachable via /grill-me alias"
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
# /challenge-me
|
|
13
|
+
|
|
14
|
+
Top-level orchestrator for the `/challenge-me` family. Walks a decision
|
|
15
|
+
tree by asking one question at a time until the agent is confident
|
|
16
|
+
enough to emit a copyable Markdown pitch.
|
|
17
|
+
|
|
18
|
+
> Also reachable as [`/grill-me`](grill-me.md) — thin alias, identical
|
|
19
|
+
> behaviour, identical sub-commands and triggers.
|
|
20
|
+
|
|
21
|
+
## Sub-commands
|
|
22
|
+
|
|
23
|
+
| Sub-command | Routes to | Purpose |
|
|
24
|
+
|---|---|---|
|
|
25
|
+
| `/challenge-me vision` | `commands/challenge-me/vision.md` | Standard variant — interrogate a fuzzy plan / idea / ticket draft to 95% confidence, emit a vision pitch |
|
|
26
|
+
| `/challenge-me with-docs` | `commands/challenge-me/with-docs.md` | Doc-aware variant — same flow plus session glossary against `CONTEXT.md`, load-bearing claim-vs-code verification, optional `CONTEXT.md` patch + ADR candidates in the pitch |
|
|
27
|
+
|
|
28
|
+
## When to pick which
|
|
29
|
+
|
|
30
|
+
- **`vision`** — greenfield idea, fresh ticket draft, or a plan with no
|
|
31
|
+
existing project glossary / domain docs. Default for "challenge me on
|
|
32
|
+
this plan".
|
|
33
|
+
- **`with-docs`** — the project has `CONTEXT.md`, an ADR directory
|
|
34
|
+
(`docs/adr/`, `docs/decisions/`, `agents/decisions/`), or the user
|
|
35
|
+
uses domain terms that may already be defined. The variant catches
|
|
36
|
+
glossary conflicts and load-bearing claim-vs-code drift before pitch.
|
|
37
|
+
|
|
38
|
+
## Dispatch
|
|
39
|
+
|
|
40
|
+
1. Parse the user's argument: `/challenge-me <sub-command> [flags] [seed]`.
|
|
41
|
+
2. Look up the sub-command in the table above.
|
|
42
|
+
3. Load the body of the routed file and follow its `## Steps` section
|
|
43
|
+
verbatim with the remaining flags / seed.
|
|
44
|
+
4. If the sub-command is unknown or missing, print the menu and ask:
|
|
45
|
+
|
|
46
|
+
> 1. vision — standard 95%-confidence interview, emits a copyable pitch
|
|
47
|
+
> 2. with-docs — same flow, but checks the seed against `CONTEXT.md` /
|
|
48
|
+
> ADRs and emits an optional doc patch in the pitch
|
|
49
|
+
|
|
50
|
+
## Rules
|
|
51
|
+
|
|
52
|
+
- **Do NOT chain sub-commands.** One `/challenge-me <sub>` per turn.
|
|
53
|
+
- If the user invokes `/challenge-me` with no argument, **show the menu**
|
|
54
|
+
— do not guess which sub-command they meant.
|
|
55
|
+
- **No file writes from either sub-command.** Both variants are
|
|
56
|
+
conversational; the pitch is the only artefact, and it is copyable
|
|
57
|
+
Markdown the user pastes elsewhere. `with-docs` emits its `CONTEXT.md`
|
|
58
|
+
patch and ADR candidates inside the same pitch block — agent does not
|
|
59
|
+
apply them itself.
|
|
60
|
+
- **Mirror the user's language** — sub-commands inherit the
|
|
61
|
+
`language-and-tone` Iron Law for question blocks and pitch.
|
|
@@ -2,31 +2,30 @@
|
|
|
2
2
|
name: chat-history:import
|
|
3
3
|
cluster: chat-history
|
|
4
4
|
sub: import
|
|
5
|
-
description: Surface prior chat-history sessions as numbered
|
|
5
|
+
description: Surface prior chat-history sessions as a numbered table, let the user pick one, read it silently, and emit a short summary plus a resume offer — selective, user-driven cross-session import
|
|
6
6
|
disable-model-invocation: true
|
|
7
7
|
suggestion:
|
|
8
8
|
eligible: true
|
|
9
9
|
trigger_description: "import a past session into the current chat, pull a prior session into context, pick a session to read"
|
|
10
|
-
trigger_context: "user wants to selectively pull
|
|
10
|
+
trigger_context: "user wants to selectively pull a prior session's context into the current one as a short summary"
|
|
11
11
|
---
|
|
12
12
|
<!-- cloud_safe: noop -->
|
|
13
13
|
|
|
14
14
|
# /chat-history import
|
|
15
15
|
|
|
16
16
|
Read-only, **user-driven** cross-session import. Surfaces prior
|
|
17
|
-
sessions logged in `agents/.agent-chat-history` as numbered
|
|
18
|
-
user picks **one**, the agent reads that session
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
contract).
|
|
17
|
+
sessions logged in `agents/.agent-chat-history` as a numbered table,
|
|
18
|
+
the user picks **one**, the agent reads that session **silently**
|
|
19
|
+
and emits a 2–5 sentence summary, then offers to resume the last
|
|
20
|
+
task from that session. The agent does **not** render entries
|
|
21
|
+
verbatim, auto-import, or rewrite the user's context without an
|
|
22
|
+
explicit instruction.
|
|
24
23
|
|
|
25
24
|
This is the opt-in counterpart to the read-path filter (Phase 3 of
|
|
26
25
|
`road-to-chat-history-session-isolation`): default reads stay
|
|
27
26
|
session-scoped; `import` is the explicit surface for crossing the
|
|
28
|
-
session boundary
|
|
29
|
-
|
|
27
|
+
session boundary. For project-improving learnings derived from a
|
|
28
|
+
prior session, see [`/chat-history learn`](learn.md).
|
|
30
29
|
|
|
31
30
|
## When NOT to use
|
|
32
31
|
|
|
@@ -70,33 +69,35 @@ If the array is empty, stop:
|
|
|
70
69
|
> 📒 No prior sessions found in agents/.agent-chat-history.
|
|
71
70
|
```
|
|
72
71
|
|
|
73
|
-
### 3. Surface as numbered
|
|
72
|
+
### 3. Surface as a numbered table
|
|
74
73
|
|
|
75
|
-
Render
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
`(N entries — no user prompts; t-mix: …)` for tool-only sessions).
|
|
80
|
-
The session `id` is noise to humans; keep it **internal** for step
|
|
81
|
-
5's `read --session <id>` call and never render it in the listing.
|
|
74
|
+
Render the sessions as a markdown table — the row number is the
|
|
75
|
+
option (per `user-interaction` Iron Law: numbered options for any
|
|
76
|
+
picker). The session `id` is noise to humans; keep it **internal**
|
|
77
|
+
for step 5's `read --session <id>` call and never render it.
|
|
82
78
|
Format:
|
|
83
79
|
|
|
84
80
|
```
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
81
|
+
Pick a session to import:
|
|
82
|
+
|
|
83
|
+
| # | Date | Entries | Summary |
|
|
84
|
+
|----|------------------|---------|---------|
|
|
85
|
+
| 1 | YYYY-MM-DD HH:MM | N | {summary} |
|
|
86
|
+
| 2 | YYYY-MM-DD HH:MM | N | {summary} |
|
|
87
|
+
| … | | | |
|
|
88
|
+
| N | — | — | abort — do not read any session |
|
|
92
89
|
```
|
|
93
90
|
|
|
94
91
|
Format the timestamp as `YYYY-MM-DD HH:MM` (drop seconds and
|
|
95
|
-
timezone — the listing is for orientation, not forensics).
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
92
|
+
timezone — the listing is for orientation, not forensics). Lead the
|
|
93
|
+
`Summary` cell with the helper's `summary` field — that is the
|
|
94
|
+
rough arc the user picks by (`<first user msg> → <last user msg>`
|
|
95
|
+
for normal sessions, or `(N entries — no user prompts; t-mix: …)`
|
|
96
|
+
for tool-only sessions). Do **not** truncate or rewrite `summary` —
|
|
97
|
+
markdown table wrap handles long values. Always include an explicit
|
|
98
|
+
`abort` row as the last numbered option. Track option-number → `id`
|
|
99
|
+
internally so step 5 can call `scripts/chat_history.py read
|
|
100
|
+
--session <id>` with the right id.
|
|
100
101
|
|
|
101
102
|
### 4. Wait for the pick
|
|
102
103
|
|
|
@@ -106,51 +107,46 @@ default. Wait for the user's response.
|
|
|
106
107
|
|
|
107
108
|
If the user picks the abort option, stop without reading.
|
|
108
109
|
|
|
109
|
-
### 5. Read the picked session
|
|
110
|
+
### 5. Read the picked session silently
|
|
110
111
|
|
|
111
|
-
Run `scripts/chat_history.py read --session <id
|
|
112
|
-
|
|
112
|
+
Run `scripts/chat_history.py read --session <id> --last <count>`,
|
|
113
|
+
where `<count>` is the picked row's `count` from step 2. The
|
|
114
|
+
`--last` flag is **required** — the helper defaults to 5 entries,
|
|
115
|
+
which would silently truncate any longer session. The helper returns
|
|
116
|
+
the entries as JSON.
|
|
113
117
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
emits. Use a fenced block so timestamps and JSON survive markdown
|
|
118
|
-
rendering:
|
|
118
|
+
**Do not render the entries.** The verbose dump was reversed by the
|
|
119
|
+
user — token cost and scroll fatigue outweighed the verbatim
|
|
120
|
+
contract. Read the JSON in-context, then proceed to step 6.
|
|
119
121
|
|
|
120
|
-
|
|
121
|
-
> 📒 Session {id} — {count} entries
|
|
122
|
+
### 6. Summarise and offer to resume
|
|
122
123
|
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
```
|
|
128
|
-
````
|
|
129
|
-
|
|
130
|
-
If the session is large (>50 entries), still render verbatim — but
|
|
131
|
-
prepend a one-line note that the listing is long, so the user can
|
|
132
|
-
scroll. Do not silently truncate.
|
|
133
|
-
|
|
134
|
-
### 6. Hand back
|
|
124
|
+
Emit a **2–5 sentence** summary of the picked session: the topic,
|
|
125
|
+
what was decided or built, and where it left off (the last task in
|
|
126
|
+
progress, if any). Plain prose — no bullets, no headings, no
|
|
127
|
+
verbatim quotes.
|
|
135
128
|
|
|
136
|
-
|
|
137
|
-
|
|
129
|
+
Then offer the resume choice as numbered options
|
|
130
|
+
(per `user-interaction`), one question per turn:
|
|
138
131
|
|
|
139
132
|
```
|
|
140
|
-
|
|
133
|
+
1. resume — pick up the last task from that session
|
|
134
|
+
2. stop — keep the summary in context, do nothing else
|
|
141
135
|
```
|
|
142
136
|
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
behalf without an explicit
|
|
137
|
+
Wait for the pick. Do **not** auto-resume. If the user picks
|
|
138
|
+
`resume`, hand off to the relevant skill or command for that work;
|
|
139
|
+
do not silently start editing files. The agent does not write to
|
|
140
|
+
the current session's log on the user's behalf without an explicit
|
|
141
|
+
instruction.
|
|
147
142
|
|
|
148
143
|
## Gotchas
|
|
149
144
|
|
|
150
|
-
- **
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
145
|
+
- **Summary, not verbatim.** Earlier Council R2-2 favoured verbatim
|
|
146
|
+
rendering; reversed in practice — too slow, too token-expensive.
|
|
147
|
+
The agent reads the picked session in-context and emits a 2–5
|
|
148
|
+
sentence summary. Verbatim rendering is no longer part of the
|
|
149
|
+
contract.
|
|
154
150
|
- **One pick per invocation.** Multi-pick is v2. If the user wants
|
|
155
151
|
a second session, run `/chat-history import` again.
|
|
156
152
|
- **Read-only.** This command never writes to `agents/.agent-chat-history`
|
|
@@ -50,6 +50,18 @@ For each changed `.md` file:
|
|
|
50
50
|
pleasantries, hedging, connective fluff (however, furthermore, additionally),
|
|
51
51
|
redundant wording, obvious framework knowledge, repeated explanations, decorative prose
|
|
52
52
|
- **Shorten:** "in order to" → "to", "make sure to" → "ensure", use short synonyms
|
|
53
|
+
- **Abbreviate** common terms when context unambiguous: `DB`, `auth`,
|
|
54
|
+
`config`, `req`, `res`, `fn`, `impl`, `env`, `deps`, `ctx`. Skip on
|
|
55
|
+
first occurrence of the concept in the file, or when the
|
|
56
|
+
abbreviation collides with a domain term (`auth` stays
|
|
57
|
+
`authentication` inside an auth-module file). Never abbreviate
|
|
58
|
+
inside code blocks, frontmatter, file paths, command strings, or
|
|
59
|
+
Iron Law fenced blocks.
|
|
60
|
+
- **Arrows for causality:** `X causes Y` / `X leads to Y` / `X, then Y`
|
|
61
|
+
→ `X → Y`. Keep arrows out of code blocks, frontmatter, and Iron
|
|
62
|
+
Law fenced blocks; surrounding prose only. (Example phrases
|
|
63
|
+
backticked on purpose — inline-code protection skips them; never
|
|
64
|
+
strip the backticks.)
|
|
53
65
|
- **Fragments OK:** "Run tests before commit" not "You should always run tests before committing"
|
|
54
66
|
- **Drop:** "you should", "make sure to", "remember to" — state action directly
|
|
55
67
|
- **Merge** redundant bullets that say the same thing differently
|
|
@@ -76,9 +76,9 @@ Based on the type, analyze the relevant code area:
|
|
|
76
76
|
- Identify all models and tables involved
|
|
77
77
|
|
|
78
78
|
**Service context:**
|
|
79
|
-
- Read the service class and its
|
|
79
|
+
- Read the service class and its deps
|
|
80
80
|
- Trace call chain (who calls it, what it calls)
|
|
81
|
-
- Identify configuration and env
|
|
81
|
+
- Identify configuration and env deps
|
|
82
82
|
|
|
83
83
|
**Integration context:**
|
|
84
84
|
- Find API client classes, HTTP calls
|
|
@@ -22,7 +22,7 @@ commands with a single entry point + sub-command dispatch.
|
|
|
22
22
|
| `/context refactor` | `commands/context/refactor.md` | Analyze, update, and extend an existing context document |
|
|
23
23
|
|
|
24
24
|
Sub-command names match the locked contract in
|
|
25
|
-
[`docs/contracts/command-clusters.md`](
|
|
25
|
+
[`docs/contracts/command-clusters.md`](../docs/contracts/command-clusters.md).
|
|
26
26
|
|
|
27
27
|
## Dispatch
|
|
28
28
|
|
|
@@ -22,7 +22,7 @@ standalone commands with a single entry point + sub-command dispatch.
|
|
|
22
22
|
| `/copilot-agents optimize` | `commands/copilot-agents/optimize.md` | Refactor existing AGENTS.md and copilot-instructions.md for line budgets |
|
|
23
23
|
|
|
24
24
|
Sub-command names match the locked contract in
|
|
25
|
-
[`docs/contracts/command-clusters.md`](
|
|
25
|
+
[`docs/contracts/command-clusters.md`](../docs/contracts/command-clusters.md).
|
|
26
26
|
|
|
27
27
|
## Dispatch
|
|
28
28
|
|