- Python 69.6%
- TypeScript 29.2%
- CSS 0.6%
- Dockerfile 0.2%
- Shell 0.2%
- Other 0.1%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
|
|
||
| backend | ||
| docs | ||
| examples | ||
| frontend | ||
| scripts | ||
| spec | ||
| .dockerignore | ||
| .env.example | ||
| .gitignore | ||
| .pre-commit-config.yaml | ||
| CLAUDE.md | ||
| docker-compose.smoke.yml | ||
| docker-compose.yml | ||
| Dockerfile | ||
| instructions.md | ||
| LICENSE | ||
| Makefile | ||
| README.md | ||
| STATUS.md | ||
PHŌS
Self-hosted web application for designing opaque shadow stencils and lithophanes (later reflectors and mathematical lighting objects) and verifying them by forward simulation of the exported, reloaded file. Licence: GPL-3.0-or-later (LICENSE).
Status: Phase 1 (inverse single-view shadow design) approved; Phase 2 (Lithophane Studio: photo → edits → planar or cylindrical lithophane, verified STL/3MF) implemented and awaiting review — see STATUS.md. Specification: spec/SPEC.md, spec/PHASE-1.md, spec/PHASE-2.md.
Run it (Docker)
GIT_COMMIT=$(git rev-parse HEAD) docker compose up -d --build
Then open http://localhost:8000/phos/ — exactly this address: requests from any other origin (e.g. 127.0.0.1) are rejected by the CSRF protection and the app shows a banner. To serve it under another address set PHOS_PUBLIC_URL in .env. Then follow the user guide. Settings: .env.example,
deployment.
Develop
make setup # uv sync (backend/) + pnpm install (frontend/) + Playwright browser
make lint # ruff, mypy, eslint, tsc, dependency-licence check
make test # backend pytest + frontend vitest
make numerics # reference-numerics suite; prints measured vs threshold
make e2e # Playwright against a fresh backend + Vite dev server (incl. both §10b acceptance tests)
make docker-smoke # build + start the image, API smoke and browser acceptance against the container
Requires uv (Python 3.12 is fetched by uv), pnpm and, for docker-smoke, Docker with compose. Development
servers: cd backend && uv run uvicorn --factory phos.api.app:create_app --no-proxy-headers --port 8000 and
cd frontend && pnpm dev (proxies /api). Conventions: right-handed, Z up, millimetres everywhere.
Documentation
User guide · architecture · coordinate systems · optics · shadow simulation · inverse shadow design · lithophanes · image pipeline · manufacturing · tolerances · provenance · HTTP API · deployment · benchmarks · physical validation · adding presets · dependency licences