Intermediate 📅 Last Updated: July 1, 2026 ⏱️ 12 min read 📝 Obsidian + AI
Point your AI agent at an Obsidian vault folder. The agent reads your Markdown notes for context and writes new notes back as "memories." Because Obsidian is just files on disk, any agent with file access can use it — no plugin required. For structured read/write, add the Obsidian MCP server so the agent can search, create, and update notes through a clean API.
Read this if: You use Obsidian for notes and want your local AI agent to remember things between sessions — project context, decisions, research, preferences — without copy-pasting them into every chat.
Skip if: You do not use Obsidian. The concepts work with any folder of Markdown files, but the vault structure and MCP steps are Obsidian-specific.
Machine: MSI laptop (dual GPU)
GPU: NVIDIA RTX 5070 Ti Laptop (12GB) + RTX 5070 (12GB)
CPU: Intel Core Ultra 7 255HX (20 cores)
RAM: 96GB
OS: Ubuntu 26.04 LTS
Agent: Goose 1.0 via Obsidian MCP
Date: July 2026
AI models have no memory between sessions. Every new chat starts blank. Obsidian fixes this because it is just a folder of plain-text Markdown files — and agents are excellent at reading and writing files. Your vault becomes a persistent brain the agent can consult and update.
| Without Memory | With Obsidian Memory |
|---|---|
| Re-explain your project every session | Agent reads projects/my-app/context.md and knows instantly |
| Forget decisions from last week | Agent writes decisions to decisions/ and recalls them |
| Lose research across chats | All research lives in research/ as linked notes |
| No continuity | Daily logs in journal/ give the agent full history |
Create these folders in your vault. Each has a specific role for agent read/write.
my-vault/
├── _agent/ # Agent-only zone
│ ├── context.md # Current project state (agent reads this first)
│ ├── preferences.md # Your style/voice/rules
│ └── memory/ # Agent-written memories (decisions, facts)
├── projects/ # One folder per project
│ └── my-app/
│ ├── brief.md # What the project is
│ └── decisions.md # Running log of choices made
├── research/ # Topics the agent can reference
├── journal/ # Daily logs (YYYY-MM-DD.md)
├── templates/ # Note templates the agent uses
└── README.md # How to use this vault (agent reads this)
The _agent/ folder is the key. The agent reads context.md at the start of every session and writes new memories to _agent/memory/. Everything else is your normal Obsidian vault.
cd ~/my-vault
mkdir -p _agent/memory projects research journal templates
touch _agent/context.md _agent/preferences.md
echo "# Project Context" > _agent/context.md
echo "# Agent Preferences" > _agent/preferences.md
Fill in _agent/context.md — this is what the agent reads first every session.
# Project Context
## Current Project
MasterAIKit.com — a local AI guide site.
## Tech Stack
- Static HTML site
- Ollama + Open WebUI + Goose for content
- Deployed via Cloudflare
## Active Tasks
1. Publish 15 launch guides
2. Set up Starter Kit checkout
3. Record setup-review walkthroughs
## Rules
- Test everything on real hardware before publishing
- No generic AI content — every guide has a Tested On box
The simplest method — give the agent file access to the vault (read-write scoped, per our safe file access guide):
goose session --path ~/my-vault --permissions read write
For structured search, create, and update operations, add the Obsidian MCP server to your agent config:
# Goose config (~/.config/goose/config.yaml)
extensions:
obsidian:
type: stdio
command: npx
args: ["-y", "obsidian-mcp"]
env:
OBSIDIAN_VAULT: "/home/you/my-vault"
Now the agent can call tools like search_notes("VRAM"), create_note(), and update_note() instead of raw file operations.
Prompt (save as _agent/instructions.md):
At the start of every session:
1. Read _agent/context.md for current project state.
2. Read _agent/preferences.md for my voice and rules.
3. Check _agent/memory/ for past decisions.
During the session:
- When we make a decision, append it to _agent/memory/decisions.md
- When you learn a new fact, write it to _agent/memory/facts.md
- When I ask "what did we decide about X?", search the memory folder first.
Never edit files outside _agent/ unless I explicitly ask.
| Action | How It Works | File Touched |
|---|---|---|
| Load context | Agent reads context.md at session start | _agent/context.md |
| Recall a decision | Agent searches memory folder for keywords | _agent/memory/*.md |
| Save a decision | Agent appends a dated entry | _agent/memory/decisions.md |
| Save a fact | Agent creates a new note | _agent/memory/facts/[topic].md |
| Update project state | Agent rewrites context.md with new status | _agent/context.md |
The trick is forcing the agent to read and write at the right moments. Put this in your agent's system prompt or instructions file:
## Memory Protocol
- START: Read _agent/context.md and _agent/preferences.md.
- BEFORE answering: If the question references past work,
search _agent/memory/ for relevant notes.
- AFTER any decision: Write a one-line summary to
_agent/memory/decisions.md with today's date.
- END: Update _agent/context.md if project state changed.
Now context survives across sessions. Start a new chat next week, and the agent already knows your project, your rules, and what you decided last time.
Cause: You grant write access to the whole vault. The agent reorganizes your notes or overwrites a journal entry.
Fix: Restrict writes to _agent/ only. Use the file-access permission model from our safe file access guide.
Cause: context.md grows to 5,000 words. The agent spends half its context window reading it.
Fix: Keep context.md under 300 words. Move details to _agent/memory/ and let the agent search them on demand.
Cause: The agent writes decisions without dates. You cannot tell what is current.
Fix: Require ISO dates in the memory protocol: ## 2026-07-01 — Switched to Qwen 2.5 14B for coding.
Cause: Wrong vault path in the env variable, or Node/npx not installed.
Fix: Verify the path is absolute: OBSIDIAN_VAULT: "/home/you/my-vault". Test with npx obsidian-mcp directly.
Before giving any agent write access, enable Obsidian Sync or copy your vault to a backup folder. An agent with write access can delete or corrupt notes. Git is the simplest safety net: cd ~/my-vault && git init and commit before each agent session. See safe file access.
| Level | Setup | Memory Quality |
|---|---|---|
| Basic | Agent reads vault, no writes | Agent knows your context but forgets new info. |
| Standard | Agent reads vault + writes to _agent/memory/ | Full persistence. Best balance of power and safety. |
| Advanced | Obsidian MCP server + structured tools | Agent can search, link, and tag notes intelligently. |
Start with the Standard tier: vault structure + scoped read-write to
_agent/+ the memory protocol in the system prompt. That alone transforms a forgetful chatbot into an agent that knows your project. Add the MCP server only when you need search — for most people, the agent reading and writing Markdown files directly is enough. Put the vault under git so every agent-written memory is versioned and reversible.
Obsidian stores notes as markdown files that agents like Goose can read, search, and write to. The agent uses your vault as a knowledge base - reading past notes for context and saving new findings. With embeddings, agents find relevant info across thousands of notes.
Yes, if the agent saves session summaries to your vault, it reads those in future sessions. This creates persistent memory surviving restarts. Without this, most agents lose all context when sessions end.
Basic setup: point your agent at the vault directory with read-write access. For semantic search, add an embeddings model via Ollama. Total time: 30-60 minutes, mostly for search configuration.
Goose supports it natively through filesystem tools. Any agent reading local files (Cline, AutoGPT, LangChain) can use Obsidian. MCP filesystem servers connect any MCP-compatible agent to your vault.
Reasonably safe if you scope access to a subfolder or use Git for version control. Always back up before granting write access, and use read-only for initial testing. The risk is accidental overwrites, not data theft.
A ready-to-use Obsidian vault pre-structured for AI agent memory. Includes the _agent/ folder system, context and preferences templates, the memory protocol, the MCP config, and a starter set of decision-tracking notes. Download, point your agent at it, and go.
I will set up your Obsidian vault, configure the MCP server, and write your memory protocol. $99.
Get a Setup Review →Get the free Local AI Setup Checklist delivered to your inbox.
Get the Free ChecklistLast Updated: July 1, 2026 — Verified against Obsidian 1.7, Goose 1.0, and obsidian-mcp on Ubuntu 26.04 LTS.