Changelog

Real, dated changes across every SwarmADE repository. Click an entry to read the full note.

Sunday, June 14, 2026

@swarmade-workspace/shared0.19.0Add `EntitlementsSchema` / `Entitlements` to `schemas/gating.ts` (sprint-10 task 08, spec §8): the resolved per-user plan entitlements the api's `FeatureGateService.listEntitlements` computes and the desktop's `useEntitlements()` renders to grey-out gated capabilities before the authoritative server-side `assert`. UX-hint mirror only — the server stays the source of truth.

Saturday, June 13, 2026

@swarmade-workspace/shared0.18.0Add the plan-gating + upgrade contract consumed by the UpgradeModal (sprint-10 task 07, spec §8):
Add the plan-gating + upgrade contract consumed by the UpgradeModal (sprint-10 task 07, spec §8):

  - `constants/plans.ts` — `PLAN_FEATURES` / `PLAN_LABELS` / `UNLIMITED`: the typed, presentation-ready mirror of the seeded `pricing_tiers` rows (Honey, concurrent Hives, Drones, cloud sync, priority routing, monthly + effective-annual USD) the UpgradeModal and landing pricing grid render.
  - `schemas/gating.ts` — `GatedFeatureReasonSchema` / `GatedFeatureErrorSchema`: the cross-process `403 { error_code: "gated_feature", ... }` body the api FeatureGateService (task 08) returns and the desktop/landing intercept to open the modal.
  - `lib/suggestPlan.ts` — `suggestPlan(currentPlan, reason)`: the pure, total upgrade-pitch resolver (Starter→Pro, Pro→Ultra for the Hive gate; Pro for drones/cloud-sync; Ultra for priority routing).
@swarmade-workspace/shared0.17.0Add the Honey wallet read model (`HoneyWalletSchema`, `HoneyTransactionViewSchema`, `HoneyTransactionTypeSchema`) in `schemas/honey.ts` — the contract `GET /v1/honey/wallet` returns and the desktop Settings → Honey pane + landing `/account` page render (sprint-10 task 06). A read-only projection of `honey_wallets` + `honey_transactions`: spendable `total`, the `plan`/`topup` split, `honey_used_this_period`, and the last few signed ledger rows.
@swarmade-workspace/shared0.17.0Add canonical Honey topup brackets (`honeyForTopup`, `TOPUP_AMOUNTS`, `TOPUP_PRESETS`) in `constants/honey.ts` — the single source of truth for how many Honey a one-time $10/$20/$50 topup grants (tiered 0%/5%/10% bonus, spec §8.2 / sprint-10 task 05). The API endpoint, the credit consumer, and the desktop/landing topup UIs all derive from this so the quoted amount always equals the credited amount.
@swarmade-workspace/shared0.16.0Add billing/subscription contracts for the `/v1/billing/*` surface (sprint-10 task 02): `BillingCheckoutRequestSchema`, `BillingPortalRequestSchema`, `HoneyTopupRequestSchema`, `SubscriptionStateSchema` (plus their response schemas and the `BillingPlanId` / `BillingPeriod` / `SubscriptionStatus` enums). The landing + desktop consume these to drive checkout, the customer portal, Honey topups, and to render subscription state. The api mirrors them locally until this version publishes (TD-SHARED-BILLING-WIRING).

Wednesday, June 10, 2026

@swarmade-workspace/shared0.15.0Promote the last consumer-mirrored contract symbols into the shared package so
Promote the last consumer-mirrored contract symbols into the shared package so
  api / queen / desktop can drop their local `// TODO(shared@next)` copies and
  swap to shared imports (all additive — no breaking change):

  - `DroneArtifactRefsSchema` + `DroneArtifactRefs` (new `schemas/drone-artifacts.ts`):
    presigned diff / snapshot GET URLs + optional `hive_context_ref` the desktop
    attaches at task completion (ADR-014 D4). Also added `artifacts:
DroneArtifactRefsSchema.optional()` to the inbound `worker.task_done` frame so
    the strict parse no longer strips it (closes `TD-SHARED-ARTIFACTS-WIRING`).
  - `GitContextSchema` + `GitContext` (new `schemas/git-context.ts`): the
    desktop-resolved git context (`branch` / `head_sha` / `recent_commits` /
    `changed_files`) attached to the plan-creation request (ADR-014 GIT_READER);
    exported standalone for consumers to attach (closes `TD-SHARED-GITCONTEXT-WIRING`).
  - `queen.permission_request` + `queen.permission_auto_denied` are now members of
    the `WSEventSchema` discriminated union (they previously existed only as
    standalone payload schemas), so the desktop WS dispatcher can route them
    (closes the shared half of `TD-SHARED-PERMISSION-WIRING`).
  - `CostTickSchema` / `WorkerCostSchema` / `CostHistoryItemSchema` (+
    `CostHistoryResponseSchema`, `COST_HISTORY_STATUSES`, `CostHistoryStatus`) in
    new `schemas/queen-cost.ts`: the Live Cost Dashboard wire contract previously
    duplicated in swarmade-api + swarmade-desktop (closes `TD-08-16-1`).
@swarmade-workspace/memory0.1.0First published release of the SwarmMemory MCP server package.
@swarmade-workspace/shared0.14.0Add the Drone tuning contract (sprint-09 task 17): `DroneTuneSchema` (per-drone
Add the Drone tuning contract (sprint-09 task 17): `DroneTuneSchema` (per-drone
  `enabled`, `min_severity_shown` view floor, optional `promote_threshold` to make
  a drone louder, optional `timeout_ms_override` clamped to `[5_000, 600_000]`) and
  `DronesSettingsSchema` (the 8 canonical drones, each tune optional). Also export
  `DRONE_SETTINGS_IDS` plus `DRONE_TIMEOUT_MS_MIN`/`DRONE_TIMEOUT_MS_MAX`. These are
  the payload shapes for the per-Hive / per-user drone settings exchanged between
  desktop and api; effective-settings resolution order is
  `system default → user default → hive override`.
@swarmade-workspace/shared0.14.0Add the desktop ReviewPane contract (sprint-09 task 16): two client-facing
Add the desktop ReviewPane contract (sprint-09 task 16): two client-facing
  `WSEvent` variants — `queen.review.aggregated` (carries the full
  `AggregatedReview` payload so the pane renders drone cards without a follow-up
  REST fetch; one frame per attempt, keyed by `task_id` + `hive_id` for WS-room
  routing) and `drone.issue.found` (partial streaming of issues a Drone surfaces
  while a review is still in flight). Also add the `POST
/v1/queen/tasks/:taskId/follow-up` DTOs `TaskFollowUpRequestSchema` (`{ fix:
SuggestedFix }`) and `TaskFollowUpResponseSchema` (`{ follow_up_task_id,
plan_id }`) for turning a Drone's suggested fix into a follow-up TaskNode.

Tuesday, June 9, 2026

@swarmade-workspace/shared0.13.0Add the quality-gate retry loop WS events (sprint-09 task 15): `queen.task.escalated`
Add the quality-gate retry loop WS events (sprint-09 task 15): `queen.task.escalated`
  (task failed drone review 3× — desktop opens the task-escalation modal with the last
  combined review markdown and cumulative Honey spent), `queen.task.accepted` (accept
  verdict `done` / `done_with_warnings` + `combined_severity` badge for the Plan View),
  and `queen.escalation.resolved` (the user's modal verdict broadcast back to every
  window). Export `TaskEscalationActionSchema` (`take_over` / `mark_done` / `abort`)
  for the resolve endpoint DTO.
@swarmade-workspace/shared0.13.0Add the combined Drone review contract (sprint-09 task 14): `AggregatedReviewSchema` +
Add the combined Drone review contract (sprint-09 task 14): `AggregatedReviewSchema` +
  `AggregatedCriticalIssueSchema` (per-task roll-up of all `DroneReport`s with
  `combined_severity`, flattened critical issues, combined markdown, `honey_total`,
  optional `memory_ref`), extract `DroneSeveritySummarySchema` as a named export
  (shape unchanged inside `DroneReportSchema`), and register the new `review`
  memory type in `MemoryTypeSchema` for aggregator-produced SwarmMemory notes.
@swarmade-workspace/shared0.13.0Add Honey metering contracts for Drone runs (sprint-09 task 12): `HoneyKindSchema`
Add Honey metering contracts for Drone runs (sprint-09 task 12): `HoneyKindSchema`
  (`llm.invoke` | `drone.run`), `DroneRunOutcomeSchema` (success | timeout-partial |
  infra_failure | timeout-killed | egress-violation), and the internal settle
  endpoint payloads `DroneHoneySettleRequestSchema` / `DroneHoneySettleResponseSchema`.
@swarmade-workspace/drones0.6.0feat(runner): add sandboxed Docker per-run drone runner (sprint-09 task 11)
feat(runner): add sandboxed Docker per-run drone runner (sprint-09 task 11)

  Introduce the `@swarmade-workspace/drones/runner` surface that consumes the
  per-drone `drone-<id>-run` BullMQ queues and executes each drone inside a fresh,
  resource-limited, egress-restricted Docker container drawn from a warm pool:

  - `ContainerRuntime` port + `CliDockerRuntime` (shell-free `execFile` adapter)
  - `ContainerPool` — warm pool, destroy-on-release, lazy replenish
  - `network-policy` — egress allowlist iptables rule builder/applier
  - `drone-cli` — in-image dispatcher (`drone-cli run <id> --input …`)
  - `drone-runner` — per-job handler with unconditional `try/finally` teardown
  - `bullmq-workers` — one worker per drone queue with per-drone concurrency
  - `Drone.wire()` — `@internal` runner-only injection hook for `emit`/`llm`/`logger`

  Adds `bullmq` + `ioredis` runtime deps. The Docker image build, red-team
  verification, cosign signing, and GHCR push are tracked separately (Linux
  runtime / `docs/security/sandbox-pentest.md`).

Monday, June 8, 2026

@swarmade-workspace/drones0.5.0feat(refactor-safety): add RefactorSafetyDrone (sprint-09 task 09)
feat(refactor-safety): add RefactorSafetyDrone (sprint-09 task 09)

  Ninth review Drone. Triggered on `task-type-refactor`, it verifies "same
  outward behavior, different shape" across three layers: a deterministic
  exported-signature diff (removed/renamed export, widened signature, changed
  return type, changed default argument), a test-outcome diff against the cached
  baseline (regression, lost coverage), and a conservative `drone.refactor` LLM
  pass on files whose signatures are unchanged but whose internals moved
  (iteration order, equality semantics, side-effect timing, async vs sync). A
  clean refactor surfaces a single `behavior-preserved` info. Deterministic and
  host-free (balanced-paren TS tokenizer, no `@typescript-eslint/parser`); the
  suite double-run lives in an injected integration runner.
@swarmade-workspace/drones0.5.0feat(contract): add ContractDrone (sprint-09 task 08)
feat(contract): add ContractDrone (sprint-09 task 08)

  Eighth review Drone. Triggered on `diff-contains-openapi`, it diffs the API
  contract surface (OpenAPI document or `@swarmade/shared` Zod schemas) and flags
  breaking changes — removed endpoint/field, response type narrowing, new/required
  input — computing a semver impact verdict and emphasising any `/v1` break per
  CLAUDE.md §4.4. Deterministic and host-free (pure-TS structural diff, no
  `oasdiff` binary); LLM summarisation is opt-in only.

Wednesday, June 3, 2026

@swarmade-workspace/drones0.4.0Add `MigrationSafetyDrone` (sprint-09 task 07), the schema-migration auditor that gates every DB change before it reaches staging. It triggers only on `diff-contains-migration` and detects new migration files across Drizzle, Prisma, TypeORM, Alembic, golang-migrate, and Liquibase, anchoring each finding to the exact `file_path:line`.
Add `MigrationSafetyDrone` (sprint-09 task 07), the schema-migration auditor that gates every DB change before it reaches staging. It triggers only on `diff-contains-migration` and detects new migration files across Drizzle, Prisma, TypeORM, Alembic, golang-migrate, and Liquibase, anchoring each finding to the exact `file_path:line`.

  A deterministic, host-free rubric flags the structural hazards: `DROP COLUMN`/`DROP TABLE`, `RENAME COLUMN` (and MySQL `CHANGE COLUMN` renames), `TRUNCATE`/`DELETE` as `critical`; `NOT NULL` with no default and charset/collation conversions as `high`; benign `ADD COLUMN`(nullable)/`CREATE TABLE` acknowledged at `info`. A lock-duration estimator flags a non-online `CREATE/ADD INDEX` on a >1M-row table and an `ADD COLUMN` rebuild on a >10M-row table as `medium`/`long-lock` with an estimated duration (row counts from `.swarmade-table-sizes.json`, a `_hot` naming convention, or a default; the live MySQL-8.4 timing/prior-type probe lives in `lock-duration-runner.ts`, the task-11 DinD image, excluded from the unit gate). Type narrowing (`varchar(100)`→`varchar(50)`, `int`→`smallint`, `decimal(10,2)`→`decimal(8,2)`, `text`→`varchar`) is judged by the pure comparison rubric fed from the probe's prior-type lookup. A down-migration check follows each ORM's culture: missing revert is `medium` for one-way Drizzle/Liquibase, `high` for explicit-down TypeORM/Alembic/Prisma and unpaired golang-migrate `.up.sql`.

  On top of the deterministic core it layers an optional, low-temperature LLM pass (`drone.migration` role, versioned `migration-v1` prompt) for the semantic risks a regex cannot see — trigger removal, FK cascade fan-out, collation comparison surprises, default-value interactions with existing NULL rows, partial/functional-index limits — skipped when every static finding is already `critical` to save Honey. It honours `-- drone:ignore-migration <reason>` suppressions (downgrade to `info`, never dropped), settles Honey at an estimate of 4, and times out at 120 s.

Tuesday, June 2, 2026

@swarmade-workspace/drones0.3.0Add `StyleDrone` (sprint-09 task 06), the lowest-cost, lowest-severity auditor and the canary for "drone fatigue". It auto-detects the project's configured linters/formatters from their config files in a stable priority order — `[biome, eslint, prettier, ruff, rustfmt, gofmt]`, dropping ESLint+Prettier in favour of Biome when `biome.json` is present (CLAUDE.md §15.1) — and runs each against the diff's changed files. Findings map deliberately low so style never blocks a merge: a hard lint `error` → `medium`/`lint-error`, a `warn` → `low`/`lint-warning`, and an unformatted file → `low`/`formatting`. On top of the deterministic linters it layers a documentation-completeness pass (new exported symbol with no JSDoc/TSDoc/docstring → `info`/`missing-doc`, a changed signature whose existing doc was left untouched → `low`/`stale-doc`; public surface only, TS/JS/Python/Rust/Go) and an optional cheap LLM naming pass (`drone.style` role, temperature 0.0) that flags casing inconsistency (`low`/`naming-consistency`) and cryptic names (`low`/`naming-clarity`) — clamped so the model can never escalate a nit above `low`, and skipped entirely when the diff adds no new exports or when the per-hive `style.use_llm` setting is off. When no linter config is detected it still completes, emitting an `info` nudge to add one. It respects standard linter suppressions (`// biome-ignore`, `// eslint-disable-line/next-line`, `# ruff: noqa`) plus `// drone:ignore-style` (downgrade to `info`, never dropped), settles Honey at 2 (1 tooling + 1 LLM), times out at 60 s, and ships the versioned `style-v1` prompt. The actual linter execution lives in `lint-runner.ts` (task-11 runtime image); off-runtime the pure runner parsers, detector, mapping, doc and naming passes are fully unit-tested and under the coverage gate.
@swarmade-workspace/drones0.2.0Add `TestCoverageDrone` (sprint-09 task 05), the test-coverage auditor. It auto-detects the project's test runner (Vitest/Jest/pytest/cargo/go/mix) from its manifest files, runs the suite with coverage, and applies three deterministic rubrics. New-code coverage overlays the diff's added lines on the per-file coverage map: an entirely-new file with 0 % covered → `high`/`untested-new-file`, added lines that are executable but never hit → `high`/`untested-new-lines` (anchored to the exact line range), and a fully-covered change earns an `info`/`well-tested` annotation. Coverage delta vs the stored per-hive baseline flags a per-file regression ≥10 pp → `high`/`coverage-regression`, 2–9 pp → `medium`, <2 pp ignored as noise, with a first-run `info`/`coverage-baseline` note. Flaky detection re-runs only the diff's changed test files 5× and flags any test with inconsistent outcomes → `medium`/`flaky`. The LLM is used only — and optionally — to summarise the markdown report (`drone.testcov` role, low temperature), never to judge, so the verdict is reproducible and Honey-bounded (settles at 2 with no LLM, 4 with). The drone skips cleanly (empty report, zero Honey) when no test runner is detected, supports per-line `// drone:ignore-testcov <reason>` suppression (downgrade to `info`, never dropped), and ships the versioned `testcov-v1` prompt. Suite execution, the rerun loop, and the api baseline sidecar live in the task-11 runtime image; off-runtime the runner degrades gracefully (skips the pass) so the drone still completes.
@swarmade-workspace/drones0.2.0Add `PerformanceDrone` (sprint-09 task 04), the performance auditor. It runs two complementary passes gated by the artifacts in the diff. The frontend pass compares the gzipped bundle to the stored per-hive baseline (+≥50 kB → `high`/`bundle-bloat`, +10–49 kB → `medium`, +<10 kB → `info`, shrinkage → `info` improvement, first run capped at `info`) and maps the Lighthouse mobile performance score (`<50` → `high`, `50–79` → `medium`, `≥80` → `info`). The backend pass extracts newly added SQL from the diff, runs `EXPLAIN FORMAT=JSON` against an ephemeral MySQL 8.4 container and maps the plan (`type=ALL` on >1000 rows → `high`/`full-table-scan`, missing index on a JOIN → `high`/`missing-index`, `Using filesort` on >10k rows → `medium`/`filesort`), and adds an LLM judgment pass (`drone.performance` role) for ORM N+1 and lazy-load cascades over the changed source. The drone skips silently (empty report, `0` Honey) when the diff has neither frontend nor backend artifacts (e.g. docs-only), supports per-line `// drone:ignore-performance <reason>` (`#`/`--`/`/* */` too) suppression (downgrade to `info`, never dropped), and ships the versioned `performance-v1` system prompt. The build, headless-Chrome, and DinD-MySQL runtime work is provided by the task-11 runtime image; off-runtime each runner degrades gracefully (skips its pass) so the drone still completes.
@swarmade-workspace/drones0.2.0Add `A11yDrone` (sprint-09 task 03), the accessibility auditor for frontend tasks. It pairs a deterministic axe-core pass — run against the rendered DOM of changed components via a headless Chromium + Vite/React render harness (WCAG 2.1 AA; AAA reported as `low`) — with an LLM judgment pass (`drone.a11y` role) over the JSX/TSX source for the semantic anti-patterns axe cannot model (`<div onClick>` as a button, redundant ARIA, keyboard-less click handlers, generic link text, color-only state). axe violations are mapped to `DroneIssue`s (contrast → `medium`/`wcag-aa-contrast`, image-alt → `high`/`alt-text`, label → `high`/`form-label`) and traced back to JSX source. The drone skips silently (empty report, `0` Honey) when the diff has no frontend files, supports per-line `// drone:ignore-a11y <reason>` / `{/* … */}` / `<!-- … -->` suppression (downgrade to `info`, never dropped), and ships the versioned `a11y-v1` system prompt. The browser toolchain is provided by the task-11 runtime image; off-runtime the axe pass degrades gracefully to no DOM findings.
@swarmade-workspace/drones0.2.0Add `SecurityDrone` (sprint-09 task 02), the first auditor. It combines deterministic tooling — an embedded gitleaks-style secret ruleset (AWS keys, GitHub PATs, JWTs, Anthropic/OpenRouter keys, generic `api_key`) scanned over diff added-lines, and an OSV.dev dependency-CVE check (npm/pnpm/Cargo/pip/go) — with an LLM OWASP judgment pass (`drone.security` role). It short-circuits past the Honey-priced LLM call on any hard signal (secret leak or known-exploited CVE), redacts secrets before they reach the model, and supports per-line `// drone:ignore-security <reason>` suppression (downgrade to `info`, never dropped). Ships the versioned `security-v1` system prompt and a `gitleaks.toml` for the runtime image (task 11).
@swarmade-workspace/shared0.12.0Canonicalize two contract surfaces previously duplicated in consumer repos:
Canonicalize two contract surfaces previously duplicated in consumer repos:

  - **CLI bridge mapping (TD-07-07-2 / TD-07-07-3)**: derive `CLI_BRIDGE_IDS` from `CLI_IDS` via a new `CLI_ID_TO_BRIDGE_ID` map + `cliIdToBridgeId(id)` helper. The two arrays can no longer drift, and the only divergence (`claude` → `claude-code`) is explicit instead of hidden in a comment.
  - **Memory MCP contracts (TD-MEM-09-1)**: add the `find_backlinks`, `list_orphans`, `suggest_connections`, `hub_status`, and `update_memory` tool schemas + the `MemoryFrontmatter` and `MemoryLinkRef` shapes. Consumers (swarmade-desktop, swarmade-memory) now have one canonical source instead of local mirrors.
@swarmade-workspace/drones0.1.0Ship the Drone SDK base: `Drone` abstract class, `DroneRegistry` + `@RegisterDrone()` decorator, and re-exports of the shared Drone schemas (`DroneInput`, `DroneReport`, `DroneIssue`, `DroneManifest`, `DroneSeverity`, `DroneTrigger`, `SuggestedFix` + their Zod schemas). The `Drone` base class exposes protected `emit`, `llm`, and `logger` hooks the runner (sprint-09 task 11) injects after construction. Closes TD-SHARED-DRONE-SDK-WIRING.

Monday, June 1, 2026

@swarmade-workspace/shared0.11.0Add Drone SDK contract schemas for sprint-09 task 09-01: `DroneSeveritySchema`, `DroneIssueSchema`, `SuggestedFixSchema`, `DroneReportSchema`, `DroneInputSchema`, `DroneTriggerSchema`, `DroneManifestSchema` (with derived types) in `schemas/drone.ts`, plus `drone.review.started` and `drone.issue.found` event names in `constants/events.ts`. Consumed by `swarmade-drones` (SDK), `swarmade-api` (dispatch gateway), and `swarmade-queen` (review loop).
@swarmade-workspace/shared0.11.0Add the SwarmPane (desktop task 08-13) contract pieces:
Add the SwarmPane (desktop task 08-13) contract pieces:

  - `LayoutWidgetIdSchema` gains the `"swarm-pane"` pane id so the dockable swarm
    grid can be persisted in `hives.layout_json` like any other core widget.
  - New `mailbox.message` variant on `WSEventSchema` — mirrors the
    `mailbox:hive:<hive_id>` Redis channel (task 08-04) onto the Queen WS so the
    desktop SwarmPane can render each Worker's recent messages (hover preview +
    drill-down transcript) without polling the REST read endpoint. Carries the
    full persisted `MailboxMessage` plus its `hive_id` for routing.

  Both additions are non-breaking (additive enum value + additive union variant).
  Consumer wiring in `swarmade-desktop` lands behind `// TODO(shared@<next>)`
  guards until this publishes (TD-SHARED-SWARMPANE-WIRING).
@swarmade-workspace/shared0.11.0Add `SwarmTemplateSchema` + `SwarmTemplate` type (swarm templates, task 08-15).
Add `SwarmTemplateSchema` + `SwarmTemplate` type (swarm templates, task 08-15).

  A version-1 swarm-template contract: `id`, `name`, `description`, a `workers[]`
  array (role + recommended_capability + cli_preference + initial_topics + count,
  each capped at 16) and `edges[]` (role→role mailbox topic subscriptions). The
  expanded worker total is capped at 16 (`SWARM_TEMPLATE_MAX_WORKERS`) and edges
  must reference declared roles. Topics reuse the canonical `MAILBOX_TOPIC_REGEX`.

  Also adds the `WORKER_ROLES` constant + `WorkerRole` type
  (`constants/roles.ts`): the canonical Worker-role source of truth
  (coordinator/builder/reviewer/scout/drone-style/auditor) the template role enum
  is derived from.
@swarmade-workspace/shared0.11.0Add the Hive Management Tools contract (`src/schemas/tools/hive.ts`, Queen task
Add the Hive Management Tools contract (`src/schemas/tools/hive.ts`, Queen task
  08-10, spec §11.3): input/output Zod schemas for the six tools the Queen
  advertises to its LLM — `create_hive`, `archive_hive`, `add_cli_worker`,
  `remove_cli_worker`, `link_hives`, `move_task` — plus `HiveLinkRelationSchema`
  (`sub | sandbox | reference`) and `HiveCliConfigSchema`. Extend the `WSEvent`
  envelope with six Hive-scoped server→desktop events: `hive.created`,
  `hive.archived`, `hive.cli_worker_added`, `hive.cli_worker_removed`,
  `hive.linked`, `hive.task_moved`, so the desktop can refresh the tab bar, spawn
  dock panes, and update the topology view as the Queen reshapes the Hive
  structure.
@swarmade-workspace/shared0.11.0Add the Tool Permission System contract (`src/schemas/permission.ts`, Queen task 08-11, spec §11.3): the per-(user, tool) policy three-state `PermissionModeSchema` (`auto | ask | deny`), the `PermissionPolicySchema` / `PermissionRequestSchema` persistence shapes, the `PermissionResponseSchema` (`{ decision, remember }`) body for `POST /v1/queen/permissions/:id/respond`, the `PermissionPolicyUpdateSchema` for the settings `PATCH`, and the two WS event payloads `PermissionRequestEventSchema` (`queen.permission_request`) / `PermissionAutoDeniedEventSchema` (`queen.permission_auto_denied`) with their `PERMISSION_REQUEST_EVENT` / `PERMISSION_AUTO_DENIED_EVENT` name constants and the `permissionDecisionChannel(requestId)` Redis-channel helper.
Add the Tool Permission System contract (`src/schemas/permission.ts`, Queen task 08-11, spec §11.3): the per-(user, tool) policy three-state `PermissionModeSchema` (`auto | ask | deny`), the `PermissionPolicySchema` / `PermissionRequestSchema` persistence shapes, the `PermissionResponseSchema` (`{ decision, remember }`) body for `POST /v1/queen/permissions/:id/respond`, the `PermissionPolicyUpdateSchema` for the settings `PATCH`, and the two WS event payloads `PermissionRequestEventSchema` (`queen.permission_request`) / `PermissionAutoDeniedEventSchema` (`queen.permission_auto_denied`) with their `PERMISSION_REQUEST_EVENT` / `PERMISSION_AUTO_DENIED_EVENT` name constants and the `permissionDecisionChannel(requestId)` Redis-channel helper.

  Single source of truth for the permission wire shape between `swarmade-queen` (the `PermissionService` that evaluates the policy and emits the `queen.permission_request` event) and `swarmade-api` (the respond endpoint + the policy settings CRUD the desktop reads/writes). Until this publishes, both consumers carry a thin local mirror of these shapes for their Drizzle row types ([TD-SHARED-PERMISSION-WIRING]).

Friday, May 29, 2026

@swarmade-workspace/shared0.10.0Add the Replan loop contract (`src/schemas/replan.ts`, Queen task 08-09):
Add the Replan loop contract (`src/schemas/replan.ts`, Queen task 08-09):
  `ReplanTriggerSchema` (`task_stall | swarm_deadlock` discriminated union),
  `ReplanResultSchema` (`success | escalated | skipped`), `ReplanHistoryEntrySchema`,
  `EscalationNeededSchema`, `EscalationResumeSchema`, and the `MAX_REPLANS_PER_PLAN`
  cap constant. Extend the `WSEvent` envelope with three Hive-scoped events
  `queen.replan_started`, `queen.replan_completed` and `queen.escalation_needed`
  so the desktop Queen drawer can reflect a self-heal in progress and open the
  "I'm stuck after 3 attempts" escalation modal.
@swarmade-workspace/shared0.10.0Add the Convergence detector contract (`src/schemas/convergence.ts`, Queen task 08-08): `SwarmSnapshotSchema` (the structural swarm state the pure classifier consumes — tasks, workers, `lockWaiters`/`mailboxBlocked` sets and the `waitForGraph`), `ConvergenceVerdictSchema` (`ok | task_stall | swarm_deadlock` discriminated union), and the two event payloads `SwarmTaskStalledSchema` / `SwarmDeadlockForceProgressSchema` with their `swarm.task_stalled` / `swarm.deadlock_force_progress` Redis channel constants.
Add the Convergence detector contract (`src/schemas/convergence.ts`, Queen task 08-08): `SwarmSnapshotSchema` (the structural swarm state the pure classifier consumes — tasks, workers, `lockWaiters`/`mailboxBlocked` sets and the `waitForGraph`), `ConvergenceVerdictSchema` (`ok | task_stall | swarm_deadlock` discriminated union), and the two event payloads `SwarmTaskStalledSchema` / `SwarmDeadlockForceProgressSchema` with their `swarm.task_stalled` / `swarm.deadlock_force_progress` Redis channel constants.

  Single source of truth for the convergence wire shape between `swarmade-queen` (the monitor that emits the events) and the Replanner (08-09) / worker supervisor (sprint 7) that consume them. Time is explicit in the snapshot (`now`) so the classifier stays pure and deterministic.
@swarmade-workspace/shared0.10.0Add hierarchical worker spawning contracts (sprint 08 task 07):
Add hierarchical worker spawning contracts (sprint 08 task 07):

  - `spawn_subworker` MCP tool schemas (`SpawnSubworkerInputSchema`,
    `SpawnSubworkerOutputSchema`, `SubworkerRoleSchema`,
    `SwarmBudgetRejectReasonSchema`) in `schemas/tools/spawn.ts`.
  - `queen.execution.worker_spawn` WS event extended with optional
    `parent_worker_id` + `depth` so the desktop can render the swarm tree.
  - New `swarm.budget_rejected` WS event (`reason: "max_depth" | "max_nodes"`)
    emitted when a spawn would breach the depth-3 / 64-node caps.

  Consumers (swarmade-queen) currently mirror the tool shapes locally pending
  this release (TD-SHARED-HIERARCHICAL-WS-WIRING, CLAUDE.md §11.4).
@swarmade-workspace/shared0.10.0Add the File Lock Manager contract (`src/schemas/file-lock.ts`, sprint 08 task 06): `AcquireSchema` / `AcquireResultSchema` (granted | queued | deadlock_resolved discriminated union), `ReleaseSchema` / `ReleaseResultSchema`, `PreviewConflictsSchema` / `ConflictPairSchema` (read-only conflict probe for the Group Refiner, task 08-02), `LineRangeSchema` (file-level when omitted, section-level `[start, end]` when present), the `fileLockGrantChannel` Redis helper + `FileLockGrantSchema` envelope, and the `file_lock.deadlock_resolved` / `lock.stale` monitoring event channels + `FILE_LOCK_STALE_TTL_MS`. Adds `EventName.FileLockDeadlockResolved` and `EventName.LockStale`.
Add the File Lock Manager contract (`src/schemas/file-lock.ts`, sprint 08 task 06): `AcquireSchema` / `AcquireResultSchema` (granted | queued | deadlock_resolved discriminated union), `ReleaseSchema` / `ReleaseResultSchema`, `PreviewConflictsSchema` / `ConflictPairSchema` (read-only conflict probe for the Group Refiner, task 08-02), `LineRangeSchema` (file-level when omitted, section-level `[start, end]` when present), the `fileLockGrantChannel` Redis helper + `FileLockGrantSchema` envelope, and the `file_lock.deadlock_resolved` / `lock.stale` monitoring event channels + `FILE_LOCK_STALE_TTL_MS`. Adds `EventName.FileLockDeadlockResolved` and `EventName.LockStale`.

  These are the single source of truth for the lock wire shape across `swarmade-api` (lock manager service + internal REST surface) and `swarmade-queen` (the `FileLockClient` exposed as the `file_lock_acquire` / `file_lock_release` MCP tools).
@swarmade-workspace/shared0.10.0Add `output_paths` to `TaskNodeSchema` (repo-relative paths a task creates/modifies; optional, defaults to `[]`) so the Queen scheduler can detect write-conflicts between parallel siblings and the executor can scope each Worker's diff (TD-08-02-4).
Add `output_paths` to `TaskNodeSchema` (repo-relative paths a task creates/modifies; optional, defaults to `[]`) so the Queen scheduler can detect write-conflicts between parallel siblings and the executor can scope each Worker's diff (TD-08-02-4).

  Add a canonical wikilink/tag extractor — `extractLinks`, `createSlugMap`, `LINK_RE` plus the `LinkRef` / `TagRef` / `LinkExtractionResult` / `ResolveFn` types — so swarmade-memory and swarmade-desktop stop maintaining duplicate copies (TD-MEM-10-1). Supports `[[target]]` / `[[target|alias]]` links and `#tag` references, masking fenced (``` / ~~~) code blocks, inline code, and HTML comments.
@swarmade-workspace/shared0.9.0feat(schemas): add Mailbox MCP tool contract (sprint 08 task 05)
feat(schemas): add Mailbox MCP tool contract (sprint 08 task 05)

  Adds `src/schemas/tools/mailbox.ts` with the tool-surface I/O shapes for the
  three inter-Worker Mailbox MCP tools: `MailboxSendInputSchema` /
  `MailboxSendOutputSchema`, `MailboxReadInputSchema` /
  `MailboxReadOutputSchema`, and `MailboxBroadcastInputSchema` /
  `MailboxBroadcastOutputSchema`. These are a narrower projection of the
  transport contract in `mailbox.ts` (the Worker never supplies `hive_id` /
  `from_worker_id` — the Queen injects them from the tool context) and reuse the
  canonical bounds (`MAILBOX_CONTENT_MAX`, `MAILBOX_TOPIC_REGEX`, the read-limit
  pair) so the tool surface and the persistence contract cannot drift. Consumed
  by `swarmade-queen` (the `mailbox_*` tools registered in the Queen ToolRegistry).
@swarmade-workspace/shared0.8.0feat(schemas): add Shared Mailbox contract (sprint 08 task 04)
feat(schemas): add Shared Mailbox contract (sprint 08 task 04)

  Adds `MailboxMessageSchema`, `PostMessageSchema`, `ReadFilterSchema`,
  `SubscribeSchema`, `UnsubscribeSchema`, `MarkReadSchema` plus the
  `MailboxContentFormatSchema` enum and the `mailbox*Channel` Redis-channel
  helpers. These are the single source of truth for the inter-Worker Mailbox
  wire shape consumed by `swarmade-api` (HTTP boundary + DB write validation)
  and `swarmade-queen` (`MailboxClient`, exposed as an MCP tool in task 08-05).
@swarmade-workspace/shared0.7.0feat(schemas): add Worker assignment contract for the Queen scheduler
feat(schemas): add Worker assignment contract for the Queen scheduler

  Adds `AssignmentSchema` (one assignment per task: `cli_bridge_id`, `worker_id`,
  `model_role`, `cost_mode`, `selection_log`), `SelectionLogSchema` +
  `SelectionLogCandidateSchema` (the audit trail of every scored candidate bridge
  with its score + signal breakdown, the chosen bridge, and an optional
  `reasoning` code), and `CostModeSchema` (`subscription` | `credits` | `api`).
  These back the weighted CLI-bridge selection policy (Queen task 08-03) and the
  `worker_runs.selection_log_json` audit column.

  Until this publishes as the next shared minor, swarmade-queen mirrors these
  shapes locally (see [TD-SCHEDULER-ASSIGNMENT-SHARED-PUBLISH]); the mirror
  collapses to a direct re-export once consumed.
@swarmade-workspace/shared0.6.0feat(schemas): add ScheduledGroup refinement contract for the Queen scheduler
feat(schemas): add ScheduledGroup refinement contract for the Queen scheduler

  Adds `ScheduledGroupSchema` (a `TaskGroup` enriched with `cli_bridge_hint` and
  `serialisation_hints`), plus `SerialisationHintSchema` and
  `SerialisationReasonSchema` (`file_overlap` | `section_overlap`). These back the
  parallelism-group refinement pass (Queen task 08-02): the 16-Worker cap split,
  the per-group CLI bridge hint, and the advisory file-contention preview.

  `ExecutionPlanSchema.groups` now carries `ScheduledGroup[]` instead of the raw
  `TaskGroup[]`, so the public ExecutionPlan always exposes refined groups.
  Readers of `index` / `task_ids` / `max_parallelism` are unaffected (ScheduledGroup
  extends TaskGroup); only constructors of an ExecutionPlan must now supply the two
  new group fields — today only `swarmade-queen`'s SchedulerService does.

  Until this publishes as [email protected], swarmade-queen mirrors these shapes locally
  (see [TD-SCHEDULER-SCHEDULED-GROUP-SHARED-PUBLISH]); the mirror collapses to a
  direct re-export once consumed.
@swarmade-workspace/shared0.5.0Add `ExecutionPlanSchema` and `TaskGroupSchema` (+ derived `ExecutionPlan`,
Add `ExecutionPlanSchema` and `TaskGroupSchema` (+ derived `ExecutionPlan`,
  `TaskGroup` types) for the Queen pipeline Pass 3 (algorithmic scheduling,
  sprint-08 task 08-01). An `ExecutionPlan` is what `swarmade-queen`'s
  `SchedulerService.plan(dag)` emits: ordered parallelism `groups[]`, the
  weighted `critical_path_task_ids[]`, `total_estimated_duration_sec`, and a
  stable `plan_hash` (SHA-256 over the canonicalised graph identity) the
  Replanner (08-09) uses to detect plan identity across replan attempts.

  Per-task ids use the `/^T[0-9]+$/` regex (matching `TaskNodeSchema.id`),
  while `plan_id`/`dag_id` are UUIDs (the DAG envelope `plan_id`).

  Consumers (`swarmade-queen`, later `swarmade-desktop` Plan View) bump to pick
  up the new schemas. Until this release publishes, `swarmade-queen` mirrors the
  schema locally in `src/modules/scheduler/types.ts` (tracked as
  [TD-SCHEDULER-SHARED-PUBLISH], auto-resolves on the next shared release +
  queen bump — collapse the local mirror to a re-export).

Thursday, May 28, 2026

@swarmade-workspace/shared0.4.0Refresh the generated `api-client` types from the current `swarmade-api`
Refresh the generated `api-client` types from the current `swarmade-api`
  OpenAPI document. The committed `openapi.json` mirror had drifted from
  the real API contract, turning the `api-client-drift` CI job red.

  Surface changes in the regenerated `paths`/`operations`/`components`:

  - Add the `GET /v1/admin/honey/reservations`
    (`AdminHoneyController_listReservations`) endpoint.
  - Enrich `InvokeRequestDto`: `tools` is now a typed
    `{ name; description; parameters }[]` instead of `unknown[]`, plus new
    optional `plan_id`, `task_id`, `prompt_version`, `experiment_id`, and
    `variant` fields.
  - Drop the phantom `GET /v1/health` (`CommonController_health`) path,
    which never existed in the real API (live routes are `/healthz` and
    `/readyz`, excluded from the `/v1` prefix).

  No hand edits — `src/api-client/schema.ts` and `openapi.json` were
  regenerated via `pnpm gen:api` against a fresh `swarmade-api`
  `openapi:dump`. Consumers (`swarmade-desktop`, `swarmade-queen`,
  `swarmade-api`) pick up the corrected client on their next bump.
@swarmade-workspace/shared0.4.0Add `bridge_not_implemented` to `WorkerFailureReasonSchema` (sprint 07
Add `bridge_not_implemented` to `WorkerFailureReasonSchema` (sprint 07
  task 14). The desktop CLI bridge registry ships stub bridges for
  `cline`, `goose`, and `cursor` whose lifecycle methods throw a
  `BridgeNotImplementedError`. The desktop WorkerCoordinator maps that
  throw to `worker.task_failed { reason: "bridge_not_implemented",
details: <cli> }` so the Queen Plan View can render a "Switch CLI to
  Claude Code and retry" CTA instead of a generic `spawn_failed`.

  Consumers (`swarmade-queen`, `swarmade-desktop`) bump to pick up the new
  reason. Until then the desktop coordinator keeps emitting the existing
  `spawn_failed` reason for stub bridges (tracked as
  [TD-SHARED-ENUM-WIRING], auto-resolves on the next shared release +
  desktop bump).
@swarmade-workspace/shared0.3.0Add CLI bridge contracts + worker inbound frame schemas required by
Add CLI bridge contracts + worker inbound frame schemas required by
  sprint 07 task 11 (worker execution loop):

  - `cli-bridge` — `SpawnOptsSchema`, `WorkerHandleSchema`,
    `DiffFileSchema`, `DiffResultSchema`, `DiffSummarySchema`,
    `WorkerFailureReasonSchema`. Contract every desktop CLI bridge
    implements (claude-code, codex, opencode, aider …) when the Queen
    executor dispatches a Worker.
  - `queen-ws-events` — `queen.execution.worker_spawn` now carries
    `prompt`, `env`, and `timeout_ms` so the desktop bridge has
    everything it needs without a second round-trip. New
    `queen.execution.cancel` event for server → client termination
    requests.
  - `queen-ws-events` — new `WorkerInboundFrameSchema` discriminated
    union for client → server frames (`worker.output`,
    `worker.task_done`, `worker.task_failed`). Kept as a separate union
    (not merged into `WSEventSchema`) so a malicious client cannot spoof
    server-only event types like `queen.honey.deducted`.

  Consumers (`swarmade-queen`, `swarmade-desktop`, `swarmade-api`) must
  bump their dependency to pick up the new exports.
@swarmade-workspace/shared0.3.0Extend `queen.honey.deducted` WS event with optional `plan_id` and
Extend `queen.honey.deducted` WS event with optional `plan_id` and
  `task_id` attribution fields (task 07-08).

  When the LLM call originates from a Queen plan, the meter now propagates
  `plan_id` (uuid) and `task_id` (`T<N>`) on the published event so the
  desktop plan view can attribute per-task Honey burn live. Both fields
  are optional — existing producers that don't tag invocations remain
  wire-compatible.

  Consumers must run `pnpm i` to pick up the new optional fields.
@swarmade-workspace/shared0.3.0Add Queen orchestrator schemas required by sprint 07 consumers
Add Queen orchestrator schemas required by sprint 07 consumers
  (`swarmade-queen`, `swarmade-api`, `swarmade-desktop`):

  - `queen-plan` — `PlanStatusSchema` (9-state lifecycle enum) +
    `PlanSchema` for the DB-shape Plan record (id, hive_id, user_id,
    status, spec_md_hash, current_dag_id, timestamps).
  - `queen-worker` — `CliBridgeIdSchema` + `WorkerStatusSchema` +
    `WorkerAssignmentSchema` describing how a DAG node is bound to a
    concrete CLI process (task_id, worker_id, cli, model, working_dir,
    status, lifecycle timestamps).
  - `queen-ws-events` — `WSEventSchema` discriminated union over the 12
    canonical `queen.*` WebSocket / SSE events (plan started / thought /
    task_added / clarifying_questions / resumed / complete / failed,
    execution worker_spawn / worker_output / task_done / task_failed,
    honey.deducted). Every variant carries a UUIDv7 `event_id` and ISO
    `timestamp`.
  - `constants/cli-bridges` — new `CLI_BRIDGE_IDS` tuple (alongside the
    existing `CLI_IDS`) using the `claude-code` identifier that matches
    the bridge package in `swarmade-queen/src/bridges/`.

  Consumers must run `pnpm i` after upgrade to pick up the new types.

Monday, May 25, 2026

@swarmade-workspace/shared0.3.0Add `@swarmade-workspace/shared/api-client` subpath. A `createApiClient(opts)`
Add `@swarmade-workspace/shared/api-client` subpath. A `createApiClient(opts)`
  factory returns a typed `openapi-fetch` client over the swarmade-api OpenAPI
  3.1 spec — misspelling a path becomes a compile error, request and response
  bodies are inferred from the live spec, and consumers can hot-swap to a Tauri
  HTTP plugin via `opts.fetch`. The spec is regenerated by `pnpm gen:api` and a
  CI drift check (`pnpm check:api-client-drift`) prevents publishing a stale
  client.

Sunday, May 24, 2026

@swarmade-workspace/shared0.3.0Add `@swarmade-workspace/shared/test-config` subpath export carrying the
Add `@swarmade-workspace/shared/test-config` subpath export carrying the
  shared Vitest baseline (`baseVitestConfig`, threshold presets, coverage
  exclude list). Consumers spread it into their own `defineConfig({...})` to
  get consistent v8 coverage reporters, threshold floors per workspace
  CLAUDE.md §13.1, and a single source of truth for what to ignore.

Undated

@swarmade-workspace/shared0.1.0Initial scaffold of `@swarmade-workspace/shared`: placeholder Zod schemas for `User`,
Initial scaffold of `@swarmade-workspace/shared`: placeholder Zod schemas for `User`,
  `Hive` (+ `CreateHive`), and `Task` (+ `TaskStatus`); `EventName` constant map
  for cross-process event names; placeholder files for `honey`, `drone`, `llm`,
  `billing` schemas and `plans`, `drones`, `cli-bridges` constants. Dual ESM+CJS
  build via tsup with `.d.ts` emit. Zero runtime side effects on import.