Commit Graph

109 Commits

Author SHA1 Message Date
shumeiko.it
c2998f1a6b fix(web): say when the primary model has no key and which model chats use (UF-054)
Settings showed the configured primary while the status bar showed the
model new chats fall back to, so the two screens disagreed. Model Pilot now
says the primary needs a key and names the model in use.
2026-10-27 14:20:05 +01:00
shumeiko.it
97b2c984d8 refactor(web): drop the team agent tab and team memory scopes (P1.1)
Team mode is out of the community edition, but Agents still offered a Team
tab, a team agent type and team / organization memory scopes.
2026-10-27 14:17:25 +01:00
shumeiko.it
f3c48e6f19 fix(web): square the user's chat bubble at the top right (UF-053)
User messages sit on the right, but the bubble's one square corner was the
top left, pointing away from the sender.
2026-10-27 13:15:57 +01:00
shumeiko.it
da574a5a7e feat(web): tighten the calm design after its anti-slop audit
Fixes items 3-11 of anti-slop/audit-002, all scoped to data-design=calm:
- no colored edges on Model Pilot rows, a connected extension or the
  active file workspace;
- section labels and eyebrows in the text face, mono for data only;
- one accent: honey text, washes and hover lines turn neutral, honey stays
  on primary buttons, the switch, focus and attention counts;
- dots with no state behind them are hidden and live dots no longer pulse;
- no card shadow or hover lift, including the --shadow token;
- inline-style gradients go solid or flat, glows go;
- no entrance motion: framer-motion animations finish instantly and the
  inline card-enter and scroll reveals are off;
- stock Tailwind hues map onto Hive status tokens, mixed toward --text so
  small status text keeps 4.5:1 in light;
- radii follow the 6 / 10 / 14 scale, text pills become chips.

The classic design is unchanged.
2026-10-27 12:55:02 +01:00
shumeiko.it
ef99f04c5b fix(web): stop offering the Start here workspace twice on Home (UF-052)
"Pick up where you left off" listed every recent workspace, including the
one the Start here card already offers. The list now leaves it out and
hides when nothing else is left.
2026-10-27 12:54:54 +01:00
shumeiko.it
b3b61e14c9 fix(server): close the memory recall step when nothing is found or recall fails (UF-051)
Only a successful recall reported its outcome, so an empty or failed
recall left "Recalling relevant memories..." as the last step after the
answer. Both cases now send a closing step and the turn goes on.
2026-10-27 12:54:51 +01:00
shumeiko.it
06d267dec8 fix(web): name only what a chat turn touched in the activity card (UF-050)
The card headline was a fixed "Worked across your memory, web & files".
It is now built from the turn: memory, web and file tools it called and
the memory steps the server reported, or a plain Working / Done.
2026-10-27 12:54:45 +01:00
shumeiko.it
711c37358a fix(web): keep the workspace title from stretching between tabs (UF-049)
The title carries a framer-motion layoutId for the card-to-header hero morph,
which also animates any change of its box. With a short workspace name the
title is as wide as the subtitle row; hiding that row on the Chat tab changed
the width, and framer animated it as a horizontal scale (2.9x for "Eng").

Both titles now use layout="position": only the position animates, and the
hero morph still moves the name into place. The hero-morph test checks it.
2026-10-26 21:22:32 +01:00
shumeiko.it
3d1d07bd50 fix(web): pad the command palette search field and center the account row (UF-047, UF-048)
The ⌘K search input had no padding but drew its own focus ring with an
offset, so the ring ran right against the text. It now has inner padding
and no offset, so the ring reads as the field's outline; the palette test
checks both.

The sidebar account row had 8px above its content and 22px below, because
its bottom padding added to the nav's own. It now has 14px above and none
below, matching the nav padding underneath.
2026-10-26 21:16:20 +01:00
shumeiko.it
5163f3dd48 feat(web): add the calm redesign as a sidebar switch
The redesign proposed after the anti-slop audit (anti-slop/audit-001) is now
an opt-in design layer. The "New design" switch at the bottom of the sidebar
sets data-design="calm" on <html> and remembers it; theme-init.js applies the
stored choice before the first paint. The classic look stays the default and
is unchanged.

styles/calm.css, scoped to that attribute, keeps the Hive DS colors and:
bundles Hanken Grotesk and JetBrains Mono (@fontsource-variable, OFL-1.1);
uses three radii (6 / 10 / 14 px); drops the honeycomb wallpaper, gradient
fills, glass, glows and pulsing dots; keeps shadows only on menus and
dialogs; shows labels as written instead of tracked capitals; and marks the
active sidebar item with fill, a 1px line and weight instead of a stripe.
Screen layouts are unchanged.
2026-10-26 21:01:27 +01:00
shumeiko.it
1e826aa220 fix(desktop): stop the sidecar with SIGTERM first, and free a stale WhatsApp profile (UF-046)
On macOS and Linux the shell stopped the sidecar with Child::kill(), which is
SIGKILL, so the sidecar never ran its shutdown: the processes it started (MCP
servers, a managed Ollama, the WhatsApp browser) kept running. After an app
restart the orphaned WhatsApp browser still held the session profile, and the
channel failed with "The browser is already running".

The shell now sends SIGTERM, waits up to 5 seconds for the sidecar to exit,
then sends SIGKILL; Windows keeps its kill-on-close job. For crashes, where no
shutdown runs, the WhatsApp channel stops a browser left over from an earlier
run before starting its own. It only stops a process whose command line uses
this profile and whose parent is gone; a browser another running Waggle server
owns is left alone, and the channel says so instead of retrying.
2026-10-26 12:03:31 +01:00
shumeiko.it
48bdab8087 fix(server): generate personas through the built-in proxy (UF-045)
POST /api/personas/generate posted to /api/anthropic/v1/messages, a route
that does not exist, with no session token and a port built from
address().toString(), so the URL did not even parse. It also pinned
claude-sonnet-4-6, which needs an Anthropic key.

The route now calls the built-in proxy through self-request.ts, reads the
OpenAI-format reply, and picks the model from the user's default with the
same fallback chat uses, so a local Ollama model works too. An end-to-end
test with localhost trust off checks the generated persona comes back.
2026-10-26 01:50:47 +01:00
shumeiko.it
d6217ad7c2 fix(server): send the session token on the sidecar's calls to its own proxy (UF-044)
Since the server stopped trusting loopback callers, the built-in model proxy
needs the session token like every other route, but the sidecar's own calls
to it sent none. The Models key check read the proxy's 401 as a rejected key,
so a working Anthropic key showed "Key found but not responding". Scheduled AI
tasks and loops, the dream diary narrative and the profile calls failed the
same way; the profile calls also built the port from address().toString(),
and the scheduled tasks used the configured port, which the desktop app's
port fallback can leave pointing at another Waggle server.

self-request.ts now builds the address from the bound port and adds the
session token; all these calls and command.ts use it, and the token is never
sent to Ollama. An end-to-end test runs the key check through the real
middleware and proxy with localhost trust off; it fails without the fix.

UF-045 records the persona generator, which posts to a route that does not
exist; it is left open.
2026-10-26 01:46:29 +01:00
shumeiko.it
5268881f46 docs(oss): how to build the Windows desktop installer 2026-10-26 00:43:43 +01:00
shumeiko.it
ae8233b8f6 fix(web): give the chat composer a single focus outline (UF-043)
The composer textarea drew its own focus ring inside the rounded box, which
already turns amber on focus-within. The ring is gone; the box's border stays
the focus indicator (8.14:1 dark, 4.92:1 light against the composer).
2026-10-26 00:32:11 +01:00
shumeiko.it
efcb19e682 fix(web): show sidebar hints only on the icon rail, above the main area (UF-042)
With the full-width sidebar every item showed a hover hint that repeated its
visible label, and the part of the hint that reached past the sidebar was
hidden wherever the main area had content: the hint rendered inside the nav,
and the nav and <main> are sibling z-10 layers.

Sidebar hints now show only on the icon rail below lg, where they are the
only label, and render in document.body through a new opt-in `portal` flag
on HintTooltip. Other hints keep rendering in place, since several sit in
overlays above z-50 where a portaled hint would end up underneath.
2026-10-25 23:37:20 +01:00
shumeiko.it
07a529512c fix(server): let the CLI server exit on Ctrl+C and SIGTERM (UF-041)
The OAuth routes started a module-level cleanup interval that was never
cleared or unref'd. The service's SIGTERM/SIGINT handler closes the server
and relies on the event loop going empty, so the process kept running: a
first Ctrl+C in `npx waggle` or `npm run dev:server` left it alive, and
SIGTERM never ended it. The interval is now unref'd.

The launcher tests left two `waggle` processes behind on every run: they
stopped `npx` but not the waggle process it started. They now start it in
its own process group and stop the whole group, with a SIGKILL fallback,
and a new test checks that the built CLI exits by itself after SIGTERM.
2026-10-25 23:01:05 +01:00
shumeiko.it
2e08f2ae96 refactor(server): move the install audit trail from core to the server (P1.2, UF-040)
Core keeps only shared infrastructure, so InstallAuditStore leaves it and
lives in packages/server/src/local/install-audit.ts. The trail itself stays:
the Audit and Activity tabs, the extend and export routes, and the threat
model entry keep working on the same waggle.db table.

- @waggle/shared gets RecordAuditInput and the narrow InstallAuditRecorder
  (record only), which the agent's skill tools now depend on.
- The server creates the audit table before the one-time legacy copy, which
  no longer constructs it in core.
- UF-040: GET /api/debug/logs called prepare() on the store's private db
  wrapper, which has none, so the support bundle never carried recent
  installs. It now reads them through getRecentSummary().
2026-10-25 21:32:38 +01:00
shumeiko.it
3befcd8e9b docs: how to build the desktop app, and the packaged macOS launch 2026-10-24 19:18:02 +02:00
shumeiko.it
1f536151d8 fix(desktop): find the sidecar in a macOS app bundle and fit the startup screen (UF-004, UF-017)
- The packaged macOS app stayed on "Starting Waggle…": the shell looked
  for node, service.js, native/ and node_modules/ next to the executable,
  the Windows layout, while a macOS bundle keeps them in
  Contents/Resources/resources. bundled_resources_dir() checks both.
- The startup screen used min-height 100vh on an unstyled body, which
  showed scroll bars, and a fixed light text colour that is invisible in
  the light theme. It is now styled from index.html, fixed to the window,
  with a dark text colour for the light theme.
2026-10-24 19:10:23 +02:00
shumeiko.it
276808cd69 docs(oss): record the end-of-week-2 checkpoint 2026-10-24 18:27:12 +02:00
shumeiko.it
1e6f423d73 test(e2e): check memory isolation between real workspaces and the chat-scoped erase (P1.5, UF-039)
- The isolation journeys (B2.4, U2.3, U2.4, U9.3) create their workspaces
  first. They used made-up workspace ids, which the sidecar silently
  turned into personal memory, so they never compared two workspaces;
  such writes are now refused (UF-039).
- J3f follows the Memory Center on the memory contract: Erase removes
  every memory saved from the same chat and is offered only for memories
  with a chat session; the erased-sources panel is gone.
2026-10-24 18:20:01 +02:00
shumeiko.it
8a9ba09ad9 fix(server): refuse memory writes for a workspace that does not exist (UF-039)
POST /api/memory/frames, /api/quick-capture and the Memory Center's
POST /api/memory saved a memory meant for an unknown workspace into
personal memory, which every workspace reads. They now answer 404
workspace_not_found and write nothing; a request without a workspace
still goes to personal memory.
2026-10-24 18:09:43 +02:00
shumeiko.it
4dbab2cb8b docs: describe the community edition after the move to mem0 and the unified build
AGENTS.md no longer describes memory as half-migrated or asks for
build:packages before running the sidecar, lists the tsc -b build and the
test typecheck among the checks, and drops the removed weaver package.
ADR-0007 and ADR-0008 record that core no longer re-exports the legacy
substrate and that sqlite-vec is gone.
2026-10-24 17:56:20 +02:00
shumeiko.it
64580b4551 test: finish moving the root suites to the community edition (P1.5, P1.3b)
- The workspace isolation scenarios store memories through the memory
  store and check that one workspace's search never returns another's.
- The Ollama manifest test covers the Linux x64 and arm64 artifacts added
  for P1.3b; an unsupported platform still resolves to nothing.
- The root run leaves out the tests that only exercise excluded packages
  (the hook packages and the memory MCP server); they go with those
  packages in P2.2.
2026-10-24 17:53:16 +02:00
shumeiko.it
2a7f129df6 docs: describe recall search callers without the legacy HybridSearch (P1.5) 2026-10-24 17:48:05 +02:00
shumeiko.it
3fee3d6935 test(launcher): expect waggle.db and the memory store instead of personal.mind (P1.5) 2026-10-24 17:47:22 +02:00
shumeiko.it
77ddfd5b27 test(server): expect the source export condition in the sidecar and e2e builds (P2.1) 2026-10-24 17:44:23 +02:00
shumeiko.it
60fa8a1c54 test(server): seed the SSE knowledge-only memory through the contract (P1.5)
The checkout-queue test searches memory for 'SSE resilience test frame'. The
text used to reach mem0 only through the background copy of the seeded
legacy personal.mind; write it with server.memory instead.
2026-10-24 17:43:27 +02:00
shumeiko.it
3308263613 test: read run memories through the contract in the live collaboration test (P1.5)
The live external-agent test (skipped unless WAGGLE_LIVE_EXTERNAL_AGENTS=1)
looked up run memory receipts as frames in server.multiMind and
server.mindCache, which the server no longer has. Look them up with
server.memory.get and check that personal and workspace receipts sit in
their own scopes. Also type the prompt assembler's bulk fixture as
RecallFrame.
2026-10-24 17:43:27 +02:00
shumeiko.it
4280a85b24 test(cli,marketplace): drop legacy memory engine references (P1.5)
- cli: delete real-session-simulation.ts, a manual script that populated a
  hard-coded Windows .mind file through the old Orchestrator API.
- cli runtime: @waggle/core no longer depends on hive-mind-core, so the
  packed closure does not include it.
- marketplace: rename the local marketplace schema constant so it is not
  mistaken for the memory engine's SCHEMA_SQL.
2026-10-24 17:43:27 +02:00
shumeiko.it
f94331c202 test(agent): move agent tests off the legacy memory engine (P1.5)
- prompt assembler harnesses (v4 and v5): prime an in-memory contract store,
  snapshot its memories and replay them into a fresh store per condition
  instead of copying a MindDB file; the identity card is created per
  orchestrator. They had also drifted from the current Orchestrator API
  (config takes memory, buildSystemPrompt is async).
- prompt assembler unit test: build RecallFrame fixtures, the type the
  assembler consumes, instead of legacy MemoryFrame rows.
- M3c integration: drop the knowledge-graph Ontology case; the knowledge
  graph is not part of v1 and core no longer exports it.
2026-10-24 17:43:27 +02:00
shumeiko.it
ad7b90bebd test(server): drop tests of the legacy memory engine (P1.5)
- harvest-provenance: tested the removed harvest pipeline (RawArchive and
  frame metadata), which no longer exists.
- benchmarks: drop the FTS5 frame search and frame/session write
  benchmarks; they measured the legacy engine only.
2026-10-24 17:43:27 +02:00
shumeiko.it
f57d618bea test(server): check waggle.db and the memory store instead of mind files (P1.5)
- trust wiring: read install_audit from waggle.db through the server; the
  old checks read a legacy personal.mind that nothing writes any more.
- data dir: a fresh install is marked by waggle.db, not personal.mind.
- backup: expect waggle.db and memory/ in the archive.
- cross-platform: replace the MindDB block with waggle.db checks (file, WAL,
  foreign keys) and memory round trips (plain, Unicode, 100 KB) through
  server.memory. FTS5 and session CRUD were legacy-engine features.
- store fixtures (install audit, cron) open WaggleDB instead of MindDB.
2026-10-24 17:43:27 +02:00
shumeiko.it
6573f817b0 test(server): stop seeding a legacy personal mind (P1.5)
The server no longer opens personal.mind, so tests build it on an empty
data directory. The /memory command test seeds its two memories through
server.memory and now checks that the seeded text is found.
2026-10-24 17:43:11 +02:00
shumeiko.it
f1cde9a32f test(server): count memories through the contract instead of mind frames (P1.5)
The persona memory-denial and cron Loop tests counted rows in the legacy
personal and workspace minds, which nothing writes any more. Count
server.memory per scope (and origin 'loop' for the truncated Loop report)
instead, and stop seeding a personal.mind the server no longer opens.
2026-10-24 17:43:11 +02:00
shumeiko.it
c6a9fbf85a test(core): drop the legacy memory engine from core tests (P1.5)
- install audit: build fixtures on WaggleDB, the store's real home; drop the
  substrate SCHEMA_SQL parity half and the two MindDB-only recovery cases
  for rows stranded in install_audit__mig_old.
- workspace manager: create() and ensure() no longer leave a workspace.mind;
  getMindPath tests create the legacy file themselves. Drop the
  MultiMindCache cases (reopen of a missing mind, post-resolution junction
  swap): they tested the legacy cache, not the manager.
- transformers model load: use core's own in-process reranker.
2026-10-24 17:43:11 +02:00
shumeiko.it
52ee21ddb5 refactor(agent): stop the Planner persona advertising the knowledge graph (P1.5)
query_knowledge is not registered in the community edition: the knowledge
graph is deferred (ADR-0002).
2026-10-24 17:39:55 +02:00
shumeiko.it
2c376f21cf docs(oss): log the Marketplace hot-reload notification that never reaches the sidecar (UF-038) 2026-10-24 17:39:20 +02:00
shumeiko.it
7dac06706e refactor(web): drop team API calls (P1.1)
The local sidecar has no /api/team/* routes since P1.1.

- Remove searchTeamMemory, getTeamMembers, getTeamActivity and
  getTeamMessages from the adapter.
- Mission Control loses its Team and Activity tabs (both read the team
  server) and keeps the fleet view, with its own load-error state.
- Drop the stale adapter mocks from the web tests; the Mission Control
  test checks that no team tab is offered.
2026-10-24 17:35:48 +02:00
shumeiko.it
8ce2c42544 refactor(agent): remove the unused team-server tools (P1.1)
createTeamTools and createLocalTeamTools called /api/teams/* and
/api/team/* on a team server. Nothing registered them: not the
sidecar, the CLI, the team server or the worker.
2026-10-24 17:35:48 +02:00
shumeiko.it
93d73be7b4 chore(server): remove the memory benchmark judge scaffolding (P2.2)
packages/server/src/benchmarks held a LoCoMo failure-mode aggregator and
an LLM judge ensemble for the old memory engine benchmarks. Nothing in
the sidecar imports it and no npm script runs it; its inputs lived in
the root benchmarks/ directory that P2.2 already removed. Judge and eval
loops are also out of the community edition (AGENTS.md, rule 4).
2026-10-24 17:35:48 +02:00
shumeiko.it
76c7102123 refactor(server): drop team and WaggleDance targets from the command bar (P1.1)
The command bar could still offer "WaggleDance" and "Team" (governance)
as navigation targets, but those screens and app ids are gone from the
web app, so the frontend could not route them. Also drop a comment that
pointed at the removed WaggleDance routes.
2026-10-24 17:35:48 +02:00
shumeiko.it
3d966e2aca refactor(server): drop WaggleDance run tokens and the team session timeout (P1.1)
- The WaggleDance routes left the sidecar with team mode, so the
  x-waggle-run-token header no longer opens /api/waggle-dance/signal or
  /api/waggle-dance/signals. A run token still authenticates only as a
  Bearer on /v1/chat/completions (OpenClaw).
- Remove the session inactivity timeout. It switched on only in team
  mode, when CLERK_SECRET_KEY was set.
2026-10-24 17:35:48 +02:00
shumeiko.it
d426440da7 refactor: describe memory without the .mind file and knowledge graph (P1.5)
Memory lives in the mem0 store and the knowledge graph is not in v1
(ADR-0002, ADR-0007).

- The CLI system prompt listed query_knowledge, a tool the community
  edition does not register. It now lists search_all_workspaces, which
  the orchestrator does provide.
- The default identity no longer claims "persistent memory (.mind file)"
  or "knowledge graph queries".
2026-10-24 17:35:48 +02:00
shumeiko.it
697517d378 refactor(cli): run local mode only (P1.1)
Team mode is not part of the community edition (ADR-0003), so the CLI
no longer detects or switches to it.

- Remove the mode detector, the --local and --team flags, the Clerk
  browser login (/login, /logout, /whoami) and /mode.
- Remove the /admin command and its team-server REST client.
- The welcome banner drops the Mode line.
- The installed-REPL test starts plain `waggle` and checks that the team
  commands are gone.
2026-10-24 17:35:48 +02:00
shumeiko.it
d51ea0aed5 test(agent): time the connector registry against a store without spies (P1.2) 2026-10-24 17:35:36 +02:00
shumeiko.it
316cb2ba36 test(server): drop the startup test for the removed multi-mind migration (P1.2) 2026-10-24 17:35:36 +02:00
shumeiko.it
0b3e4fc339 test(core): test the SecretStore contract on VaultStore (P1.2)
secret-store.test.ts covers get, set, setAsync, writeBatch, delete,
deleteAsync, list and has through the interface. vault.test.ts keeps what is
specific to the file backend: encryption, the key file and the Windows ACL.
2026-10-24 17:35:36 +02:00
shumeiko.it
4ed21fe519 refactor: depend on SecretStore instead of the VaultStore class (P1.2)
Connectors, the connector SDK and registry, setup-connectors, provider-env,
the LiteLLM runtime config and the sidecar's `vault` decoration only read and
write secrets, so they now take the SecretStore interface. VaultStore is still
constructed in the sidecar and the service startup, and its file format is
unchanged. AGENTS.md now points at the interface.
2026-10-24 17:35:36 +02:00