LaTeX & Academic Writing

Everything you need to write academic papers in Nebula Writer, from first draft to final PDF.


When to Use This Page

  • You are writing academic papers in LaTeX
  • You need citations and bibliography workflows
  • You want built-in compilation and PDF preview

Why LaTeX in Nebula Writer

  • Built-in compilation with no external installs
  • Side-by-side editor and PDF preview
  • AI support for citations, figures, and formatting

Getting Started with LaTeX

Create a LaTeX Document

  1. Click + in the sidebar
  2. Select LaTeX as the document type
  3. Name your document (e.g., "main.tex")

The LaTeX editor

Basic Structure

Nebula Writer provides templates, or start from scratch:

\documentclass{article}
\usepackage{amsmath}
\usepackage{graphicx}

\title{Your Paper Title}
\author{Your Name}

\begin{document}
\maketitle

\section{Introduction}
Your content here.

\end{document}

Templates & Starting Points

Nebula Writer can start you with a minimal template or you can paste your own.

Suggested starter files:

  • main.tex for the main document
  • references.bib for citations
  • figures/ for images and plots

Compiling to PDF

One-Click Compile

Click the Compile button or press Cmd + Shift + B. Nebula Writer uses Tectonic — no external LaTeX installation needed.

Automatic Package Downloads

Missing a package? Tectonic downloads it automatically on first compile.

Live Preview

The PDF preview panel shows your compiled document. Updates after each successful compile.

LaTeX Split Screen Preview

You can also view the PDF preview in a dedicated panel:

PDF preview panel

SyncTeX

  • Click in PDF → jumps to source
  • Click in source → jumps to PDF

Build Errors

If compilation fails, you'll see error messages with line numbers. Click to jump to the problem.

LaTeX Debug Error


Bibliography Management

Creating a .bib File

  1. Create a new file called references.bib
  2. Add BibTeX entries manually or use the AI

BibTeX Entry Format

@article{smith2024deep,
  author = {Smith, John and Doe, Jane},
  title = {Deep Learning for Text Analysis},
  journal = {Journal of AI Research},
  year = {2024},
  volume = {15},
  pages = {100--120},
  doi = {10.1234/jair.2024.001}
}

Citing in Your Document

\bibliographystyle{plain}

According to \cite{smith2024deep}, deep learning...

Multiple citations: \cite{smith2024deep, jones2023nlp}

\bibliography{references}

Working with Figures & Tables

Figures

Store assets in a figures/ folder and reference them with \includegraphics.

Tables

Use the AI to draft tables and convert CSV-like data into LaTeX.


Academic Paper Search

Ask the AI to find papers from major databases.

Academic paper search results

Supported Databases

DatabaseCommandBest For
PubMedAutomatic for medical termsMedicine, biology, clinical
arXivAutomatic for physics/CSPreprints, cutting-edge
Semantic ScholarDefault for AI/MLCitation graphs
OpenAlexBroad searchesAll disciplines
CrossRefDOI lookupsCitation metadata

Search Examples

Find recent papers on transformer architectures

Search PubMed for clinical trials on diabetes treatment

What papers cite "Attention is All You Need"?

Find the DOI for Smith et al. 2024 deep learning paper

Results

The AI returns:

  • Paper title
  • Authors
  • Year
  • Abstract (summary)
  • DOI/URL
  • Citation count

One-Click Citations

The Fast Workflow

  1. Ask: "Find papers about [your topic]"
  2. Select: Choose from results
  3. Cite: AI adds to .bib and gives you \cite{key}

Example

You: Find papers about attention mechanisms in NLP

AI: Found 5 papers:
1. "Attention is All You Need" - Vaswani et al. 2017
2. "BERT: Pre-training of Deep Bidirectional Transformers" - Devlin et al. 2019
...

You: Add the first one to my bibliography

AI: Added to references.bib as vaswani2017attention
Use: \cite{vaswani2017attention}

Citation Key Format

Keys are auto-generated as: firstauthor + year + firstword

Examples:

  • vaswani2017attention
  • smith2024deep
  • jones2023neural

Multi-File Projects

Project Structure

For larger papers:

my-paper/
├── main.tex           # Main document
├── introduction.tex   # \input{introduction}
├── methodology.tex    # \input{methodology}
├── results.tex        # \input{results}
├── references.bib     # Bibliography
└── figures/
    ├── fig1.pdf
    └── fig2.png

Managing multiple LaTeX files

Including Files

\input{introduction}
\input{methodology}
\input{results}

AI Awareness

The AI understands project structure. Ask:

  • "What files are in this project?"
  • "Edit the methodology section" (finds the right file)
  • "Add a citation to the introduction"

Common LaTeX Tasks

Ask the AI

Add a figure with caption
Create a table with 3 columns
Write the equation for linear regression
Add a numbered list
Fix the bibliography formatting
Convert this section to an appendix

Math Equations

Inline: $E = mc^2$

Display:
\begin{equation}
  \frac{\partial f}{\partial x} = \lim_{h \to 0} \frac{f(x+h) - f(x)}{h}
\end{equation}

Figures

\begin{figure}[h]
  \centering
  \includegraphics[width=0.8\textwidth]{figures/fig1.pdf}
  \caption{Description of the figure.}
  \label{fig:example}
\end{figure}

Tables

\begin{table}[h]
  \centering
  \begin{tabular}{lcc}
    \hline
    Method & Accuracy & F1 Score \\
    \hline
    Baseline & 0.72 & 0.68 \\
    Ours & 0.89 & 0.85 \\
    \hline
  \end{tabular}
  \caption{Comparison of methods.}
  \label{tab:results}
\end{table}

Cleaning Up

Remove Build Files

After compiling, you may have .aux, .log, .synctex.gz files.

Ask the AI: "Clean up LaTeX build files"

Or use the clean command manually.

Export PDF

Your compiled PDF is in the same folder as your .tex file. Use the export function to copy it elsewhere.


Troubleshooting

Missing Packages

Tectonic downloads packages automatically. If compilation fails, read the error message and ensure the package name is correct.

Bibliography Not Showing

  • Confirm \bibliography{references} matches your file name
  • Compile twice if you just added new citations
  • Ask the AI to validate your .bib file

Citation Keys Not Found

Verify the citation key in your .bib matches what you used in \cite{}.

Tips for Academic Writing

Let the AI Help With

  • Finding relevant citations
  • Formatting tables and figures
  • Fixing LaTeX errors
  • Generating boilerplate (abstract structure, methodology outline)
  • Checking for missing citations

Review Carefully

  • Verify citation accuracy (authors, years)
  • Check that equations render correctly
  • Confirm figure/table references work
  • Proofread AI-written content

Keyboard Shortcuts

ShortcutAction
Cmd + Shift + BCompile LaTeX
Cmd + SSave
Cmd + /Focus AI chat

Next Steps