claude-obsidian-sync
MGEncrypted/claude-obsidian-sync
Mirror your Claude Code chat transcripts into an Obsidian vault — automatically, on a schedule. Credential-scrubbed, project-tagged, graph-friendly. Stdlib-only Python.
Instalação
npx convez-ai MGEncrypted/claude-obsidian-sync1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.
Métricas
README
A tradução para o português deste README ainda está na fila.
claude-obsidian-sync
Mirror your Claude Code chat transcripts into an Obsidian vault — automatically, on a schedule.
Claude Code stores each session as a JSONL transcript. This tool turns those into clean, human-readable Markdown notes in your vault, so your conversations become part of your second brain: searchable, linkable, and reloadable as context even after /compact or /clear.
What it does
- Readable notes — extracts the actual conversation, collapses verbose tool calls into one-line summaries.
- Credential scrubbing — API keys, tokens, JWTs, and inline passwords are redacted before anything touches the vault.
- Project auto-detection — each session is tagged with a project based on keyword matching, and the filename is prefixed with the project so Obsidian's graph view stays readable (
Backend 2026-06-11 fix-auth-flow.mdinstead of an opaque UUID). - Generated index —
_INDEX.mdgroups every active session by project. - Permanent archive — sessions inactive for more than N days move to
_archive/and are kept there even after the original transcript is purged.
Usage
export CLAUDE_PROJECTS_ROOT="$HOME/.claude/projects"
export OBSIDIAN_CHAT_SYNC_DIR="$HOME/ObsidianVault/Knowledge/Chat Sync"
python claude_obsidian_sync.py
Run it on a schedule (cron, systemd timer, or Windows Task Scheduler) every 15–30 minutes for a continuously up-to-date mirror.
Configuration
| Env var | Default | Purpose |
|---|---|---|
CLAUDE_PROJECTS_ROOT | ~/.claude/projects | Where Claude Code stores session folders |
OBSIDIAN_CHAT_SYNC_DIR | ~/ObsidianVault/Chat Sync | Destination folder in your vault |
CHAT_SYNC_INACTIVE_DAYS | 7 | Days before a session is archived |
Edit the PROJECT_KEYWORDS map at the top of the script to match your own projects.
Requirements
Python 3.8+. No third-party dependencies — standard library only.
License
MIT