v26.05.30.1 — MCP-first pivot + Rulebook + Plans + Soft-delete #51
Reference in New Issue
Block a user
Delete Branch "dev"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
118 commits since v26.05.13.1. Headline: the MCP-first pivot lands in production, and three new feature arcs land on top of it.
MCP-first pivot (Phases 7-10)
Scribe is now a pure data store. Claude via the in-app
/mcpendpoint is the only LLM. ~30,000 lines deleted across backend, frontend, and infrastructure./mcpmounted alongside/api/*via FastMCP's streamable-HTTP transport. ASGI middleware authenticates via bearer tokens from the existingapi_keystable; rejects with 401 before FastMCP sees the request. Per-requestuser_idContextVar for tool handlers.BAAI/bge-small-en-v1.5, 384d). First boot downloads the model to/data/fastembed-cacheonce. Migration 0052 cleared the existing 768d note_embeddings; startup re-embeds existing notes./chat,/journal,/workspace/:projectId, voice overlay, the chat-style home view. Surfaces that survived:/knowledge,/notes,/tasks,/projects,/calendar,/graph,/settings,/rules,/trash./api/chat/*,/api/journal/*,/api/voice/*,/api/push/*,/api/quick-capture,/api/fable-mcp/*and their backing services. The standalonefable-mcpstdio wheel removed.conversations,messages,generation_tool_log,moments+ junction tables,moment_embeddings,pending_curator_actions,push_subscriptions,weather_cache,rss_item_embeddings.image_cache; removed Ollama service config and frontend orphans.fabledassistantinternal package name kept stable.fmcp_<32-byte-base64url>format), shown once, sent asAuthorization: Bearer <token>. Configurable MCP server name + scope.Rulebook system (May 2026 milestone)
Cross-project standards: Rulebook → Topic → Rule, sibling to Project, with project subscriptions.
rulebooks,rulebook_topics,rules,project_rulebook_subscriptions. Each rule is astatement + why + how_to_applytriple.get_project(id)returnsapplicable_rules+subscribed_rulebooks(capped at 50)./rulesthree-pane UI (rulebooks → topics → rules) with rule editor; project Rules tab grouped by rulebook → topic.Plans-as-tasks (May 2026 milestone)
Plans are first-class without a new entity: a Task with
task_kind="plan".notes.task_kindcolumn (work|plan, defaultwork, CHECK-constrained).start_planning(project_id, title)seeds a plan template + returns applicable_rules.get_tasksurfacesapplicable_rulesfor plan-tasks only./projects/:id; Applicable Rules panel in the task editor; Knowledge view's Plans facet + plan badge.Soft-delete / Trash / Retention (May 2026 milestone)
Deletes become recoverable.
deleted_at TIMESTAMPTZ NULL+deleted_batch_id TEXT NULL(+ix_<t>_deleted_at) on 7 tables (notes,events,projects,milestones,rulebooks,rulebook_topics,rules).SoftDeleteMixininmodels/base.py.delete_*flipped to soft (return{deleted_batch_id, message}); addeddelete_task,delete_project,delete_milestone(closes the CRUD-asymmetry gap); addedlist_trash,restore,purge_trash(confirmed-gated hard delete)./api/trash(GET list, POST/<batch>/restore, DELETE/<batch>for purge). All entity DELETE handlers flipped to calltrash.delete.trash_retention_dayssetting (default 90,0= keep forever). Daily 03:30 UTC APScheduler purge cron./trashview (batches summary, Restore, Delete-permanently, Empty trash, empty state) + Settings → General → "Trash retention" field.g+xkeyboard shortcut.MCP transport — stateless HTTP
mcp/server.pysetsstateless_http=Trueon the FastMCP instance. The default stateful streamable-HTTP transport handed Claude Code anMcp-Session-Id; after a container redeploy the server rejected the now-unknown id with 404, and Claude Code doesn't re-initialize on 404 (issue #60949), so the connection stranded until manual/mcpretry. Stateless makes every request self-contained (bearer-auth only); the next message after a redeploy reconnects automatically — no manual intervention.Pre-pivot work in the diff (removed by the pivot)
The diff includes substantial work that landed on dev before the MCP pivot and was subsequently removed by it: curator phases C1-C5 (additive-only curator tools, authority routing, Needs Review panel), journal closeout + captures panel, TTS migration (kokoro → piper) + voice admin UI, diagnostics for crash investigation, model-bench tooling (
bench_ollama.py), user-controlled think mode. These commits remain in history but the surfaces they touched no longer exist in production.Deploy notes
app+db. No Ollama, no Redis, no background worker.claude mcp add --transport http scribe <BASE_URL>/mcpwith the token in the bearer header./data/fastembed-cache; persists across container restarts.Verification
2f577fe)./trashUI + Settings retention field device-checked by operator 2026-05-29./mcpretry).list_trash→restore→ re-delete →purge_trashround-trip; singledelete_task→list_trash→restoreround-trip. Both passed.Known follow-ups
Captured as plan-task 183 on project 3, milestone M1 "Authorization & share-correctness (May 2026)":
list_trash/restore/purgeignoreuser_id(cross-user leak under multi-user); retention reads user 1's setting globally rather than a per-instance admin value; collaborator-delete semantics undefined.purge_trashrowcount is off-by-one when the batch holds parent + children whose DB-level FK hasON DELETE CASCADE(end state correct, count off by one); trash items showtype: "note"foris_task=Truetasks.These feed the M1 foundation work. See project 3 milestones for the full M1→M4 roadmap (authz → audit → review surface → retrieval quality).