Skip to content

guyroyse/agents-n-arbiters

Repository files navigation

Agents & Arbiters

A multi-agent text adventure game built for Azure with Redis, LangGraph.js, and Agent Memory Server.

Overview

In this game, multiple AI agents (location, items, NPCs) independently react to player input. Each agent contributes specialized knowledge—locations provide environmental context, items offer interaction possibilities, NPCs deliver character-driven responses—while an arbiter synthesizes all agent responses into a single, coherent game experience. This collaborative approach creates richer, more dynamic storytelling than single-agent systems.

While this example is for a game, multi-agent collaboration (MAC) has powerful applications beyond gaming. For example, a customer support chatbot could use specialized agents to handle different aspects of a customer request—one agent analyzes technical issues, another handles billing questions, and a third manages escalations—with an arbiter providing unified responses to customers.

You can read more about multi-agent collaboration in the LangGraph documentation.

Prerequisites

Getting Started

  1. Copy configuration files:
cp .env.example .env
cp functions/ana-api/local.settings.example.json functions/ana-api/local.settings.json

Then edit both .env and local.settings.json to add your OpenAI API key.

  1. Start services
 docker compose up
  1. Install dependencies and start development:
npm install
npm run dev

Development URLs

Project Structure

This is a TypeScript monorepo built with npm workspaces:

Core Packages

  • shared/ana-types/ (@ana/types) - Pure TypeScript types and Zod schemas
  • shared/ana-common/ (@ana/common) - Shared utilities, Redis/LLM clients, admin functions
  • shared/ana-domain/ (@ana/domain) - Entity classes and game state management
  • shared/ana-agents/ (@ana/agents) - Complete multi-agent LangGraph system

Applications

  • static-web-apps/ana-web/ (@ana/web) - Svelte 5 frontend with terminal-style game interface
  • functions/ana-api/ (@ana/api) - Azure Functions v4 API endpoints
  • static-web-apps/ana-admin/ (@ana/admin) - Admin interface for logs and template management

Infrastructure

  • containers/agent-memory-server/ - Containerized Agent Memory Server (working memory)
  • data/redis/ - Persistent Redis data storage for local development
  • infrastructure/ - Infrastructure as Code (Bicep templates for Azure deployment)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •