This is not a traditional video game 👇
And these are not your regular NPCs 👇
Every character you see up there is actually an AI Agent playing the role of a historical figure. Plato, Aristotle, Turing, … all of them simulated by a complex Agentic Backend.
And here’s the best part: you won’t just play this simulation.
You’ll build it.
After months of late nights, countless iterations and way too much coffee,
and I are finally ready to share our latest open-source course with you: PhiloAgents.Course Structure
Over the next six weeks, we’ll guide you through everything - from building Agentic RAG systems and LangGraph workflows, to evaluating and monitoring your agents in action.
Here’s what the journey looks like:
Lesson 1 - Project Overview
Lesson 2 - Building a Philosopher Agent with LangGraph and Groq LLMs.
Lesson 3 - Giving agents memory using MongoDB (short + long term).
Lesson 4 - Creating realtime Agentic APIs with FastAPI + WebSockets.
Lesson 5 - Evaluating agents, versioning prompts, and monitoring agentic behavior using Opik.
Lesson 6 - Connecting all the dots. Simulation in action!
As always, you’ll get full access to the code, written guides, and video lessons - all available in our GitHub repo.
In today’s article, I’ll focus on Lesson 1: the project overview.
Let’s jump in! 👇
Project Overview
PhiloAgents isn’t a simple project - it’s a system made up of multiple moving parts, all working together to bring the simulation to life.
Game UI
When you play PhiloAgents, you’ll interact with a Game UI built with Phaser - a Javascript framework made for browser games. We chose it because it makes the whole experience feel way more interactive and alive. The perfect match for what we’re building here.
You’ll play as a character named Sophia (catch the clever reference? 🤣) exploring a philosophical village where you can chat with thinkers from Ancient Greece all the way to modern times.
Oh … and keep an eye out. Hidden in the village are two mysterious ML/AI engineers. I could tell you who they are... but where’s the fun in that?
If you are interested in the PhiloAgents UI, check the Phaser 3 project
LangGraph Workflow
LangGraph is basically the brain behind each philosopher.
Every “PhiloAgent” has two main responsibilities:
Response generation - Creating quality replies to Sophia’s (aka your) questions. This happens through the conversation_node and the summarize_conversation_node. The summarizer helps keep the short-term memory window in check by condensing the ongoing dialogue.
Philosopher context retrieval - Fetching relevant context from MongoDB as part of the Agentic RAG flow.
As LLM provider, we are using Groq (in particular, the Llama 3.3 70B model). More on LangGraph in Lesson 2.
MongoDB Memory
If you’ve been following my articles, you know how crucial memory is for LLMs and agents. We usually break it down into two types: short-term and long-term memory.
In PhiloAgents, we use MongoDB for both.
Short-term memory comes from the saved LangGraph state
Long-term memory stores embedded knowledge sourced from Wikipedia and the Stanford Encyclopedia of Philosophy.
We’ll cover memory in detail in Lesson 3.
FastAPI and WebSockets protocol
FastAPI takes care of all the messaging between the game and the agentic backedn - it receives your input, passes it through the LangGraph workflow, and sends the response back to the UI.
Each time you talk to a philosopher, a WebSocket connection is opened between the Phaser 3 frontend and the FastAPI backend, enabling smooth, real-time interactions.
We’ll dig into the application layer in Lesson 4.
Evaluating agents with Opik
We’re using Opik to handle prompt versioning (like character and summary prompts), conversation tracing, and to evaluate our RAG system - essential for making sure our context retrieval stays accurate and high-quality.
We’ll do a deep dive into Opik and all its features in Lesson 5 of the course.
Connecting the dots
By the end of this course (Lesson 6), you’ll have your own version of PhiloAgents running locally on your machine.
But honestly, this is just the beginning. I truly believe systems like this are the future of education.
Imagine swapping out a boring 2-hour lecture on Napoleon for a fully immersive historical simulation - where the student actually gets to meet and interact with a Napoleon Agent Twin.
Or picture a world where onboarding at a new company isn’t just slides and PDFs, but a simulation like this one - where you can chat with avatar versions of HR, the ML team, or the frontend crew and learn by doing.
I’d love to hear your ideas on where else this tech could go - what other use cases or fields do you think it could transform?
Before I go, just a quick reminder - you can also find a long-form written version of this lesson in Paul’s newsletter …
… and also my YouTube video!
Happy coding (and philosophising), friends! 👋
Great course man 😂🙏
Great. I really appreciate for doing this