/write-paper
Turn a project's verified fact graph into a publishable LaTeX paper in a configurable house style — a standalone amsart .tex with a real bibliography, compiled to PDF. Use when a project's target theorem is established and the operator wants the paper, or asks to
$ npx -y skills add frenzymath/Danus --skill write-paper --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
- You can call itInvoke it directly when you want it.
- Slash command
/write-paper
Context preview
The summary Claude sees to decide when to auto-load this skill.
Turn a project's verified fact graph into a publishable LaTeX paper in a configurable house style — a standalone amsart .tex with a real bibliography, compiled to PDF. Use when a project's target theorem is established and the operator wants the paper, or asks to
SKILL.md
write-paper.SKILL.mdname: write-paper
description: Turn a project's verified fact graph into a publishable LaTeX paper in a configurable house style — a standalone amsart .tex with a real bibliography, compiled to PDF. Use when a project's target theorem is established and the operator wants the paper, or asks to write/revise/audit references for the paper for a project. NOT human-summary (a reader-facing progress report with no bibliography); this is the publication artifact, with verified citations, headed for arXiv / a LaTeX git repo.
write-paper — fact graph → publishable paper
You are the main agent. This skill turns a project's **verified fact graph** into a **publishable** LaTeX paper in a configurable house style: a standalone `\documentclass{amsart}` `.tex` with a real manual bibliography, compiled to a clean PDF, ready for arXiv / an Overleaf (or other) LaTeX git repo. It is the publication sibling of `human-summary` (a reader-facing progress report with no bibliography).
The heavy LaTeX work is delegated to a **local codex at extra-high (`xhigh`) reasoning** — the same codex machinery the workers and the verify service already use. The writer, auditor, verifier, and reviser roles are wrapped behind the `write-paper` MCP service (tools `paper_write` / `reference_audit` / `reference_verify` / `paper_revise`): you call them with structured args, the tool assembles each role's prompt internally (so the style guide and fact-graph bytes never enter your context) and drives the codex with each role isolated by construction. The reference chain is `auditor (offline, flags) → verifier (online, checks) → reviser (edits)`. You orchestrate the stages, call these tools, gate on compilation, and surface the one or two real decisions to the operator.
When to use
- A project's target theorem is established in the fact graph and the operator
wants the paper.
- The operator asks to **write**, **revise**, **audit references for**, or
**push** the paper for a project.
Do not use it for the progress report (`human-summary`) or for the dense pro consult input (`elaboration`).
Source of content: the fact graph (never your memory)
Build the mathematics from the project's **verified facts** (`<project>/fact_graph/facts/*.md`) and the verbatim goal in `<project>/PROBLEM.md` — exactly as `human-summary` does, but for publication:
- Each fact's `## statement` is fully-quantified and self-contained → render into
the paper's theorems/propositions (clean LaTeX, do not paraphrase loosely). Its `## proof` is the argument; `## intuition` feeds a proof sketch where useful.
- Load-bearing facts first: high dependency depth (headline results) and high
in-degree (key lemmas). `predecessors` give you the internal `Theorem~\ref{}` cross-reference structure **with zero invention**.
- **Citations come structured, from the source.** Each fact's `external_refs`
(key / authors / title / arxiv / year / cited_for) records the published results its proof cited. `driver/seed_ledger.py` aggregates them across the project into the starting `REFERENCE_LEDGER.md`. Do not re-mine citations from prose — that is the #1 failure mode (hallucinated references).
- **Preserve all mathematics. Invent nothing** — no assumptions, lemmas,
citations, theorem labels, or definitions that are not in the fact graph. If a step is unclear, flag `[GAP: ...]`, do not smooth it over.
Paper workspace: `<project>/paper/` (default) — and MULTIPLE papers per project
Per-project, alongside `fact_graph/` and `global_memory/`:
<project>/paper/ # the DEFAULT paper (legacy paths — unchanged)
PROJECT_BRIEF.md # per-paper framing (interview the operator — see below)
REFERENCE_LEDGER.md # seeded from external_refs, verified by the auditor
REVISION_LOG.md # append-only round history
main.tex / main.pdf # the paper
<project>/TARGET.md # the DEFAULT paper's finalized target (danus finalize)
Seed the workspace from `templates/` (copy `*.template` → the real names) if it does not exist yet.
**One project can hold MULTIPLE papers** (e.g. a main theorem paper + a companion, or several theorems each written up separately). Every `paper_*` tool and `danus finalize` takes an optional **`paper_id`**:
- `paper_id` **omitted / `"main"`** → the **DEFAULT** paper on the **legacy** paths
above (`<project>/paper/` + `<project>/TARGET.md`). Existing single-paper projects are byte-for-byte unchanged.
- any other `paper_id` (e.g. `thmB`) → an **isolated** workspace
`<project>/papers/<paper_id>/` with its own `PROJECT_BRIEF.md` / `REFERENCE_LEDGER.md` / `REVISION_LOG.md` / `main.tex` / `TARGET.md`. So N papers never collide — each has its own files.
There is **one fact graph per project** (`<project>/fact_graph/`); papers never fork or re-filter it. A paper's facts are simply the transitive-predecessor **closure of its own headline set** — the SAME closure primitive the single-paper pipeline already uses, merely rooted at that paper's recorded target. The three shapes are one model — **a list of `{paper_id, headline_fact_ids}`**:
- **1 paper / 1 theorem** — the default: one entry, `paper_id="main"`.
- **N papers / 1 theorem each** — N entries, each a distinct `paper_id` and a
single-fact headline; written in **separate workspaces** (no overwrite).
- **N papers / one multi-theorem paper** — an entry whose `headline_fact_ids` is a
LIST of several targets; its fact set is the **union closure** of that list.
`paper_id` must be a single safe path segment (same validation as a project name); it cannot escape the project dir.
Style source
Two generic, self-contained layers under `style/`, neither naming an author or a field:
- `style/STYLE_GUIDE.md` — the compact baseline house style (binding for *voice*:
macros, theorem/proof shape, citations, cross-references, sentence-level rules).
- `style/PAPER_STRUCTURE.md` — the per-section content plan (binding for
*structure
Read more
name: write-paper description: Turn a project's verified fact graph into a publishable LaTeX paper in a configurable house style — a standalone amsart .tex with a real bibliography, compiled to PDF. Use when a project's target theorem is established and the operator wants the paper, or asks to write/revise/audit references for the paper for a project. NOT human-summary (a reader-facing progress report with no bibliography); this is the publication artifact, with verified citations, headed for arXiv / a LaTeX git repo.
write-paper — fact graph → publishable paper
You are the main agent. This skill turns a project's **verified fact graph** into a **publishable** LaTeX paper in a configurable house style: a standalone `\documentclass{amsart}` `.tex` with a real manual bibliography, compiled to a clean PDF, ready for arXiv / an Overleaf (or other) LaTeX git repo. It is the publication sibling of `human-summary` (a reader-facing progress report with no bibliography).
The heavy LaTeX work is delegated to a **local codex at extra-high (`xhigh`) reasoning** — the same codex machinery the workers and the verify service already use. The writer, auditor, verifier, and reviser roles are wrapped behind the `write-paper` MCP service (tools `paper_write` / `reference_audit` / `reference_verify` / `paper_revise`): you call them with structured args, the tool assembles each role's prompt internally (so the style guide and fact-graph bytes never enter your context) and drives the codex with each role isolated by construction. The reference chain is `auditor (offline, flags) → verifier (online, checks) → reviser (edits)`. You orchestrate the stages, call these tools, gate on compilation, and surface the one or two real decisions to the operator.
When to use
- A project's target theorem is established in the fact graph and the operator
wants the paper.
- The operator asks to **write**, **revise**, **audit references for**, or
**push** the paper for a project.
Do not use it for the progress report (`human-summary`) or for the dense pro consult input (`elaboration`).
Source of content: the fact graph (never your memory)
Build the mathematics from the project's **verified facts** (`<project>/fact_graph/facts/*.md`) and the verbatim goal in `<project>/PROBLEM.md` — exactly as `human-summary` does, but for publication:
- Each fact's `## statement` is fully-quantified and self-contained → render into
the paper's theorems/propositions (clean LaTeX, do not paraphrase loosely). Its `## proof` is the argument; `## intuition` feeds a proof sketch where useful.
- Load-bearing facts first: high dependency depth (headline results) and high
in-degree (key lemmas). `predecessors` give you the internal `Theorem~\ref{}` cross-reference structure **with zero invention**.
- **Citations come structured, from the source.** Each fact's `external_refs`
(key / authors / title / arxiv / year / cited_for) records the published results its proof cited. `driver/seed_ledger.py` aggregates them across the project into the starting `REFERENCE_LEDGER.md`. Do not re-mine citations from prose — that is the #1 failure mode (hallucinated references).
- **Preserve all mathematics. Invent nothing** — no assumptions, lemmas,
citations, theorem labels, or definitions that are not in the fact graph. If a step is unclear, flag `[GAP: ...]`, do not smooth it over.
Paper workspace: `<project>/paper/` (default) — and MULTIPLE papers per project
Per-project, alongside `fact_graph/` and `global_memory/`:
<project>/paper/ # the DEFAULT paper (legacy paths — unchanged) PROJECT_BRIEF.md # per-paper framing (interview the operator — see below) REFERENCE_LEDGER.md # seeded from external_refs, verified by the auditor REVISION_LOG.md # append-only round history main.tex / main.pdf # the paper <project>/TARGET.md # the DEFAULT paper's finalized target (danus finalize)
Seed the workspace from `templates/` (copy `*.template` → the real names) if it does not exist yet.
**One project can hold MULTIPLE papers** (e.g. a main theorem paper + a companion, or several theorems each written up separately). Every `paper_*` tool and `danus finalize` takes an optional **`paper_id`**:
- `paper_id` **omitted / `"main"`** → the **DEFAULT** paper on the **legacy** paths
above (`<project>/paper/` + `<project>/TARGET.md`). Existing single-paper projects are byte-for-byte unchanged.
- any other `paper_id` (e.g. `thmB`) → an **isolated** workspace
`<project>/papers/<paper_id>/` with its own `PROJECT_BRIEF.md` / `REFERENCE_LEDGER.md` / `REVISION_LOG.md` / `main.tex` / `TARGET.md`. So N papers never collide — each has its own files.
There is **one fact graph per project** (`<project>/fact_graph/`); papers never fork or re-filter it. A paper's facts are simply the transitive-predecessor **closure of its own headline set** — the SAME closure primitive the single-paper pipeline already uses, merely rooted at that paper's recorded target. The three shapes are one model — **a list of `{paper_id, headline_fact_ids}`**:
- **1 paper / 1 theorem** — the default: one entry, `paper_id="main"`.
- **N papers / 1 theorem each** — N entries, each a distinct `paper_id` and a
single-fact headline; written in **separate workspaces** (no overwrite).
- **N papers / one multi-theorem paper** — an entry whose `headline_fact_ids` is a
LIST of several targets; its fact set is the **union closure** of that list.
`paper_id` must be a single safe path segment (same validation as a project name); it cannot escape the project dir.
Style source
Two generic, self-contained layers under `style/`, neither naming an author or a field:
- `style/STYLE_GUIDE.md` — the compact baseline house style (binding for *voice*:
macros, theorem/proof shape, citations, cross-references, sentence-level rules).
- `style/PAPER_STRUCTURE.md` — the per-section content plan (binding for
*structure
Danus orchestrates mathematical reasoning agents with fact-graph memory. A main agent (Claude Code) steers a swarm of autonomous codex workers that prove; a cold-start verifier is the sole authority on correctness: a result becomes real only once it passes.
Other skills on danus.
- /consult
Consult a strong reasoning model for strategy — feed it the current elaboration, take its reply as the next master_guidance, and dispatch workers from it. This is the main agent's high-intelligence step (workers prove; the consult decomposes and steers). Runs over the gpt_pro
Open skill - /elaboration
Write a high-signal-to-noise mathematical progress synthesis of a project from the shared stores (global memory + fact graph), following a fixed verdict→routes→interfaces→dangers→bridges template and a strict honesty discipline. Use it each strategic cycle, right before the
Open skill - /human-summary
Write a human-readable mathematical progress report (compiled PDF) on a project for the operator / the mathematician who posed the problem. This is NOT `elaboration` (dense input for the strategy consult) and NOT the dashboard. Render from the fact graph's verified
Open skill - /initialize
First-run setup interview for a Danus deployment. Run it on the FIRST session, whenever runtime/.danus-initialized is absent or OPERATOR.md is still the blank template, or when the operator asks to set up / initialize / onboard / re-configure. It greets the operator, explains
Open skill - /check-referenced-statements
Validate externally referenced theorems by querying arXiv theorem search first and Codex's built-in web search second. Use when a markdown proof cites statements from external papers.
Open skill - /synthesize-verification-report
Aggregate all detected errors and gaps into the final verification report, apply strict accept/reject logic, and produce repair hints when rejected.
Open skill

