Local Deep Research Export Formats: Complete Guide to PDF, ODT, Quarto, LaTeX, and RIS

Local Deep Research supports five distinct export formats—PDF, ODT, Quarto, LaTeX, and RIS—each implemented as a dedicated exporter class registered in the central ExporterRegistry and accessible via the export_report_to_memory API.

The learningcircuit/local-deep-research repository provides a flexible, extensible export pipeline that converts markdown research reports into multiple document formats. Understanding these Local Deep Research export formats is essential for integrating research outputs into academic workflows, publication pipelines, and reference management systems.

Supported Export Formats

The system delivers production-ready exporters for five specific formats, each handling unique conversion requirements and output specifications.

PDF (Portable Document Format)

The PDFExporter class generates print-ready documents using WeasyPrint for HTML-to-PDF conversion. Located in src/local_deep_research/exporters/pdf_exporter.py (lines 21‑45), this exporter produces files with the .pdf extension and application/pdf MIME type. It handles title prepending and ensures proper formatting for distribution.

ODT (OpenDocument Text)

The ODTExporter class, implemented in src/local_deep_research/exporters/odt_exporter.py (lines 32‑55), utilizes Pandoc via the pypandoc library to convert markdown into OpenDocument Text format. This exporter outputs .odt files with the MIME type application/vnd.oasis.opendocument.text, making reports compatible with LibreOffice, Microsoft Word, and other word processors.

Quarto

The QuartoExporter class creates reproducible research packages rather than single documents. As defined in src/local_deep_research/exporters/quarto_exporter.py (lines 21‑53), it generates a ZIP archive (.zip, MIME type application/zip) containing a .qmd (Quarto markdown) file and a .bib bibliography file. This format supports literate programming workflows and academic publishing pipelines that require executable documents with managed references.

LaTeX

For traditional academic typesetting, the LaTeXExporter class produces .tex source files (MIME type text/plain). Implemented in src/local_deep_research/exporters/latex_exporter.py (lines 18‑43), this exporter delegates to the legacy citation formatter from the text_optimization module, preserving existing LaTeX conversion logic while integrating with the modern registry architecture.

RIS (Research Information Systems)

The RISExporter class, found in src/local_deep_research/exporters/ris_exporter.py (lines 18‑42), extracts and converts bibliographic references into RIS format. Outputting .ris files with text/plain MIME type, this exporter enables direct import into reference management software such as Zotero, EndNote, and Mendeley.

How to Export Reports Programmatically

The high-level API export_report_to_memory in src/local_deep_research/web/services/research_service.py (lines 79‑106) provides the primary interface for converting markdown content into any supported format. This function normalizes format strings, queries the ExporterRegistry, constructs an ExportOptions object, and returns raw bytes alongside filename and MIME type metadata.

from local_deep_research.web.services.research_service import export_report_to_memory

markdown = "# Sample Report\n\nThis is a **test** report.\n"

# 1️⃣ PDF

pdf_bytes, pdf_name, pdf_mime = export_report_to_memory(markdown, "pdf", title="My Report")
print(pdf_name, pdf_mime, len(pdf_bytes))

# 2️⃣ ODT

odt_bytes, odt_name, odt_mime = export_report_to_memory(markdown, "odt", title="My Report")
print(odt_name, odt_mime, len(odt_bytes))

# 3️⃣ Quarto (ZIP containing .qmd + bibliography)

qz_bytes, qz_name, qz_mime = export_report_to_memory(markdown, "quarto", title="My Report")
print(qz_name, qz_mime, len(qz_bytes))

# 4️⃣ LaTeX

tex_bytes, tex_name, tex_mime = export_report_to_memory(markdown, "latex", title="My Report")
print(tex_name, tex_mime, len(tex_bytes))

# 5️⃣ RIS

ris_bytes, ris_name, ris_mime = export_report_to_memory(markdown, "ris")
print(ris_name, ris_mime, len(ris_bytes))

The function signature accepts three parameters: the markdown content string, the target format identifier (matching the registry keys), and an optional title that propagates through ExportOptions to the respective exporter for document metadata.

The Export Architecture

All exporters register automatically with the ExporterRegistry defined in src/local_deep_research/exporters/registry.py. The registry's get_available_formats() method (lines 82‑89) returns a list of supported format strings, enabling dynamic discovery without hardcoding format names in client code.

Each exporter implements a consistent interface handling title prepending, size limits, and format-specific conversion details. The PDFExporter leverages WeasyPrint for rendering, while the ODTExporter relies on external Pandoc integration. The QuartoExporter constructs ZIP archives programmatically, and both LaTeXExporter and RISExporter manage specialized text transformations for academic workflows.

Summary

  • Local Deep Research supports five export formats: PDF, ODT, Quarto, LaTeX, and RIS.
  • Each format has a dedicated exporter class (PDFExporter, ODTExporter, QuartoExporter, LaTeXExporter, RISExporter) located in src/local_deep_research/exporters/.
  • The ExporterRegistry in registry.py provides centralized format discovery via get_available_formats().
  • The export_report_to_memory function in research_service.py serves as the unified API for all format conversions.
  • Quarto exports produce ZIP archives containing both .qmd source and .bib bibliography files, while other formats generate single documents.

Frequently Asked Questions

What export formats does Local Deep Research support?

Local Deep Research supports five export formats: PDF (via WeasyPrint), ODT (via Pandoc), Quarto (ZIP archive with .qmd and .bib), LaTeX (.tex source), and RIS (bibliographic references). Each format is implemented as a distinct exporter class registered in the central ExporterRegistry.

How do I check which export formats are available programmatically?

Query the registry directly using ExporterRegistry.get_available_formats() defined in src/local_deep_research/exporters/registry.py (lines 82‑89). This method returns a list of valid format strings that can be passed to export_report_to_memory, ensuring your code remains compatible as new exporters are added.

What is the difference between the Quarto and LaTeX exporters?

The QuartoExporter generates a ZIP archive containing a .qmd file (executable markdown) and a .bib bibliography, supporting modern literate programming workflows. The LaTeXExporter produces a single .tex source file using legacy conversion logic. Quarto outputs are designed for reproducible research environments, while LaTeX outputs target traditional typesetting pipelines.

Which exporter should I use for academic reference management?

Use the RISExporter for reference management. It extracts bibliographic data and formats it as RIS (Research Information Systems) output, which is universally accepted by reference management software including Zotero, EndNote, and Mendeley. The RIS implementation is located in src/local_deep_research/exporters/ris_exporter.py.

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 →