akanjs 3.0.0-beta.7 → 3.0.0-beta.9

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.
Files changed (60) hide show
  1. package/common/index.ts +1 -0
  2. package/common/pathGet.ts +12 -2
  3. package/common/pathSet.ts +2 -3
  4. package/common/toPathSegments.ts +10 -0
  5. package/dictionary/base.dictionary.ts +5 -0
  6. package/index.ts +5 -0
  7. package/local/apps/serverLifecycle/serverLifecycle-local.db-shm +0 -0
  8. package/local/apps/serverLifecycle/serverLifecycle-local_solid.db-shm +0 -0
  9. package/package.json +1 -1
  10. package/service/agent.service.ts +92 -1
  11. package/service/predefinedAdaptor/llm.adaptor.ts +17 -0
  12. package/store/agentic/index.ts +1 -0
  13. package/store/agentic/useAgentReference.ts +49 -0
  14. package/store/hooks.ts +1 -1
  15. package/types/common/index.d.ts +1 -0
  16. package/types/common/toPathSegments.d.ts +9 -0
  17. package/types/dictionary/base.dictionary.d.ts +1 -1
  18. package/types/dictionary/dictionary.d.ts +8 -8
  19. package/types/index.d.ts +5 -0
  20. package/types/service/agent.service.d.ts +54 -0
  21. package/types/service/predefinedAdaptor/llm.adaptor.d.ts +16 -0
  22. package/types/store/agentic/index.d.ts +1 -0
  23. package/types/store/agentic/useAgentReference.d.ts +32 -0
  24. package/types/store/hooks.d.ts +1 -1
  25. package/types/ui/Agent/Chat.d.ts +11 -1
  26. package/types/ui/Agent/Composer.d.ts +9 -2
  27. package/types/ui/Agent/Menu.d.ts +4 -2
  28. package/types/ui/Agent/Refer.d.ts +13 -0
  29. package/types/ui/Agent/useChatQueue.d.ts +3 -1
  30. package/types/ui/Agent/useChatReferences.d.ts +26 -0
  31. package/types/ui/Agent/useReferenceMenu.d.ts +43 -0
  32. package/types/ui/Field/lightRefCache.d.ts +19 -0
  33. package/types/ui/Field/useRelationOptions.d.ts +39 -0
  34. package/types/ui/Select.d.ts +2 -0
  35. package/types/ui/index.d.ts +4 -1
  36. package/types/vendor/use-agentic/AgentSession.d.ts +54 -1
  37. package/types/vendor/use-agentic/Reference.d.ts +56 -0
  38. package/types/vendor/use-agentic/index.d.ts +1 -0
  39. package/types/vendor/use-agentic/types.d.ts +36 -6
  40. package/ui/Agent/Bubble.tsx +2 -0
  41. package/ui/Agent/Chat.tsx +38 -8
  42. package/ui/Agent/Composer.tsx +18 -1
  43. package/ui/Agent/Menu.tsx +8 -3
  44. package/ui/Agent/Queued.tsx +2 -0
  45. package/ui/Agent/Refer.tsx +44 -0
  46. package/ui/Agent/sessionHistory.ts +35 -12
  47. package/ui/Agent/useChatQueue.ts +11 -1
  48. package/ui/Agent/useChatReferences.ts +67 -0
  49. package/ui/Agent/useReferenceMenu.ts +108 -0
  50. package/ui/Field/Relation.tsx +70 -150
  51. package/ui/Field/lightRefCache.ts +73 -0
  52. package/ui/Field/useRelationOptions.ts +106 -0
  53. package/ui/Select.tsx +24 -14
  54. package/ui/index.ts +8 -0
  55. package/vendor/use-agentic/AgentSession.ts +127 -1
  56. package/vendor/use-agentic/Compaction.ts +6 -0
  57. package/vendor/use-agentic/Reference.ts +99 -0
  58. package/vendor/use-agentic/Transcript.ts +7 -1
  59. package/vendor/use-agentic/index.ts +1 -0
  60. package/vendor/use-agentic/types.ts +38 -7
package/common/index.ts CHANGED
@@ -111,6 +111,7 @@ export { sleep } from "./sleep";
111
111
  export { splitVersion } from "./splitVersion";
112
112
  export { getBasePathFromPathname, parseBasePaths, parseSubRouteHosts, resolveSubRouteHosts } from "./subRoute";
113
113
  export { TrustedProxy } from "./TrustedProxy";
114
+ export { toPathSegments } from "./toPathSegments";
114
115
  export type * from "./types";
115
116
  export {
116
117
  type WebsocketAuthAckData,
package/common/pathGet.ts CHANGED
@@ -1,13 +1,23 @@
1
+ import { toPathSegments } from "./toPathSegments";
2
+
1
3
  type Indexable = Record<string | number, unknown>;
4
+ type PathSegment = string | number;
2
5
 
3
6
  const isIndexable = (value: unknown): value is Indexable => Object(value) === value;
4
7
 
8
+ const readChild = (container: Indexable, key: PathSegment) =>
9
+ container instanceof Map ? (container as Map<PathSegment, unknown>).get(key) : container[key];
10
+
5
11
  export const pathGet = (
6
12
  path: string | (string | number)[],
7
13
  obj: unknown,
8
14
  separator = ".",
9
15
  fallback: unknown = null,
10
16
  ): unknown => {
11
- const properties = Array.isArray(path) ? path : path.split(separator);
12
- return properties.reduce((prev, curr) => (isIndexable(prev) ? (prev[curr] ?? fallback) : fallback), obj);
17
+
18
+ const properties = separator === "." ? toPathSegments(path) : Array.isArray(path) ? [...path] : path.split(separator);
19
+ return properties.reduce<unknown>(
20
+ (prev, curr) => (isIndexable(prev) ? (readChild(prev, curr) ?? fallback) : fallback),
21
+ obj,
22
+ );
13
23
  };
package/common/pathSet.ts CHANGED
@@ -1,10 +1,9 @@
1
+ import { toPathSegments } from "./toPathSegments";
2
+
1
3
  type MutableIndexable = Record<string | number, unknown>;
2
4
  type PathSegment = string | number;
3
5
  type Container = MutableIndexable | Map<PathSegment, unknown>;
4
6
 
5
- const toPathSegments = (path: string | readonly PathSegment[]) =>
6
- Array.isArray(path) ? [...path] : path.toString().match(/[^.[\]]+/g) || [];
7
-
8
7
  const readChild = (container: Container, key: PathSegment) =>
9
8
  container instanceof Map ? container.get(key) : container[key];
10
9
 
@@ -0,0 +1,10 @@
1
+ type PathSegment = string | number;
2
+
3
+ /**
4
+ * The one definition of what a dotted path's segments are, so a path that writes and a path that reads cannot
5
+ * disagree about it. `a.0.b` and `a[0].b` are the same three segments — the bracket form is what a form field
6
+ * hands `writeOn<Model>`, and a read of the same path has to accept the same spelling or the agent can write
7
+ * somewhere it cannot read back.
8
+ */
9
+ export const toPathSegments = (path: string | readonly PathSegment[]) =>
10
+ Array.isArray(path) ? [...path] : path.toString().match(/[^.[\]]+/g) || [];
@@ -81,6 +81,11 @@ export const baseDictionary = serviceDictionary(["en", "ko"])
81
81
  agentAttach: ["Attach a file", "파일 첨부"],
82
82
  agentAttachRemove: ["Remove attachment", "첨부 제거"],
83
83
  agentAttachReading: ["Reading…", "읽는 중…"],
84
+ agentReferenceRemove: ["Remove reference", "참조 제거"],
85
+ agentReferenceFailed: [
86
+ "{label} could not be read, so the agent has only its name.",
87
+ "{label}을(를) 읽지 못해 이름만 전달됩니다.",
88
+ ],
84
89
  agentAttachTooLarge: ["{name} is too large to attach.", "{name}은(는) 용량이 너무 커서 첨부할 수 없습니다."],
85
90
  agentAttachUnsupported: ["{name} cannot be attached here.", "{name}은(는) 여기에 첨부할 수 없습니다."],
86
91
  agentAttachDuplicate: ["{name} is already attached.", "{name}은(는) 이미 첨부되어 있습니다."],
package/index.ts CHANGED
@@ -292,6 +292,11 @@ export interface SubspaceDeclaration {
292
292
  repo: string;
293
293
  /** Apps this subspace serves. Libraries are never listed — they are derived from each app's closure. */
294
294
  apps: string[];
295
+ /**
296
+ * The cloud workspace this subspace deploys from — its own `AKAN_WORKSPACE_ID`, not this workspace's.
297
+ * `akan subspace upload-env` is the only thing that reads it.
298
+ */
299
+ workspaceId?: string;
295
300
  }
296
301
 
297
302
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "akanjs",
3
- "version": "3.0.0-beta.7",
3
+ "version": "3.0.0-beta.9",
4
4
  "sourceType": "module",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -2,6 +2,7 @@ import { Err } from "akanjs/dictionary";
2
2
  import type {
3
3
  AgentWireAttachment,
4
4
  AgentWireMessage,
5
+ AgentWireReference,
5
6
  LlmAccepts,
6
7
  LlmTurnRequest,
7
8
  } from "./predefinedAdaptor/llm.adaptor";
@@ -16,7 +17,9 @@ export class AgentService extends serve("agent" as const, ({ plug }) => ({
16
17
 
17
18
  const names = ToolNames.of(request);
18
19
  const prepared = names.encode(
19
- AgentService.instructed(AgentService.readable(AgentService.explained(request), this.llm.accepts)),
20
+ AgentService.instructed(
21
+ AgentService.readable(AgentService.referenced(AgentService.explained(request)), this.llm.accepts),
22
+ ),
20
23
  );
21
24
  const answer = await this.llm.chat(prepared, onDelta);
22
25
  if (!answer) throw new Err("agent.error.llmUnavailable");
@@ -68,6 +71,94 @@ export class AgentService extends serve("agent" as const, ({ plug }) => ({
68
71
  return { ...rest, text: [message.text, `[The turn failed: ${error}]`].filter(Boolean).join("\n\n") };
69
72
  }
70
73
 
74
+ /**
75
+ * The ceiling one reference's value may add to a turn, mirroring the client's own — the browser clips before it
76
+ * stages, and this is the same answer given again where nothing can route around it. `runTurn` is the only path
77
+ * to `chat()`, so a host that builds the wire itself, an older client, and a replayed transcript all pass here.
78
+ */
79
+ static readonly referenceLimit = 20_000;
80
+
81
+ /**
82
+ * Folds what the user pointed at into the message they pointed with, as text.
83
+ *
84
+ * Text rather than a carrier of its own for the same reason the note in `readable` is text: it is the one field
85
+ * every provider mapping already reads, so Anthropic, the OpenAI dialect and DeepSeek need no change between
86
+ * them and none of them can drop a reference quietly.
87
+ *
88
+ * The heading rides once per message rather than once per reference, and lives here rather than in `preamble`
89
+ * because most conversations never carry one — a sentence about mention tokens in every turn of every app is
90
+ * paid by every app that has no references at all.
91
+ */
92
+ static referenced(request: LlmTurnRequest): LlmTurnRequest {
93
+ if (!request.messages.some((message) => message.references?.length)) return request;
94
+ return { ...request, messages: request.messages.map((message) => AgentService.referencedMessage(message)) };
95
+ }
96
+
97
+ private static referencedMessage(message: AgentWireMessage): AgentWireMessage {
98
+ const { references = [], ...rest } = message;
99
+ if (!references.length) return message;
100
+ const block = [AgentService.referenceHeading, ...references.map(AgentService.referenceLine)].join("\n\n");
101
+ return { ...rest, text: [message.text, block].filter(Boolean).join("\n\n") };
102
+ }
103
+
104
+ /**
105
+ * Not decoration, and not free to shorten. Both halves of the sentence were observed doing their job, against
106
+ * Anthropic, with the same referenced field and only the published tools changed:
107
+ *
108
+ * - With no tool on the screen to re-read with, the model opened its answer by saying so — that it could see
109
+ * only the snapshot and the field might have been edited since. Unprompted, ahead of the answer.
110
+ * - With the screen's own tools passed (a state read and a write), it issued the read instead of answering,
111
+ * and stopped the turn there.
112
+ *
113
+ * So it reads as an instruction rather than as framing: it re-reads where it can and says it cannot where it
114
+ * cannot, which is the pair a turn confidently quoting a stale value is bought against. Two scenarios against
115
+ * one provider, not the per-cell runs behind `preamble` — enough to keep the sentence, not enough to call it
116
+ * measured.
117
+ */
118
+ static readonly referenceHeading =
119
+ "[Referenced data: the user pointed at this while writing the message above, with the @[label](mention:…) " +
120
+ "tokens in it. Each value is what it was at the moment they sent the message, not what it is now — read it " +
121
+ "again with a tool before relying on it, and do not assume an edit you have made since is reflected here.]";
122
+
123
+ /**
124
+ * A string value is printed as itself rather than as JSON. It is the common case — one field of one document —
125
+ * and a quoted, escaped copy of a paragraph is harder for a model to read back and to quote from than the
126
+ * paragraph. It is also what a clipped value already is, so the cut JSON prints as the fragment it is.
127
+ *
128
+ * The pointer leads the line rather than riding the wire alone, and that is what the label cannot do. Pointed
129
+ * at a saved document while a *different* document of the same model sat open on the screen, the model
130
+ * compared the two ids, said the edit it could make would land on the wrong one, and stopped to ask — with no
131
+ * write call. Two references sharing a label are still two ids here, so keep the id ahead of the label.
132
+ */
133
+ private static referenceLine(reference: AgentWireReference): string {
134
+ const at = `${reference.refName}/${reference.refId}${reference.path ? `#${reference.path}` : ""}`;
135
+ const head = `${at} (${reference.label}):`;
136
+ if (reference.value === undefined)
137
+ return `${head} [not read: ${reference.note ?? "the value was not carried into this conversation"}]`;
138
+ const text =
139
+ typeof reference.value === "string" ? reference.value : (JSON.stringify(reference.value, null, 2) ?? "null");
140
+ const body =
141
+ text.length <= AgentService.referenceLimit
142
+ ? text
143
+ : `${text.slice(0, AgentService.referenceLimit)}…\n[Clipped at ${AgentService.referenceLimit} characters.]`;
144
+ return `${head}\n${AgentService.fenced(body)}${reference.note ? `\n[${reference.note}]` : ""}`;
145
+ }
146
+
147
+ /**
148
+ * Where a value ends. A multi-line one — the usual shape of the prose field somebody points at — otherwise runs
149
+ * straight into the next reference's heading, and the model reads one value that swallowed the next label.
150
+ *
151
+ * The fence grows past the longest backtick run inside the value, which is CommonMark's own answer to the same
152
+ * problem: a fixed fence is one that a value containing a fence breaks out of, and a value containing a fence is
153
+ * ordinary here, because the thing being pointed at is often something a person wrote.
154
+ */
155
+ private static fenced(text: string): string {
156
+ const runs = text.match(/`+/g);
157
+ const longest = runs ? Math.max(...runs.map((run) => run.length)) : 0;
158
+ const fence = "`".repeat(Math.max(3, longest + 1));
159
+ return `${fence}\n${text}\n${fence}`;
160
+ }
161
+
71
162
  /**
72
163
  * Replaces every attachment the provider cannot read with a note naming it, so no adaptor has to think about
73
164
  * attachments it does not support and none can lose one quietly. The model has to be *told*, not merely spared:
@@ -28,6 +28,22 @@ export interface AgentWireAttachment {
28
28
  ref?: string;
29
29
  }
30
30
 
31
+ /**
32
+ * Data the caller pointed at while writing one message, rather than a file they attached. `value` is a snapshot
33
+ * taken when the message was sent and already masked by the host — the server has no model class to mask it with,
34
+ * so what the browser staged is what leaves. `refName`/`refId`/`path` are the way back to the current value, which
35
+ * is why they travel even when the value itself does not.
36
+ */
37
+ export interface AgentWireReference {
38
+ refName: string;
39
+ refId: string;
40
+ label: string;
41
+ path?: string;
42
+ value?: unknown;
43
+ /** Read by the model in place of a value there is none of — clipped, unreadable, or gone from a restored chat. */
44
+ note?: string;
45
+ }
46
+
31
47
  /**
32
48
  * One transcript message of the in-page agent wire (`use-agentic`'s WIRE.md), typed at both ends independently —
33
49
  * the wire is the contract, so the server never imports the client package.
@@ -36,6 +52,7 @@ export interface AgentWireMessage {
36
52
  role: "user" | "assistant" | "tool";
37
53
  text?: string;
38
54
  attachments?: AgentWireAttachment[];
55
+ references?: AgentWireReference[];
39
56
  toolCalls?: AgentWireToolCall[];
40
57
  toolResults?: AgentWireToolResult[];
41
58
  error?: string;
@@ -7,6 +7,7 @@ export * from "./StStateBuilder";
7
7
  export * from "./StStateDraft";
8
8
  export * from "./StToolBuilder";
9
9
  export * from "./StToolDraft";
10
+ export * from "./useAgentReference";
10
11
  export * from "./useFieldTool";
11
12
  export * from "./useFileFieldTool";
12
13
  export * from "./useFormTools";
@@ -0,0 +1,49 @@
1
+ "use client";
2
+ import { SessionContext } from "../../vendor/use-agentic";
3
+
4
+ import { useContext } from "../hooks";
5
+ import { type AgentFieldType, AgentValue, type AgentValueOf } from "./AgentValue";
6
+
7
+ /**
8
+ * What a component hands over when the user points at data it is already drawing.
9
+ *
10
+ * The pointer and the value are declared apart on purpose. `refName`/`refId`/`path` say *what was pointed at*, and
11
+ * travel so the agent can read it again later; `type` and `value` say *what is being shown to the model now*, and
12
+ * the component supplies the value it already holds, so there is no round trip. They come apart because the two
13
+ * are genuinely different in the case this exists for: a rich-text field stored as `field(Any)` is an editor
14
+ * document at its path and a paragraph of prose to a reader, and the model wants the paragraph.
15
+ *
16
+ * `type` is `st.expose`'s vocabulary, not a second one. It decides what leaves the browser — a model class masks
17
+ * by that model, a scalar passes, `Any` passes untouched — so naming a `Light` class that does not carry the field
18
+ * is how a reference arrives empty.
19
+ */
20
+ export interface AgentReferenceInput<T extends AgentFieldType> {
21
+ refName: string;
22
+ refId: string;
23
+ /** What the chip draws and what the token in the draft spells. */
24
+ label: string;
25
+ /** A dotted path into the document, in `pathSet`'s vocabulary. Absent points at the whole of it. */
26
+ path?: string;
27
+ type: T;
28
+ value: AgentValueOf<T>;
29
+ }
30
+
31
+ /**
32
+ * Points the enclosing agent session at data, from anywhere that draws it.
33
+ *
34
+ * No-ops outside a session rather than throwing, the same call `AgentValue.publishable` makes: a card carrying a
35
+ * reference button is mounted on whatever routes render it, and a route that happens to host no agent must not
36
+ * lose its render over it.
37
+ */
38
+ export const useAgentReference = () => {
39
+ const session = useContext(SessionContext);
40
+ return <T extends AgentFieldType>({ type, value, ...pointer }: AgentReferenceInput<T>) => {
41
+ const owner = `reference ${pointer.refName}/${pointer.refId}`;
42
+ if (!session) {
43
+ console.warn(`${owner} was not staged: this component is not inside an <Agent.Chat /> or <Agent.Zone />.`);
44
+ return;
45
+ }
46
+ if (!AgentValue.publishable(owner, type)) return;
47
+ session.refer({ ...pointer, value: AgentValue.serialize(type, value) });
48
+ };
49
+ };
package/store/hooks.ts CHANGED
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- export { useEffect, useRef, useSyncExternalStore } from "react";
2
+ export { useContext, useEffect, useRef, useSyncExternalStore } from "react";
@@ -38,6 +38,7 @@ export { sleep } from "./sleep.d.ts";
38
38
  export { splitVersion } from "./splitVersion.d.ts";
39
39
  export { getBasePathFromPathname, parseBasePaths, parseSubRouteHosts, resolveSubRouteHosts } from "./subRoute.d.ts";
40
40
  export { TrustedProxy } from "./TrustedProxy.d.ts";
41
+ export { toPathSegments } from "./toPathSegments.d.ts";
41
42
  export type * from "./types.d.ts";
42
43
  export { type WebsocketAuthAckData, type WebsocketAuthRequest, websocketAuthContract, } from "./websocketAuth.d.ts";
43
44
  export { type WebsocketBinaryFrame, websocketBinaryFrameContract } from "./websocketBinaryFrame.d.ts";
@@ -0,0 +1,9 @@
1
+ type PathSegment = string | number;
2
+ /**
3
+ * The one definition of what a dotted path's segments are, so a path that writes and a path that reads cannot
4
+ * disagree about it. `a.0.b` and `a[0].b` are the same three segments — the bracket form is what a form field
5
+ * hands `writeOn<Model>`, and a read of the same path has to accept the same spelling or the agent can write
6
+ * somewhere it cannot read back.
7
+ */
8
+ export declare const toPathSegments: (path: string | readonly PathSegment[]) => any[];
9
+ export {};
@@ -1 +1 @@
1
- export declare const baseDictionary: import("./dictInfo.d.ts").ServiceDictInfo<[string, string], "ping" | "pingBody" | "pingParam" | "pingQuery" | "wsPing" | "pubsubPing", "serverUnreachable" | "serverUnavailable" | "gatewayTimeout" | "unexpectedResponse", "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view">;
1
+ export declare const baseDictionary: import("./dictInfo.d.ts").ServiceDictInfo<[string, string], "ping" | "pingBody" | "pingParam" | "pingQuery" | "wsPing" | "pubsubPing", "serverUnreachable" | "serverUnavailable" | "gatewayTimeout" | "unexpectedResponse", "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view">;
@@ -1,13 +1,13 @@
1
1
  import type { AgentEndpoint, AgentTurn, BaseEndpoint } from "akanjs/signal";
2
2
  export declare const dictionary: {
3
- base: import("./locale.d.ts").DictModule<import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view">, "base.error.gatewayTimeout" | "base.error.serverUnavailable" | "base.error.serverUnreachable" | "base.error.unexpectedResponse">;
3
+ base: import("./locale.d.ts").DictModule<import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view">, "base.error.gatewayTimeout" | "base.error.serverUnavailable" | "base.error.serverUnreachable" | "base.error.unexpectedResponse">;
4
4
  agentTurn: import("./locale.d.ts").DictModule<import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc`, never>;
5
5
  agent: import("./locale.d.ts").DictModule<import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, "agent.error.llmUnavailable" | "agent.error.deepseekRequestFailed" | "agent.error.openaiRequestFailed" | "agent.error.anthropicRequestFailed">;
6
6
  };
7
- export declare const Err: import("./trans.d.ts").ErrConstructor<"base.error.gatewayTimeout" | "base.error.serverUnavailable" | "base.error.serverUnreachable" | "base.error.unexpectedResponse" | "agent.error.llmUnavailable" | "agent.error.deepseekRequestFailed" | "agent.error.openaiRequestFailed" | "agent.error.anthropicRequestFailed">, translate: (lang: "en" | "ko" | (string & {}) | "zhChs" | "zhCht" | "ja", key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, data?: import("./trans.d.ts").TranslationData) => string, msg: {
8
- info: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
9
- success: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
10
- error: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
11
- warning: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
12
- loading: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
13
- }, getDictionary: (lang: "en" | "ko" | (string & {}) | "zhChs" | "zhCht" | "ja") => object, getAllDictionary: () => import("./trans.d.ts").RootDictionary, __Dict_Key__: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, __Error_Key__: "base.error.gatewayTimeout" | "base.error.serverUnavailable" | "base.error.serverUnreachable" | "base.error.unexpectedResponse" | "agent.error.llmUnavailable" | "agent.error.deepseekRequestFailed" | "agent.error.openaiRequestFailed" | "agent.error.anthropicRequestFailed";
7
+ export declare const Err: import("./trans.d.ts").ErrConstructor<"base.error.gatewayTimeout" | "base.error.serverUnavailable" | "base.error.serverUnreachable" | "base.error.unexpectedResponse" | "agent.error.llmUnavailable" | "agent.error.deepseekRequestFailed" | "agent.error.openaiRequestFailed" | "agent.error.anthropicRequestFailed">, translate: (lang: "en" | "ko" | (string & {}) | "zhChs" | "zhCht" | "ja", key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, data?: import("./trans.d.ts").TranslationData) => string, msg: {
8
+ info: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
9
+ success: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
10
+ error: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
11
+ warning: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
12
+ loading: (key: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, option?: import("./trans.d.ts").TransMessageOption) => void;
13
+ }, getDictionary: (lang: "en" | "ko" | (string & {}) | "zhChs" | "zhCht" | "ja") => object, getAllDictionary: () => import("./trans.d.ts").RootDictionary, __Dict_Key__: import("./locale.d.ts").ServiceTranslatorKey<"base", BaseEndpoint, "error" | "remove" | "save" | "refresh" | "password" | "skip" | "stop" | "send" | "ok" | "agent" | "success" | "somethingWrong" | "connecting" | "connected" | "serverDisconnected" | "refreshing" | "tryReconnecting" | "serverHasProblem" | "checkServerStatus" | "cameraPromptHeader" | "cameraPromptPhoto" | "cameraPromptPicture" | "cameraPromptCancel" | "failed" | "processing" | "processed" | "noData" | "invalidValueError" | "emailInvalidError" | "phoneInvalidError" | "cancel" | "unauthorized" | "agentIntro" | "agentPlaceholder" | "agentClear" | "agentQuestion" | "agentAnswer" | "agentListen" | "agentVoiceFailed" | "agentAttach" | "agentAttachRemove" | "agentAttachReading" | "agentReferenceRemove" | "agentReferenceFailed" | "agentAttachTooLarge" | "agentAttachUnsupported" | "agentAttachDuplicate" | "agentAttachTooMany" | "agentAttachTooMuch" | "agentAnswerNeeded" | "agentQueue" | "agentQueuePlaceholder" | "agentQueued" | "agentQueueEdit" | "agentQueueCancel" | "agentToolDone" | "agentToolFailed" | "agentToolRunning" | "agentToolResult" | "agentTokens" | "agentSummarizing" | "agentContinue" | "agentKeepGoing" | "agentCmdNew" | "agentCmdRetry" | "agentCmdCompact" | "agentCmdCopy" | "agentCmdHelp" | "agentCmdTools" | "agentHelpIntro" | "agentHelpNote" | "agentNothingToRetry" | "agentNothingToCompact" | "agentCompacted" | "agentSummary" | "agentBusy" | "agentCopied" | "agentCopyFailed" | "agentToolsHead" | "agentToolsState" | "approve" | "decline" | "confirmClose" | "textTooShortError" | "textTooLongError" | "selectTooShortError" | "selectTooLongError" | "numberTooSmallError" | "numberTooBigError" | "passwordNotMatchError" | "selectDateError" | "priceUnit" | "passwordConfirm" | "noOptions" | "noSelection" | "addModel" | "createModel" | "createSuccess" | "updateModel" | "removeModel" | "updateSuccess" | "removeSuccess" | "sureToRemove" | "irreversibleOps" | "typeNameToRemove" | "yesRemove" | "removeMsg" | "confirmMsg" | "perPage" | "cardView" | "tableView" | "exportCsv" | "exportJson" | "actions" | "draftConflict" | "draftApplied" | "draftRestore" | "draftDiscard" | "draftStartOver" | "new" | "edit" | "view"> | import("./locale.d.ts").ScalarTranslatorKey<"agentTurn", AgentTurn, never> | `agentStop.${string}` | `agentStop.${string}.desc` | import("./locale.d.ts").ServiceTranslatorKey<"agent", AgentEndpoint, never>, __Error_Key__: "base.error.gatewayTimeout" | "base.error.serverUnavailable" | "base.error.serverUnreachable" | "base.error.unexpectedResponse" | "agent.error.llmUnavailable" | "agent.error.deepseekRequestFailed" | "agent.error.openaiRequestFailed" | "agent.error.anthropicRequestFailed";
package/types/index.d.ts CHANGED
@@ -278,6 +278,11 @@ export interface SubspaceDeclaration {
278
278
  repo: string;
279
279
  /** Apps this subspace serves. Libraries are never listed — they are derived from each app's closure. */
280
280
  apps: string[];
281
+ /**
282
+ * The cloud workspace this subspace deploys from — its own `AKAN_WORKSPACE_ID`, not this workspace's.
283
+ * `akan subspace upload-env` is the only thing that reads it.
284
+ */
285
+ workspaceId?: string;
281
286
  }
282
287
  /**
283
288
  * What `akan.subspace.ts` at a workspace root may write: the customer repos this workspace is mirrored
@@ -35,6 +35,60 @@ export declare class AgentService extends AgentService_base {
35
35
  */
36
36
  static explained(request: LlmTurnRequest): LlmTurnRequest;
37
37
  private static explainedMessage;
38
+ /**
39
+ * The ceiling one reference's value may add to a turn, mirroring the client's own — the browser clips before it
40
+ * stages, and this is the same answer given again where nothing can route around it. `runTurn` is the only path
41
+ * to `chat()`, so a host that builds the wire itself, an older client, and a replayed transcript all pass here.
42
+ */
43
+ static readonly referenceLimit = 20000;
44
+ /**
45
+ * Folds what the user pointed at into the message they pointed with, as text.
46
+ *
47
+ * Text rather than a carrier of its own for the same reason the note in `readable` is text: it is the one field
48
+ * every provider mapping already reads, so Anthropic, the OpenAI dialect and DeepSeek need no change between
49
+ * them and none of them can drop a reference quietly.
50
+ *
51
+ * The heading rides once per message rather than once per reference, and lives here rather than in `preamble`
52
+ * because most conversations never carry one — a sentence about mention tokens in every turn of every app is
53
+ * paid by every app that has no references at all.
54
+ */
55
+ static referenced(request: LlmTurnRequest): LlmTurnRequest;
56
+ private static referencedMessage;
57
+ /**
58
+ * Not decoration, and not free to shorten. Both halves of the sentence were observed doing their job, against
59
+ * Anthropic, with the same referenced field and only the published tools changed:
60
+ *
61
+ * - With no tool on the screen to re-read with, the model opened its answer by saying so — that it could see
62
+ * only the snapshot and the field might have been edited since. Unprompted, ahead of the answer.
63
+ * - With the screen's own tools passed (a state read and a write), it issued the read instead of answering,
64
+ * and stopped the turn there.
65
+ *
66
+ * So it reads as an instruction rather than as framing: it re-reads where it can and says it cannot where it
67
+ * cannot, which is the pair a turn confidently quoting a stale value is bought against. Two scenarios against
68
+ * one provider, not the per-cell runs behind `preamble` — enough to keep the sentence, not enough to call it
69
+ * measured.
70
+ */
71
+ static readonly referenceHeading: string;
72
+ /**
73
+ * A string value is printed as itself rather than as JSON. It is the common case — one field of one document —
74
+ * and a quoted, escaped copy of a paragraph is harder for a model to read back and to quote from than the
75
+ * paragraph. It is also what a clipped value already is, so the cut JSON prints as the fragment it is.
76
+ *
77
+ * The pointer leads the line rather than riding the wire alone, and that is what the label cannot do. Pointed
78
+ * at a saved document while a *different* document of the same model sat open on the screen, the model
79
+ * compared the two ids, said the edit it could make would land on the wrong one, and stopped to ask — with no
80
+ * write call. Two references sharing a label are still two ids here, so keep the id ahead of the label.
81
+ */
82
+ private static referenceLine;
83
+ /**
84
+ * Where a value ends. A multi-line one — the usual shape of the prose field somebody points at — otherwise runs
85
+ * straight into the next reference's heading, and the model reads one value that swallowed the next label.
86
+ *
87
+ * The fence grows past the longest backtick run inside the value, which is CommonMark's own answer to the same
88
+ * problem: a fixed fence is one that a value containing a fence breaks out of, and a value containing a fence is
89
+ * ordinary here, because the thing being pointed at is often something a person wrote.
90
+ */
91
+ private static fenced;
38
92
  /**
39
93
  * Replaces every attachment the provider cannot read with a note naming it, so no adaptor has to think about
40
94
  * attachments it does not support and none can lose one quietly. The model has to be *told*, not merely spared:
@@ -25,6 +25,21 @@ export interface AgentWireAttachment {
25
25
  /** The host's own handle on this file, carried so a relay can act on it. A provider mapping ignores it. */
26
26
  ref?: string;
27
27
  }
28
+ /**
29
+ * Data the caller pointed at while writing one message, rather than a file they attached. `value` is a snapshot
30
+ * taken when the message was sent and already masked by the host — the server has no model class to mask it with,
31
+ * so what the browser staged is what leaves. `refName`/`refId`/`path` are the way back to the current value, which
32
+ * is why they travel even when the value itself does not.
33
+ */
34
+ export interface AgentWireReference {
35
+ refName: string;
36
+ refId: string;
37
+ label: string;
38
+ path?: string;
39
+ value?: unknown;
40
+ /** Read by the model in place of a value there is none of — clipped, unreadable, or gone from a restored chat. */
41
+ note?: string;
42
+ }
28
43
  /**
29
44
  * One transcript message of the in-page agent wire (`use-agentic`'s WIRE.md), typed at both ends independently —
30
45
  * the wire is the contract, so the server never imports the client package.
@@ -33,6 +48,7 @@ export interface AgentWireMessage {
33
48
  role: "user" | "assistant" | "tool";
34
49
  text?: string;
35
50
  attachments?: AgentWireAttachment[];
51
+ references?: AgentWireReference[];
36
52
  toolCalls?: AgentWireToolCall[];
37
53
  toolResults?: AgentWireToolResult[];
38
54
  error?: string;
@@ -7,6 +7,7 @@ export * from "./StStateBuilder.d.ts";
7
7
  export * from "./StStateDraft.d.ts";
8
8
  export * from "./StToolBuilder.d.ts";
9
9
  export * from "./StToolDraft.d.ts";
10
+ export * from "./useAgentReference.d.ts";
10
11
  export * from "./useFieldTool.d.ts";
11
12
  export * from "./useFileFieldTool.d.ts";
12
13
  export * from "./useFormTools.d.ts";