This is a submission for the
Recommended demo path:
- Open a tenant workspace, for example
https://justin.gridypig.com. - Create or sign in as a player/creator.
- Start a new game and choose Quiz Clash.
- Use the AI quiz builder prompt, for example:
Create a fun 8-question quiz about Nigerian tech startups for a launch party. Mix simple and tricky questions.
- Show Hermes-generated questions appearing in GridyPig's editable quiz format.
- Save the quiz set and open a live room.
- Join with another player or show the simulation/live room flow.
- Play through a few turns and show the final leaderboard.
Screenshots/video placeholders:
Game landing page
Code
Repository: github.com/cjustinobi/greedy-pig
Key areas:
- Hermes Cloud Run adapter:
deploy/hermes/
- Backend quiz generation service:
apps/backend/src/quiz/quiz-ai.service.ts
- Quiz APIs and quiz bank:
apps/backend/src/quiz/
- Frontend quiz setup UI:
apps/frontend/src/components/quiz/
- Real-time game room:
apps/frontend/src/components/game/
My Tech Stack
Frontend: Next.js, React, Tailwind CSS, Framer Motion
Backend: NestJS, Prisma, PostgreSQL/Supabase
Realtime: Socket.io
Agent Runtime: Hermes Agent behind an OpenAI-compatible Cloud Run adapter
Infrastructure: Google Cloud Run, Docker, Vercel, GitHub Actions
Product Layer: Multi-tenant workspaces, PWA support, referral system, reusable quiz bank, wallet-aware game modes
How I Used Hermes Agent
Hermes Agent powers the AI quiz generation layer. I wrapped Hermes in a small Cloud Run service that exposes an OpenAI-compatible /v1/chat/completions endpoint. That allowed the existing GridyPig backend to treat Hermes like a pluggable AI provider while still keeping provider details outside the game engine.
The integration has three important parts.
1. Prompt-to-Playable Structured Output
GridyPig does not need a paragraph of generated text. It needs valid game data.
Hermes receives the creator's intent and is instructed to return a strict quiz schema:
{
"questions": [
{
"prompt": "Question text",
"type": "MULTIPLE_CHOICE",
"options": ["A", "B", "C", "D"],
"correctAnswers": ["A"],
"difficulty": "MEDIUM",
"explanation": "Why the answer is correct"
}
]
}
The backend then validates and normalizes the output before it ever reaches gameplay. If a question is malformed, it is rejected instead of silently breaking the room.
2. Agent Adapter Built for Production Constraints
Hermes Agent runs as its own Cloud Run service. During testing I hit real deployment issues: container startup, Cloud Run port binding, long-running agent loops, and noisy CLI output around JSON.
I solved this by building a dedicated adapter that:
- Listens on Cloud Run's
PORTcorrectly. - Secures requests with a shared secret between the backend and Hermes service.
- Uses ephemeral runtime state so the agent does not hang on Cloud Storage/FUSE SQLite WAL files.
- Bounds generation to a single quiet chat turn for predictable response time.
- Extracts clean quiz JSON even when the CLI returns session noise or markdown wrappers.
That adapter made Hermes usable as a real service, not just a local experiment.
3. Human-in-the-Loop Creation
I intentionally kept the creator in control. Hermes accelerates quiz creation, but the creator can still:
- Edit every generated question.
- Choose predefined or custom categories.
- Pick question type: yes/no or multiple choice.
- Use voice dictation for questions and options.
- Import questions from a template.
- Save questions into a reusable quiz bank.
- Search and reuse existing quiz questions later.
This matters because a great quiz is partly AI generation and partly human taste. Hermes gets the creator 80% of the way there, then GridyPig gives them tools to polish the final game.
What Makes It More Than a Quiz Generator
The generated quiz becomes part of a full multiplayer game system:
Turn-by-turn Quiz Clash: players answer in sequence and the highest score wins.
GridyPig streak mode: correct answers can keep a player in control, preserving the push-your-luck feel of the original game.
Server-side validation: scoring and turns are enforced by the backend, not trusted to the browser.
Inactivity countdowns: if a player stalls, the room warns everyone and passes the turn safely.
Final standings: the game ends with a leaderboard showing how each participant performed.
Tenant workspaces: each business/community can run its own branded games.
Reusable quiz bank: creators can build from scratch or reuse questions over time.
What I Learned
The biggest lesson was that agentic features need product boundaries.
It is tempting to let an agent do everything, but a real-time game needs deterministic behavior. Hermes is excellent at helping create the content, but the platform still needs strict validation, typed payloads, server-side scoring, and predictable fallback behavior.
So the winning architecture became:
Creator intent -> Hermes Agent -> Structured quiz draft -> Backend validation -> Human editing -> Live multiplayer game
That separation keeps the AI useful without letting it destabilize the game loop.
What's Next
I want to expand the Hermes layer from quiz generation into a full game-master assistant:
- Suggest better distractor options for weak multiple-choice questions.
- Rebalance difficulty based on historical answer rates.
- Generate themed quiz packs for events, product launches, schools, and community nights.
- Help creators convert reusable quiz-bank content into polished game sessions.
- Create post-game summaries that explain what players struggled with and what they learned.
GridyPig started as a dice game. With Hermes Agent, it is becoming a creator-powered game platform where anyone can turn an idea into a live multiplayer experience.
SOCIAL SHARE CARD GENERATOR