This commit is contained in:
@@ -1,2 +1,2 @@
|
|||||||
DASHSCOPE_API_KEY=sk-a294f382488d46a1aa0d7cd8e750729b、
|
DASHSCOPE_API_KEY=sk-a294f382488d46a1aa0d7cd8e750729b
|
||||||
volcengine_API_KEY=db1f8b60-0ffc-473c-98da-40daa3a95df8
|
volcengine_API_KEY=db1f8b60-0ffc-473c-98da-40daa3a95df8
|
||||||
@@ -462,6 +462,10 @@ class MyRecognitionCallback(RecognitionCallback):
|
|||||||
except Exception as e:
|
except Exception as e:
|
||||||
print(f"Failed to send final ASR result: {e}")
|
print(f"Failed to send final ASR result: {e}")
|
||||||
|
|
||||||
|
def on_error(self, result: RecognitionResult) -> None:
|
||||||
|
print(f"ASR Error: {result}")
|
||||||
|
|
||||||
|
|
||||||
def on_event(self, result: RecognitionResult) -> None:
|
def on_event(self, result: RecognitionResult) -> None:
|
||||||
if result.get_sentence():
|
if result.get_sentence():
|
||||||
text = result.get_sentence()['text']
|
text = result.get_sentence()['text']
|
||||||
|
|||||||
Reference in New Issue
Block a user