Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/eva/models/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ class ModelConfig(BaseModel):

# CASCADE-only latency controls.
pre_tool_speech: str = Field(
"off",
"auto",
description="Prompt a model-generated lead-in before tool calls: 'off' or 'auto'.",
)

Expand All @@ -206,7 +206,7 @@ def _normalize_pre_tool_speech(cls, value: str) -> str:
return value.lower() if isinstance(value, str) else value

llm_streaming: bool = Field(
False,
True,
description="Stream Chat Completions output to TTS sentence-by-sentence.",
)
parallel_tool_calls: bool | None = Field(
Expand Down
12 changes: 6 additions & 6 deletions tests/unit/models/test_config_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -848,16 +848,16 @@ def test_runconfig_roundtrip(self):


class TestLatencyOptimizationFlags:
def test_defaults_off(self):
def test_defaults_on(self):
c = _config(env_vars=_BASE_ENV)
assert c.model.pre_tool_speech == "off"
assert c.model.llm_streaming is False

def test_set_via_env(self):
c = _config(env_vars=_BASE_ENV | {"EVA_MODEL__PRE_TOOL_SPEECH": "auto", "EVA_MODEL__LLM_STREAMING": "true"})
assert c.model.pre_tool_speech == "auto"
assert c.model.llm_streaming is True

def test_set_via_env(self):
c = _config(env_vars=_BASE_ENV | {"EVA_MODEL__PRE_TOOL_SPEECH": "off", "EVA_MODEL__LLM_STREAMING": "false"})
assert c.model.pre_tool_speech == "off"
assert c.model.llm_streaming is False

@pytest.mark.parametrize("value", ["bogus", "force"])
def test_invalid_pre_tool_speech_rejected(self, value):
with pytest.raises(ValueError):
Expand Down
Loading