A Python implementation of advanced valuation models, designed for 1:1 mathematical parity with reference Google Sheets models.
This is a UV workspace monorepo with two packages:
packages/
├── valuation-engine/ # Pure computation library (zero external deps)
│ └── src/valuation_engine/
│ ├── engine.py # FCFF Ginzu engine
│ ├── inputs_builder.py # Canonical input preparation
│ └── models/ # Data contracts (re-exports)
│
└── valuation-service/ # FastAPI REST API
└── src/valuation_service/
├── app.py # FastAPI application factory
├── api/ # Endpoints, schemas
├── connectors/ # Data source adapters (Yahoo, SEC)
├── services/ # Orchestration layer
└── utils/ # JSON sanitization, etc.
tests/ # All tests (engine + service)
docs/ # Methodology & documentation
- Python 3.11+
- uv (Python package manager)
# Install all dependencies
uv sync --all-packages
# Run test suite
uv run pytest tests/ -v
# Start development server
uv run uvicorn valuation_service.app:app --reload
# Lint code
uv run ruff check packages/ tests/- Methodology — FCFF Ginzu valuation model documentation
- Engine Guide — Usage guide for the valuation engine
- Cost of Capital — Cost of capital worksheet reference