llms.py
Features

Rendering Math with KaTeX

Display mathematical expressions in your conversations using KaTeX.

The katex extension enables beautiful rendering of LaTeX math expressions in AI responses using KaTeX. It integrates automatically with the markdown parser to render math equations in both inline and block formats.

Features

  • Fast Rendering: Uses KaTeX for high-performance rendering of math expressions.
  • Inline Math: Renders math within text using $ or $$ delimiters.
  • Block Math: Renders complex equations in their own block using $ or $$ delimiters across multiple lines.
  • Auto-Integration: Automatically extends the marked parser used in the application.

Basic math expressions