@newheap/platform-ai-chat 0.4.0 → 0.5.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/fesm2022/newheap-platform-ai-chat.mjs +174 -17
- package/fesm2022/newheap-platform-ai-chat.mjs.map +1 -1
- package/i18n/en.json +12 -1
- package/i18n/nl.json +12 -1
- package/index.d.ts +37 -4
- package/package.json +1 -1
package/i18n/en.json
CHANGED
|
@@ -49,7 +49,8 @@
|
|
|
49
49
|
"assistant": "Assistant",
|
|
50
50
|
"tool": "Tool",
|
|
51
51
|
"working": "The assistant is working",
|
|
52
|
-
"loading": "Loading conversation"
|
|
52
|
+
"loading": "Loading conversation",
|
|
53
|
+
"elapsed": "{{seconds}}s"
|
|
53
54
|
},
|
|
54
55
|
"composer": {
|
|
55
56
|
"label": "Message",
|
|
@@ -80,6 +81,16 @@
|
|
|
80
81
|
"rejected": "Rejected"
|
|
81
82
|
}
|
|
82
83
|
},
|
|
84
|
+
"tool-group": {
|
|
85
|
+
"running": "Calling {{name}}…",
|
|
86
|
+
"awaiting-approval": "Waiting for approval: {{name}}",
|
|
87
|
+
"used-one": "Used 1 tool",
|
|
88
|
+
"used-many": "Used {{count}} tools",
|
|
89
|
+
"progress": "{{finished}} of {{total}} done",
|
|
90
|
+
"failed": "{{count}} failed",
|
|
91
|
+
"show-calls": "Show tool calls",
|
|
92
|
+
"hide-calls": "Hide tool calls"
|
|
93
|
+
},
|
|
83
94
|
"approval": {
|
|
84
95
|
"title": "Approval required",
|
|
85
96
|
"fallback-summary": "Review this action before it runs.",
|
package/i18n/nl.json
CHANGED
|
@@ -49,7 +49,8 @@
|
|
|
49
49
|
"assistant": "Assistent",
|
|
50
50
|
"tool": "Tool",
|
|
51
51
|
"working": "De assistent is bezig",
|
|
52
|
-
"loading": "Gesprek laden"
|
|
52
|
+
"loading": "Gesprek laden",
|
|
53
|
+
"elapsed": "{{seconds}} s"
|
|
53
54
|
},
|
|
54
55
|
"composer": {
|
|
55
56
|
"label": "Bericht",
|
|
@@ -80,6 +81,16 @@
|
|
|
80
81
|
"rejected": "Afgewezen"
|
|
81
82
|
}
|
|
82
83
|
},
|
|
84
|
+
"tool-group": {
|
|
85
|
+
"running": "Roept {{name}} aan…",
|
|
86
|
+
"awaiting-approval": "Wacht op goedkeuring: {{name}}",
|
|
87
|
+
"used-one": "1 tool gebruikt",
|
|
88
|
+
"used-many": "{{count}} tools gebruikt",
|
|
89
|
+
"progress": "{{finished}} van {{total}} klaar",
|
|
90
|
+
"failed": "{{count}} mislukt",
|
|
91
|
+
"show-calls": "Tool-aanroepen tonen",
|
|
92
|
+
"hide-calls": "Tool-aanroepen verbergen"
|
|
93
|
+
},
|
|
83
94
|
"approval": {
|
|
84
95
|
"title": "Goedkeuring nodig",
|
|
85
96
|
"fallback-summary": "Controleer deze actie voordat ze wordt uitgevoerd.",
|
package/index.d.ts
CHANGED
|
@@ -805,8 +805,9 @@ declare class NhAssistantConversationListComponent {
|
|
|
805
805
|
declare const NH_ASSISTANT_VIRTUAL_SCROLL_THRESHOLD = 200;
|
|
806
806
|
/**
|
|
807
807
|
* The messages of a conversation as a live log. Assistant text renders as sanitized
|
|
808
|
-
* Markdown, tool calls
|
|
809
|
-
*
|
|
808
|
+
* Markdown, consecutive tool calls as one collapsible group that counts along, and
|
|
809
|
+
* approvals as cards. While a turn runs without visible progress, a working indicator
|
|
810
|
+
* shows the elapsed time. The thread follows new content while the user is at the bottom.
|
|
810
811
|
*/
|
|
811
812
|
declare class NhAssistantThreadComponent {
|
|
812
813
|
private readonly injector;
|
|
@@ -817,7 +818,16 @@ declare class NhAssistantThreadComponent {
|
|
|
817
818
|
readonly approvalDecision: _angular_core.OutputEmitterRef<ApprovalDecision>;
|
|
818
819
|
readonly virtualThreshold = 200;
|
|
819
820
|
readonly virtual: _angular_core.Signal<boolean>;
|
|
821
|
+
/**
|
|
822
|
+
* True while the turn runs and nothing else shows progress: before the first part and
|
|
823
|
+
* between tool calls while the model decides what to do next. Streaming text and a
|
|
824
|
+
* running tool group show their own progress; an approval waits for the user.
|
|
825
|
+
*/
|
|
820
826
|
readonly working: _angular_core.Signal<boolean>;
|
|
827
|
+
/** Whole seconds since the running turn started. */
|
|
828
|
+
readonly elapsedSeconds: _angular_core.Signal<number>;
|
|
829
|
+
private readonly turnStartedAt;
|
|
830
|
+
private readonly now;
|
|
821
831
|
private readonly scroller;
|
|
822
832
|
private readonly viewport;
|
|
823
833
|
constructor();
|
|
@@ -882,6 +892,29 @@ declare class NhAssistantToolCallCardComponent {
|
|
|
882
892
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<NhAssistantToolCallCardComponent, "nh-assistant-tool-call-card", never, { "part": { "alias": "part"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
883
893
|
}
|
|
884
894
|
|
|
895
|
+
/** Overall state of a run of tool calls, from most to least urgent. */
|
|
896
|
+
type NhAssistantToolCallGroupState = 'awaiting-approval' | 'running' | 'failed' | 'succeeded';
|
|
897
|
+
/**
|
|
898
|
+
* Summarizes consecutive tool calls in one collapsed line that counts along live: the
|
|
899
|
+
* tool that runs now while the assistant works, and how many tools were used and failed
|
|
900
|
+
* afterwards. Expanding it shows every call as a card.
|
|
901
|
+
*/
|
|
902
|
+
declare class NhAssistantToolCallGroupComponent {
|
|
903
|
+
readonly calls: _angular_core.InputSignal<readonly ToolCallPart[]>;
|
|
904
|
+
readonly callsId: string;
|
|
905
|
+
readonly expanded: _angular_core.WritableSignal<boolean>;
|
|
906
|
+
/** The call that currently needs attention or runs; the latest one when several do. */
|
|
907
|
+
readonly current: _angular_core.Signal<ToolCallPart | null>;
|
|
908
|
+
readonly total: _angular_core.Signal<number>;
|
|
909
|
+
readonly finished: _angular_core.Signal<number>;
|
|
910
|
+
readonly failed: _angular_core.Signal<number>;
|
|
911
|
+
readonly state: _angular_core.Signal<NhAssistantToolCallGroupState>;
|
|
912
|
+
readonly stateIcon: _angular_core.Signal<NhAssistantIconName>;
|
|
913
|
+
toggle(): void;
|
|
914
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<NhAssistantToolCallGroupComponent, never>;
|
|
915
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<NhAssistantToolCallGroupComponent, "nh-assistant-tool-call-group", never, { "calls": { "alias": "calls"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
916
|
+
}
|
|
917
|
+
|
|
885
918
|
/** Formats remaining milliseconds as `m:ss`, or `h:mm:ss` above one hour. */
|
|
886
919
|
declare function formatNhAssistantCountdown(milliseconds: number): string;
|
|
887
920
|
/**
|
|
@@ -996,5 +1029,5 @@ declare function nhAssistantErrorKeys(error: NhAssistantError | null): string[];
|
|
|
996
1029
|
/** Dash-case identifiers as the contract requires for agent and MCP server ids. */
|
|
997
1030
|
declare const NH_ASSISTANT_DASH_CASE: RegExp;
|
|
998
1031
|
|
|
999
|
-
export { NH_ASSISTANT_ACCESS_POLICY, NH_ASSISTANT_CONFIG, NH_ASSISTANT_FETCH, NH_ASSISTANT_ICONS, NH_ASSISTANT_MAX_CUSTOM_INSTRUCTIONS, NH_ASSISTANT_NO_ANSWER_NOTICE_CODE, NH_ASSISTANT_PAGE_CONTEXT_LIMITS, NH_ASSISTANT_PANEL_MOBILE_QUERY, NH_ASSISTANT_PANEL_WIDTH, NH_ASSISTANT_SSE_EVENT_TYPES, NH_ASSISTANT_TRANSLATIONS, NH_ASSISTANT_VIRTUAL_SCROLL_THRESHOLD, NhAssistantAdminApiService, NhAssistantAgentPickerComponent, NhAssistantAllowAllAccessPolicy, NhAssistantApiError, NhAssistantApiService, NhAssistantApprovalCardComponent, NhAssistantClientErrorCodes, NhAssistantComposerComponent, NhAssistantConversationListComponent, NhAssistantLauncherComponent, NhAssistantPanelComponent, NhAssistantPanelService, NhAssistantPreferencesComponent, NhAssistantSseParser, NhAssistantStore, NhAssistantThreadComponent, NhAssistantToolCallCardComponent, NhAssistantTranslationMerger, applyNhAssistantApprovalDecision, applyNhAssistantEvent, describeNhAssistantClientContext, formatNhAssistantCountdown, nhAssistantCodeForStatus, nhAssistantErrorMessageKey, nhAssistantLatestTurnHasText, normalizeNhAssistantClientContext, provideNhAssistant, NH_ASSISTANT_DASH_CASE as ɵNH_ASSISTANT_DASH_CASE, NhAssistantIconComponent as ɵNhAssistantIconComponent, NhAssistantTranslatePipe as ɵNhAssistantTranslatePipe, nhAssistantErrorKeys as ɵnhAssistantErrorKeys, toNhAssistantError as ɵtoNhAssistantError };
|
|
1000
|
-
export type { AdminAgent, AdminAgentInput, AgentSummary, ApplicationContext, ApplicationContextVersion, ApprovalDecision, ApprovalPart, ApprovalPresentation, ApprovalPresentationField, ApprovalRequiredEvent, ApprovalStatus, AssistantAddressForm, AssistantAutonomy, AssistantErrorEvent, AssistantPreferences, AssistantResponseLength, AssistantStatus, AssistantStyle, ClientContext, ClientContextEntity, Conversation, ConversationPage, ConversationStatus, ConversationSummary, CreateConversationRequest, DecideApprovalRequest, McpAuthMode, McpServer, McpServerInput, McpServerTestResult, McpTool, McpToolEffect, McpToolStatus, Message, MessageDeltaEvent, MessagePart, NhAssistantAccessPolicy, NhAssistantClientContext, NhAssistantClientErrorCode, NhAssistantConfig, NhAssistantError, NhAssistantFetch, NhAssistantIconName, NhAssistantNotice, NhAssistantRawSseMessage, NhAssistantSseEvent, NhAssistantSseEventMap, NhAssistantSseEventType, NhAssistantStatusCodes, SendMessageRequest, TextPart, ToolCallPart, ToolCallStatus, ToolCatalogEffect, ToolCatalogEntry, ToolCompletedEvent, ToolStartedEvent, TurnCompletedEvent, TurnCompletionStatus, TurnStartedEvent, TurnUsage, UpdateAdminAgentRequest, UpdateApplicationContextRequest, UpdateMcpToolRequest };
|
|
1032
|
+
export { NH_ASSISTANT_ACCESS_POLICY, NH_ASSISTANT_CONFIG, NH_ASSISTANT_FETCH, NH_ASSISTANT_ICONS, NH_ASSISTANT_MAX_CUSTOM_INSTRUCTIONS, NH_ASSISTANT_NO_ANSWER_NOTICE_CODE, NH_ASSISTANT_PAGE_CONTEXT_LIMITS, NH_ASSISTANT_PANEL_MOBILE_QUERY, NH_ASSISTANT_PANEL_WIDTH, NH_ASSISTANT_SSE_EVENT_TYPES, NH_ASSISTANT_TRANSLATIONS, NH_ASSISTANT_VIRTUAL_SCROLL_THRESHOLD, NhAssistantAdminApiService, NhAssistantAgentPickerComponent, NhAssistantAllowAllAccessPolicy, NhAssistantApiError, NhAssistantApiService, NhAssistantApprovalCardComponent, NhAssistantClientErrorCodes, NhAssistantComposerComponent, NhAssistantConversationListComponent, NhAssistantLauncherComponent, NhAssistantPanelComponent, NhAssistantPanelService, NhAssistantPreferencesComponent, NhAssistantSseParser, NhAssistantStore, NhAssistantThreadComponent, NhAssistantToolCallCardComponent, NhAssistantToolCallGroupComponent, NhAssistantTranslationMerger, applyNhAssistantApprovalDecision, applyNhAssistantEvent, describeNhAssistantClientContext, formatNhAssistantCountdown, nhAssistantCodeForStatus, nhAssistantErrorMessageKey, nhAssistantLatestTurnHasText, normalizeNhAssistantClientContext, provideNhAssistant, NH_ASSISTANT_DASH_CASE as ɵNH_ASSISTANT_DASH_CASE, NhAssistantIconComponent as ɵNhAssistantIconComponent, NhAssistantTranslatePipe as ɵNhAssistantTranslatePipe, nhAssistantErrorKeys as ɵnhAssistantErrorKeys, toNhAssistantError as ɵtoNhAssistantError };
|
|
1033
|
+
export type { AdminAgent, AdminAgentInput, AgentSummary, ApplicationContext, ApplicationContextVersion, ApprovalDecision, ApprovalPart, ApprovalPresentation, ApprovalPresentationField, ApprovalRequiredEvent, ApprovalStatus, AssistantAddressForm, AssistantAutonomy, AssistantErrorEvent, AssistantPreferences, AssistantResponseLength, AssistantStatus, AssistantStyle, ClientContext, ClientContextEntity, Conversation, ConversationPage, ConversationStatus, ConversationSummary, CreateConversationRequest, DecideApprovalRequest, McpAuthMode, McpServer, McpServerInput, McpServerTestResult, McpTool, McpToolEffect, McpToolStatus, Message, MessageDeltaEvent, MessagePart, NhAssistantAccessPolicy, NhAssistantClientContext, NhAssistantClientErrorCode, NhAssistantConfig, NhAssistantError, NhAssistantFetch, NhAssistantIconName, NhAssistantNotice, NhAssistantRawSseMessage, NhAssistantSseEvent, NhAssistantSseEventMap, NhAssistantSseEventType, NhAssistantStatusCodes, NhAssistantToolCallGroupState, SendMessageRequest, TextPart, ToolCallPart, ToolCallStatus, ToolCatalogEffect, ToolCatalogEntry, ToolCompletedEvent, ToolStartedEvent, TurnCompletedEvent, TurnCompletionStatus, TurnStartedEvent, TurnUsage, UpdateAdminAgentRequest, UpdateApplicationContextRequest, UpdateMcpToolRequest };
|