@softure-ai/skills 0.8.0 → 0.9.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/README.md CHANGED
@@ -42,8 +42,11 @@ installer injects only that mode's section into the rules block:
42
42
  The autonomous standard (roles of the coordinator and its threads, results always sent to the main
43
43
  chat, condensed messages with the decision first, the coordinator's go on green PRs, threads closed only
44
44
  after the merge, the report table `ID | What it does | Stage | Link` with the `X of N` counter, issues
45
- for SOFTURE package bugs) lives in the rules block, so every session, cloud ones included, reads it from
46
- `AGENTS.md` without being told. Tune it with `autonomy` (WORKFLOW §2). Switch modes only on the
45
+ for SOFTURE package bugs and for gaps in these skills) lives in the rules block, so every session that
46
+ runs in a checkout, cloud ones included, reads it from `AGENTS.md` without being told. A hosted
47
+ project's coordinator (for example a claude.ai project's main chat) is started outside the checkout:
48
+ paste the one-paragraph pointer from WORKFLOW §8.5 (`softure-init` prints it) into the project
49
+ instructions, and it starts the run by itself. Tune it with `autonomy` (WORKFLOW §2). Switch modes only on the
47
50
  owner's word: change `mode`, re-run the installer, commit both.
48
51
 
49
52
  Per-project choices go into `context/workflow.json` → `install` and are applied on every install,
@@ -96,6 +99,11 @@ npm version patch # or minor / major: bumps package.json and creates ta
96
99
  git push --follow-tags
97
100
  ```
98
101
 
102
+ Where a tag cannot be pushed (a cloud agent session's git proxy lets only branches through), bump the
103
+ version without a tag (`npm version minor --no-git-tag-version`), commit and push it to `master`, then
104
+ run the **auto-release** workflow (Actions → auto-release → Run workflow, on `master`). It creates
105
+ `vX.Y.Z` on `master`'s head and starts `release.yml` on that tag, the same path as a pushed tag.
106
+
99
107
  The `v*.*.*` tag runs `.github/workflows/release.yml`, which:
100
108
  1. validates and test-installs the package, and checks that the tag matches `package.json`;
101
109
  2. publishes `@softure-ai/skills` to **npmjs.com** through trusted publishing (OIDC, provenance,
package/WORKFLOW.md CHANGED
@@ -406,9 +406,11 @@ the owner: `softure-init` asks for it, and a missing key means `"manual"`.
406
406
  The behavioural rules of each mode live in the project's `AGENTS.md` (the managed block from
407
407
  `rules/AGENTS.md`). The installer injects **only the section of the active mode**
408
408
  (`## Operating mode: manual` or `## Operating mode: autonomous`), whatever `install.rules` says, so a
409
- manual project never carries autonomous instructions and every session, cloud ones included, reads
410
- its mode's rules without being told. That block is the source of truth for §8.3 and §8.4; this
411
- section defines the contract skills rely on.
409
+ manual project never carries autonomous instructions and every session that runs in a checkout,
410
+ cloud ones included, reads its mode's rules without being told. A hosted project's coordinator,
411
+ started by the harness outside the checkout, gets one pointer to them in the project instructions
412
+ (§8.5). That block is the source of truth for §8.3 and §8.4; this section defines the contract
413
+ skills rely on.
412
414
 
413
415
  **Switching mode** (only on the owner's explicit word): set `mode` in `context/workflow.json`, re-run
414
416
  the installer (`npx softure-skills`, or `npm install`) so the `AGENTS.md` block follows, and commit both
@@ -451,11 +453,52 @@ leaves the working tree without the owner's word, approvals never carry over to
451
453
  ### 8.4 Autonomous mode
452
454
 
453
455
  Defined in `rules/AGENTS.md` → `## Operating mode: autonomous`: the standing consent, the
454
- coordinator and its sessions, the merge queue, reports, issues as the work source, releases, and
455
- the stop rules. `autonomy` in `workflow.json` (§2) tunes it per project. Project-specific standing
456
+ coordinator and its sessions, the start of a run, the merge queue, reports, issues as the work
457
+ source, filing gaps in SOFTURE packages, releases, and the stop rules. `autonomy` in `workflow.json` (§2) tunes it per project. Project-specific standing
456
458
  orders (a repo that is read-only, an extra label, a test that must not run per push) belong in the
457
459
  project's own `AGENTS.md`, outside the managed block, not in a session's memory.
458
460
 
461
+ ### 8.5 Hosted projects
462
+
463
+ A hosted multi-session project (for example a claude.ai project) has a **main-chat session** that
464
+ the owner talks to and that starts **thread sessions**. The main-chat session is the coordinator;
465
+ each thread carries one change. They differ from a local run in three ways: the coordinator has no
466
+ shell over the threads, each thread is a cloud session in its own container on a branch the harness
467
+ assigns, and the coordinator is started by the harness, not inside a checkout.
468
+
469
+ **Bootstrap.** The coordinator never loads the repository's `AGENTS.md` by itself, so the project
470
+ instructions carry one pointer to it. `softure-init` prints it for autonomous projects; paste it
471
+ into the hosted project's instructions:
472
+
473
+ ```text
474
+ This project runs the SOFTURE workflow from <owner>/<repo>. Before anything else, read its
475
+ AGENTS.md (the managed SOFTURE block) and context/workflow.json from the main branch. You are the
476
+ coordinator described there: follow "Operating mode: autonomous", starting with "Start of a run".
477
+ ```
478
+
479
+ Nothing else needs saying: the rules, the roadmap and the owner's standing orders live in the
480
+ repository (§8.4). Thread briefs still name "follow AGENTS.md → Operating mode: autonomous"; a thread
481
+ runs in a checkout and reads the block itself.
482
+
483
+ **Mapping.** Each step of `softure-worktree-manager` and `softure-worktree` in a hosted project:
484
+
485
+ | step | local | hosted project |
486
+ | --- | --- | --- |
487
+ | launch (M3) | `wm-launch.sh` | start a thread session with the standard brief (item ID, change-id, outcome, base, owned files, waits for, merge path, report-to, "follow AGENTS.md → Operating mode: autonomous") |
488
+ | in-flight state (M0.1) | `wm-resume.sh` | roadmap rows on `origin/<main>` (with `cloudState: "branch"` they show only at merge, so also memory), the harness's thread list, open pull requests |
489
+ | watch (M4) | `wm-watch.sh` Monitor | thread messages and the report routine; no polling |
490
+ | READY / merged report | `SendMessage` | cross-session message to the coordinator's session, never a reply in the thread |
491
+ | go | a signal in the conversation | coordinator-to-thread message |
492
+ | branch | `<change-id>` in a worktree | the branch the harness assigns; the change-id lives in `context/changes/` and `change.md` → `branch:` |
493
+ | Phase A | `wt-open.sh` + worktree | in the thread's own checkout, no `git worktree add` (`softure-worktree` → Cloud session) |
494
+ | reports / heartbeat | `CronCreate` | a recurring routine; without a scheduling tool, a setup thread creates it from `softure-worktree-manager/references/report-routine.md` |
495
+ | close | `claude stop` + worktree removal | resolve the thread after its pull request is merged |
496
+
497
+ `worktree.cloudState` (§2) and `install.gitignore: false` (for containers that never run
498
+ `npm install`) apply to the threads as to any cloud session. Forge access in a hosted session is often
499
+ scoped to the project's own repository: attach a repository the run needs (for example SOFTURE/SKILLS
500
+ to file a gap) before deciding it is out of reach.
501
+
459
502
  ## 9. Commits
460
503
 
461
504
  - Implementation: `<type>(<change-id>): <phase title> (p<N>)`. Type is `feat`, `fix`, `refactor`,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@softure-ai/skills",
3
- "version": "0.8.0",
3
+ "version": "0.9.0",
4
4
  "description": "SOFTURE agent skills: a spec-driven delivery workflow (shape → prd → roadmap → plan → implement → review) plus parallel worktree orchestration",
5
5
  "license": "MIT",
6
6
  "repository": {
package/rules/AGENTS.md CHANGED
@@ -84,7 +84,9 @@ resolving conflicts, closing the issues the work solves, filing issues, starting
84
84
  sessions (threads), giving threads their go, and running report routines. It lives in the repository,
85
85
  so every session reads it here itself; it is not consent relayed by another session. A brief points
86
86
  to this section instead of quoting chat messages. **Only a production deploy or release waits for the
87
- owner's word** (see Releases). Nothing in this section needs to be told to a fresh session again.
87
+ owner's word** (see Releases). Nothing in this section needs to be told to a fresh session again;
88
+ a hosted project's coordinator that does not run inside a checkout gets one pointer to it in the
89
+ project instructions (WORKFLOW §8.5).
88
90
 
89
91
  **Decide, don't ask.** Take the recommended option and record it under `## Decisions (auto)` in the
90
92
  artifact. Small product decisions are yours: the owner trusts the recommendation and corrects it
@@ -102,6 +104,17 @@ irreversible action nobody asked for, a secret or access only the owner has, sco
102
104
  AGENTS.md → Operating mode: autonomous"). It carries one change and talks only to the coordinator.
103
105
  - A session started by the owner directly, with no coordinator, does both jobs itself.
104
106
 
107
+ **Start of a run.** A coordinator that wakes with no run in flight (a fresh or cleared session, or a
108
+ hosted project's main-chat session on its first message) starts the run itself, without waiting for
109
+ the owner's "go":
110
+ 1. read `context/workflow.json` and the roadmap (or the issue queue) on the main branch; outside a
111
+ checkout, read them, and this block, from the repository first;
112
+ 2. adopt what is already in flight: roadmap rows `in_progress` or `ready_to_merge`, the harness's open
113
+ threads, open pull requests (`softure-worktree-manager` M0.1); give the go to every READY thread;
114
+ 3. start a thread for every ready, parallel-safe item;
115
+ 4. create the report routine and post the first roadmap report.
116
+ Only a "stop" or "pause" from the owner, recorded in memory, holds it back.
117
+
105
118
  **Messages to the owner and between sessions:**
106
119
  - In `chatLanguage` (default: `language`), whatever language the artifacts use.
107
120
  - **Condensed: the decision first, then what was done.** First line: `Decision: <what the owner has to
@@ -165,7 +178,11 @@ irreversible action nobody asked for, a secret or access only the owner has, sco
165
178
  60 (60 → `0 * * * *`, 120 → `0 */2 * * *`; `wt_config.py --report-cron` prints it); a value below 60
166
179
  runs hourly. **One recurring routine** drives the reports: the coordinator creates it when work
167
180
  starts and deletes it when nothing runs, or on the owner's "stop" or "pause". Never a chain of
168
- one-off wake-ups. After a pause (usage limit) name the reports that were skipped. A report produced in a thread of its own (a scheduled routine) is pasted into the main
181
+ one-off wake-ups. **A coordinator without a scheduling tool** (a hosted project's main-chat session)
182
+ starts one short setup thread whose only job is to create that routine from the template
183
+ `softure-worktree-manager/references/report-routine.md` and send its id back; the setup thread is
184
+ then closed. The coordinator records the id in memory and, at the end of the run or on "stop" or
185
+ "pause", has a thread delete the routine by that id. Missing tools never mean skipped reports. After a pause (usage limit) name the reports that were skipped. A report produced in a thread of its own (a scheduled routine) is pasted into the main
169
186
  chat and that thread is closed at once.
170
187
  - Shape, the same in every project, nothing else:
171
188
  1. title: `Roadmap report <roadmap name>, <HH:MM>`;
@@ -203,10 +220,16 @@ irreversible action nobody asked for, a secret or access only the owner has, sco
203
220
 
204
221
  Nothing moved since the last report: one line (`15:00, no change: 47 of 50; SA-35 implement 2/3`).
205
222
 
206
- **Bugs and gaps in SOFTURE packages.** A well-founded, non-duplicate bug or gap in an `@softure-ai/*`
207
- package (or in this project's own scope) is filed right away as an issue in the repository that owns
208
- the package (e.g. SOFTURE/AI), without asking. The work goes on around it; the item that needs the
209
- fix is `blocked (<repo>#<N>)`.
223
+ **Bugs and gaps in SOFTURE packages.** A well-founded, non-duplicate bug or gap is filed right away as
224
+ an issue, without asking, in the repository that owns it:
225
+ - `@softure-ai/skills` (the skills, this managed block, `WORKFLOW.md`) → **SOFTURE/SKILLS**;
226
+ - every other `@softure-ai/*` package → **SOFTURE/AI**;
227
+ - this project's own scope → this project's repository.
228
+
229
+ Search the target for a duplicate first. When the harness scopes forge access to this project, attach
230
+ the owning repository first (read and issues) and only then decide you cannot file; if it is still out
231
+ of reach, put the issue text in the main chat for the owner. The work goes on around it; the item that
232
+ needs the fix is `blocked (<repo>#<N>)`.
210
233
 
211
234
  **Issues as the work source** (`autonomy.source: "issues"`, no roadmap):
212
235
  - The coordinator lists open issues (through a thread when it has no forge access). Not well-founded:
@@ -237,8 +260,11 @@ push, merge or publish this section covers, cite this section and `mode` once; i
237
260
  ask the owner for a word in that session and keep the other work going.
238
261
 
239
262
  **Memory** holds only project state (queue, IDs, counters, the owner's specific orders and decisions).
240
- The rules above are not memory material: when the owner corrects how the process runs, the fix belongs
241
- in these skills, so say so in the main chat.
263
+ The rules above are not memory material. **When the owner has to explain or correct how the process
264
+ runs** (a step that should have happened by itself, a rule that is missing or wrong), that is a gap in
265
+ these skills: the session that received it checks SOFTURE/SKILLS for a duplicate, files an issue right
266
+ away (neutral text, "an adopting app") and posts the link in the main chat. Memory keeps only the
267
+ project-specific order itself.
242
268
 
243
269
  ## Conventions
244
270
 
@@ -93,7 +93,9 @@ start any work: no change, PRD or roadmap is created here.
93
93
  detection must now produce no new writes.
94
94
  8. **Report** a status block, one line per artifact (`created`, `present` or `merged: <keys>`),
95
95
  then the unresolved values the owner should fill in, every inferred value with its reason,
96
- and the next step. Then stop: do not chain into other skills.
96
+ and the next step. With `mode: "autonomous"`, end it with the project-instructions snippet
97
+ for hosted projects (WORKFLOW §8.5), `<owner>/<repo>` filled in from `origin`, ready to paste.
98
+ Then stop: do not chain into other skills.
97
99
 
98
100
  ## `workflow.json`
99
101
 
@@ -150,6 +150,13 @@ branch, and the *other* sessions are other containers that see **only
150
150
  `origin`** — a stage written to a local `<main>` is invisible to them, so two
151
151
  cloud sessions could take the same item.
152
152
 
153
+ **A thread of a hosted project** (a coordinator in the project's main chat
154
+ starts one session per change; WORKFLOW §8.5) is such a cloud session: Phase A
155
+ runs in its own checkout on the branch the harness assigned (no `git worktree
156
+ add`), the change-id lives in `context/changes/`, the READY and merge reports
157
+ go to the coordinator's session by cross-session message, the go comes back
158
+ the same way, and the thread is resolved only after its pull request is merged.
159
+
153
160
  **`worktree.cloudState: "branch"`** changes points 1 and 6: the claim and every
154
161
  stage are committed **on the session branch only** (`wt-roadmap.py` does it by
155
162
  itself in that mode) and nothing goes to `origin/<main>` before the merge. Use
@@ -105,6 +105,24 @@ Read `mode` at M0 (`python3 <S>/wt_config.py mode`; WORKFLOW §8):
105
105
  the owner asks for one (`--status-every N`). Conflict resolution inside an
106
106
  approved merge stays this skill's job.
107
107
 
108
+ ### Hosted projects
109
+
110
+ In a hosted multi-session project (WORKFLOW §8.5) the coordinator is the
111
+ project's main-chat session: no shell over the workers, no `claude agents`, no
112
+ `Monitor`. The loop below stays; its tools map like this:
113
+
114
+ | step | here | hosted project |
115
+ | --- | --- | --- |
116
+ | M0.1 adopt | `wm-resume.sh` | roadmap rows on `origin/<main>`, the thread list, open pull requests |
117
+ | M3 launch | `wm-launch.sh` | start a thread with the standard brief (`AGENTS.md` → Coordinator duties) |
118
+ | M4 watch | `wm-watch.sh` | thread messages and the report routine |
119
+ | M4 status | `CronCreate` | a recurring routine; no scheduling tool → setup thread with `references/report-routine.md` |
120
+ | READY, go | `SendMessage` | cross-session messages, both ways |
121
+ | M5 cleanup | `claude stop` + worktree removal | the thread resolves itself after its pull request is merged |
122
+
123
+ A fresh main-chat session starts the run by itself (`AGENTS.md` → Start of a
124
+ run); it does not wait for this skill to be invoked.
125
+
108
126
  ## The coordinator does not fix — it commissions
109
127
 
110
128
  **Every code change goes to a worker.** A red test on `<main>`, a regression,
@@ -385,6 +403,14 @@ to a multiple of 60, because routines fire at most hourly: 60 → `0 * * * *`,
385
403
  the first launch and deleted at M7 or on the owner's "stop"/"pause"; reports
386
404
  never re-arm the next one. An explicit `--status-every` still wins.
387
405
 
406
+ **No scheduling tool in this session** (a hosted project's main-chat
407
+ session): start one setup thread with the brief in
408
+ `references/report-routine.md`; it creates the routine (bound to this session
409
+ when the harness allows, else a fresh session per firing), sends back its id
410
+ and is closed. Record the id in memory; at M7 or on "stop"/"pause" have a
411
+ thread delete the routine by that id. Never skip the reports, never chain
412
+ one-off wake-ups instead.
413
+
388
414
  `--status-every N` changes the period (build the minute list from an
389
415
  off-mark offset: N=20 → `7,27,47 * * * *`); `--status-every 0` skips it. Arm
390
416
  it **once** per run — M6 re-arms the Monitor, not the cron. Remember its id:
@@ -621,8 +647,9 @@ Everything else is decided and written into the report.
621
647
  before its worktree is removed.
622
648
  - **The run ends only when the roadmap is realised** (M7) — never after one
623
649
  item, never after one batch.
624
- - **The owner hears from the run on a clock** — a status cron is armed while
625
- anything is in flight (unless `--status-every 0`) and deleted at M7.
650
+ - **The owner hears from the run on a clock** — a status cron (or, without a
651
+ scheduling tool, the routine from `references/report-routine.md`) is armed
652
+ while anything is in flight (unless `--status-every 0`) and deleted at M7.
626
653
  - **No tag, no release, no deploy, ever** (while `release.owner` is true).
627
654
  **No push of `<main>`** — except the single push at M7 that the roadmap
628
655
  header orders; the full integration suite on `<main>` follows it (or the
@@ -0,0 +1,48 @@
1
+ # Report routine: template for coordinators without a scheduling tool
2
+
3
+ Used when the coordinator cannot create a recurring routine itself (a hosted project's main-chat
4
+ session; `rules/AGENTS.md` → Roadmap reports). The coordinator starts one short **setup thread**
5
+ with the brief below. Every project gets the same routine, so every project gets the same report.
6
+
7
+ ## Brief for the setup thread
8
+
9
+ ```text
10
+ Setup thread: create the roadmap report routine (SOFTURE workflow, autonomous mode).
11
+ Coordinator session: <coordinator session id>.
12
+ 1. Read the cron: `python3 .claude/skills/softure-worktree/scripts/wt_config.py --report-cron`
13
+ (or the same script under node_modules/@softure-ai/skills/skills/), and `timezone` from
14
+ context/workflow.json.
15
+ 2. Create ONE recurring routine named "Roadmap report <roadmap name>", with that cron in that
16
+ timezone and the routine prompt from softure-worktree-manager/references/report-routine.md,
17
+ "Routine prompt", with the placeholders filled in. Bind it, in this order of preference:
18
+ a) to the coordinator's session (the routine wakes the coordinator);
19
+ b) otherwise to a fresh session per firing.
20
+ Never bind it to this thread: this thread is closed next.
21
+ 3. Send the routine id and its first fire time to the coordinator's session, then close this
22
+ thread. Write no code, open no pull request.
23
+ ```
24
+
25
+ ## Routine prompt
26
+
27
+ Fill in `<roadmap name>`, `<coordinator session id>` and `<owner/repo>`.
28
+
29
+ ```text
30
+ Roadmap report for <roadmap name> (SOFTURE workflow, AGENTS.md → Operating mode: autonomous → Roadmap reports).
31
+ If several firings queued up while busy, do one.
32
+ - Running as the coordinator: post the roadmap report in the main chat in the standard shape
33
+ (title, "X of N on <main>", the four-column table of the items not done yet, Decision, times),
34
+ in chatLanguage, times in timezone. Then run the heartbeat: give the go to every READY thread,
35
+ nudge stalled ones, start every item a merge unblocked. Nothing moved: one line.
36
+ - Running in a session of its own: read <owner/repo> on the main branch (context/foundation/roadmap.md,
37
+ open pull requests and their checks), send the coordinator's session <coordinator session id> the
38
+ facts in one message ("Report due <HH:MM>: X of N on <main>; <ID> <stage> (PR #N, checks); ...")
39
+ and ask it to post the report and run its heartbeat. Then end this session. Change nothing in
40
+ the repository.
41
+ ```
42
+
43
+ ## Removing it
44
+
45
+ At the end of the run, or on the owner's "stop" or "pause", the coordinator asks a thread (the setup
46
+ thread's successor or any running thread) to delete the routine by its id, and clears the id from
47
+ memory once the thread confirms. A fresh coordinator finds the id in memory; without one, it asks a
48
+ thread to list the account's routines and delete the one named after the roadmap.