Skip to content

brycewang-stanford/Auto-Empirical-Research-Skills / skills/22-christopherkenny-skills/skills/latex-to-quarto

latex-to-quarto

Verified

Converts LaTeX article-class .tex documents to Quarto .qmd format for multi-format publishing (HTML, PDF, Word). Use when asked to convert, port, migrate, or translate a .tex LaTeX file to Quarto; when porting an academic paper or manuscript from LaTeX to Quarto; when a .tex document needs to render to HTML, Word, or Typst PDF. Covers preamble → YAML front matter, section headings, text formatting, math, citations (natbib/biblatex), cross-references, figures, tables, lists, footnotes, hyperlinks, and special characters.

references/09-sections-lists.md

View on GitHub
# Section Headings and Lists

---

## Section Headings

| LaTeX | Quarto |
|-------|--------|
| `\section{Title}` | `# Title` |
| `\subsection{Title}` | `## Title` |
| `\subsubsection{Title}` | `### Title` |
| `\paragraph{Title}` | `#### Title` |
| `\subparagraph{Title}` | `##### Title` |
| `\section*{Title}` | `# Title {.unnumbered}` |
| `\subsection*{Title}` | `## Title {.unnumbered}` |
| `\subsubsection*{Title}` | `### Title {.unnumbered}` |
| `\section{Title}\label{sec:x}` | `# Title {#sec-x}` |
| `\section*{Title}\label{sec:x}` | `# Title {.unnumbered #sec-x}` |

### Merging Labels into Headings

If a `\label{sec:x}` appears on the line immediately after a heading, merge it into the
heading's attribute block:

```latex
\section{Introduction}
\label{sec:intro}
```
→
```markdown
# Introduction {#sec-intro}
```

If both `*` (unnumbered) and a label are present:

```latex
\section*{Appendix A}
\label{app:a}
```
→
```markdown
# Appendix A {.unnumbered #sec-a}
```

---

## Itemize (Unordered Lists)

```latex
\begin{itemize}
  \item First item
  \item Second item with \textbf{bold}
  \item Third item
\end{itemize}
```

→

```markdown
- First item
- Second item with **bold**
- Third item
```

---

## Enumerate (Ordered Lists)

```latex
\begin{enumerate}
  \item First step
  \item Second step
  \item Third step
\end{enumerate}
```

→

```markdown
1. First step
2. Second step
3. Third step
```

---

## Description Lists

```latex
\begin{description}
  \item[OLS] Ordinary least squares estimator
  \item[IV] Instrumental variables estimator
\end{description}
```

→

```markdown
OLS
:   Ordinary least squares estimator

IV
:   Instrumental variables estimator
```

---

## Nested Lists

Indent continuation lines by four spaces per level:

```latex
\begin{itemize}
  \item Top level
  \begin{itemize}
    \item Nested item
    \item Another nested
  \end{itemize}
  \item Back to top
\end{itemize}
```

→

```markdown
- Top level
    - Nested item
    - Another nested
- Back to top
```

Mixed nesting (ordered inside unordered):

```latex
\begin{itemize}
  \item Category A
  \begin{enumerate}
    \item First in A
    \item Second in A
  \end{enumerate}
\end{itemize}
```

→

```markdown
- Category A
    1. First in A
    2. Second in A
```

---

## Items with Multiple Paragraphs

```latex
\begin{itemize}
  \item First paragraph of item.

  Second paragraph of same item.
  \item Next item.
\end{itemize}
```

→

```markdown
- First paragraph of item.

  Second paragraph of same item.

- Next item.
```

(Continuation paragraphs within an item are indented by two spaces.)

---

## Custom Enumerate Labels (`enumitem`)

If `enumitem` is used with custom labels (e.g., `[label=(\alph*)]`), convert to
standard numbered lists and note the loss of custom labeling:

```latex
\begin{enumerate}[label=(\alph*)]
  \item First
  \item Second
\end{enumerate}
```

→ (flag in report: custom labels lost)

```markdown
a. First
b. Second
```

Or use standard `1.` if alphabetic labeling isn't critical.

---

## `\item[custom]` in Itemize

An `\item[*]` or `\item[-]` in an `itemize` environment uses a custom bullet:

```latex
\begin{itemize}
  \item[--] Dashed item
  \item[$\bullet$] Bulleted item
\end{itemize}
```

→ Convert to standard `-` items and flag the custom bullets in your report.

---

## Block Quotes (`quote` / `quotation`)

| LaTeX | Quarto |
|-------|--------|
| `\begin{quote}...\end{quote}` | `> text` (block quote) |
| `\begin{quotation}...\end{quotation}` | `> text` (block quote) |

```latex
\begin{quote}
The quick brown fox.
\end{quote}
```

→

```markdown
> The quick brown fox.
```
canvas-designanthropics/skillsCreate beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.Stars: 198kUpdated Claude CodeCodexVerifiedInstall
docxanthropics/skillsUse this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include: any mention of 'Word doc', 'word document', '.docx', '.dotx', or requests to produce professional documents with formatting like tables of contents, headings, page numbers, or letterheads. Also use when extracting or reorganizing content from .docx or .dotx files, inserting or replacing images in documents, performing find-and-replace in Word files, working with tracked changes or comments, or converting content into a polished Word document. If the user asks for a 'report', 'memo', 'letter', 'template', or similar deliverable as a Word or .docx file, use this skill. Do NOT use for PDFs, spreadsheets, Google Docs, or general coding tasks unrelated to document generation.Stars: 198kUpdated Claude CodeCodexVerifiedInstall
pdfanthropics/skillsUse this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple PDFs into one, splitting PDFs apart, rotating pages, adding watermarks, creating new PDFs, filling PDF forms, encrypting/decrypting PDFs, extracting images, and OCR on scanned PDFs to make them searchable. If the user mentions a .pdf file or asks to produce one, use this skill.Stars: 198kUpdated Claude CodeCodexVerifiedInstall
pptxanthropics/skillsUse this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or presentations; reading, parsing, or extracting text from any .pptx or .potx file (even if the extracted content will be used elsewhere, like in an email or summary); editing, modifying, or updating existing presentations; combining or splitting slide files; working with templates (.potx), layouts, speaker notes, or comments. Trigger whenever the user mentions "deck," "slides," "presentation," or references a .pptx or .potx filename, regardless of what they plan to do with the content afterward. If a .pptx or .potx file needs to be opened, created, or touched, use this skill.Stars: 198kUpdated Claude CodeCodexVerifiedInstall