init

A command that creates YAML settings for mdvdb, a tool for searching and organizing collections of Markdown notes. It can create project settings or user-wide defaults.

In plain words
What is it for?
Initializing a Markdown collection, creating global defaults, and changing settings such as the embedding provider, model, search limits, chunking, clustering, and watched folders.
Why use it?
It gives a notes collection an editable configuration for search, text processing, clustering, and file watching instead of relying only on built-in defaults.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/geckse/markdown-vdb/init
Clone the repo
git clone --depth 1 https://github.com/geckse/markdown-vdb
Per session 7 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,002 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00007 $0.01002
Opus 5 $0.00003 $0.00501
Sonnet 5 $0.00001 $0.00200
Haiku 4.5 $0.00001 $0.00100

Measured 2d ago against content hash fd6785dd9ea8, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

init 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 2d 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.

docs/cli/commands/init.md · 168 lines

How it starts

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

mdvdb init

Create a YAML configuration for a collection or for user-wide defaults.

Usage

mdvdb init [--global]
Flag Effect
--global Create user defaults at ~/.mdvdb/config.yaml instead of project config

The standard global flags also apply. Use mdvdb --root <PATH> init to initialize a different collection root.

Project initialization

Run init at the root of a Markdown collection:

cd my-notes
mdvdb init

It creates .markdownvdb/config.yaml with a starter configuration equivalent to:

embedding:
  provider: openai
  model: text-embedding-3-small
  dimensions: auto
  batch_size: 100

search:
  limit: 10
  min_score: 0.0
  mode: hybrid
  rrf_k: 60.0

chunking:
  max_tokens: 512
  overlap_tokens: 50

clustering:
  enabled: true
  rebalance_threshold: 50

watch:
  enabled: true
  debounce_ms: 300

sources:
  dirs: [.]

Unwritten settings retain built-in defaults, including Leiden as the automatic clustering algorithm. Edit the YAML directly or use dotted scalar updates such as:

mdvdb config set embedding.provider ollama
mdvdb config set embedding.model nomic-embed-text
mdvdb config set embedding.dimensions auto

After the first ingest, the directory also contains generated index data:

.markdownvdb/
├── config.yaml
├── index
└── fts/

Features such as Shard-local analysis may later add a disposable cache/ directory.

init creates configuration only. It does not scan, embed, or index files; run mdvdb ingest after configuring a provider.

User defaults

mdvdb init --global

This creates ~/.mdvdb/config.yaml, or $MDVDB_CONFIG_HOME/config.yaml when MDVDB_CONFIG_HOME is set. The generated file is intentionally minimal:

# Values here apply unless project config.yaml overrides them.
# Credentials belong in .env, not YAML.

# embedding:
#   provider: openai
#   model: text-embedding-3-small
#   dimensions: auto

User YAML supplies defaults. Project .markdownvdb/config.yaml is deep-merged over it, and shell MDVDB_* overrides have the highest settings priority.

Read the full file on GitHub · 168 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. 2d ago First seen · 168 lines · 7 tokens per session scan A fd6785dd9ea8

Subscribe to this mod's changes

init is a command published in the GitHub repository geckse/markdown-vdb (23 stars, last pushed 18d ago), licensed MIT. It adds 7 tokens to every session and 1,002 once invoked, about $0.0000 per session on Opus 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

Other commands, from other repositories