BackNext.js
Jul 1, 2026

AI Portfolio Chatbot

  • Next.js
  • FastAPI
  • PostgreSQL
  • pgvector
  • Anthropic Claude

Most portfolio chatbots are third-party widgets bolted onto a site. This one takes a different approach: a dedicated FastAPI microservice with its own vector store, indexing this site's own project and blog content.

How it works

Every .mdx file in this repository's content directory is chunked, embedded, and stored in Postgres via pgvector. When a visitor asks a question, the backend retrieves the most relevant chunks and asks an LLM to answer strictly from that context — no hallucinated claims about projects that don't exist.

User question → similarity search (pgvector) → relevant chunks → LLM → streamed answer

If nothing relevant is found, the assistant says so honestly instead of making something up.

Why build it this way

I wanted to self-host the retrieval pipeline instead of delegating to an off-the-shelf chatbot builder, so this project could double as a working, production-shaped RAG system rather than just a writeup describing one.