The chat
Hatch has a chat panel in the right sidebar. It answers questions about your notes and proposes changes to them. This page says how it works, where your keys live, and what it can and can't do.
Opening it
- The chat icon in the side panel,
Mod-J, or "Open chat" in the command palette. - On a phone it opens as a full screen sheet.
- Settings are at Settings, AI (
/settings/ai).
What it can do
- Read any note in the open vault. Hidden folders (
.hatch,.obsidian) are left out. - Search notes, list a folder, and look up which notes link to a note.
- Propose a change to a note, or a new note.
What it can't do
- Change a note on its own. Every change shows as a diff with Accept and Reject. Nothing is written before you accept.
- Overwrite a note that changed after the change was proposed. The card says "This note changed since" and offers to run again.
- Delete, move or rename notes (through an API key provider).
- See your API keys. They are sent to the service as a request header, never as part of a message.
Accepting a change
- If the note is open, the change goes in as an edit in the editor. Undo takes it back, and it saves and syncs like typing.
- If the note is not open, it is written through the vault.
- The text from before is kept in History. The new text is kept too, marked "AI edit".
- With several changes waiting, "Accept all" accepts each in turn. Each one is still checked against the note as it is now.
Providers
You pick the provider and the model at the top of the panel.
Anthropic (API key)
- Works on web, phone and desktop.
- Requests go straight from your device to
api.anthropic.com. There is no Hatch server in between. - Plain
fetchwith streaming. No SDK. - The model list comes from Anthropic once a key is saved.
OpenAI-compatible (API key and address)
- Works on web, phone and desktop.
- Covers OpenAI, OpenRouter, Ollama, LM Studio and anything else that speaks Chat Completions.
- Leave the address empty for OpenAI. For Ollama on your computer use
http://localhost:11434/v1. It needs no key. - A local server has to allow requests from the page. For Ollama, set
OLLAMA_ORIGINS. - The model list comes from the server's
/models. If it has none, type the model's name.
Agents on this computer (desktop only)
- Hatch can talk to an agent you installed and signed in to yourself: Claude Code, Codex or Gemini CLI.
- Hatch starts the agent as a child process in your vault folder and talks to it over the Agent Client Protocol (ACP).
- Hatch never sees, stores or passes on your sign-in. It never offers a login. If the agent says it is signed out, run it in a terminal and sign in there (
claude,codex login,gemini). - Settings, AI shows which agents were found, and the command to install one. Hatch shows the command as text. It never runs it.
- The agent also gets Hatch's own MCP server, read-only, so it can search notes and read the component guide.
Programs Hatch looks for:
| Agent | Program | Install |
|---|---|---|
| Claude Code | claude-agent-acp | npm install -g @anthropic-ai/claude-code @agentclientprotocol/claude-agent-acp |
| Codex | codex-acp | npm install -g @openai/codex @agentclientprotocol/codex-acp |
| Gemini CLI | gemini --acp | npm install -g @google/gemini-cli |
The subscription credit note: using Claude Code from Hatch counts as programmatic use. It draws from your plan's monthly Agent SDK credit, billed at API rates. Settings, AI says this in one line.
How an agent's changes reach you:
- When the agent writes a file through Hatch (ACP
fs/write_text_file), nothing is written. It becomes a proposed change with Accept and Reject, like any other. - When the agent asks permission to use one of its own tools, the request shows in the chat with "Allow once" and "Reject". If the request carries a file change, you see it as a diff first.
- After you allow it, the agent writes the file itself, straight to disk. A tool you allowed does not go through Hatch, so there is no Accept step for it and Hatch can't stop it.
- Hatch saves what you are typing before each message to an agent. When the agent reports a changed file, the open note takes the new text at once and History gets an "AI edit" version. If you typed in that note meanwhile, both texts are kept: yours in the note, the agent's next to it as a conflict copy.
- An agent that asks for a file or a permission between messages gets an error at once, so it never hangs waiting.
- A command the agent wants to run shows as the command text. Hatch can't turn what a command does into a diff. Reject it if you are not sure.
- Hatch never picks "always allow" for you. It only offers once or reject.
Ask AI on selected text
- Select text in a note and press Ask AI, the first button of the toolbar over the selection.
- Pick one of the asks (Improve writing, Fix spelling and grammar, Make shorter, Make simpler) or type your own, then Enter.
- The new text shows under the field as it arrives. Nothing in the note changes until you press Replace or Insert below. Undo takes either back in one step.
- Try again asks the same again. Discard or Escape closes it. Stop ends an answer still on its way.
- It uses the provider and model picked in the chat. With an agent picked there, it uses a service you added a key for, because an agent edits files itself. With no key it says where to add one.
- What goes along: the selected text, up to 600 characters on each side of it in the same block, the note's name and your ask. No tools, nothing else from the vault.
- If the text changed while the answer was written (someone else typing), Replace says so instead of writing over it.
- Turning AI chat off in Settings, Features takes the button away too.
Send to AI
Talk a note over with the assistant you already use, without copying and pasting.
- Select text and press Send to AI in the toolbar over it (next to Ask AI), or pick Send to AI in the note's actions, the command palette, or
Mod-Shift-J. - Pick an assistant. Hatch writes a prompt with the note (or the part you selected) and opens the assistant with it waiting in the message box. Nothing is sent until you press send there.
- The assistant you used last comes first next time.
| Assistant | How it opens | What it gets |
|---|---|---|
| Claude | claude.ai/new?q= | The note's text and its path |
| Claude app (desktop) | claude://claude.ai/new?q= | The same, in the desktop app |
| ChatGPT | chatgpt.com/?prompt= | The note's text and its path |
| Grok | grok.com/?q=, which asks before it sends | The note's text and its path |
| Gemini | No link fills its box: the prompt is copied and Gemini opens | The note's text and its path |
| Claude Code | claude-cli://open?cwd=<vault>&q= (a new terminal session) | The note's path. It reads the note from the vault folder |
| Codex | codex://new?path=<vault>&prompt= (the ChatGPT desktop app) | The note's path, the same way |
| Cursor | cursor://anysphere.cursor-deeplink/prompt?text= | The note's path |
| Copy for any AI | The clipboard | The note's text and its path |
Getting answers back into the note:
- A coding agent opens in your vault folder. The prompt asks it to leave the note alone until you ask, then add what you ask it to save to the end of the note under "From Claude Code" (or its own name). Hatch picks up the change like any edit made outside it, and History keeps the version from before.
- A chat app with Hatch's MCP server connected (Claude's desktop app, for one) can read the note by its path and add to it with
append_to_note. The prompt names the path for that. - Any other chat: copy the answer and paste it into the note.
Links have a size limit. When the note is too long for the link, the prompt carries the start of the note and says the rest is on the clipboard, and Hatch copies the whole prompt.
In Settings, AI, Send to AI: turn assistants on or off, and add one of your own as a web address with {prompt} where the prompt goes (https://chat.example.com/?q={prompt}). Only https addresses are taken, or http on this computer.
What Hatch never does: talk to an assistant itself, see its sign-in, or send anything before you press send. Links that send at once (Perplexity's) are left out for that reason. The desktop app opens only the app links in the table, and only with your open vault as the folder (isAppLink in packages/ai/src/sendTo.ts, checked in the main process). Turning AI chat off in Settings, Features takes Send to AI away too.
Where keys live
- Never in the vault. Never synced. Never in a log.
- Desktop: the system keychain, through Electron
safeStorage. The file is in Hatch's own data folder. - Web and phone: this device's browser storage (IndexedDB). The key stays on this device.
- Linux without a keychain (no GNOME Keyring or KWallet): Electron would fall back to a fixed password, which protects nothing. Hatch keeps the key in memory until you close it, and the settings page says so.
- If the browser won't store anything, the key is kept until you close Hatch, and the settings page says so.
- "Remove key" deletes it from the device.
- A saved key is never shown again. Paste a new one to replace it.
Where conversations live
- On this device, in IndexedDB. Not in the vault, and not synced.
- The last 30 per vault are kept. "Earlier chats" at the top of the panel lists them.
- A conversation with an agent picked up after a restart starts a new agent session. Hatch passes along the earlier messages as text.
What goes with a message
- The open note, by default. Remove its chip to leave it out.
- The text you selected in the note, when there is some.
- Notes you add by typing
@. - With an API key provider the text of these notes is sent along. An agent gets their paths and reads them itself.
In the panel
Thinking. While the model thinks, a "Thinking" line shows what it is thinking about. It folds to "Thought for 6s" once it moves on. Open or close it yourself and it stays that way. Claude 4.6 and later (Haiku from 5) are asked for a summary of their thinking (adaptive thinking). The signed thinking goes back to Anthropic unchanged with the tool results, as the API requires. OpenAI-compatible servers that send
reasoning_contentorreasoning, and agents that share their thoughts, show the same way.Steps. Two or more tool calls in a row fold into one line, like "Read 3 notes, searched twice". While they run, the line says what is happening now ("Reading Cabin"). Open it to see each step. A step that failed says why.
Notes used. Under an answer, "Used 3 notes" opens into links to the notes it read to answer. An agent's own reads count too.
Copy, try again, edit. Under each answer, copy it as Markdown. Under the last one, try again (the same message, with what went with it) or edit your message. Sending the edit replaces your message and the answer after it. Changes that were still waiting go with it. Accepted ones stay in their notes and in History.
Scrolling. The panel scrolls only when you ask it to. A new message starts near the top, with a little of the turn before it still showing, and the answer grows into the space below. Text that arrives out of view stays there, and "Jump to latest" takes you to it. Once you're at the end, the newest text stays in view. Selecting text holds it still. An earlier chat opens at your last message.
Starter questions. An empty chat offers a few questions you can ask with one press. With the open note going along they are about that note (summarize it, find related notes, turn it into slides).