Core Commands
Quick reference for common development tasks across all components.Frontend (Next.js)
Python (ML/Backend)
Rust (API/Core)
Utility Scripts
Located in the root directory for cross-component operations:Development Guidelines
React/Frontend Best Practices
Only use
useEffect
when truly necessary. See React documentation for alternatives.Color System
Use the predefined color system fromprospero/frontend/app/globals.css
:
Rust Development Standards
Code Organization
- Always place
use
statements at the top of files - Use workspace dependencies in
prospero/rust/Cargo.toml
- Never specify versions in individual crate
Cargo.toml
files
API Development
When modifying API endpoints:- Update the endpoint implementation
- Run golden tests to update OpenAPI spec:
- Update
structify.stainless.yml
if needed - Commit the updated
openapi.json
Formatting
Use the project-specific formatter configuration:Python Development
Workflow Functions
When using the analytics decorator, ensure helper functions are defined inside:API/SDK Generation
The SDK generation pipeline:- Source: Rust code with
utoipa
annotations - Generation: Golden tests create
openapi.json
- SDK Creation: Stainless uses OpenAPI + config
- Distribution: SDKs published to npm/PyPI
Always commit
openapi.json
changes with API modifications to keep SDKs in sync.Critical Rules
Code Quality Standards
- Write self-documenting code that doesn’t need comments
- Use clear, descriptive variable names
- Only add comments for genuinely complex logic
- No docstrings or file headers (they become outdated)
- No comments when removing code
Git Workflow
- Keep PRs atomic and under ~200 lines when possible
- Use branch naming convention:
claude/{feature-name}
- Write clear commit messages focusing on “why”
- Squash and merge to maintain linear history
Testing Strategy
Test Organization
- Unit Tests: Jest with React Testing Library
- Integration: Component interaction tests
- E2E: Playwright for user workflows
- Location:
__tests__/
directories
Running Tests
Environment Setup
Required Tools
1
Install UV for Python
2
Install Rust
3
Install Node.js
IDE Configuration
Install recommended extensions:
- Rust Analyzer
- Python (Pylance)
- ESLint
- Prettier
- Tailwind CSS IntelliSense
Startup Mindset
This is a fast-moving startup environment. We prioritize:- Speed: Ship features in days, not weeks
- Quality: Maintain high code standards
- Simplicity: Avoid over-engineering
- Focus: Build what users need now
Make good architectural choices but optimize for rapid iteration. Perfect is the enemy of shipped.