Skip to content

Fix System One score legend labels - #294

Open
webdevtodayjason wants to merge 1 commit into
mainfrom
fable/issue-288
Open

webdevtodayjason wants to merge 1 commit into
mainfrom
fable/issue-288

Conversation

@webdevtodayjason

@webdevtodayjason webdevtodayjason commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

Problem

/v1/systemone built score legends from criteria keys, so labelled levels such as {"0": "Calm"} returned {"0": "0"} instead of the display label the caller sent.

Decision

Preserve score display labels during question translation and use them only for the outbound legend. Criteria keys remain the source for model options, selected-level lookup, probabilities, and expected-score arithmetic.

Proof

  • .venv/bin/pytest -q tests/test_systemone.py: 53 passed
  • .venv/bin/pytest -q tests/: 3243 passed, 2 skipped, 1 xfailed, with one unrelated free-space timing assertion that passed immediately when rerun alone
  • .venv/bin/pytest -q tests/test_download_fit.py::test_free_space_is_measured_on_the_nearest_parent_that_exists: 1 passed
  • .venv/bin/ruff check: all checks passed

Changelog: Fixed /v1/systemone score legends to return criteria labels instead of level keys.

Fixes #288


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

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.

systemone: score legend returns the level keys instead of the labels sent in criteria

1 participant