@exaudeus/workrail 3.35.0 → 3.35.1

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.
@@ -4,7 +4,7 @@
4
4
  <meta charset="UTF-8" />
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
6
  <title>WorkRail Console</title>
7
- <script type="module" crossorigin src="/console/assets/index-B10Bn8qC.js"></script>
7
+ <script type="module" crossorigin src="/console/assets/index-D7jQyCSD.js"></script>
8
8
  <link rel="stylesheet" crossorigin href="/console/assets/index-8dh0Psu-.css">
9
9
  </head>
10
10
  <body>
@@ -445,12 +445,12 @@
445
445
  "sha256": "cf9d09641f1c31fffe6c7835b30bbbad52572befec1acab7fb9a0c188431af36",
446
446
  "bytes": 60355
447
447
  },
448
- "console-ui/assets/index-B10Bn8qC.js": {
449
- "sha256": "7f622b872ba39f5973c38b8fc93e9a5b00074dcdab4540ffbc7a3a78a560e55a",
450
- "bytes": 754653
448
+ "console-ui/assets/index-D7jQyCSD.js": {
449
+ "sha256": "f0692154276f354dbbdce868634b19caf01a3b5d2a2e033bb1ecd19d61889eb9",
450
+ "bytes": 754955
451
451
  },
452
452
  "console-ui/index.html": {
453
- "sha256": "c814df5d1fa998848e5c4ee61a1455c2a50bfcefb0af908d3f8fa02d311de32c",
453
+ "sha256": "83c7ee221c0d7e05b7e1728f795a289cd317dfe922a49c460ac66f1cebd4c097",
454
454
  "bytes": 417
455
455
  },
456
456
  "console/standalone-console.d.ts": {
@@ -4975,3 +4975,174 @@ Long-term (when mobile exists):
4975
4975
  ```
4976
4976
 
4977
4977
  **Build order:** outbox.jsonl integration (foundation, works everywhere) → generic webhook (covers Slack/Discord/Teams/anything) → platform notifications (macOS/Linux/Windows) → mobile app push (when mobile exists).
4978
+
4979
+ ---
4980
+
4981
+ ## 🎉 WorkTrain first confirmed end-to-end autonomous session (Apr 18, 2026)
4982
+
4983
+ **Timestamp:** 2026-04-18T15:09:49Z
4984
+ **Commit:** `473f4bd0` (main)
4985
+ **npm version:** v3.34.1 (published, installable by anyone)
4986
+ **What happened:** A real MR review workflow (`mr-review-workflow-agentic`) ran completely autonomously via webhook trigger, advanced through all phases (context gathering, review, synthesis, validation, handoff), self-validated, and produced a structured finding set. 8 step advances, `outcome: success`.
4987
+
4988
+ **Trigger:** `POST /webhook/mr-review {"goal": "Review PR #566: fix two minor bugs..."}`
4989
+ **Session:** `sess_3bmjuzf7l2vrqynjtleg5iskm4`
4990
+ **Result:** APPROVE with High confidence. 3 Minor findings, 1 Informational. Correctly decided not to delegate since no Critical/Major issues.
4991
+
4992
+ ---
4993
+
4994
+ ### What works at this commit
4995
+
4996
+ - ✅ Daemon accepts webhooks, starts sessions, runs workflows end-to-end
4997
+ - ✅ Sessions advance through all workflow phases autonomously
4998
+ - ✅ `mr-review-workflow-agentic` v2.6 runs fully -- context gathering, review phases, synthesis loop, validation, handoff
4999
+ - ✅ `wr.discovery` v3.2.0 runs fully -- with new phase-0-reframe (goal reframing before research)
5000
+ - ✅ Console shows live sessions via event log (no daemon connection required)
5001
+ - ✅ MCP server is stable (bridge removed, EPIPE fixed, v3.34.1 published)
5002
+ - ✅ GitHub + GitLab polling triggers (no webhooks needed)
5003
+ - ✅ `worktrain init`, `tell`, `inbox`, `spawn`, `await` CLI commands
5004
+ - ✅ Stuck detection + visibility (`worktrain status`, `worktrain logs --follow`)
5005
+ - ✅ `complete_step` tool -- daemon manages continueToken, LLM never handles it
5006
+ - ✅ Assessment gate circuit breaker (stops at 3 blocked attempts, shows artifact format)
5007
+ - ✅ `worktrain daemon --install` creates launchd service (daemon survives MCP reconnects)
5008
+ - ✅ Self-configuration (`triggers.yml`, `daemon-soul.md`, `AGENTS.md` for workrail repo)
5009
+
5010
+ ### Current limitations at this commit
5011
+
5012
+ **Blocking reliable complex workflows:**
5013
+ 1. **`complete_step` not yet tested in production** -- just merged, daemon still using `continue_workflow` in running sessions. Needs daemon restart to take effect.
5014
+ 2. **Assessment gates still unreliable** -- `complete_step` fixes the token issue; the `artifacts` field (#557) fixes the submission issue. But `coding-task-workflow-agentic` phases with quality gates haven't been tested end-to-end yet.
5015
+ 3. **Native `spawn_agent` not yet merged** -- implementation in progress. Until it lands, all subagent delegation is via `mcp__nested-subagent__Task` (invisible black box).
5016
+ 4. **No session identity (parentSessionId)** -- multi-phase work appears as unrelated flat sessions in the console.
5017
+
5018
+ **Architecture not yet realized:**
5019
+ 5. **Coordinator scripts don't exist** -- `worktrain spawn/await` is there but no templates.
5020
+ 6. **Subagent loop not rethought** -- LLM still decides when to delegate; workflow-as-orchestrator model is spec'd but not built.
5021
+ 7. **Workflow runtime adapter not built** -- workflows run in daemon mode as-is; no MCP vs daemon adaptation layer.
5022
+ 8. **Knowledge graph not built** -- context gathering still sweeps files on every session.
5023
+ 9. **MCP simplification PR-B not done** -- HttpServer still starts with MCP server.
5024
+
5025
+ **Missing for production autonomy:**
5026
+ 10. **No notifications** -- daemon completes work silently. Users have no awareness unless watching console/logs.
5027
+ 11. **No auto-commit from handoff artifact** -- merged but untested end-to-end.
5028
+ 12. **Late-bound goals not implemented** -- triggers require static goals; dynamic goals (like PR reviews) need `goalTemplate: "{{$.goal}}"` as default.
5029
+ 13. **No coordinator script template** -- the multi-phase autonomous pipeline exists as primitives but not as a usable script.
5030
+
5031
+ ---
5032
+
5033
+ ### Artifacts as first-class citizens: explorable, accessible, out of the repo (Apr 18, 2026)
5034
+
5035
+ **The current mess:** every autonomous session dumps `design-candidates.md`, `implementation_plan.md`, `design-review-findings.md`, `mr-review.md` etc. as files in the repo root or worktrees. They are:
5036
+ - Not indexed or searchable
5037
+ - Not visible in the console
5038
+ - Not accessible to other sessions (agent B can't read agent A's handoff without knowing the exact file path)
5039
+ - Polluting the repo with ephemeral working documents
5040
+ - Lost when worktrees are cleaned up
5041
+ - Scattered across the filesystem with no structure
5042
+
5043
+ **The right model:** artifacts are WorkTrain data, not filesystem files.
5044
+
5045
+ ---
5046
+
5047
+ #### What an artifact is
5048
+
5049
+ Any structured output from a session that has value beyond the session itself:
5050
+ - **Handoff docs** -- what one session produces for the next to consume
5051
+ - **Design candidates** -- research output with tradeoffs and recommendation
5052
+ - **Implementation plans** -- what to build, how, in what order
5053
+ - **Review findings** -- MR review output with findings, severity, recommendation
5054
+ - **Spec files** -- behavioral specs, acceptance criteria, API contracts
5055
+ - **Investigation summaries** -- bug investigation root cause and reproduction
5056
+ - **Context bundles** -- pre-packaged knowledge for subagent consumption
5057
+
5058
+ **NOT artifacts:** step notes (stay in WorkRail session store), event logs (stay in daemon events), source code (stays in repo).
5059
+
5060
+ ---
5061
+
5062
+ #### Where artifacts live
5063
+
5064
+ `~/.workrail/artifacts/<sessionId>/<artifact-type>-<timestamp>.json`
5065
+
5066
+ Structured JSON, not markdown. The display layer (console, `worktrain artifacts`) renders them as human-readable. Other agents query them as structured data.
5067
+
5068
+ **Why JSON not markdown:**
5069
+ - Queryable by other agents (what are the findings with severity=critical?)
5070
+ - Renderable by the console with proper formatting, filtering, search
5071
+ - Versionable and diffable in the artifact store
5072
+ - Accessible via the knowledge graph (artifacts become nodes with typed edges)
5073
+
5074
+ ---
5075
+
5076
+ #### Console integration
5077
+
5078
+ The console session detail view gets an "Artifacts" tab alongside "Steps" and "Notes":
5079
+
5080
+ ```
5081
+ Session: sess_3bmj... [MR Review: PR #566]
5082
+ ├── Steps (8)
5083
+ ├── Notes
5084
+ └── Artifacts (3)
5085
+ ├── 📋 review-findings.json "APPROVE -- 3 Minor, 1 Info"
5086
+ ├── 📄 context-bundle.json "12 files read, 4 patterns identified"
5087
+ └── 🔍 investigation-notes.json "Signal 3 dead code in max_turns path"
5088
+ ```
5089
+
5090
+ Click an artifact → full rendered view in the console.
5091
+
5092
+ ---
5093
+
5094
+ #### Accessibility to other agents
5095
+
5096
+ Agents can query artifacts from prior sessions via a new tool:
5097
+
5098
+ ```
5099
+ read_artifact({ sessionId: 'sess_3bmj...', type: 'review-findings' })
5100
+ → { verdict: 'APPROVE', findings: [...], recommendation: '...' }
5101
+
5102
+ search_artifacts({ type: 'implementation-plan', workflowId: 'coding-task-workflow-agentic', since: '7d' })
5103
+ → [{ sessionId, summary, createdAt }, ...]
5104
+ ```
5105
+
5106
+ This replaces the current pattern where agents `cat design-candidates.md` from a known path -- fragile, path-dependent, breaks across worktrees.
5107
+
5108
+ ---
5109
+
5110
+ #### Workflow integration
5111
+
5112
+ Workflow steps declare their artifact output type:
5113
+
5114
+ ```json
5115
+ {
5116
+ "id": "phase-1c-challenge-and-select",
5117
+ "output": {
5118
+ "artifact": "design-candidates",
5119
+ "schema": "wr.artifacts.design-candidates.v1"
5120
+ }
5121
+ }
5122
+ ```
5123
+
5124
+ The daemon automatically stores the step's notes as a typed artifact. Other steps and other sessions can query it by type rather than by file path.
5125
+
5126
+ ---
5127
+
5128
+ #### What stays in the repo
5129
+
5130
+ Almost nothing from WorkTrain sessions. The only things that belong in the repo:
5131
+ - Source code changes (committed via auto-commit or human review)
5132
+ - Long-lived spec files that are part of the product (e.g. `docs/ideas/backlog.md`)
5133
+ - Workflow definitions (`workflows/*.json`)
5134
+
5135
+ Everything else -- design docs, review findings, investigation notes, implementation plans -- lives in `~/.workrail/artifacts/`. If you want a design doc in the repo, you explicitly commit it. The default is: it lives in WorkTrain's data layer.
5136
+
5137
+ ---
5138
+
5139
+ #### Build order
5140
+
5141
+ 1. **Artifact store** -- `~/.workrail/artifacts/<sessionId>/` directory structure, JSON schema for common types
5142
+ 2. **Daemon writes artifacts** -- workflow steps with `output.artifact` declaration write to the artifact store automatically
5143
+ 3. **`worktrain artifacts` CLI** -- list, read, search artifacts by session, type, date
5144
+ 4. **Console artifacts tab** -- render artifacts in session detail view
5145
+ 5. **`read_artifact` / `search_artifacts` tools** -- agents can query the artifact store
5146
+ 6. **Knowledge graph integration** -- artifacts become nodes, sessions link to their artifacts
5147
+
5148
+ **The `NEVER COMMIT MARKDOWN FILES` rule in metaGuidance is a symptom of this missing feature.** The rule exists because agents keep dumping files in the wrong place. With a proper artifact store, the rule becomes unnecessary -- artifacts have nowhere to go except the artifact store.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@exaudeus/workrail",
3
- "version": "3.35.0",
3
+ "version": "3.35.1",
4
4
  "description": "Step-by-step workflow enforcement for AI agents via MCP",
5
5
  "license": "MIT",
6
6
  "repository": {