@smartspace/chat-ui 1.14.4-dev.e9d1170 → 1.14.4-dev.ede137a
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/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/index.d.ts +222 -134
- package/dist/index.js +1400 -519
- package/dist/index.js.map +1 -1
- package/package.json +4 -1
package/dist/index.d.ts
CHANGED
|
@@ -80,6 +80,104 @@ declare const ChatVariablesForm: React.ForwardRefExoticComponent<ChatVariablesFo
|
|
|
80
80
|
setVariables: (variables: Record<string, unknown>) => void;
|
|
81
81
|
} & React.RefAttributes<ChatVariablesFormRef>>;
|
|
82
82
|
|
|
83
|
+
/**
|
|
84
|
+
* What the backend tells the composer about speech-to-text (dictation).
|
|
85
|
+
* `region` is the Azure region of the Speech resource, e.g. `australiaeast`.
|
|
86
|
+
* The SDK needs the region rather than the account's custom-domain URL: the
|
|
87
|
+
* recognition path only exists on the regional host, and that is what the
|
|
88
|
+
* issued token is scoped to. Absent when speech isn't configured.
|
|
89
|
+
*/
|
|
90
|
+
type SpeechConfig = {
|
|
91
|
+
enabled: boolean;
|
|
92
|
+
region?: string | null;
|
|
93
|
+
/** BCP-47 locale to recognise when the client doesn't ask for one. */
|
|
94
|
+
defaultLocale: string;
|
|
95
|
+
};
|
|
96
|
+
/**
|
|
97
|
+
* A short-lived token from the Speech resource's own token service, scoped to
|
|
98
|
+
* recognition in one region and good for about ten minutes. Handed to the SDK
|
|
99
|
+
* as-is; the backend owns how it is minted.
|
|
100
|
+
*/
|
|
101
|
+
type SpeechToken = {
|
|
102
|
+
token: string;
|
|
103
|
+
/** ISO-8601 instant. */
|
|
104
|
+
expiresOn: string;
|
|
105
|
+
};
|
|
106
|
+
|
|
107
|
+
type DictationState = 'idle' | 'starting' | 'listening';
|
|
108
|
+
type DictationError = 'permission-denied' | 'no-microphone' | 'network'
|
|
109
|
+
/** Worth another go: the install is fine, this attempt wasn't. */
|
|
110
|
+
| 'unavailable-temporarily'
|
|
111
|
+
/** Don't keep asking: this install can't do dictation. */
|
|
112
|
+
| 'unavailable' | 'unknown';
|
|
113
|
+
type UseDictationOptions = {
|
|
114
|
+
/** Azure region from `SpeechConfig`; dictation is unavailable without it. */
|
|
115
|
+
region?: string | null;
|
|
116
|
+
/** BCP-47 recognition locale (server default unless the user chose one). */
|
|
117
|
+
locale: string;
|
|
118
|
+
/** From the ChatService; dictation is unavailable without it. */
|
|
119
|
+
getToken?: () => Promise<SpeechToken>;
|
|
120
|
+
/** A final recognised phrase — insert it into the editor. */
|
|
121
|
+
onPhrase: (text: string) => void;
|
|
122
|
+
/**
|
|
123
|
+
* Provisional text, revised several times a second. Rendered as greyed ghost
|
|
124
|
+
* text at the caret. Deliberately a callback rather than hook state: holding it
|
|
125
|
+
* in state would re-render the whole composer on every partial result.
|
|
126
|
+
*/
|
|
127
|
+
onInterim?: (text: string) => void;
|
|
128
|
+
/**
|
|
129
|
+
* Hard stop, so a forgotten mic can't run for an hour. Keep it under the
|
|
130
|
+
* token's ~10 minute life: the token is never refreshed once the session is
|
|
131
|
+
* running, so a longer cap would end the session on an auth failure.
|
|
132
|
+
*/
|
|
133
|
+
maxDurationMs?: number;
|
|
134
|
+
/** Stop after this long without any speech. */
|
|
135
|
+
idleTimeoutMs?: number;
|
|
136
|
+
};
|
|
137
|
+
/**
|
|
138
|
+
* Streams microphone audio to Azure AI Speech and hands back recognised
|
|
139
|
+
* phrases. Owns the whole session: mic permission + stream, SDK loading,
|
|
140
|
+
* recogniser lifecycle, idle/max timers, and teardown on stop or unmount.
|
|
141
|
+
* Interim (not yet final) text goes to `onInterim` for display only; only final
|
|
142
|
+
* phrases reach `onPhrase`.
|
|
143
|
+
*/
|
|
144
|
+
declare function useDictation({ region, locale, getToken, onPhrase, onInterim, maxDurationMs, idleTimeoutMs, }: UseDictationOptions): {
|
|
145
|
+
supported: boolean;
|
|
146
|
+
available: boolean;
|
|
147
|
+
state: DictationState;
|
|
148
|
+
error: DictationError | null;
|
|
149
|
+
/** Name of the microphone in use, once a session is live. May be ''. */
|
|
150
|
+
deviceLabel: string;
|
|
151
|
+
/** Listening, but the microphone has produced no sound for a while. */
|
|
152
|
+
silent: boolean;
|
|
153
|
+
start: () => Promise<void>;
|
|
154
|
+
stop: () => void;
|
|
155
|
+
toggle: () => void;
|
|
156
|
+
};
|
|
157
|
+
|
|
158
|
+
type DictationButtonProps = {
|
|
159
|
+
state: DictationState;
|
|
160
|
+
error: DictationError | null;
|
|
161
|
+
disabled?: boolean;
|
|
162
|
+
onToggle: () => void;
|
|
163
|
+
/**
|
|
164
|
+
* Microphone in use. Shown while listening because the browser picks the
|
|
165
|
+
* device, not us, and picking the wrong one is otherwise invisible: the
|
|
166
|
+
* session looks perfectly healthy and simply transcribes nothing.
|
|
167
|
+
*/
|
|
168
|
+
deviceLabel?: string;
|
|
169
|
+
/** Icon/button sizing to match the surrounding toolbar. */
|
|
170
|
+
size?: 'sm' | 'md';
|
|
171
|
+
};
|
|
172
|
+
/**
|
|
173
|
+
* The composer's microphone, which carries the dictation state itself rather than
|
|
174
|
+
* relying on text elsewhere: a spinning ring while the session is starting, and a
|
|
175
|
+
* filled stop square while it is listening — the same shape Send takes during a
|
|
176
|
+
* run, because the button's job is the same at that point. The transcript appears
|
|
177
|
+
* in the composer at the caret, so nothing is reported in two places.
|
|
178
|
+
*/
|
|
179
|
+
declare function DictationButton({ state, error, disabled, onToggle, deviceLabel, size, }: DictationButtonProps): react_jsx_runtime.JSX.Element;
|
|
180
|
+
|
|
83
181
|
type MentionUserLike = {
|
|
84
182
|
id: string;
|
|
85
183
|
displayName: string;
|
|
@@ -97,6 +195,19 @@ type MarkdownEditorHandle = {
|
|
|
97
195
|
* Callers that need the freshest text (e.g. sending on Enter) should read from here.
|
|
98
196
|
*/
|
|
99
197
|
getMarkdown: () => string;
|
|
198
|
+
/**
|
|
199
|
+
* Inserts plain text at the caret (dictation, snippets), replacing any
|
|
200
|
+
* selection. Prepends a space when the caret directly follows a
|
|
201
|
+
* non-whitespace character so successive inserts read as prose. No-op when
|
|
202
|
+
* the editor isn't editable.
|
|
203
|
+
*/
|
|
204
|
+
insertText: (text: string) => void;
|
|
205
|
+
/**
|
|
206
|
+
* Shows provisional dictation text greyed at the caret. Display-only — it never
|
|
207
|
+
* enters the document, so it cannot be serialised, undone, or sent. Pass '' to
|
|
208
|
+
* clear; inserting the final text via `insertText` clears it too.
|
|
209
|
+
*/
|
|
210
|
+
setDictationGhost: (text: string) => void;
|
|
100
211
|
/**
|
|
101
212
|
* Returns mention users currently present in the editor document.
|
|
102
213
|
* Useful for building API payloads (e.g. comments.mentionedUsers).
|
|
@@ -376,6 +487,19 @@ interface ChatService {
|
|
|
376
487
|
* compiling — the composer only shows a Stop button when it is provided.
|
|
377
488
|
*/
|
|
378
489
|
cancelFlowRun?(flowRunId: string): Promise<void>;
|
|
490
|
+
/**
|
|
491
|
+
* Speech-to-text (composer dictation). Both are optional so existing
|
|
492
|
+
* service implementations keep compiling — the composer renders a
|
|
493
|
+
* microphone only when both are provided AND the config says enabled.
|
|
494
|
+
* `getSpeechConfig` is read once per session. `getSpeechToken` is called
|
|
495
|
+
* when a dictation session starts (in parallel with the mic permission
|
|
496
|
+
* prompt — and again if that token aged out while the prompt sat open). The
|
|
497
|
+
* token is handed to the SDK as-is and never refreshed mid-session, so a
|
|
498
|
+
* session is capped to stay inside its life. No caching wanted: a stale
|
|
499
|
+
* token cannot be renewed.
|
|
500
|
+
*/
|
|
501
|
+
getSpeechConfig?(): Promise<SpeechConfig>;
|
|
502
|
+
getSpeechToken?(): Promise<SpeechToken>;
|
|
379
503
|
}
|
|
380
504
|
|
|
381
505
|
type ChatIdentity = {
|
|
@@ -422,6 +546,7 @@ declare const messagesResponseSchema: z.ZodObject<{
|
|
|
422
546
|
data: z.ZodOptional<z.ZodNullable<z.ZodAny>>;
|
|
423
547
|
errorCode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
424
548
|
message: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
549
|
+
traceId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
425
550
|
}, z.core.$strip>>;
|
|
426
551
|
hasComments: z.ZodBoolean;
|
|
427
552
|
id: z.ZodString;
|
|
@@ -433,13 +558,11 @@ declare const messagesResponseSchema: z.ZodObject<{
|
|
|
433
558
|
createdByUserId: z.ZodString;
|
|
434
559
|
id: z.ZodString;
|
|
435
560
|
name: z.ZodString;
|
|
436
|
-
type: z.
|
|
437
|
-
Input: "Input";
|
|
438
|
-
Output: "Output";
|
|
439
|
-
}>;
|
|
561
|
+
type: z.ZodString;
|
|
440
562
|
value: z.ZodOptional<z.ZodNullable<z.ZodAny>>;
|
|
441
563
|
}, z.core.$strip>>;
|
|
442
564
|
}, z.core.$strip>>;
|
|
565
|
+
scoped: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
443
566
|
total: z.ZodNumber;
|
|
444
567
|
}, z.core.$strip>;
|
|
445
568
|
type MessagesResponseDto = z.infer<typeof messagesResponseSchema>;
|
|
@@ -451,6 +574,8 @@ type MessageErrorDto = NonNullable<MessageDto['errors']>[number] & {
|
|
|
451
574
|
};
|
|
452
575
|
type MessageError = NonNullable<Message['errors']>[number];
|
|
453
576
|
declare function mapMessageValueDtoToModel(dto: MessageValueDto): MessageValue;
|
|
577
|
+
/** `type` is an extensible enum; a value this UI cannot place is dropped. */
|
|
578
|
+
declare const mapMessageValuesDtoToModels: (dtos: MessageValueDto[]) => MessageValue[];
|
|
454
579
|
declare function mapMessageErrorDtoToModel(dto: MessageErrorDto): MessageError;
|
|
455
580
|
declare function mapMessageDtoToModel(dto: MessageDto): Message;
|
|
456
581
|
declare function mapMessagesDtoToModels(dto: MessageDto[]): Message[];
|
|
@@ -472,7 +597,7 @@ declare function applyDeltaToMessage(target: Message, delta: {
|
|
|
472
597
|
/**
|
|
473
598
|
* User-facing text for message errors.
|
|
474
599
|
*
|
|
475
|
-
* The backend attaches a stable machine-readable category to
|
|
600
|
+
* The backend attaches a stable machine-readable category to failures
|
|
476
601
|
* (`errorCode`, e.g. "llm.rate_limit") alongside the numeric HTTP `code`.
|
|
477
602
|
* Prefer the category — it distinguishes causes the HTTP code can't (a 400
|
|
478
603
|
* can be a content filter, a context-window blowout, or a malformed
|
|
@@ -482,8 +607,16 @@ declare function applyDeltaToMessage(target: Message, delta: {
|
|
|
482
607
|
type MessageErrorLike = number | {
|
|
483
608
|
code: number;
|
|
484
609
|
errorCode?: string | null;
|
|
610
|
+
message?: string | null;
|
|
485
611
|
};
|
|
486
612
|
declare const getMessageErrorText: (error: MessageErrorLike) => string;
|
|
613
|
+
/**
|
|
614
|
+
* The provider detail behind an error, shown in an optional "Show details"
|
|
615
|
+
* disclosure under the friendly bubble from {@link getMessageErrorText}.
|
|
616
|
+
* Returns null when there's nothing to add (a bare HTTP code, or no message
|
|
617
|
+
* on the error at all).
|
|
618
|
+
*/
|
|
619
|
+
declare const getMessageErrorDetail: (error: MessageErrorLike) => string | null;
|
|
487
620
|
|
|
488
621
|
/**
|
|
489
622
|
* Structured transient statuses carried on a message's `status` value.
|
|
@@ -552,6 +685,7 @@ declare const threadsListResponseSchema: z.ZodObject<{
|
|
|
552
685
|
totalMessages: z.ZodNumber;
|
|
553
686
|
workSpaceId: z.ZodString;
|
|
554
687
|
}, z.core.$strip>>;
|
|
688
|
+
scoped: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
555
689
|
total: z.ZodNumber;
|
|
556
690
|
}, z.core.$strip>;
|
|
557
691
|
declare const threadResponseSchema: z.ZodObject<{
|
|
@@ -642,11 +776,7 @@ declare const workspaceResponseSchema: z.ZodObject<{
|
|
|
642
776
|
schema: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
643
777
|
}, z.core.$strip>>>>;
|
|
644
778
|
variables: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
645
|
-
access: z.
|
|
646
|
-
None: "None";
|
|
647
|
-
Read: "Read";
|
|
648
|
-
Write: "Write";
|
|
649
|
-
}>;
|
|
779
|
+
access: z.ZodString;
|
|
650
780
|
schema: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
651
781
|
}, z.core.$strip>>>>;
|
|
652
782
|
}, z.core.$strip>>;
|
|
@@ -666,12 +796,10 @@ declare const workspaceResponseSchema: z.ZodObject<{
|
|
|
666
796
|
path: z.ZodString;
|
|
667
797
|
}, z.core.$strip>;
|
|
668
798
|
flowId: z.ZodString;
|
|
799
|
+
honourSourceDeletes: z.ZodBoolean;
|
|
669
800
|
id: z.ZodString;
|
|
670
801
|
inputName: z.ZodString;
|
|
671
|
-
type: z.
|
|
672
|
-
Periodic: "Periodic";
|
|
673
|
-
Container: "Container";
|
|
674
|
-
}>;
|
|
802
|
+
type: z.ZodString;
|
|
675
803
|
}, z.core.$strip>>;
|
|
676
804
|
}, z.core.$strip>>;
|
|
677
805
|
id: z.ZodString;
|
|
@@ -716,13 +844,7 @@ declare const workspaceResponseSchema: z.ZodObject<{
|
|
|
716
844
|
providerDeploymentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
717
845
|
providerId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
718
846
|
region: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
719
|
-
status: z.
|
|
720
|
-
Deploying: "Deploying";
|
|
721
|
-
Ready: "Ready";
|
|
722
|
-
Failed: "Failed";
|
|
723
|
-
Deleting: "Deleting";
|
|
724
|
-
Deleted: "Deleted";
|
|
725
|
-
}>;
|
|
847
|
+
status: z.ZodString;
|
|
726
848
|
statusMessage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
727
849
|
statusUpdatedAt: z.ZodOptional<z.ZodNullable<z.ZodISODateTime>>;
|
|
728
850
|
steps: z.ZodArray<z.ZodObject<{
|
|
@@ -730,68 +852,52 @@ declare const workspaceResponseSchema: z.ZodObject<{
|
|
|
730
852
|
id: z.ZodString;
|
|
731
853
|
index: z.ZodNumber;
|
|
732
854
|
message: z.ZodString;
|
|
733
|
-
name: z.
|
|
734
|
-
DeployVNet: "DeployVNet";
|
|
735
|
-
DeployVM: "DeployVM";
|
|
736
|
-
InstallDependencies: "InstallDependencies";
|
|
737
|
-
DownloadModel: "DownloadModel";
|
|
738
|
-
TestModel: "TestModel";
|
|
739
|
-
}>;
|
|
855
|
+
name: z.ZodString;
|
|
740
856
|
progress: z.ZodNumber;
|
|
741
857
|
startedAt: z.ZodOptional<z.ZodNullable<z.ZodISODateTime>>;
|
|
742
858
|
}, z.core.$strip>>;
|
|
743
859
|
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
744
|
-
virtualMachineServerType: z.ZodOptional<z.
|
|
745
|
-
TextGenerationInference: "TextGenerationInference";
|
|
746
|
-
VLlm: "VLlm";
|
|
747
|
-
}>>;
|
|
860
|
+
virtualMachineServerType: z.ZodOptional<z.ZodString>;
|
|
748
861
|
virtualMachineUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
749
862
|
vmSize: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
750
863
|
}, z.core.$strip>>;
|
|
751
864
|
displayName: z.ZodString;
|
|
752
865
|
id: z.ZodString;
|
|
753
|
-
modelDeploymentProviderType: z.ZodOptional<z.
|
|
754
|
-
|
|
755
|
-
AzureOpenAi: "AzureOpenAi";
|
|
756
|
-
HuggingFace: "HuggingFace";
|
|
757
|
-
Cohere: "Cohere";
|
|
758
|
-
Anthropic: "Anthropic";
|
|
759
|
-
Gemini: "Gemini";
|
|
760
|
-
VertexAi: "VertexAi";
|
|
761
|
-
AzureFoundry: "AzureFoundry";
|
|
762
|
-
}>>;
|
|
763
|
-
modelPublisher: z.ZodOptional<z.ZodEnum<{
|
|
764
|
-
OpenAi: "OpenAi";
|
|
765
|
-
HuggingFace: "HuggingFace";
|
|
766
|
-
Cohere: "Cohere";
|
|
767
|
-
Anthropic: "Anthropic";
|
|
768
|
-
Google: "Google";
|
|
769
|
-
Meta: "Meta";
|
|
770
|
-
Mistral: "Mistral";
|
|
771
|
-
Microsoft: "Microsoft";
|
|
772
|
-
DeepSeek: "DeepSeek";
|
|
773
|
-
XAi: "XAi";
|
|
774
|
-
Amazon: "Amazon";
|
|
775
|
-
Qwen: "Qwen";
|
|
776
|
-
Other: "Other";
|
|
777
|
-
}>>;
|
|
866
|
+
modelDeploymentProviderType: z.ZodOptional<z.ZodString>;
|
|
867
|
+
modelPublisher: z.ZodOptional<z.ZodString>;
|
|
778
868
|
name: z.ZodString;
|
|
779
|
-
properties: z.ZodArray<z.ZodObject<{
|
|
869
|
+
properties: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
870
|
+
defaultValue: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
871
|
+
maxValue: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
872
|
+
minValue: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
780
873
|
name: z.ZodString;
|
|
874
|
+
step: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
781
875
|
type: z.ZodEnum<{
|
|
782
876
|
Boolean: "Boolean";
|
|
877
|
+
}>;
|
|
878
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
879
|
+
defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
880
|
+
maxValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
881
|
+
minValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
882
|
+
name: z.ZodString;
|
|
883
|
+
step: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
884
|
+
type: z.ZodEnum<{
|
|
783
885
|
Number: "Number";
|
|
886
|
+
}>;
|
|
887
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
888
|
+
defaultValue: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
889
|
+
maxValue: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
890
|
+
minValue: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
891
|
+
name: z.ZodString;
|
|
892
|
+
step: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
893
|
+
type: z.ZodEnum<{
|
|
784
894
|
String: "String";
|
|
785
895
|
}>;
|
|
786
|
-
}, z.core.$strip>>;
|
|
896
|
+
}, z.core.$strip>]>>;
|
|
787
897
|
}, z.core.$strip>;
|
|
788
898
|
prePrompt: z.ZodString;
|
|
789
899
|
presencePenalty: z.ZodNumber;
|
|
790
|
-
role: z.
|
|
791
|
-
Document: "Document";
|
|
792
|
-
Agent: "Agent";
|
|
793
|
-
Analyzer: "Analyzer";
|
|
794
|
-
}>;
|
|
900
|
+
role: z.ZodString;
|
|
795
901
|
temperature: z.ZodNumber;
|
|
796
902
|
topP: z.ZodNumber;
|
|
797
903
|
}, z.core.$strip>>;
|
|
@@ -805,11 +911,7 @@ declare const workspaceResponseSchema: z.ZodObject<{
|
|
|
805
911
|
supportsFiles: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
806
912
|
tags: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>;
|
|
807
913
|
variables: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
808
|
-
access: z.
|
|
809
|
-
None: "None";
|
|
810
|
-
Read: "Read";
|
|
811
|
-
Write: "Write";
|
|
812
|
-
}>;
|
|
914
|
+
access: z.ZodString;
|
|
813
915
|
schema: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
814
916
|
}, z.core.$strip>>;
|
|
815
917
|
}, z.core.$strip>;
|
|
@@ -884,11 +986,7 @@ declare const workspacesListResponseSchema: z.ZodObject<{
|
|
|
884
986
|
schema: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
885
987
|
}, z.core.$strip>>>>;
|
|
886
988
|
variables: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
887
|
-
access: z.
|
|
888
|
-
None: "None";
|
|
889
|
-
Read: "Read";
|
|
890
|
-
Write: "Write";
|
|
891
|
-
}>;
|
|
989
|
+
access: z.ZodString;
|
|
892
990
|
schema: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
893
991
|
}, z.core.$strip>>>>;
|
|
894
992
|
}, z.core.$strip>>;
|
|
@@ -908,12 +1006,10 @@ declare const workspacesListResponseSchema: z.ZodObject<{
|
|
|
908
1006
|
path: z.ZodString;
|
|
909
1007
|
}, z.core.$strip>;
|
|
910
1008
|
flowId: z.ZodString;
|
|
1009
|
+
honourSourceDeletes: z.ZodBoolean;
|
|
911
1010
|
id: z.ZodString;
|
|
912
1011
|
inputName: z.ZodString;
|
|
913
|
-
type: z.
|
|
914
|
-
Periodic: "Periodic";
|
|
915
|
-
Container: "Container";
|
|
916
|
-
}>;
|
|
1012
|
+
type: z.ZodString;
|
|
917
1013
|
}, z.core.$strip>>;
|
|
918
1014
|
}, z.core.$strip>>;
|
|
919
1015
|
id: z.ZodString;
|
|
@@ -958,13 +1054,7 @@ declare const workspacesListResponseSchema: z.ZodObject<{
|
|
|
958
1054
|
providerDeploymentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
959
1055
|
providerId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
960
1056
|
region: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
961
|
-
status: z.
|
|
962
|
-
Deploying: "Deploying";
|
|
963
|
-
Ready: "Ready";
|
|
964
|
-
Failed: "Failed";
|
|
965
|
-
Deleting: "Deleting";
|
|
966
|
-
Deleted: "Deleted";
|
|
967
|
-
}>;
|
|
1057
|
+
status: z.ZodString;
|
|
968
1058
|
statusMessage: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
969
1059
|
statusUpdatedAt: z.ZodOptional<z.ZodNullable<z.ZodISODateTime>>;
|
|
970
1060
|
steps: z.ZodArray<z.ZodObject<{
|
|
@@ -972,68 +1062,52 @@ declare const workspacesListResponseSchema: z.ZodObject<{
|
|
|
972
1062
|
id: z.ZodString;
|
|
973
1063
|
index: z.ZodNumber;
|
|
974
1064
|
message: z.ZodString;
|
|
975
|
-
name: z.
|
|
976
|
-
DeployVNet: "DeployVNet";
|
|
977
|
-
DeployVM: "DeployVM";
|
|
978
|
-
InstallDependencies: "InstallDependencies";
|
|
979
|
-
DownloadModel: "DownloadModel";
|
|
980
|
-
TestModel: "TestModel";
|
|
981
|
-
}>;
|
|
1065
|
+
name: z.ZodString;
|
|
982
1066
|
progress: z.ZodNumber;
|
|
983
1067
|
startedAt: z.ZodOptional<z.ZodNullable<z.ZodISODateTime>>;
|
|
984
1068
|
}, z.core.$strip>>;
|
|
985
1069
|
url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
986
|
-
virtualMachineServerType: z.ZodOptional<z.
|
|
987
|
-
TextGenerationInference: "TextGenerationInference";
|
|
988
|
-
VLlm: "VLlm";
|
|
989
|
-
}>>;
|
|
1070
|
+
virtualMachineServerType: z.ZodOptional<z.ZodString>;
|
|
990
1071
|
virtualMachineUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
991
1072
|
vmSize: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
992
1073
|
}, z.core.$strip>>;
|
|
993
1074
|
displayName: z.ZodString;
|
|
994
1075
|
id: z.ZodString;
|
|
995
|
-
modelDeploymentProviderType: z.ZodOptional<z.
|
|
996
|
-
|
|
997
|
-
AzureOpenAi: "AzureOpenAi";
|
|
998
|
-
HuggingFace: "HuggingFace";
|
|
999
|
-
Cohere: "Cohere";
|
|
1000
|
-
Anthropic: "Anthropic";
|
|
1001
|
-
Gemini: "Gemini";
|
|
1002
|
-
VertexAi: "VertexAi";
|
|
1003
|
-
AzureFoundry: "AzureFoundry";
|
|
1004
|
-
}>>;
|
|
1005
|
-
modelPublisher: z.ZodOptional<z.ZodEnum<{
|
|
1006
|
-
OpenAi: "OpenAi";
|
|
1007
|
-
HuggingFace: "HuggingFace";
|
|
1008
|
-
Cohere: "Cohere";
|
|
1009
|
-
Anthropic: "Anthropic";
|
|
1010
|
-
Google: "Google";
|
|
1011
|
-
Meta: "Meta";
|
|
1012
|
-
Mistral: "Mistral";
|
|
1013
|
-
Microsoft: "Microsoft";
|
|
1014
|
-
DeepSeek: "DeepSeek";
|
|
1015
|
-
XAi: "XAi";
|
|
1016
|
-
Amazon: "Amazon";
|
|
1017
|
-
Qwen: "Qwen";
|
|
1018
|
-
Other: "Other";
|
|
1019
|
-
}>>;
|
|
1076
|
+
modelDeploymentProviderType: z.ZodOptional<z.ZodString>;
|
|
1077
|
+
modelPublisher: z.ZodOptional<z.ZodString>;
|
|
1020
1078
|
name: z.ZodString;
|
|
1021
|
-
properties: z.ZodArray<z.ZodObject<{
|
|
1079
|
+
properties: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
1080
|
+
defaultValue: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
1081
|
+
maxValue: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
1082
|
+
minValue: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
1022
1083
|
name: z.ZodString;
|
|
1084
|
+
step: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
1023
1085
|
type: z.ZodEnum<{
|
|
1024
1086
|
Boolean: "Boolean";
|
|
1087
|
+
}>;
|
|
1088
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1089
|
+
defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1090
|
+
maxValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1091
|
+
minValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1092
|
+
name: z.ZodString;
|
|
1093
|
+
step: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1094
|
+
type: z.ZodEnum<{
|
|
1025
1095
|
Number: "Number";
|
|
1096
|
+
}>;
|
|
1097
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1098
|
+
defaultValue: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1099
|
+
maxValue: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1100
|
+
minValue: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1101
|
+
name: z.ZodString;
|
|
1102
|
+
step: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1103
|
+
type: z.ZodEnum<{
|
|
1026
1104
|
String: "String";
|
|
1027
1105
|
}>;
|
|
1028
|
-
}, z.core.$strip>>;
|
|
1106
|
+
}, z.core.$strip>]>>;
|
|
1029
1107
|
}, z.core.$strip>;
|
|
1030
1108
|
prePrompt: z.ZodString;
|
|
1031
1109
|
presencePenalty: z.ZodNumber;
|
|
1032
|
-
role: z.
|
|
1033
|
-
Document: "Document";
|
|
1034
|
-
Agent: "Agent";
|
|
1035
|
-
Analyzer: "Analyzer";
|
|
1036
|
-
}>;
|
|
1110
|
+
role: z.ZodString;
|
|
1037
1111
|
temperature: z.ZodNumber;
|
|
1038
1112
|
topP: z.ZodNumber;
|
|
1039
1113
|
}, z.core.$strip>>;
|
|
@@ -1047,14 +1121,11 @@ declare const workspacesListResponseSchema: z.ZodObject<{
|
|
|
1047
1121
|
supportsFiles: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
1048
1122
|
tags: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>;
|
|
1049
1123
|
variables: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
1050
|
-
access: z.
|
|
1051
|
-
None: "None";
|
|
1052
|
-
Read: "Read";
|
|
1053
|
-
Write: "Write";
|
|
1054
|
-
}>;
|
|
1124
|
+
access: z.ZodString;
|
|
1055
1125
|
schema: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
1056
1126
|
}, z.core.$strip>>;
|
|
1057
1127
|
}, z.core.$strip>>;
|
|
1128
|
+
scoped: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
1058
1129
|
total: z.ZodNumber;
|
|
1059
1130
|
}, z.core.$strip>;
|
|
1060
1131
|
type WorkspaceDto = z.infer<typeof workspaceResponseSchema>;
|
|
@@ -1260,6 +1331,11 @@ declare const modelsKeys: {
|
|
|
1260
1331
|
}];
|
|
1261
1332
|
};
|
|
1262
1333
|
|
|
1334
|
+
declare const speechKeys: {
|
|
1335
|
+
all: readonly ["speech"];
|
|
1336
|
+
config: () => readonly ["speech", "config"];
|
|
1337
|
+
};
|
|
1338
|
+
|
|
1263
1339
|
declare const messagesListOptions: (service: ChatService, threadId: string, opts?: {
|
|
1264
1340
|
take?: number;
|
|
1265
1341
|
skip?: number;
|
|
@@ -1422,4 +1498,16 @@ declare function useModels({ search, take, skip, }?: {
|
|
|
1422
1498
|
total: number;
|
|
1423
1499
|
}, Error>;
|
|
1424
1500
|
|
|
1425
|
-
|
|
1501
|
+
/**
|
|
1502
|
+
* Whether dictation is available on this install and how to connect. Read once
|
|
1503
|
+
* per app session — it only changes with a deploy — and disabled entirely for
|
|
1504
|
+
* services that don't implement speech, in which case the composer renders no
|
|
1505
|
+
* microphone.
|
|
1506
|
+
*
|
|
1507
|
+
* A definitive answer (including a 404 from an older backend) is cached for the
|
|
1508
|
+
* session; a transient failure is retried, because otherwise one blip on load
|
|
1509
|
+
* would silently disable the mic until the page is reloaded.
|
|
1510
|
+
*/
|
|
1511
|
+
declare function useSpeechConfig(): _tanstack_react_query.UseQueryResult<SpeechConfig, Error>;
|
|
1512
|
+
|
|
1513
|
+
export { type ChatContextIds, type ChatIdentity, ChatProvider, type ChatProviderProps, type ChatService, ChatVariablesForm, DRAFT_THREAD_PREFIX, DateFromApi, DictationButton, type DictationButtonProps, type DictationError, type DictationState, type FileInfo$1 as FileInfo, type FileScope, type FlowRunVariables, MarkdownEditor, type MarkdownEditorHandle, type MentionUser, type Message, MessageComposer, type MessageComposerProps, type MessageContentItem, type MessageError, type MessageErrorLike, MessageList, type MessageListProps, MessageListSkeleton, MessageMarkdown, type MessageThread, type MessageValue, MessageValueType, type Model, type ModelProperty, NEW_THREAD_ID, type RetryStatus, type SpeechConfig, type SpeechToken, THREAD_LIST_PAGE_SIZE, type ThreadsResponse, type UseDictationOptions, type Variables, type Workspace, applyDeltaToMessage, applyThreadToCache, createDraftThreadId, createThreadId, downloadFileBlobOptions, filesKeys, flowRunsKeys, getMessageErrorDetail, getMessageErrorText, getModelIcon, getRetryStatusText, getThreadPlaceholderFromListCache, getUserPhotoUrl, invalidateWorkspaceThreadLists, isDraftThreadId, mapFileInfoDtoToModel, mapMentionUserDtoToModel, mapMessageDtoToModel, mapMessageErrorDtoToModel, mapMessageValueDtoToModel, mapMessageValuesDtoToModels, mapMessagesDtoToModels, mapSignalRThreadSummaryToModel, mapThreadDtoToModel, mapThreadsResponseDtoToModel, mapWorkspaceDtoToModel, mapWorkspacesDtoToModels, markDraftThreadId, messagesKeys, messagesListOptions, messagesMutationsKeys, modelsKeys, parseDateTime, parseDateTimeHuman, parseRetryStatus, randomUUID, setThreadOptimisticRunning, setThreadRunningInLists, speechKeys, taggableUsersOptions, threadDetailOptions, threadsKeys, unmarkDraftThreadId, useAddInputToMessage, useChatContext, useChatIdentity, useChatService, useDictation, useDownloadFileBlobQuery, useFileMutations, useFlowRunVariables, useIsDraftThreadId, useMessages, useModels, useSendMessage, useSpeechConfig, useTaggableWorkspaceUsers, useThread, useThreadIsRunning, useUpdateFlowRunVariable, useWorkspace, utcDate, workspaceDetailOptions, workspaceKeys };
|