claude-code-pilot 3.0.0 → 3.1.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 (124) hide show
  1. package/README.md +76 -97
  2. package/bin/install.js +13 -13
  3. package/manifest.json +1 -1
  4. package/package.json +1 -1
  5. package/src/agents/doc-updater.md +1 -1
  6. package/src/agents/gan-evaluator.md +209 -0
  7. package/src/agents/gan-generator.md +131 -0
  8. package/src/agents/gan-planner.md +99 -0
  9. package/src/agents/harness-optimizer.md +35 -0
  10. package/src/agents/loop-operator.md +36 -0
  11. package/src/agents/opensource-forker.md +198 -0
  12. package/src/agents/opensource-packager.md +249 -0
  13. package/src/agents/opensource-sanitizer.md +188 -0
  14. package/src/agents/performance-optimizer.md +446 -0
  15. package/src/available-rules/README.md +1 -1
  16. package/src/commands/{aside.md → ccp/aside.md} +14 -13
  17. package/src/commands/{build-fix.md → ccp/build-fix.md} +5 -0
  18. package/src/commands/{checkpoint.md → ccp/checkpoint.md} +12 -7
  19. package/src/commands/{code-review.md → ccp/code-review.md} +5 -0
  20. package/src/commands/{context-budget.md → ccp/context-budget.md} +2 -1
  21. package/src/commands/{cpp-build.md → ccp/cpp-build.md} +6 -5
  22. package/src/commands/{cpp-review.md → ccp/cpp-review.md} +7 -6
  23. package/src/commands/{cpp-test.md → ccp/cpp-test.md} +6 -5
  24. package/src/commands/ccp/docs-update.md +48 -0
  25. package/src/commands/{docs.md → ccp/docs.md} +4 -3
  26. package/src/commands/{e2e.md → ccp/e2e.md} +7 -6
  27. package/src/commands/{eval.md → ccp/eval.md} +10 -5
  28. package/src/commands/{evolve.md → ccp/evolve.md} +3 -3
  29. package/src/commands/{go-build.md → ccp/go-build.md} +6 -5
  30. package/src/commands/{go-review.md → ccp/go-review.md} +7 -6
  31. package/src/commands/{go-test.md → ccp/go-test.md} +6 -5
  32. package/src/commands/{gradle-build.md → ccp/gradle-build.md} +1 -0
  33. package/src/commands/{harness-audit.md → ccp/harness-audit.md} +6 -1
  34. package/src/commands/{kotlin-build.md → ccp/kotlin-build.md} +6 -5
  35. package/src/commands/{kotlin-review.md → ccp/kotlin-review.md} +7 -6
  36. package/src/commands/{kotlin-test.md → ccp/kotlin-test.md} +6 -5
  37. package/src/commands/{learn.md → ccp/learn.md} +7 -2
  38. package/src/commands/{model-route.md → ccp/model-route.md} +6 -1
  39. package/src/commands/{orchestrate.md → ccp/orchestrate.md} +4 -3
  40. package/src/commands/{plan.md → ccp/plan.md} +6 -5
  41. package/src/commands/ccp/profile-user.md +46 -0
  42. package/src/commands/{prompt-optimize.md → ccp/prompt-optimize.md} +3 -2
  43. package/src/commands/{prune.md → ccp/prune.md} +4 -4
  44. package/src/commands/{python-review.md → ccp/python-review.md} +7 -6
  45. package/src/commands/{quality-gate.md → ccp/quality-gate.md} +6 -1
  46. package/src/commands/{refactor-clean.md → ccp/refactor-clean.md} +5 -0
  47. package/src/commands/{resume-session.md → ccp/resume-session.md} +9 -8
  48. package/src/commands/ccp/review.md +37 -0
  49. package/src/commands/{rules-distill.md → ccp/rules-distill.md} +2 -1
  50. package/src/commands/{rust-build.md → ccp/rust-build.md} +6 -5
  51. package/src/commands/{rust-review.md → ccp/rust-review.md} +7 -6
  52. package/src/commands/{rust-test.md → ccp/rust-test.md} +6 -5
  53. package/src/commands/{save-session.md → ccp/save-session.md} +2 -1
  54. package/src/commands/ccp/secure-phase.md +35 -0
  55. package/src/commands/{sessions.md → ccp/sessions.md} +29 -24
  56. package/src/commands/{setup-pm.md → ccp/setup-pm.md} +1 -0
  57. package/src/commands/{setup-refresh.md → ccp/setup-refresh.md} +4 -3
  58. package/src/commands/{setup.md → ccp/setup.md} +24 -23
  59. package/src/commands/{skill-create.md → ccp/skill-create.md} +8 -8
  60. package/src/commands/{skill-health.md → ccp/skill-health.md} +5 -5
  61. package/src/commands/{tdd.md → ccp/tdd.md} +9 -8
  62. package/src/commands/{test-coverage.md → ccp/test-coverage.md} +5 -0
  63. package/src/commands/{tool-guide.md → ccp/tool-guide.md} +2 -1
  64. package/src/commands/{update-codemaps.md → ccp/update-codemaps.md} +5 -0
  65. package/src/commands/{update-docs.md → ccp/update-docs.md} +5 -0
  66. package/src/commands/{verify.md → ccp/verify.md} +5 -0
  67. package/src/commands/ccp/workstreams.md +68 -0
  68. package/src/examples/CLAUDE.md +4 -4
  69. package/src/examples/django-api-CLAUDE.md +5 -5
  70. package/src/examples/go-microservice-CLAUDE.md +6 -6
  71. package/src/examples/rust-api-CLAUDE.md +4 -4
  72. package/src/examples/saas-nextjs-CLAUDE.md +8 -8
  73. package/src/hooks/session-start.js +1 -1
  74. package/src/pilot/references/mcp-servers.json +1 -1
  75. package/src/pilot/workflows/docs-update.md +1165 -0
  76. package/src/pilot/workflows/help.md +48 -56
  77. package/src/pilot/workflows/profile-user.md +452 -0
  78. package/src/pilot/workflows/review.md +244 -0
  79. package/src/pilot/workflows/secure-phase.md +164 -0
  80. package/src/rules/common/code-review.md +124 -0
  81. package/src/rules/zh/README.md +108 -0
  82. package/src/rules/zh/agents.md +50 -0
  83. package/src/rules/zh/code-review.md +124 -0
  84. package/src/rules/zh/coding-style.md +48 -0
  85. package/src/rules/zh/development-workflow.md +44 -0
  86. package/src/rules/zh/git-workflow.md +24 -0
  87. package/src/rules/zh/hooks.md +30 -0
  88. package/src/rules/zh/patterns.md +31 -0
  89. package/src/rules/zh/performance.md +55 -0
  90. package/src/rules/zh/security.md +29 -0
  91. package/src/rules/zh/testing.md +29 -0
  92. package/src/skills/autonomous-agent-harness/SKILL.md +267 -0
  93. package/src/skills/autonomous-loops/SKILL.md +610 -0
  94. package/src/skills/bun-runtime/SKILL.md +84 -0
  95. package/src/skills/content-hash-cache-pattern/SKILL.md +161 -0
  96. package/src/skills/context-budget/SKILL.md +3 -3
  97. package/src/skills/continuous-learning-v2/SKILL.md +4 -4
  98. package/src/skills/continuous-learning-v2/agents/observer.md +1 -1
  99. package/src/skills/cost-aware-llm-pipeline/SKILL.md +183 -0
  100. package/src/skills/design-system/SKILL.md +82 -0
  101. package/src/skills/eval-harness/SKILL.md +270 -0
  102. package/src/skills/flutter-dart-code-review/SKILL.md +435 -0
  103. package/src/skills/gan-style-harness/SKILL.md +278 -0
  104. package/src/skills/git-workflow/SKILL.md +715 -0
  105. package/src/skills/hexagonal-architecture/SKILL.md +276 -0
  106. package/src/skills/iterative-retrieval/SKILL.md +211 -0
  107. package/src/skills/laravel-plugin-discovery/SKILL.md +229 -0
  108. package/src/skills/nextjs-turbopack/SKILL.md +44 -0
  109. package/src/skills/nuxt4-patterns/SKILL.md +100 -0
  110. package/src/skills/opensource-pipeline/SKILL.md +255 -0
  111. package/src/skills/perl-security/SKILL.md +503 -0
  112. package/src/skills/project-flow-ops/SKILL.md +111 -0
  113. package/src/skills/project-guidelines-example/SKILL.md +349 -0
  114. package/src/skills/prompt-optimizer/SKILL.md +38 -38
  115. package/src/skills/pytorch-patterns/SKILL.md +396 -0
  116. package/src/skills/regex-vs-llm-structured-text/SKILL.md +220 -0
  117. package/src/skills/repo-scan/SKILL.md +78 -0
  118. package/src/skills/rules-distill/SKILL.md +264 -0
  119. package/src/skills/rules-distill/scripts/scan-rules.sh +58 -0
  120. package/src/skills/rules-distill/scripts/scan-skills.sh +129 -0
  121. package/src/skills/swift-concurrency-6-2/SKILL.md +216 -0
  122. package/src/skills/token-budget-advisor/SKILL.md +133 -0
  123. package/src/skills/verification-loop/SKILL.md +1 -1
  124. package/src/skills/workspace-surface-audit/SKILL.md +125 -0
@@ -0,0 +1,133 @@
1
+ ---
2
+ name: token-budget-advisor
3
+ description: >-
4
+ Offers the user an informed choice about how much response depth to
5
+ consume before answering. Use this skill when the user explicitly
6
+ wants to control response length, depth, or token budget.
7
+ TRIGGER when: "token budget", "token count", "token usage", "token limit",
8
+ "response length", "answer depth", "short version", "brief answer",
9
+ "detailed answer", "exhaustive answer", "respuesta corta vs larga",
10
+ "cuántos tokens", "ahorrar tokens", "responde al 50%", "dame la versión
11
+ corta", "quiero controlar cuánto usas", or clear variants where the
12
+ user is explicitly asking to control answer size or depth.
13
+ DO NOT TRIGGER when: user has already specified a level in the current
14
+ session (maintain it), the request is clearly a one-word answer, or
15
+ "token" refers to auth/session/payment tokens rather than response size.
16
+ origin: community
17
+ ---
18
+
19
+ # Token Budget Advisor (TBA)
20
+
21
+ Intercept the response flow to offer the user a choice about response depth **before** Claude answers.
22
+
23
+ ## When to Use
24
+
25
+ - User wants to control how long or detailed a response is
26
+ - User mentions tokens, budget, depth, or response length
27
+ - User says "short version", "tldr", "brief", "al 25%", "exhaustive", etc.
28
+ - Any time the user wants to choose depth/detail level upfront
29
+
30
+ **Do not trigger** when: user already set a level this session (maintain it silently), or the answer is trivially one line.
31
+
32
+ ## How It Works
33
+
34
+ ### Step 1 — Estimate input tokens
35
+
36
+ Use the repository's canonical context-budget heuristics to estimate the prompt's token count mentally.
37
+
38
+ Use the same calibration guidance as [context-budget](../context-budget/SKILL.md):
39
+
40
+ - prose: `words × 1.3`
41
+ - code-heavy or mixed/code blocks: `chars / 4`
42
+
43
+ For mixed content, use the dominant content type and keep the estimate heuristic.
44
+
45
+ ### Step 2 — Estimate response size by complexity
46
+
47
+ Classify the prompt, then apply the multiplier range to get the full response window:
48
+
49
+ | Complexity | Multiplier range | Example prompts |
50
+ |--------------|------------------|------------------------------------------------------|
51
+ | Simple | 3× – 8× | "What is X?", yes/no, single fact |
52
+ | Medium | 8× – 20× | "How does X work?" |
53
+ | Medium-High | 10× – 25× | Code request with context |
54
+ | Complex | 15× – 40× | Multi-part analysis, comparisons, architecture |
55
+ | Creative | 10× – 30× | Stories, essays, narrative writing |
56
+
57
+ Response window = `input_tokens × mult_min` to `input_tokens × mult_max` (but don’t exceed your model’s configured output-token limit).
58
+
59
+ ### Step 3 — Present depth options
60
+
61
+ Present this block **before** answering, using the actual estimated numbers:
62
+
63
+ ```
64
+ Analyzing your prompt...
65
+
66
+ Input: ~[N] tokens | Type: [type] | Complexity: [level] | Language: [lang]
67
+
68
+ Choose your depth level:
69
+
70
+ [1] Essential (25%) -> ~[tokens] Direct answer only, no preamble
71
+ [2] Moderate (50%) -> ~[tokens] Answer + context + 1 example
72
+ [3] Detailed (75%) -> ~[tokens] Full answer with alternatives
73
+ [4] Exhaustive (100%) -> ~[tokens] Everything, no limits
74
+
75
+ Which level? (1-4 or say "25% depth", "50% depth", "75% depth", "100% depth")
76
+
77
+ Precision: heuristic estimate ~85-90% accuracy (±15%).
78
+ ```
79
+
80
+ Level token estimates (within the response window):
81
+ - 25% → `min + (max - min) × 0.25`
82
+ - 50% → `min + (max - min) × 0.50`
83
+ - 75% → `min + (max - min) × 0.75`
84
+ - 100% → `max`
85
+
86
+ ### Step 4 — Respond at the chosen level
87
+
88
+ | Level | Target length | Include | Omit |
89
+ |------------------|---------------------|-----------------------------------------------------|---------------------------------------------------|
90
+ | 25% Essential | 2-4 sentences max | Direct answer, key conclusion | Context, examples, nuance, alternatives |
91
+ | 50% Moderate | 1-3 paragraphs | Answer + necessary context + 1 example | Deep analysis, edge cases, references |
92
+ | 75% Detailed | Structured response | Multiple examples, pros/cons, alternatives | Extreme edge cases, exhaustive references |
93
+ | 100% Exhaustive | No restriction | Everything — full analysis, all code, all perspectives | Nothing |
94
+
95
+ ## Shortcuts — skip the question
96
+
97
+ If the user already signals a level, respond at that level immediately without asking:
98
+
99
+ | What they say | Level |
100
+ |----------------------------------------------------|-------|
101
+ | "1" / "25% depth" / "short version" / "brief answer" / "tldr" | 25% |
102
+ | "2" / "50% depth" / "moderate depth" / "balanced answer" | 50% |
103
+ | "3" / "75% depth" / "detailed answer" / "thorough answer" | 75% |
104
+ | "4" / "100% depth" / "exhaustive answer" / "full deep dive" | 100% |
105
+
106
+ If the user set a level earlier in the session, **maintain it silently** for subsequent responses unless they change it.
107
+
108
+ ## Precision note
109
+
110
+ This skill uses heuristic estimation — no real tokenizer. Accuracy ~85-90%, variance ±15%. Always show the disclaimer.
111
+
112
+ ## Examples
113
+
114
+ ### Triggers
115
+
116
+ - "Give me the short version first."
117
+ - "How many tokens will your answer use?"
118
+ - "Respond at 50% depth."
119
+ - "I want the exhaustive answer, not the summary."
120
+ - "Dame la version corta y luego la detallada."
121
+
122
+ ### Does Not Trigger
123
+
124
+ - "What is a JWT token?"
125
+ - "The checkout flow uses a payment token."
126
+ - "Is this normal?"
127
+ - "Complete the refactor."
128
+ - Follow-up questions after the user already chose a depth for the session
129
+
130
+ ## Source
131
+
132
+ Standalone skill from [TBA — Token Budget Advisor for Claude Code](https://github.com/Xabilimon1/Token-Budget-Advisor-Claude-Code-).
133
+ Original project also ships a Python estimator script, but this repository keeps the skill self-contained and heuristic-only.
@@ -117,7 +117,7 @@ Set a mental checkpoint:
117
117
  - After finishing a component
118
118
  - Before moving to next task
119
119
 
120
- Run: /verify
120
+ Run: /ccp:verify
121
121
  ```
122
122
 
123
123
  ## Integration with Hooks
@@ -0,0 +1,125 @@
1
+ ---
2
+ name: workspace-surface-audit
3
+ description: Audit the active repo, MCP servers, plugins, connectors, env surfaces, and harness setup, then recommend the highest-value ECC-native skills, hooks, agents, and operator workflows. Use when the user wants help setting up Claude Code or understanding what capabilities are actually available in their environment.
4
+ origin: ECC
5
+ ---
6
+
7
+ # Workspace Surface Audit
8
+
9
+ Read-only audit skill for answering the question "what can this workspace and machine actually do right now, and what should we add or enable next?"
10
+
11
+ This is the ECC-native answer to setup-audit plugins. It does not modify files unless the user explicitly asks for follow-up implementation.
12
+
13
+ ## When to Use
14
+
15
+ - User says "set up Claude Code", "recommend automations", "what plugins or MCPs should I use?", or "what am I missing?"
16
+ - Auditing a machine or repo before installing more skills, hooks, or connectors
17
+ - Comparing official marketplace plugins against ECC-native coverage
18
+ - Reviewing `.env`, `.mcp.json`, plugin settings, or connected-app surfaces to find missing workflow layers
19
+ - Deciding whether a capability should be a skill, hook, agent, MCP, or external connector
20
+
21
+ ## Non-Negotiable Rules
22
+
23
+ - Never print secret values. Surface only provider names, capability names, file paths, and whether a key or config exists.
24
+ - Prefer ECC-native workflows over generic "install another plugin" advice when ECC can reasonably own the surface.
25
+ - Treat external plugins as benchmarks and inspiration, not authoritative product boundaries.
26
+ - Separate three things clearly:
27
+ - already available now
28
+ - available but not wrapped well in ECC
29
+ - not available and would require a new integration
30
+
31
+ ## Audit Inputs
32
+
33
+ Inspect only the files and settings needed to answer the question well:
34
+
35
+ 1. Repo surface
36
+ - `package.json`, lockfiles, language markers, framework config, `README.md`
37
+ - `.mcp.json`, `.lsp.json`, `.claude/settings*.json`, `.codex/*`
38
+ - `AGENTS.md`, `CLAUDE.md`, install manifests, hook configs
39
+ 2. Environment surface
40
+ - `.env*` files in the active repo and obvious adjacent ECC workspaces
41
+ - Surface only key names such as `STRIPE_API_KEY`, `TWILIO_AUTH_TOKEN`, `FAL_KEY`
42
+ 3. Connected tool surface
43
+ - Installed plugins, enabled connectors, MCP servers, LSPs, and app integrations
44
+ 4. ECC surface
45
+ - Existing skills, commands, hooks, agents, and install modules that already cover the need
46
+
47
+ ## Audit Process
48
+
49
+ ### Phase 1: Inventory What Exists
50
+
51
+ Produce a compact inventory:
52
+
53
+ - active harness targets
54
+ - installed plugins and connected apps
55
+ - configured MCP servers
56
+ - configured LSP servers
57
+ - env-backed services implied by key names
58
+ - existing ECC skills already relevant to the workspace
59
+
60
+ If a surface exists only as a primitive, call that out. Example:
61
+
62
+ - "Stripe is available via connected app, but ECC lacks a billing-operator skill"
63
+ - "Google Drive is connected, but there is no ECC-native Google Workspace operator workflow"
64
+
65
+ ### Phase 2: Benchmark Against Official and Installed Surfaces
66
+
67
+ Compare the workspace against:
68
+
69
+ - official Claude plugins that overlap with setup, review, docs, design, or workflow quality
70
+ - locally installed plugins in Claude or Codex
71
+ - the user's currently connected app surfaces
72
+
73
+ Do not just list names. For each comparison, answer:
74
+
75
+ 1. what they actually do
76
+ 2. whether ECC already has parity
77
+ 3. whether ECC only has primitives
78
+ 4. whether ECC is missing the workflow entirely
79
+
80
+ ### Phase 3: Turn Gaps Into ECC Decisions
81
+
82
+ For every real gap, recommend the correct ECC-native shape:
83
+
84
+ | Gap Type | Preferred ECC Shape |
85
+ |----------|---------------------|
86
+ | Repeatable operator workflow | Skill |
87
+ | Automatic enforcement or side-effect | Hook |
88
+ | Specialized delegated role | Agent |
89
+ | External tool bridge | MCP server or connector |
90
+ | Install/bootstrap guidance | Setup or audit skill |
91
+
92
+ Default to user-facing skills that orchestrate existing tools when the need is operational rather than infrastructural.
93
+
94
+ ## Output Format
95
+
96
+ Return five sections in this order:
97
+
98
+ 1. **Current surface**
99
+ - what is already usable right now
100
+ 2. **Parity**
101
+ - where ECC already matches or exceeds the benchmark
102
+ 3. **Primitive-only gaps**
103
+ - tools exist, but ECC lacks a clean operator skill
104
+ 4. **Missing integrations**
105
+ - capability not available yet
106
+ 5. **Top 3-5 next moves**
107
+ - concrete ECC-native additions, ordered by impact
108
+
109
+ ## Recommendation Rules
110
+
111
+ - Recommend at most 1-2 highest-value ideas per category.
112
+ - Favor skills with obvious user intent and business value:
113
+ - setup audit
114
+ - billing/customer ops
115
+ - issue/program ops
116
+ - Google Workspace ops
117
+ - deployment/ops control
118
+ - If a connector is company-specific, recommend it only when it is genuinely available or clearly useful to the user's workflow.
119
+ - If ECC already has a strong primitive, propose a wrapper skill instead of inventing a brand-new subsystem.
120
+
121
+ ## Good Outcomes
122
+
123
+ - The user can immediately see what is connected, what is missing, and what ECC should own next.
124
+ - Recommendations are specific enough to implement in the repo without another discovery pass.
125
+ - The final answer is organized around workflows, not API brands.