poke-conduit
A production-shaped, durable multi-agent backend for the Poke MCP client, providing backlog management, council deliberation, and proactive reminders.
README
poke-conduit
The durable brain Poke consults. Poke already lives in iMessage (sanctioned, no Apple API, no ban risk) and is an MCP client that calls external MCP servers. poke-conduit inverts the usual integration: instead of building our own iMessage transport, Poke is the front-end terminal and poke-conduit is the MCP server it calls — a production-shaped, durable, multi-agent backend.
iMessage ──► Poke (MCP client) ──► poke-conduit /mcp ──► Postgres (Neon)
▲ │ orchestrator · worker-agents
└───── proactive push ───┘ council · backlog · scheduler
(Poke inbound API)
You text Poke; Poke calls a tool here; poke-conduit does durable work and can text you back later through Poke's inbound API (async council verdicts, fired reminders).
What it does
| Capability | Tools | Notes |
|---|---|---|
| Queued-notes backlog (flagship) | add_note · list_backlog · complete_note · pin_note |
Durable to-read / to-do queue, 1-based refs, pinning. |
| Council (multi-agent) | ask_council · council_status |
Fans a hard question out to six persona agents (Builder · Skeptic · Operator · User-Advocate · Strategist · Pragmatist), then a synthesizer makes the call. deliver=return replies inline; deliver=async returns now and pushes the verdict when ready. |
| Proactive reminders | set_reminder · list_reminders |
Minute-resolution scheduler fires due reminders and pushes them via Poke. One-shot or daily. |
| Availability / DND | get_status · set_status |
active / dnd / deep_work, optional note + until. |
| Recipes | list_recipes · install_recipe · run_recipe |
Saved routines. A recipe is a free-text prompt and/or an executable steps macro — a JSON array of { tool, args } that run_recipe dispatches through the conduit's own tools in order (offline-testable, can't recurse into itself). |
Architecture
A few small, single-responsibility seams make the whole thing testable offline and deployable with just Neon:
- Hand-rolled MCP (
src/mcp/,src/http/core.ts) — a Streamable-HTTP JSON-RPC handler over WebRequest/Response. No SDK: the surface Poke speaks is tiny, and hand-rolling keeps it edge-runtime-compatible and fully unit-testable. (Same choice thepoke-amb-bridgemade.)POST /mcpis rate-limited per identity (Poke user id, else IP) via aRateLimiterport (src/http/ratelimit.ts) — in-memory locally, Postgres-backed in prod; a static landing page is served at/, and a browserGET /mcpreturns friendly server info instead of a 500. Storeport (src/store/) — oneSqlStoreruns on pg-mem (tests /serve/ demo) and Neon (prod) over an injectedSqldriver. All timestamps are ISO text so they sort lexically and round-trip byte-identically between the two.Modelport (src/model/) —ClaudeModelwhenANTHROPIC_API_KEYis set, else a deterministicMockModel(so tests and the demo need zero credentials).Stepseam (src/durable/step.ts) — council logic is written once againstStep. It runs underLocalStep(in-process, memoized) inline within Vercel's 300 s budget by default, or on Inngest for true serverless durability when configured. The async council routes through an optionaldispatchAsyncCouncilprovider (src/durable/inngest.ts): setINNGEST_EVENT_KEY(andnpm install inngest) and runs survive function freezes with per-step retries; leave it unset and it transparently falls back to the inline path. Inngest stays out of the 3-dep core — it's loaded lazily through a non-literal import, so the package is needed only when the feature is switched on.- Two credentials, two directions — inbound (Poke → conduit:
Bearer/x-poke-key+ injectedx-poke-user-id, gated byMCP_AUTH_ENFORCE) is distinct from outbound (conduit → Poke:POKE_API_KEYto Poke's inbound API, which makes Poke act on the message).
Run it locally
No credentials required — it falls back to pg-mem + MockModel + a mock Poke client.
npm install
npm test # 129 tests (unit + tool handlers + full MCP wire e2e)
npm run demo # narrated, self-asserting end-to-end walkthrough (22 checks)
npm run serve # local HTTP server: GET / · POST /mcp · GET /cron · GET /healthz
The demo runs the real wire path (handleMcp(Request) → Response) and never sends a real
message. Set ANTHROPIC_API_KEY first to watch the council deliberate with real Claude:
export ANTHROPIC_API_KEY=sk-ant-...
npm run demo
Drive the local server by hand:
npm run serve &
curl -s localhost:7411/mcp -H 'content-type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' | jq '.result.tools | length' # 13
Deploy
See DEPLOY.md — Vercel (edge functions) + Neon, env vars, the cron schedule
caveat, and how to point Poke at your /mcp endpoint.
Project layout
api/ mcp.ts · cron.ts · inngest.ts · healthz.ts · _store.ts (Vercel edge entry points)
public/ index.html (static landing page served at /)
src/
config.ts · ids.ts
store/ types · schema · sql (SqlStore) · pgmem · pg (Neon) · index
model/ types · mock · claude · index
durable/ step.ts (Step · LocalStep · fromInngestStep) · inngest.ts (optional durable provider)
poke/ index.ts (PokeClient · HttpPokeClient · MockPokeClient)
agents/ personas · worker · council · orchestrator
tools/ backlog · reminders · status · recipes · recipe-runner · council · index
mcp/ auth.ts · server.ts (JSON-RPC)
http/ core.ts (Request→Response core) · ratelimit.ts (RateLimiter port)
scheduler.ts · render.ts · serve.ts · demo.ts
test/ store · model · step · council · council-async · scheduler · render · auth · tools · recipe-runner · mcp · ratelimit
docs/superpowers/ specs/ · plans/
Built as a finished MVP from a design spec → plan → task-by-task implementation, tests written
immediately after each unit. See docs/superpowers/ for the spec (with the as-built addendum) and
the implementation plan.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。