Run artifact

workspace/targets/Quakes/ANALYSIS.md

Blueprint Analysis: Quakes

Commander Expectations

Crew

CrewCharge
CommanderDefines intent and decides what done means.
Team LeadConfirms epic completeness and stakeholder expectations.
Planning CrewAuthors atomic specifications and the ordered Manifest.
Shipyard CrewBuilds the tickets without synchronous Commander access.

Story List

Feature: Fetch Earthquake Data

IDStoryHigh-level AC
FETCH-001Fetch and save the USGS GeoJSON feedThe command requests the specified date range and magnitude, saves a valid response unchanged, and reports its feature count. Network, HTTP, or invalid-response failures write no file.

Feature: Report on Saved Earthquake Data

IDStoryHigh-level AC
REPORT-001Summarize earthquake eventsThe report applies the magnitude filter and writes event count, time bounds, magnitude statistics, and tsunami count as CSV.
REPORT-002List the largest eventsThe report applies the magnitude filter and count option, orders by magnitude descending then time ascending, and writes CSV.
REPORT-003Report events by dayThe report applies the magnitude filter and writes date totals, daily maximum magnitudes, and the overall total as CSV.
REPORT-004Report events by regionThe report applies the magnitude filter, groups by the specified region rule, and orders groups by count descending then region ascending.
REPORT-005Find events near a pointThe report applies the magnitude filter, includes events within the radius using the specified haversine distance, and orders by distance then time.

Feature: Automated Verification

IDStoryHigh-level AC
VERIFY-001Provide the automated test suiteA POSIX-compatible bin/test.sh runs the pytest suite from the application root and exits zero only when every test passes.

Story Guidance

Named stories planning must produce. Authoritative record: STORY_GUIDANCE.json.

None.

Surfaced Acceptance Criteria

None.

Source Inventory

PathContent kindDispositionReason
sources/INSTRUCTIONS.mdmarkdownanalyzedreadable UTF-8
sources/quakes_2025-01-01_07.geojsontextanalyzedreadable UTF-8
sources/run.shcodeanalyzedreadable UTF-8

Relationship Model

Source or groupRelationship typeRelated source or groupEvidenceDelivery implication
sources/INSTRUCTIONS.mdinstruction-to-testsources/run.shThe instructions define command behavior; the harness compares report output and exit codes with known answers.Implement report behavior against the staged conformance harness.
sources/quakes_2025-01-01_07.geojsondependencysources/run.shThe harness uses the frozen GeoJSON snapshot for report checks.Stage the snapshot with the harness so acceptance can run offline.
sources/INSTRUCTIONS.mddependencyFETCH-001Fetch uses the USGS event service and specifies response validation and failure behavior.Stub the HTTP call in tests; do not rely on network access.
sources/INSTRUCTIONS.mddependencyREPORT-001–REPORT-005All reports read a saved FeatureCollection and share event fields, time, region, filtering, and CSV rules.Plan shared parsing and normalization as supporting implementation for report stories.
sources/INSTRUCTIONS.mddependencyVERIFY-001The instructions require pytest coverage of reports, options, fetch stubbing, and exit codes.Include offline fetch stubbing and the required behavior coverage in the test suite.

Source Roles

PathRolePlan dispositionBuild disposition
sources/INSTRUCTIONS.mdauthor intentprompt-onlynone
sources/quakes_2025-01-01_07.geojsonassetcontextstage
sources/run.shconformance harnesscontextstage

Planning Instructions

Delivery Shape

A Python command-line application named quakes reads saved GeoJSON FeatureCollections to produce five CSV reports, and fetches feed data from the USGS event service. The primary flow is fetch a date range to a file, then run one or more reports against that saved file. Reports also accept files supplied independently. The supplied harness and snapshot provide offline final verification.

Story Realization Map

Story IDDurable Blueprint scopeEvidenceRelated filesRequires
FETCH-001fetch command, request construction, response validation, unchanged file outputsources/INSTRUCTIONS.mdsources/run.shCapability, integration, focused tests
REPORT-001summary commandsources/INSTRUCTIONS.md, sources/run.shsources/quakes_2025-01-01_07.geojsonCapability, focused tests
REPORT-002top commandsources/INSTRUCTIONS.md, sources/run.shsources/quakes_2025-01-01_07.geojsonCapability, focused tests
REPORT-003daily commandsources/INSTRUCTIONS.md, sources/run.shsources/quakes_2025-01-01_07.geojsonCapability, focused tests
REPORT-004regions commandsources/INSTRUCTIONS.md, sources/run.shsources/quakes_2025-01-01_07.geojsonCapability, focused tests
REPORT-005near command and haversine searchsources/INSTRUCTIONS.md, sources/run.shsources/quakes_2025-01-01_07.geojsonCapability, focused tests
VERIFY-001POSIX bin/test.sh and pytest suitesources/INSTRUCTIONS.mdsources/run.sh, sources/quakes_2025-01-01_07.geojsonTest harness, acceptance contract

Test and Acceptance Strategy

Each report story gets focused tests for its command behavior, formatting, relevant options, and edge cases. Fetch tests replace the HTTP call with a stub. The suite must also cover malformed arguments, unreadable or invalid files, region and distance rules, and empty matches.

Final acceptance runs the supplied harness unfiltered from the application root. VERIFY-001 is the terminal verification story and gates on all implementation stories. The harness exit status is the acceptance verdict.

Sequencing and Dependencies

Implement shared argument handling, FeatureCollection reading, event normalization, filtering, and CSV output as support for the command stories. Fetch is independently testable through its HTTP stub. Report stories depend on shared reading and filtering behavior. The automated suite exercises all command stories; final harness verification follows their completion and uses the staged snapshot.

Source Conflicts and Gaps

No unresolved source conflicts or human-owned planning decisions. The sources specify the CLI, runtime, standard-library HTTP client, test runner, command behavior, and offline acceptance harness. Deployment is not applicable to this CLI.

Analysis Notes

generated: 2026-10-24 blueprint: /mnt/c/Users/barlo/projects/drydock/uat/Quakes/runs/20261024.065111/workspace/targets/Quakes/blueprint

Quality: Ready blockers: 0 questions: 0 features: 3 stories: 7 stack: Python 3.11+, standard library (urllib.request), pytest display_name: not proposed short_description: not proposed

None.