Project Structure
Interactive file explorer for the Luna monorepo. Click any file to see what it does.
Click a file or folder to read its description. Folders expand and collapse on click. The tree opens with the main backend and frontend directories pre-expanded.
Tip: data/ is gitignored — never commit it. server/ is Python,interfaces/web/ is TypeScript.
Key entry points
When adding new functionality, these are the files to start with:
| File | What to do here |
|---|---|
server/main.py | Mount new FastAPI routers. |
server/config.py | Add new .env settings as typed fields. |
server/services/tool_registry.py | Register new tools with a default permission mode. |
server/services/llm/ | Add a new LLM provider streaming generator. |
server/processes/registry.py | Register new background workers. |
interfaces/web/src/App.tsx | Add new top-level view modes. |
interfaces/web/src/store/index.ts | Add new global state slices and actions. |
electron/main.js | Add native menus, IPC handlers, or OS integrations. |
interfaces/cli/luna.mjs | Add new developer CLI subcommands. |
Where new code belongs
Routes go in server/routers/. Business logic goes in server/services/. Routers should be thin — validate input, call a service, return the result. Never put complex logic directly in a router.