obi-sdk 0.12.0 → 0.12.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/modular/chunks/index-74e2d1b3.js +6 -0
- package/dist/modular/chunks/index-74e2d1b3.js.map +1 -0
- package/dist/modular/chunks/{obi-widget-6b2916f1.js → obi-widget-b64f0c73.js} +8 -3
- package/dist/modular/chunks/obi-widget-b64f0c73.js.map +1 -0
- package/dist/modular/index.js +1 -1
- package/dist/modular/ui.js +10 -10
- package/dist/obi-sdk.standalone.iife.js +1 -1
- package/dist/obi-sdk.standalone.iife.js.map +1 -1
- package/dist/react.es.js +7 -4
- package/dist/react.es.js.map +1 -1
- package/dist/react.umd.js +1 -1
- package/dist/react.umd.js.map +1 -1
- package/package.json +3 -3
- package/dist/modular/chunks/index-21eeed74.js +0 -6
- package/dist/modular/chunks/index-21eeed74.js.map +0 -1
- package/dist/modular/chunks/obi-widget-6b2916f1.js.map +0 -1
package/dist/react.es.js
CHANGED
|
@@ -16582,10 +16582,10 @@ var O;
|
|
|
16582
16582
|
A.READY = "ready", A.ERROR = "error", A.PAUSED = "paused", A.LOADING = "loading", A.THINKING = "thinking", A.RESEARCHING = "researching", A.AGENT_SPEAKING = "agent_speaking", A.USER_SPEAKING = "user_speaking", A.AWAITING_USER_INPUT = "awaiting_user_input";
|
|
16583
16583
|
})(O || (O = {}));
|
|
16584
16584
|
class KC {
|
|
16585
|
-
constructor({ sessionId: e, apiBaseUrl: t }) {
|
|
16586
|
-
this.currentState = O.READY, this.livekitState = "speaking", this.assistantAudioContext = null, this.userAudioContext = null, this._assistantAudioTimer = null, this._userAudioTimer = null, this.sessionId = e, this.apiBaseUrl = t || NC, this.client = new _g({
|
|
16585
|
+
constructor({ sessionId: e, apiBaseUrl: t, user: n }) {
|
|
16586
|
+
this.currentState = O.READY, this.livekitState = "speaking", this.assistantAudioContext = null, this.userAudioContext = null, this._assistantAudioTimer = null, this._userAudioTimer = null, this.user = void 0, this.sessionId = e, this.apiBaseUrl = t || NC, this.client = new _g({
|
|
16587
16587
|
baseUrl: this.apiBaseUrl
|
|
16588
|
-
}), this.emitter = new Om();
|
|
16588
|
+
}), this.emitter = new Om(), this.user = n;
|
|
16589
16589
|
}
|
|
16590
16590
|
emit(e, t) {
|
|
16591
16591
|
this.emitter.emit(e, t);
|
|
@@ -16680,7 +16680,10 @@ class KC {
|
|
|
16680
16680
|
adaptiveStream: !0,
|
|
16681
16681
|
dynacast: !0
|
|
16682
16682
|
}), this.setupRoomEventListeners();
|
|
16683
|
-
const e = await this.client.getJoinToken(this.sessionId, {
|
|
16683
|
+
const e = await this.client.getJoinToken(this.sessionId, {
|
|
16684
|
+
skipIntro: !0,
|
|
16685
|
+
...this.user && { user: JSON.stringify(this.user) }
|
|
16686
|
+
});
|
|
16684
16687
|
if (await this.room.connect(e.data.url, e.data.token), this.microphoneStream) {
|
|
16685
16688
|
const t = this.microphoneStream.getAudioTracks()[0];
|
|
16686
16689
|
await this.room.localParticipant.publishTrack(t, {
|