22
33Welcome to the Lotus development guide! This document will help you get set up and contributing to the project.
44
5+ > ** Note** : Pre-built binaries are not yet available. These prerequisites are for building from source.
6+
57## Getting Started
68
79### Prerequisites
810
9- - ** [ Bun] ( https://bun.sh/ ) ** : Lotus is built on the Bun runtime. Ensure you have the latest version installed.
11+ - ** [ Rust] ( https://rustup.rs/ ) ** (latest stable) — builds the server and game engine
12+ - ** [ Bun] ( https://bun.sh/ ) ** (v1.0.0+) — builds the web/TUI/Discord clients
13+
14+ Scripts are written in TypeScript and compile down to Lua internally — you don't need to know Lua.
1015
1116### Installation
1217
@@ -17,41 +22,53 @@ Welcome to the Lotus development guide! This document will help you get set up a
1722 cd lotus
1823 ```
1924
20- 2. Install dependencies:
25+ 2. Install TypeScript dependencies:
2126 ` ` ` bash
2227 bun install
2328 ` ` `
2429
30+ 3. Build Rust backend:
31+ ` ` ` bash
32+ cargo build --release
33+ ` ` `
34+
2535# ## Project Structure
2636
27- Lotus is a monorepo managed by Bun workspaces.
28-
29- - ** ` apps/` ** : Deployable applications.
30- - ` server` : The core game server.
31- - ` web` : The web frontend.
32- - ` cli` : The terminal client.
33- - ` discord-bot` : The Discord integration.
34- - ** ` packages/` ** : Shared libraries.
35- - ` core` : The game engine logic.
36- - ` scripting` : The Reed compiler and interpreter.
37- - ` client` : The TypeScript SDK.
38- - ` shared` : Shared types and utilities.
39- - ** ` plugins/` ** : Optional game features.
40- - ` ai` : LLM integration.
41- - ` memory` : Vector memory system.
37+ Lotus is a monorepo with Rust backend (` crates/` ) and TypeScript frontends (` apps/` , ` packages/` ).
38+
39+ # ### Rust Crates (`crates/`)
40+
41+ - ` lotus-ir` : S-expression types and validation
42+ - ` lotus-core` : Entity system, capabilities, SQLite storage
43+ - ` lotus-runtime` : Script execution with LuaJIT
44+ - ` lotus-cli` : CLI binary
45+ - ` syntax/typescript` : TypeScript → S-expression transpiler
46+ - ` runtime/luajit` : S-expression → Lua codegen
47+ - ` transport/websocket-jsonrpc` : WebSocket server
48+ - ` plugins/* ` : Native plugins (ai, fs, net, sqlite, procgen, vector, memory)
49+ - ` apps/notes-server` : Notes app server
50+ - ` apps/filebrowser-server` : File browser app server
51+
52+ # ### TypeScript (`apps/`, `packages/`)
53+
54+ - ** ` apps/` ** : Frontend applications
55+ - ` web` : Main web frontend (SolidJS)
56+ - ` tui` : Terminal user interface
57+ - ` discord-bot` : Discord integration
58+ - ` notes` : Wiki-style notes client
59+ - ` filebrowser` : File browser client
60+ - ** ` packages/` ** : Shared libraries
61+ - ` client` : WebSocket client SDK
62+ - ` shared` : Shared types (JSON-RPC protocol)
4263
4364# ## Running Tests
4465
45- To run tests across the entire workspace:
46-
4766` ` ` bash
48- bun test
49- ` ` `
50-
51- To run tests for a specific package:
67+ # Rust tests
68+ cargo test --workspace
5269
53- ` ` ` bash
54- bun test --filter @lotus/core
70+ # TypeScript tests
71+ bun test
5572` ` `
5673
5774# # Building the Documentation
0 commit comments