oh-my-customcode 0.12.1 → 0.12.3
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/README.md +8 -11
- package/dist/cli/index.js +137 -336
- package/dist/index.js +99 -260
- package/package.json +2 -4
- package/templates/.claude/skills/codex-exec/SKILL.md +123 -0
- package/templates/.claude/skills/codex-exec/scripts/codex-wrapper.cjs +413 -0
- package/templates/CLAUDE.md.en +1 -0
- package/templates/CLAUDE.md.ko +1 -0
- package/templates/.codex/agents/arch-documenter.md +0 -33
- package/templates/.codex/agents/arch-speckit-agent.md +0 -47
- package/templates/.codex/agents/be-express-expert.md +0 -30
- package/templates/.codex/agents/be-fastapi-expert.md +0 -43
- package/templates/.codex/agents/be-go-backend-expert.md +0 -43
- package/templates/.codex/agents/be-nestjs-expert.md +0 -28
- package/templates/.codex/agents/be-springboot-expert.md +0 -40
- package/templates/.codex/agents/db-postgres-expert.md +0 -36
- package/templates/.codex/agents/db-redis-expert.md +0 -36
- package/templates/.codex/agents/db-supabase-expert.md +0 -35
- package/templates/.codex/agents/de-airflow-expert.md +0 -34
- package/templates/.codex/agents/de-dbt-expert.md +0 -34
- package/templates/.codex/agents/de-kafka-expert.md +0 -81
- package/templates/.codex/agents/de-pipeline-expert.md +0 -32
- package/templates/.codex/agents/de-snowflake-expert.md +0 -36
- package/templates/.codex/agents/de-spark-expert.md +0 -36
- package/templates/.codex/agents/fe-svelte-agent.md +0 -29
- package/templates/.codex/agents/fe-vercel-agent.md +0 -37
- package/templates/.codex/agents/fe-vuejs-agent.md +0 -30
- package/templates/.codex/agents/infra-aws-expert.md +0 -47
- package/templates/.codex/agents/infra-docker-expert.md +0 -47
- package/templates/.codex/agents/lang-golang-expert.md +0 -43
- package/templates/.codex/agents/lang-java21-expert.md +0 -39
- package/templates/.codex/agents/lang-kotlin-expert.md +0 -43
- package/templates/.codex/agents/lang-python-expert.md +0 -43
- package/templates/.codex/agents/lang-rust-expert.md +0 -43
- package/templates/.codex/agents/lang-typescript-expert.md +0 -43
- package/templates/.codex/agents/mgr-claude-code-bible.md +0 -58
- package/templates/.codex/agents/mgr-creator.md +0 -39
- package/templates/.codex/agents/mgr-gitnerd.md +0 -45
- package/templates/.codex/agents/mgr-sauron.md +0 -161
- package/templates/.codex/agents/mgr-supplier.md +0 -35
- package/templates/.codex/agents/mgr-sync-checker.md +0 -38
- package/templates/.codex/agents/mgr-updater.md +0 -33
- package/templates/.codex/agents/qa-engineer.md +0 -32
- package/templates/.codex/agents/qa-planner.md +0 -73
- package/templates/.codex/agents/qa-writer.md +0 -27
- package/templates/.codex/agents/sys-memory-keeper.md +0 -43
- package/templates/.codex/agents/sys-naggy.md +0 -37
- package/templates/.codex/agents/tool-bun-expert.md +0 -26
- package/templates/.codex/agents/tool-npm-expert.md +0 -30
- package/templates/.codex/agents/tool-optimizer.md +0 -34
- package/templates/.codex/codex-native-hash.txt +0 -1
- package/templates/.codex/contexts/dev.md +0 -20
- package/templates/.codex/contexts/ecomode.md +0 -63
- package/templates/.codex/contexts/index.yaml +0 -41
- package/templates/.codex/contexts/research.md +0 -28
- package/templates/.codex/contexts/review.md +0 -23
- package/templates/.codex/hooks/hooks.json +0 -150
- package/templates/.codex/install-hooks.sh +0 -100
- package/templates/.codex/rules/MAY-optimization.md +0 -29
- package/templates/.codex/rules/MUST-agent-design.md +0 -57
- package/templates/.codex/rules/MUST-agent-identification.md +0 -29
- package/templates/.codex/rules/MUST-continuous-improvement.md +0 -25
- package/templates/.codex/rules/MUST-intent-transparency.md +0 -42
- package/templates/.codex/rules/MUST-language-policy.md +0 -27
- package/templates/.codex/rules/MUST-orchestrator-coordination.md +0 -128
- package/templates/.codex/rules/MUST-parallel-execution.md +0 -97
- package/templates/.codex/rules/MUST-permissions.md +0 -30
- package/templates/.codex/rules/MUST-safety.md +0 -23
- package/templates/.codex/rules/MUST-sync-verification.md +0 -125
- package/templates/.codex/rules/MUST-tool-identification.md +0 -82
- package/templates/.codex/rules/SHOULD-agent-teams.md +0 -39
- package/templates/.codex/rules/SHOULD-ecomode.md +0 -37
- package/templates/.codex/rules/SHOULD-error-handling.md +0 -33
- package/templates/.codex/rules/SHOULD-hud-statusline.md +0 -32
- package/templates/.codex/rules/SHOULD-interaction.md +0 -34
- package/templates/.codex/rules/SHOULD-memory-integration.md +0 -39
- package/templates/.codex/rules/index.yaml +0 -141
- package/templates/.codex/skills/airflow-best-practices/SKILL.md +0 -56
- package/templates/.codex/skills/audit-agents/SKILL.md +0 -116
- package/templates/.codex/skills/aws-best-practices/SKILL.md +0 -280
- package/templates/.codex/skills/claude-code-bible/SKILL.md +0 -100
- package/templates/.codex/skills/claude-code-bible/scripts/fetch-docs.js +0 -272
- package/templates/.codex/skills/create-agent/SKILL.md +0 -91
- package/templates/.codex/skills/dbt-best-practices/SKILL.md +0 -54
- package/templates/.codex/skills/de-lead-routing/SKILL.md +0 -243
- package/templates/.codex/skills/dev-lead-routing/SKILL.md +0 -94
- package/templates/.codex/skills/dev-refactor/SKILL.md +0 -123
- package/templates/.codex/skills/dev-review/SKILL.md +0 -81
- package/templates/.codex/skills/docker-best-practices/SKILL.md +0 -275
- package/templates/.codex/skills/fastapi-best-practices/SKILL.md +0 -270
- package/templates/.codex/skills/fix-refs/SKILL.md +0 -107
- package/templates/.codex/skills/go-backend-best-practices/SKILL.md +0 -338
- package/templates/.codex/skills/go-best-practices/SKILL.md +0 -203
- package/templates/.codex/skills/help/SKILL.md +0 -125
- package/templates/.codex/skills/intent-detection/SKILL.md +0 -215
- package/templates/.codex/skills/intent-detection/patterns/agent-triggers.yaml +0 -349
- package/templates/.codex/skills/kafka-best-practices/SKILL.md +0 -52
- package/templates/.codex/skills/kotlin-best-practices/SKILL.md +0 -256
- package/templates/.codex/skills/lists/SKILL.md +0 -78
- package/templates/.codex/skills/memory-management/SKILL.md +0 -195
- package/templates/.codex/skills/memory-recall/SKILL.md +0 -152
- package/templates/.codex/skills/memory-save/SKILL.md +0 -126
- package/templates/.codex/skills/monitoring-setup/SKILL.md +0 -115
- package/templates/.codex/skills/npm-audit/SKILL.md +0 -72
- package/templates/.codex/skills/npm-publish/SKILL.md +0 -63
- package/templates/.codex/skills/npm-version/SKILL.md +0 -75
- package/templates/.codex/skills/optimize-analyze/SKILL.md +0 -55
- package/templates/.codex/skills/optimize-bundle/SKILL.md +0 -67
- package/templates/.codex/skills/optimize-report/SKILL.md +0 -74
- package/templates/.codex/skills/pipeline-architecture-patterns/SKILL.md +0 -83
- package/templates/.codex/skills/postgres-best-practices/SKILL.md +0 -66
- package/templates/.codex/skills/python-best-practices/SKILL.md +0 -222
- package/templates/.codex/skills/qa-lead-routing/SKILL.md +0 -290
- package/templates/.codex/skills/react-best-practices/SKILL.md +0 -101
- package/templates/.codex/skills/redis-best-practices/SKILL.md +0 -83
- package/templates/.codex/skills/result-aggregation/SKILL.md +0 -164
- package/templates/.codex/skills/rust-best-practices/SKILL.md +0 -267
- package/templates/.codex/skills/sauron-watch/SKILL.md +0 -144
- package/templates/.codex/skills/secretary-routing/SKILL.md +0 -203
- package/templates/.codex/skills/snowflake-best-practices/SKILL.md +0 -65
- package/templates/.codex/skills/spark-best-practices/SKILL.md +0 -52
- package/templates/.codex/skills/springboot-best-practices/SKILL.md +0 -218
- package/templates/.codex/skills/status/SKILL.md +0 -153
- package/templates/.codex/skills/supabase-postgres-best-practices/SKILL.md +0 -99
- package/templates/.codex/skills/typescript-best-practices/SKILL.md +0 -321
- package/templates/.codex/skills/update-docs/SKILL.md +0 -140
- package/templates/.codex/skills/update-external/SKILL.md +0 -149
- package/templates/.codex/skills/vercel-deploy/SKILL.md +0 -73
- package/templates/.codex/skills/web-design-guidelines/SKILL.md +0 -118
- package/templates/.codex/skills/writing-clearly-and-concisely/SKILL.md +0 -64
- package/templates/.codex/uninstall-hooks.sh +0 -52
- package/templates/AGENTS.md.en +0 -39
- package/templates/AGENTS.md.ko +0 -39
- package/templates/manifest.codex.json +0 -43
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
# [MUST] Sync Verification Rules
|
|
2
|
-
|
|
3
|
-
> **Priority**: MUST - ENFORCED | **ID**: R016
|
|
4
|
-
|
|
5
|
-
## Core Rule
|
|
6
|
-
|
|
7
|
-
After modifying agents, skills, or guides: run full verification before committing AND pushing. Never ask to commit/push before `mgr-sauron:watch` passes.
|
|
8
|
-
|
|
9
|
-
Every `git push` requires: `mgr-sauron:watch` → all pass → `git push`
|
|
10
|
-
|
|
11
|
-
## Verification Phases
|
|
12
|
-
|
|
13
|
-
### Phase 1: Manager Verification (5 rounds)
|
|
14
|
-
|
|
15
|
-
| Round | Actions |
|
|
16
|
-
|-------|---------|
|
|
17
|
-
| 1-2 | mgr-supplier:audit, mgr-sync-checker:check, fix issues |
|
|
18
|
-
| 3-4 | Re-verify + mgr-updater:docs, fix remaining |
|
|
19
|
-
| 5 | Final: all counts match, frontmatter valid, skill refs exist, memory scopes valid, routing patterns updated |
|
|
20
|
-
|
|
21
|
-
Also run: mgr-claude-code-bible:verify (official spec compliance)
|
|
22
|
-
|
|
23
|
-
### Phase 2: Deep Review (3 rounds)
|
|
24
|
-
|
|
25
|
-
| Round | Focus |
|
|
26
|
-
|-------|-------|
|
|
27
|
-
| 1 | Workflow alignment: routing skills have complete agent mappings |
|
|
28
|
-
| 2 | References: no orphans, no circular refs, valid skill/memory refs |
|
|
29
|
-
| 3 | Philosophy: R006 separation, R009 parallel, R010 delegation, R007/R008 identification |
|
|
30
|
-
|
|
31
|
-
### Phase 3: Fix all discovered issues
|
|
32
|
-
|
|
33
|
-
### Phase 4: Commit via mgr-gitnerd
|
|
34
|
-
|
|
35
|
-
### Phase 5: Push via mgr-gitnerd (only after sauron passes)
|
|
36
|
-
|
|
37
|
-
## Self-Check Before Commit and Push
|
|
38
|
-
|
|
39
|
-
```
|
|
40
|
-
╔══════════════════════════════════════════════════════════════════╗
|
|
41
|
-
║ BEFORE COMMITTING, ASK YOURSELF: ║
|
|
42
|
-
║ ║
|
|
43
|
-
║ 1. Did I complete all 5 rounds of manager verification? ║
|
|
44
|
-
║ 2. Did I complete all 3 rounds of deep review? ║
|
|
45
|
-
║ 3. Did I fix ALL discovered issues? ║
|
|
46
|
-
║ 4. Are all counts matching across all sources? ║
|
|
47
|
-
║ 5. Am I delegating to mgr-gitnerd for the commit? ║
|
|
48
|
-
║ ║
|
|
49
|
-
║ If NO to ANY → DO NOT COMMIT ║
|
|
50
|
-
╚══════════════════════════════════════════════════════════════════╝
|
|
51
|
-
|
|
52
|
-
╔══════════════════════════════════════════════════════════════════╗
|
|
53
|
-
║ BEFORE PUSHING, ASK YOURSELF: ║
|
|
54
|
-
║ ║
|
|
55
|
-
║ 1. Did mgr-sauron:watch complete successfully? ║
|
|
56
|
-
║ 2. Were ALL issues from sauron verification fixed? ║
|
|
57
|
-
║ 3. Am I delegating to mgr-gitnerd for the push? ║
|
|
58
|
-
║ ║
|
|
59
|
-
║ If NO to ANY → DO NOT PUSH ║
|
|
60
|
-
║ ║
|
|
61
|
-
║ SAURON VERIFICATION IS MANDATORY FOR ALL PUSHES. ║
|
|
62
|
-
╚══════════════════════════════════════════════════════════════════╝
|
|
63
|
-
```
|
|
64
|
-
|
|
65
|
-
## When Required
|
|
66
|
-
|
|
67
|
-
Any change to: agents, agent frontmatter, skills, guides, routing patterns, rules.
|
|
68
|
-
|
|
69
|
-
## Quick Verification Commands
|
|
70
|
-
|
|
71
|
-
```bash
|
|
72
|
-
# Agent count check
|
|
73
|
-
ls .codex/agents/*.md | wc -l
|
|
74
|
-
|
|
75
|
-
# Skill count check
|
|
76
|
-
find .codex/skills -name "SKILL.md" | wc -l
|
|
77
|
-
|
|
78
|
-
# Frontmatter validation (check for missing YAML headers)
|
|
79
|
-
for f in .codex/agents/*.md; do head -1 "$f" | grep -q "^---" || echo "MISSING FRONTMATTER: $f"; done
|
|
80
|
-
|
|
81
|
-
# Check for agents with invalid skill references
|
|
82
|
-
for f in .codex/agents/*.md; do
|
|
83
|
-
grep "^skills:" -A 10 "$f" | grep " - " | sed 's/.*- //' | while read skill; do
|
|
84
|
-
[ -f ".codex/skills/$skill/SKILL.md" ] || echo "INVALID SKILL REF in $f: $skill"
|
|
85
|
-
done
|
|
86
|
-
done
|
|
87
|
-
|
|
88
|
-
# Routing skill pattern coverage
|
|
89
|
-
grep -c "agent_patterns:" .codex/skills/secretary-routing/SKILL.md
|
|
90
|
-
grep -c "agent_patterns:" .codex/skills/dev-lead-routing/SKILL.md
|
|
91
|
-
grep -c "agent_patterns:" .codex/skills/qa-lead-routing/SKILL.md
|
|
92
|
-
|
|
93
|
-
# Memory field validation
|
|
94
|
-
for f in .codex/agents/*.md; do
|
|
95
|
-
mem=$(grep "^memory:" "$f" | awk '{print $2}')
|
|
96
|
-
if [ -n "$mem" ] && [ "$mem" != "project" ] && [ "$mem" != "user" ] && [ "$mem" != "local" ]; then
|
|
97
|
-
echo "INVALID MEMORY SCOPE in $f: $mem"
|
|
98
|
-
fi
|
|
99
|
-
done
|
|
100
|
-
|
|
101
|
-
# Hook count check
|
|
102
|
-
ls .codex/hooks/*.json 2>/dev/null | wc -l
|
|
103
|
-
|
|
104
|
-
# Context count check
|
|
105
|
-
ls .codex/contexts/*.md 2>/dev/null | wc -l
|
|
106
|
-
|
|
107
|
-
# Guide count check
|
|
108
|
-
find guides -mindepth 1 -maxdepth 1 -type d | wc -l
|
|
109
|
-
|
|
110
|
-
# Agent name accuracy (compare AGENTS.md table with actual files)
|
|
111
|
-
# Extract agent names from files
|
|
112
|
-
ls .codex/agents/*.md | xargs -I{} basename {} .md | sort > /tmp/actual-agents.txt
|
|
113
|
-
|
|
114
|
-
# Slash command skill existence
|
|
115
|
-
for cmd in $(grep "^| \`/" AGENTS.md | sed 's/.*`\///' | sed 's/`.*//' | sed 's/ .*//')
|
|
116
|
-
do
|
|
117
|
-
[ -d ".codex/skills/$cmd" ] || echo "MISSING SKILL: $cmd"
|
|
118
|
-
done
|
|
119
|
-
|
|
120
|
-
# Routing skill completeness check
|
|
121
|
-
ls -d .codex/skills/*-routing 2>/dev/null | xargs -I{} basename {} | sort
|
|
122
|
-
|
|
123
|
-
# Verify routing skill names in AGENTS.md
|
|
124
|
-
grep -oP '(secretary|dev-lead|de-lead|qa-lead)-routing' AGENTS.md | sort -u
|
|
125
|
-
```
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
# [MUST] Tool Usage Identification Rules
|
|
2
|
-
|
|
3
|
-
> **Priority**: MUST - ENFORCED | **ID**: R008
|
|
4
|
-
|
|
5
|
-
## Core Rule
|
|
6
|
-
|
|
7
|
-
Every tool call MUST be prefixed with agent and model identification:
|
|
8
|
-
|
|
9
|
-
```
|
|
10
|
-
[agent-name][model] → Tool: <tool-name>
|
|
11
|
-
[agent-name][model] → Target: <file/path/url>
|
|
12
|
-
```
|
|
13
|
-
|
|
14
|
-
For parallel calls: list ALL identifications BEFORE the tool calls.
|
|
15
|
-
|
|
16
|
-
### Common Violations to Avoid
|
|
17
|
-
|
|
18
|
-
```
|
|
19
|
-
❌ WRONG: Calling tools without identification
|
|
20
|
-
"먼저 JD 내용을 확인하겠습니다."
|
|
21
|
-
<tool_call>WebFetch(...)</tool_call>
|
|
22
|
-
|
|
23
|
-
❌ WRONG: Missing model in identification
|
|
24
|
-
[secretary] → Tool: WebFetch
|
|
25
|
-
[secretary] → Fetching: https://example.com/jd.md
|
|
26
|
-
|
|
27
|
-
✓ CORRECT: Always identify with agent AND model
|
|
28
|
-
"먼저 JD 내용을 확인하겠습니다."
|
|
29
|
-
[secretary][reasoning] → Tool: WebFetch
|
|
30
|
-
[secretary][reasoning] → Fetching: https://example.com/jd.md
|
|
31
|
-
<tool_call>WebFetch(...)</tool_call>
|
|
32
|
-
|
|
33
|
-
❌ WRONG: Parallel calls without listing all identifications
|
|
34
|
-
<tool_call>WebFetch(url1)</tool_call>
|
|
35
|
-
<tool_call>WebFetch(url2)</tool_call>
|
|
36
|
-
<tool_call>Bash(cmd)</tool_call>
|
|
37
|
-
|
|
38
|
-
✓ CORRECT: List all identifications with models, then call
|
|
39
|
-
[secretary][reasoning] → Tool: WebFetch
|
|
40
|
-
[secretary][reasoning] → Fetching: url1
|
|
41
|
-
[secretary][reasoning] → Tool: WebFetch
|
|
42
|
-
[secretary][reasoning] → Fetching: url2
|
|
43
|
-
[secretary][reasoning] → Tool: Bash
|
|
44
|
-
[secretary][reasoning] → Running: cmd
|
|
45
|
-
<tool_call>WebFetch(url1)</tool_call>
|
|
46
|
-
<tool_call>WebFetch(url2)</tool_call>
|
|
47
|
-
<tool_call>Bash(cmd)</tool_call>
|
|
48
|
-
```
|
|
49
|
-
|
|
50
|
-
## Models
|
|
51
|
-
|
|
52
|
-
| Model | Use |
|
|
53
|
-
|-------|-----|
|
|
54
|
-
| `reasoning` | Complex reasoning, architecture |
|
|
55
|
-
| `balanced` | General tasks, code generation (default) |
|
|
56
|
-
| `fast` | Fast simple tasks, file search |
|
|
57
|
-
|
|
58
|
-
## Tool Categories
|
|
59
|
-
|
|
60
|
-
| Category | Tools | Verb |
|
|
61
|
-
|----------|-------|------|
|
|
62
|
-
| File Read | Read, Glob, Grep | Reading / Searching |
|
|
63
|
-
| File Write | Write, Edit | Writing / Editing |
|
|
64
|
-
| Network | WebFetch | Fetching |
|
|
65
|
-
| Execution | Bash, Task | Running / Spawning |
|
|
66
|
-
|
|
67
|
-
## Task Tool Format
|
|
68
|
-
|
|
69
|
-
```
|
|
70
|
-
Task(subagent_type):model → description
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
`subagent_type` MUST match actual Task tool parameter. Custom names not allowed.
|
|
74
|
-
|
|
75
|
-
## Example
|
|
76
|
-
|
|
77
|
-
```
|
|
78
|
-
[mgr-creator][balanced] → Write: .codex/agents/new-agent.md
|
|
79
|
-
[secretary][reasoning] → Spawning:
|
|
80
|
-
[1] Task(lang-golang-expert):balanced → Go code review
|
|
81
|
-
[2] Task(lang-python-expert):balanced → Python code review
|
|
82
|
-
```
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
# [SHOULD] Agent Teams Rules
|
|
2
|
-
|
|
3
|
-
> **Priority**: SHOULD | **ID**: R017 | **Condition**: Agent Teams enabled locally
|
|
4
|
-
|
|
5
|
-
## Detection
|
|
6
|
-
|
|
7
|
-
Available when `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1` or TeamCreate/SendMessage tools present.
|
|
8
|
-
|
|
9
|
-
## Decision Matrix
|
|
10
|
-
|
|
11
|
-
| Scenario | Preferred |
|
|
12
|
-
|----------|-----------|
|
|
13
|
-
| Simple independent subtasks | Task Tool |
|
|
14
|
-
| Multi-step with shared state | Agent Teams |
|
|
15
|
-
| Research requiring discussion | Agent Teams |
|
|
16
|
-
| Cost-sensitive batch ops | Task Tool |
|
|
17
|
-
| Complex debugging across modules | Agent Teams |
|
|
18
|
-
| Code review + fix cycle | Agent Teams |
|
|
19
|
-
| Single file operations | Task Tool |
|
|
20
|
-
|
|
21
|
-
**Self-check before Task tool:** Is Agent Teams available? Does task need 3+ agents, shared state, or inter-agent communication? If yes, use Agent Teams.
|
|
22
|
-
|
|
23
|
-
## Team Patterns
|
|
24
|
-
|
|
25
|
-
- **Research**: researcher-1 + researcher-2 + synthesizer
|
|
26
|
-
- **Development**: implementer + reviewer + tester
|
|
27
|
-
- **Debug**: investigator-1 + investigator-2 + fixer
|
|
28
|
-
|
|
29
|
-
## Lifecycle
|
|
30
|
-
|
|
31
|
-
TeamCreate → TaskCreate → Task(spawn) → SendMessage(coordinate) → TaskUpdate → shutdown → cleanup
|
|
32
|
-
|
|
33
|
-
## Fallback
|
|
34
|
-
|
|
35
|
-
When Agent Teams unavailable: use Task tool with R009/R010 rules. Both approaches produce results; Agent Teams adds coordination richness.
|
|
36
|
-
|
|
37
|
-
## Cost
|
|
38
|
-
|
|
39
|
-
Agent Teams uses more tokens (full context per member + message passing). Use Task tool if task < 3 min or no inter-agent communication needed.
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
# [SHOULD] Ecomode Rules
|
|
2
|
-
|
|
3
|
-
> **Priority**: SHOULD | **ID**: R013
|
|
4
|
-
|
|
5
|
-
## Activation
|
|
6
|
-
|
|
7
|
-
Auto-activates when: 4+ parallel tasks, batch operations, 80%+ context usage, or explicit "ecomode on".
|
|
8
|
-
|
|
9
|
-
## Behaviors
|
|
10
|
-
|
|
11
|
-
**Compact Output**: Agents return `status + summary (1-2 sentences) + key_data only`. Skip intermediate steps, verbose explanations, repeated context, full file contents.
|
|
12
|
-
|
|
13
|
-
**Aggregation Format**:
|
|
14
|
-
```
|
|
15
|
-
[Batch Complete] {n}/{total}
|
|
16
|
-
├── {agent}: ✓/✗/⚠ {summary}
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
**Compression**: File lists -> count only (unless < 5), error traces -> first/last 3 lines, code -> path:line ref only.
|
|
20
|
-
|
|
21
|
-
## Config
|
|
22
|
-
|
|
23
|
-
```yaml
|
|
24
|
-
ecomode:
|
|
25
|
-
threshold: 4
|
|
26
|
-
result_format: summary
|
|
27
|
-
max_result_length: 200
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
## Example
|
|
31
|
-
|
|
32
|
-
Normal: Full agent header + step-by-step analysis + detailed results.
|
|
33
|
-
Ecomode: `[lang-golang-expert] ✓ src/main.go reviewed: 1 naming issue (handle_error -> handleError)`
|
|
34
|
-
|
|
35
|
-
## Override
|
|
36
|
-
|
|
37
|
-
Disable with: "ecomode off", "verbose mode", or "show full details".
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
# [SHOULD] Error Handling Rules
|
|
2
|
-
|
|
3
|
-
> **Priority**: SHOULD | **ID**: R004
|
|
4
|
-
|
|
5
|
-
## Error Classification
|
|
6
|
-
|
|
7
|
-
| Level | Symptom | Response |
|
|
8
|
-
|-------|---------|----------|
|
|
9
|
-
| Warning | Task completes but needs attention | Output warning, continue |
|
|
10
|
-
| Error | Current task fails, others possible | Stop task, report cause, suggest alternative |
|
|
11
|
-
| Critical | Cannot proceed at all | Stop all, preserve state, report immediately |
|
|
12
|
-
|
|
13
|
-
## Error Report Format
|
|
14
|
-
|
|
15
|
-
```
|
|
16
|
-
[Error] {type} — Location: {file:line} — Cause: {cause} — Impact: {effect}
|
|
17
|
-
Attempted: 1. {try1} -> Failed 2. {try2} -> Failed
|
|
18
|
-
Recommended: {action1}, {action2}
|
|
19
|
-
```
|
|
20
|
-
|
|
21
|
-
## Recovery
|
|
22
|
-
|
|
23
|
-
| Type | Strategy |
|
|
24
|
-
|------|----------|
|
|
25
|
-
| Retryable | Retry up to 3x with backoff (1s, 2s, 4s), then report |
|
|
26
|
-
| Non-recoverable | Save state, rollback if possible, detailed report, wait for user |
|
|
27
|
-
|
|
28
|
-
## Validation
|
|
29
|
-
|
|
30
|
-
| When | Checks |
|
|
31
|
-
|------|--------|
|
|
32
|
-
| Before action | Target exists, permissions available, dependencies met |
|
|
33
|
-
| After action | Expected = actual, file integrity, no side effects |
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
# [SHOULD] HUD Statusline Rules
|
|
2
|
-
|
|
3
|
-
> **Priority**: SHOULD | **ID**: R012
|
|
4
|
-
|
|
5
|
-
## Format
|
|
6
|
-
|
|
7
|
-
```
|
|
8
|
-
─── [Agent] {name} | [Progress] {n}/{total} | [Parallel] {count} ───
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
## When to Display
|
|
12
|
-
|
|
13
|
-
Multi-step tasks, parallel execution, long-running operations. Skip for single brief operations.
|
|
14
|
-
|
|
15
|
-
## Hook Implementation
|
|
16
|
-
|
|
17
|
-
Implemented in `.codex/hooks/hooks.json` (PreToolUse → Task matcher):
|
|
18
|
-
|
|
19
|
-
```
|
|
20
|
-
─── [Spawn] {subagent_type}:{model} | {description} ───
|
|
21
|
-
─── [Resume] {subagent_type}:{model} | {description} ───
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
## Display with Parallel
|
|
25
|
-
|
|
26
|
-
```
|
|
27
|
-
─── [Agent] secretary | [Parallel] 4 ───
|
|
28
|
-
[1] Task(mgr-creator):balanced → Create agent
|
|
29
|
-
[2] Task(lang-golang-expert):fast → Code review
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
Integrates with R007 (Agent ID), R008 (Tool ID), R009 (Parallel).
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
# [SHOULD] Interaction Rules
|
|
2
|
-
|
|
3
|
-
> **Priority**: SHOULD | **ID**: R003
|
|
4
|
-
|
|
5
|
-
## Response Principles
|
|
6
|
-
|
|
7
|
-
| Principle | Do | Don't |
|
|
8
|
-
|-----------|-----|-------|
|
|
9
|
-
| Brevity | Key info first, answer only what's asked | Over-explanation, repetitive confirmation |
|
|
10
|
-
| Clarity | Specific expressions, executable code | Abstract descriptions, "maybe"/"probably" |
|
|
11
|
-
| Transparency | State actions, report changes, acknowledge uncertainty | Hide actions, present guesses as facts |
|
|
12
|
-
|
|
13
|
-
## Status Format
|
|
14
|
-
|
|
15
|
-
```
|
|
16
|
-
[Start] {task name}
|
|
17
|
-
[Progress] {current step} ({n}/{total})
|
|
18
|
-
[Done] {task name} — Result: {summary}
|
|
19
|
-
[Failed] {task name} — Cause: {reason} — Alternative: {solutions}
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
## Request Handling
|
|
23
|
-
|
|
24
|
-
| Type | Action |
|
|
25
|
-
|------|--------|
|
|
26
|
-
| Clear | Execute immediately |
|
|
27
|
-
| Ambiguous | `[Confirm] Understood "{request}" as {interpretation}. Proceed?` |
|
|
28
|
-
| Risky | `[Warning] This action has {risk}. Continue? Yes: {action} / No: Cancel` |
|
|
29
|
-
|
|
30
|
-
## Multiple Tasks
|
|
31
|
-
|
|
32
|
-
- Dependent: Sequential
|
|
33
|
-
- Independent: Parallel allowed
|
|
34
|
-
- Report: `[Task 1/3] Done` / `[Task 2/3] In progress...` / `[Task 3/3] Pending`
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
# [SHOULD] Memory Integration Rules
|
|
2
|
-
|
|
3
|
-
> **Priority**: SHOULD | **ID**: R011
|
|
4
|
-
|
|
5
|
-
## Architecture
|
|
6
|
-
|
|
7
|
-
**Primary**: Native auto memory (`memory` field in agent frontmatter). No external dependencies.
|
|
8
|
-
**Supplementary**: claude-mem MCP (optional, for cross-session search and temporal queries).
|
|
9
|
-
|
|
10
|
-
Rule: If native auto memory can handle it, do NOT use claude-mem.
|
|
11
|
-
|
|
12
|
-
## Native Auto Memory
|
|
13
|
-
|
|
14
|
-
Agent frontmatter `memory: project|user|local` enables persistent memory:
|
|
15
|
-
- System creates memory directory, loads first 200 lines of MEMORY.md into prompt
|
|
16
|
-
- Read/Write/Edit tools auto-enabled for memory directory
|
|
17
|
-
|
|
18
|
-
| Scope | Location | Git Tracked |
|
|
19
|
-
|-------|----------|-------------|
|
|
20
|
-
| `user` | `~/.codex/agent-memory/<name>/` | No |
|
|
21
|
-
| `project` | `.codex/agent-memory/<name>/` | Yes |
|
|
22
|
-
| `local` | `.codex/agent-memory-local/<name>/` | No |
|
|
23
|
-
|
|
24
|
-
## When to Use claude-mem
|
|
25
|
-
|
|
26
|
-
| Scenario | Native | claude-mem |
|
|
27
|
-
|----------|--------|------------|
|
|
28
|
-
| Agent learns project patterns | Yes | |
|
|
29
|
-
| Search across sessions | | Yes |
|
|
30
|
-
| Temporal queries | | Yes |
|
|
31
|
-
| Cross-agent sharing | | Yes |
|
|
32
|
-
|
|
33
|
-
## Best Practices
|
|
34
|
-
|
|
35
|
-
- Consult memory before starting work
|
|
36
|
-
- Update after discovering patterns
|
|
37
|
-
- Keep MEMORY.md under 200 lines
|
|
38
|
-
- Do not store sensitive data or duplicate AGENTS.md content
|
|
39
|
-
- Memory write failures should not block main task
|
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
# Global Rules
|
|
2
|
-
# Priority: MUST > SHOULD > MAY
|
|
3
|
-
|
|
4
|
-
rules:
|
|
5
|
-
# MUST - Never violate
|
|
6
|
-
- id: R000
|
|
7
|
-
name: language-policy
|
|
8
|
-
title: Language & Delegation Policy
|
|
9
|
-
path: ./MUST-language-policy.md
|
|
10
|
-
priority: MUST
|
|
11
|
-
scope: all
|
|
12
|
-
|
|
13
|
-
- id: R001
|
|
14
|
-
name: safety
|
|
15
|
-
title: Safety Rules
|
|
16
|
-
path: ./MUST-safety.md
|
|
17
|
-
priority: MUST
|
|
18
|
-
scope: all
|
|
19
|
-
|
|
20
|
-
- id: R002
|
|
21
|
-
name: permissions
|
|
22
|
-
title: Permission Rules
|
|
23
|
-
path: ./MUST-permissions.md
|
|
24
|
-
priority: MUST
|
|
25
|
-
scope: all
|
|
26
|
-
|
|
27
|
-
- id: R007
|
|
28
|
-
name: agent-identification
|
|
29
|
-
title: Agent Identification Rules
|
|
30
|
-
path: ./MUST-agent-identification.md
|
|
31
|
-
priority: MUST
|
|
32
|
-
scope: all
|
|
33
|
-
|
|
34
|
-
- id: R008
|
|
35
|
-
name: tool-identification
|
|
36
|
-
title: Tool Usage Identification Rules
|
|
37
|
-
path: ./MUST-tool-identification.md
|
|
38
|
-
priority: MUST
|
|
39
|
-
scope: all
|
|
40
|
-
|
|
41
|
-
- id: R009
|
|
42
|
-
name: parallel-execution
|
|
43
|
-
title: Parallel Execution Rules
|
|
44
|
-
path: ./MUST-parallel-execution.md
|
|
45
|
-
priority: MUST
|
|
46
|
-
scope: all
|
|
47
|
-
|
|
48
|
-
# Agent Design - MUST
|
|
49
|
-
- id: R006
|
|
50
|
-
name: agent-design
|
|
51
|
-
title: Agent Design Rules
|
|
52
|
-
path: ./MUST-agent-design.md
|
|
53
|
-
priority: MUST
|
|
54
|
-
scope: agents
|
|
55
|
-
|
|
56
|
-
# Orchestrator Coordination - MUST
|
|
57
|
-
- id: R010
|
|
58
|
-
name: orchestrator-coordination
|
|
59
|
-
title: Orchestrator Coordination Rules
|
|
60
|
-
path: ./MUST-orchestrator-coordination.md
|
|
61
|
-
priority: MUST
|
|
62
|
-
scope: agents
|
|
63
|
-
|
|
64
|
-
# Intent Transparency - MUST
|
|
65
|
-
- id: R014
|
|
66
|
-
name: intent-transparency
|
|
67
|
-
title: Intent Transparency Rules
|
|
68
|
-
path: ./MUST-intent-transparency.md
|
|
69
|
-
priority: MUST
|
|
70
|
-
scope: orchestrator
|
|
71
|
-
|
|
72
|
-
# Continuous Improvement - MUST
|
|
73
|
-
- id: R015
|
|
74
|
-
name: continuous-improvement
|
|
75
|
-
title: Continuous Improvement Rules
|
|
76
|
-
path: ./MUST-continuous-improvement.md
|
|
77
|
-
priority: MUST
|
|
78
|
-
scope: all
|
|
79
|
-
|
|
80
|
-
# Sync Verification - MUST
|
|
81
|
-
- id: R016
|
|
82
|
-
name: sync-verification
|
|
83
|
-
title: Sync Verification Rules
|
|
84
|
-
path: ./MUST-sync-verification.md
|
|
85
|
-
priority: MUST
|
|
86
|
-
scope: all
|
|
87
|
-
|
|
88
|
-
# SHOULD - Strongly recommended
|
|
89
|
-
- id: R003
|
|
90
|
-
name: interaction
|
|
91
|
-
title: Interaction Rules
|
|
92
|
-
path: ./SHOULD-interaction.md
|
|
93
|
-
priority: SHOULD
|
|
94
|
-
scope: all
|
|
95
|
-
|
|
96
|
-
- id: R004
|
|
97
|
-
name: error-handling
|
|
98
|
-
title: Error Handling Rules
|
|
99
|
-
path: ./SHOULD-error-handling.md
|
|
100
|
-
priority: SHOULD
|
|
101
|
-
scope: all
|
|
102
|
-
|
|
103
|
-
# Memory Integration - SHOULD
|
|
104
|
-
- id: R011
|
|
105
|
-
name: memory-integration
|
|
106
|
-
title: Memory Integration Rules
|
|
107
|
-
path: ./SHOULD-memory-integration.md
|
|
108
|
-
priority: SHOULD
|
|
109
|
-
scope: all
|
|
110
|
-
|
|
111
|
-
# HUD Statusline - SHOULD
|
|
112
|
-
- id: R012
|
|
113
|
-
name: hud-statusline
|
|
114
|
-
title: HUD Statusline Rules
|
|
115
|
-
path: ./SHOULD-hud-statusline.md
|
|
116
|
-
priority: SHOULD
|
|
117
|
-
scope: all
|
|
118
|
-
|
|
119
|
-
# Ecomode - SHOULD
|
|
120
|
-
- id: R013
|
|
121
|
-
name: ecomode
|
|
122
|
-
title: Ecomode Rules
|
|
123
|
-
path: ./SHOULD-ecomode.md
|
|
124
|
-
priority: SHOULD
|
|
125
|
-
scope: all
|
|
126
|
-
|
|
127
|
-
# Agent Teams - SHOULD
|
|
128
|
-
- id: R017
|
|
129
|
-
name: agent-teams
|
|
130
|
-
title: Agent Teams Rules
|
|
131
|
-
path: ./SHOULD-agent-teams.md
|
|
132
|
-
priority: SHOULD
|
|
133
|
-
scope: orchestrator
|
|
134
|
-
|
|
135
|
-
# MAY - Optional
|
|
136
|
-
- id: R005
|
|
137
|
-
name: optimization
|
|
138
|
-
title: Optimization Guide
|
|
139
|
-
path: ./MAY-optimization.md
|
|
140
|
-
priority: MAY
|
|
141
|
-
scope: all
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: airflow-best-practices
|
|
3
|
-
description: Apache Airflow best practices for DAG authoring, testing, and production deployment
|
|
4
|
-
user-invocable: false
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# Apache Airflow Best Practices
|
|
8
|
-
|
|
9
|
-
## DAG Authoring
|
|
10
|
-
|
|
11
|
-
### Top-Level Code (CRITICAL)
|
|
12
|
-
- Avoid heavy computation at module level (executed on every DAG parse)
|
|
13
|
-
- Minimize imports at module level
|
|
14
|
-
- Use `@task` decorator (TaskFlow API) for Python tasks
|
|
15
|
-
- Keep DAG file under 1000 lines
|
|
16
|
-
|
|
17
|
-
### Scheduling
|
|
18
|
-
- Use cron expressions or timetables
|
|
19
|
-
- Set `catchup=False` for most cases
|
|
20
|
-
- Use data-aware scheduling (datasets) for dependencies
|
|
21
|
-
- Configure SLA monitoring
|
|
22
|
-
|
|
23
|
-
### Task Dependencies
|
|
24
|
-
- Use `>>` / `<<` for clarity
|
|
25
|
-
- Group related tasks with TaskGroup
|
|
26
|
-
- Avoid deep nesting (max 3 levels)
|
|
27
|
-
|
|
28
|
-
## Testing
|
|
29
|
-
|
|
30
|
-
### Unit Tests
|
|
31
|
-
- Test DAG import without errors
|
|
32
|
-
- Detect cycles in dependencies
|
|
33
|
-
- Mock external connections
|
|
34
|
-
- Test task logic independently
|
|
35
|
-
|
|
36
|
-
### Integration Tests
|
|
37
|
-
- Use Airflow test mode
|
|
38
|
-
- Validate end-to-end workflows
|
|
39
|
-
- Test with sample data
|
|
40
|
-
|
|
41
|
-
## Production Deployment
|
|
42
|
-
|
|
43
|
-
### Performance
|
|
44
|
-
- Lazy-load heavy libraries inside tasks
|
|
45
|
-
- Use connection pooling
|
|
46
|
-
- Minimize DAG parse time
|
|
47
|
-
- Enable parallelism
|
|
48
|
-
|
|
49
|
-
### Reliability
|
|
50
|
-
- Set appropriate retries and retry_delay
|
|
51
|
-
- Use SLA callbacks for monitoring
|
|
52
|
-
- Implement proper error handling
|
|
53
|
-
- Log important events
|
|
54
|
-
|
|
55
|
-
## References
|
|
56
|
-
- [Airflow Best Practices](https://airflow.apache.org/docs/apache-airflow/stable/best-practices.html)
|