diff --git a/hermes_constants.py b/hermes_constants.py index 64331299345..29dac85fe8a 100644 --- a/hermes_constants.py +++ b/hermes_constants.py @@ -797,7 +797,7 @@ VALID_REASONING_EFFORTS = ("minimal", "low", "medium", "high", "xhigh", "max") def parse_reasoning_effort(effort) -> dict | None: """Parse a reasoning effort level into a config dict. - Valid levels: "none", "minimal", "low", "medium", "high", "xhigh". + Valid levels: "none", "minimal", "low", "medium", "high", "xhigh", "max". Returns None when the input is empty or unrecognized (caller uses default). Returns {"enabled": False} for "none" (aliases: "false", "disabled", and YAML boolean False — users write ``reasoning_effort: false``/``off``/``no`` diff --git a/tests/test_hermes_constants.py b/tests/test_hermes_constants.py index f23bed43ab8..e4b064ed947 100644 --- a/tests/test_hermes_constants.py +++ b/tests/test_hermes_constants.py @@ -473,7 +473,7 @@ class TestParseReasoningEffort: @pytest.mark.parametrize( "value", - ["bogus", "very-high", "max", "0", "off", "true", "default"], + ["bogus", "very-high", "0", "off", "true", "default"], ) def test_unknown_levels_return_none(self, value): """Unrecognized strings fall back to the caller default (None).""" @@ -482,11 +482,11 @@ class TestParseReasoningEffort: def test_known_supported_levels_are_documented(self): """Guard against silently dropping a documented level. - The docstring promises "minimal", "low", "medium", "high", "xhigh". - If someone removes one from VALID_REASONING_EFFORTS without updating - the docstring, this test will fail and force the call out. + The docstring promises "minimal", "low", "medium", "high", "xhigh", + "max". If someone removes one from VALID_REASONING_EFFORTS without + updating the docstring, this test will fail and force the call out. """ - documented = {"minimal", "low", "medium", "high", "xhigh"} + documented = {"minimal", "low", "medium", "high", "xhigh", "max"} assert documented.issubset(set(VALID_REASONING_EFFORTS))