okstra 0.34.1 → 0.36.1
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.kr.md +27 -19
- package/README.md +27 -19
- package/docs/kr/architecture.md +59 -45
- package/docs/kr/cli.md +61 -18
- package/docs/pr-template-usage.md +65 -0
- package/docs/project-structure-overview.md +353 -354
- package/docs/superpowers/plans/2026-05-12-ticket-id-in-reports.md +1 -1
- package/docs/superpowers/plans/2026-05-14-convergence-queue-pruning.md +1 -1
- package/docs/superpowers/plans/2026-05-17-dual-format-final-report.md +1 -1
- package/docs/superpowers/plans/2026-05-20-final-report-language.md +1501 -0
- package/docs/superpowers/plans/2026-05-20-implementation-planning-multi-stage.md +1267 -0
- package/docs/superpowers/plans/2026-05-20-okstra-run-prompt-sot-b1.md +1007 -0
- package/docs/superpowers/plans/2026-05-20-wizard-messages-json-sot.md +720 -0
- package/docs/superpowers/plans/2026-05-20-wizard-prompt-json-sot-a1.md +681 -0
- package/docs/superpowers/plans/2026-05-21-improvement-discovery-task-type.md +1691 -0
- package/docs/superpowers/plans/2026-05-24-implementation-lead-context-slimming.md +1700 -0
- package/docs/superpowers/specs/2026-05-20-final-report-language-design.md +383 -0
- package/docs/superpowers/specs/2026-05-20-implementation-planning-multi-stage-design.md +320 -0
- package/docs/superpowers/specs/2026-05-20-okstra-run-prompt-sot-design.md +299 -0
- package/docs/superpowers/specs/2026-05-21-improvement-discovery-task-type-design.md +335 -0
- package/docs/task-process/README.md +74 -0
- package/docs/task-process/common-flow.md +166 -0
- package/docs/task-process/error-analysis.md +101 -0
- package/docs/task-process/final-verification.md +167 -0
- package/docs/task-process/implementation-planning.md +128 -0
- package/docs/task-process/implementation.md +149 -0
- package/docs/task-process/release-handoff.md +206 -0
- package/docs/task-process/requirements-discovery.md +115 -0
- package/package.json +1 -1
- package/runtime/BUILD.json +2 -2
- package/runtime/agents/SKILL.md +30 -7
- package/runtime/agents/workers/claude-worker.md +31 -6
- package/runtime/agents/workers/codex-worker.md +37 -10
- package/runtime/agents/workers/gemini-worker.md +34 -7
- package/runtime/agents/workers/report-writer-worker.md +19 -10
- package/runtime/bin/okstra-central.sh +6 -6
- package/runtime/bin/okstra-codex-exec.sh +49 -28
- package/runtime/bin/okstra-gemini-exec.sh +39 -21
- package/runtime/bin/okstra-render-final-report.py +13 -2
- package/runtime/bin/okstra-wrapper-status.py +155 -0
- package/runtime/bin/okstra.sh +2 -2
- package/runtime/prompts/launch.template.md +1 -0
- package/runtime/prompts/profiles/_common-contract.md +11 -6
- package/runtime/prompts/profiles/_implementation-deliverable.md +53 -0
- package/runtime/prompts/profiles/_implementation-executor.md +60 -0
- package/runtime/prompts/profiles/_implementation-verifier.md +76 -0
- package/runtime/prompts/profiles/error-analysis.md +3 -7
- package/runtime/prompts/profiles/implementation-planning.md +22 -21
- package/runtime/prompts/profiles/implementation.md +28 -118
- package/runtime/prompts/profiles/improvement-discovery.md +42 -0
- package/runtime/prompts/profiles/release-handoff.md +1 -1
- package/runtime/prompts/profiles/requirements-discovery.md +8 -12
- package/runtime/prompts/wizard/prompts.ko.json +230 -0
- package/runtime/python/lib/okstra/cli.sh +2 -49
- package/runtime/python/lib/okstra/globals.sh +21 -21
- package/runtime/python/lib/okstra/interactive.sh +7 -7
- package/runtime/python/okstra_ctl/clarification_items.py +3 -9
- package/runtime/python/okstra_ctl/consumers.py +53 -0
- package/runtime/python/okstra_ctl/final_report_schema.py +0 -7
- package/runtime/python/okstra_ctl/i18n.py +73 -0
- package/runtime/python/okstra_ctl/improvement_lenses.py +44 -0
- package/runtime/python/okstra_ctl/index.py +1 -1
- package/runtime/python/okstra_ctl/paths.py +26 -20
- package/runtime/python/okstra_ctl/render.py +166 -207
- package/runtime/python/okstra_ctl/render_final_report.py +53 -10
- package/runtime/python/okstra_ctl/run.py +299 -108
- package/runtime/python/okstra_ctl/run_context.py +22 -0
- package/runtime/python/okstra_ctl/seeding.py +186 -0
- package/runtime/python/okstra_ctl/session.py +65 -7
- package/runtime/python/okstra_ctl/wizard.py +348 -127
- package/runtime/python/okstra_ctl/workflow.py +21 -2
- package/runtime/python/okstra_ctl/worktree.py +54 -1
- package/runtime/python/okstra_project/resolver.py +4 -3
- package/runtime/python/okstra_token_usage/report.py +2 -2
- package/runtime/schemas/final-report-v1.0.schema.json +22 -16
- package/runtime/skills/okstra-brief/SKILL.md +102 -218
- package/runtime/skills/okstra-convergence/SKILL.md +2 -3
- package/runtime/skills/okstra-inspect/SKILL.md +581 -0
- package/runtime/skills/okstra-report-writer/SKILL.md +35 -15
- package/runtime/skills/okstra-run/SKILL.md +8 -7
- package/runtime/skills/okstra-schedule/SKILL.md +14 -157
- package/runtime/skills/okstra-setup/SKILL.md +28 -1
- package/runtime/skills/okstra-team-contract/SKILL.md +16 -107
- package/runtime/templates/okstra.CLAUDE.md +104 -0
- package/runtime/templates/reports/brief.template.md +204 -0
- package/runtime/templates/reports/final-report.template.md +93 -98
- package/runtime/templates/reports/i18n/en.json +135 -0
- package/runtime/templates/reports/i18n/ko.json +135 -0
- package/runtime/templates/reports/implementation-planning-input.template.md +18 -0
- package/runtime/templates/reports/improvement-discovery-input.template.md +78 -0
- package/runtime/templates/reports/schedule.template.md +12 -3
- package/runtime/templates/reports/task-brief.template.md +2 -2
- package/runtime/templates/worker-prompt-preamble.md +108 -0
- package/runtime/validators/lib/fixtures.sh +30 -0
- package/runtime/validators/lib/runners.sh +1 -1
- package/runtime/validators/validate-implementation-plan-stages.py +211 -0
- package/runtime/validators/validate-run.py +121 -26
- package/runtime/validators/validate-workflow.sh +2 -2
- package/runtime/validators/validate_improvement_report.py +275 -0
- package/src/config.mjs +18 -0
- package/src/install.mjs +41 -14
- package/src/setup.mjs +133 -1
- package/src/uninstall.mjs +27 -3
- package/runtime/skills/okstra-history/SKILL.md +0 -165
- package/runtime/skills/okstra-logs/SKILL.md +0 -173
- package/runtime/skills/okstra-report-finder/SKILL.md +0 -111
- package/runtime/skills/okstra-status/SKILL.md +0 -246
- package/runtime/skills/okstra-time-summary/SKILL.md +0 -172
|
@@ -1,173 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: okstra-logs
|
|
3
|
-
description: Use when the user asks about okstra worker wrapper log files — listing, sizes, ages, disk usage, or wants to know what `*.log` sidecars exist for past dispatches and which ones are safe to clean up. Trigger words include "okstra logs", "로그 현황", "로그 파일", "log files", "log size", "log status", "로그 정리", "log cleanup".
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# OKSTRA Logs
|
|
7
|
-
|
|
8
|
-
Read-only inventory of codex/gemini wrapper log files written next to each
|
|
9
|
-
prompt history file (`<prompt>.log`). Reports sizes, ages, totals, and
|
|
10
|
-
suggests cleanup commands. **Does not delete** — the user runs whichever
|
|
11
|
-
`find … -delete` line they like.
|
|
12
|
-
|
|
13
|
-
## When to Use
|
|
14
|
-
|
|
15
|
-
- The user wants to see how much disk space okstra wrapper logs consume.
|
|
16
|
-
- The user wants to know which tasks / phases / workers have lingering log
|
|
17
|
-
sidecars from past dispatches.
|
|
18
|
-
- The user is planning a cleanup and wants ready-to-run `find` commands
|
|
19
|
-
scoped by age, task-id, or task-group.
|
|
20
|
-
|
|
21
|
-
## Background
|
|
22
|
-
|
|
23
|
-
Codex/gemini wrappers (`okstra-codex-exec.sh`, `okstra-gemini-exec.sh`)
|
|
24
|
-
write a sidecar log next to each prompt history file:
|
|
25
|
-
|
|
26
|
-
```
|
|
27
|
-
.project-docs/okstra/tasks/<task-group>/<task-id>/runs/<phase>/prompts/
|
|
28
|
-
<worker>-prompt-<phase>-<seq>.md <-- prompt (git-tracked)
|
|
29
|
-
<worker>-prompt-<phase>-<seq>.log <-- live stdout+stderr mirror
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
The log is truncated at each dispatch (`: > "$log_path"`) — only the latest
|
|
33
|
-
run for a given seq is preserved. Different seqs (`-001`, `-002`, …) keep
|
|
34
|
-
separate files. Long-running implementation dispatches can produce
|
|
35
|
-
multi-MB logs; analysis-phase dispatches are typically smaller.
|
|
36
|
-
|
|
37
|
-
## Step 0: Verify okstra runtime + project setup
|
|
38
|
-
|
|
39
|
-
Before any other step, run each of the following commands as a **separate Bash tool call**. Each command starts with the literal token `okstra` so the `Bash(okstra:*)` permission match succeeds. Do **not** wrap any of them in `if`, `eval`, `export`, `$(...)`, `VAR=...`, `||`, or `&&`, and do **not** introduce a `$OKSTRA_CMD` variable or an `npx -y okstra@latest` fallback — those leading tokens defeat the permission match and force a confirmation prompt on every call. The LLM (you) inspects each command's output and decides what to do next in natural language — never in shell.
|
|
40
|
-
|
|
41
|
-
1. `okstra ensure-installed`
|
|
42
|
-
If this exits non-zero, tell the user: "okstra not installed — run `npx okstra@latest install` once, then retry this skill." Then stop. Do **not** try to invoke `npx -y okstra@latest ...` as a fallback.
|
|
43
|
-
|
|
44
|
-
2. `okstra check-project --json`
|
|
45
|
-
Reads the project from the current working directory. Parse the JSON from stdout. The shape is `{ok, projectRoot, projectJsonPath, projectId}`.
|
|
46
|
-
|
|
47
|
-
- `ok: false` → tell the user: "this project has no okstra setup. Run `/okstra-setup` first." Then stop.
|
|
48
|
-
- `ok: true` → carry `projectRoot` as a literal string and use it as the search root for the steps below.
|
|
49
|
-
|
|
50
|
-
Subsequent `okstra <subcmd>` calls self-bootstrap their Python path, so this skill never needs `okstra paths --shell` / `export PYTHONPATH=...`.
|
|
51
|
-
|
|
52
|
-
## Step 1: Inventory
|
|
53
|
-
|
|
54
|
-
Find all wrapper log files and collect metadata. Use a single `find` to
|
|
55
|
-
keep the I/O cost predictable, then format the results.
|
|
56
|
-
|
|
57
|
-
Construct the logs root by appending `/.project-docs/okstra/tasks` to the literal `projectRoot` value parsed in Step 0, and paste it as a literal absolute path in place of `<LOGS_ROOT>` below (no shell variables, no `$(...)`):
|
|
58
|
-
|
|
59
|
-
```bash
|
|
60
|
-
find <LOGS_ROOT> -type f -path '*/runs/*/prompts/*.log' \
|
|
61
|
-
-printf '%s\t%T@\t%p\n' 2>/dev/null \
|
|
62
|
-
| sort -k1,1nr
|
|
63
|
-
```
|
|
64
|
-
|
|
65
|
-
The columns produced are `size_bytes | mtime_epoch | path`.
|
|
66
|
-
|
|
67
|
-
On macOS, `find -printf` is unavailable. Fall back to `-exec stat` — again substitute the literal `<LOGS_ROOT>`. The `-exec ... {} +` form contains no shell variables and no `$(...)`, so the `Bash(find:*)` permission match holds:
|
|
68
|
-
|
|
69
|
-
```bash
|
|
70
|
-
find <LOGS_ROOT> -type f -path '*/runs/*/prompts/*.log' -exec stat -f '%z%t%m%t%N' {} + 2>/dev/null | sort -k1,1nr
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
If the result is empty, report `No wrapper log files found under <projectRoot>` and exit.
|
|
74
|
-
|
|
75
|
-
## Step 2: Summary table
|
|
76
|
-
|
|
77
|
-
Group results and emit two tables.
|
|
78
|
-
|
|
79
|
-
### Table A — Top 20 largest logs
|
|
80
|
-
|
|
81
|
-
| # | Task | Phase | Worker | Seq | Size | Age | Path |
|
|
82
|
-
|---|------|-------|--------|-----|------|-----|------|
|
|
83
|
-
|
|
84
|
-
Parse fields from the path:
|
|
85
|
-
- task-group / task-id: from the `tasks/<task-group>/<task-id>/` segment
|
|
86
|
-
- phase: from `runs/<phase>/`
|
|
87
|
-
- worker: from filename prefix before `-prompt-`
|
|
88
|
-
- seq: from filename suffix (last 3-digit segment)
|
|
89
|
-
|
|
90
|
-
Format sizes as human-readable (KB / MB). Format age as `Nd` (days) or
|
|
91
|
-
`Nh` (hours) from `mtime` relative to "now".
|
|
92
|
-
|
|
93
|
-
### Table B — Per-task totals
|
|
94
|
-
|
|
95
|
-
| Task Key | Files | Total Size | Oldest | Newest |
|
|
96
|
-
|----------|-------|-----------:|--------|--------|
|
|
97
|
-
|
|
98
|
-
Sort by total size descending. "Task Key" = `<project-id>:<task-group>:<task-id>` for consistency with other okstra skills.
|
|
99
|
-
|
|
100
|
-
### Footer line
|
|
101
|
-
|
|
102
|
-
```
|
|
103
|
-
Total: N files, X.X MB across M tasks under <PROJECT_ROOT>
|
|
104
|
-
```
|
|
105
|
-
|
|
106
|
-
## Step 3: Suggested cleanup commands
|
|
107
|
-
|
|
108
|
-
Emit a fenced bash block the user can copy-paste. Do NOT execute these.
|
|
109
|
-
Each block pairs a dry-run preview (`-print`) with the destructive
|
|
110
|
-
(`-delete`) command so the user can confirm the match set before
|
|
111
|
-
committing.
|
|
112
|
-
|
|
113
|
-
```markdown
|
|
114
|
-
## Cleanup options (manual)
|
|
115
|
-
|
|
116
|
-
# 7일 이상 된 로그만 삭제
|
|
117
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks \
|
|
118
|
-
-type f -path '*/runs/*/prompts/*.log' -mtime +7 -print # dry-run
|
|
119
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks \
|
|
120
|
-
-type f -path '*/runs/*/prompts/*.log' -mtime +7 -delete
|
|
121
|
-
|
|
122
|
-
# 30일 이상 된 로그만 삭제
|
|
123
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks \
|
|
124
|
-
-type f -path '*/runs/*/prompts/*.log' -mtime +30 -print # dry-run
|
|
125
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks \
|
|
126
|
-
-type f -path '*/runs/*/prompts/*.log' -mtime +30 -delete
|
|
127
|
-
|
|
128
|
-
# 특정 task-group 의 로그 일괄 삭제 (예: dev-9388)
|
|
129
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks/dev-9388 \
|
|
130
|
-
-type f -name '*.log' -print # dry-run
|
|
131
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks/dev-9388 \
|
|
132
|
-
-type f -name '*.log' -delete
|
|
133
|
-
|
|
134
|
-
# 특정 task-id 의 로그 일괄 삭제 (예: dev-9428)
|
|
135
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks/*/dev-9428 \
|
|
136
|
-
-type f -name '*.log' -print # dry-run
|
|
137
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks/*/dev-9428 \
|
|
138
|
-
-type f -name '*.log' -delete
|
|
139
|
-
|
|
140
|
-
# 전체 일괄 삭제 (주의)
|
|
141
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks \
|
|
142
|
-
-type f -path '*/runs/*/prompts/*.log' -print # dry-run
|
|
143
|
-
find <PROJECT_ROOT>/.project-docs/okstra/tasks \
|
|
144
|
-
-type f -path '*/runs/*/prompts/*.log' -delete
|
|
145
|
-
```
|
|
146
|
-
|
|
147
|
-
Substitute the literal `<PROJECT_ROOT>` with the resolved absolute path so
|
|
148
|
-
the commands are directly copy-pasteable.
|
|
149
|
-
|
|
150
|
-
## Step 4: Notes for the user
|
|
151
|
-
|
|
152
|
-
End the response with these short reminders:
|
|
153
|
-
|
|
154
|
-
- Logs are truncated on each re-dispatch of the same `seq`, so deleting an
|
|
155
|
-
in-flight run's log will cause the wrapper to recreate an empty file on
|
|
156
|
-
the next dispatch — no data loss beyond the current trace.
|
|
157
|
-
- **If a dispatch is currently running, check `okstra status` first** and
|
|
158
|
-
avoid deleting logs for tasks in `in-progress` state — you will lose
|
|
159
|
-
the live trace for the active run.
|
|
160
|
-
- Prompt history files (`.md`) are separate and are NOT touched by these
|
|
161
|
-
commands — only `.log` sidecars.
|
|
162
|
-
- This skill **does not modify any external files itself**, including
|
|
163
|
-
`.gitignore`. If the project commits `.project-docs/okstra/`, the user
|
|
164
|
-
may want to add
|
|
165
|
-
`.project-docs/okstra/tasks/**/runs/**/prompts/*.log` to `.gitignore`
|
|
166
|
-
manually to keep large logs out of git.
|
|
167
|
-
|
|
168
|
-
## What this skill is NOT
|
|
169
|
-
|
|
170
|
-
- Does NOT delete log files. Only inventories and suggests commands.
|
|
171
|
-
- Does NOT touch prompt history files (`.md`), worker results, manifests,
|
|
172
|
-
or any other okstra state.
|
|
173
|
-
- Does NOT run on a schedule. Invoke explicitly when needed.
|
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: okstra-report-finder
|
|
3
|
-
description: Use when the user provides a task key and needs to find the final report path, or wants to read a previous okstra report to continue work based on its findings. Trigger words include "find report", "show report for", "read the okstra report", "continue from report".
|
|
4
|
-
user-invocable: false
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# OKSTRA Report Finder
|
|
8
|
-
|
|
9
|
-
## When to Use
|
|
10
|
-
|
|
11
|
-
- 사용자가 task-key를 주고 해당 최종 보고서를 찾을 때
|
|
12
|
-
- 이전 okstra 보고서를 읽고 후속 작업을 진행할 때
|
|
13
|
-
- 보고서 내용을 기반으로 구현, 수정, 추가 검증을 시작할 때
|
|
14
|
-
|
|
15
|
-
## Step 0: Verify okstra runtime + project setup
|
|
16
|
-
|
|
17
|
-
각 명령은 **별도 Bash tool call** 로 실행한다. 모든 명령은 리터럴 `okstra` 토큰으로 시작해 `Bash(okstra:*)` 권한 매칭을 통과해야 한다. `if`, `eval`, `export`, `$(...)`, `VAR=...`, `||`, `&&` 로 감싸지 말고, `$OKSTRA_CMD` 변수나 `npx -y okstra@latest` 폴백도 도입하지 않는다 — 첫 토큰이 비리터럴이면 권한 매칭이 깨져 호출마다 확인 프롬프트가 뜬다. 각 명령의 출력은 LLM(너) 이 보고 자연어로 분기 판단을 한다 — shell 분기는 쓰지 않는다.
|
|
18
|
-
|
|
19
|
-
1. `okstra ensure-installed`
|
|
20
|
-
비정상 종료 → 사용자에게 그대로 안내: "okstra not installed — run `npx okstra@latest install` once, then retry this skill." 그리고 중단. 폴백으로 `npx -y okstra@latest ...` 를 호출하지 않는다.
|
|
21
|
-
|
|
22
|
-
2. `okstra check-project --json`
|
|
23
|
-
현재 작업 디렉터리 기준 프로젝트를 읽는다. stdout 의 JSON shape: `{ok, projectRoot, projectJsonPath, projectId}`.
|
|
24
|
-
|
|
25
|
-
- `ok: false` → 사용자에게 "this project has no okstra setup. Run `/okstra-setup` first." 안내 후 중단.
|
|
26
|
-
- `ok: true` → `projectRoot` 를 리터럴 문자열로 들고 catalog/manifest 위치를 잡는다.
|
|
27
|
-
|
|
28
|
-
후속 `okstra <subcmd>` 호출은 Python path 를 자체 부트스트랩하므로 본 스킬은 `okstra paths --shell` / `export PYTHONPATH=...` 를 필요로 하지 않는다.
|
|
29
|
-
|
|
30
|
-
## Step 1: Task Key로 Report 경로 찾기
|
|
31
|
-
|
|
32
|
-
task-key 형식: `<project-id>:<task-group>:<task-id>`
|
|
33
|
-
|
|
34
|
-
**Normalization**: task-key 매칭은 lowercase 로 수행한다. 디스크상의 group/id 세그먼트는 slugify (lowercase + non-alphanumeric runs → `-`) 된다 (`scripts/lib/okstra/interactive.sh:147`). 따라서 catalog 조회는 case-insensitive 이지만 파일 경로를 만들 때는 slugified segment 를 사용해야 한다.
|
|
35
|
-
|
|
36
|
-
### 방법 A: task-catalog.json (빠름)
|
|
37
|
-
|
|
38
|
-
1. `.project-docs/okstra/discovery/task-catalog.json`을 읽는다.
|
|
39
|
-
2. `tasks` 배열에서 `taskKey` 를 lowercase 비교로 매칭한다.
|
|
40
|
-
3. `latestReportPath` 필드는 task-type 과 무관한 "가장 최근 보고서" 이다.
|
|
41
|
-
|
|
42
|
-
### 방법 B: task-manifest.json (직접)
|
|
43
|
-
|
|
44
|
-
task-catalog 가 없는 경우:
|
|
45
|
-
|
|
46
|
-
1. task-key 에서 task-group / task-id 를 추출하고 slugify 한다.
|
|
47
|
-
2. `.project-docs/okstra/tasks/<group-segment>/<id-segment>/task-manifest.json` 을 읽는다.
|
|
48
|
-
3. `latestReportPath` 필드 (task-type 무관, 최신).
|
|
49
|
-
|
|
50
|
-
### 방법 C: timeline.json (특정 run 의 보고서)
|
|
51
|
-
|
|
52
|
-
특정 날짜나 run 의 보고서가 필요한 경우:
|
|
53
|
-
|
|
54
|
-
1. `.project-docs/okstra/tasks/<group-segment>/<id-segment>/history/timeline.json` 을 읽는다.
|
|
55
|
-
2. `runs[]` 배열에서 필터한다. 실제 필드:
|
|
56
|
-
- `runs[].runTimestamp` (ISO-8601 시작 시각)
|
|
57
|
-
- `runs[].status` (run 종료 상태)
|
|
58
|
-
- `runs[].taskType` (`requirements-discovery` 등 phase 이름)
|
|
59
|
-
- `runs[].reportPath` (해당 run 의 보고서 상대 경로)
|
|
60
|
-
|
|
61
|
-
### 방법 D: 특정 task-type 의 최신 보고서 (fallback)
|
|
62
|
-
|
|
63
|
-
`latestReportPath` (방법 A/B) 는 task-type 을 가리지 않는다. 사용자가 *특정* task-type (예: `implementation-planning`) 의 최신 보고서를 요청하면:
|
|
64
|
-
|
|
65
|
-
1. 디렉토리: `.project-docs/okstra/tasks/<group-segment>/<id-segment>/runs/<task-type-segment>/reports/`
|
|
66
|
-
2. 파일명 패턴: `final-report-<task-type-segment>-<NNN>.md` (`scripts/okstra_ctl/sequence.py:31`)
|
|
67
|
-
3. seq 가 가장 큰 파일이 해당 task-type 의 최신 보고서.
|
|
68
|
-
4. timeline.json 의 `runs[].taskType == <task-type>` 으로 교차검증 가능.
|
|
69
|
-
|
|
70
|
-
## Step 2: Report 존재 확인
|
|
71
|
-
|
|
72
|
-
1. `latestReportPath`가 비어있지 않고, 해당 경로의 파일이 실제로 존재하는지 확인한다.
|
|
73
|
-
- 두 신호 중 하나라도 보고서 존재를 가리키면 경로를 표시한다 (tolerant).
|
|
74
|
-
2. 존재하면 경로를 표시하고 읽을지 사용자에게 확인한다.
|
|
75
|
-
3. 존재하지 않으면 `task-manifest.json`에서 다음 신호를 확인한다:
|
|
76
|
-
- `latestReportPath`가 비어있거나 누락된 경우, 그리고
|
|
77
|
-
- `currentStatus`가 `completed`가 아니고, `workStatus`가 `done`이 아니며, `workflow.routingStatus`도 완료를 가리키지 않는 경우
|
|
78
|
-
→ "이 task는 아직 완료되지 않았습니다 (currentStatus: `<currentStatus>`, workStatus: `<workStatus>`)."
|
|
79
|
-
- 위 신호 중 하나라도 완료를 가리키는데 파일만 없는 경우
|
|
80
|
-
→ "보고서 파일이 존재하지 않습니다: `<path>`"
|
|
81
|
-
|
|
82
|
-
워크플로 상태 enum은 `todo | in-progress | blocked | done` (workStatus) 와 `currentStatus`의 `completed` / `contract-violated` 등이다. `"completed"` 문자열은 `workStatus`에는 존재하지 않으므로 두 필드를 혼동하지 말 것.
|
|
83
|
-
|
|
84
|
-
## Step 3: Report 읽기 및 후속 작업 안내
|
|
85
|
-
|
|
86
|
-
보고서를 읽은 후 사용자에게 가능한 후속 작업을 안내한다:
|
|
87
|
-
|
|
88
|
-
1. **구현 진행**: 보고서의 "권장 다음 단계" 섹션 기반으로 코드 수정
|
|
89
|
-
2. **추가 검증**: 같은 task-key 로 새 okstra run 실행. 구체 커맨드:
|
|
90
|
-
```bash
|
|
91
|
-
scripts/okstra.sh --task-key <task-key> --task-type <task-type>
|
|
92
|
-
```
|
|
93
|
-
더 풍부한 옵션 (base-ref, workers, render-only 등) 이 필요하면 `okstra-history` 스킬을 사용한다.
|
|
94
|
-
3. **관련 task 확인**: 보고서의 관련 task 참조가 있으면 해당 task 의 보고서도 조회
|
|
95
|
-
|
|
96
|
-
## Output
|
|
97
|
-
|
|
98
|
-
```markdown
|
|
99
|
-
## Report for <task-key>
|
|
100
|
-
|
|
101
|
-
| Field | Value |
|
|
102
|
-
| ------------ | -------------------------------------------------- |
|
|
103
|
-
| Status | `<status>` |
|
|
104
|
-
| Task type | `<task-type>` |
|
|
105
|
-
| Run seq | `<NNN>` |
|
|
106
|
-
| Run date | `<runTimestamp ISO-8601>` |
|
|
107
|
-
| Report (rel) | `<relative-path-from-project-root>` |
|
|
108
|
-
| Report (abs) | `<absolute-path>` |
|
|
109
|
-
```
|
|
110
|
-
|
|
111
|
-
이후 사용자 요청에 따라 보고서를 읽고 후속 작업을 진행한다.
|
|
@@ -1,246 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: okstra-status
|
|
3
|
-
description: Use when the user asks for overall okstra task status, current lifecycle phase, next recommended phase, blockers, approval state, status for a specific task key, OR wants to update a task's workStatus (todo / in-progress / blocked / done). Trigger words include "okstra status", "task status", "current phase", "next phase", "what is pending", "resume point", "okstra status set", "okstra mark", "<task-id> done", "<task-id> in-progress", "<task-id> 진행중", "<task-id> 완료".
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# OKSTRA Status
|
|
7
|
-
|
|
8
|
-
## When to Use
|
|
9
|
-
|
|
10
|
-
- When user wants to view the progress of the entire project
|
|
11
|
-
- When user want to check the current phase, next phase, blockers, and resume points for a specific `task-key`
|
|
12
|
-
- When user want to check which tasks are pending approval or which tasks can be resumed
|
|
13
|
-
|
|
14
|
-
## Step 0: Verify okstra runtime + project setup
|
|
15
|
-
|
|
16
|
-
Before any other step, run each of the following commands as a **separate Bash tool call**. Each command starts with the literal token `okstra` so the `Bash(okstra:*)` permission match succeeds. Do **not** wrap any of them in `if`, `eval`, `export`, `$(...)`, `VAR=...`, `||`, or `&&`, and do **not** introduce a `$OKSTRA_CMD` variable or an `npx -y okstra@latest` fallback — those leading tokens defeat the permission match and force a confirmation prompt on every call. The LLM (you) inspects each command's output and decides what to do next in natural language — never in shell.
|
|
17
|
-
|
|
18
|
-
1. `okstra ensure-installed`
|
|
19
|
-
If this exits non-zero, tell the user: "okstra not installed — run `npx okstra@latest install` once, then retry this skill." Then stop. Do **not** try to invoke `npx -y okstra@latest ...` as a fallback.
|
|
20
|
-
|
|
21
|
-
2. `okstra check-project --json`
|
|
22
|
-
Reads the project from the current working directory. Parse the JSON from stdout. The shape is `{ok, projectRoot, projectJsonPath, projectId}`.
|
|
23
|
-
|
|
24
|
-
- `ok: false` → tell the user: "this project has no okstra setup. Run `/okstra-setup` first." Then stop.
|
|
25
|
-
- `ok: true` → carry `projectRoot` as a literal string into the steps below; reuse it instead of re-resolving.
|
|
26
|
-
|
|
27
|
-
Subsequent `okstra <subcmd>` calls self-bootstrap their Python path, so this skill never needs `okstra paths --shell` / `export PYTHONPATH=...`.
|
|
28
|
-
|
|
29
|
-
## Step 1: Overall Project Status
|
|
30
|
-
|
|
31
|
-
To view the overall project status, read `.project-docs/okstra/discovery/task-catalog.json`. The catalog is the authoritative source — every field listed below (including `workStatus`, `workStatusUpdatedAt`, `workStatusNote`) is projected directly from each `task-manifest.json` by `scripts/okstra_ctl/render.py :: render_task_catalog_discovery`. Do NOT re-open individual manifests for the overview.
|
|
32
|
-
|
|
33
|
-
Extract the following fields from each task.
|
|
34
|
-
|
|
35
|
-
| Field | Description |
|
|
36
|
-
|------|------|
|
|
37
|
-
| `taskKey` | `<project-id>:<task-group>:<task-id>` |
|
|
38
|
-
| `taskType` | latest task type |
|
|
39
|
-
| `workCategory` | bugfix / feature / improvement / refactor / ops-change / unknown. Display `unknown` as-is, but flag with `(unset)` annotation so the reader knows the requirements-discovery classification was skipped or no `--work-category` flag was passed. |
|
|
40
|
-
| `currentStatus` | task-level status |
|
|
41
|
-
| `currentPhase` | lifecycle current phase |
|
|
42
|
-
| `currentPhaseState` | lifecycle phase state |
|
|
43
|
-
| `nextRecommendedPhase` | next recommended phase |
|
|
44
|
-
| `routingStatus` | routing decision status |
|
|
45
|
-
| `awaitingApproval` | approval 대기 여부 |
|
|
46
|
-
| `latestRunStatus` | latest run status |
|
|
47
|
-
| `latestReportPath` | latest report path |
|
|
48
|
-
| `latestResumeCommandPath` | latest resume command |
|
|
49
|
-
| `workStatus` | user-managed work status (todo / in-progress / blocked / done; default in-progress) |
|
|
50
|
-
| `updatedAt` | last update time |
|
|
51
|
-
|
|
52
|
-
Sort by:
|
|
53
|
-
|
|
54
|
-
1. `updatedAt` Descending
|
|
55
|
-
2. Next, `taskKey`
|
|
56
|
-
|
|
57
|
-
출력 형식:
|
|
58
|
-
|
|
59
|
-
The overview table is intentionally narrow so it renders cleanly in a terminal. Only six columns are shown; for any task that needs a closer look (phase state, routing, approval gate, last run status, resume path, etc.) tell the user to run `okstra status <task-key>` for the detail view in Step 2.
|
|
60
|
-
|
|
61
|
-
If `awaitingApproval` is true OR `routingStatus == "pending"`, append a `*` to the `Next` cell as a visual marker and explain the marker once below the table.
|
|
62
|
-
|
|
63
|
-
```markdown
|
|
64
|
-
## okstra Status — <project-id>
|
|
65
|
-
|
|
66
|
-
| # | Task Key | Category | Phase | workStatus | Next |
|
|
67
|
-
|---|----------|----------|-------|------------|------|
|
|
68
|
-
| 1 | proj:group:id | bugfix | error-analysis | in-progress | implementation-planning |
|
|
69
|
-
| 2 | proj:group:id2 | feature | requirements-discovery | done | pending-routing-decision* |
|
|
70
|
-
|
|
71
|
-
`*` = awaiting user approval or pending routing decision. Run `okstra status <task-key>` for details.
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
## Step 2: Specific Task Status
|
|
75
|
-
|
|
76
|
-
Given a specific `task-key` or `task-group + task-id`:
|
|
77
|
-
|
|
78
|
-
1. If possible, quickly look it up in `task-catalog.json`.
|
|
79
|
-
2. If necessary, read `.project-docs/okstra/tasks/<task-group>/<task-id>/task-manifest.json` directly.
|
|
80
|
-
3. If you need the latest run information, read `history/timeline.json` along with the latest run manifest.
|
|
81
|
-
|
|
82
|
-
Required fields:
|
|
83
|
-
|
|
84
|
-
- `taskKey`
|
|
85
|
-
- `taskType`
|
|
86
|
-
- `workCategory`
|
|
87
|
-
- `currentStatus`
|
|
88
|
-
- `latestRunStatus`
|
|
89
|
-
- `workflow.currentPhase`
|
|
90
|
-
- `workflow.currentPhaseState`
|
|
91
|
-
- `workflow.phaseStates`
|
|
92
|
-
- `workflow.lastCompletedPhase`
|
|
93
|
-
- `workflow.nextRecommendedPhase`
|
|
94
|
-
- `workflow.awaitingApproval`
|
|
95
|
-
- `workflow.routingStatus`
|
|
96
|
-
- `workflow.lastSafeCheckpoint`
|
|
97
|
-
- `workStatus`
|
|
98
|
-
- `workStatusUpdatedAt`
|
|
99
|
-
- `workStatusNote`
|
|
100
|
-
- `latestReportPath`
|
|
101
|
-
- `latestResumeCommandPath`
|
|
102
|
-
- `historyTimelinePath`
|
|
103
|
-
|
|
104
|
-
Output format:
|
|
105
|
-
|
|
106
|
-
```markdown
|
|
107
|
-
## okstra Task Status — <task-key>
|
|
108
|
-
|
|
109
|
-
- Work category: `<category>`
|
|
110
|
-
- Current phase: `<phase>`
|
|
111
|
-
- Current phase state: `<phase-state>`
|
|
112
|
-
- Last completed phase: `<phase-or-->`
|
|
113
|
-
- Next recommended phase: `<phase>`
|
|
114
|
-
- Awaiting approval: `<yes|no>`
|
|
115
|
-
- Routing status: `<routing-status>`
|
|
116
|
-
- Task status: `<task-status>`
|
|
117
|
-
- Latest run status: `<run-status>`
|
|
118
|
-
- Latest report: `<relative-path-or-->`
|
|
119
|
-
- Resume command: `<relative-path-or-->`
|
|
120
|
-
- workStatus: `<todo|in-progress|blocked|done>` (updated `<workStatusUpdatedAt-or-->`)
|
|
121
|
-
- workStatus note: `<workStatusNote-or-->`
|
|
122
|
-
|
|
123
|
-
### Phase States
|
|
124
|
-
|
|
125
|
-
- `requirements-discovery`: `<state>`
|
|
126
|
-
- `error-analysis`: `<state>`
|
|
127
|
-
- `implementation-planning`: `<state>`
|
|
128
|
-
- `implementation`: `<state>`
|
|
129
|
-
- `final-verification`: `<state>`
|
|
130
|
-
- `release-handoff`: `<state>`
|
|
131
|
-
|
|
132
|
-
### Safe Resume Checkpoint
|
|
133
|
-
|
|
134
|
-
- Label: `<checkpoint-label>`
|
|
135
|
-
- Run manifest: `<relative-path-or-->`
|
|
136
|
-
- Team state: `<relative-path-or-->`
|
|
137
|
-
- Report: `<relative-path-or-->`
|
|
138
|
-
- Resume command: `<relative-path-or-->`
|
|
139
|
-
```
|
|
140
|
-
|
|
141
|
-
## Step 3: Resume and Next-Step Guidance
|
|
142
|
-
|
|
143
|
-
The status response always includes one of the following options:
|
|
144
|
-
|
|
145
|
-
1. **Resume current run**
|
|
146
|
-
- If `latestResumeCommandPath` exists, display that path.
|
|
147
|
-
2. **Restart current phase**
|
|
148
|
-
- Indicates whether the task can be re-run with the same `task-key` and the current `taskType`.
|
|
149
|
-
3. **Start next phase**
|
|
150
|
-
- If `workflow.nextRecommendedPhase` is one of `error-analysis`, `implementation-planning`, `implementation`, `final-verification`, or `release-handoff`, that phase is proposed as the next candidate for the Okstra run.
|
|
151
|
-
- If `nextRecommendedPhase` is `pending-release-handoff`, the prior `final-verification` run completed but its verdict still has to be inspected before entering `release-handoff` — surface this as a verdict-gated next step and present `release-handoff` as a candidate only when the cited verdict is `accepted`.
|
|
152
|
-
4. **Need more information**
|
|
153
|
-
- If `nextRecommendedPhase` is `pending-routing-decision` or `routingStatus` is `pending`, this indicates that additional information is required.
|
|
154
|
-
5. **Task complete (terminal)**
|
|
155
|
-
- If `nextRecommendedPhase` is `done-or-follow-up`, the task lifecycle has reached its terminal signal. This is **not** a "next phase" — do not propose a new Okstra run. Surface the latest report and ask the user whether any follow-up task should be opened separately.
|
|
156
|
-
|
|
157
|
-
## Step 4: Update workStatus
|
|
158
|
-
|
|
159
|
-
The skill MUST recognize requests to change a task's `workStatus` and update the corresponding `task-manifest.json`.
|
|
160
|
-
|
|
161
|
-
### Trigger Patterns (recognize both)
|
|
162
|
-
|
|
163
|
-
**Natural language (Korean / English)**:
|
|
164
|
-
- "DEV-6827 done으로 바꿔줘"
|
|
165
|
-
- "PROD-1623을 blocked로 표시"
|
|
166
|
-
- "DEV-9047 진행중"
|
|
167
|
-
- "Mark DEV-6827 as done"
|
|
168
|
-
|
|
169
|
-
**Explicit command**:
|
|
170
|
-
- `okstra status set <task-id> <status>`
|
|
171
|
-
- `okstra status set <task-group> <task-id> <status>` (used to disambiguate)
|
|
172
|
-
- `okstra mark <task-id> <status>`
|
|
173
|
-
- `okstra status set <task-id> <status> --note "<note>"`
|
|
174
|
-
|
|
175
|
-
Accepted `<status>` values: `todo`, `in-progress`, `blocked`, `done`.
|
|
176
|
-
|
|
177
|
-
### Procedure
|
|
178
|
-
|
|
179
|
-
1. **Validate status value**. If not in the enum, output an error and the allowed values list. Do not modify any file.
|
|
180
|
-
|
|
181
|
-
2. **Look up the task** in `.project-docs/okstra/discovery/task-catalog.json` by `task-id` (case-insensitive on both `task-id` and `task-group`).
|
|
182
|
-
- If the user provided `<task-group>` explicitly, scope the lookup to that group (case-insensitive).
|
|
183
|
-
- If a single match is found → proceed.
|
|
184
|
-
- If multiple matches across different `task-group` values → list the groups and ask the user to retry with the explicit form. Example output:
|
|
185
|
-
```
|
|
186
|
-
<TASK-ID>은 여러 task-group에 존재합니다:
|
|
187
|
-
- <group1>
|
|
188
|
-
- <group2>
|
|
189
|
-
다음 형식으로 다시 시도하세요: okstra status set <task-group> <TASK-ID> <status>
|
|
190
|
-
```
|
|
191
|
-
Stop without modifying any file.
|
|
192
|
-
- If no match → output `<TASK-ID>를 찾을 수 없습니다.` and stop.
|
|
193
|
-
|
|
194
|
-
3. **Open the matching `task-manifest.json`** at `.project-docs/okstra/tasks/<task-group-segment>/<task-id-segment>/task-manifest.json`. Assemble the path from the catalog entry's `taskGroupPathSegment` and `taskIdPathSegment` fields (these are the filesystem-safe segments emitted by the renderer) — NOT from the raw user-supplied `<task-group>` / `<task-id>` strings, which may differ in case or contain characters that were normalized when the manifest was created. As a defensive shortcut, prefer the `taskManifestPath` field directly when present.
|
|
195
|
-
|
|
196
|
-
4. **Update fields at the manifest root**:
|
|
197
|
-
- `workStatus` ← new status value
|
|
198
|
-
- `workStatusUpdatedAt` ← current ISO-8601 UTC timestamp (e.g. `2026-05-01T10:23:45Z`)
|
|
199
|
-
- `workStatusNote`:
|
|
200
|
-
- If `--note` is provided → set the field to its value.
|
|
201
|
-
- If `--note` is NOT provided → leave any existing `workStatusNote` field untouched (do not delete, do not blank). If the field did not exist before, do not create it.
|
|
202
|
-
|
|
203
|
-
**Manifest preservation rules** (critical to avoid silent corruption):
|
|
204
|
-
- Use a targeted in-place edit (e.g. the Edit tool with old_string/new_string anchors).
|
|
205
|
-
- Do NOT round-trip the file through `JSON.parse` + `JSON.stringify` — that reorders keys, drops trailing newlines, and normalizes spacing.
|
|
206
|
-
- Preserve the existing key order, indentation style, and trailing newline of the file exactly.
|
|
207
|
-
|
|
208
|
-
5. **Confirm in Korean**:
|
|
209
|
-
|
|
210
|
-
```
|
|
211
|
-
✓ <TASK-ID> workStatus: <previous> → <new>
|
|
212
|
-
✓ task-manifest.json 업데이트됨
|
|
213
|
-
```
|
|
214
|
-
|
|
215
|
-
Use `<previous>` = `(없음)` if the field was absent before.
|
|
216
|
-
|
|
217
|
-
### Default Value Convention
|
|
218
|
-
|
|
219
|
-
If `workStatus` is missing or empty in any manifest, infer the display value from the lifecycle state — DO NOT default to a static `in-progress`:
|
|
220
|
-
|
|
221
|
-
| Manifest state | Inferred display |
|
|
222
|
-
|---|---|
|
|
223
|
-
| `currentStatus == "completed"` AND `workflow.nextRecommendedPhase == "done-or-follow-up"` | `done` (inferred) |
|
|
224
|
-
| `currentStatus == "completed"` AND `workflow.currentPhaseState == "completed"` | `phase-done` (inferred) |
|
|
225
|
-
| `currentStatus == "contract-violated"` OR `workflow.currentPhaseState == "blocked"` | `blocked` (inferred) |
|
|
226
|
-
| anything else | `in-progress` (default) |
|
|
227
|
-
|
|
228
|
-
Annotate inferred values with `(inferred)` or `(default)` in the rendered output so the reader can see which value is user-set vs. system-inferred. Do not back-fill the field on read; only write it when the user explicitly issues an update.
|
|
229
|
-
|
|
230
|
-
### Catalog Sync Note
|
|
231
|
-
|
|
232
|
-
This skill updates `task-manifest.json` only. `discovery/task-catalog.json` may become stale until it is regenerated by another tool. Downstream consumers (e.g. `okstra-schedule`) should re-read each manifest directly to obtain the authoritative `workStatus`.
|
|
233
|
-
|
|
234
|
-
---
|
|
235
|
-
|
|
236
|
-
## Output Rules
|
|
237
|
-
|
|
238
|
-
- Responses should be concise and written in Korean.
|
|
239
|
-
- Use project-relative paths whenever possible.
|
|
240
|
-
- If there is no recent report, display `--`.
|
|
241
|
-
- If a specific task does not exist, explicitly state that it cannot be found based on `task-catalog.json`.
|
|
242
|
-
- If `awaitingApproval` is true, clearly indicate that the task is awaiting user approval.
|
|
243
|
-
|
|
244
|
-
## Out-of-Scope Backlog
|
|
245
|
-
|
|
246
|
-
- **Step 0 boilerplate duplication.** The `ensure-installed` + `check-project --json` preamble (literal-token-first, separate Bash calls) is near-identical across every user-facing okstra skill. The Claude Code skill framework has no include/snippet mechanism today, so each skill duplicates the prose. A future change should either (a) extract the preamble into a single `okstra preflight` subcommand the skill can call in one line, or (b) ship the block as a shared SKILL fragment if the framework gains include support. Not actionable inside this skill alone.
|