@arcgis/ai-components 5.2.0-next.16 → 5.2.0-next.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent-utils/index.d.ts +78 -0
- package/dist/agent-utils/index.js +116 -97
- package/dist/agent-utils/types.d.ts +12 -12
- package/dist/cdn/27NEUQN3.js +2 -0
- package/dist/cdn/{IR7PTESF.js → 2NMR43NW.js} +1 -1
- package/dist/cdn/4I4MCV7V.js +71 -0
- package/dist/cdn/{P7DG5T3Z.js → 4RZPOYZ7.js} +1 -1
- package/dist/cdn/5SBLS4NW.js +2 -0
- package/dist/cdn/{BX7FSMUU.js → 6LZ6GOHF.js} +1 -1
- package/dist/cdn/{K3JCH4XW.js → C7E7MJSR.js} +1 -1
- package/dist/cdn/{JIWK6QK6.js → CIW3QMKV.js} +1 -1
- package/dist/cdn/{DHKUXLU3.js → CJIV4KJZ.js} +1 -1
- package/dist/cdn/CVHJMR5X.js +2 -0
- package/dist/cdn/ETD76QRC.js +14 -0
- package/dist/cdn/FC2ZX3SS.js +2 -0
- package/dist/cdn/{4UDYY3HL.js → HOCTVCHH.js} +1 -1
- package/dist/cdn/I64KIZG3.js +2 -0
- package/dist/cdn/{S75VFYR4.js → I76F57I2.js} +19 -18
- package/dist/cdn/IB4WTK74.js +2 -0
- package/dist/cdn/{3JGWGKT6.js → IC5P5NYY.js} +1 -1
- package/dist/cdn/{QYR3NSF2.js → IDZTJLVN.js} +2 -2
- package/dist/cdn/IW43UAIS.js +3 -0
- package/dist/cdn/{22IT5TDB.js → JBNITHPO.js} +5 -5
- package/dist/cdn/{7CYGX4F4.js → JEIMRNYM.js} +1 -1
- package/dist/cdn/K37GTMOF.js +18 -0
- package/dist/cdn/{NE7E52YR.js → KTK4HNL2.js} +8 -2
- package/dist/cdn/{TR4GFL7X.js → L77BTGXY.js} +1 -1
- package/dist/cdn/{XOH56EQ2.js → LODKJRS4.js} +1 -1
- package/dist/cdn/LSNMNSYS.js +2 -0
- package/dist/cdn/NNC3UYMR.js +2 -0
- package/dist/cdn/NOJYPREL.js +3 -0
- package/dist/cdn/{Q6LRANX6.js → O3F47IO5.js} +1 -1
- package/dist/cdn/{O3RFFPU3.js → O7TGCM5P.js} +1 -1
- package/dist/cdn/PBTINZTK.js +65 -0
- package/dist/cdn/PSWI3MFB.js +2 -0
- package/dist/cdn/RNLQZV6U.js +36 -0
- package/dist/cdn/RX45PCYB.js +9 -0
- package/dist/cdn/SLNLQG3A.js +2 -0
- package/dist/cdn/{X4XY5HIE.js → SMADRJ67.js} +1 -1
- package/dist/cdn/{GBYLKQIL.js → T7CQZ27H.js} +1 -1
- package/dist/cdn/UNFG4ZJ5.js +3 -0
- package/dist/cdn/V6TM3MTN.js +22 -0
- package/dist/cdn/{IOD3GDA7.js → VKU4WAQV.js} +1 -1
- package/dist/cdn/{RUURNLTP.js → W2JAKE2M.js} +1 -1
- package/dist/cdn/{3VOQD2MR.js → WAVKMZA6.js} +1 -1
- package/dist/cdn/WQQRLD5F.js +2 -0
- package/dist/cdn/XAI6OR2N.js +2 -0
- package/dist/cdn/{DXVU45KM.js → XVQJBUMY.js} +1 -1
- package/dist/cdn/YJ3QQXF6.js +2 -0
- package/dist/cdn/{DQSEBKOX.js → YYY7HKYX.js} +1 -1
- 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/converterUtils.js +39 -32
- package/dist/chunks/dataExplorationGraph.js +12 -10
- package/dist/chunks/helpGraph.js +8 -8
- package/dist/chunks/help_prompt.js +34 -17
- package/dist/chunks/navigationGraph.js +4 -4
- package/dist/chunks/navigation_intent_prompt.js +8 -2
- package/dist/chunks/state.js +1 -1
- package/dist/chunks/utils2.js +8 -8
- package/dist/components/arcgis-assistant/customElement.d.ts +7 -0
- package/dist/components/arcgis-assistant/customElement.js +301 -181
- package/dist/components/arcgis-assistant-agent/customElement.js +5 -1
- package/dist/components/arcgis-assistant-chat/customElement.js +22 -17
- package/dist/components/arcgis-assistant-data-exploration-agent/customElement.js +9 -5
- package/dist/components/arcgis-assistant-help-agent/customElement.js +6 -2
- package/dist/components/arcgis-assistant-interrupt/customElement.js +4 -4
- package/dist/components/arcgis-assistant-knowledge-agent/customElement.js +16 -12
- package/dist/components/arcgis-assistant-layer-styling-agent/customElement.js +8 -4
- package/dist/components/arcgis-assistant-message-block/customElement.js +1 -1
- package/dist/components/arcgis-assistant-message-text/customElement.d.ts +1 -0
- package/dist/components/arcgis-assistant-message-text/customElement.js +12 -12
- package/dist/components/arcgis-assistant-navigation-agent/customElement.js +9 -5
- package/dist/components/arcgis-assistant-user-message/customElement.js +10 -8
- 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 +2 -2
- package/dist/types/lumina.d.ts +2 -2
- package/dist/types/preact.d.ts +2 -2
- package/dist/types/react.d.ts +2 -2
- package/dist/types/stencil.d.ts +2 -2
- package/dist/utils/index.d.ts +1 -2
- package/package.json +4 -4
- package/dist/cdn/7PANDHIL.js +0 -16
- package/dist/cdn/CE6VDP2D.js +0 -72
- package/dist/cdn/CI3QSFPS.js +0 -2
- package/dist/cdn/F2AHA4GB.js +0 -54
- package/dist/cdn/FUIGPHBH.js +0 -2
- package/dist/cdn/GPYYAQVI.js +0 -2
- package/dist/cdn/I2Y67HBL.js +0 -14
- package/dist/cdn/JG2BIENI.js +0 -3
- package/dist/cdn/K475UT3E.js +0 -2
- package/dist/cdn/L4XF4H6V.js +0 -36
- package/dist/cdn/PB2ODJC7.js +0 -2
- package/dist/cdn/SBHLUL3Q.js +0 -2
- package/dist/cdn/XBW4MWQR.js +0 -2
- package/dist/cdn/XU6NCSE2.js +0 -22
- package/dist/cdn/Z7UWJ4AI.js +0 -3
- package/dist/orchestrator/registry/agentRegistry.d.ts +0 -33
- /package/dist/cdn/{CHPQM77M.js → IKEF7ZHH.js} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{$ as Xr,$a as Fc,$b as Qn,A as zo,Aa as Cc,Ab as Zc,B as Jo,Bb as Qc,C as qo,Ca as vi,Cb as el,D as Fe,Da as Ec,Db as me,E as Yo,Ea as Kn,Eb as nn,F as Xo,Fa as Wn,Fb as Xn,G as Zo,Ga as kc,Gb as Sr,H as Qo,Ha as xc,Hb as tl,I as ec,Ia as _r,Ib as rl,J as tc,Ja as Tc,Jb as Zn,K as rc,Ka as Ic,Kb as nl,L as z,La as Ac,Lb as sl,M as ct,Ma as Oc,Mb as il,N as nc,Na as Nc,O as sc,Oa as Ze,Ob as Nt,P as Tt,Pa as ee,Pb as al,Q as Yr,Qa as Pc,R as ic,Ra as yr,Rb as ol,S as Hn,Sa as ke,Sb as ie,T as ac,Ta as ut,Tb as cl,Ua as re,Ub as Si,V as zt,Va as Mc,Vb as ll,W as Jt,Wa as Rc,Wb as D,X as oc,Xa as Lc,Xb as Pt,Y as cc,Ya as rn,Yb as ul,Z as $,Za as pt,Zb as pl,_ as gr,_b as je,a as No,aa as Ee,ab as At,ac as _e,b as Po,ba as It,bb as Dc,bc as hl,c as Mo,ca as Zr,cb as jc,cc as fl,d as Ro,da as lc,db as br,dc as ae,e as I,ea as uc,eb as zn,ec as es,f as Lo,fa as Qr,fb as Xt,fc as ml,g as Fo,ga as en,gb as Vc,gc as dl,h as Le,ha as pc,hb as Bc,hc as gl,i as Do,ia as hc,ib as Uc,ic as _l,ja as he,jb as wr,jc as yl,k as Bn,ka as tn,kb as $c,kc as bl,l as jo,la as fc,lb as Jn,lc as wl,m as Vo,ma as mc,mb as Gc,mc as vl,n as Bo,na as lt,nb as Ot,o as dr,oa as De,ob as Hc,p as wi,pa as qt,pb as Kc,pc as ts,qa as dc,qb as Wc,qc as Sl,r as Uo,ra as gc,rb as qn,rc as Cl,s as Un,sa as _c,sb as Yn,sc as El,t as $n,ta as fe,tb as zc,tc as Ci,u as $o,ua as yc,ub as vr,uc as kl,v as Go,va as bc,vb as Zt,vc as xl,w as Gn,wa as wc,wb as Jc,x as Ho,xa as vc,xb as qc,y as Ko,ya as Yt,yb as Yc,z as Wo,za as Sc,zb as Xc}from"./
|
|
2
|
+
import{$ as Xr,$a as Fc,$b as Qn,A as zo,Aa as Cc,Ab as Zc,B as Jo,Bb as Qc,C as qo,Ca as vi,Cb as el,D as Fe,Da as Ec,Db as me,E as Yo,Ea as Kn,Eb as nn,F as Xo,Fa as Wn,Fb as Xn,G as Zo,Ga as kc,Gb as Sr,H as Qo,Ha as xc,Hb as tl,I as ec,Ia as _r,Ib as rl,J as tc,Ja as Tc,Jb as Zn,K as rc,Ka as Ic,Kb as nl,L as z,La as Ac,Lb as sl,M as ct,Ma as Oc,Mb as il,N as nc,Na as Nc,O as sc,Oa as Ze,Ob as Nt,P as Tt,Pa as ee,Pb as al,Q as Yr,Qa as Pc,R as ic,Ra as yr,Rb as ol,S as Hn,Sa as ke,Sb as ie,T as ac,Ta as ut,Tb as cl,Ua as re,Ub as Si,V as zt,Va as Mc,Vb as ll,W as Jt,Wa as Rc,Wb as D,X as oc,Xa as Lc,Xb as Pt,Y as cc,Ya as rn,Yb as ul,Z as $,Za as pt,Zb as pl,_ as gr,_b as je,a as No,aa as Ee,ab as At,ac as _e,b as Po,ba as It,bb as Dc,bc as hl,c as Mo,ca as Zr,cb as jc,cc as fl,d as Ro,da as lc,db as br,dc as ae,e as I,ea as uc,eb as zn,ec as es,f as Lo,fa as Qr,fb as Xt,fc as ml,g as Fo,ga as en,gb as Vc,gc as dl,h as Le,ha as pc,hb as Bc,hc as gl,i as Do,ia as hc,ib as Uc,ic as _l,ja as he,jb as wr,jc as yl,k as Bn,ka as tn,kb as $c,kc as bl,l as jo,la as fc,lb as Jn,lc as wl,m as Vo,ma as mc,mb as Gc,mc as vl,n as Bo,na as lt,nb as Ot,o as dr,oa as De,ob as Hc,p as wi,pa as qt,pb as Kc,pc as ts,qa as dc,qb as Wc,qc as Sl,r as Uo,ra as gc,rb as qn,rc as Cl,s as Un,sa as _c,sb as Yn,sc as El,t as $n,ta as fe,tb as zc,tc as Ci,u as $o,ua as yc,ub as vr,uc as kl,v as Go,va as bc,vb as Zt,vc as xl,w as Gn,wa as wc,wb as Jc,x as Ho,xa as vc,xb as qc,y as Ko,ya as Yt,yb as Yc,z as Wo,za as Sc,zb as Xc}from"./IKEF7ZHH.js";import{Dd as Mt}from"./ZEYIBYSF.js";var H="__start__",W="__end__",Qe="__input__";var Er="__error__",rs="__pregel_ns_writes",Ae="__pregel_send",kr="__pregel_call",Ve="__pregel_read",Be="__pregel_checkpointer",xr="__pregel_resuming",an="__pregel_task_id",on="__pregel_stream",vf="__pregel_resume_value",Tr="__pregel_resume_map",be="__pregel_scratchpad",er="__pregel_previous",Sf="__pregel_durability",ns="checkpoint_id",Oe="checkpoint_ns",Tl="__pregel_node_finished",Ne="checkpoint_map",Il="__pregel_abort_signals",K="__interrupt__",xe="__resume__",cn="__no_writes__",Rt="__return__",tr="__previous__",X="langsmith:hidden";var ki="__self__",et="__pregel_tasks",Pe="__pregel_push",ss="__pregel_pull",Te="00000000-0000-0000-0000-000000000000",Al=[X,Qe,K,xe,Er,cn,Ae,Ve,Be,Sf,on,xr,an,kr,vf,be,er,Ne,Oe,ns],Ei=Symbol.for("langgraph.command"),Ol=class{[Ei];constructor(e){this[Ei]=e}};function is(e){let t=e;return t!=null&&typeof t.node=="string"&&t.args!==void 0}var Qt=class{lg_name="Send";node;args;constructor(e,t){this.node=e,this.args=sn(t)}toJSON(){return{lg_name:this.lg_name,node:this.node,args:this.args}}};function Z(e){return e instanceof Qt}var Cr="__overwrite__",Cf=class{lg_name="Overwrite";[Cr];constructor(e){this[Cr]=e}get value(){return this[Cr]}toJSON(){return{[Cr]:this[Cr]}}static isInstance(e){return!e||typeof e!="object"?!1:"__overwrite__"in e||"lg_name"in e&&e.lg_name==="Overwrite"}};function as(e){return typeof e=="object"&&e!==null&&"__overwrite__"in e?[!0,e[Cr]]:[!1,void 0]}function Nl(e){return as(e)[0]}function ln(e){return!e||typeof e!="object"||!("__interrupt__"in e)?!1:Array.isArray(e[K])}var ye=class extends Ol{lg_name="Command";lc_direct_tool_output=!0;graph;update;resume;goto=[];static PARENT="__parent__";constructor(e){super(e),this.resume=e.resume,this.graph=e.graph,this.update=e.update,e.goto&&(this.goto=Array.isArray(e.goto)?sn(e.goto):[sn(e.goto)])}_updateAsTuples(){return this.update&&typeof this.update=="object"&&!Array.isArray(this.update)?Object.entries(this.update):Array.isArray(this.update)&&this.update.every(e=>Array.isArray(e)&&e.length===2&&typeof e[0]=="string")?this.update:[["__root__",this.update]]}toJSON(){let e;return typeof this.goto=="string"?e=this.goto:Z(this.goto)?e=this.goto.toJSON():e=this.goto?.map(t=>typeof t=="string"?t:t.toJSON()),{lg_name:this.lg_name,update:this.update,resume:this.resume,goto:e}}};function Q(e){return typeof e!="object"||e==null?!1:"lg_name"in e&&e.lg_name==="Command"}function sn(e,t=new Map){if(e!=null&&typeof e=="object"){if(t.has(e))return t.get(e);let r;if(Array.isArray(e))r=[],t.set(e,r),e.forEach((n,s)=>{r[s]=sn(n,t)});else if(Q(e)&&!(e instanceof ye))r=new ye(e),t.set(e,r);else if(is(e)&&!(e instanceof Qt))r=new Qt(e.node,e.args),t.set(e,r);else if(Q(e)||Z(e))r=e,t.set(e,r);else if("lc_serializable"in e&&e.lc_serializable)r=e,t.set(e,r);else{r={},t.set(e,r);for(let[n,s]of Object.entries(e))r[n]=sn(s,t)}return r}return e}var Ue=class extends Error{lc_error_code;constructor(e,t){let r=e??"";t?.lc_error_code&&(r=`${r}
|
|
3
3
|
|
|
4
4
|
Troubleshooting URL: https://docs.langchain.com/oss/javascript/langgraph/${t.lc_error_code}/
|
|
5
5
|
`),super(r),this.lc_error_code=t?.lc_error_code}},xi=class extends Ue{get is_bubble_up(){return!0}},Ti=class extends Ue{constructor(e,t){super(e,t),this.name="GraphRecursionError"}static get unminifiable_name(){return"GraphRecursionError"}},rr=class extends Ue{constructor(e,t){super(e,t),this.name="GraphValueError"}static get unminifiable_name(){return"GraphValueError"}},ht=class extends xi{interrupts;constructor(e,t){super(JSON.stringify(e,null,2),t),this.name="GraphInterrupt",this.interrupts=e??[]}static get unminifiable_name(){return"GraphInterrupt"}},os=class extends ht{constructor(e,t){super([{value:e}],t),this.name="NodeInterrupt"}static get unminifiable_name(){return"NodeInterrupt"}},cs=class extends xi{command;constructor(e){super(),this.name="ParentCommand",this.command=e}static get unminifiable_name(){return"ParentCommand"}};function Ii(e){return e!==void 0&&e.name===cs.unminifiable_name}function nr(e){return e!==void 0&&e.is_bubble_up===!0}function ft(e){return e!==void 0&&[ht.unminifiable_name,os.unminifiable_name].includes(e.name)}var ls=class extends Ue{constructor(e,t){super(e,t),this.name="EmptyInputError"}static get unminifiable_name(){return"EmptyInputError"}},B=class extends Ue{constructor(e,t){super(e,t),this.name="EmptyChannelError"}static get unminifiable_name(){return"EmptyChannelError"}},L=class extends Ue{constructor(e,t){super(e,t),this.name="InvalidUpdateError"}static get unminifiable_name(){return"InvalidUpdateError"}},Ef=class extends Ue{constructor(e,t){super(e,t),this.name="MultipleSubgraphError"}static get unminifiable_name(){return"MultipleSubgraphError"}},Ai=class extends Ue{constructor(e,t){super(e,t),this.name="UnreachableNodeError"}static get unminifiable_name(){return"UnreachableNodeError"}},kf=class extends Ue{constructor(e,t){super(e,t),this.name="RemoteException"}static get unminifiable_name(){return"RemoteException"}},un=class extends Ue{constructor(e,t){super(e,t),this.name="StateGraphInputError",this.message="Invalid StateGraph input. Make sure to pass a valid StateDefinition, Annotation.Root, or Zod schema."}static get unminifiable_name(){return"StateGraphInputError"}},xf=()=>(globalThis[Symbol.for("LG_CHECKPOINT_SEEN_NS_SET")]===void 0&&(globalThis[Symbol.for("LG_CHECKPOINT_SEEN_NS_SET")]=new Set),globalThis[Symbol.for("LG_CHECKPOINT_SEEN_NS_SET")]);var Pl=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/i;function Tf(e){return typeof e=="string"&&Pl.test(e)}var Ir=Tf;function If(e){if(!Ir(e))throw TypeError("Invalid UUID");var t,r=new Uint8Array(16);return r[0]=(t=parseInt(e.slice(0,8),16))>>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=t&255,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=t&255,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=t&255,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=t&255,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=t&255,r}var us=If;var ne=[];for(ps=0;ps<256;++ps)ne.push((ps+256).toString(16).slice(1));var ps;function tt(e,t=0){return(ne[e[t+0]]+ne[e[t+1]]+ne[e[t+2]]+ne[e[t+3]]+"-"+ne[e[t+4]]+ne[e[t+5]]+"-"+ne[e[t+6]]+ne[e[t+7]]+"-"+ne[e[t+8]]+ne[e[t+9]]+"-"+ne[e[t+10]]+ne[e[t+11]]+ne[e[t+12]]+ne[e[t+13]]+ne[e[t+14]]+ne[e[t+15]]).toLowerCase()}var hs,Af=new Uint8Array(16);function pn(){if(!hs&&(hs=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!hs))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return hs(Af)}var Oi,fs,Ni=0,Pi=0;function Of(e,t,r){var n=t&&r||0,s=t||new Array(16);e=e||{};var i=e.node,a=e.clockseq;if(e._v6||(i||(i=Oi),a==null&&(a=fs)),i==null||a==null){var o=e.random||(e.rng||pn)();i==null&&(i=[o[0],o[1],o[2],o[3],o[4],o[5]],!Oi&&!e._v6&&(i[0]|=1,Oi=i)),a==null&&(a=(o[6]<<8|o[7])&16383,fs===void 0&&!e._v6&&(fs=a))}var c=e.msecs!==void 0?e.msecs:Date.now(),l=e.nsecs!==void 0?e.nsecs:Pi+1,u=c-Ni+(l-Pi)/1e4;if(u<0&&e.clockseq===void 0&&(a=a+1&16383),(u<0||c>Ni)&&e.nsecs===void 0&&(l=0),l>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");Ni=c,Pi=l,fs=a,c+=122192928e5;var h=((c&268435455)*1e4+l)%4294967296;s[n++]=h>>>24&255,s[n++]=h>>>16&255,s[n++]=h>>>8&255,s[n++]=h&255;var f=c/4294967296*1e4&268435455;s[n++]=f>>>8&255,s[n++]=f&255,s[n++]=f>>>24&15|16,s[n++]=f>>>16&255,s[n++]=a>>>8|128,s[n++]=a&255;for(var d=0;d<6;++d)s[n+d]=i[d];return t||tt(s)}var Ml=Of;function Mi(e){var t=typeof e=="string"?us(e):e,r=Nf(t);return typeof e=="string"?tt(r):r}function Nf(e,t=!1){return Uint8Array.of((e[6]&15)<<4|e[7]>>4&15,(e[7]&15)<<4|(e[4]&240)>>4,(e[4]&15)<<4|(e[5]&240)>>4,(e[5]&15)<<4|(e[0]&240)>>4,(e[0]&15)<<4|(e[1]&240)>>4,(e[1]&15)<<4|(e[2]&240)>>4,96|e[2]&15,e[3],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15])}function Pf(e){e=unescape(encodeURIComponent(e));for(var t=[],r=0;r<e.length;++r)t.push(e.charCodeAt(r));return t}var Mf="6ba7b810-9dad-11d1-80b4-00c04fd430c8",Rf="6ba7b811-9dad-11d1-80b4-00c04fd430c8";function Ri(e,t,r){function n(s,i,a,o){var c;if(typeof s=="string"&&(s=Pf(s)),typeof i=="string"&&(i=us(i)),((c=i)===null||c===void 0?void 0:c.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");var l=new Uint8Array(16+s.length);if(l.set(i),l.set(s,i.length),l=r(l),l[6]=l[6]&15|t,l[8]=l[8]&63|128,a){o=o||0;for(var u=0;u<16;++u)a[o+u]=l[u];return a}return tt(l)}try{n.name=e}catch{}return n.DNS=Mf,n.URL=Rf,n}var Lf=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),Li={randomUUID:Lf};function Ff(e,t,r){if(Li.randomUUID&&!t&&!e)return Li.randomUUID();e=e||{};var n=e.random||(e.rng||pn)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){r=r||0;for(var s=0;s<16;++s)t[r+s]=n[s];return t}return tt(n)}var ms=Ff;function Df(e,t,r,n){switch(e){case 0:return t&r^~t&n;case 1:return t^r^n;case 2:return t&r^t&n^r&n;case 3:return t^r^n}}function Fi(e,t){return e<<t|e>>>32-t}function jf(e){var t=[1518500249,1859775393,2400959708,3395469782],r=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof e=="string"){var n=unescape(encodeURIComponent(e));e=[];for(var s=0;s<n.length;++s)e.push(n.charCodeAt(s))}else Array.isArray(e)||(e=Array.prototype.slice.call(e));e.push(128);for(var i=e.length/4+2,a=Math.ceil(i/16),o=new Array(a),c=0;c<a;++c){for(var l=new Uint32Array(16),u=0;u<16;++u)l[u]=e[c*64+u*4]<<24|e[c*64+u*4+1]<<16|e[c*64+u*4+2]<<8|e[c*64+u*4+3];o[c]=l}o[a-1][14]=(e.length-1)*8/Math.pow(2,32),o[a-1][14]=Math.floor(o[a-1][14]),o[a-1][15]=(e.length-1)*8&4294967295;for(var h=0;h<a;++h){for(var f=new Uint32Array(80),d=0;d<16;++d)f[d]=o[h][d];for(var _=16;_<80;++_)f[_]=Fi(f[_-3]^f[_-8]^f[_-14]^f[_-16],1);for(var b=r[0],w=r[1],S=r[2],C=r[3],x=r[4],A=0;A<80;++A){var N=Math.floor(A/20),P=Fi(b,5)+Df(N,w,S,C)+x+t[N]+f[A]>>>0;x=C,C=S,S=Fi(w,30)>>>0,w=b,b=P}r[0]=r[0]+b>>>0,r[1]=r[1]+w>>>0,r[2]=r[2]+S>>>0,r[3]=r[3]+C>>>0,r[4]=r[4]+x>>>0}return[r[0]>>24&255,r[0]>>16&255,r[0]>>8&255,r[0]&255,r[1]>>24&255,r[1]>>16&255,r[1]>>8&255,r[1]&255,r[2]>>24&255,r[2]>>16&255,r[2]>>8&255,r[2]&255,r[3]>>24&255,r[3]>>16&255,r[3]>>8&255,r[3]&255,r[4]>>24&255,r[4]>>16&255,r[4]>>8&255,r[4]&255]}var Rl=jf;var Vf=Ri("v5",80,Rl),Di=Vf;function Ll(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),r.push.apply(r,n)}return r}function Fl(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ll(Object(r),!0).forEach(function(n){Bf(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ll(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Bf(e,t,r){return(t=Uf(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Uf(e){var t=$f(e,"string");return typeof t=="symbol"?t:t+""}function $f(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ds(e={},t,r=0){var n=Ml(Fl(Fl({},e),{},{_v6:!0}),new Uint8Array(16));if(n=Mi(n),t){for(var s=0;s<16;s++)t[r+s]=n[s];return t}return tt(n)}function hn(e){return ds({clockseq:e})}function mt(e,t){let r=t.replace(/-/g,"").match(/.{2}/g).map(n=>parseInt(n,16));return Di(e,new Uint8Array(r))}var fn="__pregel_tasks",ji="__error__",sr="__scheduled__",Vi="__interrupt__",Bi="__resume__";var Dl="[...]",Gf="[Circular]",gs=[],Ar=[];function Hf(){return{depthLimit:Number.MAX_SAFE_INTEGER,edgesLimit:Number.MAX_SAFE_INTEGER}}function jl(e,t,r,n){typeof n>"u"&&(n=Hf()),$i(e,"",0,[],void 0,0,n);var s;try{Ar.length===0?s=JSON.stringify(e,t,r):s=JSON.stringify(e,Kf(t),r)}catch{return JSON.stringify("[unable to serialize, circular reference is too complex to analyze]")}finally{for(;gs.length!==0;){var i=gs.pop();i.length===4?Object.defineProperty(i[0],i[1],i[3]):i[0][i[1]]=i[2]}}return s}function Ui(e,t,r,n){var s=Object.getOwnPropertyDescriptor(n,r);s.get!==void 0?s.configurable?(Object.defineProperty(n,r,{value:e}),gs.push([n,r,t,s])):Ar.push([t,r,e]):(n[r]=e,gs.push([n,r,t]))}function $i(e,t,r,n,s,i,a){i+=1;var o;if(typeof e=="object"&&e!==null){for(o=0;o<n.length;o++)if(n[o]===e){Ui(Gf,e,t,s);return}if(typeof a.depthLimit<"u"&&i>a.depthLimit){Ui(Dl,e,t,s);return}if(typeof a.edgesLimit<"u"&&r+1>a.edgesLimit){Ui(Dl,e,t,s);return}if(n.push(e),Array.isArray(e))for(o=0;o<e.length;o++)$i(e[o],o,o,n,e,i,a);else{var c=Object.keys(e);for(o=0;o<c.length;o++){var l=c[o];$i(e[l],l,o,n,e,i,a)}}n.pop()}}function Kf(e){return e=typeof e<"u"?e:function(t,r){return r},function(t,r){if(Ar.length>0)for(var n=0;n<Ar.length;n++){var s=Ar[n];if(s[1]===t&&s[0]===r){r=s[2],Ar.splice(n,1);break}}return e.call(this,t,r)}}var Vl=[];var Bl=I({});var Ul=I({});var _s=(e,t)=>{let r=[...new Set(t?.map(s=>{if(typeof s=="string")return s;let i=new s({});if(!("getType"in i)||typeof i.getType!="function")throw new Error("Invalid type provided.");return i.getType()}))],n=e.getType();return r.some(s=>s===n)};function Wl(e,t){return Array.isArray(e)?$l(e,t):_e.from(r=>$l(r,e))}function $l(e,t={}){let{includeNames:r,excludeNames:n,includeTypes:s,excludeTypes:i,includeIds:a,excludeIds:o}=t,c=[];for(let l of e)if(!(n&&l.name&&n.includes(l.name))){{if(i&&_s(l,i))continue;if(o&&l.id&&o.includes(l.id))continue}s||a||r?(r&&l.name&&r.some(u=>u===l.name)||s&&_s(l,s)||a&&l.id&&a.some(u=>u===l.id))&&c.push(l):c.push(l)}return c}function zl(e){return Array.isArray(e)?Gl(e):_e.from(Gl)}function Gl(e){if(!e.length)return[];let t=[];for(let r of e){let n=r,s=t.pop();if(!s)t.push(n);else if(n.getType()==="tool"||n.getType()!==s.getType())t.push(s,n);else{let i=Yt(s),a=Yt(n),o=i.concat(a);typeof i.content=="string"&&typeof a.content=="string"&&(o.content=`${i.content}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
+
import{_ as h,a as E,b as y,ta as k}from"./CJIV4KJZ.js";var j=new Set(["agentExecutionContext","outputMessage","summary","status"]);function x(){return{assignedTask:"",messages:[],priorSteps:[],sharedState:{},userRequest:""}}function O(r){let o=[...new Set([...r].filter(n=>j.has(n)))];if(o.length!==0)throw new Error(`custom state cannot define reserved runtime fields: ${o.join(", ")}.`)}function S(r){let o=Object.entries(r);return Object.fromEntries(o.map(([n,t])=>[n,h({reducer:(i,g)=>g,default:()=>t})]))}function $(r={}){O(Object.keys(r));let o=S(r);return h.Root({...o,agentExecutionContext:h({reducer:(n,t)=>({...n,...t}),default:x}),outputMessage:h({reducer:(n="",t)=>typeof t=="string"&&t.trim()?t:n,default:()=>""}),summary:h({reducer:(n="",t)=>typeof t=="string"?t:n,default:()=>""}),status:h({reducer:(n,t)=>t??n,default:()=>{}})})}function M(r){let o=new Set;for(let t of r)for(let i of Object.keys(t.shape??{}))o.add(i);let n=Object.fromEntries([...o].map(t=>[t,void 0]));return $(n)}function T(r,o,n,t={}){let{agent:i,entryNode:g,middlewares:c=[]}=t,a=new k(n);if(Object.keys(r).length===0)throw new Error("Graph requires at least one node.");if(o.length===0)throw new Error("Graph requires at least one edge.");if(c.length>0&&!i)throw new Error("Graph middleware requires agent metadata.");let s=new Set(Object.keys(r)),l=new Map,w=new Map;for(let e of s)l.set(e,0),w.set(e,0);for(let e of o)"to"in e?(s.has(e.from)&&w.set(e.from,(w.get(e.from)??0)+1),s.has(e.to)&&l.set(e.to,(l.get(e.to)??0)+1)):s.has(e.from)&&w.set(e.from,(w.get(e.from)??0)+1);for(let[e,f]of Object.entries(r)){let u=N(i,e,c,async(d,p)=>await Promise.resolve(f(d,p))),m=async(d,p)=>await u(d,p);a=a.addNode(e,m)}for(let e of o)if("to"in e){let f=e.from,u=e.to;if(!s.has(f))throw new Error(`Graph edge references unknown from-node: ${f}`);if(!s.has(u))throw new Error(`Graph edge references unknown to-node: ${u}`);a.addEdge(f,u)}else{let f=e.from;if(!s.has(f))throw new Error(`Graph conditional edge references unknown from-node: ${f}`);a.addConditionalEdges(f,async(u,m)=>{let d=await e.decide(u,m);if(!d)return y;if(!s.has(d))throw new Error(`Graph conditional edge returned unknown node: ${d}`);return d})}let G=q(s,l,g);a.addEdge(E,G);let b=[...s].filter(e=>(w.get(e)??0)===0);for(let e of b)a.addEdge(e,y);return a}function N(r,o,n,t){return!n.length||!r?t:async(i,g)=>await n.reduceRight((c,a)=>async s=>await a.handler(s,c),async c=>{let a=await t(c.state,c.config);return{...c.state,...a}})({agent:r,config:g,nodeName:o,state:i})}function q(r,o,n){if(n){if(!r.has(n))throw new Error(`Graph entry node references unknown node: ${n}`);return n}let t=[...r].filter(i=>(o.get(i)??0)===0);if(t.length!==1)throw new Error(`Graph could not infer a single entry node (found ${t.length}). Provide an explicit entryNode or ensure exactly one node has no incoming edges.`);return t[0]}export{$ as a,M as b,T as c};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
+
import c from"./HOCTVCHH.js";import b from"./IDZTJLVN.js";import a from"./I76F57I2.js";import{a as i}from"./4RZPOYZ7.js";import{a as u,b as p,q as f,ta as S}from"./CJIV4KJZ.js";export default $arcgis.t(([,,,,,,{r:x},{A:_,B:h,a:w,m:E,o:y,p:I,q:L,r:v,s:F,t:$,u:C,v:N,w:R,x:T,y:b,z:A},q])=>{var V=.7,z=10,D=async(a,t)=>{try{await i({text:"Similarity search to find fields"},t);let e=y(t,"fieldSearch"),n=y(t,"layersAndFieldsRegistry"),o=y(t,"embeddingCache"),r=await e.searchFields({text:a.agentExecutionContext.assignedTask,layerIds:a.vectorSearchLayerIds,minScore:V,topResults:z,embeddingCache:o}),m=r.map(({layerId:d,results:c})=>{let g=c.map(s=>` - ${s.name} (${s.score.toFixed(2)})`).join(`
|
|
3
|
+
`);return`${n.get(d)?.layerItem.name??d}:
|
|
4
|
+
${g}`}).join(`
|
|
5
|
+
`),l;return r.length>0?l=`Vector search completed. Matching layers and fields with scores:
|
|
6
|
+
${m}`:l=`No vector search results found for score over ${V}.`,await i({text:l},t),{...a,vectorSearchFieldResults:r}}catch(e){throw await i({text:`Error during vector search: ${e instanceof Error?e.message:String(e)}`},t),new Error(`Vector search failed: ${e instanceof Error?e.message:String(e)}`)}},B=.7,G=async(a,t)=>{try{await i({text:`Similarity search to find layers: ${a.agentExecutionContext.assignedTask}`},t);let e=y(t,"layerSearch"),n=y(t,"layersAndFieldsRegistry"),o=await e.searchLayers({text:a.agentExecutionContext.assignedTask,minScore:B}),r=o.map(d=>d.id),m=o.map(({id:d,score:c})=>`${n.get(d)?.layerItem.name??d} (${c.toFixed(2)})`).join(`
|
|
7
|
+
`),l;return r.length>0?l=`Vector search completed. Matching layers with scores:
|
|
8
|
+
${m}`:l="Vector search completed. No matching layers found.",await i({text:l},t),{...a,vectorSearchLayerIds:r}}catch(e){throw await i({text:`Error during vector search: ${e instanceof Error?e.message:String(e)}`},t),new Error(`Vector search failed: ${e instanceof Error?e.message:String(e)}`)}},k=[L,v,F,$,C,N,R,T,b,A,_],M=(a,t=3)=>{let e=a.map((o,r)=>o.type==="human"?r:-1).filter(o=>o!==-1);if(e.length===0)return[];let n=e.length>t?e[e.length-t]:e[0];return a.slice(n)},H=async(a,t)=>{await i({text:"Requesting LLM for layer query results"},t);let e=await E("navigation_intent_prompt");if(!t?.configurable)throw new Error("config.configurable is required for layer query tools");let n={layerFieldInfo:a.layerFieldInfo},o=await x({promptText:e,modelTier:"advanced",config:t,messages:M(a.agentExecutionContext.messages),inputVariables:n,tools:k});return await q(o,t),{...a,agentExecutionContext:{...a.agentExecutionContext,messages:[...a.agentExecutionContext.messages,o]}}};async function P(a,t){let e=await new w(k,{handleToolErrors:!1}).invoke({messages:M(a.agentExecutionContext.messages)},t),n=e.messages.map(r=>r.text).join(`
|
|
9
|
+
`);await i({text:`Finished executing layer filter tool: ${n}`},t);let o=e.messages.map(r=>r.text).join(`
|
|
10
|
+
`);return{...a,outputMessage:o}}var J=async(a,t)=>(await i({text:"Exiting Layer Styling agent"},t),a),K=async(a,t)=>{try{await i({text:"Populating layer and field info"},t);let e=[];for(let n of a.vectorSearchFieldResults){let o=function(g){let s=l.get(g)?.layerItem;return s?[s.name&&`Name: ${s.name}`,s.title&&`Title: ${s.title}`,s.description&&`Description: ${s.description}`].filter(Boolean).join(" | "):g},{layerId:r,results:m}=n,l=y(t,"layersAndFieldsRegistry"),d=l.get(r)?.fieldRegistry;if(!d)continue;let c=e.find(g=>g.layerId===r);c||(c={layerId:r,layerSummary:o(r),fieldInfos:[]},e.push(c));for(let g of m){let s=d.get(g.name);s&&c.fieldInfos.push(s)}}return await i({text:"Populated layerFieldInfo"},t),{...a,layerFieldInfo:e}}catch(e){throw await i({text:"Error populating layerFieldInfo"},t),new Error(`Error populating layerFieldInfo: ${e instanceof Error?e.message:String(e)}`)}},U=(a,t)=>{let e=a.vectorSearchLayerIds??[];if(e.length<=1)return{...a,selectedLayerId:a.vectorSearchLayerIds[0]};let{hitlResponse:n}=t.configurable;if(n?.agentId!==j.id||n.id!=="reviewLayerSelection"){let r={agentId:j.id,id:"reviewLayerSelection",kind:"singleSelection",message:"Choose a layer to apply the styles.",metadata:[...e]};throw new f(r)}let o=null;return Array.isArray(n.payload)&&n.payload.length>0&&(o=n.payload[0]),{...a,selectedLayerId:o??a.vectorSearchLayerIds[0]}},O=(a,t)=>I(["layerSearch","fieldSearch","layersAndFieldsRegistry"],"Layer Styling Agent")(a,t),Q=()=>new S(h).addNode("requireLayerStylingServices",O).addNode("vectorSearchLayers",G).addNode("layerSelectionHITL",U).addNode("vectorSearchFields",D).addNode("populateLayerFieldInfo",K).addNode("agent",H).addNode("tools",P).addNode("earlyExit",J).addEdge(u,"requireLayerStylingServices").addEdge("requireLayerStylingServices","vectorSearchLayers").addConditionalEdges("layerSelectionHITL",a=>a.vectorSearchLayerIds.length?"vectorSearchFields":"earlyExit").addConditionalEdges("vectorSearchFields",a=>a.vectorSearchFieldResults.length?"populateLayerFieldInfo":"earlyExit").addEdge("populateLayerFieldInfo","agent").addEdge("agent","tools").addEdge("tools",p).addEdge("earlyExit",p),W=String.raw`- **layerStyling** — User wants to change how features are drawn or styled on the map based on their data, such as applying color, size, transparency, symbols, or charts according to field values.
|
|
11
|
+
_Example: “Color points by sales amount”_
|
|
12
|
+
_Example: “Show population density with a color gradient”_
|
|
13
|
+
_Example: “Create a relationship map between height and depth”_
|
|
14
|
+
_Example: “Vary circle sizes according to population”_`,j={id:"layerStyling",name:"Layer Styling Agent",description:W,createGraph:Q,workspace:h};return j},"identity/IdentityManager","portal/Portal","config","core/reactiveUtils","layers/FeatureLayer","request",a,b,c)
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
+
import c from"./RNLQZV6U.js";import b from"./IDZTJLVN.js";import a from"./I76F57I2.js";import{a as s,c as o}from"./W2JAKE2M.js";import"./5W7S2RS4.js";import"./NXKKG5TK.js";import{v as i,z as r}from"./MAV3DW27.js";import"./ADYIXCSG.js";import"./4RZPOYZ7.js";import"./6LZ6GOHF.js";import"./CJIV4KJZ.js";import"./IKEF7ZHH.js";import"./WNS5ZUF5.js";import"./ZEYIBYSF.js";import"./YIMNOUTF.js";export default $arcgis.t(([,,,,,,,,,,,,,a])=>{var t=class extends i{constructor(){super(...arguments),this.agent=a}static{this.properties={referenceElement:1}}#t;#i;getContext(){if(!this.#t)throw new Error("arcgis-assistant-navigation-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=s(this,"arcgis-assistant-navigation-agent"),this.#i=o(this)}disconnectedCallback(){this.#i?.unregister(this.agent.id),super.disconnectedCallback()}};r("arcgis-assistant-navigation-agent",t);return t},"identity/IdentityManager","portal/Portal","config","core/reactiveUtils","layers/FeatureLayer","request","intl","smartMapping/statistics/summaryStatistics","smartMapping/statistics/uniqueValues","views/LinkChartView","rest/knowledgeGraphService",a,b,c)
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{a as t}from"./
|
|
2
|
+
import{a as t}from"./4RZPOYZ7.js";export default $arcgis.t(([])=>{var d=async(o,i)=>{let r=o.tool_calls??[];if(r.length===0){await t({text:`LLM did not request any tool calls: ${String(o?.content)}`},i);return}await Promise.all(r.map(async a=>await t({text:`LLM invoked ${a.name} tool with arguments: ${JSON.stringify(a.args,null,2)}`},i)))};return d},"identity/IdentityManager","portal/Portal","config","core/reactiveUtils","layers/FeatureLayer","request")
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
+
import{g as i,h as s,v as n,z as o}from"./MAV3DW27.js";import"./ADYIXCSG.js";import"./YIMNOUTF.js";var c=i`:host{display:block}`,e=class extends n{static{this.properties={block:0}}static{this.styles=c}_renderSuggestedPrompts(t){if(t.type!=="suggested-prompts")return null;let r=t.data?.prompts,a=Array.isArray(r)?r.filter(p=>typeof p=="string"):[];return a.length?s`<arcgis-assistant-suggested-prompts .prompts=${a}></arcgis-assistant-suggested-prompts>`:null}_renderBlock(t){switch(t.type){case"suggested-prompts":return this._renderSuggestedPrompts(t);case"text":return s`<arcgis-assistant-message-text .content=${t.data?.content} .parts=${t.data?.parts}></arcgis-assistant-message-text>`;default:return null}}render(){return this.block?this._renderBlock(this.block):null}};o("arcgis-assistant-message-block",e);export{e as ArcgisAssistantMessageBlock};
|