claude-dev-env 1.38.0 → 1.39.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 +10 -36
- package/_shared/pr-loop/audit-reply-template.md +147 -0
- package/_shared/pr-loop/fix-protocol.md +25 -4
- package/_shared/pr-loop/gh-payloads.md +37 -50
- package/_shared/pr-loop/scripts/code_rules_gate.py +0 -60
- package/_shared/pr-loop/scripts/config/post_audit_thread_constants.py +189 -0
- package/_shared/pr-loop/scripts/post_audit_thread.py +947 -0
- package/_shared/pr-loop/scripts/tests/test_code_rules_gate.py +0 -19
- package/_shared/pr-loop/scripts/tests/test_post_audit_thread.py +923 -0
- package/_shared/pr-loop/scripts/tests/test_post_audit_thread_constants.py +127 -0
- package/_shared/pr-loop/state-schema.md +1 -1
- package/agents/clean-coder.md +2 -2
- package/bin/install.mjs +6 -7
- package/bin/install.test.mjs +8 -0
- package/commands/doc-gist.md +16 -0
- package/commands/plan.md +0 -2
- package/commands/review-plan.md +1 -1
- package/docs/CODE_RULES.md +122 -2
- package/hooks/blocking/bot_mention_comment_blocker.py +75 -0
- package/hooks/blocking/code_rules_enforcer.py +1236 -161
- package/hooks/blocking/convergence_gate_blocker.py +130 -0
- package/hooks/blocking/destructive_command_blocker.py +74 -0
- package/hooks/blocking/gh_body_arg_blocker.py +30 -0
- package/hooks/blocking/md_to_html_blocker.py +119 -0
- package/hooks/blocking/test_bot_mention_comment_blocker.py +131 -0
- package/hooks/blocking/test_code_rules_enforcer.py +21 -0
- package/hooks/blocking/test_code_rules_enforcer_any_exempt_files.py +70 -0
- package/hooks/blocking/test_code_rules_enforcer_any_imports_and_cast.py +92 -0
- package/hooks/blocking/test_code_rules_enforcer_banned_import_alias.py +143 -0
- package/hooks/blocking/test_code_rules_enforcer_banned_prefixes.py +152 -0
- package/hooks/blocking/test_code_rules_enforcer_bare_except.py +120 -0
- package/hooks/blocking/test_code_rules_enforcer_boundary_types.py +175 -0
- package/hooks/blocking/test_code_rules_enforcer_cap_meta.py +0 -1
- package/hooks/blocking/test_code_rules_enforcer_collection_prefix.py +50 -0
- package/hooks/blocking/test_code_rules_enforcer_docstring_format.py +255 -0
- package/hooks/blocking/test_code_rules_enforcer_inline_tuple_string_magic.py +130 -0
- package/hooks/blocking/test_code_rules_enforcer_stub_implementations.py +141 -0
- package/hooks/blocking/test_code_rules_enforcer_test_branching.py +143 -0
- package/hooks/blocking/test_code_rules_enforcer_thin_wrapper_files.py +169 -0
- package/hooks/blocking/test_code_rules_enforcer_todo_markers.py +99 -0
- package/hooks/blocking/test_code_rules_enforcer_typed_dict_pairs.py +141 -0
- package/hooks/blocking/test_code_rules_enforcer_unused_imports.py +158 -0
- package/hooks/blocking/test_convergence_gate_blocker.py +63 -0
- package/hooks/blocking/test_destructive_command_blocker.py +146 -0
- package/hooks/blocking/test_destructive_command_blocker_no_verify.py +102 -0
- package/hooks/blocking/test_gh_body_arg_blocker.py +45 -0
- package/hooks/blocking/test_md_to_html_blocker.py +317 -0
- package/hooks/config/any_type_config.py +7 -0
- package/hooks/config/banned_identifiers_constants.py +11 -0
- package/hooks/config/blocking_check_limits.py +38 -0
- package/hooks/config/bot_mention_comment_blocker_constants.py +20 -0
- package/hooks/config/code_rules_enforcer_constants.py +53 -0
- package/hooks/config/convergence_branch_constants.py +9 -0
- package/hooks/config/doc_gist_auto_publish_constants.py +18 -0
- package/hooks/config/html_companion_constants.py +20 -0
- package/hooks/config/inline_tuple_string_magic_constants.py +22 -0
- package/hooks/config/test_banned_identifiers_constants.py +17 -0
- package/hooks/hooks.json +28 -20
- package/hooks/pyproject.toml +69 -0
- package/hooks/validators/mypy_integration.py +47 -1
- package/hooks/validators/run_all_validators.py +3 -3
- package/hooks/validators/test_mypy_integration.py +50 -1
- package/hooks/workflow/doc_gist_auto_publish.py +144 -0
- package/hooks/workflow/md_to_html_companion.py +365 -0
- package/hooks/workflow/test_doc_gist_auto_publish.py +117 -0
- package/hooks/workflow/test_md_to_html_companion.py +452 -0
- package/package.json +1 -1
- package/rules/gh-body-file.md +2 -0
- package/scripts/Install-SweepEmptyDirs.ps1 +111 -0
- package/scripts/check.ps1 +106 -0
- package/scripts/config/timing.py +11 -0
- package/scripts/sweep_empty_dirs.py +138 -0
- package/scripts/sync_to_cursor/rules.py +1 -1
- package/scripts/test_sweep_empty_dirs.py +183 -0
- package/skills/_shared/pr-loop/prompts/pr-consistency-audit.xml +323 -0
- package/skills/_shared/pr-loop/scripts/_cli_utils.py +22 -0
- package/skills/_shared/pr-loop/scripts/_path_resolver.py +165 -0
- package/skills/_shared/pr-loop/scripts/_xml_utils.py +20 -0
- package/skills/_shared/pr-loop/scripts/build_audit_prompt.py +182 -0
- package/skills/_shared/pr-loop/scripts/build_fix_prompt.py +185 -0
- package/skills/_shared/pr-loop/scripts/config/__init__.py +0 -0
- package/skills/_shared/pr-loop/scripts/config/path_resolver_constants.py +78 -0
- package/skills/_shared/pr-loop/scripts/init_loop_state.py +135 -0
- package/skills/_shared/pr-loop/scripts/teardown_worktrees.py +175 -0
- package/skills/_shared/pr-loop/scripts/write_audit_outcomes.py +182 -0
- package/skills/_shared/pr-loop/scripts/write_fix_outcomes.py +206 -0
- package/skills/bugteam/CONSTRAINTS.md +21 -22
- package/skills/bugteam/EXAMPLES.md +3 -3
- package/skills/bugteam/PROMPTS.md +227 -67
- package/skills/bugteam/SKILL.md +114 -455
- package/skills/bugteam/reference/README.md +1 -1
- package/skills/bugteam/reference/audit-and-teammates.md +112 -39
- package/skills/bugteam/reference/audit-contract.md +4 -22
- package/skills/bugteam/reference/copilot-gap-analysis.md +8 -5
- package/skills/bugteam/reference/design-rationale.md +2 -2
- package/skills/bugteam/reference/github-pr-reviews.md +50 -57
- package/skills/bugteam/reference/obstacles/audit-assign-ids.md +13 -0
- package/skills/bugteam/reference/obstacles/audit-capture-excerpts.md +13 -0
- package/skills/bugteam/reference/obstacles/audit-walk-categories.md +13 -0
- package/skills/bugteam/reference/obstacles/audit-write-xml.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-append-summary.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-apply-fixes.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-git-add-commit.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-git-push.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-post-reply.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-publish-summary.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-py-compile.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-read-files.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-resolve-thread.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-test-suite.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-violation-count.md +13 -0
- package/skills/bugteam/reference/obstacles/fix-write-xml.md +13 -0
- package/skills/bugteam/reference/team-setup.md +106 -9
- package/skills/bugteam/reference/teardown-publish-permissions.md +39 -8
- package/skills/bugteam/scripts/README.md +60 -0
- package/skills/bugteam/scripts/_claude_permissions_common.py +358 -0
- package/skills/bugteam/scripts/bugteam_code_rules_gate.py +976 -0
- package/skills/bugteam/scripts/bugteam_fix_hookspath.py +375 -0
- package/skills/bugteam/scripts/bugteam_preflight.py +294 -0
- package/skills/bugteam/scripts/config/bugteam_code_rules_gate_constants.py +25 -0
- package/skills/bugteam/scripts/config/bugteam_fix_hookspath_constants.py +26 -0
- package/skills/bugteam/scripts/config/bugteam_preflight_constants.py +35 -0
- package/skills/bugteam/scripts/config/claude_permissions_common_constants.py +20 -0
- package/skills/bugteam/scripts/config/probe_code_rules_enforcer_check_constants.py +12 -0
- package/skills/bugteam/scripts/config/windows_safe_rmtree_constants.py +7 -0
- package/skills/bugteam/scripts/grant_project_claude_permissions.py +175 -0
- package/skills/bugteam/scripts/probe_code_rules_enforcer_check.py +107 -0
- package/skills/bugteam/scripts/revoke_project_claude_permissions.py +220 -0
- package/skills/bugteam/scripts/test__claude_permissions_common.py +112 -0
- package/skills/bugteam/scripts/test_bugteam_code_rules_gate.py +400 -0
- package/skills/bugteam/scripts/test_bugteam_fix_hookspath.py +384 -0
- package/skills/bugteam/scripts/test_bugteam_preflight.py +268 -0
- package/skills/bugteam/scripts/test_claude_permissions_common.py +195 -0
- package/skills/bugteam/scripts/test_grant_project_claude_permissions.py +55 -0
- package/skills/bugteam/scripts/test_probe_code_rules_enforcer_check.py +76 -0
- package/skills/bugteam/scripts/test_revoke_project_claude_permissions.py +55 -0
- package/skills/bugteam/scripts/test_windows_safe_rmtree.py +108 -0
- package/skills/bugteam/scripts/windows_safe_rmtree.py +100 -0
- package/skills/bugteam/test_skill_additions.py +1 -11
- package/skills/code/SKILL.md +176 -0
- package/skills/doc-gist/SKILL.md +99 -0
- package/skills/doc-gist/references/examples/01-exploration-code-approaches.html +453 -0
- package/skills/doc-gist/references/examples/02-exploration-visual-designs.html +515 -0
- package/skills/doc-gist/references/examples/03-code-review-pr.html +638 -0
- package/skills/doc-gist/references/examples/04-code-understanding.html +491 -0
- package/skills/doc-gist/references/examples/05-design-system.html +629 -0
- package/skills/doc-gist/references/examples/06-component-variants.html +605 -0
- package/skills/doc-gist/references/examples/07-prototype-animation.html +455 -0
- package/skills/doc-gist/references/examples/08-prototype-interaction.html +396 -0
- package/skills/doc-gist/references/examples/09-slide-deck.html +592 -0
- package/skills/doc-gist/references/examples/10-svg-illustrations.html +492 -0
- package/skills/doc-gist/references/examples/11-status-report.html +528 -0
- package/skills/doc-gist/references/examples/12-incident-report.html +596 -0
- package/skills/doc-gist/references/examples/13-flowchart-diagram.html +395 -0
- package/skills/doc-gist/references/examples/14-research-feature-explainer.html +381 -0
- package/skills/doc-gist/references/examples/15-research-concept-explainer.html +368 -0
- package/skills/doc-gist/references/examples/16-implementation-plan.html +702 -0
- package/skills/doc-gist/references/examples/17-pr-writeup.html +595 -0
- package/skills/doc-gist/references/examples/18-editor-triage-board.html +573 -0
- package/skills/doc-gist/references/examples/19-editor-feature-flags.html +663 -0
- package/skills/doc-gist/references/examples/20-editor-prompt-tuner.html +722 -0
- package/skills/doc-gist/references/examples/README.md +5 -0
- package/skills/doc-gist/scripts/config/__init__.py +0 -0
- package/skills/doc-gist/scripts/config/gist_upload_constants.py +16 -0
- package/skills/doc-gist/scripts/gist_upload.py +177 -0
- package/skills/doc-gist/scripts/test_gist_upload.py +51 -0
- package/skills/findbugs/SKILL.md +68 -2
- package/skills/monitor-open-prs/SKILL.md +13 -32
- package/skills/monitor-open-prs/test_skill_contract.py +0 -11
- package/skills/pr-consistency-audit/SKILL.md +112 -0
- package/skills/pr-consistency-audit/reference/detection-rules.md +96 -0
- package/skills/pr-consistency-audit/reference/illustrations.md +78 -0
- package/skills/pr-converge/SKILL.md +227 -23
- package/skills/pr-converge/config/__init__.py +0 -0
- package/skills/pr-converge/config/constants.py +62 -0
- package/skills/pr-converge/reference/convergence-gates.md +138 -44
- package/skills/pr-converge/reference/examples.md +43 -11
- package/skills/pr-converge/reference/fix-protocol.md +6 -5
- package/skills/pr-converge/reference/ground-rules.md +5 -3
- package/skills/pr-converge/reference/multi-pr-orchestration.md +44 -19
- package/skills/pr-converge/reference/obstacles/fix-post-replies.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-publish-summary.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-push.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-read-filelines.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-reset-state.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-resolve-threads.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-spawn-clean-coder.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-stage-commit.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-trigger-bugbot.md +13 -0
- package/skills/pr-converge/reference/obstacles/fix-write-test.md +13 -0
- package/skills/pr-converge/reference/per-tick.md +90 -31
- package/skills/pr-converge/reference/state-schema.md +22 -1
- package/skills/pr-converge/reference/stop-conditions.md +9 -7
- package/skills/pr-converge/scripts/README.md +34 -46
- package/skills/pr-converge/scripts/check_bugbot_ci.py +174 -0
- package/skills/pr-converge/scripts/check_convergence.py +497 -0
- package/skills/pr-converge/scripts/check_pending_reviews.py +154 -0
- package/skills/pr-converge/scripts/config/pr_converge_constants.py +118 -0
- package/skills/pr-converge/scripts/fetch_copilot_reviews.py +134 -0
- package/skills/pr-converge/scripts/post_fix_reply.py +168 -0
- package/skills/pr-converge/workflows/schedule-wakeup-loop.md +5 -12
- package/skills/qbug/SKILL.md +132 -27
- package/skills/session-log/SKILL.md +216 -114
- package/skills/session-tidy/SKILL.md +1 -1
- package/skills/skill-builder/SKILL.md +138 -56
- package/skills/skill-builder/references/delegation-map.md +72 -113
- package/skills/skill-builder/references/progressive-disclosure.md +122 -0
- package/skills/skill-builder/references/self-audit-checklist.md +92 -0
- package/skills/skill-builder/references/skill-types.md +228 -0
- package/skills/skill-builder/references/thariq-x-post-skills.json +33 -0
- package/skills/skill-builder/templates/gap-analysis.md +15 -8
- package/skills/skill-builder/workflows/improve-skill.md +86 -57
- package/skills/skill-builder/workflows/new-skill.md +80 -168
- package/skills/skill-builder/workflows/polish-skill.md +78 -54
- package/skills/structure-prompt/SKILL.md +50 -0
- package/skills/structure-prompt/reference/adversarial-tuning.md +62 -0
- package/skills/structure-prompt/reference/block-classification.md +27 -0
- package/skills/structure-prompt/reference/canonical-case.md +48 -0
- package/skills/structure-prompt/reference/citation-depth.md +70 -0
- package/skills/structure-prompt/reference/cleanup.md +33 -0
- package/skills/structure-prompt/reference/constraints.md +33 -0
- package/skills/structure-prompt/reference/directives.md +37 -0
- package/skills/structure-prompt/reference/examples.md +72 -0
- package/skills/structure-prompt/reference/instantiation.md +51 -0
- package/skills/structure-prompt/reference/output-contract.md +72 -0
- package/skills/structure-prompt/reference/per-category.md +23 -0
- package/skills/structure-prompt/reference/persona.md +38 -0
- package/skills/structure-prompt/reference/research.md +33 -0
- package/skills/structure-prompt/reference/structure.md +28 -0
- package/agents/code-standards-agent.md +0 -93
- package/agents/groq-coder.md +0 -113
- package/agents/plan-executor.md +0 -226
- package/agents/project-docs-analyzer.md +0 -53
- package/agents/project-structure-organizer-agent.md +0 -72
- package/agents/skill-to-agent-converter.md +0 -370
- package/agents/skill-writer-agent.md +0 -470
- package/agents/user-docs-writer.md +0 -67
- package/agents/workflow-visual-documenter.md +0 -82
- package/commands/readability-review.md +0 -20
- package/hooks/mypy.ini +0 -2
- package/hooks/notification/attention_needed_notify.py +0 -71
- package/hooks/notification/claude_notification_handler.py +0 -67
- package/hooks/notification/notification_utils.py +0 -267
- package/hooks/notification/subagent_complete_notify.py +0 -381
- package/hooks/notification/test_attention_needed_notify.py +0 -47
- package/hooks/notification/test_claude_notification_handler.py +0 -54
- package/hooks/notification/test_notification_utils.py +0 -91
- package/hooks/notification/test_subagent_complete_notify.py +0 -79
- package/scripts/config/groq_bugteam_config.py +0 -230
- package/scripts/config/test_groq_bugteam_config.py +0 -83
- package/scripts/config/test_spec_implementer_prompt.py +0 -32
- package/scripts/groq_bugteam.README.md +0 -131
- package/scripts/groq_bugteam.py +0 -647
- package/scripts/groq_bugteam_dotenv.py +0 -40
- package/scripts/groq_bugteam_spec.py +0 -226
- package/scripts/test_groq_bugteam.py +0 -529
- package/scripts/test_groq_bugteam_apply_fix_from_spec.py +0 -426
- package/scripts/test_groq_bugteam_dotenv.py +0 -66
- package/scripts/test_groq_bugteam_spec.py +0 -338
- package/skills/bugteam/SKILL_EVALS.md +0 -309
- package/skills/dream/SKILL.md +0 -118
- package/skills/ingest/SKILL.md +0 -40
- package/skills/npm-creator/SKILL.md +0 -187
- package/skills/readability-review/SKILL.md +0 -127
- package/skills/resume-review/SKILL.md +0 -261
- package/skills/rule-audit/SKILL.md +0 -307
- package/skills/rule-creator/SKILL.md +0 -150
- package/skills/searching-obsidian-vault/SKILL.md +0 -131
- package/skills/skill-writer/REFERENCE.md +0 -284
- package/skills/skill-writer/SKILL.md +0 -222
- package/skills/tdd-team/SKILL.md +0 -128
|
@@ -1,370 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: skill-to-agent-converter
|
|
3
|
-
description: Converts skill files into complementary agents by parsing skill content and generating properly structured agent files with YAML frontmatter and system prompts. Trigger when user asks to "convert skills to agents", "generate agents from skills", "create agents for my skills", or "turn my skills into agents".
|
|
4
|
-
tools: Read,Write,Glob,Grep,AskUserQuestion
|
|
5
|
-
model: sonnet
|
|
6
|
-
color: purple
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
# Skill-to-Agent Converter - Automated Skill Enhancement
|
|
10
|
-
|
|
11
|
-
You are a specialized agent that converts skill files into complementary agents. Your role is to analyze existing skills and generate well-structured agent files that can proactively invoke those skills in appropriate contexts.
|
|
12
|
-
|
|
13
|
-
## Your Responsibilities
|
|
14
|
-
|
|
15
|
-
- Scan both global (~/.claude/skills/) and project (.claude/skills/) skill directories
|
|
16
|
-
- Present available skills to the user for selection
|
|
17
|
-
- Parse skill frontmatter (name, description, allowed-tools) and content
|
|
18
|
-
- Read and incorporate supporting skill documentation files
|
|
19
|
-
- Generate complete agent files with proper YAML frontmatter and system prompts
|
|
20
|
-
- Create contextual complexity heuristics for agent invocation
|
|
21
|
-
- Generate diverse, realistic examples in proper XML format
|
|
22
|
-
- Mirror directory structure (global skills → ~/.claude/agents/, project skills → .claude/agents/)
|
|
23
|
-
- Maintain conversion tracking via .skill-to-agent-mapping.json
|
|
24
|
-
|
|
25
|
-
## Your Process
|
|
26
|
-
|
|
27
|
-
### Phase 1: Discovery
|
|
28
|
-
|
|
29
|
-
1. **Scan for Skills**
|
|
30
|
-
- Use Glob to find all *.md files in ~/.claude/skills/ (global)
|
|
31
|
-
- Use Glob to find all *.md files in .claude/skills/ (project)
|
|
32
|
-
- Compile list of available skills with their locations
|
|
33
|
-
|
|
34
|
-
2. **Present Options**
|
|
35
|
-
- Use AskUserQuestion to show skill selection list
|
|
36
|
-
- Group by location (global vs project)
|
|
37
|
-
- Allow multi-select for batch conversion
|
|
38
|
-
- Show skill name and first-line description
|
|
39
|
-
|
|
40
|
-
3. **Read Skill Content**
|
|
41
|
-
- For each selected skill:
|
|
42
|
-
- Read main SKILL.md file
|
|
43
|
-
- Parse YAML frontmatter (name, description, allowed-tools)
|
|
44
|
-
- Read PRINCIPLES.md if exists
|
|
45
|
-
- Read EXAMPLES.md if exists
|
|
46
|
-
- Read any other supporting *.md files in skill directory
|
|
47
|
-
|
|
48
|
-
### Phase 2: Analysis
|
|
49
|
-
|
|
50
|
-
1. **Domain Analysis**
|
|
51
|
-
- Identify skill's domain (testing, refactoring, documentation, architecture, etc.)
|
|
52
|
-
- Extract core methodology and patterns
|
|
53
|
-
- Determine skill's trigger contexts and use cases
|
|
54
|
-
- Identify when skill should NOT be used (anti-patterns)
|
|
55
|
-
|
|
56
|
-
2. **Complexity Heuristics**
|
|
57
|
-
- Based on skill domain, create decision rules for when to invoke
|
|
58
|
-
- Consider file count, code complexity, change scope
|
|
59
|
-
- Define threshold metrics (e.g., "files > 5", "functions > 10", "nested depth > 3")
|
|
60
|
-
- Create contextual patterns (e.g., "before major refactoring", "after test failures")
|
|
61
|
-
|
|
62
|
-
3. **Example Generation**
|
|
63
|
-
- Create 2-3 diverse, realistic examples
|
|
64
|
-
- Use proper XML format with context/user/assistant/commentary blocks
|
|
65
|
-
- Show different complexity levels and scenarios
|
|
66
|
-
- Include both ideal use cases and boundary cases
|
|
67
|
-
|
|
68
|
-
### Phase 3: Agent Generation
|
|
69
|
-
|
|
70
|
-
1. **Frontmatter Construction**
|
|
71
|
-
```yaml
|
|
72
|
-
---
|
|
73
|
-
name: [skill-name]-orchestrator
|
|
74
|
-
description: Use PROACTIVELY when [complexity heuristics]. Invokes the [skill-name] skill to [primary purpose]. Trigger when [specific scenarios].
|
|
75
|
-
tools: Task,[other-tools-from-skill]
|
|
76
|
-
model: sonnet
|
|
77
|
-
---
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
2. **System Prompt Structure**
|
|
81
|
-
```markdown
|
|
82
|
-
# [Skill Name] Orchestrator - [Brief Subtitle]
|
|
83
|
-
|
|
84
|
-
You are a specialized agent that orchestrates the [skill-name] skill for [use case].
|
|
85
|
-
|
|
86
|
-
## Your Responsibilities
|
|
87
|
-
[List specific duties]
|
|
88
|
-
|
|
89
|
-
## When to Invoke This Agent
|
|
90
|
-
[Complexity heuristics and triggering conditions]
|
|
91
|
-
|
|
92
|
-
## Your Process
|
|
93
|
-
[Step-by-step workflow including Task tool invocation]
|
|
94
|
-
|
|
95
|
-
## Critical Rules
|
|
96
|
-
[Mandatory constraints from skill principles]
|
|
97
|
-
|
|
98
|
-
## When NOT to Use This Agent
|
|
99
|
-
[Anti-patterns and exclusions]
|
|
100
|
-
|
|
101
|
-
## Examples
|
|
102
|
-
[2-3 XML-formatted examples with commentary]
|
|
103
|
-
|
|
104
|
-
## Output Format
|
|
105
|
-
[Expected deliverables]
|
|
106
|
-
```
|
|
107
|
-
|
|
108
|
-
3. **Content Mapping**
|
|
109
|
-
- Skill `allowed-tools` → Agent `tools` (always include Task)
|
|
110
|
-
- Skill description → Agent description with proactive language
|
|
111
|
-
- Skill principles → Agent critical rules
|
|
112
|
-
- Skill examples → Agent examples with XML formatting
|
|
113
|
-
- Supporting docs → Inline in relevant agent sections
|
|
114
|
-
|
|
115
|
-
### Phase 4: Save and Track
|
|
116
|
-
|
|
117
|
-
1. **Save Agent File**
|
|
118
|
-
- Global skill → Save to ~/.claude/agents/[skill-name]-orchestrator.md
|
|
119
|
-
- Project skill → Save to .claude/agents/[skill-name]-orchestrator.md
|
|
120
|
-
- Preserve directory structure and scope
|
|
121
|
-
|
|
122
|
-
2. **Update Mapping**
|
|
123
|
-
- Read existing .skill-to-agent-mapping.json (create if missing)
|
|
124
|
-
- Add entry: `{ "skill": "path/to/skill.md", "agent": "path/to/agent.md", "converted": "ISO-date" }`
|
|
125
|
-
- Save to same directory as agent file
|
|
126
|
-
- Track for refresh/update operations
|
|
127
|
-
|
|
128
|
-
3. **Report Results**
|
|
129
|
-
- List all conversions completed
|
|
130
|
-
- Show absolute file paths for both skill and agent
|
|
131
|
-
- Explain invocation patterns for new agents
|
|
132
|
-
- Suggest test scenarios
|
|
133
|
-
|
|
134
|
-
## Critical Rules
|
|
135
|
-
|
|
136
|
-
1. **NEVER guess skill structure** - Always read the actual skill file
|
|
137
|
-
2. **ALWAYS include Task tool** - Agents orchestrate skills via Task
|
|
138
|
-
3. **ALWAYS use absolute paths** - No relative paths in output
|
|
139
|
-
4. **ALWAYS preserve scope** - Global stays global, project stays project
|
|
140
|
-
5. **ALWAYS generate XML examples** - Use context/user/assistant/commentary format
|
|
141
|
-
6. **NEVER overwrite without checking** - If agent exists, ask user if refresh/update
|
|
142
|
-
7. **ALWAYS incorporate supporting docs** - Read PRINCIPLES.md, EXAMPLES.md, etc.
|
|
143
|
-
8. **ALWAYS create proactive descriptions** - Use "Use PROACTIVELY when" language
|
|
144
|
-
|
|
145
|
-
## When to Use This Agent
|
|
146
|
-
|
|
147
|
-
Trigger this agent when:
|
|
148
|
-
|
|
149
|
-
- User has skills that would benefit from contextual auto-invocation
|
|
150
|
-
- User wants to create agents for existing skills
|
|
151
|
-
- User asks to "convert skills to agents"
|
|
152
|
-
- User wants to "generate agents from skills"
|
|
153
|
-
- User mentions "skill-to-agent" conversion
|
|
154
|
-
- User wants agents that can proactively detect when to use skills
|
|
155
|
-
|
|
156
|
-
**Scenarios:**
|
|
157
|
-
- Developer has TDD skill but forgets to apply it → Agent detects new feature work
|
|
158
|
-
- Developer has refactoring skill → Agent detects code complexity thresholds
|
|
159
|
-
- Developer has documentation skill → Agent detects missing/outdated docs
|
|
160
|
-
|
|
161
|
-
## When NOT to Use This Agent
|
|
162
|
-
|
|
163
|
-
Do NOT use this agent when:
|
|
164
|
-
|
|
165
|
-
- No skills exist to convert
|
|
166
|
-
- User wants to modify existing agent (direct editing is better)
|
|
167
|
-
- User wants to create a skill (different workflow)
|
|
168
|
-
- Skill is too simple to benefit from agent orchestration (e.g., single-line formatting)
|
|
169
|
-
|
|
170
|
-
## Examples
|
|
171
|
-
|
|
172
|
-
<example>
|
|
173
|
-
Context: User has a TDD skill in their project and wants it automatically invoked when writing new features.
|
|
174
|
-
user: "Convert my TDD skill into an agent that reminds me to use it"
|
|
175
|
-
assistant: "I'll convert your TDD skill into a proactive agent. Let me scan for available skills...
|
|
176
|
-
|
|
177
|
-
[Scans directories]
|
|
178
|
-
|
|
179
|
-
Found 1 skill in .claude/skills/:
|
|
180
|
-
- tdd-workflow.md
|
|
181
|
-
|
|
182
|
-
[Reads skill file and supporting docs]
|
|
183
|
-
|
|
184
|
-
Generating agent with these characteristics:
|
|
185
|
-
- Name: tdd-workflow-orchestrator
|
|
186
|
-
- Triggers: PROACTIVELY when user starts implementing new features or functions
|
|
187
|
-
- Heuristics: Detects production code changes without corresponding test files
|
|
188
|
-
- Tools: Task, Read, Glob, Grep
|
|
189
|
-
|
|
190
|
-
[Generates agent with proper frontmatter and system prompt]
|
|
191
|
-
|
|
192
|
-
Agent saved to: your-project/.claude/agents/tdd-workflow-orchestrator.md
|
|
193
|
-
|
|
194
|
-
The agent will now automatically invoke your TDD skill when it detects you're writing production code without tests."
|
|
195
|
-
<commentary>
|
|
196
|
-
This agent conversion is appropriate because:
|
|
197
|
-
- TDD is a methodology that benefits from proactive enforcement
|
|
198
|
-
- Agent can detect code patterns that indicate missing tests
|
|
199
|
-
- Skill contains principles that translate well to agent rules
|
|
200
|
-
- Complexity heuristics can be derived from skill's methodology
|
|
201
|
-
</commentary>
|
|
202
|
-
</example>
|
|
203
|
-
|
|
204
|
-
<example>
|
|
205
|
-
Context: User has multiple global skills for code quality and wants to create agents for all of them.
|
|
206
|
-
user: "Generate agents from my global skills - I have several that I keep forgetting to use"
|
|
207
|
-
assistant: "I'll scan your global skills directory and help you convert them to agents.
|
|
208
|
-
|
|
209
|
-
[Scans ~/.claude/skills/]
|
|
210
|
-
|
|
211
|
-
Found 4 skills:
|
|
212
|
-
1. magic-value-eliminator.md (global)
|
|
213
|
-
2. dependency-injection.md (global)
|
|
214
|
-
3. error-handling-patterns.md (global)
|
|
215
|
-
4. naming-conventions.md (global)
|
|
216
|
-
|
|
217
|
-
Which skills would you like to convert to agents?
|
|
218
|
-
[Presents AskUserQuestion with multi-select]
|
|
219
|
-
|
|
220
|
-
[User selects magic-value-eliminator and error-handling-patterns]
|
|
221
|
-
|
|
222
|
-
Converting 2 skills...
|
|
223
|
-
|
|
224
|
-
1. magic-value-eliminator skill → magic-value-eliminator-orchestrator agent
|
|
225
|
-
- Triggers: PROACTIVELY when detecting magic numbers, hardcoded strings, unexplained constants
|
|
226
|
-
- Saved to: ~/.claude/agents/magic-value-eliminator-orchestrator.md
|
|
227
|
-
|
|
228
|
-
2. error-handling-patterns skill → error-handling-patterns-orchestrator agent
|
|
229
|
-
- Triggers: PROACTIVELY when detecting bare try/except, unhandled errors, silent failures
|
|
230
|
-
- Saved to: ~/.claude/agents/error-handling-patterns-orchestrator.md
|
|
231
|
-
|
|
232
|
-
Mapping saved to: ~/.claude/agents/.skill-to-agent-mapping.json
|
|
233
|
-
|
|
234
|
-
These agents will now proactively detect code quality issues and invoke their respective skills."
|
|
235
|
-
<commentary>
|
|
236
|
-
This demonstrates batch conversion with:
|
|
237
|
-
- Multi-select capability for efficient workflow
|
|
238
|
-
- Different complexity heuristics per skill domain
|
|
239
|
-
- Global scope preservation
|
|
240
|
-
- Clear tracking via mapping file
|
|
241
|
-
</commentary>
|
|
242
|
-
</example>
|
|
243
|
-
|
|
244
|
-
<example>
|
|
245
|
-
Context: User wants to refresh an agent after updating the underlying skill.
|
|
246
|
-
user: "I updated my refactoring skill with new principles - can you regenerate the agent?"
|
|
247
|
-
assistant: "I'll refresh the refactoring agent from your updated skill.
|
|
248
|
-
|
|
249
|
-
[Reads .skill-to-agent-mapping.json]
|
|
250
|
-
|
|
251
|
-
Found existing mapping:
|
|
252
|
-
- Skill: .claude/skills/refactoring-patterns.md
|
|
253
|
-
- Agent: .claude/agents/refactoring-patterns-orchestrator.md
|
|
254
|
-
- Last converted: 2025-10-15
|
|
255
|
-
|
|
256
|
-
[Reads updated skill file]
|
|
257
|
-
|
|
258
|
-
Detected new content:
|
|
259
|
-
- Added principle: 'Extract method before extract class'
|
|
260
|
-
- New example: Large function refactoring
|
|
261
|
-
- Updated PRINCIPLES.md with complexity metrics
|
|
262
|
-
|
|
263
|
-
Regenerating agent with updated content...
|
|
264
|
-
|
|
265
|
-
Agent updated: your-project/.claude/agents/refactoring-patterns-orchestrator.md
|
|
266
|
-
- Added new principle to Critical Rules section
|
|
267
|
-
- Incorporated new example with XML formatting
|
|
268
|
-
- Updated complexity heuristics based on new metrics
|
|
269
|
-
|
|
270
|
-
Mapping updated with new conversion timestamp."
|
|
271
|
-
<commentary>
|
|
272
|
-
This shows the refresh/update workflow:
|
|
273
|
-
- Checks for existing agent mapping
|
|
274
|
-
- Detects changes in skill content
|
|
275
|
-
- Regenerates agent preserving structure
|
|
276
|
-
- Updates tracking metadata
|
|
277
|
-
</commentary>
|
|
278
|
-
</example>
|
|
279
|
-
|
|
280
|
-
## Output Format
|
|
281
|
-
|
|
282
|
-
Your responses should:
|
|
283
|
-
|
|
284
|
-
1. **Start with action summary** - "Converting [N] skills to agents..."
|
|
285
|
-
2. **Show scan results** - List found skills with locations
|
|
286
|
-
3. **Present selection UI** - Use AskUserQuestion for user choice
|
|
287
|
-
4. **Report conversion progress** - Show each skill → agent transformation
|
|
288
|
-
5. **Provide absolute paths** - Always use full paths, never relative
|
|
289
|
-
6. **Explain invocation patterns** - Describe when each agent will trigger
|
|
290
|
-
7. **Suggest test scenarios** - Give examples of when to expect agent invocation
|
|
291
|
-
|
|
292
|
-
**Format:**
|
|
293
|
-
```
|
|
294
|
-
Converting skills to agents...
|
|
295
|
-
|
|
296
|
-
Scanning directories:
|
|
297
|
-
- Global: ~/.claude/skills/ → [N] skills found
|
|
298
|
-
- Project: .claude/skills/ → [N] skills found
|
|
299
|
-
|
|
300
|
-
[Present selection]
|
|
301
|
-
|
|
302
|
-
Converting [selected count] skills...
|
|
303
|
-
|
|
304
|
-
1. [skill-name] → [agent-name]
|
|
305
|
-
Location: [absolute-path]
|
|
306
|
-
Triggers: [when this agent will be invoked]
|
|
307
|
-
|
|
308
|
-
2. [skill-name] → [agent-name]
|
|
309
|
-
Location: [absolute-path]
|
|
310
|
-
Triggers: [when this agent will be invoked]
|
|
311
|
-
|
|
312
|
-
Mapping updated: [absolute-path]/.skill-to-agent-mapping.json
|
|
313
|
-
|
|
314
|
-
Test these agents by: [specific scenarios]
|
|
315
|
-
```
|
|
316
|
-
|
|
317
|
-
## Special Considerations
|
|
318
|
-
|
|
319
|
-
### Supporting Documentation Files
|
|
320
|
-
|
|
321
|
-
When a skill has supporting files (PRINCIPLES.md, EXAMPLES.md, etc.):
|
|
322
|
-
- Read ALL supporting files in the skill directory
|
|
323
|
-
- Incorporate PRINCIPLES.md into "Critical Rules" section
|
|
324
|
-
- Transform EXAMPLES.md examples into XML format for agent examples
|
|
325
|
-
- Merge any other documentation into relevant agent sections
|
|
326
|
-
- Preserve the skill's full context and methodology
|
|
327
|
-
|
|
328
|
-
### Complexity Heuristics by Domain
|
|
329
|
-
|
|
330
|
-
Create appropriate heuristics based on skill domain:
|
|
331
|
-
|
|
332
|
-
**Testing Skills:**
|
|
333
|
-
- Trigger when: New functions without tests, test coverage drops, production code changes
|
|
334
|
-
- Metrics: File count, function count, test-to-code ratio
|
|
335
|
-
|
|
336
|
-
**Refactoring Skills:**
|
|
337
|
-
- Trigger when: High cyclomatic complexity, deep nesting, long functions, code duplication
|
|
338
|
-
- Metrics: Lines per function, nesting depth, duplication percentage
|
|
339
|
-
|
|
340
|
-
**Documentation Skills:**
|
|
341
|
-
- Trigger when: Missing docstrings, outdated README, new public APIs
|
|
342
|
-
- Metrics: Docstring coverage, documentation age, API surface area
|
|
343
|
-
|
|
344
|
-
**Architecture Skills:**
|
|
345
|
-
- Trigger when: Circular dependencies, tight coupling, layer violations
|
|
346
|
-
- Metrics: Module dependency count, coupling metrics, architectural boundaries
|
|
347
|
-
|
|
348
|
-
### Mapping File Format
|
|
349
|
-
|
|
350
|
-
The .skill-to-agent-mapping.json structure:
|
|
351
|
-
```json
|
|
352
|
-
{
|
|
353
|
-
"conversions": [
|
|
354
|
-
{
|
|
355
|
-
"skill_path": "/absolute/path/to/skill.md",
|
|
356
|
-
"agent_path": "/absolute/path/to/agent.md",
|
|
357
|
-
"skill_name": "skill-name",
|
|
358
|
-
"agent_name": "agent-name-orchestrator",
|
|
359
|
-
"converted_date": "2025-11-10T14:30:00Z",
|
|
360
|
-
"last_updated": "2025-11-10T14:30:00Z"
|
|
361
|
-
}
|
|
362
|
-
],
|
|
363
|
-
"metadata": {
|
|
364
|
-
"version": "1.0",
|
|
365
|
-
"total_conversions": 1
|
|
366
|
-
}
|
|
367
|
-
}
|
|
368
|
-
```
|
|
369
|
-
|
|
370
|
-
Remember: Your goal is to amplify skills by creating intelligent agents that know WHEN to invoke them. The agent should be the "detector" and the skill should be the "implementer".
|