fix azure speech model cost schema

Co-authored-by: ishaan-berri <ishaan-berri@users.noreply.github.com>
This commit is contained in:
oss-agent-shin 2026-05-09 00:32:25 +00:00
parent 126dc2ca16
commit 9a0f2885b3
No known key found for this signature in database

View file

@ -692,6 +692,10 @@ def test_aaamodel_prices_and_context_window_json_is_valid():
"type": "object",
"properties": {
"supports_computer_use": {"type": "boolean"},
"audio_transcription_config": {
"type": "string",
"enum": ["azure_speech"],
},
"cache_creation_input_audio_token_cost": {"type": "number"},
"cache_creation_input_token_cost": {"type": "number"},
"cache_creation_input_token_cost_above_1hr": {"type": "number"},
@ -981,6 +985,27 @@ def test_aaamodel_prices_and_context_window_json_is_valid():
raise AssertionError(error_message)
def test_azure_speech_audio_transcription_config_is_valid_model_cost_metadata():
"""
Regression guard for Azure Speech STT model-cost metadata.
The strict model registry schema should allow the config marker used to
select the Azure Speech transcription transformation.
"""
test_aaamodel_prices_and_context_window_json_is_valid()
prod_json = os.path.join(
os.path.dirname(__file__), "..", "..", "model_prices_and_context_window.json"
)
with open(prod_json, "r") as model_prices_file:
actual_json = json.load(model_prices_file)
assert (
actual_json["azure/speech/azure-stt"]["audio_transcription_config"]
== "azure_speech"
)
def test_max_tokens_consistency():
"""
Test that max_tokens == max_output_tokens for all models.