AI-native game development framework based on Dual-World Theory. Uses View=f(State) to simplify complex game logic and state management.
127 GitHub stars with active community development
Open source under MIT license — free to use and modify
Event-driven game state engine for AI-native development
Cobweb is an AI-native game development framework based on Dual-World Theory, implementing a deterministic state machine driven by events. It separates game logic into a pure Logic Layer and a replaceable Presentation Layer, where View = f(State). Developers define events and rules that govern all state transitions, making the entire game process recordable, traceable, and AI-perceivable. Cobweb is ideal for building complex, data-driven game systems that benefit from AI automation and clear architectural boundaries.
Cobweb is a JavaScript framework designed to be engine-agnostic. You can integrate it with any engine by connecting its event system to your game's rendering pipeline.
Yes, Cobweb's event-driven architecture is optimized for deterministic state updates, making it suitable for real-time games. The presentation layer can be throttled independently to maintain performance.
Cobweb focuses on single-player state management, but its deterministic nature makes it straightforward to extend for multiplayer via state synchronization and conflict resolution.
Install Cobweb to get started:
Or visit the project page for detailed setup instructions.