claude-dev-env 2.9.0 → 2.11.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/CLAUDE.md +2 -2
- package/_shared/advisor/CLAUDE.md +3 -2
- package/_shared/advisor/advisor-protocol.md +74 -108
- package/_shared/advisor/reference/advisor-block.md +37 -0
- package/_shared/advisor/reference/cli-chain.md +45 -0
- package/_shared/advisor/reference/consult-format.md +41 -0
- package/_shared/advisor/reference/lifecycle.md +21 -0
- package/_shared/advisor/reference/sol-rung.md +31 -0
- package/_shared/advisor/reference/spawn-walk-log.md +31 -0
- package/_shared/advisor/reference/third-party-bind.md +30 -0
- package/_shared/advisor/reference/warm-up.md +33 -0
- package/_shared/advisor/scripts/codex_sol_advisor.py +449 -0
- package/_shared/advisor/scripts/config/advisor_scripts_constants/advisor_route_constants.py +21 -0
- package/_shared/advisor/scripts/config/advisor_scripts_constants/model_tier_run_validator_constants.py +19 -17
- package/_shared/advisor/scripts/config/advisor_scripts_constants/sol_advisor_constants.py +28 -0
- package/_shared/advisor/scripts/model_tier_run_validator.py +32 -9
- package/_shared/advisor/scripts/tests/test_codex_sol_advisor.py +474 -0
- package/_shared/advisor/scripts/tests/test_model_tier_run_validator.py +79 -0
- package/_shared/advisor/scripts/tests/test_tier_model_ids.py +39 -17
- package/_shared/advisor/scripts/tier_model_ids.py +24 -0
- package/_shared/pr-loop/CLAUDE.md +1 -1
- package/_shared/pr-loop/audit-contract.md +17 -6
- package/_shared/pr-loop/audit-reply-template.md +4 -4
- package/_shared/pr-loop/code-rules-gate.md +3 -5
- package/_shared/pr-loop/fix-protocol.md +2 -3
- package/_shared/pr-loop/gh-payloads.md +1 -1
- package/_shared/pr-loop/scripts/CLAUDE.md +1 -1
- package/_shared/pr-loop/scripts/README.md +1 -1
- package/_shared/pr-loop/scripts/code_rules_gate.py +2 -0
- package/_shared/pr-loop/scripts/code_rules_gate_parts/gate_running.py +16 -1
- package/_shared/pr-loop/scripts/code_rules_gate_parts/git_blob_readers.py +11 -5
- package/_shared/pr-loop/scripts/preflight.py +9 -4
- package/_shared/pr-loop/scripts/reviews_disabled.py +50 -22
- package/_shared/pr-loop/scripts/tests/conftest.py +20 -0
- package/_shared/pr-loop/scripts/tests/test_claude_permissions_common.py +6 -6
- package/_shared/pr-loop/scripts/tests/test_reviews_disabled.py +50 -6
- package/_shared/pr-loop/scripts/tests/test_revoke_project_claude_permissions.py +1 -1
- package/_shared/pr-loop/state-schema.md +5 -14
- package/agents/CLAUDE.md +2 -2
- package/agents/clean-coder.md +58 -548
- package/agents/code-quality-agent.md +10 -2
- package/agents/code-verifier.md +1 -1
- package/agents/test_agent_frontmatter.py +32 -40
- package/audit-rubrics/CLAUDE.md +2 -1
- package/audit-rubrics/audit-categories.json +704 -0
- package/audit-rubrics/prompts/category-i-concurrency.md +1 -1
- package/bin/CLAUDE.md +16 -5
- package/bin/ever-shipped-skills.mjs +2 -0
- package/bin/install-plan.mjs +402 -0
- package/bin/install-transaction.mjs +455 -0
- package/bin/install.mjs +593 -147
- package/bin/install.plan.test.mjs +194 -0
- package/bin/install.profile-root.test.mjs +154 -0
- package/bin/install.profiles.test.mjs +253 -0
- package/bin/install.settings-defaults.test.mjs +200 -0
- package/bin/install.transaction.test.mjs +400 -0
- package/bin/install.uninstall-transaction.test.mjs +418 -0
- package/bin/merge_managed_permissions.mjs +130 -0
- package/bin/resolve-install-root.mjs +181 -0
- package/bin/select-install-targets.mjs +401 -0
- package/commands/CLAUDE.md +0 -2
- package/docs/references/CLAUDE.md +3 -1
- package/docs/references/advisor-tool.md +25 -7
- package/docs/references/prose-style-enforcement.md +25 -0
- package/docs/references/team-advisor-skill.md +3 -3
- package/docs/references/weak-executor-advisor.md +91 -0
- package/hooks/blocking/CLAUDE.md +6 -6
- package/hooks/blocking/_path_setup.py +9 -5
- package/hooks/blocking/code_rules_docstrings.py +124 -30
- package/hooks/blocking/code_rules_enforcer.py +161 -16
- package/hooks/blocking/code_rules_shared.py +40 -23
- package/hooks/blocking/config/CLAUDE.md +3 -5
- package/hooks/blocking/config/prose_style_enforcement_constants.py +38 -0
- package/hooks/blocking/config/test_prose_style_enforcement_constants.py +45 -0
- package/hooks/blocking/eli11_reply_enforcer.py +70 -113
- package/hooks/blocking/hedging_language_blocker.py +103 -20
- package/hooks/blocking/hook_prose_detector_consistency.py +6 -0
- package/hooks/blocking/intent_only_ending_blocker.py +6 -0
- package/hooks/blocking/plain_language_blocker.py +139 -20
- package/hooks/blocking/pre_tool_use_dispatcher.py +102 -20
- package/hooks/blocking/state_description_blocker.py +7 -1
- package/hooks/blocking/tdd_enforcer.py +8 -0
- package/hooks/blocking/test__path_setup.py +28 -0
- package/hooks/blocking/test_code_rules_enforcer_agent_home_tooling.py +99 -0
- package/hooks/blocking/test_code_rules_enforcer_docstring_args_span_scope.py +232 -10
- package/hooks/blocking/test_code_rules_enforcer_ephemeral.py +1 -1
- package/hooks/blocking/test_code_rules_enforcer_join_separator_magic.py +41 -0
- package/hooks/blocking/test_code_rules_enforcer_string_magic.py +98 -0
- package/hooks/blocking/test_eli11_reply_enforcer.py +98 -165
- package/hooks/blocking/test_fable_spawn_gate.py +18 -11
- package/hooks/blocking/test_hedging_language_blocker.py +120 -1
- package/hooks/blocking/test_hook_prose_detector_consistency.py +28 -8
- package/hooks/blocking/test_intent_only_ending_blocker.py +27 -2
- package/hooks/blocking/test_package_inventory_stale_blocker.py +11 -4
- package/hooks/blocking/test_plain_language_blocker.py +129 -19
- package/hooks/blocking/test_plain_language_blocker_allowlist.py +70 -26
- package/hooks/blocking/test_pre_tool_use_dispatcher.py +99 -26
- package/hooks/blocking/test_pre_tool_use_dispatcher_native.py +87 -50
- package/hooks/blocking/test_state_description_blocker.py +45 -2
- package/hooks/blocking/test_stop_dispatcher.py +11 -7
- package/hooks/blocking/test_volatile_path_in_post_blocker.py +12 -12
- package/hooks/blocking/volatile_path_in_post_blocker.py +2 -2
- package/hooks/hooks.json +15 -0
- package/hooks/hooks_constants/CLAUDE.md +14 -3
- package/hooks/hooks_constants/ask_user_question_shape.py +281 -0
- package/hooks/hooks_constants/code_rules_enforcer_constants.py +2 -1
- package/hooks/hooks_constants/eli11_reply_enforcer_constants.py +5 -12
- package/hooks/hooks_constants/hedging_uncertainty_constants.py +42 -0
- package/hooks/hooks_constants/issue_tracker_session_starter_constants.py +23 -0
- package/hooks/hooks_constants/orchestrator_auto_starter_constants.py +23 -0
- package/hooks/hooks_constants/piped_pytest_blocker_constants.py +4 -1
- package/hooks/hooks_constants/plain_language_blocker_constants.py +4 -1
- package/hooks/hooks_constants/pre_tool_use_dispatcher_constants.py +6 -0
- package/hooks/hooks_constants/project_paths_reader.py +31 -4
- package/hooks/hooks_constants/prose_matcher_precision_constants.py +40 -0
- package/hooks/hooks_constants/pytest_invocation.py +354 -0
- package/hooks/hooks_constants/session_start_injector.py +163 -0
- package/hooks/hooks_constants/session_start_injector_constants.py +46 -0
- package/hooks/hooks_constants/shell_command_pipeline.py +397 -0
- package/hooks/hooks_constants/shell_command_segments.py +5 -0
- package/hooks/hooks_constants/test_ask_user_question_shape.py +167 -0
- package/hooks/hooks_constants/test_project_paths_reader.py +29 -0
- package/hooks/hooks_constants/test_prose_metrics_parity.py +8 -0
- package/hooks/hooks_constants/test_pytest_invocation.py +130 -0
- package/hooks/hooks_constants/test_session_start_injector.py +168 -0
- package/hooks/hooks_constants/test_shell_command_pipeline.py +135 -0
- package/hooks/hooks_constants/volatile_path_in_post_blocker_constants.py +1 -1
- package/hooks/hooks_constants/working_style_prompt_constants.py +30 -0
- package/hooks/observability/CLAUDE.md +2 -0
- package/hooks/observability/prose_matcher_advisory.py +237 -0
- package/hooks/observability/test_prose_matcher_advisory.py +143 -0
- package/hooks/session/CLAUDE.md +9 -1
- package/hooks/session/_path_setup.py +13 -0
- package/hooks/session/issue_tracker_session_starter.py +135 -0
- package/hooks/session/orchestrator_auto_starter.py +100 -0
- package/hooks/session/test__path_setup.py +28 -0
- package/hooks/session/test_issue_tracker_session_starter.py +104 -0
- package/hooks/session/test_orchestrator_auto_starter.py +99 -0
- package/hooks/session/test_working_style_prompt.py +47 -0
- package/hooks/session/untracked_repo_detector.py +1 -24
- package/hooks/session/working_style_prompt.py +36 -0
- package/hooks/validators/_path_setup.py +19 -0
- package/hooks/validators/run_all_validators.py +8 -13
- package/installable-surfaces.manifest.json +21 -0
- package/output-styles/CLAUDE.md +1 -3
- package/package.json +4 -2
- package/rules/CLAUDE.md +1 -0
- package/rules/durable-post-artifacts.md +2 -2
- package/rules/eli11-replies.md +6 -1
- package/rules/hedging-claims.md +4 -2
- package/rules/long-horizon-autonomy.md +3 -1
- package/rules/opus5-communication-contract.md +45 -0
- package/rules/plain-language.md +2 -2
- package/rules/research-mode.md +1 -1
- package/scripts/CLAUDE.md +11 -0
- package/scripts/Sync-RepoMain.ps1 +215 -0
- package/scripts/active_capability_references.py +218 -0
- package/scripts/ci/windows-installer-lifecycle.ps1 +78 -0
- package/scripts/claude_chain_runner.py +394 -6
- package/scripts/claude_chain_usage.py +1 -1
- package/scripts/codex_compat_materializer.py +105 -85
- package/scripts/dev_env_scripts_constants/CLAUDE.md +2 -0
- package/scripts/dev_env_scripts_constants/active_capability_constants.py +46 -0
- package/scripts/dev_env_scripts_constants/claude_chain_constants.py +74 -0
- package/scripts/dev_env_scripts_constants/verify_installable_package_constants.py +116 -0
- package/scripts/profile-isolation-launchers/config/mcp-bundles.json +25 -0
- package/scripts/profile-isolation-launchers/config/profile-isolation-constants.mjs +60 -0
- package/scripts/profile-isolation-launchers/config/profiles.manifest.json +54 -0
- package/scripts/profile-isolation-launchers/config/shared-allowlist.json +64 -0
- package/scripts/profile-isolation-launchers/launcher-runtime.mjs +180 -0
- package/scripts/profile-isolation-launchers/lib/profile-manifest.mjs +288 -0
- package/scripts/profile-isolation-launchers/mcp-bundles.mjs +275 -0
- package/scripts/profile-isolation-launchers/profile-isolation-contract.test.mjs +221 -0
- package/scripts/profile-isolation-launchers/tests/launcher-runtime.test.mjs +108 -0
- package/scripts/profile-isolation-launchers/tests/mcp-bundles.test.mjs +147 -0
- package/scripts/profile-isolation-launchers/tests/shortcut-contract.test.ps1 +102 -0
- package/scripts/profile-isolation-launchers/tests/version-compatibility.test.mjs +210 -0
- package/scripts/profile-isolation-launchers/version-compatibility.mjs +299 -0
- package/scripts/profile-isolation-launchers/windows/shortcut-inventory.ps1 +127 -0
- package/scripts/profile-isolation-launchers/windows/shortcut-manifest.json +51 -0
- package/scripts/profile-isolation-launchers/windows/shortcut-reconcile.ps1 +77 -0
- package/scripts/spawn_grok_batch.py +3 -0
- package/scripts/test_active_capability_references.py +108 -0
- package/scripts/test_claude_chain_runner.py +414 -82
- package/scripts/test_claude_chain_usage.py +12 -12
- package/scripts/test_resolve_worker_spawn.py +2 -2
- package/scripts/test_verify_installable_package.py +208 -0
- package/scripts/tests/test_codex_compat_materializer.py +33 -0
- package/scripts/verify_installable_package.py +612 -0
- package/settings.json +10 -0
- package/skills/CLAUDE.md +2 -0
- package/skills/_shared/advisor/CLAUDE.md +1 -1
- package/skills/_shared/advisor/scripts/README.md +2 -0
- package/skills/_shared/pr-loop/scripts/CLAUDE.md +1 -0
- package/skills/_shared/pr-loop/scripts/audit_category_schema.py +355 -0
- package/skills/_shared/pr-loop/scripts/skills_pr_loop_constants/CLAUDE.md +1 -0
- package/skills/_shared/pr-loop/scripts/skills_pr_loop_constants/audit_category_schema_constants.py +32 -0
- package/skills/_shared/pr-loop/scripts/skills_pr_loop_constants/path_resolver_constants.py +7 -19
- package/skills/_shared/pr-loop/scripts/test_audit_category_schema.py +94 -0
- package/skills/_shared/pr-loop/scripts/test_build_audit_prompt.py +21 -0
- package/skills/autoconverge/reference/convergence.md +2 -1
- package/skills/autoconverge/reference/stop-conditions.md +5 -3
- package/skills/beat-sheet/SKILL.md +54 -0
- package/skills/beat-sheet/reference/visual-beats.md +29 -0
- package/skills/bugteam/CONSTRAINTS.md +4 -4
- package/skills/bugteam/EXAMPLES.md +1 -1
- package/skills/bugteam/reference/README.md +1 -1
- package/skills/e-code-review/SKILL.md +26 -5
- package/skills/e-code-review/reference/effort-evaluation.md +35 -0
- package/skills/e-code-review/reference/medium.md +15 -4
- package/skills/e-code-review/scripts/config/e_code_review_effort_constants/__init__.py +41 -0
- package/skills/e-code-review/scripts/config/e_code_review_effort_constants/effort_constants.py +40 -0
- package/skills/e-code-review/scripts/e_code_review_scripts_constants/finding_pipeline_constants.py +49 -0
- package/skills/e-code-review/scripts/effort_defaults_evidence.json +186 -0
- package/skills/e-code-review/scripts/effort_evaluation.py +362 -0
- package/skills/e-code-review/scripts/finding_pipeline.py +140 -0
- package/skills/e-code-review/scripts/fixtures/demanding.json +26 -0
- package/skills/e-code-review/scripts/fixtures/easy.json +14 -0
- package/skills/e-code-review/scripts/fixtures/medium.json +20 -0
- package/skills/e-code-review/scripts/grok_code_review.py +16 -7
- package/skills/e-code-review/scripts/test_effort_evaluation.py +180 -0
- package/skills/e-code-review/scripts/test_finding_pipeline.py +197 -0
- package/skills/e-code-review/scripts/test_grok_code_review.py +77 -0
- package/skills/grokify/SKILL.md +1 -1
- package/skills/grokify/templates/handoff-template.md +2 -2
- package/skills/orchestrator/SKILL.md +5 -4
- package/skills/plan-to-pr/scripts/create_packet.py +4 -4
- package/skills/plan-to-pr/scripts/load_skill_constants.py +41 -0
- package/skills/plan-to-pr/scripts/validate_packet.py +4 -4
- package/skills/plan-to-pr/scripts/validate_protocol.py +4 -1
- package/skills/plan-to-pr/scripts/validate_run.py +4 -1
- package/skills/pr-converge/scripts/check_convergence.py +21 -19
- package/skills/pr-converge/scripts/check_convergence_availability.py +50 -7
- package/skills/pr-converge/scripts/conftest.py +35 -0
- package/skills/pr-converge/scripts/test_check_convergence_availability.py +65 -0
- package/skills/pr-converge/scripts/test_check_convergence_codex.py +11 -1
- package/skills/pr-converge/scripts/test_check_convergence_contract.py +9 -2
- package/skills/pr-loop-cloud-transport/SKILL.md +1 -1
- package/skills/rebase/SKILL.md +15 -3
- package/skills/reviewer-gates/SKILL.md +2 -2
- package/skills/show/SKILL.md +51 -0
- package/skills/show/references/accessibility.md +7 -0
- package/skills/show/references/art.md +3 -0
- package/skills/show/references/charts.md +3 -0
- package/skills/show/references/core-design.md +14 -0
- package/skills/show/references/erds.md +3 -0
- package/skills/show/references/flowcharts.md +3 -0
- package/skills/show/references/host-and-html.md +3 -0
- package/skills/show/references/illustrative-diagrams.md +10 -0
- package/skills/show/references/interaction.md +3 -0
- package/skills/show/references/mockups.md +3 -0
- package/skills/show/references/quality-gates.md +7 -0
- package/skills/show/references/structural-diagrams.md +3 -0
- package/skills/show/references/subject-inventory.md +21 -0
- package/skills/show/references/svg-contract.md +22 -0
- package/skills/show/routing.yaml +30 -0
- package/skills/show/samples/pr1262-v2.svg +222 -0
- package/skills/show/scripts/README.md +6 -0
- package/skills/show/scripts/validate-artifact.py +91 -0
- package/skills/show/scripts/validate-package.py +18 -0
- package/skills/show/templates/html-widget.html +4 -0
- package/skills/show/templates/svg-base.svg +19 -0
- package/skills/show/tests/fixtures/css-var.svg +6 -0
- package/skills/show/tests/fixtures/dead-ref.svg +7 -0
- package/skills/show/tests/fixtures/filled-glyph.svg +8 -0
- package/skills/show/tests/fixtures/inherited-fill.svg +18 -0
- package/skills/show/tests/fixtures/invalid.svg +1 -0
- package/skills/show/tests/fixtures/large-canvas.svg +21 -0
- package/skills/show/tests/fixtures/unfilled-connector.svg +15 -0
- package/skills/show/tests/fixtures/valid.html +1 -0
- package/skills/show/tests/test_validate-artifact.py +74 -0
- package/skills/show/tests/test_validators.py +59 -0
- package/skills/show/workflows/create-visual.md +13 -0
- package/skills/show/workflows/review-visual.md +20 -0
- package/skills/split-pr/SKILL.md +85 -0
- package/skills/split-pr/reference/path-layers.md +16 -0
- package/skills/split-pr/reference/proposal-format.md +15 -0
- package/skills/split-pr/reference/split-further-loop.md +10 -0
- package/skills/split-pr/reference/splitting-principles.md +26 -0
- package/skills/split-pr/scripts/analyze_pr.py +279 -0
- package/skills/split-pr/scripts/categorize_files.py +106 -0
- package/skills/split-pr/scripts/config/__init__.py +1 -0
- package/skills/split-pr/scripts/config/dependency_constants.py +14 -0
- package/skills/split-pr/scripts/config/git_operations_constants.py +36 -0
- package/skills/split-pr/scripts/config/packing_constants.py +61 -0
- package/skills/split-pr/scripts/config/plan_constants.py +49 -0
- package/skills/split-pr/scripts/config/split_pr_constants.py +110 -0
- package/skills/split-pr/scripts/execute_split_slices.py +82 -0
- package/skills/split-pr/scripts/pack_files_into_slices.py +212 -0
- package/skills/split-pr/scripts/split_pr_dependency_graph.py +70 -0
- package/skills/split-pr/scripts/split_pr_git_operations.py +184 -0
- package/skills/split-pr/scripts/split_pr_layer_order.py +58 -0
- package/skills/split-pr/scripts/split_pr_paginate.py +119 -0
- package/skills/split-pr/scripts/split_pr_process_runner.py +52 -0
- package/skills/split-pr/scripts/split_pr_script_types.py +126 -0
- package/skills/split-pr/scripts/split_pr_title.py +41 -0
- package/skills/split-pr/scripts/test_analyze_pr.py +228 -0
- package/skills/split-pr/scripts/test_categorize_files.py +55 -0
- package/skills/split-pr/scripts/test_categorize_files_packing.py +59 -0
- package/skills/split-pr/scripts/test_execute_split_slices.py +99 -0
- package/skills/split-pr/scripts/test_split_pr_dependency_graph.py +47 -0
- package/skills/split-pr/scripts/test_split_pr_git_operations.py +125 -0
- package/skills/split-pr/scripts/test_split_pr_layer_order.py +36 -0
- package/skills/split-pr/scripts/test_split_pr_paginate.py +65 -0
- package/skills/split-pr/scripts/test_split_pr_script_types.py +73 -0
- package/skills/split-pr/scripts/test_split_pr_title.py +28 -0
- package/skills/split-pr/scripts/test_verify_dependency_graph.py +46 -0
- package/skills/split-pr/scripts/test_verify_plan.py +56 -0
- package/skills/split-pr/scripts/test_verify_plan_contract.py +50 -0
- package/skills/split-pr/scripts/test_verify_plan_path_normalization.py +45 -0
- package/skills/split-pr/scripts/verify_dependency_graph.py +111 -0
- package/skills/split-pr/scripts/verify_plan.py +139 -0
- package/skills/team-advisor/SKILL.md +7 -4
- package/skills/team-advisor/reference/advisor-docs-review.md +207 -0
- package/system-prompts/software-engineer.xml +11 -2
- package/commands/initialize.md +0 -90
- package/commands/stubcheck.md +0 -88
- package/output-styles/caveman-agent.md +0 -37
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
# Advisor-Tool Documentation Review
|
|
2
|
+
|
|
3
|
+
Distilled facts from the Anthropic advisor-tool documentation, for the
|
|
4
|
+
Sonnet-executor advisor path and the hand-rolled `/team-advisor` bind. Every
|
|
5
|
+
source claim below cites its page; section H is repository practice and says
|
|
6
|
+
so.
|
|
7
|
+
|
|
8
|
+
Consult timing, the hard rule before a first write, and how to weigh the
|
|
9
|
+
advice live in [`docs/references/advisor-tool.md`](../../../docs/references/advisor-tool.md).
|
|
10
|
+
The consult cadence lives in [`SKILL.md`](../SKILL.md). This file carries the
|
|
11
|
+
source facts those two omit: measured effects, Sonnet steering, cost levers,
|
|
12
|
+
failure modes, and what transfers to a hand-rolled bind.
|
|
13
|
+
|
|
14
|
+
## Sources
|
|
15
|
+
|
|
16
|
+
| # | Page |
|
|
17
|
+
|---|---|
|
|
18
|
+
| 1 | [Advisor tool — platform docs](https://platform.claude.com/docs/en/agents-and-tools/tool-use/advisor-tool) |
|
|
19
|
+
| 2 | [Escalate hard decisions with the advisor tool — Claude Code](https://code.claude.com/docs/en/advisor) |
|
|
20
|
+
| 3 | [The advisor strategy — blog](https://claude.com/blog/the-advisor-strategy) |
|
|
21
|
+
| 4 | [Best practices for computer and browser use — blog](https://claude.com/blog/best-practices-for-computer-and-browser-use-with-claude) |
|
|
22
|
+
| 5 | [Claude models explained — blog](https://claude.com/blog/claude-models-explained-choosing-the-best-model-for-your-use-case) |
|
|
23
|
+
| 6 | [Messages API — beta](https://platform.claude.com/docs/en/api/beta/messages) |
|
|
24
|
+
| 7 | [Claude Code changelog](https://code.claude.com/docs/en/changelog) |
|
|
25
|
+
|
|
26
|
+
## A. Consult timing the canonical rules omit
|
|
27
|
+
|
|
28
|
+
Planner funnel, page 1:
|
|
29
|
+
|
|
30
|
+
```text
|
|
31
|
+
If your agent exposes other planner-like tools (for example, a todo list
|
|
32
|
+
tool), prompt the model to call the advisor before those tools so the
|
|
33
|
+
advisor's plan funnels into them.
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Consult moments for long agent runs, page 4: "choosing which tab to open,
|
|
37
|
+
recovering from an unexpected modal, deciding whether to abandon a strategy".
|
|
38
|
+
|
|
39
|
+
Frequency control stays prompt-only, page 2:
|
|
40
|
+
|
|
41
|
+
```text
|
|
42
|
+
There is no setting to cap or force advisor calls; if you want Claude to
|
|
43
|
+
consult more or less often during a task, say so in your instructions.
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## B. Measured effect of the hard rule
|
|
47
|
+
|
|
48
|
+
The rule itself — an advisor call before the first write, edit, or
|
|
49
|
+
state-changing shell call — lives under **Hard rule** in
|
|
50
|
+
[`advisor-tool.md`](../../../docs/references/advisor-tool.md). Page 1 states
|
|
51
|
+
it inside the Haiku and Opus system-prompt blocks and reports its effect:
|
|
52
|
+
the Haiku coding block raises pass rates by roughly 7.5 points on an
|
|
53
|
+
internal coding benchmark. On Opus the same checkpoint raises
|
|
54
|
+
under-calling tasks 7–10 points and holds roughly flat on a mixed workload
|
|
55
|
+
where plan-free tasks over-call.
|
|
56
|
+
|
|
57
|
+
## C. Sonnet-executor facts
|
|
58
|
+
|
|
59
|
+
Page 1 marks the startup nudge as dead weight on Sonnet:
|
|
60
|
+
|
|
61
|
+
```text
|
|
62
|
+
On Sonnet executors, the plain-text nudge had no measurable effect in
|
|
63
|
+
Anthropic's testing.
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Steering for a Sonnet executor belongs in the system prompt, prepended
|
|
67
|
+
"before any other sentences that mention the advisor" (page 1).
|
|
68
|
+
|
|
69
|
+
Page 4 names a long-session gap: the executor does not always remember the
|
|
70
|
+
advisor exists on long-horizon tasks; the tested pattern is a one-line
|
|
71
|
+
reminder after roughly 20 advisor-free turns.
|
|
72
|
+
|
|
73
|
+
Named pairing, page 1:
|
|
74
|
+
|
|
75
|
+
```text
|
|
76
|
+
You currently use Sonnet on complex tasks: Add a higher-tier advisor. Opus
|
|
77
|
+
keeps total cost similar or lower; Claude Fable 5 maximizes the quality lift.
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Effort pairing, page 1:
|
|
81
|
+
|
|
82
|
+
```text
|
|
83
|
+
For coding tasks, pairing a Sonnet executor at medium effort with an Opus
|
|
84
|
+
advisor achieves intelligence comparable to Sonnet at default effort, at
|
|
85
|
+
lower cost. For maximum intelligence, keep the executor at default effort.
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
Page 3 footnotes the benchmark condition: the Sonnet-plus-advisor SWE-bench
|
|
89
|
+
Multilingual run uses the suggested system prompt "with thinking turned
|
|
90
|
+
off" — a consult substitutes for extended thinking in that run.
|
|
91
|
+
|
|
92
|
+
## D. Benchmarks
|
|
93
|
+
|
|
94
|
+
Page 3 and page 5 report these results:
|
|
95
|
+
|
|
96
|
+
- Sonnet 4.6 with an Opus 4.6 advisor: +2.7 points on SWE-bench Multilingual
|
|
97
|
+
over Sonnet solo, cost per agentic task down 11.9%.
|
|
98
|
+
- Haiku 4.5 with an Opus advisor on BrowseComp: 41.2% versus 19.7% solo;
|
|
99
|
+
trails Sonnet solo by 29% in score at 85% lower cost per task.
|
|
100
|
+
- Sonnet 5 with a Fable 5 advisor (page 5): within 10% of Fable 5's own score
|
|
101
|
+
at 63% of the price of running Fable 5 for the whole task, on SWE-bench
|
|
102
|
+
Pro.
|
|
103
|
+
|
|
104
|
+
Advisor reply shape, page 3:
|
|
105
|
+
|
|
106
|
+
```text
|
|
107
|
+
Opus accesses the shared context and returns a plan, a correction, or a stop
|
|
108
|
+
signal, and the executor resumes. The advisor never calls tools or produces
|
|
109
|
+
user-facing output.
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
## E. Cost levers
|
|
113
|
+
|
|
114
|
+
Output size is the advisor's largest cost driver; the top-level `max_tokens`
|
|
115
|
+
parameter does not bound it (pages 1, 4, 6). A tool-definition
|
|
116
|
+
`max_tokens: 2048` cuts mean advisor output roughly 7x with near-zero
|
|
117
|
+
truncation; `1024` cuts roughly 10x and truncates about 10% of calls. The
|
|
118
|
+
server passes the advisor its remaining budget, so the advisor self-shapes
|
|
119
|
+
its reply length.
|
|
120
|
+
|
|
121
|
+
The brevity line belongs in the user message and addresses the advisor
|
|
122
|
+
directly; the wording lives under **Brevity cue** in
|
|
123
|
+
[`advisor-tool.md`](../../../docs/references/advisor-tool.md).
|
|
124
|
+
|
|
125
|
+
Direct address works because the advisor reads the executor's prompt as
|
|
126
|
+
quoted context: "instructions that address the advisor directly are followed
|
|
127
|
+
much more reliably than third-person descriptions." A brief that asks for
|
|
128
|
+
roughly 80 percent of the true ceiling raises consult frequency while
|
|
129
|
+
lowering total cost.
|
|
130
|
+
|
|
131
|
+
Typical advisor output runs 400–700 text tokens, or 1,400–1,800 with
|
|
132
|
+
thinking included.
|
|
133
|
+
|
|
134
|
+
Advisor-side caching breaks even at roughly three consults per conversation;
|
|
135
|
+
set it once and leave it. A `clear_thinking` setting with `keep` other than
|
|
136
|
+
`"all"` shifts the advisor's quoted transcript and causes advisor-side cache
|
|
137
|
+
misses.
|
|
138
|
+
|
|
139
|
+
`max_uses` caps consults per request; Anthropic's launch example sets
|
|
140
|
+
`max_uses: 3`. Conversation-level caps count client-side; dropping the tool
|
|
141
|
+
requires stripping every `advisor_tool_result` block from history, or the API
|
|
142
|
+
returns 400.
|
|
143
|
+
|
|
144
|
+
## F. Failure modes and API mechanics
|
|
145
|
+
|
|
146
|
+
Error codes the advisor call surfaces (pages 1, 6): `max_uses_exceeded`,
|
|
147
|
+
`too_many_requests`, `overloaded`, `prompt_too_long`,
|
|
148
|
+
`execution_time_exceeded`, `unavailable`, `model_not_found`.
|
|
149
|
+
|
|
150
|
+
```text
|
|
151
|
+
The executor sees the error and continues without further advice. The
|
|
152
|
+
request itself does not fail.
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
The advisor runs without tools and without context management; thinking
|
|
156
|
+
blocks are dropped, and only advice text returns. On the server side,
|
|
157
|
+
nothing the executor puts in `input` reaches the advisor — the server
|
|
158
|
+
forwards the full transcript itself.
|
|
159
|
+
|
|
160
|
+
Fable, Opus 5, and Mythos advisors return `advisor_redacted_result`
|
|
161
|
+
(encrypted, round-trips verbatim). Opus 4.8 and below return plaintext
|
|
162
|
+
`advisor_result`. A native Fable-class advisor's encrypted block carries no
|
|
163
|
+
guidance the client can read; when logging or auditing the guidance matters,
|
|
164
|
+
pick a plaintext-returning advisor — the hand-rolled CLI and warm-agent
|
|
165
|
+
paths always yield a readable transcript.
|
|
166
|
+
|
|
167
|
+
Pairing invariant: "The advisor must be at least as capable as the
|
|
168
|
+
executor." Claude Code enforces the same check per subagent — subagents
|
|
169
|
+
inherit the configured advisor and apply the same pairing check against
|
|
170
|
+
their own model.
|
|
171
|
+
|
|
172
|
+
The native advisor is a server tool with no name a permission rule or hook
|
|
173
|
+
matcher can reference, so it bypasses hooks. The bind this skill uses lives
|
|
174
|
+
in [`SKILL.md`](../SKILL.md) **Bind**.
|
|
175
|
+
|
|
176
|
+
Consults run slow enough to look like stalls: changelog 2.1.214 (page 7)
|
|
177
|
+
fixes a spurious "check your network" warning that appeared while the
|
|
178
|
+
advisor was thinking.
|
|
179
|
+
|
|
180
|
+
Usage accounting: each consult is an `advisor_message` entry in
|
|
181
|
+
`usage.iterations[]` with its own model and token counts, billed at advisor
|
|
182
|
+
rates.
|
|
183
|
+
|
|
184
|
+
## G. What transfers to the hand-rolled advisor path
|
|
185
|
+
|
|
186
|
+
The claude-dev-env advisor is a warm agent or CLI session. Three inversions
|
|
187
|
+
apply against the native server tool:
|
|
188
|
+
|
|
189
|
+
1. **Context forwarding is manual.** The native tool auto-forwards the full
|
|
190
|
+
transcript. Everything a hand-rolled advisor sees arrives in the consult.
|
|
191
|
+
Build the first packet with
|
|
192
|
+
[`_shared/advisor/reference/consult-format.md`](../../../_shared/advisor/reference/consult-format.md);
|
|
193
|
+
later consults carry only the delta.
|
|
194
|
+
2. **Caching becomes prefix stability.** The charter and role text stay
|
|
195
|
+
byte-stable at the top of the consult stream; volatile detail goes last.
|
|
196
|
+
3. **Hooks apply.** Consult payloads travel through ordinary tools, so each
|
|
197
|
+
payload stays hook-safe and the bind log is mechanically validated.
|
|
198
|
+
|
|
199
|
+
## H. Measuring the advisor's lift
|
|
200
|
+
|
|
201
|
+
Repository practice, sourced to no page: benchmark three routes on one
|
|
202
|
+
representative workload — the executor alone, the executor plus advisor, and
|
|
203
|
+
the strongest model throughout. Route future work by measured cost per
|
|
204
|
+
successful task.
|
|
205
|
+
|
|
206
|
+
Track, per route: completion rate, regression rate, tool calls, tokens by
|
|
207
|
+
tier, and latency.
|
|
@@ -28,8 +28,8 @@
|
|
|
28
28
|
Lead every response with the direct answer or result. Open with the substance — the
|
|
29
29
|
conclusion, the fix, the decision — before any supporting context or explanation. Expand
|
|
30
30
|
depth in proportion to the complexity of the ask: a direct question earns a sentence; a
|
|
31
|
-
multi-file investigation
|
|
32
|
-
reply-length cap is wrong.
|
|
31
|
+
multi-file investigation or requested full audit earns structured explanation long enough
|
|
32
|
+
to cover the substance. Depth scales with the ask; a fixed reply-length cap is wrong.
|
|
33
33
|
|
|
34
34
|
Reference specific code locations using the pattern `file_path:line_number` so the user can
|
|
35
35
|
navigate directly to the source.
|
|
@@ -381,6 +381,15 @@
|
|
|
381
381
|
work around tool limitations — are removed when the task is done.
|
|
382
382
|
</cleanup>
|
|
383
383
|
|
|
384
|
+
<communication_contract>
|
|
385
|
+
Visible output is concise by default. The first progress update is one sentence.
|
|
386
|
+
Later updates mark only important discoveries or direction changes. The final
|
|
387
|
+
response begins with the outcome. When thinking is disabled, speak one brief
|
|
388
|
+
natural-language sentence before a tool call that needs context, state when no
|
|
389
|
+
fitting tool exists, and never emit internal-system XML in visible output.
|
|
390
|
+
Full contract: rules/opus5-communication-contract.md (opus5-communication-contract-v1).
|
|
391
|
+
</communication_contract>
|
|
392
|
+
|
|
384
393
|
<help_and_feedback>
|
|
385
394
|
When the user asks for help with this tool or wants to report a problem:
|
|
386
395
|
- For usage help, direct them to: /help
|
package/commands/initialize.md
DELETED
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
# Initialize Session
|
|
2
|
-
|
|
3
|
-
You are starting a new task. Before proceeding, you MUST read and internalize the critical protocols from CLAUDE.md.
|
|
4
|
-
|
|
5
|
-
## MANDATORY PROTOCOL REVIEW
|
|
6
|
-
|
|
7
|
-
Read CLAUDE.md now and focus on:
|
|
8
|
-
|
|
9
|
-
### 1. AGENT-FIRST WORKFLOW (CRITICAL)
|
|
10
|
-
|
|
11
|
-
**BEFORE RESPONDING TO ANY USER MESSAGE:**
|
|
12
|
-
- ☐ What is the user asking for?
|
|
13
|
-
- ☐ Does ANY agent match this request?
|
|
14
|
-
- ☐ If yes → INVOKE THE AGENT via Task tool
|
|
15
|
-
- ☐ If no agent matches → Proceed with skills/direct implementation
|
|
16
|
-
|
|
17
|
-
**Agent Decision Tree:**
|
|
18
|
-
- Automation work → check available agents for automation patterns
|
|
19
|
-
- Web App Development → check available agents for framework-specific patterns
|
|
20
|
-
|
|
21
|
-
**Never skip agent check to "save time" or because request "seems simple"**
|
|
22
|
-
|
|
23
|
-
### 2. SKILLS WORKFLOW (CRITICAL)
|
|
24
|
-
|
|
25
|
-
**Before ANY task:**
|
|
26
|
-
- ☐ List available skills in your mind
|
|
27
|
-
- ☐ Does ANY skill match this request?
|
|
28
|
-
- ☐ If yes → Use Skill tool to read and run it
|
|
29
|
-
- ☐ Announce which skill you're using
|
|
30
|
-
- ☐ Follow the skill exactly
|
|
31
|
-
|
|
32
|
-
**Mandatory skills to remember:**
|
|
33
|
-
- `code-standards` - For ALL code generation, planning, implementation
|
|
34
|
-
- `superpowers:test-driven-development` - For ANY feature/bugfix
|
|
35
|
-
- `superpowers:brainstorming` - BEFORE coding on design tasks
|
|
36
|
-
- `superpowers:systematic-debugging` - For bugs/failures
|
|
37
|
-
- `superpowers:verification-before-completion` - Before claiming work is done
|
|
38
|
-
|
|
39
|
-
### 3. TDD IS NON-NEGOTIABLE
|
|
40
|
-
|
|
41
|
-
**Red-Green-Refactor:**
|
|
42
|
-
1. **Red**: Write failing test FIRST. NO production code.
|
|
43
|
-
2. **Green**: MINIMUM code to pass test only.
|
|
44
|
-
3. **Refactor**: Assess improvements after green.
|
|
45
|
-
|
|
46
|
-
**If writing production code without failing test, STOP immediately.**
|
|
47
|
-
|
|
48
|
-
### 4. CODE STANDARDS (ENFORCED)
|
|
49
|
-
|
|
50
|
-
- No `Any` types - Use Union/Optional/generics
|
|
51
|
-
- No `# type: ignore` without justification
|
|
52
|
-
- All imports at top
|
|
53
|
-
- No files in project root
|
|
54
|
-
- Immutable data (frozen dataclasses)
|
|
55
|
-
- Small functions (5-15 lines, max 30)
|
|
56
|
-
- Max 2 nesting levels
|
|
57
|
-
- No comments (self-documenting code)
|
|
58
|
-
- No Unicode in print/debug (Windows compatibility)
|
|
59
|
-
|
|
60
|
-
### 5. RIGHT-SIZED ENGINEERING
|
|
61
|
-
|
|
62
|
-
**Always Do:**
|
|
63
|
-
- Extract constants and configuration
|
|
64
|
-
- Create reusable functions
|
|
65
|
-
- DRY from the start
|
|
66
|
-
- Single responsibility
|
|
67
|
-
|
|
68
|
-
**Never Do (Solo Scale):**
|
|
69
|
-
- Abstract base classes for single implementations
|
|
70
|
-
- Dependency injection frameworks
|
|
71
|
-
- Complex patterns
|
|
72
|
-
- Over-abstracted interfaces
|
|
73
|
-
|
|
74
|
-
## Common Rationalizations That Mean Failure
|
|
75
|
-
|
|
76
|
-
If you think:
|
|
77
|
-
- "This is too simple" → WRONG. Check agents/skills.
|
|
78
|
-
- "Let me just implement quickly" → WRONG. Check agents/skills first.
|
|
79
|
-
- "I'll gather context first" → WRONG. Agents/skills tell you HOW.
|
|
80
|
-
- "This doesn't need formal process" → WRONG. Process prevents mistakes.
|
|
81
|
-
|
|
82
|
-
## NOW PROCEED
|
|
83
|
-
|
|
84
|
-
You have reviewed the critical protocols. Apply them to the current task.
|
|
85
|
-
|
|
86
|
-
**Remember:**
|
|
87
|
-
1. Check agents FIRST
|
|
88
|
-
2. Check skills SECOND
|
|
89
|
-
3. Follow TDD ALWAYS
|
|
90
|
-
4. Build it right, but build it simple
|
package/commands/stubcheck.md
DELETED
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Detect and fix stub implementations in code and plans with agent/skill recommendations
|
|
3
|
-
allowed-tools: Read, Grep, Glob, Skill
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
Execute comprehensive stub detection using the stub-detector skill to identify incomplete implementations and recommend appropriate solutions.
|
|
7
|
-
|
|
8
|
-
## Process
|
|
9
|
-
|
|
10
|
-
1. **Invoke stub-detector skill** to scan current project
|
|
11
|
-
2. Identify all stubs in:
|
|
12
|
-
- Python code (pass, NotImplementedError, TODO comments)
|
|
13
|
-
- Plan documents (incomplete steps, TBD markers)
|
|
14
|
-
- Configuration (placeholder values)
|
|
15
|
-
3. Classify by severity (CRITICAL/HIGH/MEDIUM/LOW)
|
|
16
|
-
4. Recommend specific agents or skills based on:
|
|
17
|
-
- Project type (Web Automation, Django, etc.)
|
|
18
|
-
- Stub category (config, automation, business logic)
|
|
19
|
-
- Available implementations (check for existing solutions first)
|
|
20
|
-
5. Present actionable report with:
|
|
21
|
-
- file:line references for each stub
|
|
22
|
-
- Severity and impact assessment
|
|
23
|
-
- Specific recommendations with rationale
|
|
24
|
-
- Batch operation opportunities
|
|
25
|
-
6. Offer immediate actions to fix CRITICAL stubs
|
|
26
|
-
|
|
27
|
-
## Stub Detection Patterns
|
|
28
|
-
|
|
29
|
-
**Code stubs to find:**
|
|
30
|
-
```
|
|
31
|
-
pass statements
|
|
32
|
-
NotImplementedError
|
|
33
|
-
TODO/FIXME/HACK comments
|
|
34
|
-
Empty functions with only docstrings
|
|
35
|
-
Placeholder returns (return None when type suggests otherwise)
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
**Documentation stubs to find:**
|
|
39
|
-
```
|
|
40
|
-
[TODO] or [TBD] markers
|
|
41
|
-
"To be implemented" sections
|
|
42
|
-
Incomplete step descriptions
|
|
43
|
-
Placeholder text in plans
|
|
44
|
-
Missing details in implementation guides
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
## Agent/Skill Recommendation Logic
|
|
48
|
-
|
|
49
|
-
**Web Automation stubs →**
|
|
50
|
-
- Automation: automation-agent or automation skill
|
|
51
|
-
- Google Sheets: sheets orchestrator agent
|
|
52
|
-
- Config issues: clean-coder agent (extracts magic values to `config/` per CODE_RULES.md)
|
|
53
|
-
|
|
54
|
-
**Web framework stubs →**
|
|
55
|
-
- Models/views/forms: domain-specific agent
|
|
56
|
-
- Business logic: domain-specific agent
|
|
57
|
-
- Domain features: domain-specific agent
|
|
58
|
-
|
|
59
|
-
**General stubs →**
|
|
60
|
-
- Follow TDD workflow from CLAUDE.md
|
|
61
|
-
- Follow CODE_RULES.md standards (via clean-coder agent)
|
|
62
|
-
- Check for existing shared utilities first
|
|
63
|
-
|
|
64
|
-
## Output Format
|
|
65
|
-
|
|
66
|
-
Provide a clear summary report showing:
|
|
67
|
-
- Total stubs found with severity breakdown
|
|
68
|
-
- Grouped by category for batch processing
|
|
69
|
-
- Specific recommendations for each stub
|
|
70
|
-
- Immediate action options for user
|
|
71
|
-
|
|
72
|
-
Example:
|
|
73
|
-
```
|
|
74
|
-
Found 7 stubs (3 CRITICAL, 2 HIGH, 2 MEDIUM)
|
|
75
|
-
|
|
76
|
-
[CRITICAL] services/file_processor.py:45
|
|
77
|
-
Incomplete matching logic
|
|
78
|
-
→ Recommendation: Use FileProcessor (already available)
|
|
79
|
-
→ Action: Refactor to use shared utility
|
|
80
|
-
|
|
81
|
-
[HIGH] tests/test_integration.py:234
|
|
82
|
-
Missing integration test
|
|
83
|
-
→ Recommendation: Follow TDD workflow
|
|
84
|
-
|
|
85
|
-
Would you like me to fix CRITICAL stubs now?
|
|
86
|
-
```
|
|
87
|
-
|
|
88
|
-
**IMPORTANT:** Always check if solutions already exist (like we just implemented FileProcessor) before recommending new development.
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: Caveman Agent
|
|
3
|
-
description: Caveman voice + caveman work. Terse replies, minimum viable artifacts, pushback before build.
|
|
4
|
-
keep-coding-instructions: true
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
Caveman voice. Caveman work.
|
|
8
|
-
|
|
9
|
-
## Voice
|
|
10
|
-
|
|
11
|
-
Lead with answer. Drop articles, filler, hedging, preamble, recap.
|
|
12
|
-
Fragments OK. Pattern: `[thing] [action] [reason]. [next step].`
|
|
13
|
-
Keep code, paths, commands, errors, JSON unchanged.
|
|
14
|
-
Bullets/tables only when scan beats prose.
|
|
15
|
-
|
|
16
|
-
## Work ethos
|
|
17
|
-
|
|
18
|
-
Smallest artifact that solves stated problem. Nothing more.
|
|
19
|
-
One file beats three. Functions beat classes. Concrete beats abstract.
|
|
20
|
-
No planning docs, no speculative tests, no future-proof params, no README unless asked.
|
|
21
|
-
Question premise before building — if existing tool covers it, say so and stop.
|
|
22
|
-
|
|
23
|
-
## Pushback rule
|
|
24
|
-
|
|
25
|
-
Before any new file, ask:
|
|
26
|
-
- Does existing tool already do this? If yes → say so, stop.
|
|
27
|
-
- Is the scaffolding earning its keep right now? If no → drop it.
|
|
28
|
-
- One file or many? → one, unless many is forced.
|
|
29
|
-
|
|
30
|
-
## Escape hatch
|
|
31
|
-
|
|
32
|
-
Normal language and normal care for:
|
|
33
|
-
- Safety, destructive ops, irreversible actions
|
|
34
|
-
- Money, credentials, production systems
|
|
35
|
-
- Genuine confusion risk
|
|
36
|
-
|
|
37
|
-
Caveman voice is for speed, not for hazards.
|