Commit Graph

4512 Commits

Author SHA1 Message Date
Fusion
65a9371d31 feat(FN-3505): add node onboarding mapping flow with asset-gated bundling
- Add onboarding project-mapping API contracts and dashboard UI wiring in AddNodeModal/NodesView
- Persist node-to-project mappings with rollback-safe failure handling and expanded hook/API test coverage
- Document node onboarding mapping behavior in architecture and multi-project docs
- Add tsup bundle asset gates for openclaw bridge and droid runtime, with changesets and bundle output tests

Fusion-Task-Id: FN-3505
2026-05-07 19:29:54 -07:00
Fusion
84a34a062c feat(FN-3718): add droid runtime to tsup bundle with asset gate
Stages the droid runtime as a bundled plugin in the CLI's tsup configuration, gates the bundle bootstrap on droid asset availability, and adds tests asserting correct staging behavior in bundle output.

Fusion-Task-Id: FN-3718
2026-05-07 19:17:52 -07:00
Fusion
63a14fe7a5 feat(FN-3717): gate bootstrap on openclaw bridge asset
Stabilizes the OpenClaw bundle by hardening the asset copy logic and gating the bootstrap flow on the openclaw bridge asset being present, with regression tests covering the new bundle-output helpers and a patch changeset for `@runfusion/fusion`.

Fusion-Task-Id: FN-3717
2026-05-07 19:00:19 -07:00
Fusion
01aa2681f0 feat(FN-3504): add path mapping API with core contracts, routes, client hel
This merge introduces three major features: a full path-mapping API layer across core, dashboard, and desktop (FN-3504, four commits), shell multi-profile support with a new NativeShellConnectionManager component and connection manager onboarding flow (FN-3403), and migration of the WhatsApp plugin

Fusion-Task-Id: FN-3504
2026-05-07 18:47:08 -07:00
Fusion
7b9e5259d3 feat(FN-3403): add shell multi-profile support with connection manager onbo
Merges shell multi-profile support for desktop (FN-3403) — spanning new connection-manager flows, shell onboarding interoperability, mobile connection profiles, desktop IPC/shell-settings plumbing, and tokenized titlebar styles — with a secondary migration of the WhatsApp plugin to the Baileys pairi

Fusion-Task-Id: FN-3403
2026-05-07 18:35:45 -07:00
Fusion
a3572156e3 feat(FN-3713): remove legacy webhook key references from schema test
Cleans up legacy webhook key references from the schema test file, removing outdated assertions that referenced deprecated fields.

Fusion-Task-Id: FN-3713
2026-05-07 18:29:54 -07:00
Fusion
ef7efd0c96 feat(FN-3713): migrate WhatsApp plugin to Baileys pairing flow
- Add Baileys-based connection/auth modules and pairing route support for QR, pair code, status, and logout
- Refactor plugin entrypoint and split reply/auth/connection logic into focused modules
- Update plugin metadata/docs/settings schema to pairing-era configuration and remove legacy webhook key usage
- Add targeted tests for auth state, connection handling, reply flow, and updated schema expectations

Fusion-Task-Id: FN-3713
2026-05-07 18:26:14 -07:00
Fusion
2e3be32f1b feat(FN-3560): add permanent agent gating enforcement in pi with tool class
The merge lands three major features: a permanent-agent gating system (FN-3560, 6 steps) that classifies and enforces tool access policies for permanent agents in the PI extension, with full test coverage and updated agent docs; an OpenClaw MCP bridge (FN-3717) adding MCP config, schema server, and

Fusion-Task-Id: FN-3560
2026-05-07 18:07:12 -07:00
Fusion
836ca6807a feat(FN-3717): add OpenClaw MCP bridge (+5 more)
Commits merged:
- docs(FN-3717): update openclaw runtime and settings docs
- test(FN-3717): fix openclaw engine test typing
- test(FN-3717): strengthen openclaw bridge coverage
- feat(FN-3717): complete Step 2 — wire engine and bundle delivery
- fix(FN-3717): address openclaw bridge review feedback
- feat(FN-3717): complete Step 1 — add OpenClaw MCP bridge

Files changed:
.changeset/fn-3717-openclaw-tool-bridge.md         |  5 ++
 docs/settings-reference.md                         | 28 +++++---
 packages/cli/src/__tests__/bundle-output.test.ts   |  9 +++
 packages/cli/tsup.config.ts                        |  7 ++
 .../src/__tests__/openclaw-runtime-e2e.test.ts     | 28 ++++++++
 .../__tests__/openclaw-runtime-integration.test.ts | 10 +++
 plugins/fusion-plugin-openclaw-runtime/README.md   | 13 ++++
 .../src/__tests__/cli-spawn.test.ts                | 82 +++++++++++++++++++---
 .../src/__tests__/mcp-config.test.ts               | 45 ++++++++++++
 .../src/__tests__/runtime-adapter.test.ts          | 46 ++++++++++++
 .../fusion-plugin-openclaw-runtime/src/index.ts    |  5 ++
 .../src/mcp-config.ts                              | 60 ++++++++++++++++
 .../src/mcp-schema-server.cjs                      | 59 ++++++++++++++++
 .../src/pi-module.ts                               | 52 ++++++++++++--
 .../src/runtime-adapter.ts                         | 26 +++++++
 .../fusion-plugin-openclaw-runtime/src/types.ts    |  4 ++
 16 files changed, 457 insertions(+), 22 deletions(-)

Fusion-Task-Id: FN-3717
2026-05-07 18:00:18 -07:00
Fusion
c32999b293 feat(FN-3394): add evals dashboard view with API routes and client hooks
Adds a full evals dashboard view (FN-3394) with a client hook, server-side read routes, and navigation integration across the Header and mobile nav, backed by comprehensive tests. Wires Hermes chat message tools with mailbox behavior documentation (FN-3620), and extends the agent heartbeat and tools

Fusion-Task-Id: FN-3394
2026-05-07 17:24:11 -07:00
Fusion
d5ee17759a feat(FN-3620): wire Hermes chat message tools and document mailbox behavior
Merges FN-3620, completing the Hermes chat mailbox integration with wired message tools, locked sender/recipient contract tests, and mailbox behavior documentation, plus a small CSS polish adding `focus-visible` styles and token radius to the render toggle. A changeset for FN-3710 (cluster task ID o

Fusion-Task-Id: FN-3620
2026-05-07 16:53:55 -07:00
Fusion
240421419f feat(FN-3710): add planning mode priority controls and agent workspace memo
Adds an agent workspace memory reader so agents can access workspace context, and extends the planning mode modal with priority controls for task routes and subtasks (FN-3716, FN-3718). Minor CSS token and mobile focus fixes are also included (FN-3710).

Fusion-Task-Id: FN-3710
2026-05-07 16:47:57 -07:00
Fusion
324ab5d44e feat(FN-3718): add agent workspace memory reader and include workspace memo
Merged branch lands two features: FN-3718 wires workspace memory into the agent instruction pipeline — adding a reader helper, injecting workspace memory into agent instructions and identity snapshots, and documenting the resolution order — and FN-3716 adds planning mode priority controls for task r

Fusion-Task-Id: FN-3718
2026-05-07 16:09:35 -07:00
Fusion
c6d12ba5af feat(FN-3716): add planning mode priority controls for task routes and subt
Adds per-subtask priority controls to planning mode with three implementation steps (route priority support, UI controls, and design-token polish), gates research tools behind an experimental feature flag with a new core infrastructure module, and introduces a WhatsApp chat plugin with discovery and

Fusion-Task-Id: FN-3716
2026-05-07 16:03:25 -07:00
Fusion
aaaebdcb0d feat(FN-3706): gate research tools behind experimental feature
The merge introduces a research tool surface gating mechanism: shared availability helpers in core and engine, applied to the executor and triage agent so research prompts and tool exposure are gated behind experimental-feature flags, with tests covering the new logic.

Fusion-Task-Id: FN-3706
2026-05-07 15:53:58 -07:00
Fusion
e3daa7b3b9 feat(FN-3714): add WhatsApp chat plugin with plugin discovery and install U
Adds a WhatsApp chat plugin (`plugins/fusion-plugin-whatsapp-chat/`) as the first bundled plugin, including the plugin package with UI rendering, dashboard plugin manager integration, CLI bundling support, and plugin route runtime context. Also updates documentation to cover plugin management and ap

Fusion-Task-Id: FN-3714
2026-05-07 14:28:29 -07:00
Timothy Laurent
f0c9592c08 fix(dashboard): address PR review feedback for model filtering and insights
- Always apply configured-provider filter (even when empty set)
- Convert getConfiguredProviderNames to async (fs/promises)
- Validate model overrides as non-empty provider+model pair
- Clear stale persisted insight model when no longer available
- Replace hardcoded max-height with design token in overflow menu

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:10:45 -07:00
Timothy Laurent
17c9da0732 feat(insights): model selector with favorites, provider filtering, and configured-providers-only API
- Wire up CustomModelDropdown in InsightsView with favorites support:
  favoriteProviders, favoriteModels, and toggle callbacks
- Auto-promote resolved planning provider as implicit favorite when
  no explicit favorites are set
- Filter /models API to only return providers with credentials in
  Fusion's own auth stores (primary + legacy .pi + models.json),
  excluding supplemental stores (Codex CLI, Claude Code, env vars)
  that surface unconfigured providers
- Still allow enabled extension providers (Claude CLI, Droid CLI,
  llama.cpp) when their settings toggles are on

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:10:45 -07:00
Timothy Laurent
4dfffaf14c fix(insights): fetch models internally so model dropdown is populated
InsightsView accepted a models prop that was never passed from App.tsx.
Now fetches models via fetchModels() on mount (same pattern as ChatView),
falling back to the prop if provided.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:10:45 -07:00
Timothy Laurent
97b3727a3a fix(settings): prevent project-level global keys from overriding global settings
getSettingsFast() and getSettings() spread project-level settings over
global settings without filtering by scope. A stale project-level
experimentalFeatures: {} in SQLite would override the global
experimentalFeatures: { insights: true, ... }, making all experimental
features invisible in the dashboard.

Now both methods strip global-only keys from project settings before
the merge, matching the behavior of getSettingsByScopeFast().

Also adds max-height and overflow-y to the overflow dropdown menu.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:10:45 -07:00
Timothy Laurent
c2b01ffab1 test(api): add triggerInsightRun model params tests
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:10:44 -07:00
Timothy Laurent
99bfc6b54f fix(insights): preserve custom model selection across retries
Stores modelProvider/modelId in the run's inputMetadata.metadata at
creation time, then recovers it in the retry handler so the user's
explicit model choice survives a transient failure and retry.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:10:44 -07:00
Timothy Laurent
d1a192aa6a fix(insights): validate localStorage model values and tighten fallback condition
- Guard against malformed localStorage values (e.g. "provider/") by
  validating both parts are non-empty before sending to the server
- Only wire settings fallback when both provider AND modelId are
  explicitly provided, preventing mismatched provider/modelId combos

Addresses ISSUE-002 and ISSUE-003 from code quality review.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:09:39 -07:00
Timothy Laurent
f7080fef6a feat(insights): add collapsible model selector to InsightsView with gear trigger
Adds a Settings gear button to the InsightsView action bar that toggles a
collapsible model configuration row. The row contains a CustomModelDropdown
allowing users to override the insight generation model. Selections persist
to localStorage under the "fusion-insight-model" key. A yellow indicator dot
appears on the gear when a non-default model is active.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:09:39 -07:00
Timothy Laurent
1f5e928d7c feat(insights): thread model selection through useInsights hook
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:09:39 -07:00
Timothy Laurent
c7963e8e29 feat(api): add optional model params to triggerInsightRun
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:09:38 -07:00
Timothy Laurent
3557d4b34f feat(insights): accept optional model override in POST /run with settings fallback; fix retry handler
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-07 14:09:38 -07:00
Fusion
6b435eba0e feat(FN-3712): document approval policy runtime and architecture contracts
Adds documentation for the approval architecture and runtime policy contract to `docs/architecture.md` and `docs/agents.md` (FN-3712).

Fusion-Task-Id: FN-3712
2026-05-07 14:06:53 -07:00
Fusion
667761a88a feat(FN-3547): add runtime action classification and gating system for agen
Merged seven commits that introduce a runtime action gate for task execution (FN-3547) — adding action classification, git-based heuristics for branch/remote gating, and per-step session enforcement — with tests covering the gate logic, heartbeat integration, and PI agent creation. Also landed FN-37

Fusion-Task-Id: FN-3547
2026-05-07 13:52:43 -07:00
Fusion
7b6bc2e531 feat(FN-3711): consolidate graph position storage and remove scopedStorage
Consolidated graph position storage into a canonical shared helper (`projectStorage.ts`) with hardened persistence logic and removed the duplicate `scopedStorage` module. Updated integration tests and documented the canonical storage approach. A smaller fix (`FN-3628`) addressed mobile touch targets

Fusion-Task-Id: FN-3711
2026-05-07 13:29:26 -07:00
Fusion
4f495fcc77 feat(FN-3628): fix chat mobile touch targets and token consistency
The merge brings a mobile accessibility fix to ChatView, improving touch target sizing and aligning CSS token usage with the dashboard's design system conventions.

Fusion-Task-Id: FN-3628
2026-05-07 13:27:50 -07:00
Fusion
15371e6c1d feat(FN-3557): add draft-apply save/cancel confirmations and SQLite approva
Merges a substantial cross-cutting batch: approval request persistence with a SQLite store (FN-3546), branch/baseBranch fields added to the task schema (FN-3429), project-node path mapping APIs and storage layer (FN-3428/FN-3503), draft-to-form unification and interview close/confirmation boundaries

Fusion-Task-Id: FN-3557
2026-05-07 13:11:37 -07:00
Fusion
3f7aedd4fd feat(FN-3546): add approval request persistence layer with SQLite store and
Merged branches introduce an approval-request persistence layer (FN-3546) with a new `ApprovalRequestStore` in core, schema v68 with audit history support, and updated dashboard task/API tests, alongside a minor task-schema extension (FN-3429) adding `branch`/`baseBranch` fields to the task model an

Fusion-Task-Id: FN-3546
2026-05-07 13:05:03 -07:00
Fusion
dcead400c9 feat(FN-3429): add branch and baseBranch fields to task schema
Adds a changeset for feature FN-3429 to track the branch/baseBranch task fields, marking this work for the next `@runfusion/fusion` release.

Fusion-Task-Id: FN-3429
2026-05-07 12:59:11 -07:00
Fusion
19584fcdee feat(FN-3428): add project-node path mapping APIs and agent detail review-b
Merges FN-3428's branch-field contract and merge target override/default behavior tests across core, dashboard, and engine, plus a companion fix that sweeps subsumed autostash orphans and surfaces outcomes on the task feed. Adds project-node path mapping persistence APIs and schema (FN-3503), new ag

Fusion-Task-Id: FN-3428
2026-05-07 12:47:33 -07:00
gsxdsm
1473608833 fix(merger): sweep subsumed autostash orphans and surface outcomes on task feed
Autostash entries from prior runs piled up indefinitely (50+ on a single
working tree) because every silent restore failure (apply hard-fails on
untracked-overwrite, transient git error, etc.) leaves a permanent stash
and the warn-only behavior trains developers to ignore the warnings.

- Add `sweepAutostashOrphans`, called at merge entry: classifies each
  orphan by diffing its stashed paths against HEAD. If every path is
  byte-identical to HEAD the dev's work has already landed, so drop the
  stash automatically. Live orphans (real lost work) get loud warnings
  on both the engine log and the task feed.
- Surface every restore terminal outcome (`restored`, `failed`,
  `conflict-needs-manual` from each path) via `store.logEntry` so devs
  can see in `fn task show` what happened to their stash without
  grepping engine logs.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-07 12:39:15 -07:00
Fusion
b434cc2d38 feat(FN-3503): add project-node path mapping persistence APIs and schema
Adds project-node path mapping infrastructure in the core database layer (schema, migration backfill, and persistence APIs in `central-core.ts` and `central-db.ts`) with accompanying documentation. Also introduces a review-before-apply draft gate for agent onboarding and the agent detail view's mail

Fusion-Task-Id: FN-3503
2026-05-07 12:36:09 -07:00
Fusion
ad5bed22f8 feat(FN-3708): add tests for TodoModal lazy props
Adds test coverage for TodoModal's lazy-loaded prop handling, completing the second step of the FN-3708 test work.

Fusion-Task-Id: FN-3708
2026-05-07 12:30:18 -07:00
gsxdsm
ae97fca340 fix(test-isolation): allow-list known isolated HOMEs to stop FN-3711-style flakes
The leak guard in scripts/check-test-isolation.mjs reported
fusion-test-home-root-* dirs created by scripts/test-changed.mjs as
leaks when transient EBUSY on /var/folders prevented cleanup or the
baseline file got rotated. Track every HOME basename the script mints
and pass it via FUSION_TEST_ISOLATION_IGNORE_NAMES so the check
allow-lists them unconditionally. Surface cleanup rm failures via
console.warn instead of swallowing.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-07 12:25:45 -07:00
Fusion
c92eebc5c3 feat(FN-3701): add agent detail mail tab and review-before-apply flow to ag
The merge adds a mail tab to the agent detail view in the dashboard (with wiring and documentation), implements a review-before-apply draft gate in the experimental agent onboarding modal, and introduces an opt-in web builtin tool for AI agents with engine and CLI reference updates.

Fusion-Task-Id: FN-3701
2026-05-07 12:24:54 -07:00
Fusion
73dd8e8923 feat(FN-3465): add review-before-apply flow to agent onboarding modal, fix
Adds a review-before-apply flow to the Experimental Agent Onboarding Modal with an explicit draft review gate, updating the modal component and its co-located CSS, plus test coverage. Also corrects the focus ring token used in the ChatView session delete action.

Fusion-Task-Id: FN-3465
2026-05-07 12:18:45 -07:00
Fusion
0cfc160bd6 feat(FN-3556): add review-before-apply flow with explicit draft review gate
This merge adds an agent permission policy model with persistence (FN-3545), an explicit draft review gate for task workflow steps (FN-3556), web builtin tool opt-in for AI agents (FN-3713), an inline fast mode toggle wired into peer execution (FN-3711), and a retry mechanism for overlapping task ID

Fusion-Task-Id: FN-3556
2026-05-07 12:12:54 -07:00
Fusion
80cf5f7345 feat(FN-3713): add web builtin tool opt-in for AI agents
Added agent permission policy model with persistence in core, and wired web-builtin tool opt-in enabling planning and synthesis web tools in the dashboard with corresponding docs and a changeset. Also added an inline fast-mode toggle wired into peer executor state, retry logic for cluster task-ID ov

Fusion-Task-Id: FN-3713
2026-05-07 12:06:49 -07:00
Fusion
c177a526fc feat(FN-3545): add agent permission policy model and persistence
Introduces a multi-agent permission policy model in `@fusion/core` (types, store persistence, API exposure) with corresponding dashboard UI wiring in the agent onboarding modal and task detail modal, plus a distributed task ID overlap retry mechanism for cluster creation, an inline fast mode toggle

Fusion-Task-Id: FN-3545
2026-05-07 12:00:43 -07:00
Fusion
cc02def488 feat(FN-3711): add inline fast mode toggle and wire shared state in peer ex
This merge introduces several dashboard and engine improvements: agent inbox wake controls (FN-3087, FN-3588) with immediate message triggers; separated plugin lifecycle from setup probe state (FN-3704); assigned-agent triage inheritance in the engine (FN-3703); inline fast mode toggle in the task d

Fusion-Task-Id: FN-3711
2026-05-07 11:54:41 -07:00
Fusion
24325cd3c1 feat(FN-3710): retry overlap-class cluster create failures in distributed t
Adds retry logic for distributed task ID overlap conflicts across the cluster, hardening the ID allocator with exponential-backoff recovery, wiring the retry into task workflow registration, and documenting the behavior in architecture docs. Minor CSS tokenization on the Mailbox and Plugin Manager m

Fusion-Task-Id: FN-3710
2026-05-07 11:48:25 -07:00
Fusion
a98e5aac1a feat(FN-3712): add provider response copy action to chat bubble
The merge delivers four distinct features: a copy-to-clipboard action on provider responses in the chat bubble (FN-3712, with styling and tests across ChatView), richer agent onboarding drafts documented and wired into the dashboard onboarding modal (FN-3555), assigned-agent triage inheritance so ag

Fusion-Task-Id: FN-3712
2026-05-07 11:41:01 -07:00
Fusion
e60c8c3c5a feat(FN-3555): document richer onboarding drafts in agents.md and dashboard
Documents richer onboarding drafts in agents.md and updates the dashboard README with a small addition, completing Step 4 of the onboarding feature.

Fusion-Task-Id: FN-3555
2026-05-07 11:25:01 -07:00
Fusion
f43b68dd6f feat(FN-3703): implement assigned-agent triage inheritance in engine and tr
Implements assigned-agent triage inheritance (FN-3703), allowing triage logic to be delegated to the assigned agent rather than always routing through the original owner, with test coverage and documentation. Also adds immediate wake controls for agent inbox and message API (FN-3087), wires shared s

Fusion-Task-Id: FN-3703
2026-05-07 11:18:56 -07:00
Fusion
29692dbbcc feat(FN-3464): wire shared state in peer exchange service (FN-3464 Step 1)
Merges peer exchange shared state wiring (FN-3464) into the engine with updated tests, adds immediate wake controls for agent inbox and message API (FN-3087), and restores the narrow logs/system mouse auto-toggle policy with CLI documentation (FN-3708). Dependency graph plugin receives test and high

Fusion-Task-Id: FN-3464
2026-05-07 11:15:27 -07:00