explainer-book
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chineseexplainer-book
explainer-book
explainerペルソナ・図・検証の仕組みは をそのまま使う。先に を読むこと。
このスキルが足すのは、本全体の設計と検査。
explainer../explainer/SKILL.mdスクリプトは、このスキルのディレクトリ(以下 )の にあります。
は、隣の スキルの を呼びます。2 つのスキルは同じ場所に入れてください。
依存の入れ方は の「準備」と同じです。
<skill>scripts/verify-book.mjsexplainerscripts/verify-doc.mjsexplainerThe book edition of .
When a single quick-study guide (within 20 minutes, one example at a time) is not enough, divide the material into chapters and make it something readers learn by doing.
explainerUse the persona, diagram, and validation mechanisms from unchanged. Read first.
This skill adds whole-book design and validation.
explainer../explainer/SKILL.mdThe scripts are located in this skill’s directory (below ), under .
calls the adjacent skill’s . Place the two skills in the same location.
Set up dependencies in the same way as the “Setup” section of .
<skill>scripts/verify-book.mjsexplainerscripts/verify-doc.mjsexplainerいつ本にするか
When to make a book
次のどれかに当てはまったら本にする。1 つも当てはまらなければ、 の 1 本で書く。
explainer- 読了が 20 分を超える
- 読み手が手を動かす演習が要る(読むだけでは「判定できる」ようにならない)
- 概念に順序がある(A を知らないと B が読めない)
Make it a book if any of the following applies. If none applies, write it as a single document.
explainer- Reading takes more than 20 minutes
- Readers need hands-on exercises (reading alone does not enable them to “make a determination”)
- Concepts have a dependency order (B cannot be understood without A)
構成
Structure
<topic>-book/
README.md 目次:想定読者、章ごとの「読み終えたらできること」、章の依存図、再現方法
book.json 章の順序・学習目標・導入する概念・演習(references/book-json.md)
01-quickstart.md 最初の章は必ず quickstart:理論の前に、動く結果に着く
02-….md concept:1 章 1 つの判定を身につける
03-….md practice:演習が中心
checks.json 本文の出力と演習の答えを再生成するコマンド(explainer と同じ形式)
examples/ 章で使うコード・モデル。演習の出発点と答えを別ファイルにする
figures/ book-map.*(生成)と各章の図<topic>-book/
README.md 目次:想定読者、章ごとの「読み終えたらできること」、章の依存図、再現方法
book.json 章の順序・学習目標・導入する概念・演習(references/book-json.md)
01-quickstart.md 最初の章は必ず quickstart:理論の前に、動く結果に着く
02-….md concept:1 章 1 つの判定を身につける
03-….md practice:演習が中心
checks.json 本文の出力と演習の答えを再生成するコマンド(explainer と同じ形式)
examples/ 章で使うコード・モデル。演習の出発点と答えを別ファイルにする
figures/ book-map.*(生成)と各章の図手順
Procedure
1. ペルソナ explainer と同じ。「怪しいところ」から、本全体の問いを 1 つ決める
2. 目標を並べる 問いに答えるために読み手ができるべき判定を 3〜6 個。1 章に 1〜2 個
3. 概念の順序 各判定に要る概念を書き出し、どの章で導入するかを決める(book.json introduces / requires)
4. 実物を先に 各章の例と演習を作り、走らせる。演習は「出発点で落ちる」「答えで通る」を両方確かめる
5. 章を書く explainer の writing.md の型。章の冒頭に所要時間とゴール、末尾に理解度チェック
6. 検証 node <skill>/scripts/verify-book.mjs <book-dir> [--write]
7. 読ませる first-reader で、少なくとも 01-quickstart と演習の章を、ペルソナ本人に読ませる(explainer の手順 8)
8. 渡す dist/index.html と、各章の 1 行要約。未検証の点を明記1. ペルソナ explainer と同じ。「怪しいところ」から、本全体の問いを 1 つ決める
2. 目標を並べる 問いに答えるために読み手ができるべき判定を 3〜6 個。1 章に 1〜2 個
3. 概念の順序 各判定に要る概念を書き出し、どの章で導入するかを決める(book.json introduces / requires)
4. 実物を先に 各章の例と演習を作り、走らせる。演習は「出発点で落ちる」「答えで通る」を両方確かめる
5. 章を書く explainer の writing.md の型。章の冒頭に所要時間とゴール、末尾に理解度チェック
6. 検証 node <skill>/scripts/verify-book.mjs <book-dir> [--write]
7. 読ませる first-reader で、少なくとも 01-quickstart と演習の章を、ペルソナ本人に読ませる(explainer の手順 8)
8. 渡す dist/index.html と、各章の 1 行要約。未検証の点を明記2. 学習目標
2. Learning objectives
目標は「読み終えたら、何を判定できるか」で書く。「〜を理解する」は検査できないので書かない。
- 悪い例:「CTI を理解する」
- 良い例:「CTI が出たとき、条件が弱すぎるだけか、性質が本当に破れるかを TLC で判定できる」
各目標には、理解度チェックの問いを 1 つ以上付ける()。
<!-- quiz: <目標id> -->Write each objective in terms of “what the reader can determine after finishing.” Do not write “understand …,” because it cannot be assessed.
- Bad example: “Understand CTI”
- Good example: “When CTI appears, use TLC to determine whether the conditions are merely too weak or whether the property is actually violated”
Attach at least one comprehension-check question to every objective ().
<!-- quiz: <objective-id> -->3. 概念の順序
3. Concept order
- ペルソナが既に知っている概念は に書く。説明しない。
assumed - それ以外の概念は、ちょうど 1 つの章が する。その章より前の章の本文に出てきたら、検証が落ちる。
introduces - 章が前提にする概念は に書く。依存図の矢印になる。
requires
- Put concepts the persona already knows in . Do not explain them.
assumed - For every other concept, exactly one chapter it. If it appears in the body of an earlier chapter, validation fails.
introduces - Put concepts that a chapter depends on in . These become arrows in the dependency graph.
requires
4. 演習
4. Exercises
演習の答えも実行して確かめる。答えが間違った演習は、間違いを教える。
| kind | 例 | 検査 |
|---|---|---|
| 条件・関数・設定を書かせる | |
| 道具を回して判定させる | |
- 答えは、演習と同じ節の に入れる。
<details> - 演習の前に を置く。
<!-- exercise: <id> -->
Run the exercise answers as well and verify them. An exercise with an incorrect answer teaches the mistake.
| kind | Example | Check |
|---|---|---|
| Have the reader write conditions, functions, or configuration | |
| Have the reader run a tool to make a determination | |
- Put the answer in a element in the same section as the exercise.
<details> - Place before the exercise.
<!-- exercise: <id> -->
5. 章を書く
5. Writing chapters
explainer- 冒頭の引用ブロックに、所要時間・ゴール(その章の目標)・前提(前の章)を書く。
- 末尾で次の章へリンクする()。HTML では前後の章と目次へのナビが付く。
→ [02 …](02-….md) - 前の章の結果を使うときは、章番号で参照する(「1 章の 3 つの check」)。同じ説明を繰り返さない。
- 手で推論した結果(「この状態には着けない」「この順序で起きる」)は、道具の出力に置き換える。推論は外れる。
In addition to the style, follow these rules:
explainer- In the opening block quote, include the estimated time required, the goal (the chapter’s objectives), and the prerequisites (previous chapters).
- At the end, link to the next chapter (). In HTML, navigation to the previous and next chapters and to the table of contents is added.
→ [02 …](02-….md) - When using a result from a previous chapter, refer to it by chapter number (“the three checks in Chapter 1”). Do not repeat the same explanation.
- Replace results derived through manual reasoning (“this state is unreachable,” “this happens in this order”) with tool output. Manual reasoning can be wrong.
6. 検証
6. Validation
node <skill>/scripts/verify-book.mjs <book-dir> # 検査
node <skill>/scripts/verify-book.mjs <book-dir> --write # 依存図と SVG を作り直す本全体の検査:
| 検査 | 落ちる条件 |
|---|---|
| chapters | 章ファイルがない。 |
| objectives | quiz が付いていない目標がある。quiz が他の章の目標を名指ししている |
| concepts | 概念を導入より前の章で使っている。 |
| budget | 本文の推定読了時間(500 字/分 + コード 15 行/分)が |
| exercises | 印がない。答えが |
| map | |
そのあと、README と全章を に渡す。出力の引用、図、ページ間リンク、各ページの vlmkit ゲートを検査する。
verify-doc.mjs --pagesbook verdict: VERIFIEDnode <skill>/scripts/verify-book.mjs <book-dir> # 検査
node <skill>/scripts/verify-book.mjs <book-dir> --write # 依存図と SVG を作り直すThe whole-book checks are:
| Check | Failure condition |
|---|---|
| chapters | A chapter file is missing. The |
| objectives | An objective has no quiz. A quiz explicitly refers to an objective in a different chapter. |
| concepts | A concept is used in a chapter before it is introduced. A |
| budget | The estimated body reading time (500 characters/min + 15 lines of code/min) exceeds |
| exercises | A marker is missing. The answer is not in |
| map | |
Afterward, pass the README and every chapter to . It checks output quotations, diagrams, links between pages, and the vlmkit gate for every page.
verify-doc.mjs --pagesKeep fixing the material until it displays .
book verdict: VERIFIEDやってはいけないこと
Things not to do
- 章を増やして薄める。 1 章に目標がない、または理解度チェックが目標を問わないなら、その章は要らない。
- 演習の答えを走らせない。
- 前の章の説明を繰り返す。 章番号で参照する。
- 検証を通すために言い換える。 概念の検査に落ちたら、定義を前の章に移すか、章の順序を見直す。同義語に置き換えて逃げない。
- Add chapters and dilute the material. If a chapter has no objective, or its comprehension check does not ask about the objective, the chapter is unnecessary.
- Do not run the exercise answers.
- Do not repeat the previous chapter’s explanation. Refer to it by chapter number.
- Do not reword things merely to pass validation. If a concept check fails, move the definition to an earlier chapter or revise the chapter order. Do not evade the check with synonyms.
ファイル
Files
| パス | 内容 |
|---|---|
| book.json の全フィールド |
| 本全体の検査 → verify-doc.mjs |
| 複数ページを HTML に(目次・前後の章へのナビつき) |
| Path | Contents |
|---|---|
| All fields of book.json |
| Whole-book validation → verify-doc.mjs |
| Builds multiple pages into HTML, with a table of contents and previous/next chapter navigation |