↓ Skip to main content
  1. Home projects/

Personas Chat: talk to a local LLM as an uncle or an aunt

··Index: 6·
Table of Contents

In Personas Chat you pick one of the personas (uncle, aunt or wife, for example) and talk to a local language model that answers in their voice, in Polish. The model runs locally, and none of the conversation leaves the machine.

I built the frontend in Vue 3 with TypeScript and the backend in FastAPI, which runs the model through llama-cpp-python. Replies stream into the chat window as they’re generated, and recent chats are kept in the browser.

A Vue chat in the browser talks to a FastAPI backend that adds a persona prompt and runs a local model; replies stream back.personas, JSON filebrowserVue 3 chat windowrecent chats kept hereFastAPI backendpersona prompt, history,summary of old messageslocal language modelllama-cpp-pythonnothing leaves the machinereplies stream into the chat as they are generateda persona is a short system prompt
How a chat message travels to the local model and back

What I did
#

Personas are just short system prompts kept in a JSON file. The uncle tells rough, hearty jokes, the aunt is warm and likes to talk about baking, and the wife is loving but practical.

The first version, in April 2025, was a simple chat that worked. After that I added conversation history and a summary of older messages, so that long talks don’t lose the thread and the prompt doesn’t have to grow without limit.

Related