Skip to content
Back to search

gemini-obsidian

A Gemini CLI extension for interfacing with an Obsidian vault with local first RAG capabilities

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today

Check it deeper on your machine

It has changed since its scan on 11 Nov 2026.

As a Claude Code plugin, install it and then ask Claude Code:

/plugin marketplace add keithmackay/mackayi/plugin install scanskillsafety@mackayiDo a deep scan of https://github.com/thoreinstein/gemini-obsidian with scanskillsafety

Or from a terminal, clone it and run it:

git clone https://github.com/keithmackay/scanskillsafety-skill ~/.claude/skills/scanskillsafetynode ~/.claude/skills/scanskillsafety/cli.cjs --deep 'https://github.com/thoreinstein/gemini-obsidian'

It checks the exact commit: every file, its packages against OSV (api.osv.dev), how it compares with this page's scan (findsafeskills.com receives the repository's address), and, if you agree, Claude reading every file with your own Claude subscription. It never runs the code.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/thoreinstein--gemini-obsidian/badge.svg)](/listings/thoreinstein--gemini-obsidian)

HTML

<a href="/listings/thoreinstein--gemini-obsidian"><img src="/api/listings/thoreinstein--gemini-obsidian/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

1. **Install via Gemini CLI**:

   gemini extensions install https://github.com/thoreinstein/gemini-obsidian

2. **Install Native Dependencies**: This extension requires native binaries for semantic search. You **must** run `npm install` inside the extension directory:

   cd ~/.gemini/extensions/gemini-obsidian && npm install

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 154 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

This file has changed since it was scanned, so this is not exactly the text that was scanned, and no line is marked. The findings are listed with the safety scan above.

  1. # Gemini Obsidian Extension
  2. This is a powerful [Gemini CLI](https://github.com/google/gemini-cli) extension that integrates your **Obsidian Vault** directly into your AI workflow. It transforms Gemini into a "Second Brain" assistant capable of reading, searching, connecting, and managing your notes.
  3. ## Features
  4. - **🧠 Semantic Search (RAG)**: Ask natural language questions about your notes. The extension indexes your vault using embeddings (via LanceDB) to find relevant context.
  5. - **🕸️ Graph Traversal**: Navigate your knowledge graph. Find backlinks (`[[linked from]]`) and outgoing links to surf your ideas.
  6. - **🛠️ Link Repair**: Audit broken wikilinks and make surgical in-note replacements without rewriting whole files.
  7. - **📝 Smart Journaling**: Fetch today's daily note or append logs to specific headings (e.g., `## Work Log`) with timestamps.
  8. - **⚡ Management**: Create, move, rename notes, safely update YAML frontmatter in single or batch mode, and edit specific sections.
  9. - **🔍 Fuzzy Search**: Quickly find files by name or content.
  10. ## Demo
  11. ![demo.gif](docs/demo.gif)
  12. ## Prerequisites
  13. - **Node.js**: v18 or higher.
  14. - **Gemini CLI**: The host application for this extension.
  15. - **Obsidian Vault**: A local folder containing your markdown notes.
  16. ## Installation
  17. 1. **Install via Gemini CLI**:
  18. ```sh
  19. gemini extensions install https://github.com/thoreinstein/gemini-obsidian
  20. ```
  21. 2. **Install Native Dependencies**:
  22. This extension requires native binaries for semantic search. You **must** run `npm install` inside the extension directory:
  23. ```sh
  24. cd ~/.gemini/extensions/gemini-obsidian && npm install
  25. ```
  26. ## Configuration
  27. The extension needs to know where your Obsidian vault is located.
  28. **Option 1: Environment Variable**
  29. Set `OBSIDIAN_VAULT_PATH` in your shell profile:
  30. ```bash
  31. export OBSIDIAN_VAULT_PATH="/Users/you/Documents/MyVault"
  32. ```
  33. **Option 2: Runtime Configuration**
  34. The first time you use a tool, gemini will ask for your vault path and call `obsidian_set_vault`. The path must be an existing Obsidian vault (a folder containing `.obsidian`). It is cached in `~/.gemini-obsidian.config.json`.
  35. Tools always operate on the configured vault. They do not accept a per-call vault path.
  36. ## Data Storage & Troubleshooting
  37. - **Vector Index**: The semantic search index is stored locally in `~/.gemini-obsidian-lancedb`.
  38. - **Module Not Found Error**: If you see an error like `Cannot find module '@lancedb/lancedb'`, it means the native dependencies were not installed. Run `npm install` in the extension directory as shown in the Installation section.
  39. - **Cache Reset**: If you suspect the index is corrupted or want a fresh start, you can manually delete the `~/.gemini-obsidian-lancedb` folder. The next time you run `/obsidian:index` or `obsidian_rag_index`, it will be recreated.
  40. - **Logs**: If you encounter issues, check the extension logs. Since this runs as an MCP server, errors are typically output to stderr.
  41. ## Indexing Performance Tuning
  42. > [!WARNING]
  43. > Initial semantic indexing can be time- and resource-intensive, especially on large vaults.
  44. > For first-time indexing on larger vaults, prefer running indexing directly from the extension directory (outside an active Gemini chat session):
  45. > `node dist/index.js obsidian_rag_index`
  46. ### Initial Indexing Expectations
  47. - Recommended threshold for one-time CLI indexing: vaults with roughly `500+` markdown files.
  48. - CPU usage can stay high for the full indexing run (multiple cores active).
  49. - In a real-world test with `~1000` files (`957` notes), indexing produced `13,296` chunks and took about `11 minutes` (`11:01`, ~`374%` CPU).
  50. For large vaults, you can tune indexing throughput and chunk size with environment variables:
  51. - `GEMINI_OBSIDIAN_EMBED_BATCH_SIZE` (default: `48`): Number of chunks embedded per batch.
  52. - `GEMINI_OBSIDIAN_MIN_CHUNK_CHARS` (default: `40`): Skip very small chunks below this size.
  53. - `GEMINI_OBSIDIAN_MAX_CHUNK_CHARS` (default: `1800`): Split oversized paragraphs into smaller embedding-safe segments.
  54. - `GEMINI_OBSIDIAN_TARGET_CHUNK_CHARS` (default: `700`): Merge nearby short segments into larger chunks to reduce total embeddings.
  55. Higher `GEMINI_OBSIDIAN_TARGET_CHUNK_CHARS` generally improves indexing speed by reducing chunk count, but can reduce retrieval granularity.
  56. Example preset for very large vaults:
  57. ```bash
  58. GEMINI_OBSIDIAN_EMBED_BATCH_SIZE=48 \
  59. GEMINI_OBSIDIAN_TARGET_CHUNK_CHARS=900 \
  60. GEMINI_OBSIDIAN_MIN_CHUNK_CHARS=60 \
  61. node dist/index.js obsidian_rag_index
  62. ```
  63. ## Commands
  64. The extension comes with pre-configured slash commands for common workflows:
  65. | Command | Description |
  66. | :--- | :--- |
  67. | `/obsidian:daily` | Retrieve today's daily note, summarize tasks, and ask for updates. |
  68. | `/obsidian:recap` | Harvest cross-workspace sessions and record into today's daily note using custom templates. |
  69. | `/obsidian:ask` | Ask a question to your vault using RAG (e.g., `/obsidian:ask "What did I learn about React?"`). |
  70. | `/obsidian:search` | Fuzzy search for files by name or content. |
  71. | `/obsidian:index` | Trigger a manual re-index of the vault for semantic search. |
  72. ## Available Tools
  73. The following tools are exposed to the Gemini agent:
  74. ### Retrieval & Search
  75. - `obsidian_rag_index`: Index the vault for semantic search.
  76. - `obsidian_rag_query`: Perform a semantic search query.
  77. - `obsidian_search_notes`: Simple text/filename search.
  78. - `obsidian_list_notes`: List files in a folder.
  79. - `obsidian_read_note`: Read the full content of a note.
  80. ### Graph & Connections
  81. - `obsidian_get_backlinks`: Find all notes that link TO a specific note.
  82. - `obsidian_get_links`: Find all notes linked FROM a specific note.
  83. - `obsidian_get_broken_links`: Find wikilinks that point to missing notes.
  84. ### Management & Journaling
  85. - `obsidian_set_vault`: Set the default Obsidian vault path. Must be an existing Obsidian vault; saved for future sessions.
  86. - `obsidian_create_vault`: Create a new Obsidian vault directory on disk, with optional desktop app registration.
  87. - `obsidian_create_note`: Create a new markdown note.
  88. - `obsidian_append_note`: Append text to the end of a note.
  89. - `obsidian_append_daily_log`: Append text to a specific heading (e.g., "Log") in today's daily note with a timestamp.
  90. - `obsidian_move_note`: Rename or move a note.
  91. - `obsidian_update_frontmatter`: Safely update YAML frontmatter keys in single-key or batch mode.
  92. - `obsidian_replace_section`: Replace the body of a heading without touching the rest of the file.
  93. - `obsidian_insert_at_heading`: Insert content at the beginning or end of a heading section.
  94. - `obsidian_replace_in_note`: Replace the first exact text match in a note for surgical inline edits.
  95. - `obsidian_get_daily_note`: Get or create today's daily note.
  96. - `obsidian_harvest_cli_sessions`: Scan and harvest Gemini CLI terminal sessions across all project workspaces, extracting user intents, topics, and key engineering milestones with support for custom template-driven daily logging and work recaps.
  97. > **Note on Session Formats**: Scans standard JSONL session logs (`session-*.jsonl`). Legacy single-file `.json` sessions from older Gemini CLI versions are not scanned until migrated by opening them in current CLI versions.
  98. > **Privacy Notice**: This tool aggregates user prompts across all terminal sessions on the specified date into the model context. Be mindful if sensitive tokens or credentials were pasted into CLI sessions during the day.
  99. ## Skills
  100. - `obsidian-companion`: Tool selection and vault workflow guidance.
  101. - `compound`: Promote repeated project knowledge into durable global notes.
  102. - `moc-update`: Suggest Maps of Content that should link to a newly created note.
  103. - `link-audit`: Audit broken links, orphans, and cleanup opportunities.
  104. ## Development
  105. ```bash
  106. # Build changes
  107. npm run build
  108. # Type check
  109. npm run type-check
  110. # Run tests
  111. npm test
  112. ```
  113. ## License
  114. ISC

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.