chainlit icon indicating copy to clipboard operation
chainlit copied to clipboard

LaTeX Handling Improvement

Open hayescode opened this issue 1 year ago • 8 comments
trafficstars

Is your feature request related to a problem? Please describe. When setting latex=true in config.toml it expects mathematical formulas to be encased in $ signs. All popular LLMs are not trained with this syntax and no amount of system instructions can get the LLM to consistently output in this format. Instead it looks like this:

image

Describe the solution you'd like Switch latex rendering to standard format. This also fixes the bug causing clashes with non-formula $ signs.

Describe alternatives you've considered Adding You must ALWAYS encapsulate formulas in '$' signs. For example: $$ y = ax^2 + bx + c $$. If you do anything else for any reason then you are a bad assistant

Additional context https://discord.com/channels/1088038867602526210/1196096445804187748/1196096445804187748

hayescode avatar Aug 16 '24 21:08 hayescode