learn

A memory tool for teaching the agent a fact or preferred way of working and saving it for later conversations.

In plain words
What is it for?
Use it when you want the agent to remember a rule, personal preference, fact, or project-related information.
Why use it?
It keeps important corrections and preferences from having to be repeated in every session.

Skill for Claude CodeCodex

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

Made for: Claude Code, Codex.

Per session 84 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,988 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.00084 $0.01988
Opus 5 $0.00042 $0.00994
Sonnet 5 $0.00017 $0.00398
Haiku 4.5 $0.00008 $0.00199

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

Security

Grade A, and why

learn 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.

.claude/plugins/onebrain/skills/learn/SKILL.md · 186 lines

How it starts

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

Learn

Teach the agent a new fact or behavioral preference. Writes immediately to memory/ — no batch processing.

One-File-Per-Concept Rule

If the user provides multiple facts in one /learn call, create separate files for each concept. Do not combine multiple facts into one file.

Why: Memory files are the unit of deprecation. If fact A becomes outdated but B stays valid, a combined file forces you to either keep stale A or discard still-valid B. Separate files let each fact be independently deprecated or superseded.

Active Projects Intent Detection

Write to MEMORY.md ## Active Projects ONLY when the user message explicitly references a project lifecycle event.

Triggers Active Projects update (write to MEMORY.md):

  • "starting project X", "project Y is done", "adding project Z", "updating status of project A"

Does NOT trigger (write to memory/ file instead):

  • "in project X we use Y", "I worked on project X before"

When unclear → AskUserQuestion: "Add to Active Projects in MEMORY.md, or create a memory file?" Options: active-projects / memory-file

Contradiction Detection

Before writing a new file, grep memory/ for files with overlapping topics or similar content. Scan ONLY files with status: active or status: needs-review — skip deprecated files.

Why: Deprecated files are intentionally retired. Re-surfacing them as conflicts would create ghost conversations about facts the user has already decided to discard.

If a potential conflict is found, show this display block first: ⚠️ Possible conflict with memory/{filename}.md New: "{new fact}" Existing: "{existing fact}"

Then AskUserQuestion:

  • question: "How should I handle this conflict?"
  • header: "Conflict"
  • multiSelect: false
  • options:
    • label: "update", description: "Merge new fact into existing file (old content still partially correct)"
    • label: "supersede", description: "Create new file, deprecate old (old content fully outdated)"
    • label: "separate", description: "Create new file separately (no conflict, keep both)"

Read the full file on GitHub · 186 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 · 186 lines · 84 tokens per session scan A a6eac4889010

Subscribe to this mod's changes

learn is a skill published in the GitHub repository onebrain-ai/onebrain (25 stars, last pushed 5d ago), licensed Apache-2.0. It adds 84 tokens to every session and 1,988 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

llm-wiki

Build and maintain a persistent, interlinked Obsidian-compatible markdown wiki using Karpathy's LLM Wiki pattern. Extension-backed with auto-generated metadata, guardrails, and 14 custom tools (+3 opt-in agent-trajectory tools).

zosmaai/pi-llm-wiki · 52 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