Skip to content

feat(engine): use the type menu's names in question text and step labels - #167

Merged
prayaslashkari merged 2 commits into
developmentfrom
feat/type-menu-names-164
Nov 17, 2026
Merged

prayaslashkari merged 2 commits into
developmentfrom
feat/type-menu-names-164

Conversation

@prayaslashkari

@prayaslashkari prayaslashkari commented Nov 17, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

The noun lives once on each entity module and feeds the question sentence, the step labels and the count messages.

 engine/entities/
-├── samples.ts    LABEL = 'samples'
+├── samples.ts    LABEL = 'sample results'
-├── aquifers.ts   LABEL = 'aquifers'
+├── aquifers.ts   LABEL = 'ground water aquifers'
-└── streams.ts    LABEL = 'streams'
+└── streams.ts    LABEL = 'streams and flowlines'
-What samples in Indiana are downstream of Waste Treatment and Disposal facilities?
+What sample results in Indiana are downstream of Waste Treatment and Disposal facilities?
-What wells in Maine are within at most 2 miles of bedrock aquifers?
+What wells in Maine are within at most 2 miles of bedrock ground water aquifers?
-Finding samples downstream of facilities
+Finding sample results downstream of facilities
-No samples match the first block, so the question has no answer.
+No sample results match the first block, so the question has no answer.

Closes #164

Evidence

  • Before: each noun went red first with its old value still in place: stepLabels failed 2 of 3 (samples), blockWording 2 of 7 (streams), then the 2 new aquifer cases:

    describe(aquifers)                     expected 'ground water aquifers', got 'aquifers'
    describe(streams, 1 type)              expected 'Stream / River streams and flowlines', got 'Stream / River streams'
    planPipeline(samples downstream).step  expected 'Finding sample results downstream of facilities'
    

    After: npm test passed 594, skipped 11. query-shapes.txt (the SPARQL golden file) did not move; only question-text.txt was re-recorded, and every line in its diff is a noun swap. npm run build passed. npm run lint shows the same 15 errors that were already there.

  • The raw-type-name check in stepLabels now removes each real label before it looks for type names, because "ground water aquifers" contains "aquifers". It still catches a bare "waterBodies" or "aquifers".

Merge Danger

Door: two-way

Wording only. Reverting the three constants restores the old text.

Blast Radius: copy

  • Cached dashboard results store step descriptions in their list of queries run, so those keep the old step names until npm run warm-cache runs after deploy. No DATA_VERSION bump is needed: the answers are the same.
  • Some filtered sentences read long: "Stream / River streams and flowlines", and "PFHpA Groundwater (GW) sample results" next to "ground water aquifers".
  • The hand-written card titles in engine/constants/prebuiltQueries.ts still say "Samples".

prayaslashkari and others added 2 commits November 17, 2026 15:28
…and flowlines as the Type menu does

The question sentence, step labels and count messages now use the Type
menu's nouns. SPARQL is unchanged; only the question-text snapshot moved.

Closes #164

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
@railway-app

railway-app Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

🚅 Deployed to the explorer-app-pr-167 environment in sawgraph-explorer

Service Status Web Updated
sawgraph-api ❌ Build Failed (View Logs) Web Nov 17, 2026 at 8:35 pm UTC
sawgraph-web ✅ Success (View Logs) Web Nov 17, 2026 at 8:30 pm UTC
1 service not affected by this PR
  • sawgraph-db-dev

@prayaslashkari
prayaslashkari merged commit 5a3919b into development Nov 17, 2026
2 of 3 checks passed

This branch had an error being deployed

1 failed deployment
sawgraph-explorer / explorer-app-pr-167 — d061ba56 Deployed Nov 17, 2026 by railway-app[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant