@athenaintel/react 0.5.0 → 0.6.0
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.cjs +672 -393
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +16 -41
- package/dist/index.js +673 -394
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -6,7 +6,6 @@ import { ComponentPropsWithRef } from 'react';
|
|
|
6
6
|
import { FC } from 'react';
|
|
7
7
|
import { ForwardRefExoticComponent } from 'react';
|
|
8
8
|
import { JSX } from 'react/jsx-runtime';
|
|
9
|
-
import { LangChainMessage } from '@assistant-ui/react-langgraph';
|
|
10
9
|
import * as React_2 from 'react';
|
|
11
10
|
import { ReactNode } from 'react';
|
|
12
11
|
import { RefAttributes } from 'react';
|
|
@@ -56,7 +55,7 @@ export declare interface AssetTab {
|
|
|
56
55
|
type: AssetType;
|
|
57
56
|
}
|
|
58
57
|
|
|
59
|
-
export declare type AssetType = 'presentation' | 'spreadsheet' | 'document' | 'unknown';
|
|
58
|
+
export declare type AssetType = 'presentation' | 'spreadsheet' | 'document' | 'notebook' | 'unknown';
|
|
60
59
|
|
|
61
60
|
export declare const AthenaChat: FC<AthenaChatProps>;
|
|
62
61
|
|
|
@@ -145,6 +144,8 @@ export declare interface AthenaProviderProps {
|
|
|
145
144
|
export declare interface AthenaRuntimeConfig {
|
|
146
145
|
/** URL for the chat streaming endpoint. Defaults to Athena production sync server. */
|
|
147
146
|
apiUrl?: string;
|
|
147
|
+
/** URL for the sync server resume endpoint. Derived from apiUrl if not provided. */
|
|
148
|
+
resumeApiUrl?: string;
|
|
148
149
|
/** URL for the Agora backend API. Defaults to Athena production API. */
|
|
149
150
|
backendUrl?: string;
|
|
150
151
|
/** API key for authentication. Used when no auth token is provided. */
|
|
@@ -167,8 +168,6 @@ export declare interface AthenaRuntimeConfig {
|
|
|
167
168
|
systemPrompt?: string;
|
|
168
169
|
/** Thread ID override. Auto-generated if not provided. */
|
|
169
170
|
threadId?: string;
|
|
170
|
-
/** Pre-loaded messages for thread switching. */
|
|
171
|
-
initialMessages?: LangChainMessage[];
|
|
172
171
|
}
|
|
173
172
|
|
|
174
173
|
/**
|
|
@@ -262,16 +261,23 @@ export declare function CollapsibleContent({ ...props }: React.ComponentProps<ty
|
|
|
262
261
|
|
|
263
262
|
export declare function CollapsibleTrigger({ ...props }: React.ComponentProps<typeof Collapsible_2.CollapsibleTrigger>): JSX.Element;
|
|
264
263
|
|
|
264
|
+
export declare function createAssetToolUI(config: {
|
|
265
|
+
icon: React.ElementType;
|
|
266
|
+
assetType: AssetType;
|
|
267
|
+
runningLabel: string;
|
|
268
|
+
doneLabel: string;
|
|
269
|
+
}): ToolCallMessagePartComponent;
|
|
270
|
+
|
|
265
271
|
export declare const CreateDocumentToolUI: ToolCallMessagePartComponent;
|
|
266
272
|
|
|
267
273
|
export declare const CreateEmailDraftToolUI: ToolCallMessagePartComponent;
|
|
268
274
|
|
|
275
|
+
export declare const CreateNotebookToolUI: ToolCallMessagePartComponent;
|
|
276
|
+
|
|
269
277
|
export declare const CreatePresentationToolUI: ToolCallMessagePartComponent;
|
|
270
278
|
|
|
271
279
|
export declare const CreateSheetToolUI: ToolCallMessagePartComponent;
|
|
272
280
|
|
|
273
|
-
export declare function createThreadListStore(config: StoreConfig): UseBoundStore<StoreApi<ThreadListStore>>;
|
|
274
|
-
|
|
275
281
|
export declare const DEFAULT_BACKEND_URL = "https://api.athenaintel.com/api/assistant-ui";
|
|
276
282
|
|
|
277
283
|
export declare const EmailSearchToolUI: ToolCallMessagePartComponent;
|
|
@@ -325,10 +331,14 @@ declare interface MenuItem {
|
|
|
325
331
|
*/
|
|
326
332
|
declare type MenuScope = string;
|
|
327
333
|
|
|
334
|
+
export declare const OpenAssetToolUI: ToolCallMessagePartComponent;
|
|
335
|
+
|
|
328
336
|
export declare const ReadAssetToolUI: ToolCallMessagePartComponent;
|
|
329
337
|
|
|
330
338
|
export declare function resetAssetAutoOpen(): void;
|
|
331
339
|
|
|
340
|
+
export declare const RunPythonCodeToolUI: ToolCallMessagePartComponent;
|
|
341
|
+
|
|
332
342
|
declare interface ScopeRegistry {
|
|
333
343
|
entries: Map<MenuScope, ScopeRegistryEntry>;
|
|
334
344
|
}
|
|
@@ -354,12 +364,6 @@ declare interface SourceResult {
|
|
|
354
364
|
};
|
|
355
365
|
}
|
|
356
366
|
|
|
357
|
-
declare interface StoreConfig {
|
|
358
|
-
backendUrl: string;
|
|
359
|
-
apiKey?: string;
|
|
360
|
-
token?: string | null;
|
|
361
|
-
}
|
|
362
|
-
|
|
363
367
|
export declare const themes: {
|
|
364
368
|
/** Default light theme. Neutral grays with blue accent. */
|
|
365
369
|
readonly light: {
|
|
@@ -500,30 +504,10 @@ export declare function themeToStyleVars(theme: AthenaTheme): Record<string, str
|
|
|
500
504
|
|
|
501
505
|
export declare function ThreadList({ className }: ThreadListProps): JSX.Element;
|
|
502
506
|
|
|
503
|
-
export declare interface ThreadListActions {
|
|
504
|
-
/** Fetch threads from Agora. */
|
|
505
|
-
fetchThreads: () => Promise<void>;
|
|
506
|
-
/** Switch to an existing thread. */
|
|
507
|
-
switchThread: (threadId: string) => void;
|
|
508
|
-
/** Create a new thread and switch to it. */
|
|
509
|
-
newThread: () => Promise<string>;
|
|
510
|
-
/** Archive a thread. If it's active, switch to the most recent thread. */
|
|
511
|
-
archiveThread: (threadId: string) => Promise<void>;
|
|
512
|
-
}
|
|
513
|
-
|
|
514
507
|
export declare interface ThreadListProps {
|
|
515
508
|
className?: string;
|
|
516
509
|
}
|
|
517
510
|
|
|
518
|
-
export declare interface ThreadListState {
|
|
519
|
-
threads: ThreadSummary[];
|
|
520
|
-
activeThreadId: string | null;
|
|
521
|
-
isLoading: boolean;
|
|
522
|
-
error: string | null;
|
|
523
|
-
}
|
|
524
|
-
|
|
525
|
-
export declare type ThreadListStore = ThreadListState & ThreadListActions;
|
|
526
|
-
|
|
527
511
|
/**
|
|
528
512
|
* Agora thread API client.
|
|
529
513
|
* Calls existing REST endpoints for thread CRUD.
|
|
@@ -691,9 +675,6 @@ export declare function TooltipTrigger({ ...props }: React_2.ComponentProps<type
|
|
|
691
675
|
|
|
692
676
|
export declare function tryParseJson(text: string): Record<string, unknown> | null;
|
|
693
677
|
|
|
694
|
-
/** Hook to get just the active thread ID. */
|
|
695
|
-
export declare function useActiveThreadId(): string | null;
|
|
696
|
-
|
|
697
678
|
/**
|
|
698
679
|
* Hook to programmatically append text to the composer.
|
|
699
680
|
*
|
|
@@ -765,12 +746,6 @@ export declare function useMentionSuggestions(tools: MentionTool[]): MentionSugg
|
|
|
765
746
|
*/
|
|
766
747
|
export declare function useParentAuth(): string | null;
|
|
767
748
|
|
|
768
|
-
/** Hook to access thread list state and actions. */
|
|
769
|
-
export declare function useThreadList(): ThreadListState & ThreadListActions;
|
|
770
|
-
|
|
771
|
-
/** Returns true while a thread switch is loading messages. */
|
|
772
|
-
export declare function useThreadLoading(): boolean;
|
|
773
|
-
|
|
774
749
|
export declare type ViewMode = 'tabs' | 'tiled';
|
|
775
750
|
|
|
776
751
|
export declare const WebSearchToolUI: ToolCallMessagePartComponent;
|