Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/skovy/llm-markdown

Demo rendering rich responses from LLMs
https://github.com/skovy/llm-markdown

gpt latex llm markdown mermaid nextjs vercel-ai

Last synced: 7 days ago
JSON representation

Demo rendering rich responses from LLMs

Awesome Lists containing this project

README

        

# 📝 LLM Markdown

A [Nextjs](https://nextjs.org) app demonstrating how to display rich-text responses from Large Language Models (LLMs) by prompting and rendering Markdown formatting, Mermaid diagrams, and LaTeX equations.

Read more in this blog post: [Rendering rich responses from LLMs](https://www.skovy.dev/blog/vercel-ai-rendering-markdown)

## Examples

This example is asking for the top grossing movies, structured as a Mermaid pie chart.

![LLM Markdown Demo](other/demo-movies.gif)

This example is asking when vegetables should be planted, structured as a Mermaid Gantt chart.

![LLM Markdown Demo](other/demo-vegetables.gif)

## Technologies

- [Nextjs](https://nextjs.org)
- [Vercel AI](https://sdk.vercel.ai/docs)
- [`remark`](https://remark.js.org)
- [`mermaid`](https://mermaid.js.org)
- [`latex.js`](https://latex.js.org)
- And more...

## Setup

- Clone the project
- `npm install`
- `npm run dev`
- Open in your browser
- Set your OpenAI API Key