Guide for contributors working on Bonsai Desk.
Install the same prerequisites listed in installation.md, then run:
git clone https://github.com/Kxrbx/BonsaiDesk.git
cd BonsaiDesk
.\install.bat
.\scripts\check.ps1If you prefer PowerShell scripts directly:
powershell -ExecutionPolicy Bypass -File .\scripts\bootstrap.ps1.\launch-app.batOr run each side manually:
powershell -ExecutionPolicy Bypass -File .\scripts\run-backend.ps1
powershell -ExecutionPolicy Bypass -File .\scripts\run-frontend.ps1BonsaiDesk/
|-- backend/
| |-- app/
| | |-- api/ # FastAPI route handlers
| | |-- core/ # Runtime and chat logic
| | |-- db/ # SQLite persistence
| | `-- main.py # FastAPI app entrypoint
| |-- tests/
| `-- requirements.txt
|-- frontend/
| |-- src/
| |-- package.json
| `-- vite.config.ts
|-- scripts/
|-- docs/
`-- .github/
Run the full project check:
.\scripts\check.ps1Backend tests only:
cd backend
..\.venv\Scripts\python.exe -m unittest discover -s tests -vFrontend production build:
cd frontend
npm run build- Use type hints.
- Prefer
snake_casefor functions and variables,PascalCasefor classes. - Keep docstrings concise and useful.
- Use
camelCasefor variables/functions andPascalCasefor components/types. - Keep components small and move reusable API/types logic into shared modules.
- Update versions in
backend/app/__init__.py,frontend/package.json, andfrontend/package-lock.json. - Update CHANGELOG.md.
- Run
.\scripts\check.ps1. - Create and push a tag such as
v0.3.0. - Draft a GitHub release.