An Obsidian plugin that integrates Claude's Agent SDK to help you organize, search, and maintain your vault using natural language commands.
- π€ Natural Language Control - Ask the agent to organize notes, search content, or manage your vault
- π Smart Linking - Automatically suggests and creates [[wiki links]] between related concepts
- π Powerful Search - Full-text search and backlink discovery
- π Web Integration - Search the web, fetch content from URLs, and incorporate external information
- π Flexible Inbox Processing - Process captures from your inbox (daily notes, scratchpad, etc.) into organized permanent notes
- π Stop Button - Interrupt the agent anytime with a dedicated stop button
- β¨ Modern UI - Smooth animations, thinking indicator, and polished chat interface
- βοΈ Fully Customizable - Edit workflow preferences to match your PKM system and vault structure
- π οΈ Obsidian-Specific Tools:
list_pages()- List all markdown files organized by foldersearch_vault(query)- Full-text search across your vaultget_backlinks(page)- Find pages that link TO a specific pageget_outgoing_links(page)- Find what a page links TOget_daily_note(date)- Get path to daily notes
Plus access to all Claude Code built-in tools (Read, Edit, Write, Bash, Glob, Grep)!
- Obsidian Desktop - This plugin only works on desktop (not mobile)
- Claude Code CLI - Install the Claude Code command-line tool
- Install:
npm install -g @anthropic-ai/claude-code - Or download from Claude Code releases
- Install:
- Anthropic API Key - Configure Claude Code with your API key
- Get key: Anthropic Console
- Configure: Run
claude configin your terminal
Test that Claude Code is working:
claude --version- Download the latest release from the Releases page
- Extract the files to your vault's plugins folder:
<vault>/.obsidian/plugins/obsidian-agent/ - The folder should contain:
main.jsmanifest.jsonstyles.css(if present)
- Reload Obsidian
- Enable "Obsidian Agent" in Settings β Community Plugins
- Install the BRAT plugin
- Add this repository:
szweibel/obsidian-agent-plugin - BRAT will auto-update the plugin when new versions are released
- Open Settings β Obsidian Agent
- Click "Auto-Detect" to find your Claude Code CLI path
- If auto-detect fails, manually enter the path (e.g.,
C:\Users\YourName\.local\bin\claude.exeon Windows)
- If auto-detect fails, manually enter the path (e.g.,
- (Optional) Customize the Workflow Preferences to match your vault
The workflow preferences control how the agent organizes your vault. You can customize:
- Folder Structure - Update folder names to match your vault (e.g., change
Library/toWork/) - Inbox System - Configure for daily notes, scratchpad, inbox file, or your own system
- Processing Workflow - Modify how the agent processes and organizes content
- Linking Philosophy - Adjust how aggressively the agent creates links
Examples:
- Daily notes workflow: Change
Scratchpad.mdtoDaily/YYYY-MM-DD.mdthroughout the workflow - Custom inbox: Use
Inbox.md,Capture.md, or whatever you prefer - Different folder names: Replace
Library/with your own folder structure
Note: The default workflow uses Scratchpad.md as an inbox, but you can easily customize it. Core rules and tool descriptions are protected - only workflow preferences are customizable.
Extend the agent with your own tools by wrapping external scripts/commands. This allows you to add domain-specific functionality like library catalog search, database queries, or custom APIs.
Create a tools config file (e.g., ~/my-tools.json):
{
"tools": [
{
"name": "search_library",
"description": "Search the library catalog for books and articles",
"parameters": {
"title": {"type": "string", "optional": true, "description": "Search by title"},
"author": {"type": "string", "optional": true, "description": "Search by author"}
},
"command": "python3",
"args": ["/path/to/library_search.py"],
"env": {
"API_KEY": "your-key-here"
}
}
]
}OS-Specific Command Examples:
Windows with WSL:
{
"command": "wsl",
"args": ["python3", "/home/user/scripts/tool.py"]
}Windows (native Python):
{
"command": "python",
"args": ["C:\\Users\\YourName\\scripts\\tool.py"]
}macOS/Linux:
{
"command": "python3",
"args": ["/home/user/scripts/tool.py"]
}Configuration:
- Set Custom Tools Config Path in plugin settings to your config file path
- Reload the plugin
- Your custom tools will appear alongside built-in Obsidian tools
Requirements for scripts:
- Accept parameters as CLI arguments (e.g.,
--title="..." --author="...") - Output JSON to stdout
- Exit with code 0 on success
The plugin handles path resolution (supports ~, absolute paths like C:\ or /, and relative to vault), and works cross-platform (Windows, macOS, Linux).
- Ribbon Icon: Click the bot icon in the left sidebar
- Command Palette:
Cmd/Ctrl+Pβ "Open Agent Chat" - Keyboard Shortcut: Configure in Settings β Hotkeys
Search and Explore:
- "Search for 'teaching' in my vault"
- "What pages link to the Teaching page?"
- "Show me all notes in the Library folder"
Web Integration:
- "Search the web for recent developments in AI and summarize them"
- "Fetch the content from this URL and create a note"
- "Find information about Zettelkasten method and add it to my vault"
Organization:
- "Process my scratchpad" or "Process my daily notes from the last week"
- "Organize the captures into separate notes"
- "Move the content about books to a new Books note"
- "Create atomic notes from my inbox"
Linking:
- "Find related notes that should link to this Teaching Philosophy page"
- "What concepts in this note deserve their own atomic notes?"
Settings:
- "Turn on line numbers in Obsidian"
- "Show me my Obsidian settings"
- Clickable Links - Click [[wiki links]] in responses to open notes
- Tool Indicators - See what tools the agent is using (shown as π§ tool_name)
- Thinking Indicator - Animated indicator shows when the agent is processing
- Stop Button - Interrupt the agent mid-response if needed
- Clear Button - Start a fresh conversation (clears history)
- Session Memory - Agent remembers the entire conversation until you clear it
- Modern UI - Smooth animations, polished styling, and professional appearance
Solution:
- Verify Claude Code is installed:
claude --version - Go to Settings β Obsidian Agent
- Click "Auto-Detect" or manually enter the CLI path
- Common paths:
- Mac/Linux:
~/.local/bin/claudeor/usr/local/bin/claude - Windows:
C:\Users\YourName\.local\bin\claude.exe
- Mac/Linux:
Solution:
- Verify your API key is configured:
claude config - Check your API key at Anthropic Console
- Ensure you have API credits available
Solution:
- Check the browser console (Ctrl+Shift+I / Cmd+Option+I)
- Look for
[ObsidianAgent]log messages - Try clearing the chat and starting a new session
- Verify the workflow preferences in settings haven't been corrupted
Solution:
- Open Settings β Obsidian Agent
- Edit the Workflow Preferences to match your folder names and workflow
- Update references like
Library/,Scratchpad.md, etc. to match your vault
- Local Processing - All vault operations happen locally on your machine
- API Calls - The plugin sends your queries and vault content to Anthropic's API via Claude Code
- No Telemetry - This plugin doesn't collect any usage data
- Permissions - The agent runs with
bypassPermissionsmode for seamless file operations
Important: Be mindful that vault content is sent to Anthropic's API. Don't use this plugin with sensitive/confidential information unless you're comfortable with that.
# Clone the repository
git clone https://github.com/szweibel/obsidian-agent-plugin.git
cd obsidian-agent-plugin
# Install dependencies
npm install
# Build
npm run build
# Development (watch mode)
npm run devsrc/
main.ts - Main plugin class, tools, and chat UI
settings.ts - Settings interface and UI
dist/
main.js - Built plugin (generated)
manifest.json - Plugin metadata
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
MIT License - see LICENSE file for details
- Built with Claude Agent SDK
- Uses Obsidian Plugin API
- Inspired by the Zettelkasten and PKM communities
- Issues: GitHub Issues
- Discussions: GitHub Discussions
Note: This plugin is not officially affiliated with Obsidian or Anthropic.