@magnusekdahl/parallix 1.0.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/CHANGELOG.md +140 -0
- package/LICENSE +661 -0
- package/README.md +196 -0
- package/config/agents.json +25 -0
- package/config/agents.local.json.template +8 -0
- package/config/state-map.json +4 -0
- package/config/state-map.json.template +31 -0
- package/config/workflow.config.schema.json +98 -0
- package/data/.gitkeep +0 -0
- package/docs/adr/0031-ai-agent-instruction-boundary-and-command-floor.md +114 -0
- package/docs/adr/0032-mission-refinement-state-and-usage-budget-signals.md +135 -0
- package/docs/adr/0034-module-and-skill-invocation-model.md +202 -0
- package/docs/adr/0036-mission-sizing-and-dependency-wave-heuristics.md +79 -0
- package/docs/adr/0037-ai-workflow-coordination-architecture.md +162 -0
- package/docs/adr/0041-integration-pipeline-gates.md +165 -0
- package/docs/adr/0042-workflow-cli-color-rendering-approach.md +106 -0
- package/docs/adr/0043-git-target-resolution-strategy.md +185 -0
- package/docs/adr/0044-workflow-distribution-model.md +277 -0
- package/docs/adr/0045-parallax-branch-model.md +182 -0
- package/docs/adr/0046-npm-publish-process-and-security.md +138 -0
- package/docs/adr/index.md +20 -0
- package/docs/agents.md +212 -0
- package/docs/authority-reference.md +298 -0
- package/docs/forgejo-setup.md +31 -0
- package/docs/migration/extraction.md +61 -0
- package/docs/migration/task-classification.md +36 -0
- package/docs/operator-setup.md +76 -0
- package/docs/readme-rewrite-benchmark.md +188 -0
- package/docs/use-cases.md +105 -0
- package/examples/README.md +62 -0
- package/examples/run-enterprise-tarball-workflow-smoke.sh +257 -0
- package/examples/run-verify-env-smoke.sh +40 -0
- package/index.js +250 -0
- package/lib/README.md +13 -0
- package/lib/agents/agents.js +867 -0
- package/lib/agents/claude-telemetry.js +233 -0
- package/lib/agents/claude.js +139 -0
- package/lib/agents/codex-telemetry.js +202 -0
- package/lib/agents/codex.js +219 -0
- package/lib/agents/limit-hit.js +252 -0
- package/lib/agents/mistral-telemetry.js +44 -0
- package/lib/agents/mistral.js +68 -0
- package/lib/agents/opencode-export.js +110 -0
- package/lib/agents/opencode-telemetry.js +356 -0
- package/lib/agents/opencode.js +218 -0
- package/lib/agents/stage-telemetry.js +37 -0
- package/lib/commands/active.js +625 -0
- package/lib/commands/checkpoint.js +76 -0
- package/lib/commands/config.js +39 -0
- package/lib/commands/coverage-gate.js +358 -0
- package/lib/commands/diff.js +119 -0
- package/lib/commands/draft.js +854 -0
- package/lib/commands/handoff.js +501 -0
- package/lib/commands/integrate.js +1528 -0
- package/lib/commands/mission-start.js +246 -0
- package/lib/commands/rebase.js +597 -0
- package/lib/commands/repair-handoff.js +227 -0
- package/lib/commands/resolve-conflict.js +109 -0
- package/lib/commands/review.js +13 -0
- package/lib/commands/setup-review.js +13 -0
- package/lib/commands/setup.js +3 -0
- package/lib/commands/stats-backfill.js +395 -0
- package/lib/commands/stats.js +1601 -0
- package/lib/commands/status.js +183 -0
- package/lib/commands/verify.js +1 -0
- package/lib/core/fmt.js +202 -0
- package/lib/core/git.js +73 -0
- package/lib/core/gitignore.js +110 -0
- package/lib/core/mission-utils.js +1017 -0
- package/lib/core/persistent-data-migration.js +201 -0
- package/lib/core/product-config.js +508 -0
- package/lib/core/runtime-matrix.js +82 -0
- package/lib/core/spawn-tee.js +173 -0
- package/lib/core/state-map.js +89 -0
- package/lib/core/storage.js +165 -0
- package/lib/core/verification.js +149 -0
- package/lib/index.js +77 -0
- package/lib/review/rebase.js +163 -0
- package/lib/review/review-adapter.js +135 -0
- package/lib/review/review-artifacts.js +619 -0
- package/lib/review/review-commands.js +1375 -0
- package/lib/review/review-events.js +1007 -0
- package/lib/review/review-loop.js +1004 -0
- package/lib/review/review-polling.js +141 -0
- package/lib/review/review-prompts.js +212 -0
- package/lib/review/review-state.js +280 -0
- package/lib/review/review.js +96 -0
- package/lib/tools/backlog.js +680 -0
- package/lib/tools/forgejo.js +1585 -0
- package/lib/tools/gatekeeper.js +106 -0
- package/lib/tools/sessions.js +74 -0
- package/lib/tools/setup-review.js +1053 -0
- package/package.json +56 -0
- package/prompts/act-on-review-verbose.md +20 -0
- package/prompts/act-on-review.md +22 -0
- package/prompts/draft.md +20 -0
- package/prompts/execute.md +24 -0
- package/prompts/portfolio.md +30 -0
- package/prompts/review-verbose.md +20 -0
- package/prompts/review.md +17 -0
- package/px.js +236 -0
- package/templates/AGENTS-snippet.md +14 -0
- package/templates/AGENTS.md.template +34 -0
- package/templates/CLAUDE.md.template +27 -0
- package/templates/CODEX.md.template +38 -0
- package/templates/MISTRAL.md.template +24 -0
- package/templates/claude-commands/act-on-review.md +3 -0
- package/templates/claude-commands/area-review.md +3 -0
- package/templates/claude-commands/draft.md +6 -0
- package/templates/claude-commands/execute.md +6 -0
- package/templates/claude-commands/integrate.md +4 -0
- package/templates/claude-commands/portfolio.md +5 -0
- package/templates/claude-commands/review.md +4 -0
- package/templates/codex/config.toml +6 -0
- package/templates/mission-scaffold.md +39 -0
- package/templates/vibe/skills/act-on-review/SKILL.md +16 -0
- package/templates/vibe/skills/area-review/SKILL.md +16 -0
- package/templates/vibe/skills/draft/SKILL.md +16 -0
- package/templates/vibe/skills/execute/SKILL.md +16 -0
- package/templates/vibe/skills/integrate/SKILL.md +16 -0
- package/templates/vibe/skills/portfolio/SKILL.md +21 -0
- package/templates/vibe/skills/review/SKILL.md +16 -0
- package/tools/setup-forgejo-docker.sh +84 -0
|
@@ -0,0 +1,298 @@
|
|
|
1
|
+
# Parallix Authority Reference
|
|
2
|
+
|
|
3
|
+
Consolidated parallix workflow authority for the parallix AI mission lifecycle. The executable authority is the `parallix/` code (in this repository, the root `index.js`/`px.js` and `lib/`); this file is its canonical markdown companion.
|
|
4
|
+
|
|
5
|
+
> This document holds the internal operator and authority detail that previously lived in `README.md`. It was moved here during the task-1336 README rewrite so the landing page stays focused while none of the operational detail is lost. The public-facing overview is in [`README.md`](../README.md).
|
|
6
|
+
|
|
7
|
+
Conflict resolution: `AGENTS.md` wins on hard rules and verification entrypoints; locked `MISSION.md` wins on mission-specific scope and stop rules; runtime code wins over this file.
|
|
8
|
+
|
|
9
|
+
## 1. Workflow Modes
|
|
10
|
+
|
|
11
|
+
Mission flow: `backlog → draft → ready → active → review → approved → done`. Blocking review findings loop `review → active → review` on the same branch and PR. One machine, one branch (`mission/<slug>`), one worktree (`../<project>-<slug>`), one implementer. Primary checkout stays on the primary branch (`main` or `master`, detected at runtime) for human integration only.
|
|
12
|
+
|
|
13
|
+
`AGENTS.md` and the mode's agent-prompt are always in scope. `execute`, `review`, `act-on-review`, and `integrate` also always include locked `MISSION.md` and relevant source files. Expand beyond baseline only on a clear trigger (checkpoint transition, restricted-area entry, failed verification, blocked evidence, review feedback, or material mission-shape change); state what was loaded, why triggered, and why baseline was insufficient.
|
|
14
|
+
|
|
15
|
+
## Entrypoints
|
|
16
|
+
|
|
17
|
+
- `index.js` is the dispatcher; run it directly as `node index.js <command>`.
|
|
18
|
+
- `px.js` is the `px` binary wrapper and shell-init helper.
|
|
19
|
+
|
|
20
|
+
## Config Boundary
|
|
21
|
+
|
|
22
|
+
- `config/` is tool-owned defaults and launcher policy.
|
|
23
|
+
- The target repository's `config/` directory is repo state, not parallix code.
|
|
24
|
+
- Operator-local overlays live in `.local.json` and `.example` files; they are machine-specific and must not be conflated with repo config.
|
|
25
|
+
|
|
26
|
+
| Mode | Description | Mode-specific context |
|
|
27
|
+
|---|---|---|
|
|
28
|
+
| `portfolio` | Brainstorm and filter candidate missions | REALITY_PROBE.md, docs/index.md, docs/adr/index.md, Backlog state, active branches/worktrees, strategic framework |
|
|
29
|
+
| `draft` | Build one mission spec in detail | REALITY_PROBE.md, selected mission candidate, relevant ADRs/mission history |
|
|
30
|
+
| `execute` | Implement steps for a locked mission | current `git status` |
|
|
31
|
+
| `review` | Code quality review | `git diff <primary-branch>..HEAD` |
|
|
32
|
+
| `act-on-review` | Resolve live review findings on the current mission branch | live PR comments |
|
|
33
|
+
| `area-review` | Review one repo area outside a mission execution flow | REALITY_PROBE.md, focused area source files |
|
|
34
|
+
| `integrate` | Land a reviewed mission and complete cleanup | integration checkout state |
|
|
35
|
+
|
|
36
|
+
## 2. Authority Stack
|
|
37
|
+
|
|
38
|
+
| Layer | Owns | Must not do |
|
|
39
|
+
|---|---|---|
|
|
40
|
+
| `AGENTS.md` | Hard rules, restricted actions, verification entrypoints, autonomy boundaries | Re-specify mission-specific scope or phase procedures |
|
|
41
|
+
| `docs/authority-reference.md` | Workflow modes, lifecycle, context packets, authority model, validation model | Override runtime code or mission-specific scope |
|
|
42
|
+
| `missions/<slug>/MISSION.md` | Mission contract, scoped checkpoints, risks, gates, success criteria, stop rules | Override repo-wide hard rules |
|
|
43
|
+
| `docs/agent-prompts/*.md` | Mode-specific procedures and entry/exit obligations | Re-teach the full workflow or become a second policy layer |
|
|
44
|
+
| `parallix/` code | Executable workflow behavior | Depend on markdown duplication for correctness |
|
|
45
|
+
|
|
46
|
+
## 3. Agent Selection
|
|
47
|
+
|
|
48
|
+
Four families: `codex`, `claude`, `mistral`, `qwen`. Step eligibility is in `config/agents.json`. Launchers are resolved from `PATH` by bare executable name.
|
|
49
|
+
|
|
50
|
+
`WORKFLOW_AGENT=<name>` overrides random selection only when that agent is eligible and unblocked. The effective blocklist is operator-owned at `<PARALLIX_HOME>/agents.local.json`; on first use parallix non-destructively migrates the legacy runtime-config, repo-root, and main-worktree files in that precedence order. Per-agent values: `true` (permanent block), `{ "until": "YYYY-MM-DD HH" }` (timed), `{ "blocked": false }` (unblock).
|
|
51
|
+
|
|
52
|
+
Usage-limit failures: harness writes a timed block to the local blocklist and retries with the next eligible unblocked agent. All exhausted → fail clearly.
|
|
53
|
+
|
|
54
|
+
## 4. Validation Model
|
|
55
|
+
|
|
56
|
+
Validation is layered. One prompt declaring work complete is never sufficient.
|
|
57
|
+
|
|
58
|
+
### 4.1 Primary gate runner
|
|
59
|
+
|
|
60
|
+
The primary gate is **configured per repo**, not hardcoded. Declare it under
|
|
61
|
+
`adapters.verification` in `workflow.config.json`:
|
|
62
|
+
|
|
63
|
+
```json
|
|
64
|
+
{
|
|
65
|
+
"adapters": {
|
|
66
|
+
"verification": { "command": "./scripts/verify-local.sh {{area}}", "defaultArea": "docs" }
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
- **`command`** — the shell command the workflow runs as the primary gate. The `{{area}}` token
|
|
72
|
+
is substituted with the mission's detected area before the command runs. A command with no
|
|
73
|
+
`{{area}}` token runs verbatim for every area.
|
|
74
|
+
- **`defaultArea`** — the area used when none can be detected from the mission (defaults to `docs`).
|
|
75
|
+
- **No-op default:** when `adapters.verification` is absent, verification is a no-op pass — the
|
|
76
|
+
workflow does not invent a gate for repos that have not declared one.
|
|
77
|
+
|
|
78
|
+
The area is detected from the gate-runner invocation written in `MISSION.md` (the `Gates` lines).
|
|
79
|
+
Detection recognizes any verification script referenced as a `./` or `../`-prefixed path
|
|
80
|
+
(e.g. `./scripts/ci.sh <area>`, `../tools/gate.sh <area>`), so it is not tied to the
|
|
81
|
+
`./scripts/verify-local.sh` name. The relative-path prefix is required, so a bare filename in
|
|
82
|
+
prose is not mistaken for a gate.
|
|
83
|
+
|
|
84
|
+
Default is `./scripts/verify-local.sh {{area}}` .
|
|
85
|
+
Repos **without** `verify-local.sh` declare their own command, for example:
|
|
86
|
+
|
|
87
|
+
```json
|
|
88
|
+
// Make target per area: make verify-docs, make verify-server, ...
|
|
89
|
+
{ "adapters": { "verification": { "command": "make verify-{{area}}", "defaultArea": "docs" } } }
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
```json
|
|
93
|
+
// npm script forwarding the area as an argument
|
|
94
|
+
{ "adapters": { "verification": { "command": "npm run verify -- {{area}}", "defaultArea": "docs" } } }
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
The detected area maps from the changed surface as follows (this table reflects visualBoard's
|
|
98
|
+
areas; the area names a repo uses are whatever its configured `command` accepts):
|
|
99
|
+
|
|
100
|
+
| Changed surface | Gate |
|
|
101
|
+
|---|---|
|
|
102
|
+
| `docs/`, `*.md` only | `docs` |
|
|
103
|
+
| `parallix/` or mixed parallix code | `workflow` or `all` |
|
|
104
|
+
| `web-client/` | `web` |
|
|
105
|
+
| `server/` | `server` |
|
|
106
|
+
| `auth-server/` | `auth` |
|
|
107
|
+
| `android/`, `wearos/` | `android` |
|
|
108
|
+
| `kubernetes/` | `k8s` |
|
|
109
|
+
| Multiple functional areas | `all` |
|
|
110
|
+
|
|
111
|
+
### 4.2 Mission-specific gates
|
|
112
|
+
|
|
113
|
+
Each locked mission may add gates (staging validation, manual QA, ADR creation, C2 review). These add to the baseline; they do not replace it.
|
|
114
|
+
|
|
115
|
+
### 4.3 Review gate
|
|
116
|
+
|
|
117
|
+
External review by a different agent is mandatory before integration. Valid review: surface exists; reviewer inspects `<primary-branch>..HEAD`; findings cite file references; zero-finding reviews for non-trivial missions include explicit searched-and-found-none evidence.
|
|
118
|
+
|
|
119
|
+
### 4.4 Integration gate
|
|
120
|
+
|
|
121
|
+
Complete when: mission reviewed, landing from the correct integration checkout, Backlog state updated, mission branch and worktree cleanup done.
|
|
122
|
+
|
|
123
|
+
#### 4.4.1 Integration-time pipeline gates (ADR 0041)
|
|
124
|
+
|
|
125
|
+
`px integrate` runs integration-time gates before the squash-merge lands. These gates are configured via a repo-side config file and invoked per changed top-level area.
|
|
126
|
+
|
|
127
|
+
- **Config location:** `config/integration-pipelines.json`
|
|
128
|
+
- **Schema:** `{"gates": {"<area>": {"command": "<shell-command>", "order": <number>, "run_last": <boolean>}}}`
|
|
129
|
+
- **Supported areas:** `server`, `auth-server`, `web-client`, `web-e2e`
|
|
130
|
+
- **Ordering:** Gates are executed in ascending `order` value; `run_last: true` ensures the gate runs after all others (regardless of order value)
|
|
131
|
+
- **Change detection:** Gates are only invoked for areas with changed files in the mission branch vs the primary branch
|
|
132
|
+
- **Opt-out:** `px integrate <slug> --no-integration-gates` skips all integration gates
|
|
133
|
+
- **Dry-run:** `px integrate <slug> --dry-run` prints the resolved gate plan without executing
|
|
134
|
+
|
|
135
|
+
Example config:
|
|
136
|
+
```json
|
|
137
|
+
{
|
|
138
|
+
"gates": {
|
|
139
|
+
"server": {"command": "./server/updateStaging.sh", "order": 1, "run_last": false},
|
|
140
|
+
"auth-server": {"command": "./auth-server/updateStaging.sh", "order": 2, "run_last": false},
|
|
141
|
+
"web-client": {"command": "SKIP_E2E=1 ./web-client/updateStaging.sh", "order": 3, "run_last": false},
|
|
142
|
+
"web-e2e": {"command": "./web-client/scripts/run-playwright-stage.sh", "order": 4, "run_last": true}
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
If the config file is missing or empty, `px integrate` logs `integration-gates: no config present, skipping` and proceeds without error.
|
|
148
|
+
|
|
149
|
+
## 5. Checkpoint Model
|
|
150
|
+
|
|
151
|
+
Each completed checkpoint must produce: (1) checkpoint doc under the configured mission base dir for the repo (`missions/<slug>/` in this repo), (2) non-generic `Next action:`, (3) passing relevant gate, (4) commit on `mission/<slug>`. Checkpoint docs make resume and handoff deterministic.
|
|
152
|
+
|
|
153
|
+
## 6. State Map and Command Aliases
|
|
154
|
+
|
|
155
|
+
### Virtual vs. actual state names
|
|
156
|
+
|
|
157
|
+
The workflow uses virtual state names (`backlog | ready | active | review | approved | done`). Each project's `config/state-map.json` maps virtual names to the actual backlog.md state names used by the board:
|
|
158
|
+
|
|
159
|
+
```json
|
|
160
|
+
{ "ready": "refined", "approved": "ready-for-integration" }
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
Rules:
|
|
164
|
+
- When a virtual state has a non-null mapping, the corresponding backlog.md write happens with the actual name.
|
|
165
|
+
- When a virtual state maps to `null` or is absent from the map, the workflow step advances but makes no backlog.md write (useful for sparse boards with fewer states).
|
|
166
|
+
- States that match in both worlds (e.g. `active`, `review`, `done`) need not appear in the map.
|
|
167
|
+
|
|
168
|
+
### Command aliases
|
|
169
|
+
|
|
170
|
+
Command aliases are derived automatically from `state-map.json` — no second config file to maintain. The derivation rules are:
|
|
171
|
+
|
|
172
|
+
- `ready` and its actual backlog.md name (if any) → `draft`
|
|
173
|
+
- `approved` and its actual backlog.md name (if any) → `integrate`
|
|
174
|
+
- `done` → `integrate` (always)
|
|
175
|
+
|
|
176
|
+
With the default state-map above, the effective alias table is:
|
|
177
|
+
|
|
178
|
+
| alias | canonical |
|
|
179
|
+
|-------|-----------|
|
|
180
|
+
| `approved` | `integrate` |
|
|
181
|
+
| `done` | `integrate` |
|
|
182
|
+
| `ready` | `draft` |
|
|
183
|
+
| `ready-for-integration` | `integrate` |
|
|
184
|
+
| `refined` | `draft` |
|
|
185
|
+
|
|
186
|
+
When `px <alias>` is invoked, the CLI logs `[INFO] Resolving alias <alias> → <canonical>` and delegates to the canonical command.
|
|
187
|
+
|
|
188
|
+
View the current alias table: `px aliases`
|
|
189
|
+
|
|
190
|
+
## 7. Stats Preview
|
|
191
|
+
|
|
192
|
+
Use `px stats` before integration when you want to validate the weekly tables from committed workflow data, or add `--from` and `--to` to inspect one larger inclusive date range.
|
|
193
|
+
|
|
194
|
+
**Classification:** `<PARALLIX_HOME>/stats.csv` is **parallix-owned cross-repository agent telemetry** — one statistic about how agent families perform across every repo a single parallix runtime drives. It is operator-owned and independent of both the installed package and selected consuming repo, so one runtime working in several repositories accumulates one shared statistic rather than a split per-repo file. The five-column schema (`date,mission,classification,implementer,pr_fix_rounds`) carries no repository identity by design.
|
|
195
|
+
|
|
196
|
+
## Persistent operator data
|
|
197
|
+
|
|
198
|
+
`PARALLIX_HOME` overrides the whole persistent-data root. Without it, parallix
|
|
199
|
+
uses `~/.local/state/parallix` on Linux,
|
|
200
|
+
`~/Library/Application Support/parallix` on macOS, and
|
|
201
|
+
`%LOCALAPPDATA%\parallix` on Windows. If the platform-specific base cannot be
|
|
202
|
+
resolved, it falls back to `~/.parallix`.
|
|
203
|
+
|
|
204
|
+
The root contains `stats.csv` and `agents.local.json`. Missing directories and
|
|
205
|
+
files are created on first write; read-only paths tolerate absence. The first
|
|
206
|
+
default access migrates the repo-root legacy `stats.csv` and the three legacy
|
|
207
|
+
blocklist locations without deleting them. Statistics rows are
|
|
208
|
+
deduplicated by all five columns. Blocklist precedence remains
|
|
209
|
+
runtime-config, repo-root, main-worktree; conflicts are logged with both values
|
|
210
|
+
and their sources. Malformed legacy blocklists are reported and skipped, while
|
|
211
|
+
a malformed effective file is a hard failure and is never overwritten.
|
|
212
|
+
|
|
213
|
+
Back up `PARALLIX_HOME` separately. It is not target-repository state and is not
|
|
214
|
+
inside, restored by, or removed with the globally installed npm package.
|
|
215
|
+
|
|
216
|
+
- Default preview: `px stats`
|
|
217
|
+
- Freeze the reporting window for reproducible checks: `px stats --today 2026-05-18`
|
|
218
|
+
- Preview one inclusive workflow-owned range: `px stats --from 2026-05-01 --to 2026-05-31`
|
|
219
|
+
- Be explicit about the source file: `px stats --csv-file stats.csv --today 2026-05-18`
|
|
220
|
+
- Write the output to a file for inspection or sharing: `px stats --from 2026-05-01 --to 2026-05-31 --output /tmp/workflow-stats.txt`
|
|
221
|
+
- Break one mission down by phase: `px stats task-1285` (or `px stats --mission task-1285`)
|
|
222
|
+
- Show command help and examples: `px stats --help`
|
|
223
|
+
|
|
224
|
+
Behavior:
|
|
225
|
+
- Workflow-owned stats datasets (`stats.csv` schema) print the current-week and previous-week mission tables plus the two agent-performance tables.
|
|
226
|
+
- With `--from YYYY-MM-DD --to YYYY-MM-DD`, workflow-owned stats datasets instead print one mission table and one agent-performance table for rows whose `date` is within the inclusive range.
|
|
227
|
+
- With a mission slug (`px stats task-1285`) or `--mission <slug>`, the command prints one mission broken down by phase — `draft`, `execute` (stored as the `active` stage), and `review` are always shown, plus any `follow-up`/extra recorded stages, with per-phase provider, model, implementer, token, tool-call, and duration columns and a totals row. The output is a pure function of the stored rows, so re-running it does not change the data.
|
|
228
|
+
|
|
229
|
+
Telemetry capture contract (task-1285):
|
|
230
|
+
- Stage rows are keyed by `(mission, stage)`; `draft.js`, `active.js`, and the review loop each record their phase via `recordStageStats`/`recordActiveStats`/`recordReviewStats`.
|
|
231
|
+
- Structured sources: Codex (`codex-telemetry.js`, rollout JSONL) and Claude (`claude-telemetry.js`, stdout SSE) populate real token/usage fields.
|
|
232
|
+
- `opencode` (local Qwen) exposes no structured usage source, so `opencode-telemetry.js` records honest zeros with provider/model falling back to the agent family — never fabricated numbers.
|
|
233
|
+
- `vibe`/`mistral` telemetry is **blocked** in this environment; `mistral-telemetry.js` records honest zeros and the verification is tracked as follow-up task-1288.
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
237
|
+
## Public distribution (canonical packaging and install)
|
|
238
|
+
|
|
239
|
+
This is the one authoritative public distribution story for parallix. It is the
|
|
240
|
+
near-term supported model; the architectural decision behind it is recorded in
|
|
241
|
+
ADR 0044 (`docs/adr/0044-workflow-distribution-model.md`).
|
|
242
|
+
|
|
243
|
+
**Supported acquisition/install path.** parallix is a Node.js toolkit (package
|
|
244
|
+
name `@magnusekdahl/parallix`) that coordinates AI-assisted software missions through
|
|
245
|
+
the lifecycle `backlog → draft → active → review → approved → done`. The
|
|
246
|
+
supported artifact is a **local npm tarball built from this repository** — not a
|
|
247
|
+
public registry install and not a container image. The package name is scoped so
|
|
248
|
+
the unscoped `px` / `parallix` npm names are not relied upon. The shortest
|
|
249
|
+
supported path is:
|
|
250
|
+
|
|
251
|
+
```sh
|
|
252
|
+
npm pack
|
|
253
|
+
```
|
|
254
|
+
|
|
255
|
+
```sh
|
|
256
|
+
npm install -g ./magnus-parallix-*.tgz
|
|
257
|
+
```
|
|
258
|
+
|
|
259
|
+
```sh
|
|
260
|
+
npm install -g --prefix "$HOME/.local" ./magnus-parallix-*.tgz
|
|
261
|
+
```
|
|
262
|
+
|
|
263
|
+
Use the user-writable prefix when you do not have `sudo` access. If your shell
|
|
264
|
+
does not already place `$HOME/.local/bin` on `PATH`, add it once.
|
|
265
|
+
|
|
266
|
+
`CHANGELOG.md` is the versioning authority. Until the first public release,
|
|
267
|
+
PATCH bumps are the release discipline: bump before each `px integrate`, then
|
|
268
|
+
reinstall from the new tarball after the integrate succeeds. That policy is
|
|
269
|
+
documented release practice, not automatic CLI behavior.
|
|
270
|
+
|
|
271
|
+
**How the operator invokes `px`.** After the global install, `px <command>` is
|
|
272
|
+
the installed runner; use `px shell-init` in your shell rc if you want mission
|
|
273
|
+
transitions to `cd` your terminal into the next worktree. `px --version`
|
|
274
|
+
identifies the executing `px.js` path so an accidental PATH collision with an
|
|
275
|
+
unrelated `px` is visible.
|
|
276
|
+
|
|
277
|
+
**What stays source-compatible for local development.** Running directly from a
|
|
278
|
+
checkout is unchanged: `node index.js <command>` runs from source, requires no
|
|
279
|
+
install step, and never changes the caller's shell directory. The tarball install and the source run are the same
|
|
280
|
+
code; the tarball only adds a versioned, globally linked `px`.
|
|
281
|
+
|
|
282
|
+
**What is not yet supported.** The following are explicitly out of the near-term
|
|
283
|
+
model and are not claimed to work today: publishing to the public npm registry
|
|
284
|
+
(or any other registry), Homebrew, Docker images, standalone single-file
|
|
285
|
+
binaries, and CI/release automation or npm provenance (Sigstore). ECDSA registry
|
|
286
|
+
signatures are automatic on the public npm registry and require no publisher action.
|
|
287
|
+
Distribution stays a manual `npm pack` + global install until a follow-up decision
|
|
288
|
+
changes that.
|
|
289
|
+
|
|
290
|
+
The old enterprise walkthrough has been removed. The supported packaging and
|
|
291
|
+
install path is the three shell lines above.
|
|
292
|
+
|
|
293
|
+
## References
|
|
294
|
+
|
|
295
|
+
- ADR 0044 — Workflow Distribution Model for parallix:
|
|
296
|
+
`docs/adr/0044-workflow-distribution-model.md` (candidate consumption modes,
|
|
297
|
+
Interface Boundary, Enterprise Safety Model).
|
|
298
|
+
- Phase 1–4 extraction evidence: `docs/missions/2026/task-1231` … `task-1234`.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Forgejo Setup
|
|
2
|
+
|
|
3
|
+
Standalone workflow installs need three review-surface pieces before `active`, `review`, `handoff`, `rebase --push`, or `integrate` can talk to Forgejo:
|
|
4
|
+
|
|
5
|
+
1. a reachable Forgejo base URL
|
|
6
|
+
2. a review repository matching `adapters.review.repo`
|
|
7
|
+
3. token files for the agent users that will push branches or post reviews
|
|
8
|
+
|
|
9
|
+
## Happy Path
|
|
10
|
+
|
|
11
|
+
1. Export the workflow into the repo.
|
|
12
|
+
2. If you need a local Forgejo instance, run `parallix/tools/setup-forgejo-docker.sh` and start it with Docker Compose.
|
|
13
|
+
3. Run `px setup`.
|
|
14
|
+
4. Choose whether to keep the standard Backlog.md-style layout:
|
|
15
|
+
- task storage in `backlog/`
|
|
16
|
+
- missions in `missions/`
|
|
17
|
+
- `mission/*` branches on `main`
|
|
18
|
+
- worktrees in `../<repo>-<slug>`
|
|
19
|
+
- verification via `npm test`
|
|
20
|
+
5. If you keep Forgejo bootstrap enabled, enter the Forgejo password for the login that can create the review repo.
|
|
21
|
+
6. Enter passwords for the agent users you want available on this machine, or leave them blank to skip token creation for that user.
|
|
22
|
+
|
|
23
|
+
`setup` writes `workflow.config.json`, writes token files into `.forgejo-local/tokens/`, grants the listed agent users write access to the configured review repo, creates or updates the git `review` remote, and runs `verify-env` so the install is validated before you start missions.
|
|
24
|
+
|
|
25
|
+
## Notes
|
|
26
|
+
|
|
27
|
+
- The configured review repo is created only if it does not already exist.
|
|
28
|
+
- Existing review repos are updated to grant the listed agent users `write` access, so implementer identities can see and update their own PRs.
|
|
29
|
+
- You can leave an agent password blank to skip that token on this machine.
|
|
30
|
+
- Re-running `px setup` lets you change config and rotate the local token files.
|
|
31
|
+
- `px setup-review` still exists as a narrower Forgejo-only repair path if you only need to refresh token or remote wiring.
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# parallix standalone extraction record (task-1302)
|
|
2
|
+
|
|
3
|
+
This repository was extracted from the WrGroceries monorepo's embedded `parallix/`
|
|
4
|
+
directory as the standalone-repo "extraction proof" required by ADR 0044.
|
|
5
|
+
|
|
6
|
+
## Method — history-preserving
|
|
7
|
+
|
|
8
|
+
The extraction used **`git subtree split -P parallix`** (history-preserving), not a
|
|
9
|
+
flat copy. `git filter-repo` was not available on the workstation; `git subtree split`
|
|
10
|
+
is built into git 2.53 and reproduces every commit that touched `parallix/` with the
|
|
11
|
+
subtree promoted to the repository root. The standalone repo was then created with
|
|
12
|
+
`git clone -b <split-branch> --single-branch`, the `origin` remote removed, and the
|
|
13
|
+
default branch renamed to `main`.
|
|
14
|
+
|
|
15
|
+
Result: the full commit history for the parallix tree survives (`git log` shows the
|
|
16
|
+
`mission/task-1299`, `mission/task-1301`, `mission/task-1310`, etc. commits that
|
|
17
|
+
shaped the tool), and the working tree is byte-identical to the monorepo's
|
|
18
|
+
`parallix/` tree (verified with `diff -rq` across `lib/`, `test/`, `config/`,
|
|
19
|
+
`prompts/`, `templates/`, `examples/`, and the root files).
|
|
20
|
+
|
|
21
|
+
## Verbatim guarantee and the test-harness exception
|
|
22
|
+
|
|
23
|
+
No parallix **source** (`lib/`, `index.js`, `px.js`, command interfaces) was rewritten.
|
|
24
|
+
The only post-extraction edits are to **test-harness coupling** that assumed parallix
|
|
25
|
+
lived as a subdirectory of a host monorepo. These were unavoidable to satisfy the
|
|
26
|
+
mission's `npm test` zero-failures gate in a standalone checkout, and every one of
|
|
27
|
+
them is backward-compatible — re-running the edited test files inside the monorepo
|
|
28
|
+
still executes all tests with zero skips and zero failures.
|
|
29
|
+
|
|
30
|
+
### 1. Monorepo-script tests → auto-skip when the script is absent
|
|
31
|
+
|
|
32
|
+
`test/install.test.js` and the `scripts/verify-local.sh`-invoking tests in
|
|
33
|
+
`test/integration-pipelines.test.js` exercise WrGroceries monorepo scripts
|
|
34
|
+
(`scripts/install-workflow.sh`, `scripts/verify-local.sh`) that live **outside** the
|
|
35
|
+
parallix tree and are intentionally **not** carried into the standalone repo
|
|
36
|
+
(MISSION scope item 9 — those scripts stay in WrGroceries and are repointed to the
|
|
37
|
+
global `px` runner). Each such test now carries a `{ skip: ... }` guard keyed on the
|
|
38
|
+
script's presence: it runs unchanged in the monorepo and skips (with a documented
|
|
39
|
+
reason) in the standalone repo. Tests affected: 13 in `install.test.js`, 8 in
|
|
40
|
+
`integration-pipelines.test.js`.
|
|
41
|
+
|
|
42
|
+
### 2. Monorepo `.gitignore` assertion → skip outside the monorepo host
|
|
43
|
+
|
|
44
|
+
`test/agents.test.js` has one test asserting the monorepo `.gitignore` semantics for
|
|
45
|
+
the embedded `workflow/config/` tree, computed against `../..` (the monorepo root). In
|
|
46
|
+
the standalone repo `../..` is the parent code directory, not a git repo, so the
|
|
47
|
+
assertion does not apply. It now skips when no `.git` exists at `../..`. (1 test.)
|
|
48
|
+
|
|
49
|
+
### 3. Rebase tests → made hermetic to the Forgejo-review config
|
|
50
|
+
|
|
51
|
+
The standalone repo declares `workflow.config.json` with `adapters.review.provider:
|
|
52
|
+
"forgejo"` (required for self-hosting parity). That turns
|
|
53
|
+
`isForgejoReviewEnabled(process.cwd())` ON at the repo root. The rebase tests in
|
|
54
|
+
`test/rebase.test.js`, `test/rebase_diagnostics.test.js`, and
|
|
55
|
+
`test/rebase_hardening.test.js` were written assuming Forgejo-off (in the monorepo
|
|
56
|
+
they ran with `cwd = parallix/`, which had no local config), and they do not mock the
|
|
57
|
+
Forgejo fetch path. They now inject `isForgejoReviewEnabledFn: () => false` — the same
|
|
58
|
+
injection idiom two sibling tests in the file already use with `() => true` — so they
|
|
59
|
+
are hermetic to ambient config. (11 rebase calls across 3 files.)
|
|
60
|
+
|
|
61
|
+
Net: 22 tests skip in the standalone repo (host-coupled to the monorepo); 0 fail.
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# Task Classification
|
|
2
|
+
|
|
3
|
+
| Task | Decision | Reason |
|
|
4
|
+
| --- | --- | --- |
|
|
5
|
+
| `TASK-1059` | move | workflow/parallix subject from title and mission context |
|
|
6
|
+
| `TASK-1088` | move | workflow follow-up or workflow-operations subject from title |
|
|
7
|
+
| `TASK-1115` | move | workflow/parallix subject from title and mission context |
|
|
8
|
+
| `TASK-1133` | move | workflow/parallix subject from title and mission context |
|
|
9
|
+
| `TASK-1243` | move | workflow follow-up or workflow-operations subject from title |
|
|
10
|
+
| `TASK-1267` | move | workflow follow-up or workflow-operations subject from title |
|
|
11
|
+
| `TASK-1268` | move | workflow follow-up or workflow-operations subject from title |
|
|
12
|
+
| `TASK-1269` | move | workflow follow-up or workflow-operations subject from title |
|
|
13
|
+
| `TASK-1270` | move | workflow/parallix subject from title and mission context |
|
|
14
|
+
| `TASK-1273` | move | workflow/parallix subject from title and mission context |
|
|
15
|
+
| `TASK-1275` | move | workflow/parallix subject from title and mission context |
|
|
16
|
+
| `TASK-1277` | stay | model-capacity tuning note for GPT family selection; not the parallix workflow tool itself |
|
|
17
|
+
| `TASK-1281` | move | workflow/parallix subject from title and mission context |
|
|
18
|
+
| `TASK-1287` | stay | qwen-9B benchmark note; a model-evaluation task, not a parallix workflow change |
|
|
19
|
+
| `TASK-1288` | move | workflow/parallix subject from title and mission context |
|
|
20
|
+
| `TASK-1290` | move | workflow/parallix subject from title and mission context |
|
|
21
|
+
| `TASK-1294` | move | workflow/parallix subject from title and mission context |
|
|
22
|
+
| `TASK-1297` | move | workflow/parallix subject from title and mission context |
|
|
23
|
+
| `TASK-1298` | move | workflow/parallix subject from title and mission context |
|
|
24
|
+
| `TASK-1300` | move | workflow/parallix subject from title and mission context |
|
|
25
|
+
| `TASK-1302` | move | workflow/parallix subject from title and mission context |
|
|
26
|
+
| `TASK-1303` | move | workflow/parallix subject from title and mission context |
|
|
27
|
+
| `TASK-1304` | move | workflow/parallix subject from title and mission context |
|
|
28
|
+
| `TASK-1305` | move | workflow/parallix subject from title and mission context |
|
|
29
|
+
| `TASK-1306` | move | workflow/parallix subject from title and mission context |
|
|
30
|
+
| `TASK-1307` | move | workflow/parallix subject from title and mission context |
|
|
31
|
+
| `TASK-1308` | move | workflow/parallix subject from title and mission context |
|
|
32
|
+
| `TASK-1309` | move | workflow/parallix subject from title and mission context |
|
|
33
|
+
| `TASK-1311` | move | workflow/parallix subject from title and mission context |
|
|
34
|
+
| `TASK-1312` | move | workflow/parallix subject from title and mission context |
|
|
35
|
+
| `TASK-1313` | move | workflow/parallix subject from title and mission context |
|
|
36
|
+
| `TASK-1314` | move | workflow/parallix subject from title and mission context |
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# Operator Setup — Graphify Skill Installation
|
|
2
|
+
|
|
3
|
+
## Prerequisites
|
|
4
|
+
|
|
5
|
+
The `graphify` CLI is a pinned pip package. Bootstrap it on your workstation:
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
pip3 install --user graphifyy==0.8.30
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
This installs the `graphify` entry-point script to `~/.local/bin/graphify` (on Linux/macOS). Verify:
|
|
12
|
+
|
|
13
|
+
```sh
|
|
14
|
+
~/.local/bin/graphify --version
|
|
15
|
+
# → graphify 0.8.30
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
The CLI resolves in this order: `$GRAPHIFY_BIN` → `graphify` on `$PATH` → `~/.local/bin/graphify`.
|
|
19
|
+
|
|
20
|
+
## One-Time Platform Install
|
|
21
|
+
|
|
22
|
+
Run the installer once per agent family. It copies a platform-specific skill (and, for Claude, a `CLAUDE.md` directive) into the agent's config directory. **Do not use `--project` scope** — it writes artifacts into the current working directory.
|
|
23
|
+
|
|
24
|
+
| Family | Command | Target Directory |
|
|
25
|
+
|--------|---------|-----------------|
|
|
26
|
+
| claude | `graphify install --platform claude` | `~/.claude/skills/graphify/` + `CLAUDE.md` directive |
|
|
27
|
+
| codex | `graphify install --platform codex` | `~/.agents/skills/graphify/` |
|
|
28
|
+
| qwen/opencode | `graphify install --platform opencode` | `~/.config/opencode/skills/graphify/` |
|
|
29
|
+
|
|
30
|
+
Each command produces a `SKILL.md` file in the target directory. After running all three, verify:
|
|
31
|
+
|
|
32
|
+
```sh
|
|
33
|
+
test -f ~/.claude/skills/graphify/SKILL.md && echo OK # claude
|
|
34
|
+
test -f ~/.agents/skills/graphify/SKILL.md && echo OK # codex
|
|
35
|
+
test -f ~/.config/opencode/skills/graphify/SKILL.md && echo OK # opencode
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
The install is idempotent — re-running any command overwrites the target with the latest skill file.
|
|
39
|
+
|
|
40
|
+
### Environment variable overrides
|
|
41
|
+
|
|
42
|
+
- **Claude**: Honors `$CLAUDE_CONFIG_DIR` to change the base config path.
|
|
43
|
+
- **Opencode**: No env-var overrides; always writes to `~/.config/opencode/skills/graphify/`.
|
|
44
|
+
|
|
45
|
+
## Codex Isolated HOME — Copy-Seed
|
|
46
|
+
|
|
47
|
+
Codex runs with a worktree-local HOME (`<worktree>/.workflow/codex-home`). The global `~/.agents/skills/graphify/` is invisible to codex unless copied into that isolated HOME.
|
|
48
|
+
|
|
49
|
+
The parallix harness handles this automatically. In `ensureCodexHome` (`lib/agents/codex.js`), a plain `fs.cpSync` copies the global skill into the worktree-local HOME **before** the `HOME` environment variable is overridden for the codex child process. This mirrors the existing `auth.json` copy pattern:
|
|
50
|
+
|
|
51
|
+
```
|
|
52
|
+
Source (operator's real HOME):
|
|
53
|
+
~/.agents/skills/graphify/SKILL.md
|
|
54
|
+
|
|
55
|
+
Target (worktree-local codex HOME):
|
|
56
|
+
<worktree>/.workflow/codex-home/.agents/skills/graphify/SKILL.md
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
The copy is:
|
|
60
|
+
- **Idempotent**: re-running `ensureCodexHome` leaves the target unchanged.
|
|
61
|
+
- **Clean skip**: if no global skill is installed (`fs.existsSync` returns false), the copy step is silently skipped — config is still written, but no skill directory is created.
|
|
62
|
+
- **Not a per-launch install**: this is a filesystem copy of an already-installed skill. No subprocess is spawned.
|
|
63
|
+
|
|
64
|
+
## Mistral Exclusion
|
|
65
|
+
|
|
66
|
+
Graphify ships no `mistral` or `vibe` platform. The `graphify install --platform mistral` command does not exist and will fail. The parallix harness skips mistral without error during any Graphify-related operations.
|
|
67
|
+
|
|
68
|
+
## Summary Checklist
|
|
69
|
+
|
|
70
|
+
After setup, an operator should be able to:
|
|
71
|
+
|
|
72
|
+
1. Run `graphify install --platform claude` → skill at `~/.claude/skills/graphify/`
|
|
73
|
+
2. Run `graphify install --platform codex` → skill at `~/.agents/skills/graphify/`
|
|
74
|
+
3. Run `graphify install --platform opencode` → skill at `~/.config/opencode/skills/graphify/`
|
|
75
|
+
4. Launch any mission — codex will receive the skill via the copy-seed in `ensureCodexHome`
|
|
76
|
+
5. mistral agents will not receive a Graphify skill (by design)
|