feat: integrate production cockpit AI assistant
This commit is contained in:
@@ -32,8 +32,8 @@ class SpeechStub:
|
||||
},
|
||||
"wake_word": {
|
||||
"enabled": True,
|
||||
"primary": "你好,双十一",
|
||||
"aliases": ["你好,双十一", "你好,双11"],
|
||||
"primary": "你好,小迪",
|
||||
"aliases": ["你好,小迪"],
|
||||
},
|
||||
}
|
||||
|
||||
@@ -62,8 +62,8 @@ class SpeechStub:
|
||||
"utterance_id": utterance_id,
|
||||
"sequence": sequence,
|
||||
"state": "partial",
|
||||
"raw_text": "你好双十一打开空",
|
||||
"text": "你好双十一打开空",
|
||||
"raw_text": "你好小迪打开空",
|
||||
"text": "你好小迪打开空",
|
||||
"live_text": "打开空",
|
||||
"wake_word": {"detected": True, "remainder": "打开空"},
|
||||
"semantic_cleaned": False,
|
||||
@@ -88,7 +88,7 @@ class SpeechStub:
|
||||
)
|
||||
return {
|
||||
"utterance_id": utterance_id,
|
||||
"captured_text": "你好双十一车上有点热",
|
||||
"captured_text": "你好小迪车上有点热",
|
||||
"raw_text": "车上有点热",
|
||||
"assistant_text": "车上有点热。",
|
||||
"text": "车上有点热。",
|
||||
@@ -161,7 +161,7 @@ class TestSpeechLiveWebApi:
|
||||
"final_default": "manual",
|
||||
}
|
||||
assert payload["wake_word"]["enabled"] is True
|
||||
assert payload["wake_word"]["primary"] == "你好,双十一"
|
||||
assert payload["wake_word"]["primary"] == "你好,小迪"
|
||||
|
||||
def test_preview_endpoint_forwards_accumulated_audio_identity_and_sequence(self) -> None:
|
||||
status, payload = self.post_audio(
|
||||
@@ -183,7 +183,7 @@ class TestSpeechLiveWebApi:
|
||||
]
|
||||
assert payload["state"] == "partial"
|
||||
assert payload["sequence"] == 7
|
||||
assert payload["raw_text"] == "你好双十一打开空"
|
||||
assert payload["raw_text"] == "你好小迪打开空"
|
||||
assert payload["live_text"] == "打开空"
|
||||
assert payload["semantic_cleaned"] is False
|
||||
|
||||
|
||||
Reference in New Issue
Block a user