@arcgis/ai-components 5.2.0-next.110 → 5.2.0-next.112

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 (294) hide show
  1. package/dist/agent-utils/BaseAgent.js +1 -1
  2. package/dist/agent-utils/FunctionAgent.js +1 -1
  3. package/dist/agent-utils/LLMAgent.d.ts +4 -5
  4. package/dist/agent-utils/LLMAgent.js +59 -59
  5. package/dist/agent-utils/WorkflowAgent.js +1 -1
  6. package/dist/agent-utils/index.js +1 -1
  7. package/dist/agent-utils/middlewares/humanInTheLoop.js +1 -1
  8. package/dist/agent-utils/middlewares/middleware.js +1 -1
  9. package/dist/agent-utils/middlewares/trace.js +6 -6
  10. package/dist/agent-utils/middlewares/types.js +1 -1
  11. package/dist/agent-utils/tools/FunctionTool.js +1 -1
  12. package/dist/agent-utils/workflows/ConditionalWorkflow.js +1 -1
  13. package/dist/agent-utils/workflows/LoopWorkflow.js +1 -1
  14. package/dist/agent-utils/workflows/ParallelWorkflow.js +1 -1
  15. package/dist/agent-utils/workflows/RouterWorkflow.js +1 -1
  16. package/dist/agent-utils/workflows/SequentialWorkflow.js +1 -1
  17. package/dist/agent-utils/workflows/SwitchWorkflow.js +1 -1
  18. package/dist/agentic-workflow/jsonTypes.d.ts +48 -8
  19. package/dist/agentic-workflow/nodes/HumanInTheLoopNode.d.ts +37 -0
  20. package/dist/agentic-workflow/types.d.ts +1 -1
  21. package/dist/agents/runtime/skill/createSkillAgent.d.ts +0 -1
  22. package/dist/agents/runtime/skill/createSkillAgent.js +50 -50
  23. package/dist/agents/runtime/skill/types.d.ts +2 -10
  24. package/dist/agents/runtime/skill/types.js +1 -1
  25. package/dist/agents/tools/filter/clearFilters/adapter.js +1 -1
  26. package/dist/agents/tools/filter/resetMap/adapter.js +1 -1
  27. package/dist/agents/tools/filter/setFeatureEffect/adapter.js +1 -1
  28. package/dist/agents/tools/help/listFields/adapter.js +1 -1
  29. package/dist/agents/tools/navigation/goToAddress/adapter.js +1 -1
  30. package/dist/agents/tools/navigation/goToBookmark/adapter.js +1 -1
  31. package/dist/agents/tools/navigation/goToFeatures/adapter.js +1 -1
  32. package/dist/agents/tools/navigation/goToFullExtent/adapter.js +1 -1
  33. package/dist/agents/tools/navigation/goToHomeExtent/adapter.js +1 -1
  34. package/dist/agents/tools/navigation/goToLayer/adapter.js +1 -1
  35. package/dist/agents/tools/navigation/goToScale/adapter.js +1 -1
  36. package/dist/agents/tools/navigation/goToViewpoint/adapter.js +1 -1
  37. package/dist/agents/tools/navigation/goToZoom/adapter.js +1 -1
  38. package/dist/agents/tools/query/getAttribute/adapter.js +1 -1
  39. package/dist/agents/tools/query/getStatistics/adapter.js +1 -1
  40. package/dist/agents/tools/query/getTopFeatures/adapter.js +1 -1
  41. package/dist/agents/tools/query/queryFeatures/adapter.js +1 -1
  42. package/dist/agents/tools/search/findRelevantFields/adapter.js +1 -1
  43. package/dist/agents/tools/search/findRelevantLayers/adapter.js +1 -1
  44. package/dist/agents/tools/shared/resolveToolArtifact.js +1 -1
  45. package/dist/agents/tools/shared/types.js +1 -1
  46. package/dist/cdn/2BNQ6A6J.js +2 -0
  47. package/dist/cdn/{FV6FHLYW.js → 2MWUBKWI.js} +2 -2
  48. package/dist/cdn/{GW3IVAAZ.js → 2O4DON37.js} +2 -2
  49. package/dist/cdn/33PB7ALY.js +2 -0
  50. package/dist/cdn/{FK2CVSXW.js → 33SFAZQG.js} +4 -4
  51. package/dist/cdn/{LLY5A2E2.js → 34O57OGV.js} +1 -1
  52. package/dist/cdn/{OALQBAZR.js → 3UEKINYC.js} +2 -2
  53. package/dist/cdn/434TAA3J.js +2 -0
  54. package/dist/cdn/4AQBRGO2.js +3 -0
  55. package/dist/cdn/{ZWIKFBOU.js → 4IU63OWQ.js} +2 -2
  56. package/dist/cdn/{XRVGYRXL.js → 5A355PGH.js} +2 -2
  57. package/dist/cdn/5BBXNT75.js +66 -0
  58. package/dist/cdn/{TB2GJALS.js → 5HBAJ57P.js} +2 -2
  59. package/dist/cdn/{7Y43R7QJ.js → 5MK44FNO.js} +2 -2
  60. package/dist/cdn/{LXIKAXUT.js → 5Q2XRQS6.js} +2 -2
  61. package/dist/cdn/{UAZPINUQ.js → 6ECRQVHY.js} +2 -2
  62. package/dist/cdn/{BBEGLIZC.js → 6OOZSZRJ.js} +2 -2
  63. package/dist/cdn/6OUIUXAJ.js +2 -0
  64. package/dist/cdn/{Y4TYL2AL.js → 6P44KOKX.js} +2 -2
  65. package/dist/cdn/{LBTGOMCT.js → 73TMZQI5.js} +2 -2
  66. package/dist/cdn/{BJMGT6GV.js → 74CVYM72.js} +2 -2
  67. package/dist/cdn/{PJPP6LOS.js → 7EHOFQ2P.js} +2 -2
  68. package/dist/cdn/{24EIZVUM.js → 7KSFIRXB.js} +2 -2
  69. package/dist/cdn/{STOGCXJH.js → AHCXG7XF.js} +2 -2
  70. package/dist/cdn/{VLPELJUS.js → AOVJ34QE.js} +2 -2
  71. package/dist/cdn/{3KNLFIM3.js → APFZY4PI.js} +2 -2
  72. package/dist/cdn/{KBSXHSBX.js → AVRS6UCQ.js} +2 -2
  73. package/dist/cdn/{YOW3YKWR.js → AVZ5Y6BK.js} +2 -2
  74. package/dist/cdn/{477I66FH.js → AXTQU5YL.js} +11 -11
  75. package/dist/cdn/BBPD2AS7.js +2 -0
  76. package/dist/cdn/{HV7MVIQV.js → BFZ5S7NF.js} +2 -2
  77. package/dist/cdn/{HMMYCSOK.js → BL273EGZ.js} +2 -2
  78. package/dist/cdn/C7JPWFZE.js +2 -0
  79. package/dist/cdn/{KKCLHXHG.js → CCC6LBMY.js} +1 -1
  80. package/dist/cdn/{NNPA3NLK.js → CEKOEHB3.js} +2 -2
  81. package/dist/cdn/{W54XYT2A.js → CFAC4FN3.js} +2 -2
  82. package/dist/cdn/{53KIFJFA.js → COH3QXWG.js} +2 -2
  83. package/dist/cdn/{CX2HJ67C.js → DB2TFPIO.js} +2 -2
  84. package/dist/cdn/{EYGZJKVD.js → DE26DAW5.js} +2 -2
  85. package/dist/cdn/DG27JEYG.js +50 -0
  86. package/dist/cdn/DKA6PSYN.js +2 -0
  87. package/dist/cdn/DWH23NJN.js +2 -0
  88. package/dist/cdn/EDXTPEEU.js +2 -0
  89. package/dist/cdn/{6KWGSXIN.js → ENM3L4AC.js} +2 -2
  90. package/dist/cdn/{XV7RMYLR.js → EVMIYZWD.js} +2 -2
  91. package/dist/cdn/{FHBRXZLV.js → EYOWRGDP.js} +2 -2
  92. package/dist/cdn/{45BDE3MG.js → EYY367WR.js} +2 -2
  93. package/dist/cdn/{2UJPYWWZ.js → F3CSORDI.js} +2 -2
  94. package/dist/cdn/{27CK3JHY.js → F5NIRETW.js} +2 -2
  95. package/dist/cdn/{TFAJNKBC.js → FCI6M62J.js} +2 -2
  96. package/dist/cdn/{V4PJMCJZ.js → FDOMMK2M.js} +1 -1
  97. package/dist/cdn/{4OI4QEV7.js → FS7GXTTQ.js} +2 -2
  98. package/dist/cdn/{IHUWQOMK.js → FYZATVB3.js} +2 -2
  99. package/dist/cdn/{3PPXAIRE.js → H6P3WP5D.js} +2 -2
  100. package/dist/cdn/HHP5YLUI.js +2 -0
  101. package/dist/cdn/HIAQARIQ.js +2 -0
  102. package/dist/cdn/HMIDFTEI.js +2 -0
  103. package/dist/cdn/{4CFCV47G.js → HMNBUGH2.js} +2 -2
  104. package/dist/cdn/HR6GWPKX.js +2 -0
  105. package/dist/cdn/{V266DJ5V.js → ICBIUFK7.js} +2 -2
  106. package/dist/cdn/{BTOBEN7Q.js → IH26MIYY.js} +2 -2
  107. package/dist/cdn/{QAX6UF4L.js → IHP25JWI.js} +2 -2
  108. package/dist/cdn/{M2U456J5.js → IYLFJCJ2.js} +4 -4
  109. package/dist/cdn/{JMXXRRKQ.js → J6A4AS7E.js} +2 -2
  110. package/dist/cdn/{QTEPFTAU.js → JEBRN3EU.js} +2 -2
  111. package/dist/cdn/{G24MNC7D.js → JICNSK6Y.js} +2 -2
  112. package/dist/cdn/JQYLMTDP.js +2 -0
  113. package/dist/cdn/{275FFTBE.js → K5JVB6FU.js} +2 -2
  114. package/dist/cdn/K7XWGSLN.js +2 -0
  115. package/dist/cdn/{M3KKORBG.js → K7YQIJFT.js} +2 -2
  116. package/dist/cdn/KH4V4I3W.js +2 -0
  117. package/dist/cdn/KMLJS2VW.js +2 -0
  118. package/dist/cdn/{HNTSDY3J.js → LAVFUDUG.js} +2 -2
  119. package/dist/cdn/{LL324IL6.js → LFQLCCJJ.js} +2 -2
  120. package/dist/cdn/{L3BTURBA.js → LK7ZIQW6.js} +2 -2
  121. package/dist/cdn/{ZJWR4W2S.js → LOQ2PKV5.js} +58 -58
  122. package/dist/cdn/{X42ACC66.js → LXPGQNXQ.js} +2 -2
  123. package/dist/cdn/{TXZQZR3I.js → MJSIYEWN.js} +2 -2
  124. package/dist/cdn/{CSE6BHOJ.js → MWYBF3F3.js} +2 -2
  125. package/dist/cdn/{FDRAKF5D.js → MXTXJKFE.js} +2 -2
  126. package/dist/cdn/{7DOYUO7L.js → NEV6OZN3.js} +2 -2
  127. package/dist/cdn/{NBDOPGSN.js → O4NVW75A.js} +2 -2
  128. package/dist/cdn/{ZA7ZU2F7.js → OKVLGJAG.js} +2 -2
  129. package/dist/cdn/{SUC2MIGE.js → OMF6ITSG.js} +2 -2
  130. package/dist/cdn/{A6LBMS7A.js → ONQ6JSBJ.js} +1 -1
  131. package/dist/cdn/{CKUUYQLO.js → OZAZ277H.js} +2 -2
  132. package/dist/cdn/{XNUWVZN7.js → P4XZMBU5.js} +2 -2
  133. package/dist/cdn/{L2HLFWCV.js → POL6HKCG.js} +3 -3
  134. package/dist/cdn/{AP3KPOHN.js → POZYDAU2.js} +2 -2
  135. package/dist/cdn/{FTTLFIBV.js → PQ2DPOFM.js} +2 -2
  136. package/dist/cdn/{ZY3JQCZQ.js → QNXI3WOF.js} +36 -36
  137. package/dist/cdn/{4VBOTWC3.js → QRMRID2M.js} +2 -2
  138. package/dist/cdn/{TLPZELG3.js → R74ZHFA6.js} +1 -1
  139. package/dist/cdn/{OF3TAARW.js → RHYNE5OE.js} +1 -1
  140. package/dist/cdn/{4YOG5F3W.js → RLEHNAIA.js} +1 -1
  141. package/dist/cdn/RXF2NUOL.js +2 -0
  142. package/dist/cdn/{MZUDIQQH.js → SDWWUWAF.js} +2 -2
  143. package/dist/cdn/SHI76XUV.js +2 -0
  144. package/dist/cdn/SITY6L4S.js +2 -0
  145. package/dist/cdn/{RSM7MEVT.js → SLR75R32.js} +2 -2
  146. package/dist/cdn/STHBRTTD.js +2 -0
  147. package/dist/cdn/{7UBTNDV6.js → SXM4NUT5.js} +2 -2
  148. package/dist/cdn/{XVJFPZTW.js → SZRJTQ54.js} +2 -2
  149. package/dist/cdn/TO2NY7EA.js +2 -0
  150. package/dist/cdn/{4IWDBEMN.js → TPULIO6I.js} +2 -2
  151. package/dist/cdn/TVEEQSMF.js +2 -0
  152. package/dist/cdn/TWU3QXAS.js +2 -0
  153. package/dist/cdn/{EGRRZTF6.js → TYATJUNF.js} +2 -2
  154. package/dist/cdn/UCTC4JN4.js +3 -0
  155. package/dist/cdn/{HI3XKFHD.js → UDRKUVZP.js} +2 -2
  156. package/dist/cdn/{JYNHWJUZ.js → UHEYPSOR.js} +2 -2
  157. package/dist/cdn/{VGLBH473.js → UHICISBZ.js} +2 -2
  158. package/dist/cdn/UO5PBOQR.js +2 -0
  159. package/dist/cdn/{BVUCNXC5.js → UZLQALHY.js} +1 -1
  160. package/dist/cdn/{SNG3WODY.js → V6HOUZPZ.js} +2 -2
  161. package/dist/cdn/{V52GSTOC.js → V7Y22FRP.js} +2 -2
  162. package/dist/cdn/{I72ST4JR.js → VAXH6RUQ.js} +2 -2
  163. package/dist/cdn/{NV7CL4S3.js → VNLSYVPE.js} +2 -2
  164. package/dist/cdn/VR3CF3ZY.js +2 -0
  165. package/dist/cdn/{VK6CCPTG.js → VWP2B4LB.js} +2 -2
  166. package/dist/cdn/VXFQANGJ.js +2 -0
  167. package/dist/cdn/WKZHFSH3.js +2 -0
  168. package/dist/cdn/{OXC2WP7W.js → WSWB3B7B.js} +2 -2
  169. package/dist/cdn/{EK3PM4L5.js → WVP73XWD.js} +2 -2
  170. package/dist/cdn/{SJMAKF4P.js → WXQ26G5Q.js} +2 -2
  171. package/dist/cdn/{2F4TPWZQ.js → XQ3NBBQ3.js} +1 -1
  172. package/dist/cdn/{JUNMTIB3.js → XV3DHHYJ.js} +2 -2
  173. package/dist/cdn/{VXLKTQ36.js → YHWYTHID.js} +2 -2
  174. package/dist/cdn/{XOTPSCNF.js → YIZ7PR2G.js} +2 -2
  175. package/dist/cdn/{T6W6F4TF.js → Z5XQLSYH.js} +2 -2
  176. package/dist/cdn/{Y6CV2NZR.js → ZFOG3KXV.js} +2 -2
  177. package/dist/cdn/{FPH52WOH.js → ZU2FHVNK.js} +2 -2
  178. package/dist/cdn/agent-utils/index.js +2 -2
  179. package/dist/cdn/agent-utils/middlewares/humanInTheLoop.js +2 -3
  180. package/dist/cdn/agent-utils/middlewares/middleware.js +2 -2
  181. package/dist/cdn/agent-utils/middlewares/trace.js +2 -2
  182. package/dist/cdn/assets/assistant/t9n/messages.en.json +1 -1
  183. package/dist/cdn/index.js +2 -2
  184. package/dist/chunks/BaseWorkflow.js +1 -1
  185. package/dist/chunks/SKILL.js +1 -1
  186. package/dist/chunks/SKILL2.js +1 -1
  187. package/dist/chunks/SKILL3.js +1 -1
  188. package/dist/chunks/SKILL4.js +1 -1
  189. package/dist/chunks/adapter.js +1 -1
  190. package/dist/chunks/aiFactory.js +56 -50
  191. package/dist/chunks/arcgisKnowledgeGraph.js +2 -2
  192. package/dist/chunks/arcgisToolRegistry.js +1 -1
  193. package/dist/chunks/arcgis_knowledge_current_lc_context.js +1 -1
  194. package/dist/chunks/arcgis_knowledge_current_map_context.js +1 -1
  195. package/dist/chunks/arcgis_knowledge_cypher_query_prompt.js +1 -1
  196. package/dist/chunks/arcgis_knowledge_lucene_generation_prompt.js +1 -1
  197. package/dist/chunks/arcgis_knowledge_summarize_result_prompt.js +1 -1
  198. package/dist/chunks/arcgis_knowledge_tool_prompt.js +1 -1
  199. package/dist/chunks/baseAgentState.js +1 -1
  200. package/dist/chunks/converterUtils.js +1 -1
  201. package/dist/chunks/dataExplorationAgent.js +1 -1
  202. package/dist/chunks/data_explore_filter_prompt.js +1 -1
  203. package/dist/chunks/data_explore_query_prompt.js +1 -1
  204. package/dist/chunks/embeddings.worker.js +1 -1
  205. package/dist/chunks/fetchAgentContext.js +1 -1
  206. package/dist/chunks/fetchService.js +1 -1
  207. package/dist/chunks/fieldStatistics.js +1 -1
  208. package/dist/chunks/field_descriptions_prompt.js +1 -1
  209. package/dist/chunks/formatFeatureAttributes.js +1 -1
  210. package/dist/chunks/generateLayerDescriptions.js +60 -63
  211. package/dist/chunks/graph.js +1 -1
  212. package/dist/chunks/helpAgent.js +1 -1
  213. package/dist/chunks/help_prompt.js +1 -1
  214. package/dist/chunks/index.js +1 -1
  215. package/dist/chunks/intent_prompt.js +1 -1
  216. package/dist/chunks/layerStylingGraph.js +1 -1
  217. package/dist/chunks/layer_descriptions_prompt.js +1 -1
  218. package/dist/chunks/layer_styling_prompt.js +1 -1
  219. package/dist/chunks/mergeWhereClauses.js +1 -1
  220. package/dist/chunks/navigationAgent.js +1 -1
  221. package/dist/chunks/navigation_intent_prompt.js +1 -1
  222. package/dist/chunks/navigation_tool_prompt.js +1 -1
  223. package/dist/chunks/orchestrator.js +1 -1
  224. package/dist/chunks/requireAgentServices.js +1 -1
  225. package/dist/chunks/resolvePointGeometryFilter.js +1 -1
  226. package/dist/chunks/runtime.js +1 -1
  227. package/dist/chunks/slottableRequestUtils.js +1 -1
  228. package/dist/chunks/state.js +26 -26
  229. package/dist/chunks/summarize_query_response_prompt.js +1 -1
  230. package/dist/chunks/useT9n.js +1 -1
  231. package/dist/chunks/utils.js +1 -1
  232. package/dist/chunks/utils2.js +1 -1
  233. package/dist/chunks/utils3.js +1 -1
  234. package/dist/components/arcgis-assistant/customElement.d.ts +6 -0
  235. package/dist/components/arcgis-assistant/customElement.js +126 -114
  236. package/dist/components/arcgis-assistant-agent/customElement.js +362 -220
  237. package/dist/components/arcgis-assistant-chat/customElement.js +1 -1
  238. package/dist/components/arcgis-assistant-chat-entry/customElement.js +1 -1
  239. package/dist/components/arcgis-assistant-data-exploration-agent/customElement.js +1 -1
  240. package/dist/components/arcgis-assistant-help-agent/customElement.js +1 -1
  241. package/dist/components/arcgis-assistant-interrupt/customElement.js +1 -1
  242. package/dist/components/arcgis-assistant-interrupt-preview/customElement.js +1 -1
  243. package/dist/components/arcgis-assistant-knowledge-agent/customElement.js +1 -1
  244. package/dist/components/arcgis-assistant-layer-styling-agent/customElement.js +1 -1
  245. package/dist/components/arcgis-assistant-message/customElement.js +1 -1
  246. package/dist/components/arcgis-assistant-message-block/customElement.js +1 -1
  247. package/dist/components/arcgis-assistant-message-feedback/customElement.js +1 -1
  248. package/dist/components/arcgis-assistant-message-footer/customElement.js +1 -1
  249. package/dist/components/arcgis-assistant-message-loading/customElement.js +1 -1
  250. package/dist/components/arcgis-assistant-message-log/customElement.js +1 -1
  251. package/dist/components/arcgis-assistant-message-read-aloud/customElement.js +1 -1
  252. package/dist/components/arcgis-assistant-message-text/customElement.js +1 -1
  253. package/dist/components/arcgis-assistant-navigation-agent/customElement.js +1 -1
  254. package/dist/components/arcgis-assistant-speech-input/customElement.js +1 -1
  255. package/dist/components/arcgis-assistant-suggested-prompts/customElement.js +1 -1
  256. package/dist/components/arcgis-assistant-user-message/customElement.js +1 -1
  257. package/dist/docs/api.json +1 -1
  258. package/dist/docs/docs.json +1 -1
  259. package/dist/docs/web-types.json +1 -1
  260. package/dist/index.js +1 -1
  261. package/dist/loader.js +1 -1
  262. package/dist/utils/index.js +3 -3
  263. package/package.json +11 -11
  264. package/dist/cdn/25MBI4PD.js +0 -2
  265. package/dist/cdn/2LVYAXHG.js +0 -44
  266. package/dist/cdn/2WXXSZP5.js +0 -2
  267. package/dist/cdn/5X23DDDZ.js +0 -2
  268. package/dist/cdn/65LCK3GG.js +0 -3
  269. package/dist/cdn/AUCKEB52.js +0 -2
  270. package/dist/cdn/B3HXSEBN.js +0 -2
  271. package/dist/cdn/BTTCBEPW.js +0 -2
  272. package/dist/cdn/CAOMMQSY.js +0 -66
  273. package/dist/cdn/EXMEB4X2.js +0 -2
  274. package/dist/cdn/FLUI6GCU.js +0 -2
  275. package/dist/cdn/FRYS2PZJ.js +0 -2
  276. package/dist/cdn/FSLQCZRN.js +0 -2
  277. package/dist/cdn/HKIA5PWU.js +0 -2
  278. package/dist/cdn/I3SUE2TR.js +0 -2
  279. package/dist/cdn/KAX4A7SF.js +0 -2
  280. package/dist/cdn/LIRT72WY.js +0 -2
  281. package/dist/cdn/M5B6X46F.js +0 -2
  282. package/dist/cdn/NGR5NVZE.js +0 -2
  283. package/dist/cdn/PUZ6RAFQ.js +0 -2
  284. package/dist/cdn/ROS22KOA.js +0 -2
  285. package/dist/cdn/SBNNJ5WA.js +0 -2
  286. package/dist/cdn/SDX46GZY.js +0 -2
  287. package/dist/cdn/SI22EJLC.js +0 -2
  288. package/dist/cdn/SXYKNDOF.js +0 -2
  289. package/dist/cdn/SZ2L5556.js +0 -2
  290. package/dist/cdn/UGIHS7OA.js +0 -2
  291. package/dist/cdn/VT5EWFH7.js +0 -2
  292. package/dist/cdn/XZF7Y6B2.js +0 -2
  293. package/dist/cdn/Y4ZOB6UH.js +0 -2
  294. package/dist/cdn/YIXASZUW.js +0 -2
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = '---\nname: query\ndescription: Answers questions about feature-layer data, including counts, matching records, field values, aggregates, rankings, and spatially constrained results. Use when the user asks to inspect or summarize map data.\nallowed-tools: findRelevantLayers findRelevantFields getAttribute getStatistics getTopFeatures queryFeatures\n---\n\n# Query\n\n- When the task refers to an address, place, or location resolved by an earlier agent, call `listSharedResources` with `point` as the requested kind. If a resource description clearly matches the location, pass its exact ID as `geometryFilter.sharedResourceId` and use `where: "1=1"` unless the user requests an additional attribute filter. If no resource clearly matches a referential location such as "this location," state that the spatial anchor is unavailable and do not guess coordinates.\n- Start with `findRelevantLayers` unless a previous tool result from this run explicitly identifies the relevant layer ID. Use the assigned task as the semantic query.\n- If no relevant layers are returned, explain that no matching map layer was found and stop. Never invent a layer ID.\n- Before querying, call `findRelevantFields` with only relevant layer IDs. Use only the exact field names and categorical values returned by `findRelevantFields`.\n- Set `includeSummaryStatistics` to true when the requested answer directly depends on whole-layer numeric summary statistics such as average, minimum, maximum, sum, variance, standard deviation, null count, or range. Otherwise leave it false and use `getStatistics` later if analysis requires statistics under an attribute or spatial constraint.\n- Use statistics returned by `findRelevantFields` when they directly answer an unfiltered whole-layer question. Use `getStatistics` when a where clause or spatial constraint must be applied.\n- Use `queryFeatures` to count, find, or list matching features. It is the default query tool.\n- Use `getTopFeatures` for highest, lowest, first, last, or top-N records ranked by an existing field.\n- Use `getAttribute` only when retrieving a particular attribute from a specifically identified feature.\n- Use real field names rather than aliases in SQL-92 where clauses. Use `1=1` when no attribute filter is requested.\n- Set `useCurrentExtent` only when the user explicitly refers to the current view or visible map area.\n- If the request asks to visually show, display, highlight, map, filter, reveal, emphasize, hide, include, or exclude matching features, preserve the information needed for a visual operation in the working context: layer ID, where clause, geometry filter, `useCurrentExtent`, object IDs when available, and count. Preserve the exact values returned or used by tools so another skill can reuse them without repeating discovery.\n- Base the final answer only on returned tool data. State failures or empty results directly and do not fabricate values.\n';
3
3
  export {
4
4
  e as default
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = '---\nname: filter\ndescription: Changes feature emphasis on the map by including, excluding, highlighting, dimming, or clearing filtered features. Use when the user asks to visually filter feature-layer data.\nallowed-tools: findRelevantLayers findRelevantFields setFeatureEffect resetMap clearFilters\n---\n\n# Filter\n\n- Use `clearFilters` when the user asks only to remove feature filters or effects. Use `resetMap` only when the user asks to reset the broader map state.\n- Reuse a preceding query result from this run whenever it contains the layer ID and filtering criteria needed for the visual operation. Do not repeat layer or field discovery in that case.\n- A preceding query result may provide the layer ID, where clause, geometry filter, `useCurrentExtent`, object IDs, and count. Preserve and reuse those values rather than reconstructing them.\n- If no usable preceding query geometry exists and the task refers to an address, place, or location resolved by an earlier agent, call `listSharedResources` with `point` as the requested kind. If a resource description clearly matches the location, pass its exact ID as `geometryFilter.sharedResourceId` and use `where: "1=1"` unless the user requests an additional attribute filter. If no resource clearly matches a referential location such as "this location," state that the spatial anchor is unavailable and do not guess coordinates.\n- If no usable preceding query result exists, start with `findRelevantLayers`. Use the assigned task as the semantic query. If no relevant layers are returned, explain that no matching map layer was found and stop. Never invent a layer ID.\n- When discovery is required, call `findRelevantFields` with only relevant layer IDs before constructing a filter. Use only the exact field names and categorical values returned by `findRelevantFields`.\n- Leave `includeSummaryStatistics` false unless the filter criteria explicitly depend on a requested numeric summary.\n- Use real field names rather than aliases in SQL-92 where clauses. Use `1=1` when no attribute filter is requested.\n- For highlight, show, include, exclude, or other visual-filter requests with feature criteria, call `setFeatureEffect` using the same layer ID, where clause, geometry filter, and `useCurrentExtent` value determined by the preceding query or discovery steps.\n- If a preceding query returned object IDs for ranked, top-N, or otherwise selected records, pass those object IDs to `setFeatureEffect` instead of rebuilding the selection using only a where clause.\n- Prefer the default feature effects unless the user explicitly requests a particular visual treatment.\n- Set `useCurrentExtent` only when the user explicitly refers to the current view or visible map area.\n- When available, use the preceding query result for feature counts or attribute details in the final response.\n- Report the `setFeatureEffect` outcome faithfully. Do not claim that a map effect was applied when the tool failed or no matching layer or field was found.\n';
3
3
  export {
4
4
  e as default
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `---
3
3
  name: help
4
4
  description: Answers questions about the current map, its layers and fields, available assistant capabilities, unsupported map actions, and unrelated requests that need a map-focused redirect.
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = "---\nname: navigation\ndescription: Navigates the map to addresses, bookmarks, layers, matching features, extents, scales, zoom levels, and viewpoints using live map context and semantic layer and field search.\nallowed-tools: findRelevantLayers findRelevantFields goToAddress goToBookmark goToFeatures goToFullExtent goToHomeExtent goToLayer goToScale goToViewpoint goToZoom\n---\n\n# Navigation\n\n- Complete exactly one map-changing navigation action for the assigned task. Semantic search calls do not count as navigation actions.\n- Use the runtime context as the authoritative source for the current zoom level and exact available bookmark names.\n- Prefer an available bookmark over a feature or address when it clearly matches the requested place. Prefer a matching map feature over geocoding when the request identifies a layer or feature. Otherwise use `goToAddress` for an address or place name.\n- Use `goToZoom`, `goToScale`, or `goToViewpoint` directly for explicit numeric requests. For a relative zoom request, calculate one level above or below the current zoom from the runtime context and keep it within the tool's supported range.\n- Use `goToHomeExtent` to reset the map and `goToFullExtent` for the full-world extent. These actions do not require semantic search.\n- Before `goToLayer`, call `findRelevantLayers` with a concise query describing the requested layer. Use only a returned `layerId`. If there is no clear match, do not invent an ID or navigate.\n- Before `goToFeatures`, call `findRelevantLayers`, then call `findRelevantFields` with the relevant returned layer IDs and a query describing the requested condition. Use only the exact layer IDs returned by `findRelevantLayers`. Use only the exact field names and categorical values returned by `findRelevantFields`.\n- Build `goToFeatures` filters with valid ArcGIS SQL-92. Use field names rather than aliases, use coded-value domain codes when supplied, quote string values, and use `1=1` when all features in the selected layer are requested.\n- Do not call `findRelevantFields` for layer-only navigation or direct address, bookmark, extent, scale, viewpoint, or zoom navigation.\n- If required map context or semantic search results are missing or ambiguous, explain what is missing instead of guessing.\n- Report the navigation tool result faithfully. Never claim the map moved when the tool failed.\n";
3
3
  export {
4
4
  e as default
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  import H from "@arcgis/core/identity/IdentityManager.js";
3
3
  import P from "@arcgis/core/portal/Portal.js";
4
4
  import J from "@arcgis/core/request.js";
@@ -1,40 +1,40 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
2
- import { ChatOpenAI as E, OpenAIEmbeddings as U } from "@langchain/openai";
3
- import p from "@arcgis/core/portal/Portal.js";
4
- import h from "@arcgis/core/request.js";
5
- import b from "@arcgis/core/identity/IdentityManager.js";
6
- import { generateGuid as I } from "@arcgis/toolkit/string";
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
+ import { ChatOpenAI as b, OpenAIEmbeddings as U } from "@langchain/openai";
3
+ import h from "@arcgis/core/portal/Portal.js";
4
+ import y from "@arcgis/core/request.js";
5
+ import I from "@arcgis/core/identity/IdentityManager.js";
6
+ import { generateGuid as R } from "@arcgis/toolkit/string";
7
7
  import q from "@arcgis/core/config.js";
8
- const y = {
8
+ const w = {
9
9
  advanced: "gpt-5.6-sol",
10
10
  default: "gpt-5.6-terra",
11
11
  fast: "gpt-5.6-luna"
12
- }, w = {
12
+ }, S = {
13
13
  default: "text-embedding-ada-002"
14
- }, f = /* @__PURE__ */ new Map();
14
+ }, g = /* @__PURE__ */ new Map();
15
15
  let i = null;
16
- const R = () => {
17
- const t = p.getDefault().helperServices;
16
+ const C = () => {
17
+ const t = h.getDefault().helperServices;
18
18
  if (!t?.aiModels?.url)
19
19
  throw new Error("AI Models Service URL is not defined in the portal's helper services.");
20
20
  return t.aiModels.url;
21
- }, S = async (e) => {
22
- const t = R();
23
- f.size === 0 && (i || (i = (async () => {
21
+ }, v = async (e) => {
22
+ const t = C();
23
+ g.size === 0 && (i || (i = (async () => {
24
24
  try {
25
- (await h(`${t}/models`)).data.models.forEach((s) => f.set(s.name, s));
26
- } catch (r) {
27
- throw i = null, r;
25
+ (await y(`${t}/models`)).data.models.forEach((a) => g.set(a.name, a));
26
+ } catch (n) {
27
+ throw i = null, n;
28
28
  }
29
29
  })()), await i);
30
- const o = f.get(e);
31
- if (!o)
30
+ const r = g.get(e);
31
+ if (!r)
32
32
  throw new Error(`Model '${e}' is not available in the discovery service.`);
33
- return o.endpoint;
34
- }, C = async (e = "default") => await S(y[e]), A = async (e = "default") => await S(w[e]), k = (e) => typeof e == "string" && e.length > 0 ? e : void 0, D = () => I(), F = (e) => typeof e != "string" || e.trim().length === 0 ? "MapsSDK" : `MapsSDK - ${e.trim()}`, K = (e) => {
33
+ return r.endpoint;
34
+ }, A = async (e = "default") => await v(w[e]), k = async (e = "default") => await v(S[e]), z = (e) => typeof e == "string" && e.length > 0 ? e : void 0, D = () => R(), F = (e) => typeof e != "string" || e.trim().length === 0 ? "MapsSDK" : `MapsSDK - ${e.trim()}`, K = (e) => {
35
35
  const t = e?.configurable;
36
36
  return {
37
- conversationId: k(t?.thread_id),
37
+ conversationId: z(t?.thread_id),
38
38
  abortSignal: e?.signal,
39
39
  requestId: D(),
40
40
  requestSource: F(q.applicationName)
@@ -45,50 +45,56 @@ const R = () => {
45
45
  if (e instanceof URLSearchParams)
46
46
  return e.toString();
47
47
  throw new TypeError(`Unsupported request body type: ${Object.prototype.toString.call(e)}`);
48
- }, v = async ({ config: e }) => {
49
- const t = p.getDefault(), o = await b.getCredential(`${t.url}/sharing`);
50
- return async (r, n) => {
51
- const { conversationId: s, abortSignal: c, requestId: g, requestSource: l } = K(e), a = new Headers(n?.headers);
52
- for (const m of [...a.keys()]) {
53
- const u = m.toLowerCase();
54
- (u === "authorization" || u === "api-key" || u.startsWith("x-stainless-")) && a.delete(m);
48
+ }, E = async ({
49
+ config: e,
50
+ withCredentials: t
51
+ }) => {
52
+ const r = h.getDefault(), n = await I.getCredential(`${r.url}/sharing`);
53
+ return async (o, a) => {
54
+ const { conversationId: c, abortSignal: l, requestId: p, requestSource: d } = K(e), s = new Headers(a?.headers);
55
+ for (const m of [...s.keys()]) {
56
+ const f = m.toLowerCase();
57
+ (f === "authorization" || f === "api-key" || f.startsWith("x-stainless-")) && s.delete(m);
55
58
  }
56
- const d = o?.token;
57
- d && d.length > 0 && a.set("X-Esri-Authorization", `Bearer ${d}`), t.isPortal || (l && l.length > 0 && a.set("X-Esri-Request-Source", l), s && s.length > 0 && a.set("X-Esri-Conversation-Id", s), g.length > 0 && a.set("X-Esri-Request-Id", g));
58
- const M = c && n?.signal ? AbortSignal.any([c, n.signal]) : n?.signal ?? c;
59
- return (await h(r instanceof Request ? r.url : r.toString(), {
60
- body: L(n?.body),
61
- headers: Object.fromEntries(a),
59
+ const u = n?.token;
60
+ u && u.length > 0 && s.set("X-Esri-Authorization", `Bearer ${u}`), r.isPortal || (d && d.length > 0 && s.set("X-Esri-Request-Source", d), c && c.length > 0 && s.set("X-Esri-Conversation-Id", c), p.length > 0 && s.set("X-Esri-Request-Id", p));
61
+ const M = l && a?.signal ? AbortSignal.any([l, a.signal]) : a?.signal ?? l;
62
+ return (await y(o instanceof Request ? o.url : o.toString(), {
63
+ body: L(a?.body),
64
+ headers: Object.fromEntries(s),
62
65
  responseType: "native",
66
+ withCredentials: t,
63
67
  signal: M
64
68
  })).data;
65
69
  };
66
- }, B = async (e = {}) => {
67
- const { modelTier: t = "default", config: o } = e, r = y[t], n = await C(t);
68
- return new E({
69
- modelName: r,
70
+ }, j = async (e = {}) => {
71
+ const { modelTier: t = "default", config: r } = e, n = w[t], o = await A(t);
72
+ return new b({
73
+ modelName: n,
70
74
  apiKey: "dummy-key",
75
+ useResponsesApi: !0,
76
+ zdrEnabled: !0,
71
77
  configuration: {
72
- baseURL: n,
73
- fetch: await v({ config: o })
78
+ baseURL: o,
79
+ fetch: await E({ config: r, withCredentials: !0 })
74
80
  }
75
81
  });
76
- }, j = async (e = {}) => {
77
- const { tier: t = "default", config: o } = e, r = w[t], n = await A(t);
82
+ }, H = async (e = {}) => {
83
+ const { tier: t = "default", config: r } = e, n = S[t], o = await k(t);
78
84
  return new U({
79
- modelName: r,
85
+ modelName: n,
80
86
  apiKey: "dummy-key",
81
87
  configuration: {
82
- baseURL: n,
83
- fetch: await v({ config: o })
88
+ baseURL: o,
89
+ fetch: await E({ config: r })
84
90
  },
85
91
  batchSize: 2048,
86
92
  maxConcurrency: 10
87
93
  });
88
94
  };
89
95
  export {
90
- w as E,
91
- j as a,
92
- B as c,
93
- A as g
96
+ S as E,
97
+ H as a,
98
+ j as c,
99
+ k as g
94
100
  };
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  import { StateGraph as x, START as k, END as c, Command as b } from "@langchain/langgraph/web";
3
3
  import { a as K, c as _, g as T, b as A, d as S, s as M, q as v, e as u, f as q, t as g, h as C, G as E, i as m } from "./adapter.js";
4
4
  import "@arcgis/core/identity/IdentityManager.js";
@@ -38,7 +38,7 @@ async function D(e, t) {
38
38
  inputVariables: n,
39
39
  tools: w,
40
40
  config: t
41
- }), l = (r.tool_calls?.length ?? 0) > 0, a = typeof r.text == "string" ? r.text.trim() : "", i = a.length > 0, d = r.content.toString();
41
+ }), l = (r.tool_calls?.length ?? 0) > 0, a = typeof r.text == "string" ? r.text.trim() : "", i = a.length > 0, d = r.text;
42
42
  return !l && (s === "map" || s === "knowledgeGraph") ? {
43
43
  ...e,
44
44
  arcgisKnowledgeMessages: [...e.arcgisKnowledgeMessages, r],
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const a = /* @__PURE__ */ new Map([
3
3
  [
4
4
  "clearFilters",
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `## Membership Bind Parameters
3
3
 
4
4
  The current link chart contains a subset of entities and relationships from the database. Their membership is available to Cypher queries as lists of string identifiers through these bind parameters:
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `## Membership Bind Parameters
3
3
 
4
4
  The current map contains a subset of entities and relationships from the database. Their membership is available to Cypher queries as lists of string identifiers through these bind parameters:
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `# ArcGIS Knowledge Graph Cypher Rules
3
3
 
4
4
  ## GOAL
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `## ArcgisKnowledge Agent - Lucene Generation for Graph Search
3
3
 
4
4
  You are an assistant that generates a lucene query for graph query searching.
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const n = `# ArcGIS Knowledge Agent — Action Summary
3
3
 
4
4
  You are a Knowledge Graph assistant that has executed tool calls to answer a user request.
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `# ArcgisKnowledge Tool Instructions
3
3
 
4
4
  You are an assistant that helps users answer questions and perform operations on their knowledge graph, map or link chart. You have been assigned the task below, which must be achieved by calling a single tool.
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  import { Annotation as r } from "@langchain/langgraph/web";
3
3
  const a = (e, t) => t, c = (e, t) => ({
4
4
  ...e,
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  import w from "@esri/arcgis-html-sanitizer";
3
3
  import { marked as S } from "marked";
4
4
  S.use({
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  import { createSkillAgent as e } from "../agents/runtime/skill/createSkillAgent.js";
3
3
  const t = [
4
4
  async () => (await import("./SKILL.js")).default,
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `# ArcGIS Online Map Viewer — Layer Filter Tool Calling Assistant
3
3
 
4
4
  You are an assistant that helps manage layer filters and visual effects for **ArcGIS Online Map Viewer** by selecting and calling the appropriate tool.
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `# ArcGIS JavaScript SDK FeatureLayerView Query Assistant
3
3
 
4
4
  You are a GIS assistant that generates query parameters for the ArcGIS JavaScript SDK FeatureLayerView \`queryFeatures()\` method.
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const o = `(function(){"use strict";const h=(a,r)=>{if(a.length!==r.length)throw new Error("Vectors must be the same length");let c=0,t=0,e=0;for(let n=0;n<a.length;++n){const s=a[n],l=r[n];c+=s*l,t+=s*s,e+=l*l}const i=Math.sqrt(t*e);if(i===0)return 0;const m=c/i;return Math.max(-1,Math.min(1,m))},f=(a,r,c=.6)=>{const t=[],e=[...a];for(;t.length<r&&e.length>0;){let i=-1,m=-1/0;for(let n=0;n<e.length;n++){const s=e[n].score,l=t.length===0?0:Math.max(...t.map(o=>h(e[n].vector,o.vector))),d=c*s-(1-c)*l;d>m&&(m=d,i=n)}t.push(e[i]),e.splice(i,1)}return t.map(({name:i,score:m})=>({name:i,score:m}))};let p=[];const u=new Map,v=12,y=10,M=a=>{p=a.layers.map(r=>({id:r.id,vector:r.vector}))},E=a=>{u.clear();for(const r of a.layers){const c=r.fields.map(t=>({name:t.name,vector:t.vector}));u.set(r.id,c)}};globalThis.addEventListener("message",a=>{(async()=>{const{type:r,webmapEmbeddings:c,layerIdForFieldsSearch:t=[],requestId:e,precomputedEmbedding:i,minScore:m=0,topResults:n=v}=a.data;switch(r){case"generateEmbeddings":{c&&(M(c),E(c)),globalThis.postMessage("completed");break}case"layerSearch":{if(p.length>0)try{const s=p.map(o=>({id:o.id,vector:o.vector,score:h(i,o.vector)})),d=f(s.map(o=>({name:o.id,vector:o.vector,score:o.score})),y).map(({name:o,score:b})=>({id:o,score:b}));globalThis.postMessage({requestId:e,results:d})}catch(s){globalThis.postMessage({requestId:e,results:[],error:s instanceof Error?s.message:"Calculation error"})}else globalThis.postMessage({requestId:e,results:[],error:"Layer embeddings not initialized"});break}case"fieldSearch":{if(t.length>0)try{const s=t.map(l=>{const d=u.get(l);if(!d)return{layerId:l,results:[]};const o=d.map(g=>({name:g.name,vector:g.vector,score:h(i,g.vector)})).filter(({score:g})=>g>=m),b=f(o,n);return{layerId:l,results:b}});globalThis.postMessage({requestId:e,results:s})}catch(s){globalThis.postMessage({requestId:e,results:[],error:s instanceof Error?s.message:"Field search calculation error"})}break}default:console.warn("Unknown message type:",r)}})()})})();
3
3
  `, s = typeof self < "u" && self.Blob && new Blob(["(self.URL || self.webkitURL).revokeObjectURL(self.location.href);", o], { type: "text/javascript;charset=utf-8" });
4
4
  function a(r) {
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  function c(e, o) {
3
3
  const t = e?.configurable?.context;
4
4
  if (!t || typeof t != "object")
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const i = (s, e) => {
3
3
  const r = s?.configurable?.services?.[e];
4
4
  if (r == null)
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  import v from "@arcgis/core/smartMapping/statistics/summaryStatistics.js";
3
3
  import L from "@arcgis/core/smartMapping/statistics/uniqueValues.js";
4
4
  const $ = 10, b = ["string", "small-integer", "integer"], w = async (u, e, { includeSummaryStatistics: d = !0, includeUniqueValues: y = !0 } = {}) => {
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  const e = `You are a knowledgeable GIS expert.
3
3
 
4
4
  You are given a Feature Service description and title.
@@ -1,4 +1,4 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
2
  import { formatDateOnly as F, convertDateFormatToIntlOptions as m, formatTimeOnly as T, formatDate as p } from "@arcgis/core/intl.js";
3
3
  const w = /* @__PURE__ */ new Set([
4
4
  "date",
@@ -1,55 +1,55 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/1.0/LICENSE.txt */
2
- import { Annotation as m } from "@langchain/langgraph/web";
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
+ import { Annotation as p } from "@langchain/langgraph/web";
3
3
  import { b as j, r as T, m as P, c as q } from "./baseAgentState.js";
4
- import p, { z as s } from "zod";
5
- import { ChatPromptTemplate as E, SystemMessagePromptTemplate as N } from "@langchain/core/prompts";
4
+ import l, { z as s } from "zod";
5
+ import { ChatPromptTemplate as S, SystemMessagePromptTemplate as N } from "@langchain/core/prompts";
6
6
  import { s as g } from "./index.js";
7
7
  import { AIMessage as O, isAIMessage as $, isToolMessage as U } from "@langchain/core/messages";
8
8
  import { createAgent as V, summarizationMiddleware as L, modelCallLimitMiddleware as z } from "langchain";
9
- import { c as h, E as J } from "./aiFactory.js";
10
- const ye = m.Root({
11
- agentExecutionContext: m({
9
+ import { c as y, E as W } from "./aiFactory.js";
10
+ const he = p.Root({
11
+ agentExecutionContext: p({
12
12
  default: q,
13
13
  reducer: P
14
14
  }),
15
- currentIntent: m({
15
+ currentIntent: p({
16
16
  default: () => "none",
17
17
  reducer: T
18
18
  }),
19
- routing: m({
19
+ routing: p({
20
20
  default: () => ({ mode: "auto" }),
21
21
  reducer: T
22
22
  }),
23
- lastExecutedAgent: m({
23
+ lastExecutedAgent: p({
24
24
  default: () => "",
25
25
  reducer: T
26
26
  }),
27
- requiresFollowUp: m({
27
+ requiresFollowUp: p({
28
28
  default: () => !0,
29
29
  reducer: T
30
30
  }),
31
- stepCount: m({
31
+ stepCount: p({
32
32
  default: () => 0,
33
33
  reducer: (e, t) => t ?? e + 1
34
34
  }),
35
- finalOutputMessage: m({
35
+ finalOutputMessage: p({
36
36
  default: () => "",
37
37
  reducer: j
38
38
  })
39
- }), W = (e) => {
39
+ }), B = (e) => {
40
40
  if (!e || typeof e != "object" || !("services" in e))
41
41
  return !1;
42
42
  const t = e.services;
43
43
  return !!t && typeof t == "object" && "agentRegistry" in t;
44
- }, B = (e) => {
44
+ }, G = (e) => {
45
45
  const t = e?.configurable;
46
- return W(t) ? t : void 0;
47
- }, G = (e, t, i) => {
46
+ return B(t) ? t : void 0;
47
+ }, H = (e, t, i) => {
48
48
  const n = e[t];
49
49
  return n ? typeof n == "function" ? n() : Promise.resolve(n) : new Promise((r, o) => {
50
50
  (typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(o.bind(null, /* @__PURE__ */ new Error("Unknown variable dynamic import: " + t + (t.split("/").length !== i ? ". Note that variables only represent file names one level deep." : ""))));
51
51
  });
52
- }, v = async (e) => (await G(/* @__PURE__ */ Object.assign({ "./field_descriptions_prompt.md": () => import("./field_descriptions_prompt.js"), "./intent_prompt.md": () => import("./intent_prompt.js"), "./layer_descriptions_prompt.md": () => import("./layer_descriptions_prompt.js") }), `./${e}.md`, 2)).default, H = async (e) => {
52
+ }, v = async (e) => (await H(/* @__PURE__ */ Object.assign({ "./field_descriptions_prompt.md": () => import("./field_descriptions_prompt.js"), "./intent_prompt.md": () => import("./intent_prompt.js"), "./layer_descriptions_prompt.md": () => import("./layer_descriptions_prompt.js") }), `./${e}.md`, 2)).default, J = async (e) => {
53
53
  const { agent: t, messages: i, config: n } = e;
54
54
  return { structuredResponse: (await t.invoke(
55
55
  {
@@ -70,8 +70,8 @@ const I = (e) => JSON.stringify(e, null, 2), Q = (e) => {
70
70
  assignedTask: s.string().nullable(),
71
71
  requiresFollowUp: s.boolean()
72
72
  });
73
- }, he = async (e, t) => {
74
- const i = B(t);
73
+ }, ye = async (e, t) => {
74
+ const i = G(t);
75
75
  if (t?.signal?.aborted)
76
76
  return await g({ text: "Run cancelled; skipping intent routing" }, t), {
77
77
  ...e,
@@ -92,24 +92,24 @@ const I = (e) => JSON.stringify(e, null, 2), Q = (e) => {
92
92
  currentIntent: "none",
93
93
  finalOutputMessage: "No agents registered; skipping intent detection."
94
94
  };
95
- const a = await v("intent_prompt"), c = I(o), l = Q(o), d = {
95
+ const a = await v("intent_prompt"), c = I(o), m = Q(o), d = {
96
96
  registeredAgents: c,
97
97
  priorSteps: I(e.agentExecutionContext.priorSteps),
98
98
  userRequest: e.agentExecutionContext.userRequest
99
- }, k = await E.fromTemplate(a).format(d), D = V({
100
- model: await h({
99
+ }, k = await S.fromTemplate(a).format(d), D = V({
100
+ model: await y({
101
101
  modelTier: "fast",
102
102
  config: t
103
103
  }),
104
104
  tools: [],
105
105
  systemPrompt: k,
106
- responseFormat: l,
106
+ responseFormat: m,
107
107
  middleware: [
108
108
  // Preserve recent conversation context while summarizing older messages
109
109
  // to control token usage without losing important intent signals.
110
110
  // The trigger and keep parameters can be tuned based on token limits and behavior.
111
111
  L({
112
- model: await h({
112
+ model: await y({
113
113
  modelTier: "fast",
114
114
  config: t
115
115
  }),
@@ -120,11 +120,11 @@ const I = (e) => JSON.stringify(e, null, 2), Q = (e) => {
120
120
  // 1 usual LLM call and 1 optional summarization call.
121
121
  z({ runLimit: 2 })
122
122
  ]
123
- }), { structuredResponse: R } = await H({
123
+ }), { structuredResponse: R } = await J({
124
124
  agent: D,
125
125
  messages: e.agentExecutionContext.messages,
126
126
  config: t
127
- }), f = l.parse(
127
+ }), f = m.parse(
128
128
  R ?? { intent: null, assignedTask: null, requiresFollowUp: !1 }
129
129
  ), x = f.intent ?? "none", F = {
130
130
  ...e,
@@ -171,7 +171,7 @@ Requires Follow-Up: ${f.requiresFollowUp}`
171
171
  } catch (n) {
172
172
  throw await g({ text: "Error during intent detection" }, t), new Error(`Error during intent detection: ${n instanceof Error ? n.message : String(n)}`);
173
173
  }
174
- }, X = "0.1", y = 1536, Y = "openai", Z = J.default, ee = `Name: {name}
174
+ }, X = "0.1", h = 1536, Y = "openai", Z = W.default, ee = `Name: {name}
175
175
  Title: {title}
176
176
  Description: {description}`, te = `Name: {name}
177
177
  Alias: {alias}
@@ -181,7 +181,7 @@ Description: {description}`, we = s.object({
181
181
  embeddings: s.object({
182
182
  modelProvider: s.literal(Y),
183
183
  model: s.literal(Z),
184
- dimensions: s.literal(y),
184
+ dimensions: s.literal(h),
185
185
  templates: s.object({
186
186
  layer: s.string().default(ee),
187
187
  field: s.string().default(te)
@@ -193,16 +193,16 @@ Description: {description}`, we = s.object({
193
193
  name: s.string().min(1),
194
194
  title: s.string().catch(""),
195
195
  description: s.string().catch(""),
196
- vector: s.array(s.number()).length(y, {
197
- message: `Layer vector must be exactly ${y} dimensions`
196
+ vector: s.array(s.number()).length(h, {
197
+ message: `Layer vector must be exactly ${h} dimensions`
198
198
  }),
199
199
  fields: s.array(
200
200
  s.object({
201
201
  name: s.string().min(1),
202
202
  alias: s.string().catch(""),
203
203
  description: s.string().catch(""),
204
- vector: s.array(s.number()).length(y, {
205
- message: `Field vector must be exactly ${y} dimensions`
204
+ vector: s.array(s.number()).length(h, {
205
+ message: `Field vector must be exactly ${h} dimensions`
206
206
  })
207
207
  })
208
208
  )
@@ -226,9 +226,9 @@ Description: {description}`, we = s.object({
226
226
  });
227
227
  }, M = (e, t) => {
228
228
  const i = N.fromTemplate(e);
229
- return E.fromMessages([i, ...t]);
229
+ return S.fromMessages([i, ...t]);
230
230
  }, se = async (e) => {
231
- const { promptText: t, modelTier: i, messages: n, config: r } = e, o = M(t, n ?? []), a = await h({ modelTier: i, config: r });
231
+ const { promptText: t, modelTier: i, messages: n, config: r } = e, o = M(t, n ?? []), a = await y({ modelTier: i, config: r });
232
232
  return o.pipe(a);
233
233
  }, xe = async (e) => {
234
234
  const { promptText: t, modelTier: i = "default", messages: n, inputVariables: r, config: o } = e, c = await (await se({
@@ -237,31 +237,28 @@ Description: {description}`, we = s.object({
237
237
  messages: n,
238
238
  config: o
239
239
  })).invoke(r ?? {}, o);
240
- if (typeof c == "string")
241
- return c;
242
- const l = c.content;
243
- return typeof l == "string" ? l : JSON.stringify(l);
240
+ return typeof c == "string" ? c : c.text;
244
241
  }, A = async (e) => {
245
- const { promptText: t, modelTier: i = "default", messages: n, inputVariables: r, schema: o, config: a } = e, c = M(t, n ?? []), d = (await h({ modelTier: i, config: a })).withStructuredOutput(o);
242
+ const { promptText: t, modelTier: i = "default", messages: n, inputVariables: r, schema: o, config: a } = e, c = M(t, n ?? []), d = (await y({ modelTier: i, config: a })).withStructuredOutput(o);
246
243
  return await c.pipe(d).invoke(r ?? {}, a);
247
244
  }, Te = async (e) => {
248
- const { promptText: t, modelTier: i = "default", messages: n, inputVariables: r, tools: o, config: a } = e, c = o.length > 0 ? ne(n ?? []) : n ?? [], l = M(t, c), d = await h({ modelTier: i, config: a });
249
- return await l.pipe(d.bindTools(o)).invoke(r ?? {}, a);
250
- }, ie = p.object({
251
- name: p.string(),
252
- description: p.string(),
253
- valueType: p.string(),
254
- alias: p.string()
255
- }), oe = p.object({
256
- fields: p.array(ie)
245
+ const { promptText: t, modelTier: i = "default", messages: n, inputVariables: r, tools: o, config: a } = e, c = o.length > 0 ? ne(n ?? []) : n ?? [], m = M(t, c), d = await y({ modelTier: i, config: a });
246
+ return await m.pipe(d.bindTools(o)).invoke(r ?? {}, a);
247
+ }, ie = l.object({
248
+ name: l.string(),
249
+ description: l.string(),
250
+ valueType: l.string(),
251
+ alias: l.string()
252
+ }), oe = l.object({
253
+ fields: l.array(ie)
257
254
  }), C = (e, t) => e.getFieldAlias(t) ?? void 0, b = (e, t) => C(e, t.name) ?? t.alias ?? "", re = (e, t) => {
258
255
  const i = C(e, t.name);
259
256
  return !!(i && i !== (t.alias ?? ""));
260
257
  };
261
- function S(e, t) {
258
+ function E(e, t) {
262
259
  const i = /* @__PURE__ */ new Map();
263
260
  for (const n of e.fields) {
264
- const r = t.fields.find((l) => l.name === n.name), o = b(e, n), a = re(e, n), c = {
261
+ const r = t.fields.find((m) => m.name === n.name), o = b(e, n), a = re(e, n), c = {
265
262
  name: n.name,
266
263
  type: n.type,
267
264
  alias: a ? o : r?.alias ?? o,
@@ -275,12 +272,12 @@ function S(e, t) {
275
272
  }
276
273
  const be = async (e) => {
277
274
  const i = await v("field_descriptions_prompt"), n = e.fields.filter((a) => !(b(e, a) && a.description)).map((a) => {
278
- const { name: c, type: l, description: d } = a, w = b(e, a);
279
- return [`Name: ${c}`, `Type: ${l}`, `Alias: ${w}`, `Description: ${d ?? "N/A"}`].join(", ");
275
+ const { name: c, type: m, description: d } = a, w = b(e, a);
276
+ return [`Name: ${c}`, `Type: ${m}`, `Alias: ${w}`, `Description: ${d ?? "N/A"}`].join(", ");
280
277
  }).join(`
281
278
  `);
282
279
  if (n.length === 0)
283
- return S(e, { fields: [] });
280
+ return E(e, { fields: [] });
284
281
  const r = {
285
282
  existingItemTitle: e.portalItem?.title,
286
283
  existingItemDescription: e.portalItem?.description,
@@ -292,11 +289,11 @@ const be = async (e) => {
292
289
  schema: oe,
293
290
  inputVariables: r
294
291
  });
295
- return S(e, o);
296
- }, ae = p.object({
297
- title: p.string(),
298
- description: p.string(),
299
- name: p.string().nullable()
292
+ return E(e, o);
293
+ }, ae = l.object({
294
+ title: l.string(),
295
+ description: l.string(),
296
+ name: l.string().nullable()
300
297
  }), ve = async (e, t) => {
301
298
  const n = await v("layer_descriptions_prompt"), r = Array.from(t.values()), o = {
302
299
  fieldInformation: JSON.stringify(r, null, 2),
@@ -312,15 +309,15 @@ const be = async (e) => {
312
309
  }), name: e.title ?? null };
313
310
  };
314
311
  export {
315
- ye as D,
312
+ he as D,
316
313
  we as W,
317
314
  xe as a,
318
- he as b,
315
+ ye as b,
319
316
  be as c,
320
317
  ve as d,
321
- y as e,
318
+ h as e,
322
319
  te as f,
323
- B as g,
320
+ G as g,
324
321
  Y as h,
325
322
  Te as i,
326
323
  A as j,