AI-driven text adventure: the agent chooses actions in a small dungeon (LLM required).
From the elizaOS repository root:
bun install
export OPENAI_API_KEY=your_key_herecd examples/text-adventure
cp .env.example .env # set OPENAI_API_KEY
bun install
# Quieter logs
LOG_LEVEL=fatal bun run game.ts
# Optional persistent DB
PGLITE_DATA_DIR=./adventure-db LOG_LEVEL=fatal bun run game.ts- Multiple rooms, items, and enemies
- Autonomous or guided play (see
game.tsfor flags) - Uses
ModelType.TEXT_SMALLfor action selection
examples/chat/chat.ts— CLI chatexamples/tic-tac-toe/game.ts— no-LLM minimax demoexamples/game-of-life/game.ts— no-LLM multi-agent simulation