@arcgis/ai-components 5.2.0-next.71 → 5.2.0-next.72
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/LICENSE.md +4 -2
- package/dist/agent-utils/types.d.ts +1 -1
- package/dist/agentic-workflow/AgenticWorkflowRuntime.d.ts +24 -0
- package/dist/agentic-workflow/Edge.d.ts +16 -0
- package/dist/agentic-workflow/WebAgent.d.ts +39 -0
- package/dist/agentic-workflow/jsonTypes.d.ts +186 -0
- package/dist/agentic-workflow/nodes/AgentNode.d.ts +26 -0
- package/dist/agentic-workflow/nodes/BaseNode.d.ts +35 -0
- package/dist/agentic-workflow/nodes/EndMessageNode.d.ts +25 -0
- package/dist/agentic-workflow/nodes/StartNode.d.ts +21 -0
- package/dist/agentic-workflow/nodes/support/Prompt.d.ts +20 -0
- package/dist/agentic-workflow/types.d.ts +29 -0
- package/dist/cdn/{PUFTYLJ2.js → 33BF35AO.js} +1 -1
- package/dist/cdn/55M2HE4U.js +2 -0
- package/dist/cdn/5RZGG4F2.js +2 -0
- package/dist/cdn/5SF6DEMO.js +2 -0
- package/dist/cdn/{MW5S2XCB.js → 5SFZS2RD.js} +1 -1
- package/dist/cdn/6QJFOL6M.js +2 -0
- package/dist/cdn/BAB3MK4Y.js +2 -0
- package/dist/cdn/BMBV6Y2A.js +2 -0
- package/dist/cdn/D3RKQSWS.js +2 -0
- package/dist/cdn/DBHLKLKM.js +2 -0
- package/dist/cdn/{CXW5URTF.js → DWYODVWW.js} +1 -1
- package/dist/cdn/{TFT6HK3O.js → E7KEOJZG.js} +1 -1
- package/dist/cdn/FSMHR7GK.js +2 -0
- package/dist/cdn/HO2YDJI2.js +6 -0
- package/dist/cdn/{KQHLOYKL.js → I4L45WQS.js} +1 -1
- package/dist/cdn/IGQFAL3H.js +2 -0
- package/dist/cdn/JYVBCHR6.js +6 -0
- package/dist/cdn/{XETNZW4D.js → NJJYZP3R.js} +1 -1
- package/dist/cdn/NSXX2KYS.js +2 -0
- package/dist/cdn/OFRFP4BX.js +2 -0
- package/dist/cdn/OUFGJV3R.js +2 -0
- package/dist/cdn/PAUIFUMO.js +2 -0
- package/dist/cdn/RWM5T4XB.js +180 -0
- package/dist/cdn/{YHQJ66WJ.js → S3XUYAUX.js} +1 -1
- package/dist/cdn/S6ZAQRC6.js +2 -0
- package/dist/cdn/SRFLL6ET.js +2 -0
- package/dist/cdn/UZL6UVE4.js +2 -0
- package/dist/cdn/{GP6NDTUE.js → WDOM6Z5O.js} +2 -2
- package/dist/cdn/WQKNV6KK.js +2 -0
- package/dist/cdn/{ICYUPLZM.js → WZFC5HUX.js} +1 -1
- package/dist/cdn/XPTCV6YV.js +2 -0
- package/dist/cdn/Y5UFOH54.js +2 -0
- package/dist/cdn/{E5ZKBC24.js → Z4XUJQ2I.js} +2 -2
- package/dist/cdn/{SXHH575T.js → ZJEWP2ND.js} +20 -24
- package/dist/cdn/agent-utils/index.js +1 -1
- package/dist/cdn/agent-utils/middlewares/humanInTheLoop.js +1 -1
- package/dist/cdn/agent-utils/middlewares/middleware.js +1 -1
- package/dist/cdn/agent-utils/middlewares/trace.js +1 -1
- package/dist/cdn/index.js +1 -1
- package/dist/chunks/adapter.js +668 -679
- package/dist/chunks/baseAgentState.js +56 -0
- package/dist/chunks/dataExplorationGraph.js +13 -13
- package/dist/chunks/generateLayerDescriptions.js +189 -235
- package/dist/chunks/navigationGraph.js +28 -28
- package/dist/chunks/orchestrator.js +1 -1
- package/dist/chunks/state.js +20 -26
- package/dist/chunks/utils2.js +3 -3
- package/dist/components/arcgis-assistant-agent/customElement.d.ts +13 -1
- package/dist/components/arcgis-assistant-agent/customElement.js +513 -12
- package/dist/components/arcgis-assistant-data-exploration-agent/customElement.js +1 -1
- package/dist/components/arcgis-assistant-help-agent/customElement.js +1 -1
- package/dist/components/arcgis-assistant-knowledge-agent/customElement.js +1 -1
- package/dist/components/arcgis-assistant-layer-styling-agent/customElement.js +1 -1
- package/dist/components/arcgis-assistant-navigation-agent/customElement.js +1 -1
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/dist/loader.js +1 -1
- package/dist/types/lumina.d.ts +1 -1
- package/dist/types/preact.d.ts +1 -1
- package/dist/types/react.d.ts +1 -1
- package/dist/types/stencil.d.ts +1 -1
- package/dist/utils/index.js +26 -25
- package/package.json +4 -4
- package/dist/cdn/3DJDRAGV.js +0 -2
- package/dist/cdn/4CEMUECT.js +0 -2
- package/dist/cdn/4PCAK3ET.js +0 -2
- package/dist/cdn/57OMVTIU.js +0 -2
- package/dist/cdn/6U7TEAAJ.js +0 -2
- package/dist/cdn/BE7ZN5FZ.js +0 -2
- package/dist/cdn/BNSJO6X2.js +0 -2
- package/dist/cdn/CMDRED5H.js +0 -2
- package/dist/cdn/DTIVDIDY.js +0 -2
- package/dist/cdn/HBLRVXEB.js +0 -2
- package/dist/cdn/HQXPPYMD.js +0 -2
- package/dist/cdn/IEHPNCTL.js +0 -2
- package/dist/cdn/LHLO6PTD.js +0 -2
- package/dist/cdn/OWXCOUIQ.js +0 -2
- package/dist/cdn/PVE7Q43N.js +0 -2
- package/dist/cdn/ST5FQYT7.js +0 -180
- package/dist/cdn/WUNCZOGU.js +0 -2
- package/dist/cdn/WVPU4QOO.js +0 -2
- package/dist/cdn/WXWO5D3W.js +0 -2
- package/dist/cdn/XCRR2EEG.js +0 -6
- package/dist/cdn/ZS6SXJP2.js +0 -2
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
2
|
import { StateGraph as E, START as $, END as C } from "@langchain/langgraph/web";
|
|
3
|
-
import { k as F, m as R, n as L, o as M, p as A, u as _, v as I, w as q, x as Z, g as T, y as k, t as
|
|
3
|
+
import { k as F, m as R, n as L, o as M, p as A, u as _, v as I, w as q, x as Z, g as T, y as k, t as V, f as u, r as j, N as w } from "./adapter.js";
|
|
4
4
|
import "@arcgis/core/identity/IdentityManager.js";
|
|
5
5
|
import "@arcgis/core/portal/Portal.js";
|
|
6
6
|
import "@arcgis/core/request.js";
|
|
7
7
|
import "@arcgis/toolkit/string";
|
|
8
|
-
import { h as
|
|
8
|
+
import { h as P, i as z } from "./generateLayerDescriptions.js";
|
|
9
9
|
import "@langchain/core/messages";
|
|
10
10
|
import "@langchain/core/callbacks/dispatch/web";
|
|
11
11
|
import "@langchain/openai";
|
|
@@ -29,23 +29,23 @@ const S = [
|
|
|
29
29
|
Z
|
|
30
30
|
];
|
|
31
31
|
async function B(e, t) {
|
|
32
|
-
const o = await T("navigation_tool_prompt"), { mapView: s } = k(t), i = s.map.bookmarks?.map((p) => p.name).filter(Boolean) ?? [], l = e.vectorSearchLayerResults?.length > 0 ? e.vectorSearchLayerResults.map(
|
|
32
|
+
const o = await T("navigation_tool_prompt"), { mapView: s } = k(t, ["mapView"]), i = s.map.bookmarks?.map((p) => p.name).filter(Boolean) ?? [], l = e.vectorSearchLayerResults?.length > 0 ? e.vectorSearchLayerResults.map(
|
|
33
33
|
(p, b) => `${b + 1}. layerId=${p.id} | title=${p.title ?? ""} | name=${p.name ?? ""} | score=${p.score.toFixed(2)}`
|
|
34
34
|
).join(`
|
|
35
35
|
`) : "", c = e.vectorSearchFieldResults?.length > 0 ? JSON.stringify(e.vectorSearchFieldResults, null, 2) : "", a = e.intent === "goToBookmark" && i.length ? `Available bookmarks:
|
|
36
36
|
${i.map((p) => `- ${p}`).join(`
|
|
37
37
|
`)}` : "", r = (e.intent === "goToLayer" || e.intent === "goToFeatures") && e.vectorSearchLayerResults?.length ? `Candidate layers:
|
|
38
|
-
${l}` : "",
|
|
38
|
+
${l}` : "", d = e.intent === "goToFeatures" && e.vectorSearchFieldResults?.length ? `Candidate fields:
|
|
39
39
|
${c}` : "", y = {
|
|
40
40
|
intent: e.intent,
|
|
41
41
|
bookmarksSection: a,
|
|
42
42
|
layersSection: r,
|
|
43
|
-
fieldsSection:
|
|
43
|
+
fieldsSection: d,
|
|
44
44
|
currentZoom: s.zoom,
|
|
45
45
|
assignedTask: e.agentExecutionContext.assignedTask,
|
|
46
46
|
userRequest: e.agentExecutionContext.userRequest,
|
|
47
47
|
priorSteps: e.agentExecutionContext.priorSteps
|
|
48
|
-
}, n = await
|
|
48
|
+
}, n = await P({
|
|
49
49
|
promptText: o,
|
|
50
50
|
modelTier: "fast",
|
|
51
51
|
config: t,
|
|
@@ -82,14 +82,14 @@ async function J(e, t) {
|
|
|
82
82
|
const s = e.navigationInternalState.toolCallMessage;
|
|
83
83
|
if (!s)
|
|
84
84
|
throw new Error("navigationToolCalling: missing navigationInternalState.toolCallMessage");
|
|
85
|
-
const { messages:
|
|
85
|
+
const { messages: m } = await o.invoke(
|
|
86
86
|
{
|
|
87
87
|
messages: [s]
|
|
88
88
|
},
|
|
89
89
|
t
|
|
90
90
|
);
|
|
91
91
|
let i = "", l;
|
|
92
|
-
for (const c of
|
|
92
|
+
for (const c of m) {
|
|
93
93
|
const a = D(c.content);
|
|
94
94
|
a.text && (i += `${a.text}
|
|
95
95
|
`), a.sharedStatePatch && (l = {
|
|
@@ -102,19 +102,19 @@ async function J(e, t) {
|
|
|
102
102
|
outputMessage: i,
|
|
103
103
|
sharedStatePatch: l,
|
|
104
104
|
status: "success",
|
|
105
|
-
summary: i ?
|
|
105
|
+
summary: i ? V(i) : "Navigation executed.",
|
|
106
106
|
navigationInternalState: {
|
|
107
107
|
...e.navigationInternalState,
|
|
108
108
|
toolCallMessage: void 0
|
|
109
109
|
}
|
|
110
110
|
};
|
|
111
111
|
} catch (s) {
|
|
112
|
-
const
|
|
113
|
-
return await h({ text: `Navigation tool execution failed: ${
|
|
112
|
+
const m = s instanceof Error ? s.message : String(s);
|
|
113
|
+
return await h({ text: `Navigation tool execution failed: ${m}` }, t), {
|
|
114
114
|
...e,
|
|
115
|
-
outputMessage: `Navigation tool execution failed: ${
|
|
115
|
+
outputMessage: `Navigation tool execution failed: ${m}`,
|
|
116
116
|
status: "failed",
|
|
117
|
-
summary: `Navigation tool execution failed: ${
|
|
117
|
+
summary: `Navigation tool execution failed: ${m}`,
|
|
118
118
|
navigationInternalState: {
|
|
119
119
|
...e.navigationInternalState,
|
|
120
120
|
toolCallMessage: void 0
|
|
@@ -123,14 +123,14 @@ async function J(e, t) {
|
|
|
123
123
|
}
|
|
124
124
|
}
|
|
125
125
|
async function H(e, t) {
|
|
126
|
-
const o = await T("navigation_intent_prompt"), { mapView: s } = k(t),
|
|
126
|
+
const o = await T("navigation_intent_prompt"), { mapView: s } = k(t, ["mapView"]), m = S.map((n) => ({
|
|
127
127
|
name: n.name,
|
|
128
128
|
description: n.description,
|
|
129
129
|
schema: n.schema
|
|
130
130
|
})), l = s.map.bookmarks?.map((n) => n.name).filter(Boolean) ?? [], c = l.length ? `Available bookmarks:
|
|
131
131
|
${l.map((n) => `- ${n}`).join(`
|
|
132
132
|
`)}` : "No bookmarks are available in this map.", a = {
|
|
133
|
-
tools:
|
|
133
|
+
tools: m.map(({ name: n, description: g, schema: v }) => `${n}: ${g}, ${JSON.stringify(v)}`).join(`
|
|
134
134
|
`),
|
|
135
135
|
bookmarks: c,
|
|
136
136
|
assignedTask: e.agentExecutionContext.assignedTask,
|
|
@@ -138,13 +138,13 @@ ${l.map((n) => `- ${n}`).join(`
|
|
|
138
138
|
priorSteps: e.agentExecutionContext.priorSteps
|
|
139
139
|
}, r = x.object({
|
|
140
140
|
intent: x.string()
|
|
141
|
-
}),
|
|
141
|
+
}), d = await z({
|
|
142
142
|
promptText: o,
|
|
143
143
|
config: t,
|
|
144
144
|
inputVariables: a,
|
|
145
145
|
schema: r,
|
|
146
146
|
modelTier: "fast"
|
|
147
|
-
}), y = typeof
|
|
147
|
+
}), y = typeof d.intent == "string" ? d.intent.trim().replace(/^"|"$/gu, "") : "";
|
|
148
148
|
return { ...e, intent: y || "" };
|
|
149
149
|
}
|
|
150
150
|
const U = 0.7, W = async (e, t) => {
|
|
@@ -153,16 +153,16 @@ const U = 0.7, W = async (e, t) => {
|
|
|
153
153
|
{ text: `Similarity search to find layers: ${e.agentExecutionContext.assignedTask}` },
|
|
154
154
|
t
|
|
155
155
|
);
|
|
156
|
-
const o = u(t, "layerSearch"), s = u(t, "layersAndFieldsRegistry"),
|
|
156
|
+
const o = u(t, "layerSearch"), s = u(t, "layersAndFieldsRegistry"), m = u(t, "embeddingCache"), l = (await o.searchLayers({
|
|
157
157
|
text: e.agentExecutionContext.assignedTask,
|
|
158
158
|
minScore: U,
|
|
159
|
-
embeddingCache:
|
|
159
|
+
embeddingCache: m
|
|
160
160
|
})).map(({ id: a, score: r }) => {
|
|
161
|
-
const
|
|
161
|
+
const d = s.get(a)?.layerItem;
|
|
162
162
|
return {
|
|
163
163
|
id: a,
|
|
164
|
-
title:
|
|
165
|
-
name:
|
|
164
|
+
title: d?.title,
|
|
165
|
+
name: d?.name ?? void 0,
|
|
166
166
|
score: r
|
|
167
167
|
};
|
|
168
168
|
});
|
|
@@ -185,7 +185,7 @@ ${l.map((a) => `- layerId=${a.id} | title=${a.title ?? ""} | name=${a.name ?? ""
|
|
|
185
185
|
{ text: `Similarity search to find fields: ${e.agentExecutionContext.assignedTask}` },
|
|
186
186
|
t
|
|
187
187
|
);
|
|
188
|
-
const o = u(t, "fieldSearch"), s = u(t, "layersAndFieldsRegistry"),
|
|
188
|
+
const o = u(t, "fieldSearch"), s = u(t, "layersAndFieldsRegistry"), m = u(t, "embeddingCache"), i = e.vectorSearchLayerResults?.map((r) => r.id) ?? [];
|
|
189
189
|
if (i.length === 0)
|
|
190
190
|
return await h({ text: "No candidate layers for field search" }, t), e;
|
|
191
191
|
const c = (await o.searchFields({
|
|
@@ -193,13 +193,13 @@ ${l.map((a) => `- layerId=${a.id} | title=${a.title ?? ""} | name=${a.name ?? ""
|
|
|
193
193
|
layerIds: i,
|
|
194
194
|
minScore: f,
|
|
195
195
|
topResults: K,
|
|
196
|
-
embeddingCache:
|
|
197
|
-
})).map(({ layerId: r, results:
|
|
196
|
+
embeddingCache: m
|
|
197
|
+
})).map(({ layerId: r, results: d }) => {
|
|
198
198
|
const y = s.get(r)?.fieldRegistry;
|
|
199
199
|
return {
|
|
200
200
|
layerId: r,
|
|
201
201
|
layerName: s.get(r)?.layerItem.name,
|
|
202
|
-
results:
|
|
202
|
+
results: d.map((n) => {
|
|
203
203
|
const g = y?.get(n.name);
|
|
204
204
|
return {
|
|
205
205
|
name: n.name,
|
|
@@ -217,7 +217,7 @@ ${l.map((a) => `- layerId=${a.id} | title=${a.title ?? ""} | name=${a.name ?? ""
|
|
|
217
217
|
return c.length > 0 ? a = `Vector search completed. Matching layers and fields:
|
|
218
218
|
${c.map(
|
|
219
219
|
(r) => `${r.layerName ?? r.layerId}:
|
|
220
|
-
${r.results.map((
|
|
220
|
+
${r.results.map((d) => ` - ${d.name} (${d.score.toFixed(2)})`).join(`
|
|
221
221
|
`)}`
|
|
222
222
|
).join(`
|
|
223
223
|
`)}` : a = `No vector search field results found for score over ${f}.`, await h({ text: a }, t), {
|
|
@@ -230,7 +230,7 @@ ${r.results.map((m) => ` - ${m.name} (${m.score.toFixed(2)})`).join(`
|
|
|
230
230
|
t
|
|
231
231
|
), o;
|
|
232
232
|
}
|
|
233
|
-
}, X = (e, t) =>
|
|
233
|
+
}, X = (e, t) => j(["layerSearch", "layersAndFieldsRegistry"], "Navigation Agent")(e, t), Y = () => new E(w).addNode("requireNavigationServices", X).addNode("intentLLM", H).addNode("vectorSearchLayers", W).addNode("vectorSearchFields", Q).addNode("agent", B).addNode("tools", J).addEdge($, "requireNavigationServices").addEdge("requireNavigationServices", "intentLLM").addConditionalEdges(
|
|
234
234
|
"intentLLM",
|
|
235
235
|
(t) => t.intent === "goToLayer" || t.intent === "goToFeatures" ? "vectorSearchLayers" : "agent",
|
|
236
236
|
{
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
2
|
import A from "@arcgis/core/identity/IdentityManager.js";
|
|
3
3
|
import C from "@arcgis/core/portal/Portal.js";
|
|
4
|
-
import {
|
|
4
|
+
import { j as k, k as b, D as M, n as D, o as F, W as $ } from "./generateLayerDescriptions.js";
|
|
5
5
|
import { isGraphInterrupt as L, StateGraph as W, START as q, END as j, MemorySaver as H } from "@langchain/langgraph/web";
|
|
6
6
|
import { generateGuid as P } from "@arcgis/toolkit/string";
|
|
7
7
|
import { HumanMessage as O, AIMessage as T } from "@langchain/core/messages";
|
package/dist/chunks/state.js
CHANGED
|
@@ -1,17 +1,9 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import { Annotation as
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
messages: [],
|
|
8
|
-
priorSteps: [],
|
|
9
|
-
sharedState: {},
|
|
10
|
-
userRequest: ""
|
|
11
|
-
};
|
|
12
|
-
}
|
|
13
|
-
function i(r) {
|
|
14
|
-
const n = [...new Set([...r].filter((t) => c.has(t)))];
|
|
2
|
+
import { Annotation as o } from "@langchain/langgraph/web";
|
|
3
|
+
import { c } from "./baseAgentState.js";
|
|
4
|
+
const i = /* @__PURE__ */ new Set(["agentExecutionContext", "outputMessage", "summary", "status"]);
|
|
5
|
+
function u(r) {
|
|
6
|
+
const n = [...new Set([...r].filter((t) => i.has(t)))];
|
|
15
7
|
if (n.length !== 0)
|
|
16
8
|
throw new Error(`custom state cannot define reserved runtime fields: ${n.join(", ")}.`);
|
|
17
9
|
}
|
|
@@ -20,36 +12,36 @@ function f(r) {
|
|
|
20
12
|
return Object.fromEntries(
|
|
21
13
|
n.map(([t, e]) => [
|
|
22
14
|
t,
|
|
23
|
-
|
|
24
|
-
reducer: (
|
|
15
|
+
o({
|
|
16
|
+
reducer: (s, a) => a,
|
|
25
17
|
default: () => e
|
|
26
18
|
})
|
|
27
19
|
])
|
|
28
20
|
);
|
|
29
21
|
}
|
|
30
22
|
function m(r = {}) {
|
|
31
|
-
|
|
23
|
+
u(Object.keys(r));
|
|
32
24
|
const n = f(r);
|
|
33
|
-
return
|
|
25
|
+
return o.Root({
|
|
34
26
|
...n,
|
|
35
|
-
agentExecutionContext:
|
|
27
|
+
agentExecutionContext: o({
|
|
36
28
|
reducer: (t, e) => ({
|
|
37
29
|
...t,
|
|
38
30
|
...e
|
|
39
31
|
}),
|
|
40
|
-
default:
|
|
32
|
+
default: c
|
|
41
33
|
}),
|
|
42
|
-
outputMessage:
|
|
34
|
+
outputMessage: o({
|
|
43
35
|
// Preserve the last meaningful user-facing message produced by the graph.
|
|
44
36
|
reducer: (t = "", e) => typeof e == "string" && e.trim() ? e : t,
|
|
45
37
|
default: () => ""
|
|
46
38
|
}),
|
|
47
|
-
summary:
|
|
39
|
+
summary: o({
|
|
48
40
|
// Summary is a compact orchestrator-facing outcome, so replacement semantics are enough.
|
|
49
41
|
reducer: (t = "", e) => typeof e == "string" ? e : t,
|
|
50
42
|
default: () => ""
|
|
51
43
|
}),
|
|
52
|
-
status:
|
|
44
|
+
status: o({
|
|
53
45
|
// Keep the first meaningful status until a later node explicitly replaces it.
|
|
54
46
|
reducer: (t, e) => e ?? t,
|
|
55
47
|
default: () => {
|
|
@@ -57,15 +49,17 @@ function m(r = {}) {
|
|
|
57
49
|
})
|
|
58
50
|
});
|
|
59
51
|
}
|
|
60
|
-
function
|
|
52
|
+
function g(r) {
|
|
61
53
|
const n = /* @__PURE__ */ new Set();
|
|
62
54
|
for (const e of r)
|
|
63
|
-
for (const
|
|
64
|
-
n.add(
|
|
55
|
+
for (const s of Object.keys(e.shape ?? {}))
|
|
56
|
+
n.add(s);
|
|
65
57
|
const t = Object.fromEntries([...n].map((e) => [e, void 0]));
|
|
66
58
|
return m(t);
|
|
67
59
|
}
|
|
68
60
|
export {
|
|
69
61
|
m as a,
|
|
70
|
-
|
|
62
|
+
u as b,
|
|
63
|
+
g as c,
|
|
64
|
+
f as d
|
|
71
65
|
};
|
package/dist/chunks/utils2.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference path="../../index.d.ts" />
|
|
2
2
|
import type { PublicLitElement as LitElement } from "@arcgis/lumina";
|
|
3
3
|
import type { AgentRegistration } from "../../utils/index.js";
|
|
4
|
+
import type { AgenticWorkflowJson } from "../../agentic-workflow/jsonTypes.js";
|
|
4
5
|
|
|
5
6
|
/**
|
|
6
7
|
* The Assistant Agent component is a generic wrapper for registering custom agents to the [arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/) component. To define
|
|
@@ -67,7 +68,6 @@ export abstract class ArcgisAssistantAgent<TContext = Record<string, unknown>> e
|
|
|
67
68
|
* See the [Custom Agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/) for more instructions
|
|
68
69
|
* and links to samples demonstrating how to create custom agents.
|
|
69
70
|
*
|
|
70
|
-
* @required
|
|
71
71
|
* @see [LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)
|
|
72
72
|
* @see [Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)
|
|
73
73
|
* @example
|
|
@@ -138,4 +138,16 @@ export abstract class ArcgisAssistantAgent<TContext = Record<string, unknown>> e
|
|
|
138
138
|
* ```
|
|
139
139
|
*/
|
|
140
140
|
accessor context: TContext | (() => Promise<TContext | undefined> | TContext | undefined) | undefined;
|
|
141
|
+
/**
|
|
142
|
+
* The portal item ID associated with this assistant agent.
|
|
143
|
+
*
|
|
144
|
+
* @internal
|
|
145
|
+
*/
|
|
146
|
+
accessor itemId: string | undefined;
|
|
147
|
+
/**
|
|
148
|
+
* The workflow JSON associated with this assistant agent.
|
|
149
|
+
*
|
|
150
|
+
* @internal
|
|
151
|
+
*/
|
|
152
|
+
accessor workflow: AgenticWorkflowJson | undefined;
|
|
141
153
|
}
|