How to Create a DIGEST.md 精华长文 for Readers Who Prefer Summaries

The DIGEST.md file is the final, reader-focused deliverable of the cangjie-skill pipeline that distills triple-verified methods from any source into a concise, high-density summary of approximately 5,000–10,000 Chinese characters.

The cangjie-skill repository implements a rigorous methodology for extracting actionable skills from books, long videos, podcasts, and other dense source materials. The DIGEST.md 精华长文 represents the culmination of this process—an article that lets readers grasp core ideas without consuming the entire original work. This guide explains exactly how this final artifact is generated according to the kangarooking/cangjie-skill source code.

What Is a DIGEST.md 精华长文?

A DIGEST.md serves a specific audience: readers who want thorough understanding without the time investment of the full source. Unlike the raw verified.md or individual SKILL.md files, the digest is narrative, polished, and self-contained.

The digest must satisfy four quality criteria (defined in methodology/07-stage5-deliver.md lines 39-42):

  • A new reader can recount the book's main thesis, at least three core methods, and two pitfalls
  • Zero unverified content appears
  • Critiques and author limitations are explicitly included
  • Every method links to its detailed SKILL.md

Prerequisites: Required Input Files

Before generating a digest, the pipeline must complete four prior stages. These artifacts feed into Stage 5:

File Path Purpose
books/<slug>/BOOK_OVERVIEW.md High-level source summary
books/<slug>/verified.md Triple-verified method pool
books/<slug>/*/SKILL.md Individual skill specifications
books/<slug>/GLOSSARY.md Domain terminology
books/<slug>/candidates/counter-examples.md Failure cases and traps
books/<slug>/candidates/author-limitations.md Critical assessment of source

Step-by-Step: Running Stage 5 Delivery

Stage 5 is orchestrated through methodology/07-stage5-deliver.md. The process follows three phases: data gathering, template rendering, and quality verification.

Phase 1: Gather Verified Materials

The pipeline collects all intermediate artifacts produced in earlier stages. This consolidation ensures the digest reflects the full verification chain.

import pathlib

base = pathlib.Path("books") / slug

# Core content sources

overview = (base / "BOOK_OVERVIEW.md").read_text()
verified = (base / "verified.md").read_text()
skills = list(base.glob("*/*/SKILL.md"))
glossary = (base / "GLOSSARY.md").read_text()

# Critical analysis components

counter_examples = (base / "candidates/counter-examples.md").read_text()
author_limits = (base / "candidates/author-limitations.md").read_text()

Phase 2: Template-Driven Rendering

The actual DIGEST.md structure lives in templates/DIGEST.md.template. This Jinja2 template enforces consistent layout across all digests.

import jinja2

template_path = pathlib.Path("templates/DIGEST.md.template")
env = jinja2.Environment(loader=jinja2.FileSystemLoader(template_path.parent))
template = env.get_template(template_path.name)

rendered = template.render(
    BOOK_TITLE=book_title,
    AUTHOR=author,
    YEAR=year,
    WORD_COUNT=word_count,
    N=estimated_minutes,
    OVERVIEW=overview,
    VERIFIED=verified,
    SKILLS=skills,
    GLOSSARY=glossary,
    COUNTER_EXAMPLES=counter_examples,
    AUTHOR_LIMITS=author_limits,
)

# Write final output

output_path = base / "DIGEST.md"
output_path.write_text(rendered)

Phase 3: Quality Self-Check

After rendering, the pipeline validates against the four criteria from methodology/07-stage5-deliver.md. Failed checks block completion and trigger revision.

Understanding the DIGEST.md.template Structure

The templates/DIGEST.md.template mandates specific sections that distinguish a 精华长文 from simple summarization:

Mandatory Sections:

  1. High-level overview — Establishes thesis and scope
  2. Organized argument sections — Follows the source's primary structure
  3. Methodological subsections — Detailed, linked method descriptions
  4. 陷阱与反例 (Traps & Counter-examples) — Prevents naive application
  5. 作者的局限 (Author Limitations) — Critical context, prevents soft-sell tone
  6. Quick-lookup glossary — Domain terms without friction
  7. Three-sentence takeaway — Memorable core message

Template variables like {{skill-slug}} auto-generate relative links: [{{skill-slug}}](./{{skill-slug}}/SKILL.md). This preserves the connection to deep documentation while keeping the digest readable.

Optional: Skill Installation

While DIGEST.md targets human readers, Stage 5 also handles agent-usable skill deployment. The pipeline prompts for an installation path (default: ~/.claude/skills/). This step does not modify the digest but ensures verified skills remain accessible to AI agents.

Configuration occurs via the same methodology/07-stage5-deliver.md workflow, maintaining separation between reader-facing and machine-facing artifacts.

Key Implementation Files

File GitHub Link
methodology/07-stage5-deliver.md View source
templates/DIGEST.md.template View source
Root SKILL.md (RIA-TV++ pipeline) View source
README.md (digest rationale) View source

Summary

  • DIGEST.md 精华长文 is the final reader-facing artifact of the cangjie-skill pipeline, targeting 5,000–10,000 characters of high-density summary
  • Generation requires completed prior stages: BOOK_OVERVIEW.md, verified.md, individual SKILL.md files, GLOSSARY.md, and critical analysis pools
  • Stage 5 – Delivery (methodology/07-stage5-deliver.md) orchestrates the process through template rendering and mandatory quality checks
  • DIGEST.md.template enforces consistent structure including traps, author limitations, and method links that prevent superficial treatment
  • Four explicit quality criteria ensure the digest stands alone as rigorous, critical, and actionable

Frequently Asked Questions

What makes a DIGEST.md different from a simple summary?

A DIGEST.md 精华长文 is triple-verified against the source, includes explicit critical analysis (陷阱与反例, 作者的局限), and maintains bidirectional links to detailed SKILL.md files. Simple summaries lack this rigor and connectivity.

How long should a DIGEST.md be?

The quality checklist in methodology/07-stage5-deliver.md targets 5,000–10,000 Chinese characters. This length balances thoroughness with accessibility for time-constrained readers.

Can I create a DIGEST.md without running the full cangjie-skill pipeline?

Technically yes—by manually populating templates/DIGEST.md.template—but this violates the methodology's verification requirements. The pipeline's staged design ensures no unverified content enters the digest; manual shortcuts risk degenerating into soft-sell promotional content.

Where are the generated DIGEST.md files stored?

Each source gets its own directory under books/<slug>/. The final DIGEST.md appears at books/<slug>/DIGEST.md, alongside intermediate artifacts like BOOK_OVERVIEW.md and the per-skill subdirectories.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →