/SKILL.md
Write and create Typst documents (.typ files). Use when the user asks to create, write, edit, or convert documents to Typst format, write Typst markup, create academic papers, reports, or documents in Typst, convert LaTeX to Typst, or work with .typ files. Typst is a modern markup-based typesetting system alternative to LaTeX.
npx skillsauth add akilrammohan/typst-skill typstInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Typst is a markup-based typesetting system. Files use .typ extension. No boilerplate required—just start writing.
Typst has three syntactical modes:
| Mode | Default In | Enter Via | Exit Via |
|------|-----------|-----------|----------|
| Markup | .typ files | [..] from code | # for code |
| Code | After # | #expr or { } | [..] for markup |
| Math | Never | $..$ | End $ |
= Heading 1
== Heading 2
*bold* _italic_ `code`
- bullet list
+ numbered list
/ Term: definition
@label-ref
<my-label>
#)#let x = 5
#if x > 3 [larger] else [smaller]
#for i in range(3) [Item #i. ]
#rect(width: 2cm, fill: blue)
#image("photo.png", width: 50%)
$)Inline $x^2 + y^2 = z^2$ math.
Block math (note spaces inside dollars):
$ sum_(k=1)^n k = (n(n+1))/2 $
#set page(margin: 2cm)
#set text(font: "New Computer Modern", size: 11pt)
#set par(justify: true)
#set heading(numbering: "1.1")
// Show-set: apply set rule to specific element
#show heading: set text(navy)
// Transform: completely redefine
#show heading: it => [
#text(blue)[#it.body]
]
// Named arguments after positional
#rect(width: 2cm, height: 1cm, fill: aqua)
// Trailing content block (common pattern)
#figure(
image("chart.png", width: 80%),
caption: [Analysis results],
) <fig-results>
#table(
columns: (auto, 1fr, 1fr),
[Header 1], [Header 2], [Header 3],
[Row 1], [Data], [Data],
[Row 2], [Data], [Data],
)
#grid(
columns: (1fr, 1fr),
gutter: 1em,
[Left column],
[Right column],
)
| LaTeX | Typst |
|-------|-------|
| \frac{a}{b} | a/b or frac(a,b) |
| \sqrt{x} | sqrt(x) |
| \sum_{i=1}^{n} | sum_(i=1)^n |
| \alpha, \beta | alpha, beta |
| \mathbf{x} | bold(x) |
| \text{word} | "word" |
| \left( \right) | Auto-scales, or lr(( )) |
| \begin{pmatrix} | mat(1, 2; 3, 4) |
| \begin{cases} | cases(a "if" x, b "else") |
| \vec{v} | arrow(v) or vec(a, b, c) |
$ x^2 $ // superscript
$ x_n $ // subscript
$ x_(i+1) $ // grouped subscript
$ (a+b)/c $ // fraction
$ sqrt(x) $ // square root
$ root(3, x) $ // nth root
$ sum_(i=0)^n $ // sum with limits
$ integral_a^b $ // integral
$ mat(1, 2; 3, 4) $ // matrix (semicolon = row break)
$ vec(x, y, z) $ // column vector
$ cases(1 "if" x > 0, 0 "else") $
$ "error" = x - hat(x) $ // quotes for text
$ pi r^2 $ // single letters = variables
$ A B $ // space = multiplication
Forgetting # in markup: Function calls need # prefix in markup mode
rect(...)#rect(...)Math block spacing: Block equations need spaces inside $
$x^2$$ x^2 $ (spaces required)Content vs strings: Use [content] for markup, "string" for plain text
#text(fill: red)[Hello] — content with markup#lower("HELLO") — string manipulationSemicolons in expressions: End expression early with ;
#x; to prevent next char joining expressionMulti-letter math variables: Wrap in quotes or they become function calls
$error$ (looks for error function)$"error"$ or single letters $e$#set document(title: [Paper Title], author: "Author")
#set page(margin: 2.5cm, numbering: "1")
#set text(font: "New Computer Modern", size: 11pt)
#set par(justify: true, leading: 0.65em)
#set heading(numbering: "1.1")
#align(center)[
#text(17pt, weight: "bold")[Paper Title]
#v(1em)
Author Name \
Institution \
#link("mailto:[email protected]")
]
#outline()
= Introduction
#lorem(50)
= Methods
#lorem(50)
#set page(header: [Report Title #h(1fr) #counter(page).display()])
= Results
#figure(
table(
columns: 3,
[A], [B], [C],
[1], [2], [3],
),
caption: [Sample data],
) <tab-data>
As shown in @tab-data, ...
Common symbols: => (⇒), -> (→), <- (←), != (≠), <= (≤), >= (≥), ... (…), ~ (non-breaking space)
Greek: alpha, beta, gamma, delta, epsilon, theta, lambda, mu, pi, sigma, omega
Variants: arrow.r, arrow.l.double, plus.circle — append modifiers with dots
See full list: https://typst.app/docs/reference/symbols/
For complex tasks, consult these reference files:
references/math.md: Comprehensive math mode syntax, symbols, matrices, alignmentreferences/advanced.md: Scripting, templates, page layout, bibliography, importstypst compile document.typ # → document.pdf
typst compile document.typ out.pdf # custom output
typst watch document.typ # auto-recompile on save
development
Maintainer-only workflow for handling GitHub Secret Scanning alerts on OpenClaw. Use when Codex needs to triage, redact, clean up, and resolve secret leakage found in issue comments, issue bodies, PR comments, or other GitHub content.
development
Maintainer workflow for OpenClaw releases, prereleases, changelog release notes, and publish validation. Use when Codex needs to prepare or verify stable or beta release steps, align version naming, assemble release notes, check release auth requirements, or validate publish-time commands and artifacts.
development
Run, watch, debug, and extend OpenClaw QA testing with qa-lab and qa-channel. Use when Codex needs to execute the repo-backed QA suite, inspect live QA artifacts, debug failing scenarios, add new QA scenarios, or explain the OpenClaw QA workflow. Prefer the live OpenAI lane with regular openai/gpt-5.4 in fast mode; do not use gpt-5.4-pro or gpt-5.4-mini unless the user explicitly overrides that policy.
development
End-to-end Parallels smoke, upgrade, and rerun workflow for OpenClaw across macOS, Windows, and Linux guests. Use when Codex needs to run, rerun, debug, or interpret VM-based install, onboarding, gateway smoke tests, latest-release-to-main upgrade checks, fresh snapshot retests, or optional Discord roundtrip verification under Parallels.