claude-dev-env 8.1.0 → 8.3.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 (122) hide show
  1. package/.agents/agents/poteto-agent.md +6 -0
  2. package/.agents/agents/test_agent_frontmatter.py +9 -9
  3. package/.agents/agents/test_pr_description_writer_style.py +1 -1
  4. package/.agents/agents-archived/ARCHIVE-MANIFEST.md +15 -0
  5. package/.agents/{agents → agents-archived}/clean-coder.md +4 -4
  6. package/.agents/{agents → agents-archived}/code-quality-agent.md +5 -5
  7. package/.agents/{agents → agents-archived}/plan-packet-validator.md +2 -2
  8. package/.agents/{agents → agents-archived}/session-advisor.md +2 -2
  9. package/.agents/skills/_shared/end-of-run-gotcha-recommendations.md +2 -2
  10. package/.agents/skills/cert-classification-rule/SKILL.md +3 -3
  11. package/.agents/skills/e-code-review/SKILL.md +2 -2
  12. package/.agents/skills/e-code-review/reference/fix.md +1 -1
  13. package/.agents/skills/e-code-review/reference/loop.md +1 -1
  14. package/.agents/skills/e-code-review/reference/medium.md +4 -4
  15. package/.agents/skills/e-code-review/reference/xhigh.md +5 -5
  16. package/.agents/skills/everything-search/SKILL.md +3 -3
  17. package/.agents/skills/grok-spawn/SKILL.md +9 -6
  18. package/.agents/skills/grok-spawn/reference/flag-profiles.md +12 -8
  19. package/.agents/skills/issue-tracker/SKILL.md +3 -3
  20. package/.agents/skills/orchestrator/SKILL.md +19 -18
  21. package/.agents/skills/orchestrator/reference/consult-the-orchestrator.md +1 -1
  22. package/.agents/skills/orchestrator/reference/executor-consult-block.md +1 -1
  23. package/.agents/skills/orchestrator-refresh/SKILL.md +4 -2
  24. package/.agents/skills/plugin-eval-standalone-skill/SKILL.md +96 -0
  25. package/.agents/skills/plugin-eval-standalone-skill/reference/graders-and-commands.md +108 -0
  26. package/.agents/skills/privacy-hygiene/SKILL.md +5 -6
  27. package/.agents/skills/privacy-hygiene/reference/sweep-procedure.md +5 -6
  28. package/.agents/skills/pull-request/SKILL.md +14 -5
  29. package/.agents/skills/pull-request/reference/publication-tasks.md +1 -1
  30. package/.agents/skills/repairing-hook-boundaries/SKILL.md +1 -1
  31. package/.agents/skills/syncing-submodules/SKILL.md +1 -1
  32. package/.agents/skills/team-advisor/SKILL.md +11 -9
  33. package/.agents/skills/team-advisor/reference/advisor-docs-review.md +28 -1
  34. package/.agents/skills/usage-pause/SKILL.md +3 -3
  35. package/_shared/advisor/advisor-protocol.md +7 -3
  36. package/_shared/advisor/reference/advisor-block.md +8 -1
  37. package/audit-rubrics/category_rubrics/category-f-silent-failures.md +2 -2
  38. package/audit-rubrics/category_rubrics/category-i-concurrency.md +1 -1
  39. package/audit-rubrics/category_rubrics/category-m-producer-consumer-cardinality.md +1 -1
  40. package/audit-rubrics/category_rubrics/category-n-test-name-scenario-verifier.md +5 -5
  41. package/audit-rubrics/category_rubrics/category-o-docstring-vs-impl-drift.md +5 -5
  42. package/audit-rubrics/category_rubrics/category-p-name-vs-behavior-contract.md +3 -3
  43. package/audit-rubrics/category_rubrics/category-q-cross-surface-claims.md +1 -1
  44. package/audit-rubrics/prompts/category-a-api-contracts.md +2 -2
  45. package/audit-rubrics/prompts/category-b-selector-engine-compat.md +3 -3
  46. package/audit-rubrics/prompts/category-c-resource-cleanup.md +3 -3
  47. package/audit-rubrics/prompts/category-d-scoping-and-ordering.md +1 -1
  48. package/audit-rubrics/prompts/category-e-dead-code.md +3 -3
  49. package/audit-rubrics/prompts/category-f-silent-failures.md +12 -12
  50. package/audit-rubrics/prompts/category-g-bounds-and-overflow.md +2 -2
  51. package/audit-rubrics/prompts/category-h-security-boundaries.md +4 -4
  52. package/audit-rubrics/prompts/category-i-concurrency.md +6 -6
  53. package/audit-rubrics/prompts/category-j-code-rules-compliance.md +5 -5
  54. package/audit-rubrics/prompts/category-m-producer-consumer-cardinality.md +1 -1
  55. package/audit-rubrics/prompts/category-n-test-name-scenario-verifier.md +7 -7
  56. package/audit-rubrics/prompts/category-o-docstring-vs-impl-drift.md +2 -2
  57. package/audit-rubrics/prompts/category-p-name-vs-behavior-contract.md +3 -3
  58. package/audit-rubrics/prompts/category-q-cross-surface-claims.md +2 -2
  59. package/bin/ever-shipped-skills.mjs +1 -0
  60. package/bin/ever-shipped-skills.test.mjs +4 -0
  61. package/bin/install.agents-home.test.mjs +44 -94
  62. package/bin/install.mjs +31 -24
  63. package/bin/install.test.mjs +21 -0
  64. package/bin/resolve-package-managed-directory.test.mjs +1 -1
  65. package/bin/subagent-model-policy.test.mjs +15 -8
  66. package/docs/BDD_SCENARIO_QUALITY.md +2 -2
  67. package/docs/CODE_RULES.md +7 -7
  68. package/docs/TEST_QUALITY.md +1 -1
  69. package/docs/nas-ssh-invocation.md +1 -1
  70. package/docs/references/advisor-tool.md +2 -2
  71. package/docs/references/prose-style-enforcement.md +1 -1
  72. package/docs/references/team-advisor-skill.md +2 -2
  73. package/docs/references/weak-executor-advisor.md +1 -1
  74. package/docs/subagent-model-routing.md +6 -5
  75. package/hooks/blocking/tdd_enforcer.py +2 -3
  76. package/hooks/blocking/test_bash_post_call_dispatcher.py +7 -24
  77. package/hooks/blocking/test_code_rules_enforcer_magic_allowlist.py +1 -1
  78. package/hooks/hooks_constants/bash_post_call_dispatcher_constants.py +0 -3
  79. package/hooks/hooks_constants/hosted_hook_runner.py +1 -1
  80. package/hooks/hooks_constants/msys_path_conversion_advisor_constants.py +3 -35
  81. package/hooks/hooks_constants/test_bash_post_call_dispatcher_constants.py +2 -10
  82. package/hooks/routing/subagent_model_routing.mjs +15 -0
  83. package/hooks/routing/subagent_model_routing.test.mjs +58 -25
  84. package/package.json +1 -1
  85. package/rules/archiving-agent-config.md +5 -8
  86. package/rules/git-workflow.md +3 -3
  87. package/rules/long-horizon-autonomy.md +1 -1
  88. package/rules/shell-invocation.md +0 -2
  89. package/rules/subagent-model-policy.json +5 -13
  90. package/rules/testing.md +0 -2
  91. package/scripts/active_capability_references.py +74 -19
  92. package/scripts/banned_prose_words.py +159 -0
  93. package/scripts/dev_env_scripts_constants/active_capability_constants.py +12 -10
  94. package/scripts/dev_env_scripts_constants/banned_prose_word_constants.py +95 -0
  95. package/scripts/dev_env_scripts_constants/grok_worker_constants.py +3 -3
  96. package/scripts/grok_headless_runner.py +19 -1
  97. package/scripts/grok_worker_preflight.py +67 -1
  98. package/scripts/policy_lint/adapter_retired_hook_prose.py +17 -7
  99. package/scripts/policy_lint/adapters.py +6 -6
  100. package/scripts/policy_lint/config/constants.py +8 -0
  101. package/scripts/policy_lint/registry.py +1 -1
  102. package/scripts/resolve_advisor_model_route.mjs +2 -2
  103. package/scripts/subagent_model_policy.mjs +4 -1
  104. package/scripts/sync_to_cursor/rules.py +1 -1
  105. package/scripts/test_active_capability_references.py +100 -33
  106. package/scripts/test_grok_headless_runner.py +35 -1
  107. package/scripts/test_grok_worker_preflight.py +73 -0
  108. package/scripts/tests/resolve_advisor_model_route.test.mjs +3 -3
  109. package/scripts/tests/test_banned_prose_words.py +103 -0
  110. package/scripts/tests/test_engine.py +1 -1
  111. package/scripts/tests/test_policy_lint_rules_retired_hook_prose.py +46 -0
  112. package/scripts/tests/test_rules.py +17 -6
  113. package/system-prompts/software-engineer.xml +7 -7
  114. package/hooks/advisory/msys_path_conversion_advisor.py +0 -200
  115. package/hooks/advisory/test_msys_path_conversion_advisor.py +0 -223
  116. package/hooks/hooks_constants/test_failure_recorder_constants.py +0 -34
  117. package/hooks/observability/test_failure_recorder.py +0 -221
  118. package/hooks/observability/test_test_failure_recorder.py +0 -173
  119. /package/.agents/{agents → agents-archived}/git-commit-crafter.md +0 -0
  120. /package/.agents/{agents → agents-archived}/issue-tracker.md +0 -0
  121. /package/.agents/{agents → agents-archived}/pr-description-writer.md +0 -0
  122. /package/.agents/{agents → agents-archived}/skill-writer-agent.md +0 -0
@@ -0,0 +1,6 @@
1
+ ---
2
+ name: poteto-agent
3
+ description: Use the installed pstack poteto-mode agent for delegated work.
4
+ ---
5
+
6
+ Read the installed pstack `poteto-mode/SKILL.md` in full before any work. Follow its instructions for this task.
@@ -81,7 +81,7 @@ import yaml
81
81
  ACCEPTED_FRONTMATTER_KEYS = frozenset({"name", "description", "tools", "color"})
82
82
  CODE_QUALITY_AGENT_FILENAME = "code-quality-agent.md"
83
83
  CODE_QUALITY_READ_ONLY_TOOLS = ("Read", "Grep", "Glob")
84
- INSTRUCTION_ALIAS_FILENAMES = frozenset({"AGENTS.md", "CLAUDE.md"})
84
+ INSTRUCTION_ALIAS_FILENAMES = frozenset({"AGENTS.md", "CLAUDE.md", "ARCHIVE-MANIFEST.md"})
85
85
  FRONTMATTER_FENCE_LINE = "---"
86
86
  MATERIALIZER_MODULE_NAME = "codex_compat_materializer"
87
87
  MATERIALIZER_MODULE_PATH = (
@@ -124,7 +124,7 @@ def _agent_definition_candidate_paths() -> tuple[Path, ...]:
124
124
  Returns:
125
125
  Every agent-definition `*.md` path in this directory, sorted.
126
126
  """
127
- agents_directory = Path(__file__).parent
127
+ agents_directory = Path(__file__).parent.parent / "agents-archived"
128
128
  return tuple(
129
129
  each_markdown_file
130
130
  for each_markdown_file in sorted(agents_directory.glob("*.md"))
@@ -298,7 +298,7 @@ def test_agent_frontmatter_loads_as_a_yaml_mapping(
298
298
  )
299
299
  def named_agents_yaml_safe_load_as_mapping(agent_file_name: str) -> None:
300
300
  """P-107 regression: named agents remain real YAML mappings under safe_load."""
301
- agent_definition_path = Path(__file__).parent / agent_file_name
301
+ agent_definition_path = Path(__file__).parent.parent / "agents-archived" / agent_file_name
302
302
  assert agent_definition_path.is_file(), (
303
303
  f"{agent_file_name} missing from agents/ — P-107 surface gone"
304
304
  )
@@ -419,7 +419,7 @@ def test_agent_frontmatter_carries_no_model_key(
419
419
 
420
420
 
421
421
  def _clean_coder_body() -> str:
422
- return (Path(__file__).parent / "clean-coder.md").read_text(encoding="utf-8")
422
+ return (Path(__file__).parent.parent / "agents-archived" / "clean-coder.md").read_text(encoding="utf-8")
423
423
 
424
424
 
425
425
  SOURCE_LINK_PATTERN = re.compile(
@@ -602,7 +602,7 @@ EXPECTED_SOURCE_LINK_PAIRS = {
602
602
 
603
603
 
604
604
  def _assert_source_link_contract(agent_file_name: str, agent_text: str) -> None:
605
- agents_directory = Path(__file__).parent
605
+ agents_directory = Path(__file__).parent.parent / "agents-archived"
606
606
  repository_root = agents_directory.parents[3]
607
607
  actual_source_links = frozenset(SOURCE_LINK_PATTERN.findall(agent_text))
608
608
  expected_source_links = EXPECTED_SOURCE_LINK_PAIRS[agent_file_name]
@@ -624,7 +624,7 @@ def _assert_source_link_contract(agent_file_name: str, agent_text: str) -> None:
624
624
 
625
625
 
626
626
  def test_named_agents_document_installed_paths_and_source_fallbacks() -> None:
627
- agents_directory = Path(__file__).parent
627
+ agents_directory = Path(__file__).parent.parent / "agents-archived"
628
628
  for each_agent_file_name in (
629
629
  "clean-coder.md",
630
630
  "code-quality-agent.md",
@@ -687,7 +687,7 @@ def test_source_link_contract_rejects_directory_fallback() -> None:
687
687
 
688
688
 
689
689
  def test_named_agents_resolve_active_managed_root_and_agents_home() -> None:
690
- agents_directory = Path(__file__).parent
690
+ agents_directory = Path(__file__).parent.parent / "agents-archived"
691
691
  for each_agent_file_name in (
692
692
  "clean-coder.md",
693
693
  "code-quality-agent.md",
@@ -906,14 +906,14 @@ def test_clean_coder_policy_targets_exist_in_source_package() -> None:
906
906
 
907
907
 
908
908
  def test_code_quality_agent_allows_only_read_and_search_tools() -> None:
909
- agent_definition_path = Path(__file__).parent / CODE_QUALITY_AGENT_FILENAME
909
+ agent_definition_path = Path(__file__).parent.parent / "agents-archived" / CODE_QUALITY_AGENT_FILENAME
910
910
  parsed_frontmatter = yaml.safe_load(_frontmatter_block(agent_definition_path))
911
911
 
912
912
  assert parsed_frontmatter["tools"] == list(CODE_QUALITY_READ_ONLY_TOOLS)
913
913
 
914
914
 
915
915
  def test_code_quality_agent_contract_forbids_mutating_commands() -> None:
916
- agent_definition_path = Path(__file__).parent / CODE_QUALITY_AGENT_FILENAME
916
+ agent_definition_path = Path(__file__).parent.parent / "agents-archived" / CODE_QUALITY_AGENT_FILENAME
917
917
  body = agent_definition_path.read_text(encoding="utf-8")
918
918
  assert "Use only `Read`, `Grep`, and `Glob`." in body
919
919
  assert "Author zero edits." in body
@@ -4,7 +4,7 @@ from pathlib import Path
4
4
 
5
5
 
6
6
  AGENT_DIRECTORY = Path(__file__).parent
7
- AGENT_PATH = AGENT_DIRECTORY / "pr-description-writer.md"
7
+ AGENT_PATH = AGENT_DIRECTORY.parent / "agents-archived" / "pr-description-writer.md"
8
8
  VOICE_REFERENCE_PATH = AGENT_DIRECTORY / "reference" / "pr-description-illustrative-voice.md"
9
9
  VERIFICATION_REFERENCE_PATH = AGENT_DIRECTORY / "reference" / "pr-description-verification.md"
10
10
 
@@ -0,0 +1,15 @@
1
+ # Archived agent definitions
2
+
3
+ These definitions are archived outside the package's active agent tree. Restore
4
+ one with the `git mv` command in its row, then restore the named caller and test edits.
5
+
6
+ | File | Reason | Restore |
7
+ |---|---|---|
8
+ | `clean-coder.md` | Personal coding workflow now routes through `pstack:poteto-agent` with task instructions in each call. | `git mv packages/claude-dev-env/.agents/agents-archived/clean-coder.md packages/claude-dev-env/.agents/agents/` and restore active caller references plus agent contract tests. |
9
+ | `code-quality-agent.md` | Personal review workflow now routes through `pstack:poteto-agent` with review instructions in each call. | `git mv packages/claude-dev-env/.agents/agents-archived/code-quality-agent.md packages/claude-dev-env/.agents/agents/` and restore active caller references plus agent contract tests. |
10
+ | `git-commit-crafter.md` | Personal commit drafting workflow is archived with the other package-owned agents. | `git mv packages/claude-dev-env/.agents/agents-archived/git-commit-crafter.md packages/claude-dev-env/.agents/agents/` and restore the model policy entry. |
11
+ | `issue-tracker.md` | Personal issue handling workflow now routes through `pstack:poteto-agent` loading the issue-tracker skill. | `git mv packages/claude-dev-env/.agents/agents-archived/issue-tracker.md packages/claude-dev-env/.agents/agents/` and restore active issue routing plus installer and contract tests. |
12
+ | `plan-packet-validator.md` | Personal plan validation workflow is archived with the other package-owned agents. | `git mv packages/claude-dev-env/.agents/agents-archived/plan-packet-validator.md packages/claude-dev-env/.agents/agents/` and restore the model policy entry. |
13
+ | `pr-description-writer.md` | Personal PR drafting workflow now routes through `pstack:poteto-agent` with diff-specific writing instructions. | `git mv packages/claude-dev-env/.agents/agents-archived/pr-description-writer.md packages/claude-dev-env/.agents/agents/` and restore active PR routing plus installer and contract tests. |
14
+ | `session-advisor.md` | Personal advisor workflow now routes through `pstack:poteto-agent` with the advisor response contract in the prompt. | `git mv packages/claude-dev-env/.agents/agents-archived/session-advisor.md packages/claude-dev-env/.agents/agents/` and restore advisor routing, resolver, and contract tests. |
15
+ | `skill-writer-agent.md` | Personal skill authoring workflow is archived with the other package-owned agents. | `git mv packages/claude-dev-env/.agents/agents-archived/skill-writer-agent.md packages/claude-dev-env/.agents/agents/` and restore the model policy entry. |
@@ -79,7 +79,7 @@ Load only the group that matches the task. Keep session policy details in these
79
79
 
80
80
  Material implementation questions must return to the caller for `AskUserQuestion` handling; do not ask in plain text or guess.
81
81
 
82
- Type-ignore rule (AGENTS Types): avoid `# type: ignore`; remove it and use a typed boundary or real type.
82
+ Type-ignore rule (AGENTS Types): avoid `# type: ignore`; remove it and use a typed boundary or type.
83
83
 
84
84
  Constants (AGENTS Magic values): use named constants from the target layout. Search its constants module first. Do not force a generic `config/` layout. Example:
85
85
 
@@ -101,7 +101,7 @@ def fetch_with_retries(fetch_text: Callable[[str], str], url: str) -> str:
101
101
  - **No secrets in context.** Never open `.env` / `.env.*` / credential files. The sensitive-file protector blocks editing them.
102
102
  - **No lock-file hand edits.** Do not edit lock files by hand; regenerate with the package manager.
103
103
  - **No unasked scratch files.** Follow the target repo's policy for scratch, planning, and image files. Do not create temporary scratch files or working docs. Keep valid plan packets under `docs/plans/` as uncommitted working files when the task calls for them. Store required images in the durable artifacts release, not the repository tree.
104
- - **Pre-check before Write.** Run `python <managed-root>/hooks/blocking/code_rules_enforcer.py --check <candidate> --as <real destination>` (install path; monorepo: `packages/claude-dev-env/hooks/blocking/code_rules_enforcer.py`) until clean, then Write/Edit once. Use the real `--as` path; a wrong path can hide violations. This is the mechanical CODE_RULES check; it does not run tests, ruff, mypy, or the full quality gate.
104
+ - **Pre-check before Write.** Run `python <managed-root>/hooks/blocking/code_rules_enforcer.py --check <candidate> --as <destination>` (install path; monorepo: `packages/claude-dev-env/hooks/blocking/code_rules_enforcer.py`) until clean, then Write/Edit once. Use the `--as` path; a wrong path can hide violations. This is the mechanical CODE_RULES check; it does not run tests, ruff, mypy, or the full quality gate.
105
105
  - **Candidate check vs full gate.** The pre-check tests CODE_RULES only. The full project gate runs over the complete diff and all required checks. `code_rules_enforcer.py --check` checks one candidate file before a write; a clean candidate enforcer check is not the full gate.
106
106
  - **Windows shell.** Author multi-line scripts with the Write or PowerShell tool; avoid bash heredocs that mangle paths.
107
107
  - **`gh` bodies.** Always `--body-file`; never use `--body` or `-b` with markdown.
@@ -113,7 +113,7 @@ def fetch_with_retries(fetch_text: Callable[[str], str], url: str) -> str:
113
113
 
114
114
  Every behavior change follows Red-Green-Refactor:
115
115
 
116
- 1. **RED** — write a failing test first against the real production path, with real data; run it red and keep the failure as evidence.
116
+ 1. **RED** — write a failing test first against the production path, with production data; run it red and keep the failure as evidence.
117
117
  2. **GREEN** — write the minimum production change, then run the focused test.
118
118
  3. **REFACTOR** — change structure only after GREEN, then run the focused test again.
119
119
 
@@ -121,7 +121,7 @@ Do not write production behavior before RED, skip the red run, or call a green t
121
121
 
122
122
  ## Hook-specific workflow
123
123
 
124
- For a hook change, use the target package's active managed root for installed files, not the current working directory. The default is `~/.claude`; `--target` or `CLAUDE_CONFIG_DIR` selects another managed root. Read `<managed-root>/hooks/AGENTS.md` (default: `~/.claude/hooks/AGENTS.md`; source fallback: `packages/claude-dev-env/hooks/AGENTS.md`), each closer `AGENTS.md` and `CLAUDE.md`, and the registered hook entry before editing. Trace the lifecycle event, stdin JSON, output contract, exit code, and registration. Reuse the target hook area's constants package. Run `<managed-root>/scripts/check.ps1` (default: `~/.claude/scripts/check.ps1`; source fallback: `packages/claude-dev-env/scripts/check.ps1`) and drive the real production entry point with event payloads. The RED test covers each allow and deny outcome. Run every applicable test file and suite for the hook, then the full quality gates required by the affected package.
124
+ For a hook change, use the target package's active managed root for installed files, not the current working directory. The default is `~/.claude`; `--target` or `CLAUDE_CONFIG_DIR` selects another managed root. Read `<managed-root>/hooks/AGENTS.md` (default: `~/.claude/hooks/AGENTS.md`; source fallback: `packages/claude-dev-env/hooks/AGENTS.md`), each closer `AGENTS.md` and `CLAUDE.md`, and the registered hook entry before editing. Trace the lifecycle event, stdin JSON, output contract, exit code, and registration. Reuse the target hook area's constants package. Run `<managed-root>/scripts/check.ps1` (default: `~/.claude/scripts/check.ps1`; source fallback: `packages/claude-dev-env/scripts/check.ps1`) and drive the production entry point with event payloads. The RED test covers each allow and deny outcome. Run every applicable test file and suite for the hook, then the full quality gates required by the affected package.
125
125
 
126
126
  ## Session advisor
127
127
 
@@ -127,7 +127,7 @@ evidence, report an evidence gap or open question.
127
127
 
128
128
  `id` uses the form `loop<N>-<K>` when the orchestrator supplies a loop prefix and `find<K>` for standalone audit calls. Honor the prefix supplied in the prompt.
129
129
 
130
- **The `failure_mode` field is the audit-to-fix handoff.** State the failing line, the desired post-fix property, and a one-line validation the fix agent can run to confirm correctness. The fix agent reads `failure_mode` without re-running your audit — make it self-sufficient.
130
+ **The `failure_mode` field is the audit-to-fix handoff.** State the failing line, the desired post-fix property, and a one-line validation the fix agent can run to confirm correctness. The fix agent reads `failure_mode` without re-running your audit — make it stand on its own.
131
131
 
132
132
  Each audit→fix→audit cycle in the calling skill adds wall-clock latency. A vague `failure_mode` forces another cycle to clarify; a precise `failure_mode` lets the fix land in one cycle. Word choice in this field directly controls how many cycles the loop takes.
133
133
 
@@ -165,9 +165,9 @@ not a Shape B entry.
165
165
 
166
166
  ## Collection before filtering
167
167
 
168
- Report every real finding at its true severity. Collection retains P0, P1, and
168
+ Report every finding at the severity it warrants. Collection retains P0, P1, and
169
169
  P2 findings with file, line, evidence (`excerpt` / `failure_mode`), and
170
- category. Do not drop lower-severity real findings during collection so a later
170
+ category. Do not drop lower-severity findings during collection so a later
171
171
  consumer can filter. Severity or action filtering is a separate stage after the
172
172
  collection record is complete.
173
173
 
@@ -189,7 +189,7 @@ The second pass produces either:
189
189
  - new Shape A findings citing file:line references absent from the first pass, or
190
190
  - explicit Shape B `adversarial_probes` entries for each re-examined category.
191
191
 
192
- A second pass that returns "first pass was complete, confidence high" is inadequate per the audit contract — confidence is replaced by either new findings or new adversarial evidence per category.
192
+ A second pass that returns "first pass was complete, confidence high" is inadequate per the audit contract. Confidence must yield new findings or new adversarial evidence per category.
193
193
 
194
194
  ## Merging Primary and Adversarial Findings
195
195
 
@@ -197,7 +197,7 @@ When the primary and adversarial passes flag the same file:line:
197
197
 
198
198
  - Merge into a single Shape A finding using max-wins severity (P0 > P1 > P2).
199
199
  - Concatenate the `failure_mode` strings (separator: " // adversarial: ") so both pass narratives survive.
200
- - For Shape B entries on the same category, keep every distinct `adversarial_probe` from both passes — collapsing them would drop information that was actually found.
200
+ - For Shape B entries on the same category, keep every distinct `adversarial_probe` from both passes — collapsing them would drop information that was found.
201
201
 
202
202
  The merge runs at the end of the adversarial pass, before constructing the output. The output preamble's `Total: N` counts merged findings, not pre-merge total.
203
203
 
@@ -20,7 +20,7 @@ You validate plan packets. You are not the planner and you do not repair docs.
20
20
  1. Read `README.md`, `packet.json`, `context/source-map.md`, `implementation/steps.md`, `implementation/tdd-plan.md`, `spec/acceptance.md`, and `handoff/build-prompt.md`.
21
21
  2. Read or search the source files named in `source-map.md` and `packet.json`.
22
22
  3. Verify referenced paths exist unless the packet clearly labels them as new files.
23
- 4. Verify source facts match actual files.
23
+ 4. Verify source facts match the files.
24
24
  5. Verify the implementation steps are enough for a blind build agent.
25
25
  6. Verify the TDD sequence starts with failing tests and names the behavior those tests prove.
26
26
  7. Verify scope matches the user request and non-goals.
@@ -30,4 +30,4 @@ You validate plan packets. You are not the planner and you do not repair docs.
30
30
 
31
31
  ## Output
32
32
 
33
- Return the requested structured schema. Set `allPassed` to true only when every check is clean. Each finding must name the packet file, the check, and the exact source-grounded problem.
33
+ Return the requested structured schema. Set `allPassed` to `true` only when every check is clean. Each finding must name the packet file, the check, and the exact source-grounded problem.
@@ -5,7 +5,7 @@ tools: SendMessage
5
5
  color: cyan
6
6
  ---
7
7
 
8
- You are a standing reviewer a Claude Code session consults across the life of a task — not only when it is stuck, but before it commits to a plan, once it believes the work is finished, before any commit is executed, and when it is weighing whether to change course. Your only tool is SendMessage, used to reply to the sender of each consult by name. Everything else you know arrives in the consultation message: what changed since the last consult, the live decision or question, and any file paths or excerpts the session chose to include.
8
+ You are a standing reviewer a Claude Code session consults across the life of a task. The session consults you before it commits to a plan, once it believes the work is finished, before any commit is executed, and when it weighs whether to change course. Your only tool is SendMessage, which replies to the sender of each consult by name. Everything else you know arrives in the consultation message: what changed since the last consult, the live decision or question, and any file paths or excerpts the session chose to include.
9
9
 
10
10
  Many different consumers may reach you over one shared transcript — a coordinating session and the executor subagents it spawns, not just the single session that spawned you. Three things follow from that:
11
11
 
@@ -16,7 +16,7 @@ Many different consumers may reach you over one shared transcript — a coordina
16
16
  Reply with exactly one of four signals, named on the first line:
17
17
 
18
18
  - **ENDORSE** — the plan, or the finished work, holds up, with nothing worth flagging. A clean yes.
19
- - **CORRECTION** — something needs attention before the plan or the finished work is genuinely done: a wrong assumption or step, or a risk worth naming and closing. Name the specific problem(s) and the precise fix(es) or mitigation(s). A risk you would otherwise have mentioned in passing belongs here, not folded into an ENDORSE.
19
+ - **CORRECTION** — something needs attention before the plan or the finished work is done: a wrong assumption or step, or a risk worth naming and closing. Name the specific problem(s) and the precise fix(es) or mitigation(s). A risk you would otherwise have mentioned in passing belongs here, not folded into an ENDORSE.
20
20
  - **PLAN** — the current approach needs to change. Give concrete ordered steps the session can run with its own tools, naming files, commands, and decision points.
21
21
  - **STOP** — no path satisfies the task as assigned (contradictory constraints, missing access, a rule that forbids every way through). Say why, and report your reasoning with cited proof and examples.
22
22
 
@@ -29,7 +29,7 @@ Keep only items that **bit this run**:
29
29
 
30
30
  1. Show findings in chat; categorize as P0-P3.
31
31
  2. Then `AskUserQuestion`.
32
- 3. On confirm only, file via `issue-tracker`.
32
+ 3. On confirm only, ask `pstack:poteto-agent` to load `issue-tracker` and file the issue.
33
33
 
34
34
  ### Cold-reader frame
35
35
 
@@ -126,7 +126,7 @@ Only after the chat block.
126
126
 
127
127
  Detail and ASCII stay in chat.
128
128
 
129
- **On confirm:** file via `issue-tracker`.
129
+ **On confirm:** ask `pstack:poteto-agent` to load `issue-tracker` and file the issue.
130
130
 
131
131
  Cold-reader issue body.
132
132
 
@@ -135,7 +135,7 @@ truthful note, because it becomes the pasted sentence for those classes.
135
135
 
136
136
  Do **not** fabricate a "Samsung confirmed" claim. State only what is true. The shipped Gallery
137
137
  note is true because Samsung Support did confirm that issue; a new pattern for a different
138
- issue must not borrow that wording unless the confirmation actually happened.
138
+ issue must not borrow that wording unless the confirmation happened.
139
139
 
140
140
  ## How to add the paired production-path test
141
141
 
@@ -143,7 +143,7 @@ Every new unfixable pattern gets a paired test in
143
143
  `shared_utils/samsung_utils/tests/test_cert_failure_classifier.py` that drives the production
144
144
  path:
145
145
 
146
- 1. Load the real patterns with `load_unfixable_patterns()` (no path argument, so it reads the
146
+ 1. Load the patterns with `load_unfixable_patterns()` (no path argument, so it reads the
147
147
  shipped config).
148
148
  2. Build the report HTML with the live must-fix title text, run it through
149
149
  `extract_issue_titles`, then `classify_failure`, and assert the result is `unfixable`.
@@ -153,7 +153,7 @@ path:
153
153
 
154
154
  Use the exact title strings Samsung's report produces. The existing
155
155
  `TestClassifyFailure::test_gallery_regex_matches_all_known_variants` shows the shape: a list of
156
- real title variants, each asserted as `unfixable` through `classify_failure`.
156
+ title variants, each asserted as `unfixable` through `classify_failure`.
157
157
 
158
158
  Run the tests from the `shared_utils` directory (its pytest config is anchored there):
159
159
 
@@ -24,7 +24,7 @@ Proposal mode selects the review level and records finding outcomes. The downstr
24
24
  ## Gotchas
25
25
 
26
26
  - **`low` stays single-pass.** No subagents, no full-file reads: one read pass per target item, one findings pass.
27
- - **Collection reports every real finding.** Keep every CONFIRMED or PLAUSIBLE finding at its assigned severity (`blocker`, `high`, `medium`, `low`, `nit`). Do not drop low or nit findings during collection. Severity or action filtering is a separate consumer stage after the collection record is complete (`scripts/finding_pipeline.py`).
27
+ - **Collection reports every finding.** Keep every CONFIRMED or PLAUSIBLE finding at its assigned severity (`blocker`, `high`, `medium`, `low`, `nit`). Do not drop low or nit findings during collection. Severity or action filtering is a separate consumer stage after the collection record is complete (`scripts/finding_pipeline.py`).
28
28
  - **`medium` favors precision, `xhigh` favors recall.** At `medium` (8 angles) assign severity carefully so a later filter can pick maintainer-action findings. At `xhigh` (10 angles plus a gap sweep) a single non-REFUTED vote carries the finding; do not drop on uncertainty.
29
29
  - **Every retained finding carries `severity` and `verdict`.** Severity is one of `blocker`, `high`, `medium`, `low`, `nit`. Verdict is `CONFIRMED` or `PLAUSIBLE`. Drop REFUTED candidates only; never emit an unclassified retained finding.
30
30
  - **`--fix` applies findings once.** Load `reference/fix.md` and follow it. That file owns the fix agent, the code-rules gate, skip logging, and outcome reporting. Commits are lead-owned; fix agents never commit or push.
@@ -74,7 +74,7 @@ Detail: `reference/effort-evaluation.md`.
74
74
  | `reference/preflight-proposal.md` | Isolated local review, immutable SHAs, proposal evidence, and mutation boundary |
75
75
  | `reference/effort-evaluation.md` | Effort evaluation fixtures, evidence, and skill defaults |
76
76
  | `reference/runner-selection.md` | Runner selection map |
77
- | `scripts/finding_pipeline.py` | Collect every real finding; filter severity only later |
77
+ | `scripts/finding_pipeline.py` | Collect every finding; filter severity only later |
78
78
  | `scripts/test_finding_pipeline.py` | Collection and filter-stage behavioral tests |
79
79
  | `scripts/e_code_review_scripts_constants/finding_pipeline_constants.py` | Named constants for the collect-then-filter pipeline |
80
80
  | `scripts/effort_evaluation.py` | Effort rows, recommendation, skill default resolver |
@@ -66,7 +66,7 @@ After fixes land, report the same findings list again through the structured
66
66
  findings-report call, the call that renders this review's results as a typed
67
67
  list in the host UI, with each finding now carrying an `outcome`:
68
68
  `fixed`, `no_change_needed` (the finding was wrong or already handled), or
69
- `skipped` (real but not applied). Do not repeat the findings as text in the
69
+ `skipped` (the finding stands but no fix was applied). Do not repeat the findings as text in the
70
70
  response body; the structured call is the record the host UI reads, and the
71
71
  batched skip list from above goes in the prose that follows it.
72
72
 
@@ -183,7 +183,7 @@ round's progress report. Then take the one case that matches the round's
183
183
  findings.
184
184
 
185
185
  - Any bug-severity finding: validate each bug with an advisor before touching
186
- code. Confirm it's real and confirm the intended fix, then fix every
186
+ code. Confirm the bug exists and confirm the intended fix, then fix every
187
187
  validated bug and every nit on the review target. A refuted bug removes only
188
188
  itself from the round's work; the nits are fixed either way.
189
189
  - Nits only, with at least one nit present: fix all of them on the review
@@ -2,7 +2,7 @@
2
2
 
3
3
  You are reviewing for **precision** at medium effort: assign severity carefully
4
4
  so a later consumer can select maintainer-action findings. **Collection
5
- reports every real finding** (including `low` and `nit`); do not drop by
5
+ reports every finding** (including `low` and `nit`); do not drop by
6
6
  severity during collection. Severity filtering is a separate consumer stage
7
7
  after the collection record is complete.
8
8
 
@@ -44,7 +44,7 @@ wrong-variable copy-paste, error swallowed in catch, unescaped regex metachars.
44
44
  For every line the diff DELETES or replaces, name the invariant or behavior it
45
45
  enforced, then search the new code for where that invariant is re-established.
46
46
  If you can't find it, that's a candidate: a removed guard, a dropped error
47
- path, a narrowed validation, a deleted test that was covering a real case.
47
+ path, a narrowed validation, a deleted test that was covering a case.
48
48
 
49
49
  ### Angle C — cross-file tracer
50
50
 
@@ -115,7 +115,7 @@ file(s), and the candidate, and have it return exactly one of:
115
115
 
116
116
  - **CONFIRMED** — can name the inputs/state that trigger it and the wrong
117
117
  output or crash. Quote the line.
118
- - **PLAUSIBLE** — mechanism is real, trigger is uncertain (timing, env,
118
+ - **PLAUSIBLE** — mechanism is present in the code, trigger is uncertain (timing, env,
119
119
  config). State what would confirm it.
120
120
  - **REFUTED** — factually wrong (code doesn't say that) or guarded elsewhere.
121
121
  Quote the line that proves it.
@@ -126,7 +126,7 @@ Keep candidates where the vote is CONFIRMED or PLAUSIBLE.
126
126
 
127
127
  **Collection stage first.** Keep every CONFIRMED or PLAUSIBLE finding in the
128
128
  collection record, including `low` and `nit`. Drop only REFUTED candidates.
129
- Do not drop a real finding because its severity is low.
129
+ Do not drop a finding because its severity is low.
130
130
 
131
131
  Report this review's results — `{level, findings}` — through the structured
132
132
  findings-report call: the mechanism that renders a review's results as a typed
@@ -1,7 +1,7 @@
1
1
  `xhigh effort → 5+5 angles → 1-vote verify → sweep`
2
2
 
3
- You are reviewing for **recall** at extra-high effort: catch every real bug. At
4
- this level, catching real bugs matters more than avoiding false positives — a
3
+ You are reviewing for **recall** at extra-high effort: catch every bug. At
4
+ this level, catching bugs matters more than avoiding false positives — a
5
5
  missed bug ships. Err on the side of surfacing.
6
6
 
7
7
  ## Phase 0 — Gather the diff
@@ -42,7 +42,7 @@ wrong-variable copy-paste, error swallowed in catch, unescaped regex metachars.
42
42
  For every line the diff DELETES or replaces, name the invariant or behavior it
43
43
  enforced, then search the new code for where that invariant is re-established.
44
44
  If you can't find it, that's a candidate: a removed guard, a dropped error
45
- path, a narrowed validation, a deleted test that was covering a real case.
45
+ path, a narrowed validation, a deleted test that was covering a case.
46
46
 
47
47
  ### Angle C — cross-file tracer
48
48
 
@@ -65,7 +65,7 @@ adapter): check that every method routes to the wrapped instance and not back
65
65
  through a registry/session/global — e.g. a caching provider holding a
66
66
  `delegate` field that resolves IDs via `session.get(...)` instead of
67
67
  `delegate.get(...)` will re-enter the cache or recurse. Also check that the
68
- wrapper forwards all the methods the callers actually use.
68
+ wrapper forwards all the methods the callers use.
69
69
 
70
70
  ### Reuse
71
71
 
@@ -125,7 +125,7 @@ file(s), and the candidate, and have it return exactly one of:
125
125
 
126
126
  - **CONFIRMED** — can name the inputs/state that trigger it and the wrong
127
127
  output or crash. Quote the line.
128
- - **PLAUSIBLE** — mechanism is real, trigger is uncertain (timing, env,
128
+ - **PLAUSIBLE** — mechanism is present in the code, trigger is uncertain (timing, env,
129
129
  config). State what would confirm it.
130
130
  - **REFUTED** — factually wrong (code doesn't say that) or guarded elsewhere.
131
131
  Quote the line that proves it.
@@ -152,16 +152,16 @@ Run separate searches for each extension type:
152
152
 
153
153
  ### Junctions, Symlinks & Drive Mapping
154
154
 
155
- Everything indexes REAL paths only, not junctions or mapped drives.
155
+ Everything indexes paths only, not junctions or mapped drives.
156
156
 
157
157
  | Drive | Type | Indexed? | Action |
158
158
  |-------|------|----------|--------|
159
- | Y:\ | Real NTFS | Yes | Use this path |
159
+ | Y:\ | NTFS | Yes | Use this path |
160
160
  | Z:\ | Junction to Y: | No | Use Y:\ instead |
161
161
 
162
162
  **If search returns empty:**
163
163
  1. Check if the path is a junction/symlink
164
- 2. Find the real path and search that instead
164
+ 2. Find the path the junction targets and search that instead
165
165
  3. Or use Glob tool as fallback (works on any path)
166
166
 
167
167
  **Common drive mappings:**
@@ -16,7 +16,11 @@ the scripts and the brief templates; it holds no spawn logic of its own.
16
16
  - Workers never commit, push, or call `gh`. The calling session stages, verifies,
17
17
  commits, pushes, and posts to GitHub.
18
18
  - Grok has no `SendMessage` and no Claude Agent tool. Work that needs live
19
- teammate chat or Claude-only tools stays in this session or a Claude agent.
19
+ teammate chat stays in this session. Each Grok worker uses `poteto-agent`.
20
+ The runner resolves the user pstack plugin through the selected Claude
21
+ profile's `plugins/installed_plugins.json` and includes its poteto skill content and
22
+ its resolved path in the prompt. Each task states its role, permitted edits,
23
+ acceptance checks, and report contract.
20
24
  - Each worker gets its own `--leader-socket`. Sharing one socket across processes
21
25
  races and fails.
22
26
  - Preflight is a soft gate: a fallthrough reason means skip the fleet and use
@@ -39,7 +43,7 @@ Good fits:
39
43
  **Do not use** when the work needs:
40
44
 
41
45
  - Live `SendMessage` coordination between agents
42
- - Claude-only tools (Agent tool, warm session-advisor, Claude MCP surfaces the
46
+ - Claude-only tools (Agent tool, warm advisor, Claude MCP surfaces the
43
47
  grok CLI does not load the same way)
44
48
 
45
49
  For a single interactive Grok Build handoff paste, use `/grokify` instead.
@@ -125,7 +129,7 @@ Shape:
125
129
  "tool_profile": "readonly",
126
130
  "timeout_seconds": 600,
127
131
  "is_repo_only": true,
128
- "agent_name": null
132
+ "agent_name": "poteto-agent"
129
133
  }
130
134
  ]
131
135
  }
@@ -133,7 +137,7 @@ Shape:
133
137
 
134
138
  | Field | Meaning |
135
139
  |---|---|
136
- | `role` | Preflight role whose agent files must be installed (default `bugteam`) |
140
+ | `role` | Preflight role configuration to check (default `bugteam`) |
137
141
  | `should_ping` | When true, preflight runs the opt-in live ping |
138
142
  | `workers` | Non-empty list of worker objects |
139
143
  | `role_name` | Label on the summary report for this worker |
@@ -142,7 +146,7 @@ Shape:
142
146
  | `tool_profile` | `readonly` or `build` |
143
147
  | `timeout_seconds` | Per-worker timeout (default 600, ceiling 5400). A spec asking for more is refused |
144
148
  | `is_repo_only` | Readonly only: when true, also pass `--disable-web-search` |
145
- | `agent_name` | Optional `--agent` name, or `null` |
149
+ | `agent_name` | Use `poteto-agent`; prompts carry the worker role. |
146
150
 
147
151
  Workers run with no turn cap. The timeout is the only bound on a worker's
148
152
  length, and a worker that hits it is killed with its whole process tree and
@@ -235,4 +239,3 @@ Sibling skill: `/grokify` for a single paste-ready interactive Grok Build handof
235
239
  ## Worker advisors
236
240
 
237
241
  Each grok worker binds a unique Opus-high dvisor_session_id through the lead-supplied dvisor.launcher in the batch spec (committed default is a placeholder). Reports require the same handle\'s ENDORSE (or bounded CORRECTION/PLAN then ENDORSE); STOP or malformed signals end as advisor_blocked.
238
-
@@ -109,15 +109,19 @@ The batch launcher applies this; you do not sleep in the skill.
109
109
  When `agent_name` is set, the runner passes `--agent <name>`. Grok loads the
110
110
  named agent charter from the **user-level** Claude config home (`~/.claude/`):
111
111
 
112
- - `agents/` — agent definition files (for example `code-quality-agent.md`,
113
- `clean-coder.md`)
112
+ - `agents/` contains `poteto-agent.md`.
114
113
  - `skills/`, `rules/`, `hooks/` — the rest of the installed Claude config the
115
114
  grok CLI reads for that run
116
115
 
117
- Preflight role `bugteam` checks that `code-quality-agent.md` and
118
- `clean-coder.md` exist under `~/.claude/agents/` and that the
119
- `claude-dev-env` install manifest is present. Install or reinstall
120
- `claude-dev-env` before a fleet that relies on those agents.
116
+ Preflight checks the installed `poteto-agent.md`, the poteto skill,
117
+ and the `claude-dev-env` install manifest. `CLAUDE_CONFIG_DIR` selects the
118
+ configuration root when set. The runner includes the complete skill content
119
+ and its resolved source path in each `poteto-agent` prompt. The task brief
120
+ states the worker's duty and write permissions. The user pstack entry in
121
+ `plugins/installed_plugins.json` selects the skill source. Companion paths stay
122
+ relative to that source. Without a user pstack entry, the shared
123
+ `skills/poteto-mode/SKILL.md` path is supported. Invalid metadata or an unreadable
124
+ selected source fails the gate, even when a shared copy exists.
121
125
 
122
126
  Pass `agent_name: null` (or omit the field) when the worker should run without
123
127
  a named agent charter.
@@ -130,5 +134,5 @@ a named agent charter.
130
134
  |---|---|---|---|
131
135
  | Map call sites in-repo only | `readonly` | `true` | `null` or an audit agent |
132
136
  | Research that may need the web | `readonly` | `false` | `null` |
133
- | Closed edit + tests | `build` | ignored | often `clean-coder` |
134
- | Audit-style read under a charter | `readonly` | as needed | `code-quality-agent` |
137
+ | Closed edit + tests | `build` | ignored | often `poteto-agent` |
138
+ | Audit-style read under a charter | `readonly` | as needed | `poteto-agent` |
@@ -15,9 +15,9 @@ argument-hint: "[issue action - file | update | close | refresh-epic | full hand
15
15
 
16
16
  **dedup -> do the work -> markers only -> numbers + URLs**
17
17
 
18
- Run every step the ask needs in one go (file, label, attach, refresh, and so on). The `issue-tracker` agent is the primary handler for one action per turn; this skill is the session path when the agent is unavailable or the ask spans several steps.
18
+ Run every step the ask needs in one go (file, label, attach, refresh, and so on). `pstack:poteto-agent` is the primary handler for one action per turn when it loads this skill; this skill is the session path when the agent is unavailable or the ask spans several steps.
19
19
 
20
- Prefer the **same warm** `issue-tracker` agent for follow-ups on the same issue or a related issue on the same epic. Spawn a new agent only for an unrelated work-stream or when the warm agent is gone.
20
+ Prefer the **same warm** `pstack:poteto-agent` for follow-ups on the same issue or a related issue on the same epic. Spawn a new agent only for an unrelated work-stream or when the warm agent is gone.
21
21
 
22
22
  ## Voice
23
23
 
@@ -79,7 +79,7 @@ GitHub closes the sub-issue when someone **merges** a pull request into the **de
79
79
 
80
80
  **Preferred on commits:** also put `Closes #N` in the first commit message when the fix starts. Commit alone is backup; the PR body is the contract.
81
81
 
82
- **Stacked / intermediate PRs** that do not merge into the default branch: use a plain `#N` reference in the body so the issue links without a false close promise. Put `Closes #N` only on the PR that actually lands on the default branch.
82
+ **Stacked / intermediate PRs** that do not merge into the default branch: use a plain `#N` reference in the body so the issue links without a false close promise. Put `Closes #N` only on the PR that lands on the default branch.
83
83
 
84
84
  **Not enough:** a Development "related" link with no closing keyword. **Not enough:** closing the PR without merging.
85
85
 
@@ -24,7 +24,7 @@ than a solo frontier agent held to the same verification rigor, with
24
24
  84-98% of the team's input tokens billed at the worker rate.
25
25
 
26
26
  Under this skill the session is the orchestrator. It spawns and resumes
27
- executor subagents — `clean-coder` and the like — and those executors do
27
+ executor subagents through `pstack:poteto-agent`, and those executors do
28
28
  every bit of the execution: the code edits, the build runs, the test
29
29
  runs. The orchestrating session drives the plan, keeps the run artifacts
30
30
  and the ledger current, and answers executor consults. Hard questions
@@ -190,7 +190,7 @@ Return: status, artifact paths, blockers — nothing else.
190
190
  unit that fits one sentence plus pointers, has one mechanical
191
191
  done-check, and needs no mid-run clarification. A task that does not
192
192
  fit gets split in the plan — never padded into a longer prompt.
193
- Explore fan-outs run tiny; a `clean-coder` assignment can carry a
193
+ Explore fan-outs run tiny; a `pstack:poteto-agent` assignment can carry a
194
194
  whole scoped feature.
195
195
  - **Focused tickets are the house convention.** One mechanical done-check
196
196
  per ticket; thick context lives in the assignment file, not the ticket
@@ -204,10 +204,9 @@ Return: status, artifact paths, blockers — nothing else.
204
204
  - **Resume with a thin next-slice ticket.** A warm agent already holds
205
205
  the assignment's thick context, so its next ticket names only the next
206
206
  slice of work and the done-check — it does not restate the assignment.
207
- - **Do not restate what the agent definition carries.** The routing
208
- table picks the definition, and `clean-coder` already holds the code
209
- discipline. The ticket adds the task, the pointers, and the consult
210
- block only.
207
+ - **Keep the task brief specific.** The `pstack:poteto-agent` definition
208
+ carries poteto-mode style. The ticket adds the task, the pointers, the
209
+ task-specific instructions, and the consult block.
211
210
  - **The consult block is pasted, assembled text.** Assemble it at ticket
212
211
  write time from the parts in
213
212
  [`reference/executor-consult-block.md`](reference/executor-consult-block.md)
@@ -215,16 +214,15 @@ Return: status, artifact paths, blockers — nothing else.
215
214
 
216
215
  ## Workflow Agent Routing
217
216
 
218
- Every delegated task runs through a workflow-backed agent invocation. Do
219
- not spawn a flat subagent directly when a workflow invocation or
220
- workflow resume is available.
217
+ Every delegated task uses `pstack:poteto-agent` with a task-specific prompt.
218
+ Resume an existing agent when its context matches the task.
221
219
 
222
220
  | Work | Agent type | Model |
223
221
  |---|---|---|
224
- | Feature, bug, and refactor coding | `clean-coder` | `sonnet` on a Claude host; the sonnet-equivalent id the worker-model resolver prints on a third-party host |
225
- | Review and verification | `code-quality-agent` | `sonnet` on a Claude host; the sonnet-equivalent id the worker-model resolver prints on a third-party host |
226
- | Script runs, GitHub posting, and backfill driving | `general-purpose` runner | `sonnet` on a Claude host; the sonnet-equivalent id the worker-model resolver prints on a third-party host |
227
- | PR descriptions | `pr-description-writer` | `haiku`, with file-list grounding check |
222
+ | Feature, bug, and refactor coding | `pstack:poteto-agent` | `sonnet` on a Claude host; the sonnet-equivalent id the worker-model resolver prints on a third-party host |
223
+ | Review and verification | `pstack:poteto-agent` | `sonnet` on a Claude host; the sonnet-equivalent id the worker-model resolver prints on a third-party host |
224
+ | Script runs, GitHub posting, and backfill driving | `pstack:poteto-agent` with an execution brief | `sonnet` on a Claude host; the sonnet-equivalent id the worker-model resolver prints on a third-party host |
225
+ | PR descriptions | `pstack:poteto-agent` | `haiku`, with file-list grounding check |
228
226
  | Fan-out searches and checklist verification reads | `Explore` | `haiku`; use `sonnet` when judgment-heavy |
229
227
 
230
228
  Every row that edits code, runs a build, or runs a test is a coding row.
@@ -234,8 +232,8 @@ the worker model; the per-spawn `model:` field does.
234
232
 
235
233
  Routing rules:
236
234
 
237
- - Each row spawns workflow-backed with a ticket; the routing row and the
238
- ticket together carry the agent type, model, task, and return
235
+ - Each row spawns `pstack:poteto-agent` with a ticket; the routing row and
236
+ the ticket together carry the agent type, model, task, and return
239
237
  contract. A coding task category is never served by a different tier
240
238
  as a cost call — the table is the contract.
241
239
  - **Fail closed on a Claude host.** When `sonnet` cannot be spawned, use
@@ -255,8 +253,11 @@ Routing rules:
255
253
  detection system, with no second one.
256
254
  - Resume a warm workflow agent before creating a new workflow run when
257
255
  the warm agent holds the relevant context.
258
- - Review and verification workflows apply the [review guide](../reviews/SKILL.md#review-workflow).
259
- - PR-description workflows include the actual changed-file list in the
256
+ - When a native subagent spawn is the advisor path, set
257
+ `flags: ["--advisor"]` with the Astra model. This is the explicit hook
258
+ bypass for advisor work. Do not add the flag to worker spawns.
259
+ - Review and verification workflows apply the [review guide](../e-code-review/SKILL.md).
260
+ - PR-description workflows include the changed-file list in the
260
261
  prompt and verify the final body against that file list before posting
261
262
  or returning it.
262
263
  - Exploration workflows return file paths, line numbers, and direct
@@ -274,7 +275,7 @@ Routing rules:
274
275
  background spawn — keep the `agentId` (format `a...-...`) from the
275
276
  spawn result so `SendMessage` can reach that agent later.
276
277
  - **Spawn a fresh agent only when** no existing agent holds relevant
277
- context, or a genuine task switch needs a clean context.
278
+ context, or a task switch needs a clean context.
278
279
  - **Reuse is a cost rule, not a correctness dependency.** The run
279
280
  artifacts keep every executor replaceable (Run state section).
280
281
  - **Name the agent to resume.** When a PLAN from this session fits