textbook-init

textbook-init is a skill for Claude Code from cabbage2000-lab/textbook-writer-skills. It costs 155 tokens per session (1,650 once invoked), scanned A, original, MIT.

A setup assistant for starting a textbook project or a workspace for several textbooks. It asks about the project, creates the directory structure, and can add version control and a README.

In plain words
What is it for?
Use it before writing a complete textbook to choose its location, plan the workspace, initialise Git if wanted, and hand off to the textbook-writing process.
Why use it?
It gives a new writing project an organised starting point without creating empty files that the main textbook workflow uses to track progress.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: names the AskUserQuestion tool.

Part of the textbook-writer plugin — 5 skills shipped together

Good fit Use it before writing a complete textbook to choose its location, plan the workspace, initialise Git if wanted, and hand off to the textbook-writing process.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cabbage2000-lab/textbook-writer-skills/textbook-init
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 cabbage2000-lab/textbook-writer-skills --skill textbook-init
Clone the repo
git clone --depth 1 https://github.com/cabbage2000-lab/textbook-writer-skills

Made for: Claude Code.

Or install textbook-writer, the plugin that ships this one along with the rest of its 5 skills.

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 textbook-init

README.md
[![agentmods](https://agentmods.dev/badge/skills/cabbage2000-lab/textbook-writer-skills/textbook-init/github.svg)](https://agentmods.dev/skills/cabbage2000-lab/textbook-writer-skills/textbook-init)
Your own site
<a href="https://agentmods.dev/skills/cabbage2000-lab/textbook-writer-skills/textbook-init"><img src="https://agentmods.dev/badge/skills/cabbage2000-lab/textbook-writer-skills/textbook-init/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 textbook-init

Your own site · 80×15
<a href="https://agentmods.dev/skills/cabbage2000-lab/textbook-writer-skills/textbook-init"><img src="https://agentmods.dev/badge/skills/cabbage2000-lab/textbook-writer-skills/textbook-init.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 155 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,650 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00155 $0.01650
Opus 5.5 $0.00062 $0.00660
Sonnet 5.5 $0.00031 $0.00330
Haiku 4.5 $0.00015 $0.00165

Measured 7d ago against content hash 1cc4030f2f48, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

textbook-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 7d 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.

skills/textbook-init/SKILL.md · 80 lines

How it starts

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

textbook-init

动笔前的工作目录规划师:一轮提问弄清作者要写一本还是多本、放在哪里、要不要版本管理,呈现目录方案等确认后创建目录骨架(可含 git 仓库与 README 工作说明),最后把作者交给 textbook 主流程开写。教材项目内部的文件构成以 ../textbook/references/handoff-contract.md(下称"契约文档")第 3 节为唯一权威定义,本 skill 只引用不重复定义。

何时不触发

  • 已有教材项目要续写(目录里有 .progress.json)——直接用 textbook,它会按状态文件定位续点;
  • 作者直接开写、不关心目录规划——textbook 启动时自会询问一次并默认 ./<教材名>/,无需先走本 skill;
  • 整理与教材写作无关的目录——本 skill 只服务教材项目的开局。

与流水线的关系

本 skill 只独立触发:不被 textbook 调度,不进五阶段契约链,产出是"就绪的空工作目录 + 启动指引"。

流水线文件一律不建不改:.progress.json(主 skill 是唯一写者,这是项目红线)、00-前言.md(阶段 5 派生生成)、00-教材设计.md(textbook-outline 写入)、NN-<章标题>.md(逐章生成)、98-参考答案.md(逐章追加)、99-表现性任务.md(阶段 5 派生生成)、术语表.md(主 skill 追加维护)。动机:主 skill 的重入判定靠"这些文件存不存在、内容有没有"定位续点(契约文档第 4 节),预建空文件会让它把全新项目误判成半成品;空壳文件混进交付物也违背"交付即可用"的底线。本 skill 创建的只有目录本身、.gitignore 和 README 工作说明——均在契约之外。

工作流

第 1 步:一轮提问

用 AskUserQuestion 一轮收集四项(触发语已说明的项不再问):

  1. 教材名:如《线性代数入门》——将成为项目目录名;
  2. 规划范围:a) 只写这一本 b) 未来还会写多本(追加:工作区名,默认"教材工作区");
  3. 位置:项目/工作区建在哪个目录下,默认当前目录 ./;
  4. git 版本管理:默认要(教材写作周期以周计,版本保护值回票价);作者明确不要则跳过。

若当前环境没有 AskUserQuestion 工具,降级为编号提问并等待文本回复:

请回答以下问题(回复格式如 "1 线性代数入门 2b 教材工作区 3 ./ 4 要"):
1. 教材名?
2. 规划范围? a) 只写这一本  b) 未来还会写多本(请给工作区名,默认"教材工作区")
3. 建在哪个目录下?(默认当前目录 ./)
4. 要 git 版本管理吗?(默认要)

按语义宽松解析回复,只就有歧义的一项追问。

第 2 步:方案呈现与确认

按 references/workspace-layout.md 第 1、2 节的布局规则组装方案,完整呈现后停下:

  • 目录树预览:含流水线随后会生成的文件,逐项注明"由 textbook 流水线创建"——让作者看到最终形态,同时不误以为本 skill 会建它们;
  • 关键选择及理由:单本还是工作区分层、git 建在哪一层、.gitignore 为什么不忽略 .progress.json;
  • 停点格式沿用契约文档第 5 节:

⏸ 等待确认:工作目录方案(回复"确认"开始创建,或直接提出修改)

作者提出修改 → 更新方案后重新完整呈现再等确认,循环直到明确确认;"确认,但把位置改一下"这类混合答复按修改分支处理(修改优先于确认,判定语义同契约文档第 5 节)。确认前不创建任何东西。

第 3 步:创建与交接

  1. 建目录:按确认的方案 mkdir -p;
  2. git 判重:在目标位置检查是否已处于某个 git 仓库内(方法见 references/workspace-layout.md 第 3 节)——已在,则跳过 git init 并向作者说明原因;
  3. git 初始化(作者要 git 且未命中判重):git init + 写 .gitignore + 首次提交,层级与内容规范见 references/workspace-layout.md 第 3、4 节;
  4. README 工作说明:按 references/workspace-layout.md 第 5 节模板实例化——所有字段填当前项目的真实值,写完通读确认没有残留尖括号或待填空白;
  5. 打印成果与下一步指引:

Read the full file on GitHub · 80 lines

Files

What ships with it

1 file 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. 7d ago Changed 1cc4030f2f48
  2. 1mo ago Changed · +4 lines · +13 tokens per session 4ba39b4cdbd5
  3. 1mo ago First seen · 76 lines · 142 tokens per session scan A 0e86b969ebbc

Subscribe to this mod's changes

textbook-init is a skill published in the GitHub repository cabbage2000-lab/textbook-writer-skills (38 stars, last pushed 8d ago), licensed MIT. It adds 155 tokens to every session and 1,650 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-30.

Related

Other skills, from other repositories

diffler

Generate and deliver a graded comprehension quiz from the current Git branch diff, either in the local terminal or through Google Forms. Use when a user asks to prove, test, or verify understanding of branch changes, a feature branch, or a pull request.

jamestkelly/diffler · 53 tokens

uru-thesis-reviewer

Continuous-feedback reviewer for URU (Universidad Rafael Urdaneta) theses. Emits ordered .md diff files (- old / + new) the author applies manually — never edits the .docx. Covers substance, structure, prose, citations vs NORMASURU2020. Tracks issues across sessions via stable IDs and carry-forward. Use when the user…

ralvarezdev/ralvaskills · 88 tokens

study-artifact-builder

Build a single-file interactive HTML artifact to study a paper's pipeline or dataset until it can be defended from memory — source pinning, paper-versus-code separation, per-component explanation (mechanics, real example, measured on the data, non-obvious details), ablation toggles, SVG diagram, numeric audit. Use…

ralvarezdev/ralvaskills · 98 tokens

uru-thesis-architect

Interview-first drafter for URU (Universidad Rafael Urdaneta) thesis (TEG) chapters — writes one section at a time toward the evaluation rubric the jury grades against, Spanish output, URU chapter order (I. Problema → V. Propuesta), never fabricates data. Complements uru-thesis-reviewer. Use when drafting or iterating…

ralvarezdev/ralvaskills · 85 tokens

uru-thesis-defense-architect

Design URU-style thesis defense presentation specs — fixed institutional slide structure (portada, problema, objetivos, antecedentes, variables, metodología, resultados, conclusiones), Spanish-only content, logo placement rules (large centered cover, small top-left from slide 2). Outputs one .md slide-by-slide spec.…

ralvarezdev/ralvaskills · 85 tokens

design-patterns

Skeptical design-patterns reference catalog for modern Go and Python — keeps repository, adapter, strategy, decorator, observer, builder; flags the rest as anti-patterns. Consultative, not active: consult before introducing a pattern in code-design-refactor or improve-codebase-architecture, or when pushing back on a…

ralvarezdev/ralvaskills · 0 tokens