System Architecture Overview
Alice operates within the 555-mono ecosystem, a decentralized arcade platform.Components
1. Frontend (555-mono/apps/web)
- Framework: Next.js (React).
- Role: User interface, game launcher (
GamePlayer.tsx), wallet connection. - Game Integration: Games are loaded in iframes.
alice-sdk.jsbridges the gap between the frontend and the game’s internal state.
2. Backend (backend)
- Language: Go.
- Role: API server, database (PostgreSQL/SQLite), state management.
- Key Models:
Cabinet: Represents a game instance. StoresPossessionMetadataandPossessionSchema.ArcadeState: Global settings (theme, music).
- API: REST endpoints for agents and frontend.
3. Economics (555x402)
- Blockchain: Solana.
- Role: Token management, rewards, payments.
- Integration: Alice can trigger economic events (airdrops, bounties) via backend integrations (planned).
4. Agent (Alice)
- Framework: ElizaOS.
- Role: Autonomous operator, “Ghost in the Machine”.
- Capabilities:
- Possession: Control game states via
POSSESS_CABINET. - Memory: Learn from interactions via
LOG_MEMORY. - Communication: Chat with users, tweet updates.
- Possession: Control game states via
Data Flow
- User plays a game (Frontend).
- Game reports score/state to Backend.
- Alice (Agent) polls Backend for active cabinets.
- Alice decides to intervene (Possession).
- Alice sends
POSSESS_CABINETcommand to Backend. - Backend updates
Cabinetstate. - Frontend (via SSE or polling) receives update and forwards to Game via
alice-sdk.js. - Game applies effect (e.g., God Mode).
- Alice observes result and calls
LOG_MEMORY.