A personalized, first-person chatbot that answers questions based on my resume, work experience, skills, hobbies, and overall personality. Built with React + Vite, a Go backend, OpenAI, Neo4j for structured querying, and Ollama for intent parsing.
- Embeds my structured resume data for retrieval (no raw text scraping)
- Uses Ollama (LLaMA3) to identify target node types and filters
- Runs Cypher queries on Neo4j to build context
- Builds prompts in my voice using
personaContext - Sends to OpenAI (GPT-3.5-Turbo)
- Returns chat responses that feel personal and natural
- Stores conversation history per user via MongoDB
ββββββββββββββββββββββββββββββ
β React Frontend (Vite) β
ββββββββββββββ¬ββββββββββββββββ
β
βΌ
ββββββββββββββββββββββββββββββ
β Go Backend (API Server) β
β β
β 1. Accepts input β
β 2. Plans query via Ollama β
β 3. Retrieves data via Neo4jβ
β 4. Builds context prompt β
β 5. Calls OpenAI β
β 6. Stores message in Mongo β
ββββββββββββββ¬ββββββββββββββββ
β
βΌ
ββββββββββββββββββ
β Ollama API β (DigitalOcean droplet)
ββββββββ¬ββββββββββ
β
βΌ
ββββββββββββββββββ
β Neo4j Aura DB β (Managed Cloud)
ββββββββ¬ββββββββββ
β
βΌ
ββββββββββββββββββ
β OpenAI GPT β
ββββββββββββββββββ
β²
β
ββββββββββββββββββ
β MongoDB Atlasβ (Cloud)
ββββββββββββββββββ
- Caddy Reverse Proxy (on the host) provides HTTPS and routes traffic to the backend container.
portfolio-chat-bot/
βββ client/ # React + Vite frontend
β βββ src/
β β βββ components/ # UI + chat components
β β βββ hooks/ # Custom React hooks
β β βββ lib/ # Utility functions
β β βββ pages/ # ChatPage, App.tsx, etc.
β β βββ styles/ # Tailwind + custom CSS
β βββ public/ # Static assets
β βββ .env.example # Frontend env example
β βββ vite.config.ts # Vite config
β βββ ... # Other frontend files
βββ server/ # Go backend
β βββ config/ # .env loading and config
β βββ db/ # Neo4j + Mongo logic
β βββ openai/ # GPT + context builder logic
β βββ ollama/ # Intent planning via LLaMA3
β βββ resume/ # resume.json and chunking
β βββ main.go # Entry point
β βββ routes.go # Route definitions
β βββ Dockerfile # Backend Dockerfile
β βββ .env.example # Backend env example
βββ docker-compose.yml # Orchestrates backend + Ollama
βββ .github/
β βββ workflows/ # GitHub Actions CI/CD
β βββ deploy-backend.yml
β βββ deploy.yml
βββ README.md
Notes:
- Neo4j is now managed in the cloud (Aura), not as a local container.
- Ollama runs on a dedicated DigitalOcean droplet, not locally.
- Caddy runs on the host to provide HTTPS and reverse proxy.
- MongoDB is typically managed via MongoDB Atlas (cloud), but can be local for dev.
git clone https://github.com/luxscious/portfolio-chat-bot.git
cd portfolio-chat-botcp client/.env.example client/.env
cp server/.env.example server/.envThen update:
# OpenAI
OPENAI_API_KEY=sk-...
OPENAI_API_URL=https://api.openai.com/v1/chat/completions
OPENAI_EMBEDDING_URL=https://api.openai.com/v1/embeddings
OPENAI_THREAD_URL=https://api.openai.com/v1/threads
OPENAI_ASSISTANT_ID=
# Ollama
OLLAMA_URI=http://localhost:11434
# Server config
PORT=8080
FRONTEND_ORIGIN=http://localhost:5173
# MongoDB
MONGO_URI=mongodb://localhost:27017
MONGO_DB=resumeChatbot
MONGO_COLLECTION=messages
# Neo4j
NEO4J_URI=bolt://localhost:7687
NEO4J_USER=neo4j
NEO4J_PASS=passwordcd client && npm install && npm run devcd ../server && go run .- If the backend disconnects temporarily, the frontend doesnβt retry or recover well
- Need a better indicator for GPT loading vs. server unavailability
- Intent parsing is not 100% fool proof.
- Look into costs + latency advantages of combining intent parsing and response into one LLM
- Caching to save on DB lookup
This project is also configured to run all services via Docker Compose:
- Neo4j (graph database)
- Ollama (local LLM server)
- Go backend API
- Docker and Docker Compose.
Sureβhereβs that as a clean Markdown canvas snippet you can drop right into your README:
Before running the containers, make sure you have downloaded the model you want Ollama to serve.
You need to enter the Ollama container shell to pull the model.
For example:
docker compose run --rm ollama bashThen inside the container shell:
ollama pull llama3- Put all variables in project root
.envfile
export $(cat .env | xargs)docker compose up --buildThis starts Neo4j, Ollama, and your backend.
docker compose down- The frontend runs separately with Vite.
This project uses GitHub Actions for continuous integration and deployment:
-
Backend Deployment:
On every push tomainthat affects the backend (server/**),docker-compose.yml, or the backend deploy workflow, the backend is automatically deployed to the production server via SSH.
The workflow:- Checks out the latest code.
- Sets up SSH keys and known hosts.
- Connects to the server, pulls the latest code, and runs
docker compose up --build -d.
-
Frontend Deployment:
On every push tomainthat affects the frontend (client/**), the frontend is built and deployed to GitHub Pages.
The workflow:- Checks out the latest code.
- Sets up Node.js and environment variables.
- Installs dependencies and builds the Vite project.
- Publishes the build output to GitHub Pages.
You can find the workflow files in .github/workflows/:
deploy-backend.ymlβ Deploys the backend to the server.deploy.ymlβ Deploys the frontend to GitHub Pages.
This project is deployed on a DigitalOcean server to ensure reliable performance and scalability.
Why DigitalOcean?
Resource Requirements for Llama 3:Running the Ollama Llama 3 model requires substantial memory and CPU resources, which are difficult to allocate reliably on local machines or small VMs.
Production Stability:DigitalOcean provides predictable resource availability and uptime for hosting the backend API, Ollama server, and Caddy reverse proxy.
Simplicity:The deployment uses Docker Compose to manage all services consistently across environments.
How it Works
Ollama ServiceHosts the Llama 3 model server (ollama serve), exposing the API on port 11434.
Backend ServiceA Go API that proxies requests to Ollama and handles application logic.
Caddy Reverse ProxyProvides automatic HTTPS with Letβs Encrypt certificates for secure public access.
β Tip:If you want to run this stack locally, youβll need a machine with enough RAM (8β16 GB recommended) to run the Llama 3 model without OOM errors.