moc

moc is a skill for Claude Code, Codex from onebrain-ai/onebrain. It costs 80 tokens per session (1,914 once invoked), scanned A, original, Apache-2.0.

A vault portal generator that creates or refreshes an MOC, or Map of Content, at the vault root with summaries and live note lists.

In plain words
What is it for?
Use it to build or update the main Obsidian overview page, including AI summaries, Dataview queries, and a user-maintained pinned section.
Why use it?
It gives an overview of projects, tasks, recently changed notes, and other vault sections without manually maintaining every link.

Skill for Claude CodeCodex

Part of the onebrain plugin — 32 skills, 5 agents, 2 hooks shipped together

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 skills/onebrain-ai/onebrain/moc
Any agent
npx skills add onebrain-ai/onebrain --skill moc
Clone the repo
git clone --depth 1 https://github.com/onebrain-ai/onebrain

Made for: Claude Code, Codex.

Or install onebrain, the plugin that ships this one along with the rest of its 32 skills, 5 agents, 2 hooks.

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 moc

README.md
[![agentmods](https://agentmods.dev/badge/skills/onebrain-ai/onebrain/moc.svg)](https://agentmods.dev/skills/onebrain-ai/onebrain/moc)
Your own site
<a href="https://agentmods.dev/skills/onebrain-ai/onebrain/moc"><img src="https://agentmods.dev/badge/skills/onebrain-ai/onebrain/moc.svg" alt="Measured on agentmods" height="20"></a>
Per session 80 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,914 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.00080 $0.01914
Opus 5 $0.00040 $0.00957
Sonnet 5 $0.00016 $0.00383
Haiku 4.5 $0.00008 $0.00191

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

Security

Grade A, and why

moc 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 4d 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/plugins/onebrain/skills/moc/SKILL.md · 205 lines

How it starts

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

Vault Portal

Creates or updates MOC.md at the vault root : a hybrid Map of Content with:

  • AI zone: agent-written summary callout (note counts, focus note)
  • Dataview zone: live queries for Tasks, Recently Modified, Projects, Areas, Knowledge, Resources, Bookmarks
  • Static zone: user-maintained Pinned section (never overwritten by the agent)

Usage:

  • /moc : create or refresh MOC.md and open it in Obsidian

Step 1: Read vault configuration

Read onebrain.yml from the current working directory. If it cannot be read or parsed, stop immediately and tell the user:

"onebrain.yml exists but could not be parsed : aborting. Check onebrain.yml for syntax errors and try again. Error: [error]."

Store moc_path = {vault_root}/MOC.md.


Step 2: Scan vault for summary data

Collect the following using Glob to count .md files:

  • projects_count : .md files under [projects_folder]/ (recursive)
  • areas_count : .md files under [areas_folder]/ (recursive)
  • knowledge_count : .md files under [knowledge_folder]/ (recursive)
  • resources_count : .md files under [resources_folder]/ (recursive)
  • inbox_count : .md files directly in [inbox_folder]/ (non-recursive, direct children only)
  • focus_note : the single most recently modified .md file across projects, areas, knowledge, and resources folders. Store its display name (filename without .md extension) and its vault-relative path for use as a wikilink.

If a folder does not exist on disk, use count 0 for that folder : this is expected for new vaults.

If the Glob tool returns an error or cannot enumerate a folder that appears to exist, stop immediately and tell the user:

"Could not scan [folder] : MOC.md was not written. Error: [error]. Resolve the issue and try again."

Do not write MOC.md with potentially incorrect counts.


Step 3: Preserve existing Pinned section

If MOC.md exists:

  • Read the file. If the read fails, stop immediately and tell the user:

    "Could not read existing MOC.md at [moc_path] : aborting to protect your Pinned section. Error: [error]. Resolve the file access issue and try again."

  • Extract created: from the frontmatter : store as created_date (fall back to today if absent)
  • Set is_new_file = false
  • Find the line that starts with ## 📌 Pinned
  • Store everything from that line to the end of file as pinned_content
  • If ## 📌 Pinned is not found in the existing file, warn the user before continuing:

    "Warning: Pinned section (## 📌 Pinned) not found in existing MOC.md : the default placeholder will be used instead. Any content you added below the last recognized section header may not be preserved." Then use the default pinned block.

Read the full file on GitHub · 205 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. 4d ago First seen · 205 lines · 80 tokens per session scan A 7e420d6baa10

Subscribe to this mod's changes

moc is a skill published in the GitHub repository onebrain-ai/onebrain (25 stars, last pushed 6d ago), licensed Apache-2.0. It adds 80 tokens to every session and 1,914 once invoked, about $0.0004 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 skills, from other repositories

excalidraw-diagram

Generate Excalidraw diagrams from text content. Supports three output modes - Obsidian (.md), Standard (.excalidraw), and Animated (.excalidraw with animation order). Triggers on "Excalidraw", "diagram", "standard excalidraw", "animate".

breferrari/obsidian-mind · 67 tokens

mermaid-visualizer

Transform text content into professional Mermaid diagrams for presentations and documentation. Use when users ask to visualize concepts, create flowcharts, or make diagrams from text. Supports process flows, system architectures, comparisons, mindmaps, and more with built-in syntax error prevention.

breferrari/obsidian-mind · 57 tokens

qmd

Search the vault using QMD semantic search. Use PROACTIVELY before reading files. Preference order: (1) MCP tools — mcpqmdquery, mcpqmdget, mcpqmdmultiget, mcpqmdstatus — if they appear in your tool menu, use them first; (2) CLI qmd --index ... as fallback; (3) Grep/Glob only when QMD is not installed. Trigger…

breferrari/obsidian-mind · 142 tokens

obsidian-cli

Interact with Obsidian vaults using the Obsidian CLI to read, create, search, and manage notes, tasks, properties, and more. Also supports plugin and theme development with commands to reload plugins, run JavaScript, capture errors, take screenshots, and inspect the DOM. Use when the user asks to interact with their…

breferrari/obsidian-mind · 102 tokens

deeppapernote

Generate a high-quality deep-reading note for a single paper and write it into an Obsidian-style vault. Use when the user gives a paper title, DOI, URL, arXiv ID, Zotero item, or local PDF and wants a polished Markdown note with strong structure, evidence-based analysis, and figure placeholders.

917Dhj/DeepPaperNote · 71 tokens

paper-glossary

Use when building reusable Obsidian glossary notes from an existing paper source manifest, optionally with a raw-sections override, especially when a reader needs a reviewed shortlist before glossary notes and article links are changed.

917Dhj/DeepPaperNote · 46 tokens