
LLM Automation For Obsidian Plugin
A TypeScript Obsidian plugin wiring LLMs into a knowledge base: text/image generation, video summarization, a database-backed RAG engine, flashcards, and coding exercises — across five OpenAI-compatible providers.
The plugin's surface is 40+ Obsidian commands, ribbon icons, side-pane views, and modals across five workflows: text & image generation, summarization & transcripts (article, single-video, and playlist/batch with a processing queue), learning (quizzes, flashcards with a database-backed spaced-repetition scheduler, and C# LINQPad coding exercises with local compile-and-run), knowledge retrieval, and path/tag management.
The provider layer is the defining design choice: five OpenAI-compatible providers behind one factory + service, so every LLM-calling feature is provider-agnostic. The proxy provider is explicitly designed to point at the openai-nim-proxy gateway, making this plugin both a standalone tool and a first-class client of that gateway.
The retrieval subsystem is a local hybrid RAG engine: FTS5 lexical search plus optional semantic search via local Ollama or remote Chutes embeddings, reciprocal-rank fusion, a token-budgeted evidence-pack builder, and a bounded multi-step KnowledgeAgent that can request more reads before answering with citations. A vendored FTS5-enabled sql.js wasm solves an environment-specific problem (Obsidian's bundled wasm lacks FTS5).
Key features
- Five OpenAI-compatible providers (OpenRouter, Chutes, Z.AI, Ollama, proxy) behind one factory.
- Text & image generation with per-run temperature/max-tokens/top-p overrides.
- Article, single-video, and playlist/batch summarization with a processing queue.
- Database-backed spaced-repetition flashcards (Mnemosyne-like scheduler).
- C# LINQPad coding-exercise generation with local compile-and-run (gated).
- Local hybrid RAG: FTS5 + optional semantic embeddings + RRF + bounded KnowledgeAgent with citations.
- Vendored FTS5-enabled sql.js wasm (Obsidian's bundled wasm lacks FTS5).
- 472 Vitest tests across 40 files with a full Obsidian API stub.
Stack
Gallery