codex-genesis-harness 0.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.
- package/.codex/skills/project-genesis-harness/SKILL.md +727 -0
- package/.codex/skills/project-genesis-harness/agents/openai.yaml +9 -0
- package/.codex/skills/project-genesis-harness/references/planning-schema.md +35 -0
- package/.codex/skills/project-genesis-harness/references/quality-rubric.md +21 -0
- package/.codex/skills/project-genesis-harness/references/research-rubric.md +41 -0
- package/.codex/skills/project-genesis-harness/references/workflows.md +33 -0
- package/.codex/skills/project-genesis-harness/resources/agents-template.md +27 -0
- package/.codex/skills/project-genesis-harness/resources/api-docs-template.md +32 -0
- package/.codex/skills/project-genesis-harness/resources/architecture-template.md +30 -0
- package/.codex/skills/project-genesis-harness/resources/audit-template.md +26 -0
- package/.codex/skills/project-genesis-harness/resources/bug-template.md +34 -0
- package/.codex/skills/project-genesis-harness/resources/check-template.md +21 -0
- package/.codex/skills/project-genesis-harness/resources/conventions-template.md +42 -0
- package/.codex/skills/project-genesis-harness/resources/decision-template.md +33 -0
- package/.codex/skills/project-genesis-harness/resources/design-template.md +26 -0
- package/.codex/skills/project-genesis-harness/resources/escalation-template.md +21 -0
- package/.codex/skills/project-genesis-harness/resources/feature-template.md +49 -0
- package/.codex/skills/project-genesis-harness/resources/integrations-template.md +32 -0
- package/.codex/skills/project-genesis-harness/resources/journeys-template.md +13 -0
- package/.codex/skills/project-genesis-harness/resources/lessons-learned-template.md +12 -0
- package/.codex/skills/project-genesis-harness/resources/observability-template.md +34 -0
- package/.codex/skills/project-genesis-harness/resources/phase-template.md +34 -0
- package/.codex/skills/project-genesis-harness/resources/pitfalls-template.md +22 -0
- package/.codex/skills/project-genesis-harness/resources/planning-tree-template.md +39 -0
- package/.codex/skills/project-genesis-harness/resources/project-template.md +38 -0
- package/.codex/skills/project-genesis-harness/resources/quality-score-template.md +11 -0
- package/.codex/skills/project-genesis-harness/resources/requirements-template.md +26 -0
- package/.codex/skills/project-genesis-harness/resources/research-template.md +26 -0
- package/.codex/skills/project-genesis-harness/resources/review-template.md +22 -0
- package/.codex/skills/project-genesis-harness/resources/spec-changelog-template.md +6 -0
- package/.codex/skills/project-genesis-harness/resources/stack-template.md +33 -0
- package/.codex/skills/project-genesis-harness/resources/verification-template.md +26 -0
- package/.codex/skills/project-genesis-harness/scripts/check-architecture-boundaries.sh +23 -0
- package/.codex/skills/project-genesis-harness/scripts/check-docs-sync.sh +24 -0
- package/.codex/skills/project-genesis-harness/scripts/check-no-debug-logs.sh +21 -0
- package/.codex/skills/project-genesis-harness/scripts/check-required-planning-files.sh +46 -0
- package/.codex/skills/project-genesis-harness/scripts/check-spec-changelog.sh +24 -0
- package/.codex/skills/project-genesis-harness/scripts/check-task-tracking.sh +25 -0
- package/.codex/skills/project-genesis-harness/scripts/create-adr.sh +74 -0
- package/.codex/skills/project-genesis-harness/scripts/create-bug.sh +160 -0
- package/.codex/skills/project-genesis-harness/scripts/create-feature.sh +217 -0
- package/.codex/skills/project-genesis-harness/scripts/detect-stack.sh +26 -0
- package/.codex/skills/project-genesis-harness/scripts/init-planning.sh +719 -0
- package/.codex/skills/project-genesis-harness/scripts/list-changed-files.sh +12 -0
- package/.codex/skills/project-genesis-harness/scripts/run-verification.sh +47 -0
- package/.codex/skills/project-genesis-harness/scripts/update-state.sh +33 -0
- package/.codex-plugin/plugin.json +35 -0
- package/LICENSE +22 -0
- package/README.md +181 -0
- package/VERSION +2 -0
- package/bin/genesis-harness.js +164 -0
- package/package.json +37 -0
- package/scripts/install.sh +69 -0
- package/scripts/run-evals.sh +52 -0
- package/scripts/uninstall.sh +52 -0
- package/scripts/verify.sh +109 -0
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
set -euo pipefail
|
|
3
|
+
|
|
4
|
+
usage() {
|
|
5
|
+
echo "Usage: $0 <slug> [summary] [root]" >&2
|
|
6
|
+
exit 2
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
slug="${1:-}"
|
|
10
|
+
summary="${2:-TBD}"
|
|
11
|
+
root="${3:-.}"
|
|
12
|
+
[ -n "$slug" ] || usage
|
|
13
|
+
|
|
14
|
+
case "$slug" in
|
|
15
|
+
*[!a-z0-9-]*|'') echo "Slug must use lowercase letters, numbers, and hyphens." >&2; exit 2 ;;
|
|
16
|
+
esac
|
|
17
|
+
|
|
18
|
+
cd "$root"
|
|
19
|
+
mkdir -p .planning/features
|
|
20
|
+
|
|
21
|
+
next="$(
|
|
22
|
+
find .planning/features -maxdepth 1 -type d -name '[0-9][0-9][0-9]-*' 2>/dev/null \
|
|
23
|
+
| sed -E 's#.*/([0-9]{3})-.*#\1#' \
|
|
24
|
+
| sort -n \
|
|
25
|
+
| tail -1
|
|
26
|
+
)"
|
|
27
|
+
if [ -z "$next" ]; then
|
|
28
|
+
number="001"
|
|
29
|
+
else
|
|
30
|
+
number="$(printf '%03d' "$((10#$next + 1))")"
|
|
31
|
+
fi
|
|
32
|
+
|
|
33
|
+
dir=".planning/features/${number}-${slug}"
|
|
34
|
+
if [ -e "$dir" ]; then
|
|
35
|
+
echo "Feature directory already exists: $dir" >&2
|
|
36
|
+
exit 1
|
|
37
|
+
fi
|
|
38
|
+
|
|
39
|
+
mkdir -p "$dir"
|
|
40
|
+
|
|
41
|
+
cat > "$dir/SPEC.md" <<EOF
|
|
42
|
+
# Feature: $summary
|
|
43
|
+
|
|
44
|
+
## Summary
|
|
45
|
+
|
|
46
|
+
$summary
|
|
47
|
+
|
|
48
|
+
## User Story
|
|
49
|
+
|
|
50
|
+
As a TBD, I want TBD so that TBD.
|
|
51
|
+
|
|
52
|
+
## Expected Behavior
|
|
53
|
+
|
|
54
|
+
- [ ] TBD
|
|
55
|
+
|
|
56
|
+
## Edge Cases
|
|
57
|
+
|
|
58
|
+
- [ ] TBD
|
|
59
|
+
|
|
60
|
+
## Out Of Scope
|
|
61
|
+
|
|
62
|
+
- [ ] TBD
|
|
63
|
+
|
|
64
|
+
## Acceptance Criteria
|
|
65
|
+
|
|
66
|
+
- [ ] TBD
|
|
67
|
+
EOF
|
|
68
|
+
|
|
69
|
+
cat > "$dir/IMPACT.md" <<'EOF'
|
|
70
|
+
# Impact
|
|
71
|
+
|
|
72
|
+
| Question | Answer | Notes |
|
|
73
|
+
|---|---|---|
|
|
74
|
+
| Does this affect API? | TBD | TBD |
|
|
75
|
+
| Does this affect database? | TBD | TBD |
|
|
76
|
+
| Does this affect UI? | TBD | TBD |
|
|
77
|
+
| Does this affect auth/security? | TBD | TBD |
|
|
78
|
+
| Does this affect integrations? | TBD | TBD |
|
|
79
|
+
| Does this affect environment variables? | TBD | TBD |
|
|
80
|
+
| Does this affect architecture? | TBD | TBD |
|
|
81
|
+
| Does this require docs update? | TBD | TBD |
|
|
82
|
+
| Does this require tests? | TBD | TBD |
|
|
83
|
+
| Does this require migration? | TBD | TBD |
|
|
84
|
+
| Does this affect existing user journeys? | TBD | TBD |
|
|
85
|
+
EOF
|
|
86
|
+
|
|
87
|
+
cat > "$dir/PLAN.md" <<'EOF'
|
|
88
|
+
# Plan
|
|
89
|
+
|
|
90
|
+
## Files To Change
|
|
91
|
+
|
|
92
|
+
### File: `path/to/file`
|
|
93
|
+
|
|
94
|
+
Change:
|
|
95
|
+
Why:
|
|
96
|
+
Risk:
|
|
97
|
+
Test:
|
|
98
|
+
Docs impact:
|
|
99
|
+
|
|
100
|
+
## Implementation Steps
|
|
101
|
+
|
|
102
|
+
- [ ] TBD
|
|
103
|
+
|
|
104
|
+
## Test Strategy
|
|
105
|
+
|
|
106
|
+
- [ ] TBD
|
|
107
|
+
|
|
108
|
+
## Docs To Update
|
|
109
|
+
|
|
110
|
+
- [ ] TBD
|
|
111
|
+
|
|
112
|
+
## Diagrams To Update
|
|
113
|
+
|
|
114
|
+
- [ ] DIAGRAM.mmd
|
|
115
|
+
|
|
116
|
+
## Risks
|
|
117
|
+
|
|
118
|
+
- [ ] TBD
|
|
119
|
+
|
|
120
|
+
## Rollback Plan
|
|
121
|
+
|
|
122
|
+
- [ ] TBD
|
|
123
|
+
|
|
124
|
+
## Verification Commands
|
|
125
|
+
|
|
126
|
+
```sh
|
|
127
|
+
# TBD
|
|
128
|
+
```
|
|
129
|
+
EOF
|
|
130
|
+
|
|
131
|
+
cat > "$dir/TEST_CONTRACT.md" <<'EOF'
|
|
132
|
+
# Test Contract
|
|
133
|
+
|
|
134
|
+
## Normal Input / Output
|
|
135
|
+
|
|
136
|
+
- [ ] TBD
|
|
137
|
+
|
|
138
|
+
## Edge Cases
|
|
139
|
+
|
|
140
|
+
- [ ] TBD
|
|
141
|
+
|
|
142
|
+
## Invalid Inputs
|
|
143
|
+
|
|
144
|
+
- [ ] TBD
|
|
145
|
+
|
|
146
|
+
## Expected Errors
|
|
147
|
+
|
|
148
|
+
- [ ] TBD
|
|
149
|
+
|
|
150
|
+
## Acceptance Tests
|
|
151
|
+
|
|
152
|
+
- [ ] TBD
|
|
153
|
+
|
|
154
|
+
## Manual Verification
|
|
155
|
+
|
|
156
|
+
- [ ] TBD
|
|
157
|
+
EOF
|
|
158
|
+
|
|
159
|
+
cat > "$dir/TASKS.md" <<'EOF'
|
|
160
|
+
# Tasks
|
|
161
|
+
|
|
162
|
+
- [ ] Read required planning docs
|
|
163
|
+
- [ ] Read PITFALLS.md
|
|
164
|
+
- [ ] Read LESSONS_LEARNED.md
|
|
165
|
+
- [ ] Research existing codebase patterns
|
|
166
|
+
- [ ] Research best practices
|
|
167
|
+
- [ ] Create or update Mermaid diagram
|
|
168
|
+
- [ ] Write SPEC.md
|
|
169
|
+
- [ ] Write IMPACT.md
|
|
170
|
+
- [ ] Write PLAN.md
|
|
171
|
+
- [ ] Write TEST_CONTRACT.md
|
|
172
|
+
- [ ] Add failing tests or verification
|
|
173
|
+
- [ ] Implement feature
|
|
174
|
+
- [ ] Run verification
|
|
175
|
+
- [ ] Update docs
|
|
176
|
+
- [ ] Review changed files
|
|
177
|
+
- [ ] Remove unnecessary files/code
|
|
178
|
+
- [ ] Update STATE.md
|
|
179
|
+
- [ ] Update FEATURE_INDEX.md
|
|
180
|
+
- [ ] Update SPEC_CHANGELOG.md
|
|
181
|
+
- [ ] Mark completed tasks
|
|
182
|
+
EOF
|
|
183
|
+
|
|
184
|
+
cat > "$dir/VERIFICATION.md" <<'EOF'
|
|
185
|
+
# Verification
|
|
186
|
+
|
|
187
|
+
- [ ] Define commands
|
|
188
|
+
- [ ] Run commands
|
|
189
|
+
- [ ] Record results
|
|
190
|
+
|
|
191
|
+
| Command | Result | Evidence |
|
|
192
|
+
|---|---|---|
|
|
193
|
+
| TBD | TBD | TBD |
|
|
194
|
+
EOF
|
|
195
|
+
|
|
196
|
+
cat > "$dir/REVIEW.md" <<'EOF'
|
|
197
|
+
# Review
|
|
198
|
+
|
|
199
|
+
- [ ] Changed files reviewed
|
|
200
|
+
- [ ] Missing docs checked
|
|
201
|
+
- [ ] Debug logs removed
|
|
202
|
+
- [ ] Unnecessary changes removed
|
|
203
|
+
|
|
204
|
+
## Findings
|
|
205
|
+
|
|
206
|
+
| Severity | File | Issue | Follow-Up |
|
|
207
|
+
|---|---|---|---|
|
|
208
|
+
| TBD | TBD | TBD | TBD |
|
|
209
|
+
EOF
|
|
210
|
+
|
|
211
|
+
cat > "$dir/DIAGRAM.mmd" <<'EOF'
|
|
212
|
+
flowchart LR
|
|
213
|
+
User["User"] --> Feature["Feature"]
|
|
214
|
+
Feature --> System["System"]
|
|
215
|
+
EOF
|
|
216
|
+
|
|
217
|
+
echo "$dir"
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
set -euo pipefail
|
|
3
|
+
|
|
4
|
+
root="${1:-.}"
|
|
5
|
+
cd "$root"
|
|
6
|
+
|
|
7
|
+
say() { printf '%s\n' "$*"; }
|
|
8
|
+
has() { [ -e "$1" ]; }
|
|
9
|
+
|
|
10
|
+
say "# Detected Stack Clues"
|
|
11
|
+
|
|
12
|
+
has package.json && say "- JavaScript/TypeScript: package.json"
|
|
13
|
+
has pnpm-lock.yaml && say "- Package manager: pnpm"
|
|
14
|
+
has yarn.lock && say "- Package manager: yarn"
|
|
15
|
+
has package-lock.json && say "- Package manager: npm"
|
|
16
|
+
has pyproject.toml && say "- Python: pyproject.toml"
|
|
17
|
+
has requirements.txt && say "- Python dependencies: requirements.txt"
|
|
18
|
+
has Cargo.toml && say "- Rust: Cargo.toml"
|
|
19
|
+
has go.mod && say "- Go: go.mod"
|
|
20
|
+
has composer.json && say "- PHP: composer.json"
|
|
21
|
+
find . -maxdepth 3 \( -name '*.csproj' -o -name '*.sln' \) -print | sed 's#^\./#- .NET: #' || true
|
|
22
|
+
has Dockerfile && say "- Container: Dockerfile"
|
|
23
|
+
has docker-compose.yml && say "- Compose: docker-compose.yml"
|
|
24
|
+
has compose.yml && say "- Compose: compose.yml"
|
|
25
|
+
find . -maxdepth 3 -type d \( -name src -o -name app -o -name tests -o -name test -o -name docs \) -print | sed 's#^\./#- Directory: #' || true
|
|
26
|
+
|