# Module Contracts ## Dataset Manager Contract ### Inputs - project id - uploaded file - declared dataset type when auto-detection is ambiguous ### Outputs - dataset record - metadata record - processing status ### Required states - empty: no datasets yet - uploading - processing metadata - ready - failed ## Raster Lab Contract ### Inputs - raster dataset id - optional area id ### Outputs - metadata panel - preview bounds - clip job - tile job ### Required states - no raster datasets - raster selected - unsupported raster - metadata failed ## Vector Lab Contract ### Inputs - vector dataset id - optional area id ### Outputs - feature count - geometry type summary - bounds - clip result - derived vector layer ## Detection Lab Contract ### Inputs - raster dataset id - area id - model id - confidence threshold - tile size ### Outputs - analysis run - detection features - confidence summary - GeoJSON export ## QA/QC Contract ### Inputs - prediction layer or detection run - reference layer, preferably GRB buildings - IoU threshold ### Outputs - precision - recall - F1 - matched features - false positives - false negatives - QA layer export ## Export Contract ### Inputs - project id - dataset id or analysis run id - export type ### Outputs - export record - downloadable file - metadata about source and creation date