@alterset/alterspec-client 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/prompts/_shared.md +25 -6
- package/assets/prompts/task-context.md +9 -6
- package/assets/prompts/task-done.md +5 -3
- package/assets/prompts/task-eta.md +14 -0
- package/assets/prompts/task-status.md +10 -3
- package/assets/skills/alterspec-task-eta/SKILL.md +11 -0
- package/assets/skills/alterspec-task-status/SKILL.md +1 -1
- package/dist/cli.js +535 -218
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
|
@@ -2,8 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
The CLI is `npx @alterset/alterspec-client`. Below it is written as `alterspec-client`; always run it as
|
|
4
4
|
`npx @alterset/alterspec-client ...` from the repository (or the task's worktree). The dispatcher's tools come from
|
|
5
|
-
the MCP server `dispatcher` that `.mcp.json` starts: `whoami`, `next_task`, `list_tasks`, `
|
|
6
|
-
`
|
|
5
|
+
the MCP server `dispatcher` that `.mcp.json` starts: `whoami`, `next_task`, `list_tasks`, `list_changes`, `task`,
|
|
6
|
+
`touch`, `set_eta`, `done`, `release`. Progress reaches the dispatcher through `alterspec-client progress`, never by
|
|
7
|
+
calling its tool yourself. Never call `force_release` or `mark_done`: they are an administrator's, in the
|
|
8
|
+
dispatcher's pages.
|
|
7
9
|
|
|
8
10
|
## What you work with
|
|
9
11
|
|
|
@@ -14,8 +16,12 @@ the MCP server `dispatcher` that `.mcp.json` starts: `whoami`, `next_task`, `lis
|
|
|
14
16
|
developer's clone of it. It says what the product does in business terms and names everything by ID; it never
|
|
15
17
|
says how to build it, which is this repository's business. Cite IDs when you refer to it. The clone is read-only:
|
|
16
18
|
never edit, commit or switch branches in it; `alterspec-client` pulls it.
|
|
17
|
-
- **The CLI does the deterministic work**: which commit to send, the task's brief, its branch and
|
|
18
|
-
commit that brought it in. Never work these out yourself, never pick a
|
|
19
|
+
- **The CLI does the deterministic work**: which commit to send, the task's brief and checklist, its branch and
|
|
20
|
+
worktree, the items its commits cover, the commit that brought it in. Never work these out yourself, never pick a
|
|
21
|
+
branch name.
|
|
22
|
+
- **Progress and ETA are the dispatcher's arithmetic.** Never compute a percentage or a date yourself, and never
|
|
23
|
+
guess one: say what the dispatcher answered. The developer's own date is theirs to set, with
|
|
24
|
+
`/alterspec-task-eta`.
|
|
19
25
|
|
|
20
26
|
## How every skill starts
|
|
21
27
|
|
|
@@ -43,5 +49,18 @@ the MCP server `dispatcher` that `.mcp.json` starts: `whoami`, `next_task`, `lis
|
|
|
43
49
|
## Commits of a task
|
|
44
50
|
|
|
45
51
|
Work on the task's branch, which `alterspec-client worktree <task>` makes (`--here` in this checkout). Every commit
|
|
46
|
-
of the task ends with
|
|
47
|
-
|
|
52
|
+
of the task ends with a trailer block, after a blank line:
|
|
53
|
+
|
|
54
|
+
```
|
|
55
|
+
Alterspec-Task: CHG-012/BE
|
|
56
|
+
Alterspec-Covers: CAP-CAT-001-AC-03, CAP-CAT-002
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
- `Alterspec-Task` always, the task exactly as the dispatcher wrote it.
|
|
60
|
+
- `Alterspec-Covers` only on the commit with which an item's tests pass, naming those items exactly as the task's
|
|
61
|
+
checklist writes them (`alterspec-client context <task>` lists them). Never an item whose tests don't pass yet,
|
|
62
|
+
never one the checklist lacks, never "all". An item named once stays covered; don't name it again. A commit that
|
|
63
|
+
covers nothing has no `Alterspec-Covers` line.
|
|
64
|
+
|
|
65
|
+
A hook reports the covered items to the dispatcher after each commit, by itself; when it asks, the developer runs
|
|
66
|
+
`alterspec-client progress`. The task is done when its work is in the track's main branch.
|
|
@@ -7,10 +7,11 @@ there are several, the one whose branch this checkout is on (`git branch --show-
|
|
|
7
7
|
when that doesn't settle it, ask which.
|
|
8
8
|
|
|
9
9
|
1. Start as `_shared.md` says (`whoami`, `export-head`).
|
|
10
|
-
2. Run `alterspec-client context <task>` and read the brief
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
2. Run `alterspec-client context <task>` and read the brief. It opens with the task's checklist: its items, what
|
|
11
|
+
each is and which the dispatcher holds covered already; that is the work, and its progress. Then why the change
|
|
12
|
+
was made, what changed, the delta of each of the task's objects (before and after) and where each is in the export
|
|
13
|
+
now; for the backend the acceptance criteria, rules, events and operations the capabilities name; for a UI track
|
|
14
|
+
the screens, their experience contracts, the mockup pages and the channel's design system.
|
|
14
15
|
3. Call `touch` with the task, then `task` with it. `followed_by` lists the later tasks on this track whose objects
|
|
15
16
|
overlap this one's; say them in one line, e.g. "CHG-015/BE, after yours, changes some of the same objects; it will
|
|
16
17
|
be its own task." Build what this change says, not what later ones do.
|
|
@@ -21,5 +22,7 @@ when that doesn't settle it, ask which.
|
|
|
21
22
|
the developer's. A mockup page is the agreed look and behaviour of a screen, a working example to follow, not code
|
|
22
23
|
to copy. When the spec and the code disagree, or the spec is silent, ask the developer; never fill a gap with an
|
|
23
24
|
invented business rule.
|
|
24
|
-
6.
|
|
25
|
-
|
|
25
|
+
6. Work through the checklist. For each item, make its tests pass, then commit with the trailers of `_shared.md`:
|
|
26
|
+
`Alterspec-Task: <task>` always, `Alterspec-Covers` with the items whose tests pass on that commit. The hook
|
|
27
|
+
reports them. When the work is merged into the main branch, the developer types `/alterspec-task-done <task>`;
|
|
28
|
+
never report it done yourself.
|
|
@@ -6,8 +6,10 @@ Arguments: `<CHG-NNN/TRACK>`, required. The developer typed this command: that i
|
|
|
6
6
|
Without a task, ask for it; never guess it.
|
|
7
7
|
|
|
8
8
|
1. Start as `_shared.md` says (`whoami`, `export-head`).
|
|
9
|
-
2. Run `alterspec-client
|
|
9
|
+
2. Run `alterspec-client progress <task>`, so the dispatcher has the last covered items. Say its lines as they are
|
|
10
|
+
(an item the task lacks is one of them); a failure here doesn't stop what follows.
|
|
11
|
+
3. Run `alterspec-client merged <task>`. It prints the commit on the track's main branch that brought the task in,
|
|
10
12
|
or fails when the work isn't there yet: then say so (merge the task's branch, or push the commits carrying the
|
|
11
13
|
trailer, first) and stop. Never report a task done whose work isn't on the main branch.
|
|
12
|
-
|
|
13
|
-
|
|
14
|
+
4. Call `done` with the task and that commit.
|
|
15
|
+
5. Say the result in one line. `NOT_IN_BRANCH`, `NOT_YOURS`, `NOT_IN_PROGRESS`: say the dispatcher's sentence.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# /alterspec-task-eta — set your own date for a task
|
|
2
|
+
|
|
3
|
+
Read `.alterspec-client/prompts/_shared.md` first and follow it.
|
|
4
|
+
|
|
5
|
+
Arguments: `<CHG-NNN/TRACK> <YYYY-MM-DD|clear> <reason>`. The developer typed this command: the date is their word,
|
|
6
|
+
as `done` and `release` are. Without a task or a date, ask for them; never guess either.
|
|
7
|
+
|
|
8
|
+
1. Start with `whoami` as `_shared.md` says. `export-head` is not needed.
|
|
9
|
+
2. The date is a day, `YYYY-MM-DD`, or `clear` to drop the developer's date so the dispatcher's computed ETA holds
|
|
10
|
+
again. Anything else: ask for a day in that form. Never turn words like "next Friday" into a date yourself; ask.
|
|
11
|
+
3. The reason is the developer's words after the date; it is logged with the date. Without one, ask once (one line).
|
|
12
|
+
4. Call `set_eta` with the task, the date (`null` for `clear`) and the reason.
|
|
13
|
+
5. Say the result in one line: the task's ETA now, the developer's date as theirs and the computed one beside it, or
|
|
14
|
+
the computed one alone after `clear`. `NOT_YOURS`, `NOT_IN_PROGRESS`: say the dispatcher's sentence.
|
|
@@ -9,6 +9,13 @@ Arguments: `[track]`, optional.
|
|
|
9
9
|
track when the developer named one; without one, keep the tracks `whoami` says the developer may take.
|
|
10
10
|
3. For the blocked tasks on those tracks, call `task` for at most the ten lowest levels to see what each waits for
|
|
11
11
|
(`after` with their statuses).
|
|
12
|
-
4.
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
4. Call `list_changes` with `status: "open"` for the progress and ETA of the open changes and of each level.
|
|
13
|
+
5. Answer in four short parts:
|
|
14
|
+
- **yours**: task, title, progress (`covered` of `of` items, the dispatcher's `percent`), ETA, since when, stale or
|
|
15
|
+
not. An ETA the developer set is theirs: show it as theirs, with the computed one beside it. An unknown ETA is
|
|
16
|
+
"unknown", never a guess. A task without items shows only its status.
|
|
17
|
+
- **available**: task, title, level, and how long it lasts once taken when the dispatcher says.
|
|
18
|
+
- **blocked**: task, waiting for which tasks.
|
|
19
|
+
- **changes**: per level, the open changes with their progress and ETA ("at least" when the dispatcher says so).
|
|
20
|
+
A stale task of the developer's: say it in one line and suggest `/alterspec-task-release` if they won't finish it.
|
|
21
|
+
Their own date for a task: `/alterspec-task-eta`.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: alterspec-task-eta
|
|
3
|
+
description: "Set your own date for a task in progress, or clear it. Only when the developer types it with the task, the date and the reason."
|
|
4
|
+
argument-hint: "<CHG-NNN/TRACK> <YYYY-MM-DD|clear> <reason>"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Read Bash(npx @alterset/alterspec-client *) mcp__dispatcher__*
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Read `.alterspec-client/prompts/task-eta.md` and follow those instructions exactly.
|
|
10
|
+
|
|
11
|
+
Arguments: $ARGUMENTS
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: alterspec-task-status
|
|
3
|
-
description: "Use when the developer asks where the work stands: \"what am I on?\", \"
|
|
3
|
+
description: "Use when the developer asks where the work stands: \"what am I on?\", \"how far along are we?\", \"when will CHG-012 be done?\". Their tasks with progress and ETA, the available ones on their tracks, what the blocked ones wait for, and each open change's progress."
|
|
4
4
|
argument-hint: "[track]"
|
|
5
5
|
allowed-tools: Read Glob Grep Bash(npx @alterset/alterspec-client *) mcp__dispatcher__*
|
|
6
6
|
---
|