markdown-vdb: Instructions file for Claude Code

CLAUDE.md

markdown-vdb CLAUDE.md is an instructions file for Claude Code from geckse/markdown-vdb. It costs 5,817 tokens per session, scanned A, original, MIT.

Repository instructions for a local vector database that stores Markdown files and searches their meaning without requiring separate infrastructure.

In plain words
What is it for?
Use them when changing Markdown ingestion, search, metadata, embeddings, clustering, file watching, the CLI, or Rust tests.
Why use it?
They describe the database’s search, indexing, embeddings, clustering, and file-watching design so changes fit the existing system.

Instructions file for Claude Code

Written for Claude Code: the file is CLAUDE.md.

This is geckse/markdown-vdb's own configuration. It tells Claude Code how to work on markdown-vdb itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything markdown-vdb configures →

Reuse

Borrowing it

Nothing to install: this file belongs to geckse/markdown-vdb. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/geckse/markdown-vdb/main/CLAUDE.md
Clone the repo
git clone --depth 1 https://github.com/geckse/markdown-vdb

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for markdown-vdb CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/geckse/markdown-vdb/claude-md/github.svg)](https://agentmods.dev/instructions/geckse/markdown-vdb/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/geckse/markdown-vdb/claude-md"><img src="https://agentmods.dev/badge/instructions/geckse/markdown-vdb/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for markdown-vdb CLAUDE.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/geckse/markdown-vdb/claude-md"><img src="https://agentmods.dev/badge/instructions/geckse/markdown-vdb/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 5,817 This file is loaded in full into every session.
When invoked 5,817 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.05817 $0.05817
Opus 5.5 $0.02327 $0.02327
Sonnet 5.5 $0.01163 $0.01163
Haiku 4.5 $0.00582 $0.00582

Measured 2mo ago against content hash e1d524f9b5a9, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

markdown-vdb CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

CLAUDE.md · 272 lines

How it starts

The opening of the file, as written. The whole thing — 272 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Markdown VDB

A filesystem-native vector database built around Markdown files. Rust, zero infrastructure, optimized for AI agents.

All 18 implementation phases plus graph-enhanced search, the Leiden/topics clustering rework, and frontmatter relations (phase 31) are complete and passing (1032 tests, clippy clean).

Architecture

┌─────────────────────────────────────────────────────────┐
│                    Agent Interface                       │
│              CLI (clap) + Library API                    │
│         mdvdb search | ingest | status | watch          │
├──────────┬──────────┬───────────┬───────────────────────┤
│  Search  │  Schema  │ Clustering│   File Watcher        │
│  Engine  │  System  │  (linfa)  │   (notify)            │
├──────────┴──────────┴───────────┴───────────────────────┤
│                   Index Storage                         │
│        usearch (HNSW) + rkyv (metadata) + memmap2       │
│          parking_lot::RwLock (concurrency)               │
├──────────┬──────────────────────────────────────────────┤
│ Embedding│   OpenAI | Ollama | Custom (reqwest)         │
│ Providers│   Batch processing + content-hash skip       │
├──────────┴──────────────────────────────────────────────┤
│                  Chunking Engine                        │
│      Heading-split + token size guard (tiktoken-rs)     │
├─────────────────────────────────────────────────────────┤
│              Markdown Parsing & Discovery                │
│    pulldown-cmark + serde_yml + ignore + sha2           │
├─────────────────────────────────────────────────────────┤
│               Foundation & Configuration                │
│      serde_yml + dotenvy + thiserror + anyhow + tracing │
└─────────────────────────────────────────────────────────┘

Project Structure

src/
├── main.rs              # CLI entry point (clap + anyhow)
├── lib.rs               # Public library API (MarkdownVdb)
├── config.rs            # Config loading: shell env MDVDB_* → project YAML → .env secrets → user YAML → defaults
├── format.rs            # Human-readable output formatting (colors, bars, timestamps)
├── error.rs             # Error enum (thiserror)
├── logging.rs           # Tracing subscriber setup
├── discovery.rs         # File scanning with ignore patterns (.gitignore + .mdvdbignore)
├── parser.rs            # Markdown parsing: frontmatter, headings, body
├── chunker.rs           # Heading-based chunking + token size guard
├── search.rs            # Query pipeline, metadata filtering, time decay, graph expansion, results
├── fts.rs               # Full-text search (Tantivy BM25 wrapper)
├── links.rs             # Link graph extraction, backlinks, orphan detection, multi-hop BFS, neighborhood
├── relations.rs         # Frontmatter relations: link-shape predicate, 3-step target resolution, RelationValue/ReferencedBy
├── tree.rs              # File tree with sync status indicators
├── schema.rs            # Auto-infer + overlay schema system
├── clustering/
│   ├── mod.rs           # Cluster types, Clusterer facade, stability matching, topics (multi-label)
│   ├── leiden.rs        # Cosine k-NN graph + seeded Leiden community detection + hierarchy
│   ├── kmeans.rs        # Seeded K-means fallback (also backs edge clustering)
│   └── labels.rs        # TF-IDF keywords (unigrams+bigrams, smoothed IDF), label generation
├── watcher.rs           # Filesystem watcher (notify + debouncer)
├── ingest.rs            # Full + incremental ingestion pipeline
├── embedding/
│   ├── mod.rs           # EmbeddingProvider trait + factory
│   ├── provider.rs      # Trait definition
│   ├── openai.rs        # OpenAI-compatible provider
│   ├── ollama.rs        # Ollama provider
│   ├── batch.rs         # Concurrent batch orchestration (up to 4) + hash skip
│   └── mock.rs          # Mock provider for testing
└── index/
    ├── mod.rs           # Index public API
    ├── types.rs         # StoredChunk, StoredFile, IndexMetadata (rkyv)
    ├── storage.rs       # File I/O: header + rkyv region + usearch region
    └── state.rs         # Runtime operations with RwLock concurrency

tests/
├── api_test.rs          # Library API integration tests
├── cli_test.rs          # CLI binary integration tests
├── chunker_test.rs      # Chunking pipeline tests
├── clustering_test.rs   # Leiden/K-means + topics clustering tests
├── config_test.rs       # Configuration loading tests
├── discovery_test.rs    # File discovery tests
├── embedding_test.rs    # Embedding provider tests
├── fts_test.rs          # Full-text search (Tantivy BM25) tests
├── graph_test.rs        # Graph traversal + multi-hop search tests
├── index_test.rs        # Index storage + mtime tests
├── ingest_test.rs       # Ingestion pipeline tests
├── links_test.rs        # Link graph + backlinks tests
├── parser_test.rs       # Markdown parsing tests
├── relations_test.rs    # Frontmatter relations (populate, graph edges, filters, doctor) tests
├── schema_test.rs       # Schema inference tests
├── search_test.rs       # Search engine + time decay tests
├── tree_test.rs         # File tree tests
└── watcher_test.rs      # File watcher tests

docs/prds/               # PRD specifications for all 18 phases (reference)

Read the full file on GitHub · 272 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 272 lines · 5,817 tokens per session scan A e1d524f9b5a9

Subscribe to this mod's changes

markdown-vdb CLAUDE.md is an instructions file published in the GitHub repository geckse/markdown-vdb (29 stars, last pushed 2mo ago), licensed MIT. It adds 5,817 tokens to every session, about $0.0233 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

markdown-vdb CLAUDE.md compared with instructions from other repositories

markdown-vdb CLAUDE.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
markdown-vdb CLAUDE.mdgeckse/markdown-vdbInstructions file292mo agoMITA5,817Claude Code
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143kyesterdayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149kyesterdayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode