# Skill: GeoAI Backend Build Use this skill when implementing FastAPI routers, services, schemas, domain logic, adapters or background-job entry points. ## Read first - `docs/governance/GEOINTEL_CONSTITUTION.md` - `docs/governance/ARCHITECTURE_INVARIANTS.md` - `docs/SERVICE_ARCHITECTURE.md` - `docs/API_CONTRACTS.md` - active pass prompt ## Backend rules - Keep routers thin. - Put business logic in services. - Put external integrations behind adapters. - Use typed request/response schemas. - Return stable error codes from the error catalog. - Do not let AI/model code write directly to the database. - Do not perform long processing synchronously when it belongs in jobs. ## Expected package pattern ```text backend/app/ api/ core/ db/ models/ schemas/ services/ workers/ adapters/ ``` ## Implementation checklist - [ ] Add/extend schemas. - [ ] Add/extend service. - [ ] Add/extend router. - [ ] Add validation. - [ ] Add tests or smoke checks. - [ ] Update docs/log/changelog when behavior changes. ## Completion report fields - Endpoints added/changed. - Services added/changed. - Validation rules added. - Tests run. - Contract deviations, if any.