@onereach/step-voice 6.1.7-customvoiceimp.1 → 6.1.7
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/dst/Custom Voice Input.d.ts +0 -2
- package/dst/Custom Voice Input.js +13 -16
- package/dst/Global Command.js +1 -1
- package/dst/Join Conference.js +1 -1
- package/dst/voice.d.ts +0 -1
- package/package.json +1 -1
|
@@ -104,10 +104,19 @@ class CustomVoiceInput extends voice_1.default {
|
|
|
104
104
|
.join(' | ')
|
|
105
105
|
.value();
|
|
106
106
|
// On bargeIn, we should stop playback
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
107
|
+
if (exitExists(exitId)) {
|
|
108
|
+
await this.transcript(call, {
|
|
109
|
+
message: lodash_1.default.replace(this.getExitStepLabel(exitId) ?? '', /^(\d+\. )?(~ )?/, ''),
|
|
110
|
+
voiceProcessResult,
|
|
111
|
+
reportingSettingsKey,
|
|
112
|
+
action: 'Call Recognition',
|
|
113
|
+
actionFromBot: false
|
|
114
|
+
});
|
|
115
|
+
await this.resumeRecording(call, sensitiveData);
|
|
116
|
+
// There might be hooks after this step which we will try to avoid
|
|
117
|
+
return this.exitStep(exitId, this.exitChoiceData('voice', params));
|
|
118
|
+
}
|
|
119
|
+
else if (this.rptsHasMore({ repromptsList }) &&
|
|
111
120
|
(usePromptsTriggers ? isRepromptTrigger(phrases, this.data.promptsTriggers) : true)) {
|
|
112
121
|
await this.transcript(call, {
|
|
113
122
|
message: 'Unrecognized',
|
|
@@ -127,18 +136,6 @@ class CustomVoiceInput extends voice_1.default {
|
|
|
127
136
|
});
|
|
128
137
|
return this.exitFlow();
|
|
129
138
|
}
|
|
130
|
-
else if (exitExists(exitId)) {
|
|
131
|
-
await this.transcript(call, {
|
|
132
|
-
message: lodash_1.default.replace(this.getExitStepLabel(exitId) ?? '', /^(\d+\. )?(~ )?/, ''),
|
|
133
|
-
voiceProcessResult,
|
|
134
|
-
reportingSettingsKey,
|
|
135
|
-
action: 'Call Recognition',
|
|
136
|
-
actionFromBot: false
|
|
137
|
-
});
|
|
138
|
-
await this.resumeRecording(call, sensitiveData);
|
|
139
|
-
// There might be hooks after this step which we will try to avoid
|
|
140
|
-
return this.exitStep(exitId, this.exitChoiceData('voice', params));
|
|
141
|
-
}
|
|
142
139
|
// There's no more reprompts, should move on to unrecognized direction
|
|
143
140
|
await this.transcript(call, {
|
|
144
141
|
message: 'Not Recognized',
|
package/dst/Global Command.js
CHANGED
|
@@ -185,7 +185,7 @@ class GlobalCommand extends voice_1.default {
|
|
|
185
185
|
});
|
|
186
186
|
}
|
|
187
187
|
async hangup(call) {
|
|
188
|
-
if (this.event.params.zombie
|
|
188
|
+
if (this.event.params.zombie) {
|
|
189
189
|
if (this.state.passive) {
|
|
190
190
|
this.log.debug('ignore zombie hangup waiting for full hangup');
|
|
191
191
|
return this.exitFlow();
|
package/dst/Join Conference.js
CHANGED
package/dst/voice.d.ts
CHANGED
|
@@ -53,7 +53,6 @@ export interface CallStartEvent extends VoiceEvent {
|
|
|
53
53
|
}
|
|
54
54
|
export default class VoiceStep<TIn = unknown, TOut = unknown, TParams extends VoiceEvent = VoiceEvent> extends ConvStep<IVoiceCall, TIn & {
|
|
55
55
|
handleCancel?: boolean;
|
|
56
|
-
handleZombie?: boolean;
|
|
57
56
|
}, TOut, TParams> {
|
|
58
57
|
runBefore(): Promise<void>;
|
|
59
58
|
exitStep(exitId: string, data?: any, byThread?: boolean): any;
|