Hi,👋 we have updated the app and fixed multiple bugs. We are lacking funds, request to free user not to use Adblock. Ads are non intrusive. 😊

@_avichawla: Let's build a mini-ChatGPT tha...

@_avichawla
4 views Jan 26, 2025
1
Let's build a mini-ChatGPT that's powered by DeepSeek-R1 (100% local):
2
Here's a mini-ChatGPT app that runs locally on your computer. You can chat with it just like you would chat with ChatGPT.

We use:
- @DeepSeek_AI R1 as the LLM
- @Ollama to locally serve R1
- @chainlit_io for the UI

Let's build it!
3
We begin with the import statements and define the start_chat method.

It is invoked as soon as a new chat session starts.
Media image
4
Next, we define another method which will be invoked to generate a response from the LLM:

• The user inputs a prompt.
• We add it to the interaction history.
• We generate a response from the LLM.
• We store the LLM response in the interaction history.
Media image
5
Finally, we define the main method and run the app as follows:
Media image
6
Done!

This launches our 100% locally running mini-ChatGPT that is powered by DeepSeek-R1.
7
That's a wrap!

If you enjoyed this tutorial:

Find me → @_avichawla

Every day, I share tutorials and insights on DS, ML, LLMs, and RAGs.
Actions
Visual Editor Carousel Maker NEW
Update Thread
What You Can Do
  • Download as PDF
  • Save to Notion
  • Export as Markdown
  • Visual Editor
  • LinkedIn & Instagram Carousel Maker
Create Free Account

Includes 7-day Premium trial