A personal assistant that lives on your desktop, remembers what matters, and can use your Mac for you.
TypeScript
docs(odd): record the Slack and Gmail sign-in decision
Alan Buscaglia34b739b6261b
diff --git a/odd/tasks/gentle-dot.md b/odd/tasks/gentle-dot.mdindex 2865328..5df50d9 100644--- a/odd/tasks/gentle-dot.md+++ b/odd/tasks/gentle-dot.md@@ -58,7 +58,7 @@ Branch: `feat/gentle-dot` · Delivery strategy: `single-pr` (user choice, L7; fo- **S16 — Typing closes open options.** Same quote. When the user starts typing in the composer, open menus and panels (conversations list, accounts, profiles) close; a sign-in that is waiting for the user's answer is kept, so its prompt is not lost.- **S17 — Clear header icons.** Same quote ("para las partes de profiles no entiendo porque el icono de contraste"). The header uses one consistent set of clear inline SVG icons with tooltips and accessible names (conversations, accounts, profiles with a sliders-style icon, new conversation, hide), replacing the text glyphs (☰ ⚿ ◐ + –).-- **S18 — Connectors (Gmail, Slack, Discord, Notion).** User: "como podemos hacer para un apartado de conectores, por ejemplo gmail, slack, discord, etc" and, on the proposal, "dale me gsuta )". Accepted proposal (L32): a Connectors screen like Accounts, backed by MCP servers in the assistant's own engine home (`<agentHome>/mcp.json`, logins in `mcp-auth.json`). The daemon manages the catalog, enabling, disabling, and removal, plus each connector's sign-in (remote OAuth, a guided token, or the provider's own OAuth app), with the same secret rules as model sign-in, and restarts the agent when idle. Any outward action (send mail, post to Slack or Discord, write to Notion) needs an approval card with a preview; read-only actions do not. Each connector can be set to read-only or read-and-send. First set: Gmail, Slack, Discord, Notion, Linear, and Atlassian (L33).+- **S18 — Connectors (Gmail, Slack, Discord, Notion).** User: "como podemos hacer para un apartado de conectores, por ejemplo gmail, slack, discord, etc" and, on the proposal, "dale me gsuta )". Accepted proposal (L32): a Connectors screen like Accounts, backed by MCP servers in the assistant's own engine home (`<agentHome>/mcp.json`, logins in `mcp-auth.json`). The daemon manages the catalog, enabling, disabling, and removal, plus each connector's sign-in (remote OAuth, a guided token, or the provider's own OAuth app), with the same secret rules as model sign-in, and restarts the agent when idle. Any outward action (send mail, post to Slack or Discord, write to Notion) needs an approval card with a preview; read-only actions do not. Each connector can be set to read-only or read-and-send. First set: Gmail, Slack, Discord, Notion, Linear, and Atlassian (L33). Sign-in per connector (L36): Notion, Linear, and Atlassian use their official remote MCP with one-click OAuth. Discord uses a community server with a guided bot token. Slack and Gmail use their official servers with a guided "bring your own app" setup: in-app steps to create the Slack app or Google Cloud project and consent screen, then paste the client credentials (stored only in the assistant's private home).- Open questions (being mapped, read-only): (1) whether the engine's MCP integration completes MCP OAuth in RPC mode or the daemon must run it (pi-mcp/oauth) and write `mcp-auth.json`; (2) which of these services offer an official remote MCP with OAuth today, versus community servers needing tokens or the user's own OAuth app; (3) how to classify tools as write actions, so only those require approval.- **S19 — Add any other MCP by asking the assistant.** User (L33): "Notion, Linear, Atlassian tmabien, esta bueno, y pon un apartado de conectar mcp extra, que directamente se lo pida al agente, creo que podria hacerlo no? es mas podriamos reconocer los mcps del user o no ?". The Connectors screen has an "Add another connector" option that starts a chat request. The assistant drafts the server configuration (name, command or URL, required credentials), but it never writes `mcp.json` itself: the daemon applies the draft only after the user approves a card that shows every detail. The same approval applies whenever the assistant tries to change connectors on its own initiative.@@ -130,4 +130,5 @@ Environment notes: Node v24.14.1 and pnpm are present. `cargo` is on PATH but `r- **L33 (2026-10-08, user):** "Notion, Linear, Atlassian tmabien, esta bueno, y pon un apartado de conectar mcp extra, que directamente se lo pida al agente, creo que podria hacerlo no? es mas podriamos reconocer los mcps del user o no ?". Decision recorded: the assistant drafts and the daemon applies after user approval (prompt-injection guard). Import of the user's MCP servers is read-only, per server, and explicit. The explorer was asked to extend its map.- **L34 (2026-10-08, user):** "y creo que encontre un bug, si mientras el agente esta respondiendo un mensaje, abro otra conversacion, da error y no dice que hubo error en el mismo chat". Reproduced from the user's `~/.gentle-dot/daemon.log` (error lines only): `12:17:05 assistant error: This operation was aborted`. Pi's `switch_session` aborts the active run (`agent-session-runtime.js` teardownCurrent → `session.abort()`); the bridge turned the aborted `message_end` into a generic error toast outside the chat. Also, `command get_history failed: Agent is not ready` repeats at every startup (history requested before the agent is ready). Both were added to T17 (same files: bridge.ts and UI).- **L35 (2026-10-08, T18 map + web verification):** MCP is a built-in pi-coding-agent 1.0.4 extension that reads `<agentDir>/mcp.json` only at `session_start` and stores OAuth in `mcp-auth.json` (keys `mcp__<ns>|<url>`, locked writes); new tokens are picked up on the next turn. Headless OAuth runs as a separate process (`pi mcp login <name>` with the assistant's agent dir and HOME), because `/mcp login` in RPC sends the URL as an info notice that the sanitizer hides. The assistant disables codemode, so each server needs `exposure: "direct"|"deferred"`. Approval is enforced by an extension loaded with `-e` that hooks `tool_call` (it can block, covers nested calls, and asks through `ctx.ui.confirm` → ask card). Pi documents agents running `pi mcp add` through bash, so the daemon must be the only writer of `mcp.json` and must validate it against the approved set (hash) before each start; `propose_connector` returns drafts only. Tool annotations are kept, so read-only means `readOnlyHint` AND a curated list (fail closed). Providers, from official docs on 2026-10-08: Notion `https://mcp.notion.com/mcp` (OAuth + PKCE); Linear's official remote server (OAuth 2.1 with dynamic client registration, or an API key); Atlassian Rovo `https://mcp.atlassian.com/v2/mcp` (OAuth 2.1, or an API token; the explorer's v1 URL was outdated); Slack's official hosted server requires a registered Slack app with client_id + client_secret; Gmail's official `https://gmailmcp.googleapis.com/mcp/v1` is in Developer Preview and needs the user's own Google Cloud project and consent screen; Discord has only community servers (bot token). The import map (S20) found configs for Claude Desktop, Claude Code, Cursor, VS Code, Windsurf, OpenCode, and Gentle Shell on this Mac (key names only).-- **Next step:** user decision on the Slack/Gmail sign-in approach; T17 (UI writer running, now including S21); then T18 implementation and T14 (Linux).+- **L36 (2026-10-08, user decision):** Slack and Gmail: "Guía paso a paso ahora (Recomendado)" — each user creates their own Slack app or Google Cloud project with an in-app guide; no Gentle Dot-owned OAuth apps for now.+- **Next step:** T17 (UI writer running, now including S21); then T18 implementation (it shares the bridge, protocol, and UI with T17, so it starts after T17); then T14 (Linux).