Support rendering LaTeX math expressions in Markdown output
What feature would you like to see?
Support rendering LaTeX-style mathematical expressions in Codex responses and Markdown content, instead of showing raw delimiters like $...$ and $$...$$.
Examples:
Inline math:The loss is defined as $L = \sum_{t=1}^{T} (y_t - \hat{y}_t)^2$.
Block math:
\hat{y}_{t+h} = f_\theta(x_{1:t})
Background
Codex is already useful for reading technical material, explaining papers, and discussing algorithms. However, in math-heavy domains such as machine learning, forecasting, optimization, control, and engineering, raw LaTeX is much harder to read than rendered formulas.
This is especially noticeable when using Codex for:
- learning mathematical concepts
- reading research papers
- discussing derivations or proofs
- reviewing model definitions, loss functions, and constraints
- working with Markdown notes that contain equations
At the moment, Markdown rendering is discussed in issues like #1246, but math rendering appears to be missing or incomplete.
Idea
Add support for math rendering in Codex UI output, at least for common LaTeX delimiters:
- inline:
$...$ - block:
$$...$$ - possibly fenced math blocks, if supported by the Markdown pipeline
A few implementation options could be:
- detect math spans/blocks during Markdown parsing and render them specially
- integrate a terminal-friendly math renderer
- provide a fallback mode that preserves readable formatting even if full rendering is not available
Why this matters
For users who use Codex as a technical reading and reasoning tool, formula rendering would significantly improve readability and reduce friction. This would make Codex much more practical for studying textbooks, reading papers, and working with research notes.
Additional information
GitHub itself supports mathematical expressions in Markdown via MathJax:
https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/writing-mathematical-expressions
So from a user perspective, seeing raw LaTeX in Codex feels like a missing part of Markdown support for technical content.
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗