Граф коммитов

25 Коммитов

Автор SHA1 Сообщение Дата
Glenn Harper fb04a09bc9
revert initial changes to PCMRecorder and package.json (#766) 2023-11-29 22:30:11 -05:00
Glenn Harper a8ecf1a782
remove all require usage in SDK to allow browser operation (#760) 2023-11-08 15:48:29 -05:00
Glenn Harper 8cb9e719f9
v2 translation hypothesis, conditionally import audioWorkerUrl method using import.meta (#735) 2023-09-25 13:42:19 -04:00
Glenn Harper 6a9273d811
use trusted URL for AudioWorklet (#732) 2023-09-19 12:45:34 -04:00
Glenn Harper b3a5375697
don't check punctuation in service return (#582) 2022-10-04 18:18:24 -07:00
Glenn Harper c8b83859e9
fix recognized callback when LUIS response connectionMessage is empty (#568)
* allow recognized callback to be called when LUIS response connectionMessage is empty

* fix response msg handler to account for bad intents

* Add test for bug
2022-09-28 14:06:46 -07:00
Ryan Hurey fa4c748ad6
Test stability improvements (#558)
* Test stability fixes

* disable audio duration check due to service issus

* Increase translation timeout, format & add try / catch to synthesis test

* Change to a new version of Jest that supports retries. Modify tests to work with new version. Allow 3 retries.

* package-lock update

* Re-install with the same npm version as the ADO agents are using.

* Remove gulp-parent from forced resolution list

* npm audit auto fixes

* Increase error timeouts

* Increase timeouts

* Didn't copy the env change from the package.json to the jest config

* Add logging and increase token timeout.

Co-authored-by: Yulin Li <liyulin@pku.edu.cn>
2022-07-28 15:37:58 -07:00
Ryan Hurey 21c4546092
JavaScript.slice is not inclusive of end (#557)
* Fix off by one error in pull stream tests, improve logging available for debugging audio transmission

* Clean up formatting
2022-07-23 01:21:22 -07:00
Glenn Harper ba8be3e882
Add diagnostics API for logging and console output (#506)
* Initial implementation using logLevel alias for cleaner common imports

* Use LogLevel in tests

* lint bits

* Correct write file logic

* Add tests for Diagnostics

* Correct test name

* revert OCSP test changes
2022-03-31 09:42:42 -07:00
Glenn Harper d4f70a4bb7
Add node-only tests, update file read to accomodate node (#285) 2020-12-10 09:25:34 -08:00
Glenn Harper f01a3f8adc
Add test names to console output during test run (#263) 2020-10-30 13:23:48 -07:00
Ryan Hurey 529d62ce52
Switch SDK to use Native promises. (#198)
* Switch to use native promises inside the SDK, while keeping (most) external interfaces the same.

Visible Changes: (One breaking)
*PullAudioOutputStream.read() has a return type change from an internal Promise to a Native JavaScript Promise.

* ConversationTranslator.dispose()
* SpeakerAudioDestination.write()
* SpeakerAudioDestination.close()
* SpeakerAudioDestination.resume()
* BaseAudioPlayer.stop()
* SpeechSynthesizer.close()
* SpeechRecognizer.close()
* TranslationRecognizer.close()
* IntentRecognizer.close()
* Recognizer.close()
* DialogServiceConnector.connect()
* DialogServiceConnector.disconnect()
* Connection.openConnection()
* Connection.closeConnection()
Now all accept two callbacks as parameters (cb?: () => void, err?: (error: string) => void) to indicate status. These API's had never been fully synchronous and now status can be captured.
2020-07-21 18:16:23 -07:00
Ryan Hurey fc9f3f6d2a
Add a cache for OCSP responses. (#196)
* Extend OCSP certificate verification to include a memory and disk based cache.

The disk cache will by default be located in TMPDIR/<username>/ but can be overridden.

When the cached OCSP response is within 1 day of expiring, or 1/2 way through it's vaility period (whichever is shorter) a background
task is queued to refresh it while the cached value is used.

* More fixes

* Fix error case

* Fix typos
2020-07-02 09:59:35 -07:00
Yulin Li 65d292ddf5
TTS implementation (#161)
initial commit for TTS implementation, with NodeJS support only.
2020-03-26 15:54:34 +08:00
Ryan Hurey 0413695664
Stop Recognizing should wait for pending service messages (#148)
* Commit one

* Only dialog cases failing

* Still working on the dialog connector tests

* Set turn start

* Linter fixes

* Lint errors in tests
2020-02-15 21:55:16 -08:00
Ryan Hurey 1a3f5203f6
Remove the 10 minute limit for browser based files. (#142)
* Read wave file header

* Add 44Khz tests

* Missed two files

* Remove ununsed variable
2020-02-14 12:49:53 -08:00
Ryan Hurey f68dcc6b33
Disable 2 cases while service team investigates behavior change (#120) 2020-01-16 13:36:21 -08:00
Ryan Hurey bc84473d08
Send a wave header based on the AudioFormat specified. (#115) 2020-01-13 16:17:54 -08:00
Ryan Hurey 0d6f7e69da
Remove throttling for the first 5 seconds of audio. (#68)
* Remove throttling for the first 5 seconds of audio. After that throttle at 2x realtime.

* Update translation tests to reflect change in error message from service.
2019-06-12 16:37:33 -07:00
Ryan Hurey 25a5d07f8f
Rhurey/improve.connection.perf (#67)
* Parallize opening of websocket connection with audio startup.

* Simplify recognize

* When an exception occurs, call the error callback and then dispose of the recognizer

* Adjust tests
2019-06-12 14:55:55 -07:00
Ryan Hurey 4c56ae2d5b
Update Stream code & Add AudioWorklet support (#45)
* Push work

* Pull stream work

* On Chrome browsers, use Audio Worklet to capture audio

* Fix bugs merge introduced

* Add script URL code

* CR Feedback

* Disable empty test case
2019-03-27 20:35:25 -07:00
Ryan Hurey e024406230
Rhurey/phrasehints (#34)
* Move intents to use phrase hints.

* Added classes & tests to base layer

* Initial add of PhraseListGrammar

* Add code comments and a couple of tests

* Improve comments
2019-02-12 12:19:27 -08:00
Ryan Hurey 562ba5c315
Return properties collection with service JSON for recognition. (#31) 2019-02-05 10:44:33 -08:00
Ryan Hurey c2b14574d6
Add support for Connection object. (#30)
* Add support for Connection object.

Expose internalData object on base Recognizer class. This is used to allow the fromRecognizer* pattern on the connection object and other future objects that will be conjured from a recognizer.
Seperate the concept of a connection being established from one being configured with context information via the speech.config message.
Support multiple recognize* iterations being done in the same connection. Previously each recognizeOnce / startContinuousRecog call established a new connection.

Add & Update Tests.

* Add additional test

* Remove extra blank like
2019-01-30 15:33:46 -08:00
Microsoft Open Source 384e49ae0f Initial import of sources (#2) 2018-12-17 10:13:23 +01:00