@wrongstack/core 0.282.2 → 0.283.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.
Files changed (48) hide show
  1. package/dist/{agent-subagent-runner-DCczSoQj.d.ts → agent-subagent-runner-BsuWhB28.d.ts} +2 -2
  2. package/dist/coordination/index.d.ts +12 -12
  3. package/dist/coordination/index.js +315 -41
  4. package/dist/coordination/index.js.map +1 -1
  5. package/dist/defaults/index.d.ts +12 -12
  6. package/dist/defaults/index.js +316 -53
  7. package/dist/defaults/index.js.map +1 -1
  8. package/dist/{events-BOv8h6I1.d.ts → events-KmxSmvho.d.ts} +5 -0
  9. package/dist/execution/index.d.ts +7 -7
  10. package/dist/extension/index.d.ts +2 -2
  11. package/dist/{global-mailbox-MDDFhLYh.d.ts → global-mailbox-rWVt8YlO.d.ts} +70 -7
  12. package/dist/{goal-store-BEmDmSKF.d.ts → goal-store-8owBXJT2.d.ts} +1 -1
  13. package/dist/hq/index.d.ts +32 -6
  14. package/dist/hq/index.js +128 -32
  15. package/dist/hq/index.js.map +1 -1
  16. package/dist/{index-Dd-PJJ8A.d.ts → index-BhCteHAF.d.ts} +1 -1
  17. package/dist/index.d.ts +291 -21
  18. package/dist/index.js +944 -113
  19. package/dist/index.js.map +1 -1
  20. package/dist/infrastructure/index.d.ts +1 -1
  21. package/dist/kernel/index.d.ts +4 -4
  22. package/dist/kernel/index.js.map +1 -1
  23. package/dist/models/index.js +105 -42
  24. package/dist/models/index.js.map +1 -1
  25. package/dist/{multi-agent-coordinator-BRqtpn-a.d.ts → multi-agent-coordinator-CrjeTB9i.d.ts} +1 -1
  26. package/dist/{null-fleet-bus-BkptvIVo.d.ts → null-fleet-bus-D4e9R7Qc.d.ts} +9 -4
  27. package/dist/observability/index.d.ts +1 -1
  28. package/dist/{parallel-eternal-engine-BXECuOVG.d.ts → parallel-eternal-engine-iY2uxocj.d.ts} +4 -4
  29. package/dist/{provider-runner-CJtCs1Rw.d.ts → provider-runner-oQhDaZmH.d.ts} +1 -1
  30. package/dist/sdd/index.d.ts +4 -4
  31. package/dist/sdd/index.js.map +1 -1
  32. package/dist/storage/index.d.ts +5 -5
  33. package/dist/storage/index.js.map +1 -1
  34. package/dist/{todos-checkpoint-Bw83WMh9.d.ts → todos-checkpoint-BwCrj4Cb.d.ts} +1 -1
  35. package/dist/{tool-executor-4mWN2vHW.d.ts → tool-executor-kElSEgO0.d.ts} +4 -4
  36. package/dist/types/index.d.ts +8 -8
  37. package/dist/types/index.js +105 -45
  38. package/dist/types/index.js.map +1 -1
  39. package/dist/{worktree-manager-BrtjUFYk.d.ts → worktree-manager-BjyAW30D.d.ts} +1 -1
  40. package/instructions/modes/audit-lite.md +13 -0
  41. package/instructions/modes/debug-lite.md +13 -0
  42. package/instructions/modes/plan-lite.md +14 -0
  43. package/instructions/modes/refactor-lite.md +13 -0
  44. package/instructions/modes/research-lite.md +13 -0
  45. package/instructions/modes/review-lite.md +14 -0
  46. package/instructions/modes/test-lite.md +13 -0
  47. package/package.json +1 -1
  48. package/skills/mailbox-bridge/SKILL.md +33 -0
@@ -1,4 +1,4 @@
1
- import { E as EventBus } from './events-BOv8h6I1.js';
1
+ import { E as EventBus } from './events-KmxSmvho.js';
2
2
 
3
3
  /**
4
4
  * Lifecycle of a single worktree handle.
@@ -0,0 +1,13 @@
1
+ ## Audit Lite Mode
2
+
3
+ Token-saving security sweep. Use for quick risk triage on a small diff or named file.
4
+
5
+ Scope:
6
+ - Check trust boundaries, auth/authz, secrets, injection, unsafe file/network/process use.
7
+ - Prefer grep/read over broad scans; do not enumerate every clean category.
8
+ - Treat unproven paths as NEEDS-CONTEXT instead of expanding scope automatically.
9
+
10
+ Output:
11
+ - Confirmed or likely exploitable findings only.
12
+ - Each finding: `file:line — risk — exploit sketch — fix`.
13
+ - If no issue: one sentence naming the checked surfaces.
@@ -0,0 +1,13 @@
1
+ ## Debug Lite Mode
2
+
3
+ Token-saving debugging mode. Use for fast root-cause triage before deep tracing.
4
+
5
+ Scope:
6
+ - Start from the exact error, failing test, or symptom.
7
+ - Inspect the nearest stack frame / call site / config first.
8
+ - Form one leading hypothesis, then test it with the narrowest command or read.
9
+
10
+ Output:
11
+ - Hypothesis, evidence, next check.
12
+ - If fixed, state root cause and verification.
13
+ - If not fixed after two checks, recommend switching to `debugger` for full tracing.
@@ -0,0 +1,14 @@
1
+ ## Plan Lite Mode
2
+
3
+ Token-saving planning mode. Use for quick implementation direction without a full design doc.
4
+
5
+ Scope:
6
+ - Read only enough code to identify entry points, constraints, and likely files.
7
+ - Produce the smallest safe plan that can start work now.
8
+ - Avoid multi-option architecture analysis unless the decision is blocking.
9
+
10
+ Output:
11
+ - Assumption line if any.
12
+ - 3-6 ordered steps.
13
+ - Verification target.
14
+ - One risk or unknown max.
@@ -0,0 +1,13 @@
1
+ ## Refactor Lite Mode
2
+
3
+ Token-saving refactor mode. Use for small cleanup while preserving behavior.
4
+
5
+ Scope:
6
+ - Touch only the requested symbol/file unless required by compile errors.
7
+ - Avoid opportunistic rewrites, format churn, and API changes.
8
+ - Keep changes mechanically reviewable.
9
+
10
+ Output:
11
+ - State behavior-preservation assumption.
12
+ - Summarize the minimal transformation.
13
+ - Verify with the narrowest test/typecheck/lint target.
@@ -0,0 +1,13 @@
1
+ ## Research Lite Mode
2
+
3
+ Token-saving current-data research. Use when a quick freshness check is enough.
4
+
5
+ Scope:
6
+ - Search once with 3-5 results.
7
+ - Fetch at most one authoritative source unless it conflicts with another result.
8
+ - Do not build a full literature review.
9
+
10
+ Output:
11
+ - Short answer first.
12
+ - 1-3 bullets with source domain and date/version if visible.
13
+ - Say what remains uncertain instead of continuing to search.
@@ -0,0 +1,14 @@
1
+ ## Review Lite Mode
2
+
3
+ Token-saving review pass. Use this when the user wants a quick sanity check, not a full audit.
4
+
5
+ Scope:
6
+ - Inspect only the changed or explicitly named files unless the user asks broader.
7
+ - Report only correctness bugs, obvious regressions, and high-impact security issues.
8
+ - Skip style nits, broad architecture commentary, and speculative edge cases.
9
+
10
+ Output:
11
+ - Max 5 findings, ordered by severity.
12
+ - Each finding: `file:line — issue — minimal fix`.
13
+ - If clean, say what you checked in one sentence.
14
+ - End with at most one follow-up question or verification command.
@@ -0,0 +1,13 @@
1
+ ## Test Lite Mode
2
+
3
+ Token-saving test mode. Use to add or select the narrowest useful regression coverage.
4
+
5
+ Scope:
6
+ - Prefer one focused regression over broad suite expansion.
7
+ - Target the changed behavior, boundary input, or prior failure.
8
+ - Reuse existing test style and helpers; do not redesign the test harness.
9
+
10
+ Output:
11
+ - Name the behavior under test.
12
+ - Add/run the smallest relevant test command.
13
+ - Report pass/fail and one untested risk if relevant.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wrongstack/core",
3
- "version": "0.282.2",
3
+ "version": "0.283.1",
4
4
  "license": "MIT",
5
5
  "description": "WrongStack core: kernel, types, defaults, and shared utilities for the WrongStack CLI agent.",
6
6
  "repository": {
@@ -161,6 +161,39 @@ Every error response follows the WrongStack API convention:
161
161
  - No rate limiting at the bridge layer — assume the bearer token is the
162
162
  only credential and trust the loopback network.
163
163
 
164
+ ## The HQ dashboard writes to the same mailbox
165
+
166
+ The HQ command center (`wstack --hq`) shares this exact `GlobalMailbox`.
167
+ When an operator sends a prompt from the HQ screen, it lands in the same
168
+ `_mailbox.jsonl` an external agent reads through `/mailbox/query` — so an
169
+ external agent participating via this bridge sees HQ prompts too.
170
+
171
+ HQ delivers a prompt one of two ways:
172
+
173
+ - **`POST /api/command`** on the HQ server — routes to a *connected*
174
+ client, which then calls `GlobalMailbox.send`.
175
+ - **`POST /api/mailbox-send`** on the HQ server — writes to the project
176
+ mailbox **directly**, so the prompt is delivered even when no agent is
177
+ connected. The HQ server resolves the target `projectRoot` from its
178
+ `SessionRegistry` (never a browser-supplied path).
179
+
180
+ Either way, the resulting mailbox message carries one of the HQ **send
181
+ types**, which map onto the mailbox `type` field an external agent will
182
+ observe:
183
+
184
+ | HQ send type | Mailbox `type` | Intent for the receiver |
185
+ |--------------|----------------|-------------------------|
186
+ | `steer` | `steer` | Change course now. |
187
+ | `btw` | `btw` | FYI / context — no course change demanded. |
188
+ | `queue` | `note` | A queued prompt; handle before the next step. |
189
+ | `broadcast` | `broadcast` | Sent to all agents on the project (`to: all`). |
190
+
191
+ An external agent does not need to distinguish HQ-originated messages —
192
+ they arrive with `from` set to `hq@<tag>` and are read, acked, and
193
+ completed through the same `/mailbox/query` + `/mailbox/ack` routes as
194
+ any other message. Filter on `from` if you want to treat HQ prompts
195
+ specially.
196
+
164
197
  ## Pairing with the external-facing skill
165
198
 
166
199
  This internal skill describes how to run the server. The