@murphai/assistantd
v0.1.15
Published
Published local assistant runtime control plane for Murph.
Readme
@murphai/assistantd
Published local assistant runtime control plane for Murph.
assistantd is the local daemon boundary for the personal assistant runtime. It keeps the canonical vault write surface in Murph core/CLI while giving the assistant runtime a single loopback-owned control plane for chat turns, session access, outbox draining, cron processing, automation scans, diagnostics, and status through the explicit @murphai/assistant-core headless surface.
Like device-syncd, the daemon binds the control plane to localhost by default and requires a bearer token for every control-plane request. It is meant to run one daemon per selected vault.
What it does:
- serves a localhost-only assistant control plane for local chat turns and runtime state inspection
- owns assistant session execution through one runtime authority per vault
- keeps assistant runtime state in sibling
assistant-state/**, not in canonical vault files - exposes status, session, outbox, cron, and automation control routes for local clients
- publishes
@murphai/assistantd/clientas the loopback-only HTTP client surface for daemon-routed callers - lets the CLI operate as an HTTP client when
MURPH_ASSISTANTD_BASE_URLandMURPH_ASSISTANTD_CONTROL_TOKENare configured
What it does not do:
- replace Murph core as the canonical health-data write surface
- widen the trust boundary for hosted execution
- make assistant scratchpads canonical
Environment
Required:
ASSISTANTD_VAULT_ROOTASSISTANTD_CONTROL_TOKEN
Optional:
ASSISTANTD_HOST(defaults to127.0.0.1)ASSISTANTD_PORT(defaults to50241)
CLI client configuration:
MURPH_ASSISTANTD_BASE_URLMURPH_ASSISTANTD_CONTROL_TOKEN
Startup env loading:
murph-assistantdloads.env.localfirst and then.envfrom its launch cwd before reading startup config.- Already-exported shell variables still win over those file defaults.
assistantd sets MURPH_ASSISTANTD_DISABLE_CLIENT=1 in its own process so daemon-local calls never recurse back through the HTTP client.
HTTP routes
All routes are loopback control-plane routes and require Authorization: Bearer <token>.
GET /healthzPOST /open-conversationPOST /messagePOST /session-optionsGET /statusGET /sessionsGET /sessions/:idGET /outboxGET /outbox/:intentIdPOST /outbox/drainGET /cron/statusGET /cron/jobsGET /cron/jobs/:jobGET /cron/runsPOST /automation/run-once(defaults toonce: trueandstartDaemon: false)POST /cron/process-due
Gateway routes
assistantd now also serves the local derived gateway plane over loopback-only authenticated HTTP:
POST /gateway/conversations/listPOST /gateway/conversations/getPOST /gateway/messages/readPOST /gateway/messages/sendPOST /gateway/attachments/fetchPOST /gateway/events/pollPOST /gateway/events/waitPOST /gateway/permissions/list-openPOST /gateway/permissions/respond
These routes serve the operational conversation/message gateway surface for local MCP or other transport adapters without turning assistantd into a second canonical write owner.
Local gateway helpers now honor the same assistantd base-url/token environment variables as the assistant client path, so consumers can route steady-state gateway reads/sends through the daemon whenever it is configured. The transport-neutral gateway contracts stay in @murphai/gateway-core; the vault-backed local runtime now lives in @murphai/gateway-local.
The published @murphai/assistantd/client subpath now owns that loopback client config plus the gateway daemon client helpers. CLI-only assistant routing helpers may still wrap it where they need package-local assistant contracts, but the daemon transport substrate itself no longer lives in packages/cli.
