The AI-First
Game Engine
Built on Bevy and Rust. Describe your game in natural language. Preview every change. Undo anything. Ship everywhere.
You
Add a tropical island with palm trees and an ocean surrounding it
Grai AI
Planning 4 operations: TerrainOp, WaterOp, 2× EcsOp...
See It In Action
Prompt to Scene
Type what you want. Watch it appear. Every change is previewable and reversible.
“Create a medieval village on a hillside with cobblestone paths, a central marketplace with merchant stalls, and a stone watchtower overlooking the valley. Add warm evening lighting with torches along the paths.”
Grai AI — Plan
- • TerrainOp: Generate hillside terrain mesh
- • 12× EcsOp: Spawn buildings, stalls, watchtower
- • RenderOp: Evening lighting + torch point lights
- • AssetOp: Bind cobblestone material to paths
Core Philosophy
AI That You Control
AI is a core editor subsystem — not a plugin. Every mutation is typed, validated, previewable, and fully reversible.
AI as a Core Subsystem
AI lives inside the editor as a first-class Bevy resource with full access to the scene graph, type registry, and project state.
Preview Before Apply
Every proposed change renders as a ghost overlay in the viewport and a structured diff in the AI Dock. Nothing touches your scene until you approve.
Full Undo at AI-Step Granularity
All AI mutations flow through typed Engine Operations executed via the command history. Undo an entire AI step with a single keystroke.
Possibilities
What You Can Build
From lush open worlds to tight puzzle rooms — describe it, and Grai builds it.
Tropical Islands
Terrain generation, ocean simulation, palm tree placement, and dynamic weather — all from a single prompt.
Medieval Villages
Cobblestone paths, merchant stalls, watchtowers, and warm torch lighting assembled automatically.
Sci-Fi Stations
Modular corridors, control rooms, airlocks, and holographic displays wired with blueprint graphs.
Fantasy Dungeons
Procedural room layouts, trap scripts, loot tables, and atmospheric fog — gameplay-ready from the start.
Workflows
Three Modes. One Engine.
From full manual control to pure AI-driven creation — pick the workflow that matches your experience.
You
Add a tropical island with palm trees and an ocean surrounding it
Grai AI
Planning 4 operations: TerrainOp, WaterOp, 2× EcsOp...
3D Viewport — Ghost preview of pending operations
Editor Mode
Full docking system with hierarchy, inspector, asset browser, and document tabs. Every panel, every shortcut — built for experienced game developers who want total control.
- Complete panel system
- Custom layouts
- Keyboard-first workflow
Vibe Mode
AI Dock fills the left side, a wide viewport fills the right. No hierarchy, no inspector, no clutter. Just you and the AI building a game together through conversation.
- Simplified interface
- Conversational workflow
- Zero learning curve
Story Mode
A 4-step wizard that takes you from a text prompt to a playable scene: Planning → Concept Art → 3D Asset Generation → Scene Assembly.
- Step-by-step guidance
- MeshyAI integration
- Prompt to playable
Story Mode
From Idea to Playable in Four Steps
Story Mode is a guided wizard that turns a text prompt into a complete, playable scene — no game dev experience required.
Planning
Describe your game idea. The AI generates a structured plan with scenes, assets, and gameplay systems.
Concept Art
MeshyAI generates concept images for each asset. Approve, reject, or regenerate until it matches your vision.
3D Generation
Approved concepts are converted to GLB models via MeshyAI. Auto-imported into the asset pipeline on approval.
Scene Assembly
Terrain, water, lighting, entity placement, and gameplay scaffolding — assembled and ready to play.
After assembly, continue in Vibe Mode, Editor Mode, or start another scene.
Asset Generation
Text to 3D with MeshyAI
Generate concept art and production-ready 3D models directly inside the editor. No external tools, no manual exports — just describe what you need.
Describe Your Asset
Write a natural language description — "a weathered wooden treasure chest with iron bands and a rusty lock."
Generate Concept Art
MeshyAI produces concept images. Approve the one that matches your vision, or regenerate with refined prompts.
Convert to 3D Model
The approved concept becomes a GLB model — auto-imported into your project's asset pipeline, ready to place in the scene.
Text Prompt
"A crystal sword with glowing runes"
Concept Image
Generated by MeshyAI — 4 variations
3D Model (GLB)
Auto-imported into asset pipeline
Placed in Scene
Bound to entity via AssetOp
Engine Operations
Every AI Action is an Operation
AI never directly mutates the Bevy World. All changes flow through typed, validated EngineOps — executed via the undo/redo command system and recorded for audit and replay.
Atomic Execution
If any op fails mid-step, the entire group rolls back.
ECS Operations
Spawn, despawn, reparent, rename, transform, and batch-edit entities and components.
Terrain & Water
Generate islands, sculpt terrain, paint layers, create oceans with wave parameters and foam.
Render Operations
Cameras, lights, post-processing, sky, fog, and Solari toggles — all as typed ops.
Script & Blueprint
Create and edit Rhai scripts and blueprint graphs with parse validation and graph invariant checks.
Asset Operations
Import files, manage metadata and tags, bind asset handles to components, generate with MeshyAI.
Story Operations
Story plans, concept art jobs, 3D generation requests, and full scene assembly pipelines.
Your AI, Your Choice
Multi-Provider AI
Bring your own API key. Switch providers anytime. The engine adapts — your workflow stays the same.
GPT-4o, GPT-4o-mini
Industry-leading reasoning and tool calling. Great for complex scene planning and multi-step operations.
Claude Sonnet, Claude Haiku
Nuanced understanding and careful execution. Excels at creative world-building and detailed asset descriptions.
Gemini 2.0 Flash, Gemini 2.0 Pro
Fast and multimodal. Strong at visual reasoning and rapid iteration cycles.
Plus a built-in Mock Provider for offline development and testing — no API key required.
How It Works
From Prompt to Playable
A transparent, auditable pipeline from natural language to engine mutation.
Prompt
Type a natural language request in the AI Dock chat or the Command Bar (Ctrl+K). Reference entities with @, assets with #, and templates with /.
Plan
The AI builds a minimal context snapshot, calls the provider, and returns a plan of typed tool calls mapped to EngineOps.
Preview
Review structured diffs in the Changes tab. Ghost overlays appear in the viewport showing spawn positions, transform changes, and terrain stamps.
Apply
Click Apply — operations execute atomically as a grouped step in Command History. If anything fails, the entire step rolls back.
Iterate
Undo the entire AI step with one keystroke. Refine your prompt. The conversation persists across mode switches.
Foundation
Built on Bevy & Rust
Grai Engine isn't a wrapper around an existing engine. It's built from the ground up on Bevy's ECS architecture and Rust's performance and safety guarantees.
Native Performance
Rust compiles to native code with zero-cost abstractions. No garbage collector, no runtime overhead.
ECS Architecture
Bevy's Entity Component System enables data-oriented design with cache-friendly memory layouts and parallel systems.
Memory Safety
Rust's ownership model eliminates entire classes of bugs — no null pointers, no data races, no use-after-free.
Rhai Scripting
Lightweight, sandboxed scripting language embedded in the engine. Safe by default, with parse-time validation.
Extensibility
Open & Extensible
AI-first doesn't mean AI-only. Grai gives you full control to extend, script, and customize every layer.
Rhai Scripting
Write game logic in a lightweight, sandboxed scripting language. Attach scripts to entities, iterate without recompiling.
Blueprint Graphs
Visual node-based logic for designers who prefer graphs over code. Full validation and type-safe connections.
Plugin System
Third-party plugins extend the engine through a dedicated host crate. AI is core — plugins are optional additions.
Ready to Build
the Future?
Grai Engine is in active development. Get early access, join the community, or back the project on our crowdfund page.