跳到正文
cccskills
免费在 GitHub 公开

markdown-toc

Extract a heading tree with line numbers from a Markdown file before editing. Use it to understand a long document, find an appropriate section for new notes, and check nearby text before making changes.

中文简介正在准备中。当前显示英语简介。

原文查看原文说明

Extract a Markdown heading tree with line numbers before editing or integrating notes. Use when you need to inspect a long Markdown file quickly and choose the best insertion point instead of editing blind.

查看安装方法

适用场景

  • Reviewing the structure of a long Markdown document
  • Finding the right section for additional notes
  • Checking existing headings to avoid duplicate sections
  • Inspecting nearby text before editing a note

包含的文件(3)

  • SKILL.md1.5 KB
  • agents/openai.yaml289 B
  • scripts/extract_toc.py2.0 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Markdown TOC

Use this skill when

Use this skill before editing a long Markdown file, especially when you need to:

  • inspect the heading structure quickly;
  • choose the best section for new content;
  • avoid creating redundant sections; or
  • review nearby lines before patching a note.

Quick start

Resolve {baseDir} to this skill’s actual directory, then run the bundled script. It reports ATX (#) headings, excluding fenced code; Setext headings and full Markdown parsing are outside its scope:

python3 "{baseDir}/scripts/extract_toc.py" /absolute/path/to/file.md

In this repository, common targets include:

python3 "{baseDir}/scripts/extract_toc.py" Notes/Gourmet.md
python3 "{baseDir}/scripts/extract_toc.py" "Notes/AI-Agent-Product&PE.md"

Workflow

  1. Run the TOC script on the candidate file.
  2. Read the returned heading tree and line numbers.
  3. Open the most likely section neighborhood with sed -n '<start>,<end>p' or nl -ba.
  4. Insert into an existing section when possible.
  5. Create a new section only when the file truly lacks a clean landing spot.

Output format

The script prints a compact tree like this:

TOC
--------------------------------------------------
# Title (line 1)
  ## Section (line 20)
    ### Subsection (line 42)

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Gather recent AI products, papers, tools, and viewpoints into a Chinese and English HTML daily report. Select up to ten supported items, check original sources where possible, and summarize shared trends with practical next actions.

中文简介正在准备中。当前显示英语简介。

  • Reviewing recent AI developments each morning
  • Tracking research and tools for AI agents
  • Choosing what to read or try next
huangruiteng/CS-Notes40112026年10月21日 更新

Retrieve an arxiv paper's full text from its HTML version using an ID or URL. Extract readable text with section structure, optionally save it to a file, and prepare it for reading, notes, or technical analysis.

中文简介正在准备中。当前显示英语简介。

  • Reading a paper from an arxiv ID or URL
  • Extracting full text for research notes
  • Saving long papers for section-by-section reading
huangruiteng/CS-Notes40112026年10月21日 更新

ask-echo

免费

Search the web or find images through the Ask-Echo API from 火山引擎. Retrieve result details, request an AI-generated summary, and narrow searches by time range or selected websites.

中文简介正在准备中。当前显示英语简介。

  • Finding web pages about a specific topic
  • Getting an AI-generated summary of search results
  • Searching for images
huangruiteng/CS-Notes40112026年10月21日 更新

Build or update the BlueBubbles channel plugin for Clawdbot. The skill explains code locations, existing helper functions, message delivery, connection checks, and webhook handling, which receives incoming messages and attachments through HTTP notifications.

中文简介正在准备中。当前显示英语简介。

  • Building or updating the BlueBubbles channel plugin
  • Implementing message delivery and connection checks
  • Handling incoming messages and attachments through webhooks
huangruiteng/CS-Notes40112026年10月21日 更新

Turn API documentation, SDKs, or existing scripts into reusable command-line tools for Codex. Build focused read and write commands, stable JSON output, authentication checks, and a companion skill explaining how future sessions should use the tool.

中文简介正在准备中。当前显示英语简介。

  • Turning an API into reusable commands
  • Making an internal script usable across projects
  • Adding JSON output and authentication checks
huangruiteng/CS-Notes40112026年10月21日 更新

Improve existing code through up to two optimization rounds, measuring execution time and memory use against a baseline. Verify that results remain correct, save the optimized code, and document changes, measured gains, and trade-offs in a report.

中文简介正在准备中。当前显示英语简介。

  • Improving the performance of existing code
  • Comparing execution time and memory use with a baseline
  • Checking that optimized code produces correct results
huangruiteng/CS-Notes40112026年10月21日 更新

查看 huangruiteng 的全部技能

报告此技能的问题