1009 B
1009 B
AGENTS.md
Architecture
This repository contains idea154-civicmesh-studio-federated, a Python package for federated urban resilience coordination.
Core modules:
contracts.py: canonical Pydantic contracts forLocalModel,SharedSignals,PlanDelta, andDualVariable.registry.py: Graph-of-Contracts adapter registry plus starter GIS, weather, and pump adapters.sync.py: deterministic delta log with audit hashes and replay.solver.py: lightweight ADMM-style coordinator for cross-neighborhood plan updates.
Tech Stack
- Python 3.11+
pydanticfor validation and canonical serializationpytestfor testssetuptoolsbuild backend
Rules
- Keep contracts canonical and deterministic.
- Prefer small, explicit changes over broad abstractions.
- Preserve reproducible serialization and replay behavior.
- Add or update tests when changing contract shapes, adapter behavior, or solver math.
Testing
bash test.shpython3 -m pytestpython3 -m build