DEV Community

Cover image for I Gave My Markdown CRM a Second Brain: obsidian-second-brain in Practice
Evgeniy Uryadov
Evgeniy Uryadov

Posted on Originally published at automata.sale

I Gave My Markdown CRM a Second Brain: obsidian-second-brain in Practice

My CRM isn't an app. It's a folder of Markdown files in an Obsidian vault, and a set of CLI agents that read and write those files. Client chats land there, invoices are generated from it, monitoring alerts get routed through it. The engine is open source (MIT): crm.automata.sale.
It worked for a year. Then it didn't, twice, in ways that cost real money. This post is about the fix: I adopted the open-source obsidian-second-brain methodology in one day, and I'm including the command cheat sheet I now use daily.

Two failures that forced the methodology

Failure one: an agent ran a cleanup pass over the ticket folder and deleted live tickets. Money was attached to them. The rules that should have prevented it existed, but they lived in the agent's session memory. Which is to say: they didn't exist.
Failure two: structural decisions (kill a project, move a client to on-demand monitoring, pick an e-document stack) lived in chat history. Six months later neither I nor the agent could answer "why did we choose X".
Both failures share one root: the database had no discipline. obsidian-second-brain is that discipline, packaged as commands for CLI agents.

The Folder Map trick: no restructuring required

Migration risk was my main concern. The pipeline runs 30+ live automations on a 15-minute communication cycle. Moving to the repo's default layout (wiki folders, daily notes, kanban boards) would break everything.
The methodology handles this natively: commands resolve folders not by hard-coded paths but through a Folder Map table in the vault-root instruction file, and when that map exists, it wins over the built-in defaults. Mine maps note types onto the folders I already had:

| Note type          | Folder                  |
|--------------------|-------------------------|
| Client (company)   | 10_Clients/             |
| Lead / prospect    | 15_Leads/               |
| Task               | 30_Tasks/               |
| Invoice            | 30_Invoices/            |
| Decision (ADR)     | 30_Decisions/           |
| Project            | 50_Projects_Wiki/       |
| Raw sources        | 60_Documents/, Clippings/ (immutable) |
Enter fullscreen mode Exit fullscreen mode

Daily notes stayed out: the message feed replaces them. Kanban stayed out: the dashboard task matrix replaces it. I took the rules and the tools. The structure stayed mine.

The four commands (the cheat sheet)

Each command is a thin skill wrapping the repo's command spec, triggered by a spoken phrase:
| You say | Command | What the agent does |
|---|---|---|
| "save to vault" | osb-save | Scans the session, files updates into client cards as body blocks, tasks through the CRM pipeline, facts with date stamps, plus an ops-log entry |
| "log this decision" | osb-decide | A dated line in the project card, or a full ADR (context, options, rationale, consequences) with the --formal flag |
| "check the vault" | osb-health | Runs a health scan, reports broken links, missing frontmatter, duplicates, stale stamps; edits wait for approval |
| "where's the truth on X" | osb-reconcile | Sweeps contradictions across cards, tickets, and agent memory; clear winners update with history preserved, ties become conflict cards |
The audit scanner is plain Python, no external keys:

python3 obsidian-second-brain/scripts/vault_health.py --path ~/crm-vault --json
Enter fullscreen mode Exit fullscreen mode

Noisy folders get excluded via a .vault-config.json next to the vault.

What the first audit found

1,254 notes scanned, 596 after excluding chat dumps and archives:

  • 158 wikilinks pointing to pages that don't exist
  • 76 notes without frontmatter
  • 4 title duplicates, 8 empty folders None of this was surprising. What changed is that it now surfaces in a report instead of rotting silently. ## What I deliberately skipped The repo ships a research toolkit (Perplexity, Grok, YouTube transcripts) that needs external API keys. I run this pipeline on my own infrastructure without external LLM services, so those stayed out. The core set (writing rules, ADRs, audits, reconciliation) depends on no keys. ## Takeaway If your agent's operating rules live in "somewhere", they don't live anywhere. A Folder Map, a decision log, and four phrases are cheap insurance, and none of it required touching the 30+ automations already in production. tags: aiagents, automation, markdown, productivity --- This article was prepared with AI assistance (drafting and adaptation) and reviewed by the author before publishing. Originally published at https://automata.sale/en/blog/ai-automation/automata-crm-second-brain/

Top comments (0)