Skip to content

Commit b50f06b

Browse files
authored
Merge pull request #55 from gitgitWi/feat/phase-0-foundation
docs(phase-0): 페이즈를 draft로 리뷰하고 본문은 왜·효과로 쓰게 한다
2 parents 3939883 + 1b75b2a commit b50f06b

20 files changed

Lines changed: 310 additions & 58 deletions

File tree

‎.cursor/agents/implementer.md‎

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
name: implementer
33
description: >-
44
Phase developer. Use after PLAN-READY to implement the refined PLAN.md,
5-
run bun gates, and open a stacked PR. Always isolate in a git worktree
6-
(or /in-cloud). Never edit SPEC/PLAN — send PLAN-CHANGE instead.
5+
run bun gates, and open a draft stacked PR immediately. Always isolate in a
6+
git worktree (or /in-cloud). Never edit SPEC/PLAN — send PLAN-CHANGE instead.
77
model: composer-2.5
88
---
99

@@ -12,10 +12,11 @@ You are the developer for this repo. Follow `.tasks/playbook/developer.md` (role
1212
When invoked:
1313

1414
1. Confirm you are on an isolated worktree or cloud branch. If you share the parent checkout, stop and ask for isolation.
15-
2. Read SPEC + refined PLAN + `AGENTS.md` + code-style. Implement PLAN steps in order.
15+
2. Read SPEC + refined PLAN + `AGENTS.md` + code-style + `docs/conventions/prs.md`. Implement PLAN steps in order.
1616
3. Per step: run the acceptance check. On a broken SPEC assumption, send `PLAN-CHANGE <file> <reason> <proposal>` — do not edit PLAN.md.
1717
4. Co-deliver `*.stories.ts` for UI (Phase 1+). Commits: follow `docs/conventions/commits.md`.
18-
5. Open stacked PR: `gh pr create --base <parent>` (Korean body, real `bun run check` / oxfmt / oxlint / vitest output).
19-
6. Reply `PR-READY <phase> <branch> <PR#>` and append LOG.md.
18+
5. Read `docs/conventions/prs.md`, then open a **draft** stacked PR: `gh pr create --draft --base <parent> --assignee @me --label … --body-file`. Never open as ready.
19+
6. Reply `PR-DRAFT <phase> <branch> <PR#>` and append LOG.md. Stay draft until review.
20+
7. After planner + verifier `REVIEW APPROVE`: `gh pr ready <PR#>`, then `PR-READY <phase> <branch> <PR#>`.
2021

2122
Astro APIs: query Astro Docs MCP before coding. No `getStaticProps` / `next/*`. No yarn/npm lockfiles.

‎.cursor/agents/planner.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name: planner
33
description: >-
44
Phase planner. Use before implementation to refine PLAN.md, and after
5-
PR-READY to review against SPEC and code-style. No product code.
5+
PR-DRAFT to review the still-draft PR against SPEC and code-style. No product code.
66
Use proactively when a phase PLAN needs executable steps.
77
May edit PLAN.md and LOG.md only — never product code.
88
model: inherit
@@ -12,9 +12,9 @@ You are the planner for this repo. Follow `.tasks/playbook/planner.md` (role) an
1212

1313
When invoked:
1414

15-
1. Read `.tasks/ROADMAP.md`, the current phase `SPEC.md` + `PLAN.md`, `AGENTS.md`, and `docs/conventions/code-style.md`.
15+
1. Read `.tasks/ROADMAP.md`, the current phase `SPEC.md` + `PLAN.md`, `AGENTS.md`, `docs/conventions/code-style.md`, and `docs/conventions/prs.md`.
1616
2. If asked to refine the plan (Part A): map every SPEC goal to a PLAN step; write executable files/commands/acceptance checks back to `PLAN.md` only. Reply `PLAN-READY <phase> <open questions|none>`.
17-
3. If asked to review (Part B): do not trust the PR body. Check correctness, style §1–7, StyleX/Astro contracts, real gate output, leak-guard. Reply `REVIEW <APPROVE|CHANGES> <phase> <PR#>`.
17+
3. If asked to review (Part B): review the **draft**. Do not ask for ready first. Do not trust the PR body. Check correctness, style §1–7, StyleX/Astro contracts, real gate output, leak-guard, and `docs/conventions/prs.md`. Reply `REVIEW <APPROVE|CHANGES> <phase> <PR#>`. Do not run `gh pr ready`.
1818
4. Append the report to `.tasks/phase-N-*/LOG.md`.
1919

2020
No product code. No SPEC edits (propose via leader). Korean PLAN prose; English LLM docs.

‎.cursor/agents/verifier.md‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
22
name: verifier
33
description: >-
4-
Skeptical gate checker. Use after implementer claims PR-READY or tests
5-
green. Confirm commands actually ran, SPEC goals exist in the diff, and
6-
nothing was marked done without evidence.
4+
Skeptical gate checker. Use after implementer claims PR-DRAFT (while the
5+
PR is still draft). Confirm commands actually ran, SPEC goals exist in the
6+
diff, and nothing was marked done without evidence. Do not mark the PR ready.
77
model: inherit
88
readonly: true
99
---
@@ -12,7 +12,7 @@ You are a skeptical verifier. Follow planner Part B gates in `.tasks/playbook/pl
1212

1313
When invoked:
1414

15-
1. Identify what was claimed (`PR-READY`, LOG checkboxes, PR body).
15+
1. Identify what was claimed (`PR-DRAFT`, LOG checkboxes, PR body). The PR must still be draft.
1616
2. Confirm the files exist and the stacked base is correct.
1717
3. Run or re-read real outputs for `bun run check`, `bunx oxfmt --check .`, `bunx oxlint .`, `bunx vitest run` (and phase scripts if present). A pasted log without a command you can reproduce is not evidence.
1818
4. Look for skipped steps, missing stories (Phase 1+ UI), leak-guard issues, and Astro anti-patterns.
@@ -23,4 +23,4 @@ Report:
2323
- What was claimed but incomplete or broken
2424
- `REVIEW APPROVE` or `REVIEW CHANGES` (file:line + reason)
2525

26-
Do not accept claims at face value. Do not edit product code.
26+
Do not accept claims at face value. Do not edit product code. Do not run `gh pr ready`.

‎.tasks/ROADMAP.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
- Phase별 스택 (base 체인, 아래→위 순서로 머지):
3737
`main` ← `feat/ci-gates` ← `feat/phase-0-foundation` ← `feat/phase-1-scaffold` ← `feat/phase-2-content` ←
3838
`feat/phase-3-quiz` ← `feat/phase-4-hardening`
39-
- 생성: `gh pr create --base <parent-branch>` 로 스택. CI는 PR마다 자동 실행 (CI 선행 머지 후).
39+
- 생성: 페이즈 완료 즉시 `gh pr create --draft --base <parent-branch>` (draft). planner/verifier 리뷰 통과 후 `gh pr ready`. CI는 PR마다 자동 실행 (CI 선행 머지 후).
4040
- 머지는 아래부터 순서대로 (GitHub "Merge" + base 자동전환 확인). `gh` 2.100.0 설치 확인됨.
4141
- 본 로드맵 문서 작업(`.tasks/`, `AGENTS.md`)은 스택 밖 — 별도 `docs/tasks-setup` PR 또는 Phase 0에 포함 (승인 시 결정).
4242
- 멀티에이전트 (역할은 하니스 무관, 스폰은 하니스별):
@@ -46,7 +46,7 @@
4646
- Cursor (Cline 한도 소진 시 기본): [harness/cursor.md](playbook/harness/cursor.md) — 부모 Grok 4.6 (orchestrator+leader), planner·verifier 서브에이전트, Composer 2.5 implementer는 worktree. 정의: `.cursor/agents/`.
4747
- Cline + Herdr: [harness/cline-herdr.md](playbook/harness/cline-herdr.md) — pane 3개, muse-spark / glm-5.3-flash (2026-09-10 실측).
4848
- Claude Code / Codex: 스텁. 첫 실사용 때 `_template.md`로 승격.
49-
흐름: leader 추적 → planner가 PLAN 정제·리뷰 → developer 구현 + stacked PR → 사람 머지.
49+
흐름: leader 추적 → planner가 PLAN 정제 → developer 구현 + **draft** PR → planner/verifier 리뷰 → ready 전환 → 사람 머지.
5050
**미사용:** Paseo, opencode-go 모델.
5151

5252
## 승인 플로우

‎.tasks/phase-0-foundation/LOG.md‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
- Harness: cursor (Grok parent, this session)
44
- Started: 2026-09-09
5-
- Status: in progress (human: "phase0 부터 진행")
5+
- Status: complete (2026-09-10). SPEC 종료 게이트 충족. `PR-DRAFT phase-0 feat/phase-0-foundation #55`
66

77
## Checklist (PLAN)
88

@@ -11,10 +11,11 @@
1111
- [x] 3a. Astro Docs MCP (Cursor `.cursor/mcp.json`)
1212
- [x] 3b. Astro skill pin — `.agents/skills/astro-publish/` @ `5889789e`
1313
- [x] 3c. AGENTS.md 스킬·금지패턴 + `CLAUDE.md` symlink (기존)
14-
- [ ] 3d. CI 선행 — `feat/ci-gates` (main 생성 후)
14+
- [ ] 3d. CI 선행 — `feat/ci-gates` (Phase 0 종료 게이트 아님. Phase 4 PLAN §0, 다음 스택)
1515
- [x] 4. StyleX spike → Phase 1 PLAN 첨부. sharp 설치+빌드 그린
1616

1717
## Notes
1818

19-
- `docs/tasks-setup` 푸시 후 이 브랜치 `feat/phase-0-foundation`.
19+
- bun·스킬·스파이크·default=`main`은 `origin/main`에 이미 들어가 있음 (`3939883`). 이 브랜치에 남은 것은 playbook draft→ready와 `docs/conventions/prs.md`.
2020
- 스파이크 HTML이 `stylex.css`를 링크하지 않음 → Phase 1 Base.astro 필수.
21+
- 2026-09-10 게이트 재실행: `bun run check` 스크립트 없음(Next 잔재). `oxfmt --check .` 40파일(vendored yarn·스킬 포함). `oxlint .` exit 0 (경고는 `.yarn/releases` 중심). `vitest run` 테스트 파일 0건 exit 1.

‎.tasks/phase-0-foundation/PLAN.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@
3131
- 스파이크 `bun run build` 그린 + 생성 CSS 샘플.
3232

3333
## 승인 요청
34-
- [ ] pm = bun@1.4.2 확정? (유지 희망 시 코멘트)
35-
- [ ] 스킬 1순위 채택 동의?
34+
- [x] pm = bun@1.4.2 확정? (유지 희망 시 코멘트) — 2026-09-09 진행으로 채택
35+
- [x] 스킬 1순위 채택 동의? — `.agents/skills/astro-publish/` @ `5889789e`

‎.tasks/phase-0-foundation/SPEC.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Phase 0 — Foundation: 브랜치·툴체인·지식기반
22

3-
> 상태: 진행 중 (2026-09-09 승인). 브랜치 `feat/phase-0-foundation`.
3+
> 상태: 완료 (2026-09-10). 브랜치 `feat/phase-0-foundation`. `feat/ci-gates`·`master` 삭제는 후속.
44
55
## 1. 배경
66
Next.js 12 잔재 위에서 Astro 이주를 시작할 수 없다. default branch(`master`), Node 14 워크플로우,

‎.tasks/playbook/README.md‎

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,12 @@
1616
|---|---|---|---|
1717
| orchestrator | [orchestrator.md](orchestrator.md) | spawn, routing, gates, ask human to merge | product code |
1818
| leader | [leader.md](leader.md) | phase LOG, sequence, PLAN-CHANGE triage | product code (except LOG/PLAN) |
19-
| planner | [planner.md](planner.md) | refine PLAN.md, review PR | product code, SPEC edits |
20-
| developer | [developer.md](developer.md) | implement PLAN, stacked PR | SPEC/PLAN edits |
19+
| planner | [planner.md](planner.md) | refine PLAN.md, review draft PR | product code, SPEC edits |
20+
| developer | [developer.md](developer.md) | implement PLAN, draft PR → ready after review | SPEC/PLAN edits |
2121

22-
Message verbs (`DONE`, `BLOCKED`, `PLAN-CHANGE`, `PLAN-READY`, `PR-READY`, `REVIEW`) are identical across harnesses. Append every report to `.tasks/phase-N-*/LOG.md`.
22+
Message verbs (`DONE`, `BLOCKED`, `PLAN-CHANGE`, `PLAN-READY`, `PR-DRAFT`, `PR-READY`, `REVIEW`) are identical across harnesses. Append every report to `.tasks/phase-N-*/LOG.md`.
23+
24+
PR lifecycle: developer opens `--draft` immediately at phase complete (`PR-DRAFT`) → planner/verifier review the draft → on `REVIEW APPROVE`, developer (or leader) `gh pr ready` (`PR-READY`) → human merges.
2325

2426
A harness **may fold** orchestrator + leader into one parent session (Cursor default). That is a mapping, not a license to drop LOG or gates.
2527

‎.tasks/playbook/developer.md‎

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,20 @@
11
# Developer Playbook (per-phase)
22

33
> Role contract (harness-agnostic). Model + spawn: [`harness/`](harness/).
4-
> Implements the refined PLAN.md, opens the stacked PR.
4+
> Implements the refined PLAN.md, opens a **draft** stacked PR, then marks it ready after review.
55
66
## Startup brief (leader sends this)
77

88
```text
99
You are developer for Phase N (<name>), branch feat/phase-N-<slug> (base: <parent>).
1010
Harness: <cline-herdr | cursor | claude | codex> — isolation rules in .tasks/playbook/harness/<that>.md.
11-
1. Read .tasks/phase-N-*/SPEC.md + refined PLAN.md + AGENTS.md + shared-code-style (7 rules).
11+
1. Read .tasks/phase-N-*/SPEC.md + refined PLAN.md + AGENTS.md + shared-code-style (7 rules) + docs/conventions/prs.md.
1212
2. Implement PLAN steps in order on your branch (create via `git checkout -b <branch> <parent>` unless the harness already isolated a worktree on that branch).
1313
3. Per step: run its acceptance check; on failure, fix or send PLAN-CHANGE (see below).
1414
4. Co-deliver *.stories.ts for UI components (Phase 1+); keep commits Korean messages.
15-
5. Open stacked PR: `gh pr create --base <parent>` with pr-writer format (Korean, real gate outputs).
16-
6. Reply PR-READY <phase> <branch> <PR#> with gate evidence.
15+
5. Open a **draft** stacked PR immediately: `gh pr create --draft --base <parent> --assignee @me --label … --body-file` following `docs/conventions/prs.md` (Korean, real gate outputs).
16+
6. Reply `PR-DRAFT <phase> <branch> <PR#>`. Do not mark the PR ready yet.
17+
7. After planner (and verifier, if the harness has one) `REVIEW APPROVE`: `gh pr ready <PR#>` then `PR-READY <phase> <branch> <PR#>`.
1718
Rules: product code + stories + PR body only. No SPEC/PLAN edits — propose via PLAN-CHANGE.
1819
```
1920

@@ -30,13 +31,16 @@ PLAN-CHANGE <file> <reason> <proposal>
3031
- Continue with unaffected steps while waiting; stop only if blocked end-to-end.
3132
- On `PLAN-UPDATED`: re-read PLAN.md, re-ack, resume.
3233

33-
## PR requirements (pr-writer skill)
34+
## PR requirements
3435

35-
- Korean title/body, AS-IS vs TO-BE, Mermaid diagram where structural.
36-
- Real gate outputs pasted: `bun run check`, `bunx oxfmt --check .`, `bunx oxlint .`, `bunx vitest run`.
37-
- Stacked base correct; linked issue/phase docs referenced.
36+
Canonical: [`docs/conventions/prs.md`](../../docs/conventions/prs.md). Read it before `gh pr create`.
37+
38+
- Why / effect / design change / scope — not a file list. Mermaid carries the body; no tables.
39+
- Real gate outputs from this HEAD: `bun run check`, `bunx oxfmt --check .`, `bunx oxlint .`, `bunx vitest run`.
40+
- Stacked base correct; `--assignee @me`; labels from the closed set in `prs.md`; `--body-file`; always `--draft` on create. Ready is a post-review step.
3841

3942
## Done
4043

41-
Reply `PR-READY <phase> <branch> <PR#>` to leader. Address planner `CHANGES` findings within 1 round;
42-
2nd CHANGES round → leader decides (re-scope or escalate).
44+
Reply `PR-DRAFT` as soon as the draft exists. After `REVIEW APPROVE`, mark ready (`gh pr ready`) and reply `PR-READY`.
45+
If the developer session has ended, the leader may run `gh pr ready`.
46+
Address planner/verifier `CHANGES` on the draft (still draft) within 1 round; 2nd CHANGES round → leader decides.

‎.tasks/playbook/harness/_template.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ Fallback if a pin 404s or quota-exhausts: … (log substitution in LOG.md).
3939

4040
```text
4141
# numbered steps the orchestrator actually runs
42+
# must include: developer opens --draft (PR-DRAFT) → review → gh pr ready (PR-READY)
4243
```
4344

4445
## MCP / skills this harness must load

0 commit comments

Comments
 (0)