Back to Prompt Library
implementation
Build the application
Inspect the original prompt language first, then copy or adapt it once you know how it fits your workflow.
Linked challenge: Build a CLIMADA Coastal Flood Asset Risk Modeler
Format
Code-aware
Lines
63
Sections
11
Linked challenge
Build a CLIMADA Coastal Flood Asset Risk Modeler
Prompt source
Original prompt text with formatting preserved for inspection.
63 lines
11 sections
No variables
1 code block
## Build
Assess coastal infrastructure resilience against projected storm surge events using the CLIMADA modeling framework. Quantify expected asset damage from simulated extreme weather scenarios to formulate municipal hazard adaptation strategies.
## User
Coastal Infrastructure Resilience Specialist
## Workflow
1. Retrieve historical or probabilistic tropical cyclone and storm surge hazard sets from the CLIMADA data API.
2. Load port and energy asset coordinates as custom exposures and define asset-specific vulnerability functions.
3. Calculate probabilistic impact metrics, such as expected annual damage, by combining hazard, exposure, and vulnerability.
4. Output structured asset vulnerability summaries with aggregated damage projections and risk exposure tiers.
## Interface
Command-line tool generating structured JSON/CSV vulnerability reports alongside visualizations of surge hazard impacts.
## Data
Query the CLIMADA Data API for relevant tropical cyclone storm surge hazard grids. Maintain local CSV or GeoJSON of critical coastal infrastructure for exposures.
Starter examples below are synthetic. They are not downloaded records.
## Source
[CLIMADA impact modeling](https://raw.githubusercontent.com/CLIMADA-project/climada_python/main/README.md)
Leverages the CLIMADA python library to fetch hazard data, model custom exposures, and execute impact calculations for risk assessment.
## Tools
pydantic-ai, climada, pandas, geopandas.
Orchestrates the data retrieval and impact assessment tasks while structuring output vulnerability reports into strictly typed schemas.
Language model supporting strict schema enforcement for generating spatial hazard mitigation briefs and structuring report outputs.
## Deliverables
Submit runnable source, pinned dependencies, setup commands, a working interface, example outputs, and a recorded end-to-end demo. Include tests and an action log.
## Acceptance
- Successfully fetches storm surge hazard matrices via the CLIMADA API.
- Defines and computes impact combinations applying vulnerability functions against asset exposures.
- Outputs a valid dataset detailing expected damages and structured exposure tier classifications for each asset.
## Starter Examples
```json
[
{
"input": {
"facility_id": "PORT-DOCK-88",
"asset_value_usd": 5000000,
"hazard_scenario": "100_year_surge",
"calculated_damage_usd": 250000
},
"expected_output": {
"facility_id": "PORT-DOCK-88",
"damage_ratio": 0.05,
"exposure_tier": "MODERATE",
"adaptation_recommendation": "IMPROVE_DRAINAGE_AND_ELEVATE_EQUIPMENT"
}
},
{
"input": {
"facility_id": "ENERGY-SUBSTATION-02",
"asset_value_usd": 12000000,
"hazard_scenario": "100_year_surge",
"calculated_damage_usd": 4800000
},
"expected_output": {
"facility_id": "ENERGY-SUBSTATION-02",
"damage_ratio": 0.4,
"exposure_tier": "CRITICAL",
"adaptation_recommendation": "CONSTRUCT_SEAWALL_REVETMENT"
}
}
]
```
## Safety
Supplies advisory spatial risk modeling metrics; does not replace licensed geotechnical, civil engineering, or actuarial surveys.
Use mock external writes. Require human review before any real deployment.Adaptation plan
Keep the source stable, then change the prompt in a predictable order so the next run is easier to evaluate.
Keep stable
Hold the task contract and output shape stable so generated implementations remain comparable.
Tune next
Update libraries, interfaces, and environment assumptions to match the stack you actually run.
Verify after
Test failure handling, edge cases, and any code paths that depend on hidden context or secrets.