@su-record/vibe 4.1.10 → 4.1.12

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.
Files changed (37) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/.claude-plugin/plugin.json +1 -1
  3. package/.codex-plugin/plugin.json +1 -1
  4. package/README.md +5 -3
  5. package/agents/design-art-director.md +27 -0
  6. package/agents/design-markup-reviewer.md +28 -0
  7. package/agents/en-chief-editor.md +3 -0
  8. package/agents/en-copy-editor.md +3 -0
  9. package/agents/ko-chief-editor.md +6 -0
  10. package/agents/ko-copy-editor.md +7 -0
  11. package/card.md +7 -6
  12. package/dist/core/checks/packs.js +27 -0
  13. package/dist/core/checks/packs.js.map +1 -0
  14. package/dist/core/checks/review.js +50 -28
  15. package/dist/core/checks/review.js.map +1 -1
  16. package/dist/core/checks/source.js +51 -0
  17. package/dist/core/checks/source.js.map +1 -0
  18. package/dist/core/scenarios.js +3 -0
  19. package/dist/core/scenarios.js.map +1 -1
  20. package/dist/install/plugin.js +19 -13
  21. package/dist/install/plugin.js.map +1 -1
  22. package/package.json +1 -1
  23. package/reviewers/design/1-markup-reviewer.md +21 -0
  24. package/reviewers/design/2-art-director.md +20 -0
  25. package/reviewers/en/{copy-editor.md → 1-copy-editor.md} +3 -0
  26. package/reviewers/en/{chief-editor.md → 2-chief-editor.md} +3 -0
  27. package/reviewers/ko/{copy-editor.md → 1-copy-editor.md} +7 -0
  28. package/reviewers/ko/{chief-editor.md → 2-chief-editor.md} +6 -0
  29. package/skills/antislop-design/SKILL.md +231 -0
  30. package/skills/antislop-design/references/catalogue.md +42 -0
  31. package/skills/antislop-design/references/plan.md +131 -0
  32. package/skills/antislop-en/SKILL.md +50 -0
  33. package/skills/antislop-en/references/editorial-review.md +1 -1
  34. package/skills/antislop-ko/SKILL.md +88 -0
  35. package/skills/antislop-ko/references/editorial-review.md +1 -1
  36. package/skills/vibe-handoff/SKILL.md +12 -0
  37. package/skills/vibe-scope/SKILL.md +2 -1
@@ -6,14 +6,14 @@
6
6
  },
7
7
  "metadata": {
8
8
  "description": "An AX/FDE harness for Claude Code, Codex CLI and ChatGPT desktop. Say what you need, approve the scenarios once; the harness proves the work by running the checks itself. Memory in plain files, human tokens for irreversible actions, a ledger instead of claims.",
9
- "version": "4.1.10"
9
+ "version": "4.1.12"
10
10
  },
11
11
  "plugins": [
12
12
  {
13
13
  "name": "vibe",
14
14
  "source": "./",
15
15
  "description": "An AX/FDE harness for Claude Code, Codex CLI and ChatGPT desktop. Say what you need, approve the scenarios once; the harness proves the work by running the checks itself. Memory in plain files, human tokens for irreversible actions, a ledger instead of claims.",
16
- "version": "4.1.10",
16
+ "version": "4.1.12",
17
17
  "category": "productivity"
18
18
  }
19
19
  ]
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vibe",
3
- "version": "4.1.10",
3
+ "version": "4.1.12",
4
4
  "description": "An AX/FDE harness for Claude Code, Codex CLI and ChatGPT desktop. Say what you need, approve the scenarios once; the harness proves the work by running the checks itself. Memory in plain files, human tokens for irreversible actions, a ledger instead of claims.",
5
5
  "author": {
6
6
  "name": "su-record",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vibe",
3
- "version": "4.1.10",
3
+ "version": "4.1.12",
4
4
  "description": "An AX/FDE harness for Claude Code, Codex CLI and ChatGPT desktop. Say what you need, approve the scenarios once; the harness proves the work by running the checks itself. Memory in plain files, human tokens for irreversible actions, a ledger instead of claims.",
5
5
  "author": {
6
6
  "name": "su-record",
package/README.md CHANGED
@@ -55,7 +55,7 @@ Any client can pick the work up: `vibe state` says where you are, because the st
55
55
  | `file` | exists · regex · substring · JSON Schema · column sum | `path`, `exists` / `pattern` / `contains` / `schema` / `sum: {column, equals, tolerance}` |
56
56
  | `http` | status · body schema · latency ceiling | `url`, `method`, `expect: {status, schema, maxMs}`, `timeoutMs` |
57
57
  | `eval` | count of matching cases (never a ratio) | `cases` (jsonl `{id, input, expected}`), `runner` (stdin → stdout), `expect: {pass}` |
58
- | `review` | a language pack's reviewers — copy editor, then chief editor — run by the harness through the client CLI; a stage passes only on an exact `PASS` | `path` (the manuscript), `lang` (`ko` · `en`, else detected from the text), `contract`, `evidence`, `timeoutMs` |
58
+ | `review` | an antislop pack's reviewer stages, in order, run by the harness through the client CLI; a stage passes only on an exact `PASS` | `path` (the artifact: a file, or a directory for `pack: design`), `pack` (`ko` · `en` · `design`), `lang` (`ko` · `en`, else detected from the text), `contract`, `evidence`, `screenshot`, `timeoutMs` |
59
59
  | `human` | none — a question in the inbox | `question` |
60
60
 
61
61
  `review` is the only model-judged check: the harness spawns `claude -p` (or `codex exec`, or `VIBE_REVIEW_CMD`) with the reviewer prompt and the manuscript on stdin, and reads the reply — nothing the writing model says about its own prose counts. The scope skill marks such a scenario `⚠ model-judged`, and the same REJECT twice in a row is STUCK like any other failure.
@@ -118,7 +118,9 @@ Default catalogs: `anthropics/skills`, `vercel-labs/agent-skills`, `NousResearch
118
118
 
119
119
  Six common skills ship with the package — `vibe` (entry), `vibe-discover`, `vibe-scope`, `vibe-build`, `vibe-prove`, `vibe-handoff` — under 300 lines in total, named by the Agent Skills grammar (lowercase, digits, hyphens; name = directory) so Claude Code, Codex and ChatGPT load them alike. They contain the harness command sequence and message shapes for each stage, nothing about how to code.
120
120
 
121
- Language packs ship next to the six: `antislop-ko` and `antislop-en` (`skills/antislop-<lang>`, written in that language) carry the writing principles that strip AI clichés and translationese, and `reviewers/<lang>/` the two reviewer prompts the `review` check runs — also installed as client agents (`agents/<lang>-copy-editor.md` for Claude Code, TOML under the Codex plugin tree). A pack loads only when that language is written.
121
+ Antislop packs ship next to the six. A pack is a medium, not only a language: `antislop-ko` and `antislop-en` carry the writing principles that strip AI clichés and translationese, `antislop-design` the ones that strip generic AI interfaces (the gradient hero over three glass cards, emoji icons, invented stat tiles, fade-up on every section, one typeface, everything centred). Each pack's `reviewers/<pack>/N-<stage>.md` files are the stages the `review` check runs in order — text: copy editor then chief editor; design: markup reviewer then art director — and they are installed as client agents too (`agents/<pack>-<stage>.md` for Claude Code, TOML under the Codex plugin tree). A pack loads only when that medium is worked on.
122
+
123
+ The design pack judges source, not pixels: `check: { type: review, pack: design, path: <file or directory>, contract: <brief>, screenshot: <png> }`. The harness renders nothing — when a screenshot is wanted, an earlier scenario produces it with the project's own tooling and this check hands the path to the art director, who opens it. The text packs keep working through `lang` and through the language of the manuscript.
122
124
 
123
125
  The six live in the client home, not in the repository. Project-specific skills live only inside the project (`.claude/skills`, `.codex/skills`, registry in `.vibe/skills/`) and are installed only when bound to a check or carrying knowledge the model lacks:
124
126
 
@@ -152,7 +154,7 @@ config.json token policy · skill catalogs
152
154
 
153
155
  ## Status
154
156
 
155
- `4.0.0` — phase 1: CLI core + Claude Code. Phase 2: Codex CLI and ChatGPT desktop adapters, the work graph and typed ledger edges. Phase 3a: `http` / `eval` checks, column sums, sample profiling. Phase 3b: GitHub research, project-local skills and proposals. Phase 3c: the end-to-end order-settlement example. Phase 4: the bench and `ledger compare --by harness`. `4.0.2`: no `init` — the card, skills and hook live in the client home and any `vibe` command repairs them. `4.0.3`: `vibe uninstall` also clears what an older `init` left in the project. `4.1.0`: the package is the plugin — `npm i -g` registers a local plugin in Claude Code and Codex/ChatGPT, Hermes Agent joins as a client, `vibe plugin build --check` gates manifest drift. `4.1.1`: `vibe update`. `4.1.2`: the Claude desktop app through an MCP Bundle (`vibe plugin mcpb`). `4.1.3`: the bundle finds the CLI without the shell's PATH (Homebrew, nvm, fnm, volta) or from a path set at install. `4.1.4`: `vibe read` for xlsx · docx · pptx · pdf, `vibe profile` reads xlsx, card rule 8 (read files whole). `4.1.5`: `vibe read` for Hangul hwp · hwpx and html. `4.1.6`: `vibe size`, a built-in file/function size check for any project; the CLI split into modules; the repository's own limit is now per file (400), not a total. `4.1.7`: hook entries left by vibe 3 that point at a missing script are swept at every command, so Claude Code stops reporting them. `4.1.8`: the five stage skills are `vibe-discover` … `vibe-handoff` (a dot is outside the Agent Skills name grammar) and the dotted directories an older install left in a client home are swept; `.vibe/` means one thing — the plugin tree moves to `~/.config/vibe/plugin`, a `.vibe/` counts as a project only when it holds a record, the search stops at `.git` and never lands on the home, `vibe state` shows `root`, a `run` check that exits 127 names its cwd; the `review` check and the `antislop-ko` · `antislop-en` language packs — the harness runs a copy editor and a chief editor on human-read text and passes only on `PASS`. vibe 3 stays on its 3.x tags and is no longer developed. `4.1.9`: Codex follows `vibe update` — the version Codex actually holds is read from its cache, compared with the package and re-registered (remove + add) when behind; a marketplace entry still pointing at the ≤ 4.1.7 store is drift; `vibe status` reports the Codex plugin version it read, not the package version. `4.1.10`: `vibe read --ask` — the harness reads for the model: files (numbered) go to a low-reasoning reader on the client CLI and only the answer returns; the reader runs slim (own system prompt, no tools, no settings, neutral directory) and one session per file set is resumed for follow-up questions so the corpus is read from cache, with the hit reported; the hook advises `--ask` on reads over 400 lines; card rule 8 says when to delegate; the `review` check's Codex command gets `--skip-git-repo-check`. Also: `regress record` made ids longer than the 40-character rule, so every recorded regression was silently left out of `check --all` — the id now fits, a file that parses to nothing is named in `vibe state`, and the repository's four regressions run again.
157
+ `4.0.0` — phase 1: CLI core + Claude Code. Phase 2: Codex CLI and ChatGPT desktop adapters, the work graph and typed ledger edges. Phase 3a: `http` / `eval` checks, column sums, sample profiling. Phase 3b: GitHub research, project-local skills and proposals. Phase 3c: the end-to-end order-settlement example. Phase 4: the bench and `ledger compare --by harness`. `4.0.2`: no `init` — the card, skills and hook live in the client home and any `vibe` command repairs them. `4.0.3`: `vibe uninstall` also clears what an older `init` left in the project. `4.1.0`: the package is the plugin — `npm i -g` registers a local plugin in Claude Code and Codex/ChatGPT, Hermes Agent joins as a client, `vibe plugin build --check` gates manifest drift. `4.1.1`: `vibe update`. `4.1.2`: the Claude desktop app through an MCP Bundle (`vibe plugin mcpb`). `4.1.3`: the bundle finds the CLI without the shell's PATH (Homebrew, nvm, fnm, volta) or from a path set at install. `4.1.4`: `vibe read` for xlsx · docx · pptx · pdf, `vibe profile` reads xlsx, card rule 8 (read files whole). `4.1.5`: `vibe read` for Hangul hwp · hwpx and html. `4.1.6`: `vibe size`, a built-in file/function size check for any project; the CLI split into modules; the repository's own limit is now per file (400), not a total. `4.1.7`: hook entries left by vibe 3 that point at a missing script are swept at every command, so Claude Code stops reporting them. `4.1.8`: the five stage skills are `vibe-discover` … `vibe-handoff` (a dot is outside the Agent Skills name grammar) and the dotted directories an older install left in a client home are swept; `.vibe/` means one thing — the plugin tree moves to `~/.config/vibe/plugin`, a `.vibe/` counts as a project only when it holds a record, the search stops at `.git` and never lands on the home, `vibe state` shows `root`, a `run` check that exits 127 names its cwd; the `review` check and the `antislop-ko` · `antislop-en` language packs — the harness runs a copy editor and a chief editor on human-read text and passes only on `PASS`. vibe 3 stays on its 3.x tags and is no longer developed. `4.1.9`: Codex follows `vibe update` — the version Codex actually holds is read from its cache, compared with the package and re-registered (remove + add) when behind; a marketplace entry still pointing at the ≤ 4.1.7 store is drift; `vibe status` reports the Codex plugin version it read, not the package version. `4.1.10`: `vibe read --ask` — the harness reads for the model: files (numbered) go to a low-reasoning reader on the client CLI and only the answer returns; the reader runs slim (own system prompt, no tools, no settings, neutral directory) and one session per file set is resumed for follow-up questions so the corpus is read from cache, with the hit reported; the hook advises `--ask` on reads over 400 lines; card rule 8 says when to delegate; the `review` check's Codex command gets `--skip-git-repo-check`. Also: `regress record` made ids longer than the 40-character rule, so every recorded regression was silently left out of `check --all` — the id now fits, a file that parses to nothing is named in `vibe state`, and the repository's four regressions run again. `4.1.11`: antislop reaches design — `antislop-design` and its two reviewers (markup reviewer, art director) join the text packs, reviewer stages are data (`reviewers/<pack>/N-<stage>.md`), the `review` check takes `pack`, a directory of source and a `screenshot`; the text packs gain strength tiers, five questions before a cut, the portability test, notes-to-the-writer, sample-outranks-rules and a what-is-not-a-tell list, and the reviewers may name what to keep. `4.1.12`: the agent's own report is not slop — card rule 9 (what changed apart from what `vibe check` verified; keep the caveat that changes the next step; an error is its cause and fix; answer first, no praise, apology or closing offer) and a Report voice section in `vibe-handoff` (each Built line names its check and run or says "not checked"; estimates in turns and tool calls, never calendar time; the handoff document follows `antislop-en`).
156
158
 
157
159
  ## Bench — the ledger is the benchmark
158
160
 
@@ -0,0 +1,27 @@
1
+ ---
2
+ name: design-art-director
3
+ description: Second-stage design reviewer judging whether a design that has passed markup review is fit to ship. Checks hierarchy, specificity to the brief, density, states, distinctiveness and copy voice, opening a screenshot when one is given. Called at the second stage of independent editorial review in the antislop-design skill. Does not rewrite the source; returns only PASS or a REJECT list.
4
+ tools: Read, Grep, WebFetch, WebSearch
5
+ model: inherit
6
+ ---
7
+
8
+ You are an art director seeing this work for the first time. Judge only whether the design is fit to ship — do not rewrite it.
9
+
10
+ The caller gives you the design brief as the editorial contract (who uses this, how often, the task, and any stated brand tokens or constraints), the evidence ledger (real data sources, real copy, confirmed brand values, and what is unconfirmed or placeholder), and the full source, already passed by the markup reviewer, under `## Source`. If `## Screenshot` names a file, open it with your file reader before judging and base your judgment on the rendered result; otherwise judge the source directly and say so is what you are doing. If the brief or key evidence is missing, do not pretend to review — output one line, `NEEDS-HUMAN`, and list only what is missing.
11
+
12
+ What to check:
13
+ - Hierarchy: what is seen first, and whether that is what the stated task in the brief needs seen first
14
+ - Specificity to the brief and its content: whether this design would move unchanged to a different product, brand or brief — the portability test for design; a design that passes that test unmodified is not specific to this one
15
+ - Density fit for how often and how briefly the stated user looks at this
16
+ - Whether the states the brief implies (empty, loading, error, long text, many items, one item, narrow viewport) are visibly accounted for, not only the populated average-length case
17
+ - Distinctiveness that comes from a decision, not decoration: reaching for one of the five named aesthetic clusters (warm minimal, dark neon, broadsheet, SaaS card kit, template chrome) counts as generic unless the brief specifically calls for that look
18
+ - Motion: whether any animation serves a purpose the user would miss if it were removed, versus applied uniformly as default polish
19
+ - Copy voice: whether headings, labels and button text are specific to the action and the audience, not generic filler
20
+
21
+ Output rules:
22
+ - If there is no defect that would block shipping, output exactly one line, `PASS`, with no surrounding explanation.
23
+ - If there is a defect, write `REJECT` on the first line, then one line per item in the form `file:line | what | why it hurts the reader/user | what would fix it`. Fill in all four fields. When judging from a screenshot, use the screenshot path in place of a line number.
24
+ - You may end the list with up to three lines in the form `KEEP | <span> | <reason>` naming spans that must not be touched while fixing the rejected items.
25
+ - Do not rewrite the design, and do not impose a personal aesthetic preference as if it were the brief's standard.
26
+ - Do not invent a brand rule that is not in the brief and use it as grounds for rejection.
27
+ - Do not demand a change that conflicts with the evidence ledger. If the evidence itself looks doubtful (an unsourced stat, a placeholder image left as if final), name that in the reason for rejection.
@@ -0,0 +1,28 @@
1
+ ---
2
+ name: design-markup-reviewer
3
+ description: First-stage design reviewer for markup and CSS. Judges only semantic structure, accessibility basics, contrast and catalogue slop markers in HTML/CSS/React/Vue/Svelte/SVG source bound for shipping. Called at the first stage of independent editorial review in the antislop-design skill. Does not rewrite the source; returns only PASS or a REJECT list.
4
+ tools: Read, Grep, WebFetch, WebSearch
5
+ model: inherit
6
+ ---
7
+
8
+ You are a front-end lead seeing this source for the first time. Judge defects only — do not rewrite the source.
9
+
10
+ The caller gives you the design brief as the editorial contract (who uses this, how often, the task, and any stated brand tokens or constraints), the evidence ledger (real data sources, real copy, confirmed brand values, and what is unconfirmed or placeholder), the full source under `## Source` (each file numbered line by line), and optionally `## Screenshot` naming a rendered image path. If the brief or key evidence is missing from these, do not pretend to review — output one line, `NEEDS-HUMAN`, and list only what is missing.
11
+
12
+ What to check:
13
+ - Semantic structure and landmarks: headings in one logical order, lists as `<ul>`/`<ol>`, buttons as `<button>`, links as `<a>` with a real `href`, regions marked with `<nav>`/`<main>`/`<header>`/`<footer>` rather than unlabelled `<div>`s
14
+ - Form inputs each paired with a `<label>` (or `aria-label`), and a sensible tab/focus order matching the visual order
15
+ - Images and icons carrying meaningful `alt` text, or `alt=""` when purely decorative
16
+ - Contrast of stated or computed text and background colours against the 4.5:1 threshold for normal text
17
+ - The catalogue markers in `references/catalogue.md` of the `antislop-design` skill: a strong marker (gradient hero plus three cards, emoji icons, invented stats, fake testimonials, vague-verb CTA copy) flagged alone; a weak marker (rounded corners, a shadow, centred text, uniform spacing) flagged only when two or more overlap in the same component or passage
18
+ - Copy defects: placeholder text left in ("Lorem ipsum," "Your Company," a bracketed `[TODO]`), generic verbs with no specific referent, a button label that does not name its actual action
19
+ - Invented data: a statistic, count, testimonial or username not traceable to the evidence ledger
20
+
21
+ Output rules:
22
+ - If there are no defects, output exactly one line, `PASS`, with no surrounding explanation.
23
+ - If there are defects, write `REJECT` on the first line, then one line per item in the form `file:line | what | why it hurts the reader/user | what would fix it`. Fill in all four fields.
24
+ - You may end the list with up to three lines in the form `KEEP | <span> | <reason>` naming spans that must not be touched while fixing the rejected items.
25
+ - Do not flag a difference that is purely a matter of taste. Do not flag a problem you cannot pin to a location and a user effect.
26
+ - Do not flag a single weak marker alone; only flag it where two or more overlap.
27
+ - Do not add content the evidence does not contain, and do not write replacement markup or CSS.
28
+ - Do not treat a brand-mandated colour, typeface or logo usage stated in the brief as a defect.
@@ -18,9 +18,12 @@ What to check:
18
18
  - Whether there is a sentence or paragraph that could be deleted without changing the information, the argument or the emotional arc
19
19
  - Whether a counter-argument is distorted, or the reader is asked to take something on faith without a chance to verify it
20
20
 
21
+ A weak tell alone is not grounds for a REJECT item: a single hedge, a single hyphenated compound, one passive clause with no actor worth naming, or one bolded phrase. Flag it only when two or more such tells overlap in the same passage. A tell that already changes what the reader can trust on its own, such as a stale cliché carrying a false claim of significance or an unsupported tricolon standing in for evidence, is grounds for REJECT by itself.
22
+
21
23
  Output rules:
22
24
  - If there is no defect that would block publication, output exactly one line, `PASS`, with no surrounding explanation.
23
25
  - If there is a defect, write `REJECT` on the first line, then one line per item in the form `location | reason | reader impact | pass condition`. Fill in all four fields.
24
26
  - Do not rewrite the manuscript, and do not impose a personal preference as if it were the outlet's standard.
25
27
  - Do not invent an editorial policy that is not in the editorial contract and use it as grounds for rejection.
26
28
  - Do not demand a change that conflicts with the evidence ledger. If the evidence itself looks doubtful, state that in the reason for rejection.
29
+ - The REJECT list may end with up to three lines in the form `KEEP | <span> | <reason>`, naming a specific span the writer must not touch while fixing the findings above. Use it only for a span worth protecting from an overcorrection; do not pad the list to three when there is nothing to protect.
@@ -18,9 +18,12 @@ What to check:
18
18
 
19
19
  For a usage question that needs a ruling, do not rely on memory — verify against a named dictionary and the stated style guide's current entries. When more than one form is acceptable, follow the editorial contract's formatting rule and the document's own internal consistency.
20
20
 
21
+ A weak tell alone is not grounds for a REJECT item: a single hedge, a single hyphenated compound, one passive clause with no actor worth naming, or one bolded phrase. Flag it only when two or more such tells overlap in the same passage. A tell that already changes what the reader can trust on its own, such as a dropped fact, a broken agreement or a wrong reference, is grounds for REJECT by itself.
22
+
21
23
  Output rules:
22
24
  - If there are no defects, output exactly one line, `PASS`, with no surrounding explanation.
23
25
  - If there are defects, write `REJECT` on the first line, then one line per item in the form `location | original | impact | fix condition`. Fill in all four fields.
24
26
  - Do not flag a difference that is purely a matter of taste. Do not flag a problem you cannot pin to a location and a reader effect.
25
27
  - Do not add content the evidence does not contain, and do not write a full replacement sentence.
26
28
  - Do not treat a character's dialogue, a quotation, or a deliberate non-standard usage in the manuscript as a defect.
29
+ - The REJECT list may end with up to three lines in the form `KEEP | <span> | <reason>`, naming a specific span the writer must not touch while fixing the findings above. Use it only for a span worth protecting from an overcorrection; do not pad the list to three when there is nothing to protect.
@@ -20,6 +20,10 @@ model: inherit
20
20
  - 삭제해도 정보·논지·감정선이 달라지지 않는 문장이나 문단이 있는가
21
21
  - 반론을 왜곡하거나 독자가 사실 확인 없이 믿어야 하는 대목이 있는가
22
22
 
23
+ 약한 표지와 강한 표지를 구분하라. 줄표 하나, 번역투 조사구 하나처럼 그 자체로는 흔한
24
+ 습관인 약한 표지는 같은 대목에 다른 표지와 둘 이상 겹칠 때만 반려 사유로 올려라. 진부한
25
+ 시대 선언, 근거 없는 삼단 나열·최상급처럼 강한 표지는 한 번만 나와도 반려 사유로 올려라.
26
+
23
27
  출력 규칙:
24
28
  - 게재를 막을 결함이 없으면 앞뒤 설명 없이 `PASS` 한 줄만 출력하라.
25
29
  - 결함이 있으면 첫 줄에 `REJECT`를 쓰고, 다음 줄부터 항목마다 한 줄씩
@@ -27,3 +31,5 @@ model: inherit
27
31
  - 원고를 대신 쓰거나 개인 취향을 매체 기준인 것처럼 강요하지 마라.
28
32
  - 편집 계약에 없는 편집 방침을 꾸며내어 반려 사유로 삼지 마라.
29
33
  - 근거 장부와 충돌하는 수정을 요구하지 마라. 근거 자체가 의심스러우면 그 사실을 반려 사유에 적어라.
34
+ - `REJECT` 목록의 끝에는 필자가 손대면 안 되는 대목을 최대 세 줄까지 `KEEP | 구간 | 이유`
35
+ 형식으로 덧붙일 수 있다. 목소리나 논지를 살리려고 남겨 둔 대목일 때만 쓴다.
@@ -21,6 +21,11 @@ model: inherit
21
21
  규범 판단이 필요한 말은 기억에 기대지 말고 국립국어원 어문 규범과 표준국어대사전의 현재 용례를
22
22
  확인한다. 허용 표기가 여럿이면 편집 계약의 표기 원칙과 문서 안의 일관성을 따른다.
23
23
 
24
+ 약한 표지와 강한 표지를 구분하라. 줄표 하나, 번역투 조사구 하나처럼 그 자체로는 흔한
25
+ 습관인 약한 표지는 같은 대목에 다른 표지와 둘 이상 겹칠 때만 REJECT 항목으로 올려라.
26
+ 근거 없는 도입·결말, 실제 대조 없는 `A가 아니라 B다`처럼 강한 표지는 한 번만 나와도
27
+ REJECT 항목으로 올려라.
28
+
24
29
  출력 규칙:
25
30
  - 오류가 없으면 앞뒤 설명 없이 `PASS` 한 줄만 출력하라.
26
31
  - 오류가 있으면 첫 줄에 `REJECT`를 쓰고, 다음 줄부터 항목마다 한 줄씩
@@ -28,3 +33,5 @@ model: inherit
28
33
  - 취향만 다른 표현은 지적하지 마라. 위치와 독자 영향을 특정할 수 없는 문제는 지적하지 마라.
29
34
  - 근거에 없는 내용을 추가하거나 수정문 전체를 작성하지 마라.
30
35
  - 원고의 인물 대사, 인용, 의도적인 비표준 표현은 결함으로 보지 마라.
36
+ - `REJECT` 목록의 끝에는 필자가 손대면 안 되는 대목을 최대 세 줄까지 `KEEP | 구간 | 이유`
37
+ 형식으로 덧붙일 수 있다. 목소리나 리듬을 살리려고 남겨 둔 대목일 때만 쓴다.
package/card.md CHANGED
@@ -1,10 +1,11 @@
1
1
  You are working inside vibe. Rules:
2
2
  1. Before changing anything, run `vibe state --json` and continue from it.
3
- 2. Nothing is done until `vibe check` says DONE. Never claim completion yourself.
4
- 3. When the harness asks for a human token (approval or an irreversible action), show the number and wait for it in chat. Never invent one.
3
+ 2. Nothing is done until `vibe check` says DONE. Never claim it yourself.
4
+ 3. When the harness asks for a human token, show the number and wait in chat. Never invent one.
5
5
  4. If `vibe check` fails twice the same way, stop and `vibe ask`.
6
- 5. Surface at most three things the user did not ask about, each with a reason from the harness.
7
- 6. Record any failure you fixed with `vibe regress record`.
8
- 7. Talk to the user in the user's language. Write every record (intent, scenarios, inbox, knowledge, docs) in English.
9
- 8. Read files whole with your file reader; search only to find which file. To understand a file without editing or debugging it, `vibe read <files> --ask "…"`: a low-reasoning model reads, the answer returns with line numbers. Documents and samples: `vibe read` / `vibe profile`; images: your own eyes.
6
+ 5. Surface at most three unasked things, each with a harness reason.
7
+ 6. Record each fixed failure with `vibe regress record`.
8
+ 7. Talk in the user's language; write every record (intent, scenarios, inbox, knowledge, docs) in English.
9
+ 8. Read files whole; search only to find which file. A file you will not edit or debug: `vibe read <files> --ask "…"`. Documents, samples: `vibe read` / `vibe profile`; images: your eyes.
10
+ 9. Report what changed apart from what `vibe check` verified. Keep the caveat that changes the user's next step; cut other hedges. An error is its cause and its fix. Answer first; no praise, apology or closing offer.
10
11
  Start with `/vibe {request}`.
@@ -0,0 +1,27 @@
1
+ import fs from 'node:fs';
2
+ import path from 'node:path';
3
+ import { packageRoot } from '../paths.js';
4
+ const STAGE_FILE = /^(\d+)-([a-z0-9]+(?:-[a-z0-9]+)*)\.md$/;
5
+ export function reviewersDir(pack, root = packageRoot()) {
6
+ return path.join(root, 'reviewers', pack);
7
+ }
8
+ /** The stages of a pack, in numeric order; an empty list means the pack is not in this package. */
9
+ export function packStages(pack, root = packageRoot()) {
10
+ const dir = reviewersDir(pack, root);
11
+ if (!fs.existsSync(dir))
12
+ return [];
13
+ const stages = [];
14
+ for (const name of fs.readdirSync(dir)) {
15
+ const m = STAGE_FILE.exec(name);
16
+ if (m)
17
+ stages.push({ order: Number(m[1]), name: m[2], file: path.join(dir, name) });
18
+ }
19
+ return stages.sort((a, b) => a.order - b.order || a.name.localeCompare(b.name));
20
+ }
21
+ export function listPacks(root = packageRoot()) {
22
+ const dir = path.join(root, 'reviewers');
23
+ return fs.existsSync(dir) ? fs.readdirSync(dir).filter((n) => fs.statSync(path.join(dir, n)).isDirectory()).sort() : [];
24
+ }
25
+ /** Text packs are the ones a manuscript's language can select; every other pack is named by `pack`. */
26
+ export const TEXT_PACKS = ['ko', 'en'];
27
+ //# sourceMappingURL=packs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"packs.js","sourceRoot":"","sources":["../../../src/core/checks/packs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAc1C,MAAM,UAAU,GAAG,wCAAwC,CAAC;AAE5D,MAAM,UAAU,YAAY,CAAC,IAAY,EAAE,OAAe,WAAW,EAAE;IACrE,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,WAAW,EAAE,IAAI,CAAC,CAAC;AAC5C,CAAC;AAED,mGAAmG;AACnG,MAAM,UAAU,UAAU,CAAC,IAAY,EAAE,OAAe,WAAW,EAAE;IACnE,MAAM,GAAG,GAAG,YAAY,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;IACrC,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,GAAG,CAAC;QAAE,OAAO,EAAE,CAAC;IACnC,MAAM,MAAM,GAAY,EAAE,CA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from '../lang.js';
5
- import { packageRoot } from '../paths.js';
5
+ import { packStages, TEXT_PACKS } from './packs.js';
6
+ import { collectSource } from './source.js';
6
7
  import { tail } from './run.js';
7
- const STAGES = ['copy-editor', 'chief-editor'];
8
8
  const DEFAULT_TIMEOUT_MS = 600_000;
9
+ const MAX_SOURCE_CHARS = 400_000;
9
10
  const MAX_CAPTURE = 256 * 1024;
10
11
  /** The reviewer command: `VIBE_REVIEW_CMD` (tests, custom clients), else the client CLI on PATH. The prompt goes to stdin, the reply is stdout. */
11
12
  export function reviewerCommand() {
@@ -19,18 +20,31 @@ export function reviewerCommand() {
19
20
  return 'codex exec --skip-git-repo-check -';
20
21
  return null;
21
22
  }
22
- function reviewerPrompt(lang, stage) {
23
- const file = path.join(packageRoot(), 'reviewers', lang, `${stage}.md`);
24
- return fs.existsSync(file) ? fs.readFileSync(file, 'utf-8') : null;
25
- }
26
23
  function readOptional(root, file) {
27
24
  if (!file)
28
25
  return '(not provided)';
29
26
  const full = path.resolve(root, file);
30
27
  return fs.existsSync(full) ? fs.readFileSync(full, 'utf-8') : `(missing file: ${file})`;
31
28
  }
32
- function bundle(instructions, contract, evidence, manuscript) {
33
- return `${instructions.trim()}\n\n---\n\n## Editorial contract\n\n${contract.trim()}\n\n## Evidence ledger\n\n${evidence.trim()}\n\n## Manuscript\n\n${manuscript}\n`;
29
+ function bundle(instructions, contract, evidence, body, screenshot) {
30
+ return `${instructions.trim()}\n\n---\n\n## Editorial contract\n\n${contract.trim()}\n\n## Evidence ledger\n\n${evidence.trim()}${screenshot}\n\n${body}\n`;
31
+ }
32
+ /** A text pack judges a manuscript; every other pack judges source, one file or a directory of them. */
33
+ function artifact(check, root, pack) {
34
+ if (TEXT_PACKS.includes(pack)) {
35
+ return { section: 'Manuscript', body: fs.readFileSync(path.resolve(root, check.path), 'utf-8') };
36
+ }
37
+ const collected = collectSource(root, check.path, MAX_SOURCE_CHARS);
38
+ return { section: 'Source', body: collected.text };
39
+ }
40
+ /** The pack: what the check names, else the text pack for `lang`, else the language of the text itself. */
41
+ function choosePack(check, root) {
42
+ if (check.pack)
43
+ return check.pack;
44
+ if (check.lang)
45
+ return check.lang;
46
+ const file = path.resolve(root, check.path);
47
+ return fs.statSync(file).isDirectory() ? null : detectLang(fs.readFileSync(file, 'utf-8'));
34
48
  }
35
49
  function ask(cmd, cwd, prompt, timeoutMs) {
36
50
  return new Promise((resolve) => {
@@ -57,42 +71,50 @@ function ask(cmd, cwd, prompt, timeoutMs) {
57
71
  });
58
72
  }
59
73
  /**
60
- * `review` check — the harness itself runs the language pack's reviewers in order (copy editor,
61
- * then chief editor) and reads their verdict. A stage passes only when the whole trimmed reply is
62
- * exactly `PASS`; a REJECT list, a remark after PASS, an empty or killed reply all fail, with the
63
- * reply kept in `tail`. The manuscript is never edited here.
74
+ * `review` check — the harness itself runs the pack's reviewer stages in order and reads their
75
+ * verdict. A stage passes only when the whole trimmed reply is exactly `PASS`; a REJECT list, a
76
+ * remark after PASS, an empty or killed reply all fail, with the reply kept in `tail`. Nothing is
77
+ * edited here: the reviewers judge, the writer fixes.
64
78
  */
65
79
  export async function reviewCheck(check, root) {
66
80
  const started = Date.now();
67
81
  const fail = (reason, text = '') => ({ pass: false, exit: 1, ms: Date.now() - started, tail: tail(text), reason });
68
- const file = path.resolve(root, check.path);
69
- if (!fs.existsSync(file))
70
- return fail(`manuscript missing: ${check.path}`);
71
- const manuscript = fs.readFileSync(file, 'utf-8');
72
- const lang = check.lang ?? detectLang(manuscript);
73
- if (!lang)
74
- return fail(`language unknown — set lang: ko|en on the check`);
82
+ if (!fs.existsSync(path.resolve(root, check.path)))
83
+ return fail(`artifact missing: ${check.path}`);
84
+ const pack = choosePack(check, root);
85
+ if (!pack)
86
+ return fail('language unknown — set lang: ko|en or pack: <name> on the check');
87
+ const stages = packStages(pack);
88
+ if (stages.length === 0)
89
+ return fail(`no reviewers/${pack} in this package`);
75
90
  const cmd = reviewerCommand();
76
91
  if (!cmd)
77
92
  return fail('no reviewer available — needs `claude` or `codex` on PATH, or VIBE_REVIEW_CMD');
93
+ let piece;
94
+ try {
95
+ piece = artifact(check, root, pack);
96
+ }
97
+ catch (error) {
98
+ return fail(error.message);
99
+ }
78
100
  const contract = readOptional(root, check.contract);
79
101
  const evidence = readOptional(root, check.evidence);
102
+ const shot = check.screenshot ? `\n\n## Screenshot\n\n${path.resolve(root, check.screenshot)} — open this image with your file reader before judging.` : '';
80
103
  const timeoutMs = check.timeoutMs ?? DEFAULT_TIMEOUT_MS;
81
104
  const lines = [];
82
- for (const stage of STAGES) {
83
- const instructions = reviewerPrompt(lang, stage);
84
- if (!instructions)
85
- return fail(`no ${lang} ${stage} in this package`);
86
- const r = await ask(cmd, root, bundle(instructions, contract, evidence, manuscript), timeoutMs);
105
+ for (const stage of stages) {
106
+ const instructions = fs.readFileSync(stage.file, 'utf-8');
107
+ const prompt = bundle(instructions, contract, evidence, `## ${piece.section}\n\n${piece.body}`, shot);
108
+ const r = await ask(cmd, root, prompt, timeoutMs);
87
109
  if (r.killed)
88
- return fail(`${stage}: killed after ${timeoutMs}ms`, lines.join('\n'));
110
+ return fail(`${stage.name}: killed after ${timeoutMs}ms`, lines.join('\n'));
89
111
  const verdict = r.reply.trim();
90
112
  if (verdict === 'PASS') {
91
- lines.push(`${lang} ${stage}: PASS`);
113
+ lines.push(`${pack} ${stage.name}: PASS`);
92
114
  continue;
93
115
  }
94
- lines.push(`${lang} ${stage}: ${verdict === '' ? `no reply (exit ${r.exit})` : 'not PASS'}`, verdict);
95
- return fail(`${stage} did not pass`, lines.join('\n'));
116
+ lines.push(`${pack} ${stage.name}: ${verdict === '' ? `no reply (exit ${r.exit})` : 'not PASS'}`, verdict);
117
+ return fail(`${stage.name} did not pass`, lines.join('\n'));
96
118
  }
97
119
  return { pass: true, exit: 0, ms: Date.now() - started, tail: lines.join('\n') };
98
120
  }
@@ -1 +1 @@
1
- {"version":3,"file":"review.js","sourceRoot":"","sources":["../../../src/core/checks/review.ts"],"names":[],"mappings":"A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UAAU,EAAE,EAAE,OAAO,CAAC,CAAC;QAC3G,OAAO,IAAI,CAAC,GAAG,KAAK,CAAC,IAAI,eAAe,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;IAC9D,CAAC;IACD,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,EAAE,EAAE,EAAE,IAAI,CAAC,GAAG,EAAE,GAAG,OAAO,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC;AACnF,CAAC"}
@@ -0,0 +1,51 @@
1
+ import fs from 'node:fs';
2
+ import path from 'node:path';
3
+ import { usage } from '../errors.js';
4
+ /** Files a design pack reads: the markup, the styles, the components, the vector art. */
5
+ const SOURCE_EXT = new Set(['.html', '.htm', '.css', '.js', '.jsx', '.ts', '.tsx', '.vue', '.svelte', '.svg']);
6
+ function walk(dir, out) {
7
+ for (const name of fs.readdirSync(dir).sort()) {
8
+ if (name === 'node_modules' || name.startsWith('.'))
9
+ continue;
10
+ const full = path.join(dir, name);
11
+ if (fs.statSync(full).isDirectory())
12
+ walk(full, out);
13
+ else if (SOURCE_EXT.has(path.extname(name).toLowerCase()))
14
+ out.push(full);
15
+ }
16
+ }
17
+ export function numberLines(text) {
18
+ const lines = text.replace(/\n$/, '').split('\n');
19
+ const width = String(lines.length).length;
20
+ return lines.map((line, i) => `${String(i + 1).padStart(width)}| ${line}`).join('\n');
21
+ }
22
+ /**
23
+ * The artifact as the reviewers see it: one file, or every source file under a directory, each
24
+ * numbered line by line so a finding can name `file:line`. The cap is the reviewer's context.
25
+ */
26
+ export function collectSource(root, target, maxChars) {
27
+ const full = path.resolve(root, target);
28
+ if (!fs.existsSync(full))
29
+ throw usage(`no such path: ${target}`);
30
+ const files = [];
31
+ if (fs.statSync(full).isDirectory())
32
+ walk(full, files);
33
+ else
34
+ files.push(full);
35
+ if (files.length === 0)
36
+ throw usage(`no source files under ${target}`);
37
+ const blocks = [];
38
+ let chars = 0;
39
+ const listed = [];
40
+ for (const file of files) {
41
+ const rel = path.relative(root, file);
42
+ const body = numberLines(fs.readFileSync(file, 'utf-8'));
43
+ chars += body.length;
44
+ if (chars > maxChars)
45
+ break;
46
+ listed.push(rel);
47
+ blocks.push(`<file path="${rel}">\n${body}\n</file>`);
48
+ }
49
+ return { files: listed, text: blocks.join('\n\n') };
50
+ }
51
+ //# sourceMappingURL=source.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"source.js","sourceRoot":"","sources":["../../../src/core/checks/source.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAErC,yFAAyF;AACzF,MAAM,UAAU,GAAG,IAAI,GAAG,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,CAAC,CAAC,CAAC;AAE/G,SAAS,IAAI,CAAC,GAAW,EAAE,GAAa;IACtC,KAAK,MAAM,IAAI,IAAI,EAAE,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC;QAC9C,IAAI,IAAI,KAAK,cAAc,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC;YAAE,SAAS;QAC9D,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC;QAClC,IAAI,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,WAAW,EAAE;YAAE,IAAI,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;aAChD,IAAI,UAAU,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,WAAW,EAAE,CAAC;YAAE,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,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C,QAAQ,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;QACtC,MAAM,IAAI,GAAG,WAAW,CAAC,EAAE,CAAC,YAAY,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC;QACzD,KAAK,IAAI,IAAI,CAAC,MAAM,CAAC;QACrB,IAAI,KAAK,GAAG,QAAQ;YAAE,MAAM;QAC5B,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QACjB,MAAM,CAAC,IAAI,CAAC,eAAe,GAAG,OAAO,IAAI,WAAW,CAAC,CAAC;IACxD,CAAC;IACD,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC;AACtD,CAAC"}
@@ -53,6 +53,9 @@ function checkReason(check) {
53
53
  case 'review': {
54
54
  if (!str(check['path']))
55
55
  return 'review check requires path (the manuscript)';
56
+ const pack = check['pack'];
57
+ if (pack !== undefined && (typeof pack !== 'string' || !/^[a-z0-9]+(-[a-z0-9]+)*$/.test(pack)))
58
+ return 'review pack must be a reviewers/ directory name';
56
59
  const lang = check['lang'];
57
60
  return lang === undefined || lang === 'ko' || lang === 'en' ? null : 'review lang must be ko or en';
58
61
  }
@@ -1 +1 @@
1
- {"version":3,"file":"scenarios.js","sourceRoot":"","sources":["../../src/core/scenarios.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,MAAM,CAAC;AAuExB,MAAM,WAAW,GAAwB,IAAI,GAAG,CAAC,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,CAAC,CAAC,CAAC;AACrG,MAAM,KAAK,GAAG,wBAAwB,CAAC;AAEvC,SAAS,QAAQ,CAAC,KAAc;IAC9B,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;AAC9E,CAAC;A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C,QAAkB;IACxC,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,KAAK,OAAO,CAAC;AACzC,CAAC"}
@@ -1,6 +1,7 @@
1
1
  import fs from 'node:fs';
2
2
  import os from 'node:os';
3
3
  import path from 'node:path';
4
+ import { packStages } from '../core/checks/packs.js';
4
5
  import { packageRoot } from '../core/paths.js';
5
6
  import { ensureDir, readJson, writeAtomic, writeJson } from '../core/store.js';
6
7
  import { pluginTree } from './tree.js';
@@ -45,14 +46,18 @@ function tomlString(text) {
45
46
  const escaped = text.replace(/\\/g, '\\\\').replace(new RegExp(FENCE, 'g'), '\\"\\"\\"');
46
47
  return [FENCE, escaped, FENCE].join('\n');
47
48
  }
48
- /** Codex reads custom agents as TOML (name · description · developer_instructions); one per reviewer prompt. */
49
- export function codexAgentToml(lang, stage) {
50
- const file = path.join(packageRoot(), 'reviewers', lang, `${stage}.md`);
51
- if (!fs.existsSync(file))
49
+ /** Codex reads custom agents as TOML (name · description · developer_instructions); one per reviewer stage. */
50
+ export function codexAgentToml(pack, stage) {
51
+ if (!fs.existsSync(stage.file))
52
52
  return null;
53
- const body = fs.readFileSync(file, 'utf-8').trim();
54
- const role = stage === 'copy-editor' ? 'first-pass copy editor' : 'second-pass chief editor';
55
- return `# Generated by vibe from reviewers/${lang}/${stage}.md — the ${lang} ${role} of the antislop-${lang} pack.\nname = "${lang}-${stage}"\ndescription = "antislop-${lang} ${role}: judges a submitted manuscript and returns only PASS or a REJECT list; never rewrites."\ndeveloper_instructions = ${tomlString(body)}\n`;
53
+ const body = fs.readFileSync(stage.file, 'utf-8').trim();
54
+ const role = `stage ${stage.order} ${stage.name.replace(/-/g, ' ')}`;
55
+ const name = agentName(pack, stage);
56
+ return `# Generated by vibe from reviewers/${pack}/${stage.order}-${stage.name}.md — the ${role} of the antislop-${pack} pack.\nname = "${name}"\ndescription = "antislop-${pack} ${role}: judges the submitted artifact and returns only PASS or a REJECT list; never rewrites."\ndeveloper_instructions = ${tomlString(body)}\n`;
57
+ }
58
+ /** The agent name a client sees: the text packs keep `ko-copy-editor`, other packs read `design-art-director`. */
59
+ export function agentName(pack, stage) {
60
+ return `${pack}-${stage.name}`;
56
61
  }
57
62
  function packageVersion() {
58
63
  return readJson(path.join(packageRoot(), 'package.json'))?.version ?? '0.0.0';
@@ -73,14 +78,15 @@ export function assemblePlugin(tree) {
73
78
  fs.cpSync(from, path.join(tree, 'skills', name), { recursive: true });
74
79
  written.push(`skills/${name}`);
75
80
  }
76
- for (const pack of languagePacks()) {
77
- const lang = pack.replace('antislop-', '');
78
- for (const stage of ['copy-editor', 'chief-editor']) {
79
- const toml = codexAgentToml(lang, stage);
81
+ for (const skill of languagePacks()) {
82
+ const pack = skill.replace('antislop-', '');
83
+ for (const stage of packStages(pack)) {
84
+ const toml = codexAgentToml(pack, stage);
80
85
  if (!toml)
81
86
  continue;
82
- writeAtomic(path.join(tree, 'agents', `${lang}-${stage}.toml`), toml);
83
- written.push(`agents/${lang}-${stage}.toml`);
87
+ const name = `${agentName(pack, stage)}.toml`;
88
+ writeAtomic(path.join(tree, 'agents', name), toml);
89
+ written.push(`agents/${name}`);
84
90
  }
85
91
  }
86
92
  writeAtomic(path.join(tree, 'hooks', 'codex-hooks.json'), generated['hooks/codex-hooks.json']);