markdown-search

markdown-search is a skill for Claude Code, Codex from eaglesakura/agent-skills. It costs 162 tokens per session (1,727 once invoked), scanned A, original, MIT.

A staged search method for Markdown documents that reads headings first, then selected sections, and the full text only when needed.

In plain words
What is it for?
It is for checking project documentation before coding, design, or review, including finding DO and DO NOT sections across large Markdown files.
Why use it?
It helps agents find relevant rules and knowledge while using less context than loading every document in full.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions AGENTS.md.

Good fit It is for checking project documentation before coding, design, or review, including finding DO and DO NOT sections across large Markdown files.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/eaglesakura/agent-skills/markdown-search
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.

Any agent
npx skills add eaglesakura/agent-skills --skill markdown-search
Clone the repo
git clone --depth 1 https://github.com/eaglesakura/agent-skills

Made for: Claude Code, Codex.

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-search

README.md
[![agentmods](https://agentmods.dev/badge/skills/eaglesakura/agent-skills/markdown-search/github.svg)](https://agentmods.dev/skills/eaglesakura/agent-skills/markdown-search)
Your own site
<a href="https://agentmods.dev/skills/eaglesakura/agent-skills/markdown-search"><img src="https://agentmods.dev/badge/skills/eaglesakura/agent-skills/markdown-search/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-search

Your own site · 80×15
<a href="https://agentmods.dev/skills/eaglesakura/agent-skills/markdown-search"><img src="https://agentmods.dev/badge/skills/eaglesakura/agent-skills/markdown-search.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 162 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,727 The whole file, excluding the scripts and references it only reads on demand.
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.00162 $0.01727
Opus 5.5 $0.00065 $0.00691
Sonnet 5.5 $0.00032 $0.00345
Haiku 4.5 $0.00016 $0.00173

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

Security

Grade A, and why

markdown-search 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.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/md_section.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

packages/agentic-workspace/.apm/skills/markdown-search/SKILL.md · 116 lines

How it starts

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

ドキュメント検索(Context 最適化)

実装・設計・レビューの前に、既存ドキュメントから必要最小限だけを Context に載せる SKILL である。 全文をいきなり読まず、見出し一覧(行範囲)→ 指定範囲 →(必要なら)全文 の順で深さを上げる。

段階の意図は references/context-loading.md を参照する。

いつ使うか

  • コーディング・詳細設計・レビュー前のナレッジ収集
  • 「どこに書いてあるか」を探すとき
  • ### DO: / ### DO NOT: を横断したいとき
  • 大きな *.md を読む前に構造だけ把握したいとき

優先して見る配置

リポジトリルート(.git があるディレクトリ)からの相対パス:

  • AGENTS.md やRule/Instructionによって指定されたプロジェクト固有ディレクトリ
  • docs/: 標準ドキュメントディレクトリ
  • README.md: 標準README
  • .cursor/skills/
  • .agents/skills/
  • apm_modules/
  • .ai-agent/memory/(場所は workspace-layout / 用途は workspace-agent-temporary)

同梱スクリプト

行範囲付き TOC と範囲抽出は、この SKILL の scripts/md_section.py を使う(Python 3 / 標準ライブラリのみ)。 SKILL_DIR は本 SKILL.md があるディレクトリ(.cursor/skills/・.agents/skills/・packages/.../.apm/skills/ いずれでも可)。

SCRIPT="$SKILL_DIR/scripts/md_section.py"

# Stage 1: 見出し + 行範囲(子見出しを含む終端)
# 内容 SHA-256 が同一のファイルは、先に現れた 1 件だけ対象にする(コピー二重ロード防止)
python3 "$SCRIPT" toc path/to/file.md
python3 "$SCRIPT" toc --max-level 2 path/to/dir
python3 "$SCRIPT" toc --grep 'DO NOT' path/to/file.md

# 内容重複を落とした path 一覧だけ欲しいとき
python3 "$SCRIPT" unique path/to/directory
python3 "$SCRIPT" unique -v path/a.md path/b.md   # 除外した path を stderr に出す

# Stage 2: 指定範囲だけ出力
python3 "$SCRIPT" print path/to/file.md 629 637
python3 "$SCRIPT" print path/to/file.md --at 675
python3 "$SCRIPT" print path/to/file.md --title '循環参照'

path:start-end が既に分かっているときは sed -n 'start,endp' file でもよい。

コードフェンス内の # は見出し扱いにしない。終端は同レベル以上の次見出しの直前(末尾空行は trim)。 toc / unique は既定で内容ハッシュ重複を除外する。意図的に全コピーを見たいときだけ toc --keep-duplicates を使う。

把握手順(3 段階)

Stage 1 — 見出し一覧と行範囲を取る

  • 対象 path(ファイルまたは少数の候補)を決め、TOC を取る
  • 複数ファイル横断の当たり付けは --max-level 2 から始め、必要ならレベルを下げる
  • 出力の path:start-end と見出しテキストだけで関連性を判断する(この時点で本文を読まない)
  • HQ / APM で同内容が複数 path にコピーされていることがある。内容ハッシュが一致するファイルは先頭 1 件だけを候補にし、以降の Stage でも同じ本文を二重ロードしない

DO / DO NOT を探すときも、まず TOC か見出し grep で当たりを付ける。 横断検索の前に unique で重複を落とし、一致する内容は最初の 1 ファイルだけを対象にする:

Read the full file on GitHub · 116 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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 · 116 lines · 162 tokens per session scan A 976ee7728a01

Subscribe to this mod's changes

markdown-search is a skill published in the GitHub repository eaglesakura/agent-skills (2 stars, last pushed 1mo ago), licensed MIT. It adds 162 tokens to every session and 1,727 once invoked, about $0.0006 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-31.

Related

markdown-search compared with skills from other repositories

markdown-search next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
markdown-searcheaglesakura/agent-skillsSkill21mo agoMITA162Claude Code, Codex
imagegenopenai/codexSkill134ktodayApache-2.0A113Codex
local-ai-agentsmicrosoft/ai-agents-for-beginnersSkill79ktodayMITA200Claude Code, Codex
playwright-climicrosoft/playwrightSkill99ktodayApache-2.0A19Claude Code
systematic-debuggingobra/superpowersSkill314k4d agoMITA21Claude Code
next-cache-components-adoptionvercel/next.jsSkill143ktodayMITA95Claude Code
chat-pet-sprite-creationmicrosoft/vscodeSkill195ktodayMITA53Claude Code, Codex