nikos 0.0.4 → 0.0.6

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.
@@ -2,7 +2,7 @@ import { appendFileSync, existsSync } from "node:fs";
2
2
  import { join } from "node:path";
3
3
  import { STORY_ID, findIntentDir, read } from "../lib/project.js";
4
4
  import { formatResult, validate } from "./validate.js";
5
- const CATEGORIES = ["product", "architecture", "design", "process"];
5
+ const CATEGORIES = ["product", "architecture", "design", "interface", "process"];
6
6
  /** Append a dated entry to decisions.md. Earlier entries are never touched. */
7
7
  export function decide(input, dir) {
8
8
  const title = input.title.trim();
@@ -39,7 +39,7 @@ export function runDecide(args) {
39
39
  return i >= 0 ? rest[i + 1] : undefined;
40
40
  };
41
41
  if (!title || title.startsWith("--")) {
42
- console.error('Usage: nikos decide "<title>" --why "<why>" [--story <id>] [--category product|architecture|design|process] [--supersedes "<title>"]');
42
+ console.error('Usage: nikos decide "<title>" --why "<why>" [--story <id>] [--category product|architecture|design|interface|process] [--supersedes "<title>"]');
43
43
  return 1;
44
44
  }
45
45
  const dir = opt("dir") ?? process.cwd();
package/docs/format.md CHANGED
@@ -199,7 +199,9 @@ Why this, and what we rejected.
199
199
 
200
200
  The heading is `date — title (story id)`; the story id is optional for
201
201
  project-wide decisions. Category is one of `product`, `architecture`,
202
- `design`, `process`.
202
+ `design`, `interface`, `process`. Use `interface` for a choice other stories
203
+ must keep to: a command's syntax, an output format, an API's shape. The
204
+ build-a-story playbook reads these before planning.
203
205
 
204
206
  ---
205
207
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nikos",
3
- "version": "0.0.4",
3
+ "version": "0.0.6",
4
4
  "description": "Spec-driven development for AI coding agents: story maps, Gherkin acceptance criteria and a done gate for Claude Code, Codex and Cursor",
5
5
  "license": "MIT",
6
6
  "author": "Niko Vijay",
@@ -38,8 +38,8 @@
38
38
  "vitest": "^2.1.9"
39
39
  },
40
40
  "dependencies": {
41
- "@cucumber/gherkin": "^30.0.4",
42
- "@cucumber/messages": "^26.0.1",
41
+ "@cucumber/gherkin": "^42.0.1",
42
+ "@cucumber/messages": "^34.2.1",
43
43
  "ajv": "^8.17.1",
44
44
  "yaml": "^2.6.1"
45
45
  },
@@ -31,9 +31,23 @@ Read the story's `.feature` file, `intent/constitution.md` and
31
31
  - **Accurate:** it agrees with the constitution (who it's for, the problem,
32
32
  the proof) and with every decision in `decisions.md`. Name the line it
33
33
  contradicts.
34
- - **Responsible:** where the story touches personal data, money, safety,
35
- outreach to real people or accessibility, a scenario or the description
36
- covers it. A story that touches none of these passes and says so.
34
+ - **Responsible:** for each area below that the story touches, every item
35
+ in its row is covered by a scenario (or, where the row says so, stated in
36
+ the description). Any missing item fails Responsible: name the item and give
37
+ the scenario to add. A story that touches none of these areas passes and
38
+ says so.
39
+
40
+ | Area | The story must cover |
41
+ | --- | --- |
42
+ | Money | A scenario for invalid amounts (zero, negative, more decimals than the currency has); a scenario for how amounts round; the currency, in the description or a scenario |
43
+ | Personal data | Who can see it, in the description or a scenario; a scenario for deleting it |
44
+ | Safety (health, physical harm, locks, children) | A scenario for what happens when it fails, and what the user sees then |
45
+ | Outreach to real people | A scenario for consent or opting out; nothing is sent without the person's sign-off |
46
+ | A screen people use | A scenario or description line saying it works by keyboard and with a screen reader |
47
+
48
+ For example, a story that charges a card but has no scenario for a zero or
49
+ negative amount reports:
50
+ `Responsible: fail. Money: no scenario for invalid amounts. Fix: add "AC3 — A zero or negative amount is refused".`
37
51
 
38
52
  ## 3. Fill small gaps, ask about big ones
39
53
 
@@ -38,7 +38,7 @@ add what the git history of `intent/` shows (`git log -p -- intent/`), marked
38
38
  clearly as history, not a recorded decision. Then offer to log one:
39
39
 
40
40
  ```
41
- nikos decide "<title>" --why "<why>" --category <product|architecture|design|process>
41
+ nikos decide "<title>" --why "<why>" --category <product|architecture|design|interface|process>
42
42
  ```
43
43
 
44
44
  Log it only once the person tells you the reason. Don't write a reason for
@@ -5,10 +5,10 @@ scenarios pass, not that you say so.
5
5
 
6
6
  1. Run `nikos next` to pick the story, or use the story id the person named.
7
7
  2. Check the story with the clear skill, and stop if any of the five checks fails.
8
- 3. Run `nikos plan new <story-id>` and write the approach into the plan file it creates.
9
- 4. Run `nikos state set <story-id> in_progress`.
8
+ 3. Run `nikos decisions interface`, then `nikos plan new <story-id>` and write the approach into the plan file it creates. Reuse every interface decision the story touches, and cite each in the step that uses it as `Reuses: <decision title> (intent/decisions.md:<lines>)`. If the story needs to change one, stop and ask.
9
+ 4. Run `nikos state set <story-id> in_progress --by <agent>`, where `<agent>` names your tool (`claude-code`, `codex`, `cursor`), never a person, so `state.yaml` shows who is building it.
10
10
  5. Implement the story, with a step definition for each step in its scenarios (see the verify skill).
11
11
  6. Run `nikos verify <story-id>`, then `nikos verify` to check every other story still passes, and keep the output.
12
- 7. Record each decision you made with `nikos decide "<title>" --story <story-id> --why "<why>"`.
12
+ 7. Record each decision you made with `nikos decide "<title>" --story <story-id> --why "<why>"`. Add `--category interface` for anything a later story must keep to: command syntax, output format, API shape.
13
13
  8. Run `nikos state set <story-id> done`. If it refuses, fix the failing scenarios and go back to step 6.
14
14
  9. Report every step with its evidence or its skip reason.
@@ -5,7 +5,7 @@ one that supersedes it.
5
5
 
6
6
  <!--
7
7
  ## YYYY-MM-DD — Decision title (STORY-ID)
8
- **Category:** product | architecture | design | process
8
+ **Category:** product | architecture | design | interface | process
9
9
  **Supersedes:** none
10
10
 
11
11
  Why this, and what we rejected.