Fix System One score legend labels - #294
Open
webdevtodayjason wants to merge 1 commit into
Open
webdevtodayjason wants to merge 1 commit into
webdevtodayjason wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
/v1/systemonebuilt 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 passedChangelog: Fixed
/v1/systemonescore legends to return criteria labels instead of level keys.Fixes #288
Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.