@arcgis/ai-components 5.2.0-next.6 → 5.2.0-next.8
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/cdn/{BFZJNJL6.js → 53ZCUPKK.js} +1 -1
- package/dist/cdn/{GCQLVNNC.js → 5XRDJL7R.js} +1 -1
- package/dist/cdn/{AEJHYRGT.js → EECZLT6C.js} +1 -1
- package/dist/cdn/{JV4SI65E.js → ETRWZ3MS.js} +1 -1
- package/dist/cdn/{VOQX4AVB.js → GGSZM7KV.js} +1 -1
- package/dist/cdn/{3NI46YCE.js → I6HNBTWY.js} +1 -1
- package/dist/cdn/{R6HV42YW.js → IG6YKZH3.js} +1 -1
- package/dist/cdn/{47FWPQ2A.js → P26NON3Z.js} +1 -1
- package/dist/cdn/{V7OJRG26.js → S3VPZFWQ.js} +1 -1
- package/dist/cdn/index.js +1 -1
- package/dist/chunks/generateLayerDescriptions.js +0 -1
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/dist/utils/index.d.ts +90 -43
- package/dist/utils/index.js +78 -64
- package/package.json +5 -5
package/dist/docs/api.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"@arcgis/ai-components","timestamp":"2026-06-03T04:39:19","compiler":{"name":"@arcgis/lumina-compiler","version":"5.2.0-next.6","typescriptVersion":"6.0.2"},"schemaVersion":"2.1.0","modules":[{"kind":"javascript-module","path":"index","sourcePath":"src/index.ts","declarations":[{"kind":"function","name":"getAssetPath","description":"Get a resolved path from where an asset can be loaded.","parameters":[{"name":"suffix","description":"The relative path for the asset.","type":{"text":"string"}}],"return":{"type":{"text":"string"}}},{"kind":"function","name":"setAssetPath","description":"Used to manually set the base path where package assets (like localization\nand icons) can be found.\n\nBy default, the package assets are loaded from\n`https://js.arcgis.com/<version>/<simplified-package-name>/`. We are hosting\nour assets on a CDN (Content Delivery Network) to ensure fast and reliable\naccess. It is CORS-enabled, so you can load the assets from any domain. This\nis the recommended way to load the assets and avoid bundling them with your\napplication.\n\nHowever, if you need to host the assets locally, you can copy them manually\nas part of your build process and use `setAssetPath` to customize where the\nbrowser will load the assets from.","parameters":[{"name":"path","description":"Relative or absolute path to the assets folder.","type":{"text":"URL | string","references":[{"name":"URL","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/URL","start":0,"end":3}]}}],"return":{"type":{"text":"void"}}}]},{"kind":"javascript-module","path":"agent-utils/BaseAgent","sourcePath":"src/agent-utils/BaseAgent.ts","declarations":[{"kind":"class","name":"BaseAgent","description":"BaseAgent serves as the foundational class for all agent implementations. It\nprovides common properties and methods that are shared across different types of agents.\nThis class is not intended to be used directly, use any of the subclasses that extend BaseAgent\ninstead.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"superclass":{"name":"default","module":"core/Accessor.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Accessor/"},"members":[{"kind":"field","name":"createGraph","description":"The createGraph function defines the internal graph structure of the agent,\nincluding its nodes, edges, and associated state.","docsTags":[{"name":"internal"}],"type":{"text":"AgentCreateGraph<TCustomState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TCustomState","start":17,"end":29}]},"readonly":true},{"kind":"field","name":"description","description":"Description of the agent's purpose and functionality. This can be used in registration metadata to provide context about the agent's functionality. A good description is clear and concise. Use bullet points to describe tasks the agent can accomplish. Provide examples of user questions or prompts that could be answered by the agent.","type":{"text":"string"},"default":"\"\""},{"kind":"field","name":"id","description":"The unique identifier for the agent, derived from the name property. This ID is used for registration and invocation purposes.","type":{"text":"string"},"readonly":true},{"kind":"field","name":"middlewares","description":"An optional array of middleware functions that can be used to extend or modify the agent's\nbehavior during execution.\nThis allows for flexible customization of the agent's execution logic. For example, middlewares\ncan be used to implement trace messages (i.e. logging), human-in-the-loop interrupts, or other custom actions.","type":{"text":"AgentMiddleware<TCustomState>[]","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}},{"kind":"field","name":"name","description":"A name for the agent, which is used in the registration metadata and can be displayed in tooling.\nIt should be unique across agents to avoid registration conflicts. A good agent name clearly\nindicates the scope and purpose of the agent. For example, \"WeatherAgent\" or \"CustomerSupportAgent\"\nare descriptive names that convey the agent's functionality as opposed to generic names like\n\"Agent1\" or \"MyAgent\".\n\nThe name is also used to generate the agent's [id](https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#id).","docsTags":[{"name":"required"}],"type":{"text":"string"}},{"kind":"field","name":"registration","description":"The registration property assembles the necessary metadata and graph definition for this agent,\nwhich is consumed by the orchestrator during registration.","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]},"readonly":true},{"kind":"field","name":"workspace","description":"The workspace property serves as the agent's internal state storage, which is used to maintain\ncontext across graph node executions.\nThis is where the agent's state is read from and written to during graph execution, allowing for\ndynamic behavior based on previous steps in the graph.","docsTags":[{"name":"internal"}],"type":{"text":"AgentStateAnnotation<TCustomState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]},"readonly":true},{"kind":"method","name":"generate","description":"Rebuilds internal workspace and createGraph wiring. This is automatically called during initialization and whenever\nthe name or description properties change, but can also be called manually if needed to refresh the agent's graph definition.\n\nThe agent implementation is responsible for defining the createGraph function and workspace structure in this method, which are then used during execution.","docsTags":[{"name":"internal"}],"return":{"type":{"text":"void"}}},{"kind":"method","name":"getSchemas","description":"Returns all schemas required by this agent implementation.","docsTags":[{"name":"internal"}],"return":{"description":"An array of Zod object schemas that define the structure of the agent's expected input and output data.\nThese schemas are used for validation and type inference during graph execution.","type":{"text":"ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}}},{"kind":"method","name":"initialize","return":{"type":{"text":"void"}}},{"kind":"method","name":"run","description":"Executes the agent's graph with the provided state and configuration. This method is responsible\nfor invoking the compiled graph and returning the resulting state after execution.","parameters":[{"name":"state","description":"An optional partial state object to initialize the graph execution. This can include any custom fields defined by the agent.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"An optional execution configuration that can influence the agent's behavior during invocation.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"A promise that resolves to the updated agent graph state after execution.","type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}}}]}]},{"kind":"javascript-module","path":"agent-utils/FunctionAgent","sourcePath":"src/agent-utils/FunctionAgent.ts","declarations":[{"kind":"interface","name":"FunctionAgentExecute","description":"FunctionAgentExecute defines the signature for the execute function used by FunctionAgent.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","parameters":[{"name":"state","description":"Agent state at invocation time.","type":{"text":"AgentNodeState<TInput, TOutput>","references":[{"name":"AgentNodeState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentNodeState","start":0,"end":14},{"name":"TInput","start":15,"end":21},{"name":"TOutput","start":23,"end":30}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"Structured output object or final message string.","type":{"text":"Promise<TOutput | string> | TOutput | string","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TOutput","start":8,"end":15},{"name":"TOutput","start":28,"end":35}]}}}]},{"kind":"class","name":"FunctionAgent","description":"FunctionAgent executes a user-provided function as its core logic.\nIt supports optional input and output schemas for validation and structured data handling.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseAgent","module":"agent-utils/BaseAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#BaseAgent","typeArguments":[{"text":"AgentCustomState<TInput, TOutput>","references":[{"name":"AgentCustomState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCustomState","start":0,"end":16},{"name":"TInput","start":17,"end":23},{"name":"TOutput","start":25,"end":32}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","optional":true,"type":{"text":"ConstructProperties<TInput, TOutput>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/FunctionAgent/#ConstructProperties","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}}]},{"kind":"field","name":"createGraph","description":"The createGraph function defines the internal graph structure of the agent,\nincluding its nodes, edges, and associated state.","docsTags":[{"name":"internal"}],"type":{"text":"AgentCreateGraph<TCustomState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TCustomState","start":17,"end":29}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"description","description":"Description of the agent's purpose and functionality. This can be used in registration metadata to provide context about the agent's functionality. A good description is clear and concise. Use bullet points to describe tasks the agent can accomplish. Provide examples of user questions or prompts that could be answered by the agent.","type":{"text":"string"},"default":"\"\"","inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"execute","description":"The execute function contains the core logic of the FunctionAgent.\nIt receives the current agent state and an optional execution configuration,\nand returns one of the following:\n\n- a structured output object - used in a follow-up node for further processing in the graph, or\n- a string representing a the final message to display in the chat UI.","docsTags":[{"name":"required"}],"type":{"text":"FunctionAgentExecute<TInput, TOutput>","references":[{"name":"FunctionAgentExecute","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/FunctionAgent/#FunctionAgentExecute","start":0,"end":20},{"name":"TInput","start":21,"end":27},{"name":"TOutput","start":29,"end":36}]}},{"kind":"field","name":"id","description":"The unique identifier for the agent, derived from the name property. This ID is used for registration and invocation purposes.","type":{"text":"string"},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"inputSchema","description":"The input schema defines the expected structure of the agent state when the execute function is invoked.\nIf provided, the agent will validate incoming state against this schema and throw an error if validation fails.","type":{"text":"ZodObjectSchema<TInput> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15},{"name":"TInput","start":16,"end":22}]}},{"kind":"field","name":"middlewares","description":"An optional array of middleware functions that can be used to extend or modify the agent's\nbehavior during execution.\nThis allows for flexible customization of the agent's execution logic. For example, middlewares\ncan be used to implement trace messages (i.e. logging), human-in-the-loop interrupts, or other custom actions.","type":{"text":"AgentMiddleware<TCustomState>[]","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"name","description":"A name for the agent, which is used in the registration metadata and can be displayed in tooling.\nIt should be unique across agents to avoid registration conflicts. A good agent name clearly\nindicates the scope and purpose of the agent. For example, \"WeatherAgent\" or \"CustomerSupportAgent\"\nare descriptive names that convey the agent's functionality as opposed to generic names like\n\"Agent1\" or \"MyAgent\".\n\nThe name is also used to generate the agent's [id](https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#id).","docsTags":[{"name":"required"}],"type":{"text":"string"},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"outputSchema","description":"The output schema defines the expected structure of the result returned by the execute function.\nIf provided, the agent will validate the output against this schema and handle it accordingly.","type":{"text":"ZodObjectSchema<TOutput> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15},{"name":"TOutput","start":16,"end":23}]}},{"kind":"field","name":"registration","description":"The registration property assembles the necessary metadata and graph definition for this agent,\nwhich is consumed by the orchestrator during registration.","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"workspace","description":"The workspace property serves as the agent's internal state storage, which is used to maintain\ncontext across graph node executions.\nThis is where the agent's state is read from and written to during graph execution, allowing for\ndynamic behavior based on previous steps in the graph.","docsTags":[{"name":"internal"}],"type":{"text":"AgentStateAnnotation<TCustomState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"method","name":"generate","description":"Rebuilds internal workspace and createGraph wiring. This is automatically called during initialization and whenever\nthe name or description properties change, but can also be called manually if needed to refresh the agent's graph definition.\n\nThe agent implementation is responsible for defining the createGraph function and workspace structure in this method, which are then used during execution.","docsTags":[{"name":"internal"}],"return":{"type":{"text":"void"}}},{"kind":"method","name":"getSchemas","description":"Returns all schemas required by this agent implementation.","docsTags":[{"name":"internal"}],"return":{"description":"An array of Zod object schemas that define the structure of the agent's expected input and output data.\nThese schemas are used for validation and type inference during graph execution.","type":{"text":"ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}}},{"kind":"method","name":"initialize","return":{"type":{"text":"void"}}},{"kind":"method","name":"run","description":"Executes the agent's graph with the provided state and configuration. This method is responsible\nfor invoking the compiled graph and returning the resulting state after execution.","parameters":[{"name":"state","description":"An optional partial state object to initialize the graph execution. This can include any custom fields defined by the agent.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"An optional execution configuration that can influence the agent's behavior during invocation.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"A promise that resolves to the updated agent graph state after execution.","type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<FunctionAgent<TInput, TOutput>, \"description\" | \"inputSchema\" | \"middlewares\" | \"outputSchema\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"FunctionAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/FunctionAgent/#FunctionAgent","start":5,"end":18},{"name":"TInput","start":19,"end":25},{"name":"TOutput","start":27,"end":34}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"FunctionAgent<TInput, TOutput>","references":[{"name":"FunctionAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/FunctionAgent/#FunctionAgent","start":0,"end":13},{"name":"TInput","start":14,"end":20},{"name":"TOutput","start":22,"end":29}]},{"text":"\"execute\" | \"name\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/LLMAgent","sourcePath":"src/agent-utils/LLMAgent.ts","declarations":[{"kind":"class","name":"LLMAgent","description":"LLMAgent uses a language model to generate its output based on a provided prompt template and optional tools.\nIt supports structured input and output through Zod schemas, allowing for validation and type safety. The agent's logic is defined by the prompt and the tools it has access to, making it a flexible option for a wide range of use cases.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseAgent","module":"agent-utils/BaseAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#BaseAgent","typeArguments":[{"text":"AgentCustomState<TInput, TOutput>","references":[{"name":"AgentCustomState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCustomState","start":0,"end":16},{"name":"TInput","start":17,"end":23},{"name":"TOutput","start":25,"end":32}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","optional":true,"type":{"text":"ConstructProperties<TInput, TOutput>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/LLMAgent/#ConstructProperties","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}}]},{"kind":"field","name":"createGraph","description":"The createGraph function defines the internal graph structure of the agent,\nincluding its nodes, edges, and associated state.","docsTags":[{"name":"internal"}],"type":{"text":"AgentCreateGraph<TCustomState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TCustomState","start":17,"end":29}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"description","description":"Description of the agent's purpose and functionality. This can be used in registration metadata to provide context about the agent's functionality. A good description is clear and concise. Use bullet points to describe tasks the agent can accomplish. Provide examples of user questions or prompts that could be answered by the agent.","type":{"text":"string"},"default":"\"\"","inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"id","description":"The unique identifier for the agent, derived from the name property. This ID is used for registration and invocation purposes.","type":{"text":"string"},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"inputSchema","description":"The inputSchema property is an optional Zod schema describing the expected structured input for the agent.\nThis can be used for validation of the input state before execution and also to extract variables from the input\nstate for prompt formatting.","type":{"text":"ZodObjectSchema<TInput> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15},{"name":"TInput","start":16,"end":22}]}},{"kind":"field","name":"middlewares","description":"An optional array of middleware functions that can be used to extend or modify the agent's\nbehavior during execution.\nThis allows for flexible customization of the agent's execution logic. For example, middlewares\ncan be used to implement trace messages (i.e. logging), human-in-the-loop interrupts, or other custom actions.","type":{"text":"AgentMiddleware<TCustomState>[]","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"modelTier","description":"The tier of the model to use for the agent. This can affect the capabilities and performance of the agent.","type":{"text":"\"advanced\" | \"default\" | \"fast\""},"default":"\"default\""},{"kind":"field","name":"name","description":"A name for the agent, which is used in the registration metadata and can be displayed in tooling.\nIt should be unique across agents to avoid registration conflicts. A good agent name clearly\nindicates the scope and purpose of the agent. For example, \"WeatherAgent\" or \"CustomerSupportAgent\"\nare descriptive names that convey the agent's functionality as opposed to generic names like\n\"Agent1\" or \"MyAgent\".\n\nThe name is also used to generate the agent's [id](https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#id).","docsTags":[{"name":"required"}],"type":{"text":"string"},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"outputSchema","description":"The outputSchema property is an optional Zod schema describing the expected structured output from the agent.\nIf provided, the agent will attempt to parse the language model's response according to this schema and return structured data.\nIf not provided, the agent will treat the language model's response as an unstructured string message.","type":{"text":"ZodObjectSchema<TOutput> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15},{"name":"TOutput","start":16,"end":23}]}},{"kind":"field","name":"prompt","description":"Defines the prompt template the agent will use to generate its output.\nThis prompt can include variables that are populated from the agent's state at runtime through the input schema,\nallowing for dynamic and context-aware responses from the language model.\n\nIn this example below, {location} and {weather} would be variables extracted from the agent's state according to the input schema.","docsTags":[{"name":"example","text":"\"Generate a weather report for {location} based on the current {weather} conditions.\""},{"name":"required"}],"type":{"text":"string"}},{"kind":"field","name":"registration","description":"The registration property assembles the necessary metadata and graph definition for this agent,\nwhich is consumed by the orchestrator during registration.","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"tools","description":"The tools property is an optional array of FunctionTools that the agent can use during execution.","type":{"text":"FunctionToolLike[] | undefined","references":[{"name":"FunctionToolLike","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolLike","start":0,"end":16}]}},{"kind":"field","name":"workspace","description":"The workspace property serves as the agent's internal state storage, which is used to maintain\ncontext across graph node executions.\nThis is where the agent's state is read from and written to during graph execution, allowing for\ndynamic behavior based on previous steps in the graph.","docsTags":[{"name":"internal"}],"type":{"text":"AgentStateAnnotation<TCustomState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"method","name":"generate","description":"Rebuilds internal workspace and createGraph wiring. This is automatically called during initialization and whenever\nthe name or description properties change, but can also be called manually if needed to refresh the agent's graph definition.\n\nThe agent implementation is responsible for defining the createGraph function and workspace structure in this method, which are then used during execution.","docsTags":[{"name":"internal"}],"return":{"type":{"text":"void"}}},{"kind":"method","name":"getSchemas","description":"Returns all schemas required by this agent implementation.","docsTags":[{"name":"internal"}],"return":{"description":"An array of Zod object schemas that define the structure of the agent's expected input and output data.\nThese schemas are used for validation and type inference during graph execution.","type":{"text":"ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}}},{"kind":"method","name":"initialize","return":{"type":{"text":"void"}}},{"kind":"method","name":"run","description":"Executes the agent's graph with the provided state and configuration. This method is responsible\nfor invoking the compiled graph and returning the resulting state after execution.","parameters":[{"name":"state","description":"An optional partial state object to initialize the graph execution. This can include any custom fields defined by the agent.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"An optional execution configuration that can influence the agent's behavior during invocation.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"A promise that resolves to the updated agent graph state after execution.","type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<LLMAgent<TInput, TOutput>, \"description\" | \"inputSchema\" | \"middlewares\" | \"modelTier\" | \"outputSchema\" | \"tools\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"LLMAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/LLMAgent/#LLMAgent","start":5,"end":13},{"name":"TInput","start":14,"end":20},{"name":"TOutput","start":22,"end":29}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"LLMAgent<TInput, TOutput>","references":[{"name":"LLMAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/LLMAgent/#LLMAgent","start":0,"end":8},{"name":"TInput","start":9,"end":15},{"name":"TOutput","start":17,"end":24}]},{"text":"\"name\" | \"prompt\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/WorkflowAgent","sourcePath":"src/agent-utils/WorkflowAgent.ts","declarations":[{"kind":"class","name":"WorkflowAgent","description":"WorkflowAgent wraps agents and workflows so they can be executed and registered as a single agent.\nThe workflow defines the internal graph structure and logic of the agent, while WorkflowAgent provides the interface for integration with the broader agent system.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseAgent","module":"agent-utils/BaseAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#BaseAgent","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/WorkflowAgent/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"createGraph","description":"The createGraph function defines the internal graph structure of the agent,\nincluding its nodes, edges, and associated state.","docsTags":[{"name":"internal"}],"type":{"text":"AgentCreateGraph<TCustomState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TCustomState","start":17,"end":29}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"description","description":"Description of the agent's purpose and functionality. This can be used in registration metadata to provide context about the agent's functionality. A good description is clear and concise. Use bullet points to describe tasks the agent can accomplish. Provide examples of user questions or prompts that could be answered by the agent.","type":{"text":"string"},"default":"\"\"","inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"id","description":"The unique identifier for the agent, derived from the name property. This ID is used for registration and invocation purposes.","type":{"text":"string"},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"inputSchema","description":"Optional structured input schema for the workflow wrapper.","type":{"text":"ZodObjectSchema<object> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}},{"kind":"field","name":"middlewares","description":"An optional array of middleware functions that can be used to extend or modify the agent's\nbehavior during execution.\nThis allows for flexible customization of the agent's execution logic. For example, middlewares\ncan be used to implement trace messages (i.e. logging), human-in-the-loop interrupts, or other custom actions.","type":{"text":"AgentMiddleware<TCustomState>[]","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"name","description":"A name for the agent, which is used in the registration metadata and can be displayed in tooling.\nIt should be unique across agents to avoid registration conflicts. A good agent name clearly\nindicates the scope and purpose of the agent. For example, \"WeatherAgent\" or \"CustomerSupportAgent\"\nare descriptive names that convey the agent's functionality as opposed to generic names like\n\"Agent1\" or \"MyAgent\".\n\nThe name is also used to generate the agent's [id](https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#id).","docsTags":[{"name":"required"}],"type":{"text":"string"},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"outputSchema","description":"Optional structured output schema for the workflow wrapper.","type":{"text":"ZodObjectSchema<object> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}},{"kind":"field","name":"registration","description":"The registration property assembles the necessary metadata and graph definition for this agent,\nwhich is consumed by the orchestrator during registration.","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"workflow","description":"The workflow to execute when generating and running this agent's graph.","docsTags":[{"name":"required"}],"type":{"text":"BaseWorkflow<TState>","references":[{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","start":0,"end":12},{"name":"TState","start":13,"end":19}]}},{"kind":"field","name":"workspace","description":"The workspace property serves as the agent's internal state storage, which is used to maintain\ncontext across graph node executions.\nThis is where the agent's state is read from and written to during graph execution, allowing for\ndynamic behavior based on previous steps in the graph.","docsTags":[{"name":"internal"}],"type":{"text":"AgentStateAnnotation<TCustomState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"method","name":"generate","description":"Rebuilds internal workspace and createGraph wiring. This is automatically called during initialization and whenever\nthe name or description properties change, but can also be called manually if needed to refresh the agent's graph definition.\n\nThe agent implementation is responsible for defining the createGraph function and workspace structure in this method, which are then used during execution.","docsTags":[{"name":"internal"}],"return":{"type":{"text":"void"}}},{"kind":"method","name":"getSchemas","description":"Returns all schemas required by this agent implementation.","docsTags":[{"name":"internal"}],"return":{"description":"An array of Zod object schemas that define the structure of the agent's expected input and output data.\nThese schemas are used for validation and type inference during graph execution.","type":{"text":"ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}}},{"kind":"method","name":"initialize","return":{"type":{"text":"void"}}},{"kind":"method","name":"run","description":"Executes the agent's graph with the provided state and configuration. This method is responsible\nfor invoking the compiled graph and returning the resulting state after execution.","parameters":[{"name":"state","description":"An optional partial state object to initialize the graph execution. This can include any custom fields defined by the agent.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"An optional execution configuration that can influence the agent's behavior during invocation.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"A promise that resolves to the updated agent graph state after execution.","type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<WorkflowAgent<TState>, \"description\" | \"inputSchema\" | \"middlewares\" | \"outputSchema\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"WorkflowAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/WorkflowAgent/#WorkflowAgent","start":5,"end":18},{"name":"TState","start":19,"end":25}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"WorkflowAgent<TState>","references":[{"name":"WorkflowAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/WorkflowAgent/#WorkflowAgent","start":0,"end":13},{"name":"TState","start":14,"end":20}]},{"text":"\"name\" | \"workflow\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/types","sourcePath":"src/agent-utils/types.ts","declarations":[{"kind":"interface","name":"AgentData","docsTags":[{"name":"internal"}],"supertypes":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","typeArguments":[{"text":"string"},{"text":"unknown"}]}]},{"kind":"interface","name":"EmptyAgentData","docsTags":[{"name":"internal"}],"supertypes":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","typeArguments":[{"text":"never"},{"text":"never"}]}]},{"kind":"interface","name":"AgentRuntimeState","docsTags":[{"name":"privateRemark","text":"All ADK agents are orchestrator-driven, so these channels exist for every agent graph."}],"members":[{"kind":"field","name":"agentExecutionContext","type":{"text":"AgentExecutionContext","references":[{"name":"AgentExecutionContext","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentExecutionContext","start":0,"end":21}]}},{"kind":"field","name":"outputMessage","description":"The outputMessage is a string representing the output of an agent execution.","type":{"text":"string"}},{"kind":"field","name":"summary","description":"The summary is a string providing a brief overview of the agent execution.","type":{"text":"string"}},{"kind":"field","name":"status","description":"The status field represents the current status of the agent execution, which can be used to indicate success, failure, or other relevant states.","type":{"text":"AgentStatus | undefined","references":[{"name":"AgentStatus","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentStatus","start":0,"end":11}]}}]},{"kind":"interface","name":"AgentGraphState","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"supertypes":[{"name":"AgentRuntimeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentRuntimeState"},{"name":"Omit","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#omittype-keys","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]},{"text":"keyof AgentRuntimeState","references":[{"name":"AgentRuntimeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentRuntimeState","start":6,"end":23}]}]}]},{"kind":"interface","name":"BaseAgentLike","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"members":[{"kind":"field","name":"id","description":"Stable ID derived from the agent name and used for graph node and registration identity.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}},{"kind":"field","name":"inputSchema","description":"Optional schema used to validate and shape agent input state.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"ZodObjectSchema<object> | undefined","references":[{"name":"ZodObjectSchema","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}},{"kind":"field","name":"name","description":"Human-readable name shown in registration metadata and tooling.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}},{"kind":"field","name":"outputSchema","description":"Optional schema used to validate structured agent output.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"ZodObjectSchema<object> | undefined","references":[{"name":"ZodObjectSchema","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}},{"kind":"field","name":"registration","description":"Registration payload consumed by the orchestrator.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"field","name":"generate","description":"Regenerates workspace and graph wiring for this agent.","type":{"text":"() => void"}},{"kind":"field","name":"getSchemas","description":"Returns all schemas the agent contributes to state/input/output validation.","type":{"text":"() => ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":6,"end":21}]}},{"kind":"method","name":"run","description":"Executes the compiled graph for this agent.","docsTags":[{"name":"return","text":"The resulting graph state after execution."},{"name":"since","text":"5.1"}],"parameters":[{"name":"state","description":"Optional partial state used as graph input.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"Optional runtime execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}}}]},{"kind":"interface","name":"AgentExecutionConfig","description":"AgentExecutionConfig defines the shape of the configuration object that can be passed to agent execution methods to influence their behavior at runtime.","members":[{"kind":"field","name":"configurable","description":"The configurable field allows passing arbitrary key-value pairs that can be used by agents during execution to modify their behavior or provide additional context.\nThis can include flags, parameters, or any other relevant information that an agent might need to access at runtime.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"Record<string, unknown> | undefined","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}},{"kind":"field","name":"metadata","type":{"text":"Record<string, unknown> | undefined","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}},{"kind":"field","name":"recursionLimit","type":{"text":"number | undefined"}},{"kind":"field","name":"runName","type":{"text":"string | undefined"}},{"kind":"field","name":"signal","description":"The signal property is an optional AbortSignal that can be used to cancel the execution of an agent. Agents should listen for the abort signal and gracefully handle cancellation when it is triggered.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AbortSignal | undefined","references":[{"name":"AbortSignal","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/AbortSignal","start":0,"end":11}]}},{"kind":"field","name":"tags","type":{"text":"string[] | undefined"}}]},{"kind":"interface","name":"AgentCustomState","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Omit","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#omittype-keys","typeArguments":[{"text":"TInput","references":[{"name":"TInput","start":0,"end":6}]},{"text":"keyof AgentRuntimeState","references":[{"name":"AgentRuntimeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentRuntimeState","start":6,"end":23}]}]},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Omit<TOutput, keyof AgentRuntimeState>","references":[{"name":"Omit","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#omittype-keys","start":0,"end":4},{"name":"TOutput","start":5,"end":12},{"name":"AgentRuntimeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentRuntimeState","start":20,"end":37}]}]}]},{"kind":"interface","name":"AgentNodeState","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","typeArguments":[{"text":"AgentCustomState<TInput, TOutput>","references":[{"name":"AgentCustomState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCustomState","start":0,"end":16},{"name":"TInput","start":17,"end":23},{"name":"TOutput","start":25,"end":32}]}]}]},{"kind":"interface","name":"AgentNodeUpdate","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"AgentNodeState<TInput, TOutput>","references":[{"name":"AgentNodeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentNodeState","start":0,"end":14},{"name":"TInput","start":15,"end":21},{"name":"TOutput","start":23,"end":30}]}]}]},{"kind":"interface","name":"AgentStateAnnotation","description":"AgentStateAnnotation defines the shape of the agent state used in LangGraph nodes, including both the built-in runtime channels\nand any custom fields defined by the agent.","docsTags":[{"name":"internal"},{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"AnnotationRoot","module":"web","package":"@langchain/langgraph","typeArguments":[{"text":"{\n [K in keyof TState]: BinaryOperatorAggregate<TState[K] | undefined, TState[K] | undefined>;\n} & {\n agentExecutionContext: BaseChannel<AgentExecutionContext, unknown, unknown>;\n outputMessage: BaseChannel<string, unknown, unknown>;\n summary: BaseChannel<string, unknown, unknown>;\n status: BaseChannel<AgentStatus | undefined, unknown, unknown>;\n}","references":[{"name":"TState","start":18,"end":24},{"name":"BinaryOperatorAggregate","module":"channels","package":"@langchain/langgraph","start":27,"end":50},{"name":"TState","start":51,"end":57},{"name":"TState","start":74,"end":80},{"name":"BaseChannel","module":"channels","package":"@langchain/langgraph","start":131,"end":142},{"name":"AgentExecutionContext","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentExecutionContext","start":143,"end":164},{"name":"BaseChannel","module":"channels","package":"@langchain/langgraph","start":204,"end":215},{"name":"BaseChannel","module":"channels","package":"@langchain/langgraph","start":256,"end":267},{"name":"BaseChannel","module":"channels","package":"@langchain/langgraph","start":307,"end":318},{"name":"AgentStatus","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentStatus","start":319,"end":330}]}]}]},{"kind":"interface","name":"RunnableUpdate","description":"State update shape produced by graph nodes.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"type":{"text":"Partial<TState> extends object ? Partial<TState> & Record<string, any> : Partial<TState>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"TState","start":8,"end":14},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":33,"end":40},{"name":"TState","start":41,"end":47},{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":51,"end":57},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":73,"end":80},{"name":"TState","start":81,"end":87}]}},{"kind":"interface","name":"TypedStateGraph","description":"Internal type representing the compiled graph used for agent execution.","docsTags":[{"name":"internal"},{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"StateGraph","module":"web","package":"@langchain/langgraph","typeArguments":[{"text":"StateDefinitionInit","references":[{"name":"StateDefinitionInit","module":"web","package":"@langchain/langgraph","start":0,"end":19}]},{"text":"AgentGraphState<TState>","references":[{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TState","start":16,"end":22}]},{"text":"RunnableUpdate<AgentGraphState<TState>>","references":[{"name":"RunnableUpdate","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#RunnableUpdate","start":0,"end":14},{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":15,"end":30},{"name":"TState","start":31,"end":37}]},{"text":"string"}]}]},{"kind":"interface","name":"AgentCreateGraph","description":"The shape of the `createGraph` function used by agents to generate their internal graph representation.\nThis function is responsible for defining the nodes and edges of the graph, as well as any associated state and middleware.","docsTags":[{"name":"internal"},{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","return":{"type":{"text":"TypedStateGraph<TState>","references":[{"name":"TypedStateGraph","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#TypedStateGraph","start":0,"end":15},{"name":"TState","start":16,"end":22}]}}}]},{"kind":"interface","name":"ZodObjectSchema","description":"ZodObjectSchema is a simplified type representing Zod object schemas used for input and output validation in agents.","typeParameters":[{"name":"T","constraint":{"text":"object"},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"z.ZodType<T>","references":[{"name":"default","package":"zod","start":0,"end":1},{"name":"T","start":10,"end":11}]},{"text":"\"safeParse\""}]},{"name":"default","package":"zod"}]},{"kind":"interface","name":"GraphNodes","typeParameters":[{"name":"S","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","typeArguments":[{"text":"string"},{"text":"(state: S, config?: AgentExecutionConfig) => Partial<S> | Promise<Partial<S> | S> | S","references":[{"name":"S","start":8,"end":9},{"name":"AgentExecutionConfig","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":20,"end":40},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":45,"end":52},{"name":"S","start":53,"end":54},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":58,"end":65},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":66,"end":73},{"name":"S","start":74,"end":75},{"name":"S","start":79,"end":80},{"name":"S","start":84,"end":85}]}]}]},{"kind":"interface","name":"GraphEdge","typeParameters":[{"name":"S","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"type":{"text":"{\n from: string;\n decide: (state: S, config?: AgentExecutionConfig) => Promise<string | undefined> | string | undefined;\n} | {\n from: string;\n to: string;\n}","references":[{"name":"S","start":40,"end":41},{"name":"AgentExecutionConfig","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":52,"end":72},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":77,"end":84}]}}]},{"kind":"javascript-module","path":"agent-utils/middlewares/humanInTheLoop","sourcePath":"src/agent-utils/middlewares/humanInTheLoop.ts","declarations":[{"kind":"interface","name":"HumanInTheLoopInterruptRequest","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"AgentRunRequest","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentRunRequest","typeArguments":[{"text":"TCustomState","references":[{"name":"TCustomState","start":0,"end":12}]}]}],"members":[{"kind":"field","name":"agentId","description":"The ID of the agent requesting human intervention. This can be used to correlate the\ninterrupt with a specific agent, especially in cases where\nmultiple agents may be running concurrently and using the same middleware.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}}]},{"kind":"interface","name":"HumanInTheLoopInterrupt","docsTags":[{"name":"since","text":"5.1"}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"UiInterrupt","references":[{"name":"UiInterrupt","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UiInterrupt","start":0,"end":11}]}]}]},{"kind":"interface","name":"HumanInTheLoopMiddlewareOptions","description":"Options for configuring the HumanInTheLoopMiddleware.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"method","name":"interrupt","description":"An optional function that generates a custom interrupt object based on the agent run request. This allows for dynamic messages and\nmetadata to be included in the interrupt, providing context to the user when prompting for input or approval.\n\nIf not provided, a default interrupt with a generic approval message will be used.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"request","description":"The agent run request that triggered the interrupt, containing details about the agent, node, and execution context.","type":{"text":"HumanInTheLoopInterruptRequest<TCustomState>","references":[{"name":"HumanInTheLoopInterruptRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterruptRequest","start":0,"end":30},{"name":"TCustomState","start":31,"end":43}]}}],"return":{"description":"An object containing the interrupt details, which will be thrown as a NodeInterrupt to pause the agent's execution.","type":{"text":"HumanInTheLoopInterrupt | Promise<HumanInTheLoopInterrupt>","references":[{"name":"HumanInTheLoopInterrupt","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterrupt","start":0,"end":23},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":26,"end":33},{"name":"HumanInTheLoopInterrupt","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterrupt","start":34,"end":57}]}}},{"kind":"field","name":"outputKey","description":"An optional key in the agent state where the human response should be stored.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"keyof AgentGraphState<TCustomState> | undefined","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":6,"end":21},{"name":"TCustomState","start":22,"end":34}]}}]},{"kind":"interface","name":"HumanInTheLoopToolMessageRequest","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"FunctionToolMiddlewareRequest","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareRequest","typeArguments":[{"text":"TInput","references":[{"name":"TInput","start":0,"end":6}]}]}],"members":[{"kind":"field","name":"args","description":"The arguments passed to the tool that is requesting human intervention.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"object"}},{"kind":"field","name":"toolCallId","description":"The id of the tool call that is requesting human intervention.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string | undefined"}},{"kind":"field","name":"toolName","description":"The name of the tool that is requesting human intervention.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}}]},{"kind":"interface","name":"HumanInTheLoopToolMiddlewareOptions","description":"This middleware is designed to allow for human intervention during agent execution by throwing an interrupt that can be handled by the orchestrator to pause the agent and\nprompt the user for input or approval.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"method","name":"interrupt","description":"An optional function that generates a custom interrupt object based on the tool middleware request. This allows for dynamic messages and\nmetadata to be included in the interrupt, providing context to the user when prompting for input or approval at the tool execution level.","docsTags":[{"name":"since","text":"5.1"},{"name":"return","text":"An object containing the interrupt details, which will be thrown as a NodeInterrupt to pause the tool's execution."}],"parameters":[{"name":"request","description":"The tool middleware request that triggered the interrupt, containing details about the tool, input arguments, and execution context.","type":{"text":"HumanInTheLoopToolMessageRequest<TInput>","references":[{"name":"HumanInTheLoopToolMessageRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopToolMessageRequest","start":0,"end":32},{"name":"TInput","start":33,"end":39}]}}],"return":{"type":{"text":"HumanInTheLoopInterrupt | Promise<HumanInTheLoopInterrupt>","references":[{"name":"HumanInTheLoopInterrupt","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterrupt","start":0,"end":23},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":26,"end":33},{"name":"HumanInTheLoopInterrupt","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterrupt","start":34,"end":57}]}}},{"kind":"field","name":"outputKey","description":"An optional key in the tool input where the human response should be stored.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"keyof TInput | undefined","references":[{"name":"TInput","start":6,"end":12}]}}]},{"kind":"function","name":"createHumanInTheLoopMiddleware","description":"This middleware allows for human intervention during agent execution by throwing an interrupt\nto pause the agent and prompt the user for input or approval prior to proceeding. It can be used\nto implement a human-in-the-loop workflow, where certain decisions or actions require human approval before proceeding.\n\nThe interrupt includes customizable messages and metadata to provide context to the user.","docsTags":[{"name":"since","text":"5.1"},{"name":"example","text":"```ts\nconst agent = new WorkflowAgent({\n workflow: myWorkflow,\n middlewares: [\n createHumanInTheLoopMiddleware({\n interrupt: async ({ agentId }) => ({\n message: `Agent ${agentId} is requesting approval to continue. Do you approve?`,\n }),\n }),\n ],\n});\n```"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"parameters":[{"name":"options","description":"Configuration options for the middleware, including the interrupt handler and optional output key for storing the human response in\nthe agent state.","optional":true,"type":{"text":"HumanInTheLoopMiddlewareOptions<TCustomState>","references":[{"name":"HumanInTheLoopMiddlewareOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopMiddlewareOptions","start":0,"end":31},{"name":"TCustomState","start":32,"end":44}]}}],"return":{"description":"An agent middleware that can be added to an agent's middleware stack.","type":{"text":"AgentMiddleware<TCustomState>","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}}},{"kind":"function","name":"createHumanInTheLoopToolMiddleware","description":"This middleware is designed to wrap tool calls within an agent, allowing for human intervention at the tool execution level. When a tool wrapped with this middleware is invoked,\nit will throw an interrupt similar to the agent-level middleware, prompting the user for input or approval before the tool executes.","docsTags":[{"name":"since","text":"5.1"},{"name":"example","text":"```ts\nconst myTool = new FunctionTool({\n name: \"sensitiveOperation\",\n execute: async (input) => {\n // perform sensitive operation\n },\n middlewares: [\n createHumanInTheLoopToolMiddleware({\n interrupt: async ({ toolName, args }) => ({\n message: `Tool ${toolName} is requesting approval to execute with arguments: ${JSON.stringify(args)}. Do you approve?`,\n }),\n }),\n ],\n});\n```"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"parameters":[{"name":"options","description":"Configuration options for the middleware, including the interrupt handler and optional output key for storing the human response in the tool input.","optional":true,"type":{"text":"HumanInTheLoopToolMiddlewareOptions<TInput>","references":[{"name":"HumanInTheLoopToolMiddlewareOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopToolMiddlewareOptions","start":0,"end":35},{"name":"TInput","start":36,"end":42}]}}],"return":{"description":"A function tool middleware that can be added to a tool's middleware stack.","type":{"text":"FunctionToolMiddleware<TInput, TOutput>","references":[{"name":"FunctionToolMiddleware","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddleware","start":0,"end":22},{"name":"TInput","start":23,"end":29},{"name":"TOutput","start":31,"end":38}]}}},{"kind":"function","name":"getHumanInTheLoopPayload","description":"This function retrieves the human-in-the-loop (HITL) response payload from the agent execution configuration.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TPayload","default":{"text":"unknown"}}],"parameters":[{"name":"config","description":"The agent execution configuration that may contain a HITL response.","type":{"text":"AgentExecutionConfig | undefined","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"The payload from the HITL response if available; otherwise, undefined.","type":{"text":"TPayload | undefined","references":[{"name":"TPayload","start":0,"end":8}]}}}]},{"kind":"javascript-module","path":"agent-utils/middlewares/middleware","sourcePath":"src/agent-utils/middlewares/middleware.ts","declarations":[{"kind":"function","name":"createAgentMiddleware","description":"Creates an agent middleware with the specified hooks and options.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"parameters":[{"name":"name","description":"The name of the middleware.","type":{"text":"string"}},{"name":"hooks","description":"The hooks to be used in the middleware.","type":{"text":"AgentMiddlewareHooks<TCustomState>","references":[{"name":"AgentMiddlewareHooks","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareHooks","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]}},{"name":"options","description":"Optional configuration for the middleware, such as the output key.","optional":true,"type":{"text":"{ outputKey?: keyof AgentGraphState<TCustomState>; }","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":20,"end":35},{"name":"TCustomState","start":36,"end":48}]}}],"return":{"description":"The created agent middleware.","type":{"text":"AgentMiddleware<TCustomState>","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}}},{"kind":"function","name":"createToolMiddleware","description":"Creates a tool middleware with the specified hooks and options.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"parameters":[{"name":"name","description":"The name of the middleware.","type":{"text":"string"}},{"name":"hooks","description":"The hooks to be used in the middleware.","type":{"text":"ToolMiddlewareHooks<TInput, TOutput>","references":[{"name":"ToolMiddlewareHooks","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#ToolMiddlewareHooks","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}},{"name":"options","description":"Optional configuration for the middleware, such as the output key.","optional":true,"type":{"text":"{ outputKey?: string; }"}}],"return":{"description":"The created function tool middleware.","type":{"text":"FunctionToolMiddleware<TInput, TOutput>","references":[{"name":"FunctionToolMiddleware","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddleware","start":0,"end":22},{"name":"TInput","start":23,"end":29},{"name":"TOutput","start":31,"end":38}]}}}]},{"kind":"javascript-module","path":"agent-utils/middlewares/trace","sourcePath":"src/agent-utils/middlewares/trace.ts","declarations":[{"kind":"function","name":"createAgentTraceMiddleware","description":"This middleware is responsible for sending trace messages whenever the agent makes a call to the language model or executes a tool.\n\nIt uses the `sendTraceMessage` function from the orchestrator to send messages that include\ndetails about the model calls and tool\nexecutions, which can be useful for debugging and monitoring the agent's behavior.","docsTags":[{"name":"since","text":"5.1"}],"return":{"description":"An agent middleware that wraps model calls and sends trace messages.","type":{"text":"AgentMiddleware","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15}]}}},{"kind":"function","name":"createToolTraceMiddleware","description":"This middleware is responsible for sending trace messages whenever a tool is executed by the agent. It wraps tool calls and uses the `sendTraceMessage`\nfunction from the orchestrator to send messages that include details about the tool execution, such as the tool name and its result. This can be useful for\ndebugging and monitoring the behavior of tools within the agent's execution.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"return":{"description":"A function tool middleware that wraps tool calls and sends trace messages.","type":{"text":"FunctionToolMiddleware<TInput, TOutput>","references":[{"name":"FunctionToolMiddleware","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddleware","start":0,"end":22},{"name":"TInput","start":23,"end":29},{"name":"TOutput","start":31,"end":38}]}}}]},{"kind":"javascript-module","path":"agent-utils/middlewares/types","sourcePath":"src/agent-utils/middlewares/types.ts","declarations":[{"kind":"interface","name":"MiddlewareHandler","description":"Handles a middleware request and returns the resulting value.","typeParameters":[{"name":"TRequest"},{"name":"TResult"}],"members":[{"kind":"call-signature","parameters":[{"name":"request","description":"The request payload for the current middleware stage.","type":{"text":"TRequest","references":[{"name":"TRequest","start":0,"end":8}]}}],"return":{"type":{"text":"Promise<TResult> | TResult","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TResult","start":8,"end":15},{"name":"TResult","start":19,"end":26}]}}}]},{"kind":"interface","name":"Middleware","description":"Wraps a middleware request and delegates to the next handler.","typeParameters":[{"name":"TRequest"},{"name":"TResult"}],"members":[{"kind":"call-signature","parameters":[{"name":"request","description":"The request payload for the current middleware stage.","type":{"text":"TRequest","references":[{"name":"TRequest","start":0,"end":8}]}},{"name":"handler","description":"The next handler in the middleware chain.","type":{"text":"MiddlewareHandler<TRequest, TResult>","references":[{"name":"MiddlewareHandler","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#MiddlewareHandler","start":0,"end":17},{"name":"TRequest","start":18,"end":26},{"name":"TResult","start":28,"end":35}]}}],"return":{"type":{"text":"Promise<TResult> | TResult","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TResult","start":8,"end":15},{"name":"TResult","start":19,"end":26}]}}}]},{"kind":"interface","name":"AgentMiddlewareAgent","members":[{"kind":"field","name":"description","description":"Description of the agent, which can be used to provide context in middleware hooks and interrupts.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string | undefined"}},{"kind":"field","name":"id","description":"Unique identifier for the agent, used for registration and invocation purposes.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}},{"kind":"field","name":"name","description":"Name of the agent, used for display and identification purposes.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}}]},{"kind":"interface","name":"AgentRunRequest","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"members":[{"kind":"field","name":"agent","description":"The agent that is being executed. This can be used in middleware hooks to access agent metadata and provide context for interrupts or other middleware behavior.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentMiddlewareAgent","references":[{"name":"AgentMiddlewareAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareAgent","start":0,"end":20}]}},{"kind":"field","name":"config","description":"The current execution configuration for the agent run, which may include configurable parameters, metadata, and other contextual information. This can be used in middleware\nhooks to make decisions based on the execution context or to store and retrieve information related to the agent run.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentExecutionConfig | undefined","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}},{"kind":"field","name":"nodeName","description":"The name of the current node being executed in the agent's workflow. This can be used in middleware hooks to provide context or make decisions based on the specific node.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}},{"kind":"field","name":"state","description":"The current state of the agent's workflow, which may include custom data and intermediate results. This can be used in middleware hooks to access or modify the agent's state during execution.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}}]},{"kind":"interface","name":"AgentMiddlewareHandler","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"supertypes":[{"name":"Middleware","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#Middleware","typeArguments":[{"text":"AgentRunRequest<TCustomState>","references":[{"name":"AgentRunRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentRunRequest","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]},{"text":"AgentGraphState<TCustomState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}]}]},{"kind":"interface","name":"AgentMiddleware","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"members":[{"kind":"field","name":"name","type":{"text":"string"}},{"kind":"field","name":"handler","type":{"text":"AgentMiddlewareHandler<TCustomState>","references":[{"name":"AgentMiddlewareHandler","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareHandler","start":0,"end":22},{"name":"TCustomState","start":23,"end":35}]}},{"kind":"field","name":"hooks","type":{"text":"AgentMiddlewareHooks<TCustomState> | undefined","references":[{"name":"AgentMiddlewareHooks","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareHooks","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]}},{"kind":"field","name":"outputKey","type":{"text":"keyof AgentGraphState<TCustomState> | undefined","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":6,"end":21},{"name":"TCustomState","start":22,"end":34}]}}]},{"kind":"interface","name":"AfterAgentRequest","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"supertypes":[{"name":"AgentRunRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentRunRequest","typeArguments":[{"text":"TCustomState","references":[{"name":"TCustomState","start":0,"end":12}]}]}],"members":[{"kind":"field","name":"result","type":{"text":"AgentGraphState<TCustomState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}}]},{"kind":"interface","name":"AgentMiddlewareHooks","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"members":[{"kind":"method","name":"afterAgent","description":"An optional hook that is called after the agent has executed, allowing for modification of the result or additional side effects.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"request","description":"The request payload for the afterAgent hook, including the original request and the result of the agent's execution.","type":{"text":"AfterAgentRequest<TCustomState>","references":[{"name":"AfterAgentRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AfterAgentRequest","start":0,"end":17},{"name":"TCustomState","start":18,"end":30}]}}],"return":{"description":"A partial update to the agent's state or other modifications to be applied to the final result, or a promise that resolves to such an update.","type":{"text":"Partial<AgentGraphState<TCustomState>> | Promise<Partial<AgentGraphState<TCustomState>> | void> | void","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":41,"end":48},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":49,"end":56},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":57,"end":72},{"name":"TCustomState","start":73,"end":85}]}}},{"kind":"field","name":"afterModel","type":{"text":"ModelLifecycleHook | undefined","references":[{"name":"ModelLifecycleHook","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#ModelLifecycleHook","start":0,"end":18}]},"readonly":true},{"kind":"field","name":"beforeModel","type":{"text":"ModelLifecycleHook | undefined","references":[{"name":"ModelLifecycleHook","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#ModelLifecycleHook","start":0,"end":18}]},"readonly":true},{"kind":"method","name":"beforeAgent","description":"An optional hook that is called before the agent executes, allowing for modification of the request or additional side effects.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"request","description":"The request payload for the beforeAgent hook, including the original request.","type":{"text":"AgentRunRequest<TCustomState>","references":[{"name":"AgentRunRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentRunRequest","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}}],"return":{"description":"A partial update to the agent's state or other modifications to be applied to the request, or a promise that resolves to such an update.","type":{"text":"Partial<AgentGraphState<TCustomState>> | Promise<Partial<AgentGraphState<TCustomState>> | void> | void","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":41,"end":48},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":49,"end":56},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":57,"end":72},{"name":"TCustomState","start":73,"end":85}]}}},{"kind":"field","name":"wrapAgent","description":"An optional hook that wraps the entire agent execution, allowing for complete control over the execution flow.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentMiddlewareHandler<TCustomState> | undefined","references":[{"name":"AgentMiddlewareHandler","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareHandler","start":0,"end":22},{"name":"TCustomState","start":23,"end":35}]},"readonly":true},{"kind":"field","name":"wrapModelCall","type":{"text":"LangChainMiddlewareHooks[\"wrapModelCall\"] | undefined","references":[{"name":"LangChainMiddlewareHooks","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#LangChainMiddlewareHooks","start":0,"end":24}]},"readonly":true},{"kind":"field","name":"wrapToolCall","type":{"text":"LangChainMiddlewareHooks[\"wrapToolCall\"] | undefined","references":[{"name":"LangChainMiddlewareHooks","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#LangChainMiddlewareHooks","start":0,"end":24}]},"readonly":true}]},{"kind":"interface","name":"ToolMiddlewareHooks","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"members":[{"kind":"field","name":"wrapToolCall","description":"Hook that wraps a tool call, allowing you to intercept and modify the request and response of a tool execution. This can be used for logging, modifying inputs/outputs, or implementing custom behavior around tool calls.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"FunctionToolMiddlewareHandler<TInput, TOutput> | undefined","references":[{"name":"FunctionToolMiddlewareHandler","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareHandler","start":0,"end":29},{"name":"TInput","start":30,"end":36},{"name":"TOutput","start":38,"end":45}]},"readonly":true}]},{"kind":"interface","name":"LangChainMiddlewareHooks","supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"LangChainAgentMiddleware","references":[{"name":"AgentMiddleware","package":"langchain","start":0,"end":24}]},{"text":"\"afterModel\" | \"beforeModel\" | \"wrapModelCall\" | \"wrapToolCall\""}]}]},{"kind":"interface","name":"ModelLifecycleHook","supertypes":[{"name":"NonNullable","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#extracttype-union","typeArguments":[{"text":"LangChainMiddlewareHooks[\"beforeModel\"]","references":[{"name":"LangChainMiddlewareHooks","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#LangChainMiddlewareHooks","start":0,"end":24}]}]}]}]},{"kind":"javascript-module","path":"agent-utils/tools/FunctionTool","sourcePath":"src/agent-utils/tools/FunctionTool.ts","declarations":[{"kind":"interface","name":"FunctionToolExecute","description":"Execute function used by `FunctionTool`.","typeParameters":[{"name":"TInput","constraint":{"text":"object"}},{"name":"TOutput"}],"members":[{"kind":"call-signature","parameters":[{"name":"input","description":"Structured tool input.","type":{"text":"TInput","references":[{"name":"TInput","start":0,"end":6}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<TOutput> | TOutput","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TOutput","start":8,"end":15},{"name":"TOutput","start":19,"end":26}]}}}]},{"kind":"interface","name":"FunctionToolResult","typeParameters":[{"name":"TOutput","default":{"text":"unknown"}}],"type":{"text":"TOutput | string","references":[{"name":"TOutput","start":0,"end":7}]}},{"kind":"interface","name":"FunctionToolMiddlewareRequest","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"field","name":"config","type":{"text":"AgentExecutionConfig | undefined","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}},{"kind":"field","name":"input","type":{"text":"TInput","references":[{"name":"TInput","start":0,"end":6}]}},{"kind":"field","name":"tool","type":{"text":"FunctionToolMiddlewareTool","references":[{"name":"FunctionToolMiddlewareTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareTool","start":0,"end":26}]}},{"kind":"field","name":"toolCallId","type":{"text":"string | undefined"}}]},{"kind":"interface","name":"FunctionToolMiddlewareHandler","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"supertypes":[{"name":"Middleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#Middleware","typeArguments":[{"text":"FunctionToolMiddlewareRequest<TInput>","references":[{"name":"FunctionToolMiddlewareRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareRequest","start":0,"end":29},{"name":"TInput","start":30,"end":36}]},{"text":"FunctionToolResult<TOutput>","references":[{"name":"FunctionToolResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolResult","start":0,"end":18},{"name":"TOutput","start":19,"end":26}]}]}]},{"kind":"interface","name":"FunctionToolMiddleware","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"members":[{"kind":"field","name":"name","type":{"text":"string"}},{"kind":"field","name":"handler","type":{"text":"FunctionToolMiddlewareHandler<TInput, TOutput>","references":[{"name":"FunctionToolMiddlewareHandler","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareHandler","start":0,"end":29},{"name":"TInput","start":30,"end":36},{"name":"TOutput","start":38,"end":45}]}},{"kind":"field","name":"outputKey","type":{"text":"keyof TInput | undefined","references":[{"name":"TInput","start":6,"end":12}]}}]},{"kind":"interface","name":"ToolResultMode","type":{"text":"\"continue\" | \"terminal\""}},{"kind":"interface","name":"FunctionToolLike","members":[{"kind":"field","name":"name","description":"Name of the tool, used for invocation by agents. This should be unique among the tools available to an agent.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string | undefined"}},{"kind":"field","name":"resultMode","description":"Result mode determines how the agent should treat the output of this tool. If set to \"terminal\", the agent will return the tool's output directly as its final response. If set to \"continue\", the agent will continue processing after invoking the tool, allowing for further reasoning or tool calls.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"ToolResultMode | undefined","references":[{"name":"ToolResultMode","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#ToolResultMode","start":0,"end":14}]}},{"kind":"field","name":"getTool","type":{"text":"() => StructuredToolInterface","references":[{"name":"StructuredToolInterface","module":"tools","package":"@langchain/core","start":6,"end":29}]}}]},{"kind":"class","name":"FunctionTool","description":"FunctionTool is a tool implementation that allows users to define custom logic through a provided execute function,\nalong with input/output schemas for validation and optional middleware for extensibility.\n\nThe FunctionTool is passed to LLMAgents as part of their tools array, and can be invoked by the agent during execution\nbased on the agent's prompt and reasoning process. The resultMode property allows the tool to either return\na final response directly or continue the agent's processing after execution, providing flexibility in how the tool's\noutput is used within the agent's workflow.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"superclass":{"name":"default","module":"core/Accessor.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Accessor/"},"members":[{"kind":"constructor","parameters":[{"name":"properties","optional":true,"type":{"text":"ConstructProperties<TInput, TOutput>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#ConstructProperties","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}}]},{"kind":"field","name":"description","description":"A concise, but clear description of the tool's functionality.\nThis should provide enough information for the agent to understand when and why to use the tool.\nYou can include examples of a user's input that would trigger the tool, the values to extract, and\nsample output to illustrate its purpose.","docsTags":[{"name":"required"}],"type":{"text":"string"}},{"kind":"field","name":"execute","description":"The execute function contains the custom logic that will be executed when the tool is invoked\nby an agent. It receives\nthe input object and an optional execution configuration, and returns either a result directly\nor a promise that resolves to the result.\n\nThe result is validated against the output schema, if provided.","docsTags":[{"name":"required"},{"name":"since","text":"5.1"}],"type":{"text":"FunctionToolExecute<TInput, TOutput>","references":[{"name":"FunctionToolExecute","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolExecute","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}},{"kind":"field","name":"inputSchema","description":"The input schema defines the expected structure of the input object when invoking the tool.\nThis should be a Zod schema object.\nThe agent will validate the input against this schema before execution.","type":{"text":"z.ZodType<TInput> | undefined","references":[{"name":"default","package":"zod","start":0,"end":1},{"name":"TInput","start":10,"end":16}]}},{"kind":"field","name":"middlewares","description":"Middleware that can wrap this tool's execution.","type":{"text":"FunctionToolMiddleware<TInput, TOutput>[]","references":[{"name":"FunctionToolMiddleware","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddleware","start":0,"end":22},{"name":"TInput","start":23,"end":29},{"name":"TOutput","start":31,"end":38}]}},{"kind":"field","name":"name","description":"The name of the tool, which will be used to invoke it. This should be unique among the tools\navailable to an agent. It should also be descriptive of the tool's functionality to make it\nclear to the agent when to use it.","docsTags":[{"name":"required"}],"type":{"text":"string"}},{"kind":"field","name":"outputSchema","description":"The output schema defines the expected structure of the result returned by the tool.\nThis should be a Zod schema object.\nThe agent will validate the output against this schema after execution.","type":{"text":"z.ZodType<TOutput> | undefined","references":[{"name":"default","package":"zod","start":0,"end":1},{"name":"TOutput","start":10,"end":17}]}},{"kind":"field","name":"resultMode","description":"The result mode determines how the agent should treat the output of this tool.\nIf set to `terminal`, the agent will\nreturn the tool's output directly as its final response. If set to `continue`,\nthe agent will continue processing after\ninvoking the tool, allowing for further reasoning or tool calls.","type":{"text":"ToolResultMode","references":[{"name":"ToolResultMode","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#ToolResultMode","start":0,"end":14}]},"default":"\"continue\""},{"kind":"method","name":"getTool","description":"Builds the LangChain tool adapter used by LLM agents.","return":{"type":{"text":"StructuredToolInterface","references":[{"name":"StructuredToolInterface","module":"tools","package":"@langchain/core","start":0,"end":23}]}}}]},{"kind":"interface","name":"FunctionToolMiddlewareTool","members":[{"kind":"field","name":"description","type":{"text":"string"}},{"kind":"field","name":"name","type":{"text":"string"}},{"kind":"field","name":"resultMode","type":{"text":"ToolResultMode","references":[{"name":"ToolResultMode","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#ToolResultMode","start":0,"end":14}]}}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput"}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<FunctionTool<TInput, TOutput>, \"inputSchema\" | \"middlewares\" | \"outputSchema\" | \"resultMode\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionTool","start":5,"end":17},{"name":"TInput","start":18,"end":24},{"name":"TOutput","start":26,"end":33}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"FunctionTool<TInput, TOutput>","references":[{"name":"FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionTool","start":0,"end":12},{"name":"TInput","start":13,"end":19},{"name":"TOutput","start":21,"end":28}]},{"text":"\"description\" | \"execute\" | \"name\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/BaseWorkflow","sourcePath":"src/agent-utils/workflows/BaseWorkflow.ts","declarations":[{"kind":"interface","name":"WorkflowGenerateResult","description":"Return payload from `BaseWorkflow.generate()`.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"field","name":"workspace","description":"Shared workflow state annotation.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentStateAnnotation<TState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TState","start":21,"end":27}]}},{"kind":"field","name":"createGraph","description":"Factory that creates the workflow graph.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentCreateGraph<TState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TState","start":17,"end":23}]}}]},{"kind":"class","name":"BaseWorkflow","description":"BaseWorkflow is the foundational class for defining workflows. A workflow defines a sequence of\nagents that work together to accomplish a task. This class provides the structure and common\nbuilding blocks for constructing a workflow, including generating the shared workspace and\ncreating the graph that defines how agents are connected and executed.\n\nSpecific workflows extend this base class and implement the abstract methods to define\ntheir unique behavior and structure.\n\nThe following workflow types are supported:\n\n- `SequentialWorkflow` - executes agents in a sequence, where the output of one agent can be passed as input to the next.\n- `ConditionalWorkflow` - allows for branching logic based on conditions evaluated at runtime, enabling different paths of execution depending on user input or LLM output.\n- `LoopWorkflow` - supports repeating a set of agents until a certain condition is met, useful for iterative processes.\n- `ParallelWorkflow` - enables concurrent execution of multiple agents, allowing for tasks that can be performed simultaneously.\n- `RouterWorkflow` - dynamically routes execution to different agents based on the input or state, providing flexibility in handling various scenarios.\n- `SwitchWorkflow` - similar to RouterWorkflow but designed for cases where there are multiple distinct paths based on discrete values in the input or state.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"default","module":"core/Accessor.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Accessor/"},"members":[{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"string | undefined"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"name":"index","type":{"text":"number"}}],"return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/ConditionalWorkflow","sourcePath":"src/agent-utils/workflows/ConditionalWorkflow.ts","declarations":[{"kind":"interface","name":"ConditionDecider","description":"Condition function that routes execution to either the true branch or false branch.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","parameters":[{"name":"state","description":"Current workflow graph state.","type":{"text":"AgentGraphState<TState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TState","start":16,"end":22}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<boolean> | boolean","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}}]},{"kind":"class","name":"ConditionalWorkflow","description":"ConditionalWorkflow chooses between two branch agents based on a boolean condition and\nroutes execution through a simple true/false branch.\n\nUse when:\n- you want an if/else style decision or\n- only two branches are needed.\n\nHow it works:\n- evaluate `condition(state, config)`,\n- if true, run the first branch agent,\n- if false, run the second branch agent.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ConditionalWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agents","description":"Must contain exactly two agents: `[trueAgent, falseAgent]`. The first agent is executed when\nthe condition is true, the second when the condition is false.","docsTags":[{"name":"required"}],"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"field","name":"condition","description":"Predicate that chooses the next branch.","docsTags":[{"name":"required"}],"type":{"text":"ConditionDecider<TState>","references":[{"name":"ConditionDecider","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ConditionalWorkflow/#ConditionDecider","start":0,"end":16},{"name":"TState","start":17,"end":23}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"ConditionalWorkflow<TState>","references":[{"name":"ConditionalWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ConditionalWorkflow/#ConditionalWorkflow","start":0,"end":19},{"name":"TState","start":20,"end":26}]},{"text":"\"agents\" | \"condition\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/LoopWorkflow","sourcePath":"src/agent-utils/workflows/LoopWorkflow.ts","declarations":[{"kind":"interface","name":"LoopDecider","description":"Loop continuation predicate. Return true to run another iteration.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","parameters":[{"name":"state","description":"Current workflow graph state.","type":{"text":"AgentGraphState<TState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TState","start":16,"end":22}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<boolean> | boolean","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}}]},{"kind":"class","name":"LoopWorkflow","description":"LoopWorkflow repeatedly executes an inner workflow until a stop condition is met.\n\nUse in the following scenarios:\n\n- You need retry/refine loops,\n- You want iterative planning and execution.\n\nHow it works:\n- Runs the inner `workflow`,\n- Evaluates `decideContinue(state, config)`,\n- If true, runs again; if false (or unset), stops.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/LoopWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"decideContinue","description":"Function that decides whether the loop should continue.","docsTags":[{"name":"required"}],"type":{"text":"LoopDecider<TState>","references":[{"name":"LoopDecider","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/LoopWorkflow/#LoopDecider","start":0,"end":11},{"name":"TState","start":12,"end":18}]}},{"kind":"field","name":"workflow","description":"Inner workflow to execute on each loop iteration.","docsTags":[{"name":"required"}],"type":{"text":"BaseWorkflow<TState>","references":[{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","start":0,"end":12},{"name":"TState","start":13,"end":19}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"LoopWorkflow<TState>","references":[{"name":"LoopWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/LoopWorkflow/#LoopWorkflow","start":0,"end":12},{"name":"TState","start":13,"end":19}]},{"text":"\"decideContinue\" | \"workflow\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/ParallelWorkflow","sourcePath":"src/agent-utils/workflows/ParallelWorkflow.ts","declarations":[{"kind":"class","name":"ParallelWorkflow","description":"ParallelWorkflow fans out execution to multiple agents and merges branch outputs.\n\nUse in the following scenarios:\n- Branches can run independently from the same input,\n- You want fan-out/fan-in behavior.\n\nHow it works:\n- Fan out - every agent receives the same input snapshot,\n- Each branch collects its result in a hidden state key,\n- Fan in - merge outputs in declared agent order.\n\nMerge rule:\n- If two branches set the same shared key to different values, an error is thrown,\nas this indicates a conflict the workflow cannot resolve on its own.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ParallelWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agents","description":"Agents to run in parallel from the same input snapshot.","docsTags":[{"name":"required"}],"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","parameters":[{"name":"_agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","parameters":[{"name":"_agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"name":"_index","type":{"text":"number"}}],"return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"ParallelWorkflow<TState>","references":[{"name":"ParallelWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ParallelWorkflow/#ParallelWorkflow","start":0,"end":16},{"name":"TState","start":17,"end":23}]},{"text":"\"agents\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/RouterWorkflow","sourcePath":"src/agent-utils/workflows/RouterWorkflow.ts","declarations":[{"kind":"class","name":"RouterWorkflow","description":"RouterWorkflow runs a router agent, then dispatches to exactly one downstream agent.\n\nUse in the following scenarios:\n- A model (or routing step) should choose the destination,\n- Only one branch should run per request\n\nHow it works:\n- `routerAgent` always runs first,\n- `routerAgent` reads the selected route key from `routerOutputKey`,\n- The agent corresponding to the selected route key is dispatched from `agentsMap`.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/RouterWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agentsMap","description":"Mapping of route keys to destination agents.","docsTags":[{"name":"required"}],"type":{"text":"Record<string, BaseAgentLike<TState>>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6},{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":15,"end":28},{"name":"TState","start":29,"end":35}]}},{"kind":"field","name":"routerAgent","description":"The agent that decides which route key to select.","docsTags":[{"name":"required"}],"type":{"text":"BaseAgentLike<TState>","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"field","name":"routerOutputKey","description":"State key containing the selected route returned by the router agent.","docsTags":[{"name":"required"}],"type":{"text":"keyof AgentGraphState<TState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":6,"end":21},{"name":"TState","start":22,"end":28}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","parameters":[{"name":"_agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"name":"index","type":{"text":"number"}}],"return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"RouterWorkflow<TState>","references":[{"name":"RouterWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/RouterWorkflow/#RouterWorkflow","start":0,"end":14},{"name":"TState","start":15,"end":21}]},{"text":"\"agentsMap\" | \"routerAgent\" | \"routerOutputKey\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/SequentialWorkflow","sourcePath":"src/agent-utils/workflows/SequentialWorkflow.ts","declarations":[{"kind":"class","name":"SequentialWorkflow","description":"SequentialWorkflow executes agents in strict linear order.\n\nUse in the following scenarios:\n- Later steps depend on values produced by earlier steps,\n- You want a simple linear pipeline.\n\nHow it works:\n- First agent runs and passes shared state forward,\n- Each subsequent agent receives the updated shared state from the previous agent,\n- Run agent 2, then agent 3, and so on,\n- Stop after the final agent in the sequence runs.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SequentialWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agents","description":"A list of agents to execute in the specified order.","docsTags":[{"name":"required"}],"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"string | undefined"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"name":"index","type":{"text":"number"}}],"return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"SequentialWorkflow<TState>","references":[{"name":"SequentialWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SequentialWorkflow/#SequentialWorkflow","start":0,"end":18},{"name":"TState","start":19,"end":25}]},{"text":"\"agents\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/SwitchWorkflow","sourcePath":"src/agent-utils/workflows/SwitchWorkflow.ts","declarations":[{"kind":"interface","name":"SwitchDecider","description":"Resolver function that chooses a switch case key from current graph state.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","parameters":[{"name":"state","description":"Current workflow graph state.","type":{"text":"AgentGraphState<TState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TState","start":16,"end":22}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<string | undefined> | string | undefined","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}}]},{"kind":"class","name":"SwitchWorkflow","description":"SwitchWorkflow routes execution to one of several branches based on a resolver function.\n\nUse in the following scenarios:\n- Branch selection should be based on complex logic that doesn't fit a simple true/false condition.\n- You want explicit case handling with optional fallback.\n\nHow it works:\n- Run `resolver(state, config)` to get a case key,\n- Route to matching `agentsMap` entry,\n- If unknown and `defaultAgent` exists, run default,\n- If unknown and no default, throw an error.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SwitchWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agentsMap","description":"Mapping of keys to destination agents.","docsTags":[{"name":"required"}],"type":{"text":"Record<string, BaseAgentLike<TState>>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6},{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":15,"end":28},{"name":"TState","start":29,"end":35}]}},{"kind":"field","name":"defaultAgent","description":"Optional fallback agent used when the resolver returns an unknown case.","type":{"text":"BaseAgentLike<TState> | undefined","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"field","name":"resolver","description":"Resolver used to select the case key for routing.","docsTags":[{"name":"required"}],"type":{"text":"SwitchDecider<TState>","references":[{"name":"SwitchDecider","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SwitchWorkflow/#SwitchDecider","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<SwitchWorkflow<TState>, \"defaultAgent\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"SwitchWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SwitchWorkflow/#SwitchWorkflow","start":5,"end":19},{"name":"TState","start":20,"end":26}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"SwitchWorkflow<TState>","references":[{"name":"SwitchWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SwitchWorkflow/#SwitchWorkflow","start":0,"end":14},{"name":"TState","start":15,"end":21}]},{"text":"\"agentsMap\" | \"resolver\""}]}]}]},{"kind":"javascript-module","path":"components/arcgis-assistant","sourcePath":"src/components/assistant/assistant.tsx","declarations":[{"kind":"class","name":"ArcgisAssistant","customElement":true,"tagName":"arcgis-assistant","pascalCaseName":"ArcgisAssistant","description":"The ArcGIS Assistant component provides a chat-based natural language interface for interacting with\nweb map data via agents. This component uses an orchestrator, which relies on a large language model (LLM)\nfor determining user intent. Once the intent is determined, the assistant routes the user's request\nto an agent that uses an LLM to generate text and structured responses.\n\nBy default, the `arcgis-assistant` component does not include any agents. You must register at least one\nagent for the assistant to function. You can register agents declaratively using any of the\navailable agent components, or you can register custom agents.\n\n## Register agents\n\nTo register agents declaratively, include one or more agent components as children\nof the `arcgis-assistant` component. This can be done in HTML or programmatically using JavaScript.\n\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"#my-map\">\n <arcgis-assistant-navigation-agent></arcgis-assistant-navigation-agent>\n <arcgis-assistant-data-exploration-agent></arcgis-assistant-data-exploration-agent>\n <arcgis-assistant-help-agent></arcgis-assistant-help-agent>\n</arcgis-assistant>\n```\n\n```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst navigationAgent = document.createElement(\"arcgis-assistant-navigation-agent\");\nconst dataExplorationAgent = document.createElement(\"arcgis-assistant-data-exploration-agent\");\nassistant.appendChild(navigationAgent);\nassistant.appendChild(dataExplorationAgent);\n```\n\nNote that the `reference-element` property on the `arcgis-assistant` component must point to a valid `arcgis-map` element\nfor the included ArcGIS agents to function properly, as they rely on the map context to perform their tasks. This is not\na requirement for [custom agents](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/).\n\n## Context\n\nUse the [referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement) property to provide a web map as context to the assistant and its agents.\nThis should be a reference to the map that the assistant will interact with, and is required for the included ArcGIS\nagents to function properly.\n\nTo learn more about this component, try out the [demo](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#demos)\n\n## Important considerations and best practices\n\nDue to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents. Therefore, it is important to set clear expectations\nfor end users and provide guidance on how to interact with the assistant to help mitigate these issues. Some ways to do this include:\n\n- Provide [suggestedPrompts](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#suggestedPrompts). This helps users understand the bounds of the assistant\nand gives them an idea of how to phrase questions to get the best results.\n- Use the [entryMessage](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#entryMessage) property to provide an entry message with instructions and guidance.","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"},{"name":"see","text":"[arcgis-assistant-data-exploration-agent](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-data-exploration-agent/)"},{"name":"see","text":"[arcgis-assistant-navigation-agent](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-navigation-agent/)"},{"name":"see","text":"[arcgis-assistant-help-agent](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-help-agent/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/"},{"description":"Assistant Intro\nIntroduction to the Assistant component.","url":"https://developers.arcgis.com/javascript/latest/storybook/ai-components/index.html?path=/story/arcgis-assistant--demo&singleStory=true"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"awaitingResponse","description":"Indicates whether the assistant is currently processing a user message.\nThis value is `true` while the assistant is generating a response and `false` when idle.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","readonly":true},{"kind":"field","name":"awaitingResponseStep","description":"The current processing status message shown while the assistant is generating a response.\nThis can be used to display progress details such as the current step in processing.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string","values":[{"type":"string"}]},"readonly":true},{"kind":"field","name":"copyEnabled","description":"When `true`, enables the copy action that, when clicked, copies the content of the message to the clipboard. This can be helpful for users to easily copy and share\ninformation provided by the assistant, such as a summary of findings, a set of instructions, or any other relevant details. Enabling this property can enhance the user experience by providing a convenient way for users to capture and utilize the information generated by the assistant.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant copy-enabled></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.copyEnabled = true;\n```"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"copy-enabled"},{"kind":"field","name":"description","description":"The description text displayed below the heading in the assistant. This text provides additional\ncontext about the assistant's capabilities and how users can interact with it.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant description=\"Explore parcel data ownership, zoning designations, and other relevant information.\"></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.description = \"Explore parcel data ownership, zoning designations, and other relevant information.\";\n```"}],"type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"description"},{"kind":"field","name":"entryMessage","description":"The instructions to display when the assistant is first loaded. This is intended to be a welcome or entry message that\nprovides guidance to users on how to interact with the assistant. Once the user submits their first message,\nthe entry message will be closed and replaced with the chat interface. You can use this property to provide\ninstructions, suggest prompts, or simply welcome users to the assistant.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant entry-message=\"I can answer questions about parcel ownership, zoning, and other relevant information.\"></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.entryMessage = \"I can answer questions about parcel ownership, zoning, and other relevant information.\";\n```"}],"type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"entry-message"},{"kind":"field","name":"feedbackEnabled","description":"When `true`, enables the feedback action in the chat interface, allowing developers to capture user feedback on the assistant's responses.\nThe action simply provides a thumbs up and thumbs down experience for users to indicate whether a response was helpful or not. When the\nuser submits feedback, the [@arcgisFeedback](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#event-arcgisFeedback) event is emitted allowing the app developer to capture additional feedback\nthrough a custom interface and log it to a database or service for later analysis.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant feedback-enabled></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.feedbackEnabled = true;\nassistant.addEventListener(\"arcgisFeedback\", (event) => {\n const feedback = event.detail;\n // Capture additional feedback from the user and log it to a database or service for later analysis\n});\n```"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"feedback-enabled"},{"kind":"field","name":"heading","description":"The heading text displayed at the top of the assistant. This name should be concise and\ndescriptive of the assistant's purpose.\n\nFor applications where the primary interface is the assistant, this heading could also be used as the\napplication title. In cases where the assistant could be collapsed or is a secondary interface to a standard\nGUI, the heading should be more specific to the assistant's function to avoid confusion with the overall\napplication title.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant heading=\"Parcel Viewer\"></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.heading = \"Zoning Assistant\";\n```"}],"type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"heading"},{"kind":"field","name":"interrupt","description":"The active interrupt, if the assistant is waiting for additional user input.\nApplications rendering custom interrupt UI through the `interrupt` slot can read this value\nand call [submitInterrupt()](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#submitInterrupt) or [cancelInterrupt()](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#cancelInterrupt)\nto respond.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"Interrupt | null","references":[{"name":"Interrupt","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#Interrupt","start":0,"end":9}]},"readonly":true},{"kind":"field","name":"keepSuggestedPrompts","description":"When `true`, keeps suggested prompts displayed in the UI after the user submits a message. By default, suggested prompts are cleared,\nwhen the user submits a message.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant keep-suggested-prompts></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.keepSuggestedPrompts = true;\n```"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"keep-suggested-prompts"},{"kind":"field","name":"logEnabled","description":"When `true`, enables the log action that when clicked displays log messages in the chat interface. Log messages provide detailed messages including\nwhich agents or tools were invoked, the parameters generated by the LLM, and any relevant details about how the assistant arrived at its response.\nEnabling logs can be helpful for developers for debugging during the development of an assistant or agentic web application.\nIt may also be useful to end users for transparency purposes, allowing them to understand the assistant's behavior and decision-making process.\n\nEnabling this property for a production app depends on the role of the audience. More technical audiences may benefit from having access to these\nlogs while non-technical audiences may find them overwhelming or confusing.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant log-enabled></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.logEnabled = true;\n```"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"log-enabled"},{"kind":"field","name":"messages","description":"The collection of messages exchanged between the user and the assistant. Each message includes the role\n(user or assistant), along with any relevant logs or errors. These messages are rendered in the chat interface\nand are used to provide context for the conversation. When a user submits a message, it is added to this\ncollection with the role of \"user\". When the assistant generates a response, it is added to this collection\nwith the role of \"assistant\", along with any logs or errors that occurred during processing.","docsTags":[{"name":"since","text":"5.0"}],"type":{"text":"Collection<ChatMessage>","references":[{"name":"default","module":"core/Collection.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Collection/","start":0,"end":10},{"name":"ChatMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessage","start":11,"end":22}]}},{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the assistant and its agents. Currently,\nthis is only scoped to `arcgis-map` elements. This is required when ArcGIS agents are registered to the assistant.\nFor example, this allows the navigation agent to execute a map navigation tool for a specific map.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"my-map\"></arcgis-assistant>\n```"}],"type":{"text":"ArcgisMap | string | null","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"field","name":"suggestedPrompts","description":"Prompts to suggest to the end user on load. These are intended to help users understand which questions they can ask.\nThis property should be set to establish boundaries for the end user. As all agents have limitations and LLMs can\nbe unpredictable, it's important to set clear expectations for users to give them a better chance to succeed.\nBy providing suggested prompts, you can guide users towards asking questions that are relevant to the data being\nused and the capabilities of the registered agents, which can help to ensure that the assistant provides accurate\nand helpful responses.\n\nYou should typically provide 2-3 suggested prompts.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.suggestedPrompts = [\n \"What city has the highest population?\",\n \"What is the highest point in this area?\"\n];\n```"}],"type":{"text":"string[]"}},{"kind":"method","name":"cancelInterrupt","description":"Cancels the active interrupt, if one is pending.","docsTags":[{"name":"since","text":"5.1"}],"return":{"type":{"text":"void"}},"signature":"(): void"},{"kind":"method","name":"clearChatHistory","description":"Clears the chat history between the user and the assistant. This method can be used to programmatically reset the conversation,\nremoving all messages from the chat interface.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.clearChatHistory();\n```"}],"return":{"type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}},"signature":"(): Promise<void>"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistant = document.createElement(\"arcgis-assistant\");\ndocument.body.append(arcgisAssistant);\nawait arcgisAssistant.componentOnReady();\nconsole.log(\"arcgis-assistant is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"},{"kind":"method","name":"submitInterrupt","description":"Submits a response for the active interrupt.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"response","description":"The response payload expected by the active interrupt type.","type":{"text":"string[] | boolean | string"}}],"return":{"type":{"text":"void"}},"signature":"(response: string[] | boolean | string): void"},{"kind":"method","name":"submitMessage","description":"Programmatically submits a message to the assistant. This method can be used to submit messages from outside the component,\nsuch as from another component or from custom JavaScript code. When a message is submitted using this method, it is added\nto the messages collection with the role of \"user\", and then processed by the assistant in the same way as if it were submitted\nthrough the chat interface. This allows for greater flexibility in how messages are sent to the assistant and can enable more\ncomplex interactions and integrations with other components or services.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.submitMessage(\"What is the population of New York City?\");\n```"}],"parameters":[{"name":"message","description":"The message to submit to the assistant. This should be a string containing the user's input or question they want to ask the assistant.","type":{"text":"string"}}],"return":{"type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}},"signature":"(message: string): Promise<void>"}],"attributes":[{"name":"copy-enabled","description":"When `true`, enables the copy action that, when clicked, copies the content of the message to the clipboard. This can be helpful for users to easily copy and share\ninformation provided by the assistant, such as a summary of findings, a set of instructions, or any other relevant details. Enabling this property can enhance the user experience by providing a convenient way for users to capture and utilize the information generated by the assistant.","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"copyEnabled"},{"name":"description","description":"The description text displayed below the heading in the assistant. This text provides additional\ncontext about the assistant's capabilities and how users can interact with it.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"description"},{"name":"entry-message","description":"The instructions to display when the assistant is first loaded. This is intended to be a welcome or entry message that\nprovides guidance to users on how to interact with the assistant. Once the user submits their first message,\nthe entry message will be closed and replaced with the chat interface. You can use this property to provide\ninstructions, suggest prompts, or simply welcome users to the assistant.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"entryMessage"},{"name":"feedback-enabled","description":"When `true`, enables the feedback action in the chat interface, allowing developers to capture user feedback on the assistant's responses.\nThe action simply provides a thumbs up and thumbs down experience for users to indicate whether a response was helpful or not. When the\nuser submits feedback, the [@arcgisFeedback](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#event-arcgisFeedback) event is emitted allowing the app developer to capture additional feedback\nthrough a custom interface and log it to a database or service for later analysis.","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"feedbackEnabled"},{"name":"heading","description":"The heading text displayed at the top of the assistant. This name should be concise and\ndescriptive of the assistant's purpose.\n\nFor applications where the primary interface is the assistant, this heading could also be used as the\napplication title. In cases where the assistant could be collapsed or is a secondary interface to a standard\nGUI, the heading should be more specific to the assistant's function to avoid confusion with the overall\napplication title.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"heading"},{"name":"keep-suggested-prompts","description":"When `true`, keeps suggested prompts displayed in the UI after the user submits a message. By default, suggested prompts are cleared,\nwhen the user submits a message.","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"keepSuggestedPrompts"},{"name":"log-enabled","description":"When `true`, enables the log action that when clicked displays log messages in the chat interface. Log messages provide detailed messages including\nwhich agents or tools were invoked, the parameters generated by the LLM, and any relevant details about how the assistant arrived at its response.\nEnabling logs can be helpful for developers for debugging during the development of an assistant or agentic web application.\nIt may also be useful to end users for transparency purposes, allowing them to understand the assistant's behavior and decision-making process.\n\nEnabling this property for a production app depends on the role of the audience. More technical audiences may benefit from having access to these\nlogs while non-technical audiences may find them overwhelming or confusing.","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"logEnabled"},{"name":"reference-element","description":"The reference element to the map that provides context for the assistant and its agents. Currently,\nthis is only scoped to `arcgis-map` elements. This is required when ArcGIS agents are registered to the assistant.\nFor example, this allows the navigation agent to execute a map navigation tool for a specific map.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"events":[{"name":"arcgisCancel","description":"Emitted when the user cancels a message. This is typically invoked when a user submits a question while a previous question is still being processed.\nThis allows app developers to capture messages cancelled by the user and respond to them in custom ways, such as by providing additional information,\ntriggering other actions in the app, or logging them for analysis.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisCancel\", (event) => {\n // Handle the cancelled message\n});\n```"}],"type":{"text":"void"}},{"name":"arcgisError","description":"Emitted when the assistant encounters an error. The event detail includes an Error object with information about the error that occurred.\nThis allows app developers to capture errors that occur within the assistant and respond to them in custom ways, such as by displaying an\nerror message to the user, logging the error for analysis, or triggering other actions in the app.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisError\", (event) => {\n const error = event.detail;\n // Handle the error, such as by displaying an error message to the user or logging it for analysis\n});\n```"}],"type":{"text":"Error","references":[{"name":"Error","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Error","start":0,"end":5}]}},{"name":"arcgisFeedback","description":"Emitted when the user clicks the thumbs up or thumbs down feedback action that is displayed when [feedbackEnabled](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#feedbackEnabled) is `true`.\nThe event detail includes an AssistantMessage object that includes a feedback property with an object indicating whether the feedback is positive or negative.\nThis allows the application to capture user feedback on the assistant's responses and respond to it in custom ways, such as by providing additional\ninformation, adjusting the assistant's behavior, logging the feedback for analysis, or triggering other actions in the app.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisFeedback\", (event) => {\n const feedback = event.detail;\n // Handle the feedback, such as by providing additional information, adjusting the assistant's behavior, or logging it for analysis\n});\n```"}],"type":{"text":"AssistantMessage","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"name":"arcgisInterrupt","description":"Emitted when an agent triggers an interrupt. An interrupt is a human-in-the-loop mechanism that provides a UI component prompting\nthe user for additional information.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisInterrupt\", (event) => {\n const interrupt = event.detail;\n // Handle the interrupt\n});\n```"}],"type":{"text":"Interrupt","references":[{"name":"Interrupt","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#Interrupt","start":0,"end":9}]}},{"name":"arcgisInterruptCancel","description":"Emitted when the user cancels an interrupt. This is typically invoked when a user clicks the cancel button displayed in an interrupt message","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisInterruptCancel\", (event) => {\n // Handle the interrupt cancellation such as logging it for analysis\n});\n```"}],"type":{"text":"void"}},{"name":"arcgisInterruptSubmit","description":"Emitted when the user submits a message during an interrupt. For example, this will be invoked if the user clicks the submit button\nin an interrupt message asking for confirmation, or when the user submits additional text or selects an option provided in an interrupt.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisInterruptSubmit\", (event) => {\n const message = event.detail; // The message or option selected by the user for the interrupt\n // Do something with the interrupt submission\n});\n```"}],"type":{"text":"string[] | boolean | string"}},{"name":"arcgisPromptSelect","description":"Emitted when a suggested prompt is selected from the assistant UI.\nApplications that provide a custom `chat-entry` slot can listen for this event to sync\nthe selected prompt into their own entry implementation.","docsTags":[{"name":"since","text":"5.1"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisPromptSelect\", (event) => {\n const { prompt } = event.detail;\n // Sync prompt into a custom chat entry\n});\n```"}],"type":{"text":"AssistantPromptSelectDetail","references":[{"name":"AssistantPromptSelectDetail","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantPromptSelectDetail","start":0,"end":27}]}},{"name":"arcgisReady","description":"Emitted when the assistant is ready to receive messages from the end user. This indicates that the assistant has been successfully\ninitialized and is ready to process user input.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisReady\", (event) => {\n // Handle the assistant being ready, such as by hiding a loading indicator,\n // displaying a welcome message, or enabling certain UI elements for user interaction\n});\n```"}],"type":{"text":"void"}},{"name":"arcgisSlottableRequest","description":"Emitted when the assistant requests custom slotted content for an assistant message.\n\nUse this event to render app-provided content into dynamic slot targets created at runtime\nfor assistant responses. The event detail includes:\n- name: conceptual request type\n- slotName: concrete slot target to render into\n- data: payload needed to render or update content\n\nDynamic slot name formats:\n- name = \"message\" -> slotName = \"message-{messageId}\"\n- name = \"block\" -> slotName = \"block-{messageId}-{index}\"","docsTags":[{"name":"since","text":"5.1"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisSlottableRequest\", (event) => {\n const { name, slotName, data } = event.detail;\n\n if (!data) {\n // Remove previously rendered slotted content for this slotName.\n return;\n }\n\n // Render or update app-provided content and set slot=slotName.\n // Optionally branch on name (\"message\" or \"block\") for different rendering.\n});\n```"}],"type":{"text":"AssistantSlottableRequestDetail","references":[{"name":"AssistantSlottableRequestDetail","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantSlottableRequestDetail","start":0,"end":31}]},"bubbles":false,"composed":false},{"name":"arcgisSubmit","description":"Emitted when the user submits a message. This is typically invoked when a user clicks the submit button in the chat interface or hits the Enter key.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisSubmit\", (event) => {\n const message = event.detail;\n // Do something with the submitted message, such as logging it for analysis or triggering other actions in the app\n});\n```"}],"type":{"text":"string"}}],"slots":[{"name":"header-actions-start","description":"Slot for adding actions to the start of the header."},{"name":"header-actions-end","description":"Slot for adding actions to the end of the header."},{"name":"message-starter","description":"Slot for adding content before the message list."},{"name":"messages","description":"Slot for customizing the rendered message list."},{"name":"message-loading","description":"Slot for customizing the in-progress assistant loading state."},{"name":"entry-message","description":"Slot for adding a welcome or entry message on load."},{"name":"interrupt","description":"Slot for customizing the interrupt UI."},{"name":"chat-entry","description":"Slot for customizing the chat entry UI."},{"name":"entry-actions-start","description":"Slot for adding actions to the start of the chat entry."},{"name":"entry-actions-end","description":"Slot for adding actions to the end of the chat entry."},{"name":"footer-content","description":"Slot for adding content below the chat entry."}],"importPath":"components/arcgis-assistant"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant","declaration":{"name":"ArcgisAssistant"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant/types","sourcePath":"src/components/assistant/types.ts","declarations":[{"kind":"interface","name":"Interrupt","description":"An interrupt is a UI mechanism used by an agent to prompt the user for additional input or clarification.","members":[{"kind":"field","name":"id","description":"The unique identifier of the message associated with the interrupt. This is used to associate the interrupt\nwith specific messages.","type":{"text":"string | undefined"}},{"kind":"field","name":"type","description":"The type of interrupt, which determines how the assistant will prompt the user for input. The available types are:\n\n- `boolean-choice`: Presents the user with a yes/no question.\n- `multi-select`: Allows the user to select multiple options from a list using a checkbox interface.\n- `single-select`: Allows the user to select a single option from a list using a radio button interface.\n- `text-input`: Prompts the user to enter free-form text input.\n\nThe assistant will use the specified type to determine how to display the prompt and collect the user's response.\nFor example, a `boolean-choice` interrupt might be used to confirm an action, while a `text-input`\ninterrupt could be used to ask for more details about a request.","type":{"text":"\"boolean-choice\" | \"multi-select\" | \"single-select\" | \"text-input\""}},{"kind":"field","name":"message","description":"The message to display to the user when prompting for input. This should provide clear instructions or questions\nrelated to the interrupt, guiding the user on what information is needed or what action they should take in response\nto the prompt.\n\nFor example, if the interrupt type is `boolean-choice`, the message might be \"Do you want to proceed with this\naction?\" If the type is `text-input`, the message could be \"Please provide more details about your request.\"","type":{"text":"string | undefined"}},{"kind":"field","name":"options","description":"The options to present to the user for selection when the interrupt type is `multi-select` or `single-select`.\nThis should be an array of strings representing the available choices. For `boolean-choice`,\nthe options are implicitly \"Yes\" and \"No\" and do not need to be provided.\nFor `text-input`, options are not applicable and should be omitted.\n\nFor example, if the interrupt type is `multi-select`, the options might be [\"Option 1\", \"Option 2\", \"Option 3\"].\nIf the type is `single-select`, the options could be [\"Choice A\", \"Choice B\", \"Choice C\"].","type":{"text":"string[] | undefined"}}]},{"kind":"interface","name":"AssistantMessage","description":"A chat message sent by the assistant.","supertypes":[{"name":"ChatMessageBase","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessageBase"}],"members":[{"kind":"field","name":"role","type":{"text":"\"assistant\""}},{"kind":"field","name":"content","description":"The content of the assistant's message. This can include text generated by the assistant in response to the user's message. The content is displayed in the chat interface for the user to read and interact with.","type":{"text":"string | undefined"}},{"kind":"field","name":"blocks","description":"Structured response UI blocks associated with the assistant message. These blocks are rendered as interactive\nUI elements separate from the plain text transcript and can be used to display actions, follow-up prompts,\nor app-registered custom content.","type":{"text":"UXSuggestion[] | undefined","references":[{"name":"UXSuggestion","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UXSuggestion","start":0,"end":12}]}},{"kind":"field","name":"log","description":"Log messages related to the assistant's processing of the user's request. This can include information about\nthe agents or tools it invoked, the parameters generated by the LLM, and any relevant details about how it\narrived at its response. Log messages are primarily intended for debugging and transparency purposes, allowing\ndevelopers and users to understand the assistant's behavior and decision-making process.","type":{"text":"string[] | undefined"}},{"kind":"field","name":"error","description":"An error message indicating any issues that occurred while the assistant was processing the user's request.\nThe error message may be displayed in the chat interface to inform the user of the issue and can also be used for\ndebugging and improving the assistant's performance.","type":{"text":"string | undefined"}},{"kind":"field","name":"feedback","description":"Feedback provided by the user for this specific assistant message. This allows users to indicate whether the\nassistant's response was helpful or not, which the app developer can capture and use to improve the assistant's\nperformance over time.","type":{"text":"Feedback | undefined","references":[{"name":"Feedback","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#Feedback","start":0,"end":8}]}}]},{"kind":"interface","name":"ChatMessage","description":"A chat message from the user or the assistant. Messages include all relevant information such as content,\nlogs, errors, and feedback.","type":{"text":"AssistantMessage | UserMessage","references":[{"name":"AssistantMessage","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16},{"name":"UserMessage","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#UserMessage","start":19,"end":30}]}},{"kind":"interface","name":"AssistantPromptSelectDetail","description":"Detail payload emitted when a suggested prompt is selected.","members":[{"kind":"field","name":"prompt","description":"The selected suggested prompt value.","type":{"text":"string"}}]},{"kind":"interface","name":"AssistantSlottableRequestDetail","description":"Detail payload emitted by the assistant slottable request event.","members":[{"kind":"field","name":"name","description":"The request name describing the slot being requested.","type":{"text":"AssistantSlottableRequestName","references":[{"name":"AssistantSlottableRequestName","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantSlottableRequestName","start":0,"end":29}]}},{"kind":"field","name":"slotName","description":"The slot name consumers should target when appending light DOM content.","type":{"text":"string"}},{"kind":"field","name":"data","description":"Data describing the current slot request.","type":{"text":"AssistantSlottableRequestData | undefined","references":[{"name":"AssistantSlottableRequestData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantSlottableRequestData","start":0,"end":29}]}}]},{"kind":"interface","name":"ChatMessageBase","description":"The base interface for chat messages exchanged between the user and the assistant.","members":[{"kind":"field","name":"id","description":"The unique identifier for the message. This is used to associate messages with interrupts and feedback.\nIf not provided, a unique ID will be generated automatically.","type":{"text":"string"}}]},{"kind":"interface","name":"UserMessage","description":"A chat message sent by the user.","supertypes":[{"name":"ChatMessageBase","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessageBase"}],"members":[{"kind":"field","name":"role","type":{"text":"\"user\""}},{"kind":"field","name":"content","description":"The content of the user's message. This is the text input provided by the user in the chat interface.\nThis content is sent to the assistant and its agents for processing and generating responses.","type":{"text":"string"}}]},{"kind":"interface","name":"Feedback","description":"Feedback provided by the user for a specific message.","members":[{"kind":"field","name":"positive","description":"Indicates whether the feedback is positive or negative.","type":{"text":"boolean"}}]},{"kind":"interface","name":"AssistantSlottableRequestData","description":"Data emitted with an assistant slottable request.","members":[{"kind":"field","name":"message","description":"The assistant message associated with the slot request.","type":{"text":"AssistantMessage","references":[{"name":"AssistantMessage","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"field","name":"block","description":"The block associated with the slot request, when requesting block content.","type":{"text":"UXSuggestion | undefined","references":[{"name":"UXSuggestion","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UXSuggestion","start":0,"end":12}]}},{"kind":"field","name":"index","description":"Zero-based index of the block associated with the slot request.","type":{"text":"number | undefined"}}]},{"kind":"interface","name":"AssistantSlottableRequestName","description":"Supported assistant slottable request names.","type":{"text":"\"block\" | \"message\""}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-agent/assistant-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantAgent","customElement":true,"tagName":"arcgis-assistant-agent","pascalCaseName":"ArcgisAssistantAgent","description":"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\na custom agent, you must be familiar with [LangGraph](https://docs.langchain.com/oss/javascript/langgraph/overview). Custom agents must\ninclude a StateGraph that defines the agent's graph and subgraphs.\n\nBuilding custom agents can only be done using modern JavaScript/TypeScript tooling and cannot be done directly in HTML using\nCDN imports. Therefore, you must use a package manager like npm or yarn to install the required dependencies. Please refer to the\n[Custom Agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/) for more instructions on how to create a custom agent.\n\nUse the [utils](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/) module for helper functions and types related to building custom agents, including the `AgentRegistration`\ntype and functions for making LLM calls, managing agent state, and setting up human-in-the-loop workflows.\n\n> We recommend that developers building custom agents have experience working with LLMs and generative AI, and have a good\nunderstanding of the limitations of these technologies when building applications for end users.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in either HTML or JavaScript.\n\n```html\n<arcgis-assistant></arcgis-assistant>\n```\n\n```js\nconst myCustomAgent = {\n id: \"my-custom-agent\",\n name: \"My Custom Agent\",\n description: \"An agent that does custom things. Use this agent when users want to do custom things.\",\n createGraph: {\n // StateGraph definition using LangGraph\n },\n workspace: {\n // AnnotationRoot definition using LangGraph\n // relevant variables and context required by the agent\n },\n};\n\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst assistantAgent = document.createElement(\"arcgis-assistant-agent\");\n\nassistantAgent.agent = myCustomAgent;\nassistant.appendChild(assistantAgent);\n```","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"},{"name":"see","text":"[AgentRegistration](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration)"},{"name":"see","text":"[invokeStructuredPrompt](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#invokeStructuredPrompt)"},{"name":"see","text":"[invokeToolPrompt](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#invokeToolPrompt)"},{"name":"see","text":"[invokeTextPrompt](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#invokeTextPrompt)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-agent/"}],"typeParameters":[{"name":"TContext","default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"agent","description":"The agent registration object that defines the AI agent's behavior and capabilities.\nThis must include a StateGraph definition (defined using\n[LangGraph](https://docs.langchain.com/oss/javascript/langgraph/overview)).\n\nThis is an agent defined in the client and can be invoked by the assistant from the browser to perform specific tasks\nusing functions defined in the client.\n\nSee the [Custom Agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/) for more instructions\nand links to samples demonstrating how to create custom agents.","docsTags":[{"name":"required"},{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"},{"name":"example","text":"```js\n// An example graph that updates a component property and replies with a confirmation message\nconst myCustomGraph = () => {\n const graph = new StateGraph(myCustomState)\n .addNode(\"updateComponentProperty\", updateComponentProperty)\n .addNode(\"replyComponentPropertyUpdate\", replyComponentPropertyUpdate)\n .addEdge(START, \"updateComponentProperty\")\n .addEdge(\"updateComponentProperty\", \"replyComponentPropertyUpdate\")\n .addEdge(\"replyComponentPropertyUpdate\", END);\n\n return graph;\n};\n\nconst myCustomAgentState = Annotation.Root({\n // This is required to keep track of chat messages between the user and the agent\n messages: Annotation<ChatHistory>({\n reducer: messagesStateReducer,\n default: () => [],\n }),\n // Accumulates user-visible output across graph nodes\n outputMessage: Annotation<string>({\n reducer: (current = \"\", update) =>\n typeof update === \"string\" && update.trim()\n ? current\n ? `${current}\\n\\n${update}`\n : update\n : current,\n default: () => \"\",\n }),\n // Result of the UI action performed by the agent\n // This is a custom type defined by the application\n result: Annotation<UIActionResult | null>({\n reducer: (_current, update) => update ?? null,\n default: () => null,\n }),\n});\n\nconst myCustomAgent = {\n id: \"my-custom-agent\",\n name: \"My Custom Agent\",\n description: \"An agent that does custom things. Use this agent when users want to do custom things.\",\n createGraph: myCustomGraph,\n workspace: myCustomAgentState,\n};\n\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst assistantAgent = document.createElement(\"arcgis-assistant-agent\");\n\nassistantAgent.agent = myCustomAgent;\nassistant.appendChild(assistantAgent);\n```"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"field","name":"context","description":"If the agent requires context provided by the application or user, it can be provided via this property and accessed in the\nagent's graph nodes.","docsTags":[{"name":"example","text":"```js\nassistantAgent.context = {\n myData: {\n // data required for the custom agent\n },\n};\n```"}],"type":{"text":"TContext | (() => Promise<TContext | undefined> | TContext | undefined) | undefined","references":[{"name":"TContext","start":0,"end":8},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":18,"end":25},{"name":"TContext","start":26,"end":34},{"name":"TContext","start":50,"end":58}]}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantAgent = document.createElement(\"arcgis-assistant-agent\");\ndocument.body.append(arcgisAssistantAgent);\nawait arcgisAssistantAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"importPath":"components/arcgis-assistant-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-agent","declaration":{"name":"ArcgisAssistantAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-data-exploration-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-data-exploration-agent/assistant-data-exploration-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantDataExplorationAgent","customElement":true,"tagName":"arcgis-assistant-data-exploration-agent","pascalCaseName":"ArcgisAssistantDataExplorationAgent","description":"The Data Exploration Agent enables the end user to query features, statistics, and spatial proximity\nto features in a layer within a web map. Currently, this is only scoped to querying feature layers within\na 2D web map. See the list of capabilities below for more details.\n\nThe data exploration agent is designed to answer questions about the data in the map, and does not have\naccess to external data sources or the user's location. It also cannot create visualizations in the form of charts,\nlayer renderers, new maps, or other visual outputs. It can currently only provide answers in text form based on the\ndata in the map.\n\nThis agent can change the state of the map by filtering features in a layer, but it cannot change the symbology of\nfeatures or create new layers or export results of a query to a file or external source.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in either HTML or JavaScript.\n\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"my-map\">\n <arcgis-assistant-data-exploration-agent></arcgis-assistant-data-exploration-agent>\n</arcgis-assistant>\n```\n\n```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst dataExplorationAgent = document.createElement(\"arcgis-assistant-data-exploration-agent\");\nassistant.appendChild(dataExplorationAgent);\n```\n\nOnce added to the assistant, the agent is loaded and ready to receive user messages related to data exploration.\n\n### Capabilities\n\nThe data exploration agent provides the following capabilities related to exploring data in the map:\n\n- **Query features** - Ask about the attributes of features in a layer, including a single feature or a set\n of features.\n- **Query statistics** - Ask about statistics related to features in a layer. Statistics that can be queried\n include count, average, minimum, maximum, and sum. This includes asking about the top number of features based on a\n particular attribute.\n- **Query spatial proximity** - Ask about the spatial proximity of features in a layer, such as\n the number of features that intersect a polygon, or information about features within a distance of a specified location or feature.\n This currently does not include questions about the closest feature, but this is planned to be included in a future release.\n- **Filter features** - Users can ask the agent to show a subset of features that filter by attributes, or spatial\n proximity to other features. This includes asking the agent to show features that intersect a particular area,\n or are within a certain distance of a location or feature.\n\n### Example questions\n\nThe following are example questions a user can ask within the bounds of the data exploration agent.\nThese questions assume a map with layers that include cities, states, and rivers.\n\n- \"What is the city with the largest population?\"\n- \"How does that population compare to the average population of the cities in this map?\"\n- \"How many cities are within 30 miles of the Colorado River?\"\n- \"Show all cities in the state of California.\"\n- \"List the top 5 rivers by length.\"\n- \"Emphasize the largest river on the map.\"\n\nThe following are examples of the types of questions that fall outside the bounds of the\ndata exploration agent and should therefore be avoided:\n\n- \"What is the closest restaurant to me?\" (the data exploration agent does not have access to the user's location,\nnor can it find the nearest feature from a location)\n- \"What is the projected growth of Phoenix in the next 10 years?\" (the data exploration agent can\nonly answer questions about the data in the map, not external data or projections)\n- \"Show me the population of cities in this map on a graph.\" (the data exploration agent can only\nprovide answers in text form, not visualizations)\n\n> Due to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents.","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-data-exploration-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the data exploration agent. Currently,\nthis is only scoped to `arcgis-map` elements. This provides the data exploration agent with the layers\nneeded for answering user questions about the data in the map.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","docsTags":[{"name":"see","text":"[arcgis-assistant.referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement)"},{"name":"example","text":"```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant>\n <arcgis-assistant-data-exploration-agent reference-element=\"my-map\"></arcgis-assistant-data-exploration-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"ArcgisMap | string | undefined","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantDataExplorationAgent = document.createElement(\"arcgis-assistant-data-exploration-agent\");\ndocument.body.append(arcgisAssistantDataExplorationAgent);\nawait arcgisAssistantDataExplorationAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-data-exploration-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","description":"The reference element to the map that provides context for the data exploration agent. Currently,\nthis is only scoped to `arcgis-map` elements. This provides the data exploration agent with the layers\nneeded for answering user questions about the data in the map.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"importPath":"components/arcgis-assistant-data-exploration-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-data-exploration-agent","declaration":{"name":"ArcgisAssistantDataExplorationAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-help-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-help-agent/assistant-help-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantHelpAgent","customElement":true,"tagName":"arcgis-assistant-help-agent","pascalCaseName":"ArcgisAssistantHelpAgent","description":"The Help Agent provides contextual assistance and guidance to the end user within an\nagentic web mapping application. It can provide answers to questions about the web map provided\nto the [referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-help-agent/#referenceElement) property and answer questions about other agents included\nas subcomponents to the [arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/) component.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in\neither HTML or JavaScript.\n\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"my-map\">\n <arcgis-assistant-help-agent></arcgis-assistant-help-agent>\n</arcgis-assistant>\n```\n\n```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst helpAgent = document.createElement(\"arcgis-assistant-help-agent\");\nassistant.appendChild(helpAgent);\n```\n\nOnce added to the assistant, the agent is loaded and ready to receive user messages related to help and guidance.\n\n### Example questions\n\nThe following are example questions a user can ask within the bounds of the help agent:\n\n- \"What kind of questions can I ask?\"\n- \"What layers are in this map?\"\n- \"What kind of data can I ask questions about?\"\n\nThe following are examples of the types of questions that fall outside the bounds of the\nhelp agent and should therefore be avoided:\n\n- \"Search the Esri documentation for ways that I can query my data.\"\n- \"Log a bug related to map navigation to the Esri support team.\"\n- \"How do I bake a cake?\"\n- \"How does map navigation work in ArcGIS?\"\n\n> Due to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents.","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-help-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the help agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the help agent which map for which to\nprovide assistance. This allows users to ask questions about the specific map provided to the agent.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","docsTags":[{"name":"see","text":"[arcgis-assistant.referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement)"},{"name":"example","text":"```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant>\n <arcgis-assistant-help-agent reference-element=\"my-map\"></arcgis-assistant-help-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"ArcgisMap | string | undefined","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantHelpAgent = document.createElement(\"arcgis-assistant-help-agent\");\ndocument.body.append(arcgisAssistantHelpAgent);\nawait arcgisAssistantHelpAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-help-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","description":"The reference element to the map that provides context for the help agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the help agent which map for which to\nprovide assistance. This allows users to ask questions about the specific map provided to the agent.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"importPath":"components/arcgis-assistant-help-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-help-agent","declaration":{"name":"ArcgisAssistantHelpAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-knowledge-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-knowledge-agent/assistant-knowledge-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantKnowledgeAgent","customElement":true,"tagName":"arcgis-assistant-knowledge-agent","pascalCaseName":"ArcgisAssistantKnowledgeAgent","description":"The Knowledge Agent enables the end user to explore knowledge graph data in a [link chart](https://developers.arcgis.com/javascript/latest/references/core/WebLinkChart/), a\n [knowledge graph service](https://developers.arcgis.com/javascript/latest/references/core/rest/knowledgeGraphService/), or a [knowledge graph layer](https://developers.arcgis.com/javascript/latest/references/core/layers/KnowledgeGraphLayer/) in a map via natural language queries. It also provides additional capabilities when used with a knowledge graph layer or link chart. See the list of capabilities below for more details.\n\nThe knowledge agent is designed to answer questions about data in the knowledge graph provided by the knowledge graph layer on map,\na link chart or a knowledge graph service url, and does not have access to external data sources or the user's location.\n\nIt cannot create visualizations in the form of charts, layer renderers, new maps, or other visual outputs.\nWhen provided a link chart as context, it can create new link charts based on queries generated from user prompts.\n\nThis agent can add to the knowledge graph data on a map or link chart if a user prompt generates a query that returns entities\nor relationships from the graph and asks for the returned results to be added to the view.\nIt can also change the layout of a link chart or toggle visibility of non-spatial data on a link chart.\nHowever, it cannot change the symbology of\nfeatures or create new layers or export results of a query to a file or external source.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in either HTML or JavaScript.\n\nLink Chart context example:\n```html\n<arcgis-link-chart id=\"my-link-chart\"></arcgis-link-chart>\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent reference-element=\"my-link-chart\"></arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```\n\nMap context example:\nNote: the map must contain one knowledge graph layer.\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent reference-element=\"my-map\"></arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```\n\nKnowledge Graph Service context example:\n```html\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent\n service-url=\"https://example.com/server/rest/services/Hosted/myKnowledgeGraph/KnowledgeGraphServer\"\n >\n </arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```\n\nOnce added to the assistant, the agent is loaded and ready to receive user messages directed to their knowledge graph related layers or data.\n\n### Capabilities\n\nThe knowledge agent provides the following capabilities related to a knowledge graph or associated knowledge graph layer or link chart layer:\n\n- **Query** - Ask about the entities and relationships in my graph. This includes questions about connections between entities and\npatterns in the graph, as well as questions about the structure of the graph such as the types of entities and relationships and the\nnumber of each type.\nReturns the results of the query in text form, and can optionally add returned\nentities or relationships to the map or link chart view if the user prompt requests it.\n- **Search** - Search for specific entities or relationships in the knowledge graph, or the closest matches based on their properties.\nReturns the results of the search in text form, and can optionally add returned entities or relationships to the map or link chart\nview if the user prompt requests it.\n- **Generate Cypher Query** - Generates and returns a cypher query based on a natural language question and the current knowledge\ngraph data model,\nwhich can be run against the knowledge graph service.\n\nAdditional capabilities with a map view with a knowledge graph layer or a link chart view\n\n- **Add entities and relationships** - Add entities or relationships the the knowledge graph or link chart layer based on results returned from searches or queries generated from user prompts.\n\nAdditional capabilities with a link chart view only\n\n- **Change link chart layout** - Change the layout of the link chart between different modes such as force directed, radial, or hierarchical.\n- **Toggle non-spatial visibility** - Show or hide non-spatial entities and relationships on the link chart.\n- **Create link chart from query** - Recreate the link chart with new entities and relationships based on a query generated from the\nuser prompt.\n\n\n### Example questions\n\nThe following are example questions a user can ask within the bounds of the knowledge agent:\n\n- \"What entities are in this graph, and what is the count of each entity type?\"\n- \"Who are the top 5 entities most connected to Company X?\"\n- \"Find all employees with the last name Smith.\"\n- \"What is the most influential company in this graph?\"\n- \"Generate a cypher query to find all employees of Company X that joined the company after 2022 who worked for a competitor before joining Company X.\"\n- \"Add all connections between Company X and Company Y to the link chart\"\n- \"Change the layout to hierarchical\"\n- \"Hide non spatial data on the link chart\"\n- \"Create a new link chart with all employees from Company X that joined the company after 2015 and are located in California\"\n\n> Due to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents.","docsTags":[{"name":"since","text":"5.1"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-knowledge-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"context","description":"Required and optional context for the knowledge agent. The knowledge agent requires either a link chart view,\na map view with at least one knowledge graph layer, or KnowledgeGraph instance in order to function.\n\nDepending on the context provided, different capabilities will be available.","type":{"text":"ArcgisKnowledgeContext | undefined","references":[{"name":"ArcgisKnowledgeContext","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-knowledge-agent/#ArcgisKnowledgeContext","start":0,"end":22}]}},{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the navigation agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the navigation agent which map on which to\nperform navigation actions. This is required for the navigation agent to function properly.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","docsTags":[{"name":"see","text":"[arcgis-assistant.referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement)"},{"name":"example","text":"```html\n<arcgis-link-chart id=\"my-link-chart\"></arcgis-link-chart>\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent reference-element=\"my-link-chart\"></arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"ArcgisLinkChart | ArcgisMap | string | undefined","references":[{"name":"ArcgisLinkChart","module":"components/arcgis-link-chart","package":"@arcgis/map-components","start":0,"end":15},{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":18,"end":27}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"field","name":"serviceUrl","description":"The URL of a Knowledge Graph Service. This can be set to use the agent without a map or link chart view.\n\nIf a map or link chart view reference element are provided, this property will be ignored.","docsTags":[{"name":"example","text":"```html\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent service-url=\"https://example.esri.com/server/rest/services/Hosted/KGS_Service_Name/KnowledgeGraphServer\"></arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"null | undefined | string","values":[{"type":"string"}]},"attribute":"service-url","reflects":true},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantKnowledgeAgent = document.createElement(\"arcgis-assistant-knowledge-agent\");\ndocument.body.append(arcgisAssistantKnowledgeAgent);\nawait arcgisAssistantKnowledgeAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-knowledge-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","description":"The reference element to the map that provides context for the navigation agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the navigation agent which map on which to\nperform navigation actions. This is required for the navigation agent to function properly.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"},{"name":"service-url","description":"The URL of a Knowledge Graph Service. This can be set to use the agent without a map or link chart view.\n\nIf a map or link chart view reference element are provided, this property will be ignored.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"serviceUrl"}],"importPath":"components/arcgis-assistant-knowledge-agent"},{"kind":"interface","name":"ArcgisKnowledgeContext","description":"Context required by the Knowledge Link Chart agent.\nSupplied by the application via an agent `getContext()` provider.","type":{"text":"{\n knowledgeGraph: KnowledgeGraph;\n view?: never;\n} | {\n view: LinkChartView | MapView;\n knowledgeGraph?: never;\n}","references":[{"name":"default","module":"rest/knowledgeGraph/KnowledgeGraph.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/rest/knowledgeGraph/KnowledgeGraph/","start":22,"end":36},{"name":"default","module":"views/LinkChartView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/LinkChartView/","start":72,"end":85},{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":88,"end":95}]}}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-knowledge-agent","declaration":{"name":"ArcgisAssistantKnowledgeAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-layer-styling-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-layer-styling-agent/assistant-layer-styling-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantLayerStylingAgent","customElement":true,"tagName":"arcgis-assistant-layer-styling-agent","pascalCaseName":"ArcgisAssistantLayerStylingAgent","docsTags":[{"name":"internal"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-layer-styling-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"referenceElement","type":{"text":"ArcgisMap | string | undefined","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantLayerStylingAgent = document.createElement(\"arcgis-assistant-layer-styling-agent\");\ndocument.body.append(arcgisAssistantLayerStylingAgent);\nawait arcgisAssistantLayerStylingAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-layer-styling-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"importPath":"components/arcgis-assistant-layer-styling-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-layer-styling-agent","declaration":{"name":"ArcgisAssistantLayerStylingAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-navigation-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-navigation-agent/assistant-navigation-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantNavigationAgent","customElement":true,"tagName":"arcgis-assistant-navigation-agent","pascalCaseName":"ArcgisAssistantNavigationAgent","description":"The Navigation Agent enables the end user to navigate to different areas of a web map. See the list\nof capabilities below for more details.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in either HTML or JavaScript.\n\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"my-map\">\n <arcgis-assistant-navigation-agent></arcgis-assistant-navigation-agent>\n</arcgis-assistant>\n```\n\n```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst navigationAgent = document.createElement(\"arcgis-assistant-navigation-agent\");\nassistant.appendChild(navigationAgent);\n```\n\nOnce added to the assistant, the agent is loaded and ready to receive user messages related to navigation.\n\n### Capabilities\n\nThe navigation agent provides the following capabilities related to map navigation:\n\n- **Geocoding** - Navigate to an address using Esri's World Geocoding Service.\n- **Go to extent** - Navigate to the extent of a bookmark in the map, the home extent of the web map,\n or the extent of a layer.\n- **Go to features** - Navigate to a specified feature or set of features.\n- **Go to viewpoint** - Navigate to a specified viewpoint, which can include center, zoom, and/or\n rotation.\n\n### Example questions\n\nThe following are example questions a user can ask within the bounds of the navigation agent:\n\n- \"Go to the Golden Gate Bridge\"\n- \"Zoom to a 1 to 24,000 scale\"\n- \"Zoom in\"\n- \"Go to the parks layer\"\n\nThe following are examples of the types of questions that fall outside the bounds of the\nnavigation agent and should therefore be avoided:\n\n- \"Rotate the map 45 degrees\" (this capability is not currently supported but may be in the future)\n- \"Make this map 3D and tilt the view to a 45 degree angle\" (3D navigation is currently not supported)\n- \"Where am I?\" (the navigation agent does not have access to the user's location)\n\n> Due to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents.","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-navigation-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the navigation agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the navigation agent which map on which to\nperform navigation actions. This is required for the navigation agent to function properly.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","docsTags":[{"name":"see","text":"[arcgis-assistant.referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement)"},{"name":"example","text":"```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant>\n <arcgis-assistant-navigation-agent reference-element=\"my-map\"></arcgis-assistant-navigation-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"ArcgisMap | string | undefined","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantNavigationAgent = document.createElement(\"arcgis-assistant-navigation-agent\");\ndocument.body.append(arcgisAssistantNavigationAgent);\nawait arcgisAssistantNavigationAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-navigation-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","description":"The reference element to the map that provides context for the navigation agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the navigation agent which map on which to\nperform navigation actions. This is required for the navigation agent to function properly.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"importPath":"components/arcgis-assistant-navigation-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-navigation-agent","declaration":{"name":"ArcgisAssistantNavigationAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-chat","sourcePath":"src/components/assistant/assistant-chat/assistant-chat.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantChat","customElement":true,"tagName":"arcgis-assistant-chat","pascalCaseName":"ArcgisAssistantChat","description":"Wraps and renders the conversation area. Use it as the container for message list content.\nOffers chat-level layout structure for message starter, message list, and loading regions.","docsTags":[{"name":"internal"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-chat/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"loading","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"loading"},{"kind":"field","name":"messages","type":{"text":"Collection<ChatMessage>","references":[{"name":"default","module":"core/Collection.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Collection/","start":0,"end":10},{"name":"ChatMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessage","start":11,"end":22}]}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantChat = document.createElement(\"arcgis-assistant-chat\");\ndocument.body.append(arcgisAssistantChat);\nawait arcgisAssistantChat.componentOnReady();\nconsole.log(\"arcgis-assistant-chat is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"loading","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"loading"}],"importPath":"components/arcgis-assistant-chat"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-chat","declaration":{"name":"ArcgisAssistantChat"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-chat-entry","sourcePath":"src/components/assistant/assistant-chat-entry/assistant-chat-entry.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantChatEntry","customElement":true,"tagName":"arcgis-assistant-chat-entry","pascalCaseName":"ArcgisAssistantChatEntry","description":"Provides the input bar and submit or cancel behavior. Use it to collect prompts and emit submit events.\nOffers keyboard submit/history behavior, entry action slots, and optional voice-input integration.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-chat-entry/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"awaitingResponse","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"awaiting-response"},{"kind":"field","name":"entryPlaceholder","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"entry-placeholder"},{"kind":"field","name":"inputValue","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","attribute":"input-value"},{"kind":"field","name":"keyboardShortcutsDisabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"keyboard-shortcuts-disabled"},{"kind":"field","name":"messages","type":{"text":"Collection<ChatMessage>","references":[{"name":"default","module":"core/Collection.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Collection/","start":0,"end":10},{"name":"ChatMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessage","start":11,"end":22}]}},{"kind":"field","name":"status","type":{"text":"\"error\" | \"ready\" | \"working\" | undefined","values":[{"type":"string","value":"error"},{"type":"string","value":"ready"},{"type":"string","value":"working"}]},"attribute":"status"},{"kind":"field","name":"voiceInputEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"voice-input-enabled"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantChatEntry = document.createElement(\"arcgis-assistant-chat-entry\");\ndocument.body.append(arcgisAssistantChatEntry);\nawait arcgisAssistantChatEntry.componentOnReady();\nconsole.log(\"arcgis-assistant-chat-entry is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"},{"kind":"method","name":"submitMessage","return":{"type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}},"signature":"(): Promise<void>"}],"attributes":[{"name":"awaiting-response","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"awaitingResponse"},{"name":"entry-placeholder","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"entryPlaceholder"},{"name":"input-value","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","fieldName":"inputValue"},{"name":"keyboard-shortcuts-disabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"keyboardShortcutsDisabled"},{"name":"status","type":{"text":"\"error\" | \"ready\" | \"working\"","values":[{"type":"string","value":"error"},{"type":"string","value":"ready"},{"type":"string","value":"working"}]},"fieldName":"status"},{"name":"voice-input-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"voiceInputEnabled"}],"events":[{"name":"arcgisCancel","type":{"text":"void"}},{"name":"arcgisSubmit","type":{"text":"string"}}],"slots":[{"name":"entry-actions-start","description":"Slot for adding actions to the start of the entry area."},{"name":"entry-actions-end","description":"Slot for adding actions to the end of the entry area."}],"importPath":"components/arcgis-assistant-chat-entry"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-chat-entry","declaration":{"name":"ArcgisAssistantChatEntry"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-interrupt","sourcePath":"src/components/assistant/assistant-interrupt/assistant-interrupt.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantInterrupt","customElement":true,"tagName":"arcgis-assistant-interrupt","pascalCaseName":"ArcgisAssistantInterrupt","description":"Renders interrupt prompts for extra user input. Use it when an agent pauses for confirmation, choice, or text input.\nOffers interrupt-specific input modes and submit or cancel event handling.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-interrupt/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"message","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"message"},{"kind":"field","name":"options","type":{"text":"string[] | undefined"}},{"kind":"field","name":"type","type":{"text":"\"boolean-choice\" | \"multi-select\" | \"single-select\" | \"text-input\"","values":[{"type":"string","value":"boolean-choice"},{"type":"string","value":"multi-select"},{"type":"string","value":"single-select"},{"type":"string","value":"text-input"}]},"attribute":"type"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantInterrupt = document.createElement(\"arcgis-assistant-interrupt\");\ndocument.body.append(arcgisAssistantInterrupt);\nawait arcgisAssistantInterrupt.componentOnReady();\nconsole.log(\"arcgis-assistant-interrupt is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"message","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"message"},{"name":"type","type":{"text":"\"boolean-choice\" | \"multi-select\" | \"single-select\" | \"text-input\"","values":[{"type":"string","value":"boolean-choice"},{"type":"string","value":"multi-select"},{"type":"string","value":"single-select"},{"type":"string","value":"text-input"}]},"fieldName":"type"}],"events":[{"name":"arcgisCancel","type":{"text":"void"}},{"name":"arcgisSubmit","type":{"text":"string[] | boolean | string"}}],"importPath":"components/arcgis-assistant-interrupt"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-interrupt","declaration":{"name":"ArcgisAssistantInterrupt"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message","sourcePath":"src/components/assistant/assistant-message/assistant-message.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessage","customElement":true,"tagName":"arcgis-assistant-message","pascalCaseName":"ArcgisAssistantMessage","description":"Renders a single assistant response message shell. Pass one assistant message object and let it host body and footer actions.\nOffers a reusable assistant-message layout with icon, content, and footer slot regions.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"copyEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"copy-enabled"},{"kind":"field","name":"feedbackEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"feedback-enabled"},{"kind":"field","name":"footerDisabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"footer-disabled"},{"kind":"field","name":"logEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"log-enabled"},{"kind":"field","name":"message","type":{"text":"AssistantMessage | undefined","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"field","name":"readAloudEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"read-aloud-enabled"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessage = document.createElement(\"arcgis-assistant-message\");\ndocument.body.append(arcgisAssistantMessage);\nawait arcgisAssistantMessage.componentOnReady();\nconsole.log(\"arcgis-assistant-message is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"copy-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"copyEnabled"},{"name":"feedback-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"feedbackEnabled"},{"name":"footer-disabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"footerDisabled"},{"name":"log-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"logEnabled"},{"name":"read-aloud-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"readAloudEnabled"}],"importPath":"components/arcgis-assistant-message"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message","declaration":{"name":"ArcgisAssistantMessage"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-block","sourcePath":"src/components/assistant/assistant-message-block/assistant-message-block.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageBlock","customElement":true,"tagName":"arcgis-assistant-message-block","pascalCaseName":"ArcgisAssistantMessageBlock","description":"Renders one structured assistant block. Offers default block rendering for supported suggestion-style blocks.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-block/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"block","type":{"text":"UXSuggestion | undefined","references":[{"name":"UXSuggestion","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UXSuggestion","start":0,"end":12}]}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageBlock = document.createElement(\"arcgis-assistant-message-block\");\ndocument.body.append(arcgisAssistantMessageBlock);\nawait arcgisAssistantMessageBlock.componentOnReady();\nconsole.log(\"arcgis-assistant-message-block is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"importPath":"components/arcgis-assistant-message-block"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-block","declaration":{"name":"ArcgisAssistantMessageBlock"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-feedback","sourcePath":"src/components/assistant/assistant-message-feedback/assistant-message-feedback.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageFeedback","customElement":true,"tagName":"arcgis-assistant-message-feedback","pascalCaseName":"ArcgisAssistantMessageFeedback","description":"Handles thumbs up or down feedback UI. Use it to capture helpful or not helpful signals per response.\nOffers feedback toggle behavior and emits feedback updates for the associated assistant message.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-feedback/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"feedbackEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"feedback-enabled"},{"kind":"field","name":"message","type":{"text":"AssistantMessage | undefined","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageFeedback = document.createElement(\"arcgis-assistant-message-feedback\");\ndocument.body.append(arcgisAssistantMessageFeedback);\nawait arcgisAssistantMessageFeedback.componentOnReady();\nconsole.log(\"arcgis-assistant-message-feedback is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"feedback-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"feedbackEnabled"}],"events":[{"name":"arcgisFeedback","type":{"text":"AssistantMessage","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}}],"importPath":"components/arcgis-assistant-message-feedback"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-feedback","declaration":{"name":"ArcgisAssistantMessageFeedback"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-footer","sourcePath":"src/components/assistant/assistant-message-footer/assistant-message-footer.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageFooter","customElement":true,"tagName":"arcgis-assistant-message-footer","pascalCaseName":"ArcgisAssistantMessageFooter","description":"Renders the action row under an assistant message. Use it when you want feedback, log, copy, or read-aloud controls.\nOffers one footer surface that composes common assistant response actions.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-footer/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"copyEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"copy-enabled"},{"kind":"field","name":"feedbackEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"feedback-enabled"},{"kind":"field","name":"logEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"log-enabled"},{"kind":"field","name":"message","type":{"text":"AssistantMessage | undefined","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"field","name":"readAloudEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"read-aloud-enabled"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageFooter = document.createElement(\"arcgis-assistant-message-footer\");\ndocument.body.append(arcgisAssistantMessageFooter);\nawait arcgisAssistantMessageFooter.componentOnReady();\nconsole.log(\"arcgis-assistant-message-footer is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"copy-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"copyEnabled"},{"name":"feedback-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"feedbackEnabled"},{"name":"log-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"logEnabled"},{"name":"read-aloud-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"readAloudEnabled"}],"importPath":"components/arcgis-assistant-message-footer"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-footer","declaration":{"name":"ArcgisAssistantMessageFooter"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-loading","sourcePath":"src/components/assistant/assistant-message-loading/assistant-message-loading.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageLoading","customElement":true,"tagName":"arcgis-assistant-message-loading","pascalCaseName":"ArcgisAssistantMessageLoading","description":"Shows in-progress assistant response UI. Use it to display thinking or loading state while work is running.\nOffers a default loading message shell with icon/content slot overrides.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-loading/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"loading","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"loading"},{"kind":"field","name":"loadingMessage","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","attribute":"loading-message"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageLoading = document.createElement(\"arcgis-assistant-message-loading\");\ndocument.body.append(arcgisAssistantMessageLoading);\nawait arcgisAssistantMessageLoading.componentOnReady();\nconsole.log(\"arcgis-assistant-message-loading is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"loading","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"loading"},{"name":"loading-message","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","fieldName":"loadingMessage"}],"importPath":"components/arcgis-assistant-message-loading"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-loading","declaration":{"name":"ArcgisAssistantMessageLoading"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-log","sourcePath":"src/components/assistant/assistant-message-log/assistant-message-log.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageLog","customElement":true,"tagName":"arcgis-assistant-message-log","pascalCaseName":"ArcgisAssistantMessageLog","description":"Renders expandable execution log details. Use it when exposing agent or tool trace output.\nOffers collapsible log entry rendering for debugging and troubleshooting.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-log/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"log","type":{"text":"string[] | undefined"}},{"kind":"field","name":"logEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"log-enabled"},{"kind":"field","name":"showLog","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"show-log"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageLog = document.createElement(\"arcgis-assistant-message-log\");\ndocument.body.append(arcgisAssistantMessageLog);\nawait arcgisAssistantMessageLog.componentOnReady();\nconsole.log(\"arcgis-assistant-message-log is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"log-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"logEnabled"},{"name":"show-log","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"showLog"}],"importPath":"components/arcgis-assistant-message-log"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-log","declaration":{"name":"ArcgisAssistantMessageLog"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-read-aloud","sourcePath":"src/components/assistant/assistant-message-read-aloud/assistant-message-read-aloud.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageReadAloud","customElement":true,"tagName":"arcgis-assistant-message-read-aloud","pascalCaseName":"ArcgisAssistantMessageReadAloud","description":"Adds text-to-speech playback controls. Use it to read assistant responses aloud.\nOffers read-aloud start/stop behavior with supported-state handling.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-read-aloud/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"message","type":{"text":"AssistantMessage | undefined","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"field","name":"readAloudEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"read-aloud-enabled"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageReadAloud = document.createElement(\"arcgis-assistant-message-read-aloud\");\ndocument.body.append(arcgisAssistantMessageReadAloud);\nawait arcgisAssistantMessageReadAloud.componentOnReady();\nconsole.log(\"arcgis-assistant-message-read-aloud is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"read-aloud-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"readAloudEnabled"}],"importPath":"components/arcgis-assistant-message-read-aloud"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-read-aloud","declaration":{"name":"ArcgisAssistantMessageReadAloud"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-text","sourcePath":"src/components/assistant/assistant-message-text/assistant-message-text.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageText","customElement":true,"tagName":"arcgis-assistant-message-text","pascalCaseName":"ArcgisAssistantMessageText","description":"Renders assistant message text content. Use it when the block is plain text output.\nOffers sanitized rich-text rendering for assistant-generated message content.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-text/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"content","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"content"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageText = document.createElement(\"arcgis-assistant-message-text\");\ndocument.body.append(arcgisAssistantMessageText);\nawait arcgisAssistantMessageText.componentOnReady();\nconsole.log(\"arcgis-assistant-message-text is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"content","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"content"}],"importPath":"components/arcgis-assistant-message-text"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-text","declaration":{"name":"ArcgisAssistantMessageText"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-speech-input","sourcePath":"src/components/assistant/assistant-speech-input/assistant-speech-input.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantSpeechInput","customElement":true,"tagName":"arcgis-assistant-speech-input","pascalCaseName":"ArcgisAssistantSpeechInput","description":"Captures voice input and drafts transcript text. Use it to support microphone-based prompt entry.\nOffers voice session lifecycle management and transcription event streams.","docsTags":[{"name":"internal"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"awaitingResponse","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"awaiting-response"},{"kind":"field","name":"inputValue","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","attribute":"input-value"},{"kind":"field","name":"language","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"language"},{"kind":"field","name":"mode","type":{"text":"VoiceInputMode","references":[{"name":"VoiceInputMode","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputMode","start":0,"end":14}],"values":[{"type":"string","value":"disabled"},{"type":"string","value":"media-recorder"},{"type":"string","value":"web-speech"}]},"default":"\"web-speech\"","attribute":"mode"},{"kind":"method","name":"clearDraftSession","return":{"type":{"text":"void"}},"signature":"(): void"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantSpeechInput = document.createElement(\"arcgis-assistant-speech-input\");\ndocument.body.append(arcgisAssistantSpeechInput);\nawait arcgisAssistantSpeechInput.componentOnReady();\nconsole.log(\"arcgis-assistant-speech-input is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"awaiting-response","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"awaitingResponse"},{"name":"input-value","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","fieldName":"inputValue"},{"name":"language","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"language"},{"name":"mode","type":{"text":"\"disabled\" | \"media-recorder\" | \"web-speech\"","values":[{"type":"string","value":"disabled"},{"type":"string","value":"media-recorder"},{"type":"string","value":"web-speech"}]},"default":"\"web-speech\"","fieldName":"mode"}],"events":[{"name":"arcgisVoiceInputDraftChange","type":{"text":"VoiceInputDraftChangeDetail","references":[{"name":"VoiceInputDraftChangeDetail","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputDraftChangeDetail","start":0,"end":27}]}},{"name":"arcgisVoiceInputError","type":{"text":"{ errorCode: VoiceInputErrorCode; }","references":[{"name":"VoiceInputErrorCode","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputErrorCode","start":13,"end":32}]}},{"name":"arcgisVoiceInputInterimTranscription","type":{"text":"VoiceInputTranscriptDetail","references":[{"name":"VoiceInputTranscriptDetail","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputTranscriptDetail","start":0,"end":26}]}},{"name":"arcgisVoiceInputStart","type":{"text":"void"}},{"name":"arcgisVoiceInputStop","type":{"text":"void"}},{"name":"arcgisVoiceInputTranscription","type":{"text":"VoiceInputTranscriptDetail","references":[{"name":"VoiceInputTranscriptDetail","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputTranscriptDetail","start":0,"end":26}]}},{"name":"arcgisVoiceInputTranscriptionStreamChunk","type":{"text":"VoiceInputTranscriptionStreamChunkDetail","references":[{"name":"VoiceInputTranscriptionStreamChunkDetail","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputTranscriptionStreamChunkDetail","start":0,"end":40}]}}],"importPath":"components/arcgis-assistant-speech-input"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-speech-input","declaration":{"name":"ArcgisAssistantSpeechInput"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-speech-input/support/types","sourcePath":"src/components/assistant/assistant-speech-input/support/types.ts","declarations":[{"kind":"interface","name":"VoiceInputMode","type":{"text":"\"disabled\" | \"media-recorder\" | \"web-speech\""}},{"kind":"interface","name":"VoiceInputErrorCode","type":{"text":"\"no-speech\" | \"not-allowed\" | \"not-supported\" | \"recording-failed\" | \"transcription-failed\" | \"transcription-unavailable\" | \"unhandled\""}},{"kind":"interface","name":"VoiceInputTranscriptDetail","members":[{"kind":"field","name":"transcript","type":{"text":"string"}}]},{"kind":"interface","name":"VoiceInputDraftChangeDetail","members":[{"kind":"field","name":"focusInput","type":{"text":"boolean | undefined"}},{"kind":"field","name":"value","type":{"text":"string"}}]},{"kind":"interface","name":"VoiceInputTranscriptionStreamChunkDetail","members":[{"kind":"field","name":"blob","type":{"text":"Blob","references":[{"name":"Blob","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/Blob","start":0,"end":4}]}},{"kind":"field","name":"chunkIndex","type":{"text":"number"}},{"kind":"field","name":"isFinal","type":{"text":"boolean"}},{"kind":"field","name":"mimeType","type":{"text":"string"}},{"kind":"field","name":"respondWithTranscript","type":{"text":"(transcript: string) => void"}}]}]},{"kind":"javascript-module","path":"components/arcgis-assistant-suggested-prompts","sourcePath":"src/components/assistant/assistant-suggested-prompts/assistant-suggested-prompts.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantSuggestedPrompts","customElement":true,"tagName":"arcgis-assistant-suggested-prompts","pascalCaseName":"ArcgisAssistantSuggestedPrompts","description":"Displays prompt chips and emits selection events. Use it to offer quick starter prompts.\nOffers selectable prompt chips with a prompt-select event for host synchronization.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-suggested-prompts/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"label","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"label"},{"kind":"field","name":"prompts","type":{"text":"string[]"}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantSuggestedPrompts = document.createElement(\"arcgis-assistant-suggested-prompts\");\ndocument.body.append(arcgisAssistantSuggestedPrompts);\nawait arcgisAssistantSuggestedPrompts.componentOnReady();\nconsole.log(\"arcgis-assistant-suggested-prompts is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"label","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"label"}],"events":[{"name":"arcgisPromptSelect","type":{"text":"AssistantPromptSelectDetail","references":[{"name":"AssistantPromptSelectDetail","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantPromptSelectDetail","start":0,"end":27}]}}],"importPath":"components/arcgis-assistant-suggested-prompts"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-suggested-prompts","declaration":{"name":"ArcgisAssistantSuggestedPrompts"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-user-message","sourcePath":"src/components/assistant/assistant-user-message/assistant-user-message.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantUserMessage","customElement":true,"tagName":"arcgis-assistant-user-message","pascalCaseName":"ArcgisAssistantUserMessage","description":"Renders one user-authored chat message row. Use it for displaying what the user sent.\nOffers a simple user message presentation primitive for custom message-list rendering.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-user-message/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"content","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"content"},{"kind":"field","name":"message","type":{"text":"ChatMessage | undefined","references":[{"name":"ChatMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessage","start":0,"end":11}]}},{"kind":"field","name":"user","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"user"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantUserMessage = document.createElement(\"arcgis-assistant-user-message\");\ndocument.body.append(arcgisAssistantUserMessage);\nawait arcgisAssistantUserMessage.componentOnReady();\nconsole.log(\"arcgis-assistant-user-message is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"content","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"content"},{"name":"user","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"user"}],"importPath":"components/arcgis-assistant-user-message"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-user-message","declaration":{"name":"ArcgisAssistantUserMessage"}}]},{"kind":"javascript-module","path":"utils/index","sourcePath":"src/utils/index.ts","declarations":[{"kind":"interface","name":"ChatHistory","description":"Represents the chat message history between the user and the assistant, including all messages sent and received during the conversation.\nThis structure is used to provide context for the assistant's responses and can be utilized when invoking prompts to ensure the model\nhas access to the full conversation history.","docsTags":[{"name":"since","text":"5.0"}],"type":{"text":"BaseMessage[]","references":[{"name":"BaseMessage","module":"messages","package":"@langchain/core","start":0,"end":11}]}},{"kind":"interface","name":"UiInterrupt","description":"Represents a user-facing interruption emitted by an agent that requires\ninput before execution can continue. This is used to implement human-in-the-loop workflows where\nthe agent needs to ask the user for clarification, confirmation, or additional information\nbefore proceeding with its tasks.\n\nUsed to pause an agent flow and request clarification, confirmation,\nor additional information from the user.","docsTags":[{"name":"since","text":"5.0"}],"members":[{"kind":"field","name":"id","description":"Unique identifier for this interrupt instance. This is used to associate the interrupt with a\nspecific message or action in the agent's workflow, allowing the system to track and manage the\ninterrupt effectively.","type":{"text":"string"}},{"kind":"field","name":"agentId","description":"Identifier of the agent requesting input (e.g. \"navigation\", \"myCustomAgent\", etc.).\nThis is used to associate the interrupt with the specific agent that emitted it, which\ncan be helpful for debugging, logging, and providing context to the user about which agent\nis requesting input.","type":{"text":"string"}},{"kind":"field","name":"kind","description":"The type of input being requested. See the list below for the currently supported input types. This is used\nto determine how to render the interrupt in the user interface and what kind of input to expect from the user.\n\n- `booleanChoice` - Presents the user with a yes or no option. This is typically used for confirmation\nprompts where the agent needs to confirm an action with the user before proceeding. For example, some actions\nmay have a high risk of being destructive, such as applying an edit, submitting a form, or deleting data.\nIn these cases, the agent might ask for confirmation before proceeding.\n- `multipleSelection` - Presents the user with multiple options that the user may choose from in a checkbox\ninterface.\n- `singleSelection` - Presents the user with a list of options in a radio button interface, prompting the user\nto select a single option from a list.\n- `textInput` - Prompts the user to enter free-form text before proceeding. This is a flexible input\ntype that can be used for a wide variety of purposes, such as asking the user for more details about\na request, requesting specific information needed to complete a task, or allowing the user to\nprovide feedback or additional context.","type":{"text":"\"booleanChoice\" | \"multipleSelection\" | \"singleSelection\" | \"textInput\""}},{"kind":"field","name":"message","description":"The message shown to the user when prompting for input. This should provide clear instructions or\nquestions related to the interrupt, guiding the user on what information is needed or what action\nthey should take in response to the prompt.","type":{"text":"string | undefined"}},{"kind":"field","name":"metadata","description":"Additional data required to render or handle the interrupt. This is typically an array of strings\nrepresenting options for selection when the `kind` is `multipleSelection` or `singleSelection`.\nFor `booleanChoice`, the options are implicitly \"Yes\" and \"No\" and do not need to be provided.\nFor `textInput`, options are not applicable and should be omitted.","type":{"text":"unknown | undefined"}}]},{"kind":"interface","name":"AgentRegistration","description":"Definition of a client-side agent to register to the [arcgis-assistant-agent](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-agent/) component.\nTo construct an agent, you must build a state graph using LangGraph that defines the agent's\nnodes, edges, workspace variables, and tools.","docsTags":[{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"},{"name":"beta"},{"name":"since","text":"5.0"}],"members":[{"kind":"field","name":"id","description":"A unique identifier for the agent.","type":{"text":"string"}},{"kind":"field","name":"name","description":"A human-readable name for the agent. This must be unique, but also be semantically meaningful.","type":{"text":"string"}},{"kind":"field","name":"description","description":"A brief description of the agent's purpose and functionality. This is required for the agent to be\ndiscoverable in the orchestration of the [arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/). It should provide enough information\nfor the Assistant component and users to understand when to use this agent and what it can do.\nThis description should provide examples of user prompts that would indicate this agent should be used.","docsTags":[{"name":"example","text":"```js\nagentRegistration.description = \"This agent calculates service areas for a given location.\nUse this agent when users ask questions about drive or walk times from a specific location, or when they\nask for areas reachable within a certain time frame from a location.\";\n```"}],"type":{"text":"string"}},{"kind":"field","name":"createGraph","description":"A function that creates and returns the agent's state graph. This graph defines the agent's behavior,\nincluding how it processes inputs, makes decisions, and produces outputs. The graph consists of nodes and edges\nthat represent the agent's deterministic logic and flow. This is a structure defined using LangGraph's StateGraph.","docsTags":[{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[StateGraph documentation](https://langchain-ai.github.io/langgraphjs/reference/classes/langgraph.StateGraph.html)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"type":{"text":"() => StateGraph<unknown>","references":[{"name":"StateGraph","module":"web","package":"@langchain/langgraph","start":6,"end":16}]}},{"kind":"field","name":"workspace","description":"The workspace variables or context required by the agent's graph. This includes messages, results,\nand any other relevant data required by the LLM to make decisions and determine parameters for function calls.\nThis is a structure defined using LangGraph's AnnotationRoot.","docsTags":[{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[AnnotationRoot documentation](https://langchain-ai.github.io/langgraphjs/reference/modules/langgraph.Annotation.html)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"type":{"text":"AnnotationRoot<any>","references":[{"name":"AnnotationRoot","module":"web","package":"@langchain/langgraph","start":0,"end":14}]}}]},{"kind":"interface","name":"ArcgisPromptOptions","description":"Options for sending a prompt to an LLM.","docsTags":[{"name":"since","text":"5.0"}],"members":[{"kind":"field","name":"promptText","description":"The input prompt text to send to the model.","type":{"text":"string"}},{"kind":"field","name":"modelTier","description":"The model tier to use. See the following options:\n\n- `default` - The default model tier, which provides a balance of performance and cost.\n This is suitable for most general-purpose use cases. At JS SDK v5.0, this model\n tier corresponds to GPT-5 mini model.\n- `advanced` - An advanced model tier that may provide improved accuracy or capabilities compared to\n the default tier. However, it may also come with increased cost and slower performance. At\n JS SDK v5.0, this model tier corresponds to GPT-5.2 model.\n- `fast` - A lower cost model suitable for tasks like classification and summarization. This tier may have limitations in terms of response length and complexity.\n New at JS SDK v5.1, this model tier corresponds to GPT-5.4-nano model.\n\nThe specific models available in each tier may evolve over time as new models are released and existing\nmodels are retired. The dates models are retired depends on the model provider and therefore may not\nalign with the semantic versioning rules of the JS SDK. Therefore, the user experience of apps may break\nin a minor version update of the JS SDK. It is important to keep your implementation flexible and test your prompts\nregularly to ensure they continue to perform as expected, especially when updating the JS SDK version or\n when new models are released.\n\nNote that the same prompt will not necessarily produce the same results across different\nmodels. As models are updated, you will need to re-evaluate the prompts you send to the LLM, including\nagent descriptions and tool node descriptions to\nensure they still return the expected responses. You should adjust your implementation as needed.","type":{"text":"ChatModelTier | undefined","references":[{"name":"ChatModelTier","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ChatModelTier","start":0,"end":13}]}},{"kind":"field","name":"temperature","description":"The temperature to use for the model (a number between 0 and 1). Higher values will result in more\ncreative and varied responses, while lower values will produce more focused and deterministic responses.","type":{"text":"number | undefined"}},{"kind":"field","name":"messages","description":"The chat history used to provide context for the prompt. This should include the recent messages\nexchanged between the user and the assistant that are necessary for the model to generate an\ninformed response. Providing chat history can help the model understand the conversation context\nand produce more accurate and relevant responses.","type":{"text":"ChatHistory | undefined","references":[{"name":"ChatHistory","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ChatHistory","start":0,"end":11}]}},{"kind":"field","name":"abortSignal","description":"Abort signal for cooperative run cancellation.","type":{"text":"AbortSignal | undefined","references":[{"name":"AbortSignal","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/AbortSignal","start":0,"end":11}]}},{"kind":"field","name":"inputVariables","description":"Input variables for the prompt. This can include any relevant variables related to the context\nprovided to the agent. This may be necessary for determining tool parameters or for providing additional\ncontext to the model when generating a response.","type":{"text":"Record<string, unknown> | undefined","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}]},{"kind":"interface","name":"ArcgisStructuredPromptOptions","description":"Options when sending a prompt to an LLM that expects a structured response validated against a Zod schema.","docsTags":[{"name":"since","text":"5.0"}],"typeParameters":[{"name":"T"}],"supertypes":[{"name":"ArcgisPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisPromptOptions"}],"members":[{"kind":"field","name":"schema","description":"A Zod schema that defines the expected structure of the model's response. For example, if the expected\nresult from a prompt sent to an LLM is parameters for a tool function that executes specific JS SDK core\nAPI calls, the schema should define the structure of those parameters. This allows the response from the model\nto be validated and parsed according to the defined schema, ensuring type safety and consistency.","docsTags":[{"name":"see","text":"[Zod documentation](https://zod.dev/api)"}],"type":{"text":"ZodType<T>","references":[{"name":"ZodType","package":"zod","start":0,"end":7},{"name":"T","start":8,"end":9}]}}]},{"kind":"interface","name":"ArcgisToolPromptOptions","description":"Options when sending a prompt to an LLM when the node is expected to invoke tools (e.g. functions defined\nin the client). This includes the array of tools that the model can choose to invoke in response to the prompt.","docsTags":[{"name":"since","text":"5.0"}],"supertypes":[{"name":"ArcgisPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisPromptOptions"}],"members":[{"kind":"field","name":"tools","description":"An array of tools that the model can choose to invoke in response to the prompt.","docsTags":[{"name":"see","text":"[StructuredToolInterface documentation](https://reference.langchain.com/javascript/interfaces/_langchain_core.tools.StructuredToolInterface.html)"}],"type":{"text":"StructuredToolInterface[]","references":[{"name":"StructuredToolInterface","module":"tools","package":"@langchain/core","start":0,"end":23}]}}]},{"kind":"interface","name":"TraceEventData","description":"Data structure for trace messages emitted by agents during graph execution.\nThis is used to send trace messages to the log in the chat interface, allowing users to see the\nintermediate steps and thought processes of the agent as it executes its graph.\nThis log will only be visible if the [ArcGISAssistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#logEnabled) property is set to `true`.","docsTags":[{"name":"since","text":"5.0"},{"name":"see","text":"[ArcGISAssistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#logEnabled)"}],"members":[{"kind":"field","name":"text","description":"The text content of the trace message. This should provide information about the agent's current state,\nthe actions it is taking, the decisions it is making, or any other relevant details that can help users\nunderstand the agent's behavior and thought process.","type":{"text":"string"}},{"kind":"field","name":"agentName","description":"The name of the agent associated with this trace message. This can help provide\nadditional context to users about which agent is emitting the trace message, especially in scenarios\nwhere multiple agents are involved in a conversation or workflow.","type":{"text":"string | undefined"}},{"kind":"field","name":"toolName","description":"The name of the tool associated with the trace message. This can help provide\nadditional context to users about which tool (e.g. function defined in the client) is being invoked or\nreferenced in the trace message, especially when the agent is using multiple tools in its workflow.","type":{"text":"string | undefined"}}]},{"kind":"function","name":"invokeTextPrompt","description":"Sends a prompt to an LLM and returns a plain text response. This function should be used when you expect\na simple text response from the model without the need for structured parsing or tool invocation.","docsTags":[{"name":"since","text":"5.0"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"parameters":[{"name":"options","description":"Options for the prompt, including the prompt text, model tier,\n temperature, chat history, and input variables.","type":{"text":"ArcgisPromptOptions","references":[{"name":"ArcgisPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisPromptOptions","start":0,"end":19}]}}],"return":{"description":"The model response.","type":{"text":"Promise<string>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}},{"kind":"function","name":"invokeStructuredPrompt","description":"Sends a prompt to an LLM and returns a structured response validated against a Zod schema.","docsTags":[{"name":"see","text":"[Zod documentation](https://zod.dev/api)"},{"name":"since","text":"5.0"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"typeParameters":[{"name":"T"}],"parameters":[{"name":"options","description":"Prompt options, including a Zod schema for response validation.","type":{"text":"ArcgisStructuredPromptOptions<T>","references":[{"name":"ArcgisStructuredPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisStructuredPromptOptions","start":0,"end":29},{"name":"T","start":30,"end":31}]}}],"return":{"description":"The model response parsed into the structure defined by the provided Zod schema.","type":{"text":"Promise<T>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"T","start":8,"end":9}]}}},{"kind":"function","name":"invokeToolPrompt","description":"Invokes a prompt with tools enabled and returns the model's tool call response.","docsTags":[{"name":"since","text":"5.0"},{"name":"see","text":"[AIMessage documentation](https://reference.langchain.com/javascript/classes/_langchain_core.messages.AIMessage.html)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"parameters":[{"name":"options","description":"Prompt options, including an array of tools the model can invoke.","type":{"text":"ArcgisToolPromptOptions","references":[{"name":"ArcgisToolPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisToolPromptOptions","start":0,"end":23}]}}],"return":{"description":"Resolves to the model's response as an AIMessage as defined in LangChain.","type":{"text":"Promise<AIMessage>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AIMessage","module":"messages","package":"@langchain/core","start":8,"end":17}]}}},{"kind":"function","name":"sendTraceMessage","description":"Dispatches a graph trace message to the log in the chat interface. This allows agents to emit trace\nmessages during graph execution, providing users with insights into the intermediate steps, decisions,\nand actions taken by the agent. These trace messages can help users understand the agent's thought\nprocess and behavior as it executes its graph. It can also be useful for debugging and\ntransparency purposes.","docsTags":[{"name":"since","text":"5.0"},{"name":"see","text":"[ArcGISAssistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#logEnabled)"},{"name":"see","text":"[RunnableConfig documentation](https://reference.langchain.com/javascript/interfaces/_langchain_core.runnables.RunnableConfig.html)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"parameters":[{"name":"data","description":"Trace event data to display in the chat log, including the message, agent, and tool if applicable.","type":{"text":"TraceEventData","references":[{"name":"TraceEventData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#TraceEventData","start":0,"end":14}]}},{"name":"config","description":"Optional runnable configuration\n [as defined in LangChain](https://reference.langchain.com/javascript/interfaces/_langchain_core.runnables.RunnableConfig.html),\n which can include additional context or variables to associate with the trace message.","optional":true,"type":{"text":"RunnableConfig","references":[{"name":"RunnableConfig","module":"runnables","package":"@langchain/core","start":0,"end":14}]}}],"return":{"description":"A promise that resolves once the event has been dispatched.","type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}},{"kind":"function","name":"getEmbeddings","description":"Generates vector embeddings for an array of strings.","parameters":[{"name":"inputs","description":"An array of text strings to be embedded.","type":{"text":"string[]"}}],"return":{"description":"A promise that resolves to an array of embedding vectors.","type":{"text":"Promise<number[][]>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}},{"kind":"interface","name":"UXSuggestion","description":"The suggestions emitted by the agent to the user interface.","docsTags":[{"name":"internal"}],"members":[{"kind":"field","name":"type","description":"The type of suggestion being made.","type":{"text":"string"}},{"kind":"field","name":"data","description":"Optional additional data associated with the suggestion.","type":{"text":"Record<string, unknown> | undefined","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}]},{"kind":"interface","name":"AgentStatus","description":"Execution status returned by an agent run.","docsTags":[{"name":"internal"}],"type":{"text":"\"failed\" | \"success\" | \"unknown\""}},{"kind":"interface","name":"PriorStep","description":"Summary of a previously executed agent step.","docsTags":[{"name":"internal"}],"members":[{"kind":"field","name":"agentId","type":{"text":"string"}},{"kind":"field","name":"assignedTask","type":{"text":"string"}},{"kind":"field","name":"summary","type":{"text":"string"}},{"kind":"field","name":"status","type":{"text":"AgentStatus","references":[{"name":"AgentStatus","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentStatus","start":0,"end":11}]}}]},{"kind":"interface","name":"AgentExecutionContext","description":"Runtime execution context available to agent graph nodes and tools.","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"members":[{"kind":"field","name":"userRequest","type":{"text":"string"}},{"kind":"field","name":"assignedTask","type":{"text":"string"}},{"kind":"field","name":"messages","type":{"text":"ChatHistory","references":[{"name":"ChatHistory","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ChatHistory","start":0,"end":11}]}},{"kind":"field","name":"priorSteps","type":{"text":"PriorStep[]","references":[{"name":"PriorStep","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#PriorStep","start":0,"end":9}]}},{"kind":"field","name":"sharedState","type":{"text":"SharedState<TState>","references":[{"name":"SharedState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#SharedState","start":0,"end":11},{"name":"TState","start":12,"end":18}]}}]},{"kind":"variable","name":"NavigationAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"interface","name":"NavigationContext","docsTags":[{"name":"internal"}],"members":[{"kind":"field","name":"mapView","type":{"text":"MapView","references":[{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":0,"end":7}]}}]},{"kind":"variable","name":"LayerStylingAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"interface","name":"LayerStylingContext","docsTags":[{"name":"internal"}],"members":[{"kind":"field","name":"mapView","type":{"text":"MapView","references":[{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":0,"end":7}]}}]},{"kind":"variable","name":"DataExplorationAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"interface","name":"DataExplorationContext","docsTags":[{"name":"internal"}],"members":[{"kind":"field","name":"mapView","type":{"text":"MapView","references":[{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":0,"end":7}]}}]},{"kind":"variable","name":"HelpAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"variable","name":"ArcgisKnowledgeAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"interface","name":"ArcgisKnowledgeContext","docsTags":[{"name":"internal"}],"type":{"text":"{\n knowledgeGraph: KnowledgeGraph;\n view?: never;\n} | {\n view: LinkChartView | MapView;\n knowledgeGraph?: never;\n}","references":[{"name":"default","module":"rest/knowledgeGraph/KnowledgeGraph.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/rest/knowledgeGraph/KnowledgeGraph/","start":22,"end":36},{"name":"default","module":"views/LinkChartView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/LinkChartView/","start":72,"end":85},{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":88,"end":95}]}},{"kind":"variable","name":"createWebmapEmbeddings","docsTags":[{"name":"internal"}],"type":{"text":"(mapView: MapView) => Promise<{\n schemaVersion: \"0.1\";\n modified: number;\n embeddings: {\n modelProvider: \"openai\";\n model: string;\n dimensions: 1536;\n templates: {\n layer: string;\n field: string;\n };\n };\n layers: Array<{\n id: string;\n name: string;\n title: string;\n description: string;\n vector: Array<number>;\n fields: Array<{\n name: string;\n alias: string;\n description: string;\n vector: Array<number>;\n }>;\n }>;\n}>","references":[{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":10,"end":17},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":22,"end":29},{"name":"Array","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array","start":285,"end":290},{"name":"Array","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array","start":403,"end":408},{"name":"Array","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array","start":434,"end":439},{"name":"Array","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array","start":548,"end":553}]}},{"kind":"interface","name":"AgentWithContext","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TContext","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"members":[{"kind":"field","name":"agent","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"field","name":"getContext","description":"Lazily resolves runtime context.\nCan be sync or async, and may perform lifecycle checks (e.g. await view.when()).","type":{"text":"GetContext<TContext> | undefined","references":[{"name":"GetContext","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#GetContext","start":0,"end":10},{"name":"TContext","start":11,"end":19}]}}]},{"kind":"function","name":"createAgentRuntimeState","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"return":{"type":{"text":"StatelessAgentBaseState<TState>","references":[{"name":"StatelessAgentBaseState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#StatelessAgentBaseState","start":0,"end":23},{"name":"TState","start":24,"end":30}]}}},{"kind":"function","name":"createAgentRuntimeStateWithSharedState","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"return":{"type":{"text":"StatefulAgentBaseState<TState>","references":[{"name":"StatefulAgentBaseState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#StatefulAgentBaseState","start":0,"end":22},{"name":"TState","start":23,"end":29}]}}},{"kind":"function","name":"sendUXSuggestion","docsTags":[{"name":"internal"}],"parameters":[{"name":"suggestion","type":{"text":"UXSuggestion","references":[{"name":"UXSuggestion","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UXSuggestion","start":0,"end":12}]}},{"name":"config","optional":true,"type":{"text":"RunnableConfig","references":[{"name":"RunnableConfig","module":"runnables","package":"@langchain/core","start":0,"end":14}]}}],"return":{"type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}},{"kind":"interface","name":"SharedStatePatch","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"T","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"type":{"text":"{\n [K in keyof T]?: SharedStatePatchEntry<T[K]>;\n}","references":[{"name":"T","start":18,"end":19},{"name":"SharedStatePatchEntry","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#SharedStatePatchEntry","start":23,"end":44},{"name":"T","start":45,"end":46}]}},{"kind":"function","name":"createChatModel","docsTags":[{"name":"internal"}],"parameters":[{"name":"parameter0","optional":true,"type":{"text":"{\n modelTier?: ChatModelTier;\n temperature?: number;\n abortSignal?: AbortSignal;\n}","references":[{"name":"ChatModelTier","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ChatModelTier","start":18,"end":31},{"name":"AbortSignal","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/AbortSignal","start":77,"end":88}]}}],"return":{"type":{"text":"Promise<ChatOpenAI>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"ChatOpenAI","package":"@langchain/openai","start":8,"end":18}]}}},{"kind":"interface","name":"ChatModelTier","type":{"text":"\"advanced\" | \"default\" | \"fast\""}},{"kind":"interface","name":"GetContext","typeParameters":[{"name":"TContext","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"members":[{"kind":"call-signature","return":{"type":{"text":"Promise<TContext> | TContext","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TContext","start":8,"end":16},{"name":"TContext","start":20,"end":28}]}}}]},{"kind":"interface","name":"StatelessAgentBaseState","typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"members":[{"kind":"field","name":"agentExecutionContext","type":{"text":"BaseChannel<AgentExecutionContextWithSharedState<TState>, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11},{"name":"AgentExecutionContextWithSharedState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentExecutionContextWithSharedState","start":12,"end":48},{"name":"TState","start":49,"end":55}]}},{"kind":"field","name":"outputMessage","type":{"text":"BaseChannel<string, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11}]}},{"kind":"field","name":"summary","type":{"text":"BaseChannel<string, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11}]}},{"kind":"field","name":"status","type":{"text":"BaseChannel<AgentStatus | undefined, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11},{"name":"AgentStatus","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentStatus","start":12,"end":23}]}}]},{"kind":"interface","name":"StatefulAgentBaseState","typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"supertypes":[{"name":"StatelessAgentBaseState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#StatelessAgentBaseState","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]}],"members":[{"kind":"field","name":"sharedStatePatch","type":{"text":"BaseChannel<SharedStatePatch<TState> | undefined, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11},{"name":"SharedStatePatch","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#SharedStatePatch","start":12,"end":28},{"name":"TState","start":29,"end":35}]}}]},{"kind":"interface","name":"SharedStatePatchEntry","description":"Patch shape returned by agents. `meta` is intentionally omitted.","typeParameters":[{"name":"T","default":{"text":"unknown"}}],"members":[{"kind":"field","name":"value","type":{"text":"T","references":[{"name":"T","start":0,"end":1}]}}]},{"kind":"interface","name":"SharedState","typeParameters":[{"name":"T","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"type":{"text":"{\n [K in keyof T]?: SharedStateEntry<T[K]>;\n}","references":[{"name":"T","start":18,"end":19},{"name":"SharedStateEntry","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#SharedStateEntry","start":23,"end":39},{"name":"T","start":40,"end":41}]}},{"kind":"interface","name":"AgentExecutionContextWithSharedState","typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"supertypes":[{"name":"AgentExecutionContext","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentExecutionContext","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]}]},{"kind":"interface","name":"SharedStateEntry","description":"Stored shared state entry. `meta` is added by the orchestrator.","typeParameters":[{"name":"T","default":{"text":"unknown"}}],"members":[{"kind":"field","name":"value","type":{"text":"T","references":[{"name":"T","start":0,"end":1}]}},{"kind":"field","name":"meta","type":{"text":"{\n updatedByAgentId: string;\n updatedAt: number;\n}"}}]}]}]}
|
|
1
|
+
{"name":"@arcgis/ai-components","timestamp":"2026-06-05T04:40:30","compiler":{"name":"@arcgis/lumina-compiler","version":"5.2.0-next.8","typescriptVersion":"6.0.2"},"schemaVersion":"2.1.0","modules":[{"kind":"javascript-module","path":"index","sourcePath":"src/index.ts","declarations":[{"kind":"function","name":"getAssetPath","description":"Get a resolved path from where an asset can be loaded.","parameters":[{"name":"suffix","description":"The relative path for the asset.","type":{"text":"string"}}],"return":{"type":{"text":"string"}}},{"kind":"function","name":"setAssetPath","description":"Used to manually set the base path where package assets (like localization\nand icons) can be found.\n\nBy default, the package assets are loaded from\n`https://js.arcgis.com/<version>/<simplified-package-name>/`. We are hosting\nour assets on a CDN (Content Delivery Network) to ensure fast and reliable\naccess. It is CORS-enabled, so you can load the assets from any domain. This\nis the recommended way to load the assets and avoid bundling them with your\napplication.\n\nHowever, if you need to host the assets locally, you can copy them manually\nas part of your build process and use `setAssetPath` to customize where the\nbrowser will load the assets from.","parameters":[{"name":"path","description":"Relative or absolute path to the assets folder.","type":{"text":"URL | string","references":[{"name":"URL","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/URL","start":0,"end":3}]}}],"return":{"type":{"text":"void"}}}]},{"kind":"javascript-module","path":"agent-utils/BaseAgent","sourcePath":"src/agent-utils/BaseAgent.ts","declarations":[{"kind":"class","name":"BaseAgent","description":"BaseAgent serves as the foundational class for all agent implementations. It\nprovides common properties and methods that are shared across different types of agents.\nThis class is not intended to be used directly, use any of the subclasses that extend BaseAgent\ninstead.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"superclass":{"name":"default","module":"core/Accessor.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Accessor/"},"members":[{"kind":"field","name":"createGraph","description":"The createGraph function defines the internal graph structure of the agent,\nincluding its nodes, edges, and associated state.","docsTags":[{"name":"internal"}],"type":{"text":"AgentCreateGraph<TCustomState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TCustomState","start":17,"end":29}]},"readonly":true},{"kind":"field","name":"description","description":"Description of the agent's purpose and functionality. This can be used in registration metadata to provide context about the agent's functionality. A good description is clear and concise. Use bullet points to describe tasks the agent can accomplish. Provide examples of user questions or prompts that could be answered by the agent.","type":{"text":"string"},"default":"\"\""},{"kind":"field","name":"id","description":"The unique identifier for the agent, derived from the name property. This ID is used for registration and invocation purposes.","type":{"text":"string"},"readonly":true},{"kind":"field","name":"middlewares","description":"An optional array of middleware functions that can be used to extend or modify the agent's\nbehavior during execution.\nThis allows for flexible customization of the agent's execution logic. For example, middlewares\ncan be used to implement trace messages (i.e. logging), human-in-the-loop interrupts, or other custom actions.","type":{"text":"AgentMiddleware<TCustomState>[]","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}},{"kind":"field","name":"name","description":"A name for the agent, which is used in the registration metadata and can be displayed in tooling.\nIt should be unique across agents to avoid registration conflicts. A good agent name clearly\nindicates the scope and purpose of the agent. For example, \"WeatherAgent\" or \"CustomerSupportAgent\"\nare descriptive names that convey the agent's functionality as opposed to generic names like\n\"Agent1\" or \"MyAgent\".\n\nThe name is also used to generate the agent's [id](https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#id).","docsTags":[{"name":"required"}],"type":{"text":"string"}},{"kind":"field","name":"registration","description":"The registration property assembles the necessary metadata and graph definition for this agent,\nwhich is consumed by the orchestrator during registration.","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]},"readonly":true},{"kind":"field","name":"workspace","description":"The workspace property serves as the agent's internal state storage, which is used to maintain\ncontext across graph node executions.\nThis is where the agent's state is read from and written to during graph execution, allowing for\ndynamic behavior based on previous steps in the graph.","docsTags":[{"name":"internal"}],"type":{"text":"AgentStateAnnotation<TCustomState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]},"readonly":true},{"kind":"method","name":"generate","description":"Rebuilds internal workspace and createGraph wiring. This is automatically called during initialization and whenever\nthe name or description properties change, but can also be called manually if needed to refresh the agent's graph definition.\n\nThe agent implementation is responsible for defining the createGraph function and workspace structure in this method, which are then used during execution.","docsTags":[{"name":"internal"}],"return":{"type":{"text":"void"}}},{"kind":"method","name":"getSchemas","description":"Returns all schemas required by this agent implementation.","docsTags":[{"name":"internal"}],"return":{"description":"An array of Zod object schemas that define the structure of the agent's expected input and output data.\nThese schemas are used for validation and type inference during graph execution.","type":{"text":"ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}}},{"kind":"method","name":"initialize","return":{"type":{"text":"void"}}},{"kind":"method","name":"run","description":"Executes the agent's graph with the provided state and configuration. This method is responsible\nfor invoking the compiled graph and returning the resulting state after execution.","parameters":[{"name":"state","description":"An optional partial state object to initialize the graph execution. This can include any custom fields defined by the agent.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"An optional execution configuration that can influence the agent's behavior during invocation.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"A promise that resolves to the updated agent graph state after execution.","type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}}}]}]},{"kind":"javascript-module","path":"agent-utils/FunctionAgent","sourcePath":"src/agent-utils/FunctionAgent.ts","declarations":[{"kind":"interface","name":"FunctionAgentExecute","description":"FunctionAgentExecute defines the signature for the execute function used by FunctionAgent.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","parameters":[{"name":"state","description":"Agent state at invocation time.","type":{"text":"AgentNodeState<TInput, TOutput>","references":[{"name":"AgentNodeState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentNodeState","start":0,"end":14},{"name":"TInput","start":15,"end":21},{"name":"TOutput","start":23,"end":30}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"Structured output object or final message string.","type":{"text":"Promise<TOutput | string> | TOutput | string","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TOutput","start":8,"end":15},{"name":"TOutput","start":28,"end":35}]}}}]},{"kind":"class","name":"FunctionAgent","description":"FunctionAgent executes a user-provided function as its core logic.\nIt supports optional input and output schemas for validation and structured data handling.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseAgent","module":"agent-utils/BaseAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#BaseAgent","typeArguments":[{"text":"AgentCustomState<TInput, TOutput>","references":[{"name":"AgentCustomState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCustomState","start":0,"end":16},{"name":"TInput","start":17,"end":23},{"name":"TOutput","start":25,"end":32}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","optional":true,"type":{"text":"ConstructProperties<TInput, TOutput>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/FunctionAgent/#ConstructProperties","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}}]},{"kind":"field","name":"createGraph","description":"The createGraph function defines the internal graph structure of the agent,\nincluding its nodes, edges, and associated state.","docsTags":[{"name":"internal"}],"type":{"text":"AgentCreateGraph<TCustomState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TCustomState","start":17,"end":29}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"description","description":"Description of the agent's purpose and functionality. This can be used in registration metadata to provide context about the agent's functionality. A good description is clear and concise. Use bullet points to describe tasks the agent can accomplish. Provide examples of user questions or prompts that could be answered by the agent.","type":{"text":"string"},"default":"\"\"","inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"execute","description":"The execute function contains the core logic of the FunctionAgent.\nIt receives the current agent state and an optional execution configuration,\nand returns one of the following:\n\n- a structured output object - used in a follow-up node for further processing in the graph, or\n- a string representing a the final message to display in the chat UI.","docsTags":[{"name":"required"}],"type":{"text":"FunctionAgentExecute<TInput, TOutput>","references":[{"name":"FunctionAgentExecute","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/FunctionAgent/#FunctionAgentExecute","start":0,"end":20},{"name":"TInput","start":21,"end":27},{"name":"TOutput","start":29,"end":36}]}},{"kind":"field","name":"id","description":"The unique identifier for the agent, derived from the name property. This ID is used for registration and invocation purposes.","type":{"text":"string"},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"inputSchema","description":"The input schema defines the expected structure of the agent state when the execute function is invoked.\nIf provided, the agent will validate incoming state against this schema and throw an error if validation fails.","type":{"text":"ZodObjectSchema<TInput> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15},{"name":"TInput","start":16,"end":22}]}},{"kind":"field","name":"middlewares","description":"An optional array of middleware functions that can be used to extend or modify the agent's\nbehavior during execution.\nThis allows for flexible customization of the agent's execution logic. For example, middlewares\ncan be used to implement trace messages (i.e. logging), human-in-the-loop interrupts, or other custom actions.","type":{"text":"AgentMiddleware<TCustomState>[]","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"name","description":"A name for the agent, which is used in the registration metadata and can be displayed in tooling.\nIt should be unique across agents to avoid registration conflicts. A good agent name clearly\nindicates the scope and purpose of the agent. For example, \"WeatherAgent\" or \"CustomerSupportAgent\"\nare descriptive names that convey the agent's functionality as opposed to generic names like\n\"Agent1\" or \"MyAgent\".\n\nThe name is also used to generate the agent's [id](https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#id).","docsTags":[{"name":"required"}],"type":{"text":"string"},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"outputSchema","description":"The output schema defines the expected structure of the result returned by the execute function.\nIf provided, the agent will validate the output against this schema and handle it accordingly.","type":{"text":"ZodObjectSchema<TOutput> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15},{"name":"TOutput","start":16,"end":23}]}},{"kind":"field","name":"registration","description":"The registration property assembles the necessary metadata and graph definition for this agent,\nwhich is consumed by the orchestrator during registration.","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"workspace","description":"The workspace property serves as the agent's internal state storage, which is used to maintain\ncontext across graph node executions.\nThis is where the agent's state is read from and written to during graph execution, allowing for\ndynamic behavior based on previous steps in the graph.","docsTags":[{"name":"internal"}],"type":{"text":"AgentStateAnnotation<TCustomState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"method","name":"generate","description":"Rebuilds internal workspace and createGraph wiring. This is automatically called during initialization and whenever\nthe name or description properties change, but can also be called manually if needed to refresh the agent's graph definition.\n\nThe agent implementation is responsible for defining the createGraph function and workspace structure in this method, which are then used during execution.","docsTags":[{"name":"internal"}],"return":{"type":{"text":"void"}}},{"kind":"method","name":"getSchemas","description":"Returns all schemas required by this agent implementation.","docsTags":[{"name":"internal"}],"return":{"description":"An array of Zod object schemas that define the structure of the agent's expected input and output data.\nThese schemas are used for validation and type inference during graph execution.","type":{"text":"ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}}},{"kind":"method","name":"initialize","return":{"type":{"text":"void"}}},{"kind":"method","name":"run","description":"Executes the agent's graph with the provided state and configuration. This method is responsible\nfor invoking the compiled graph and returning the resulting state after execution.","parameters":[{"name":"state","description":"An optional partial state object to initialize the graph execution. This can include any custom fields defined by the agent.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"An optional execution configuration that can influence the agent's behavior during invocation.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"A promise that resolves to the updated agent graph state after execution.","type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<FunctionAgent<TInput, TOutput>, \"description\" | \"inputSchema\" | \"middlewares\" | \"outputSchema\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"FunctionAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/FunctionAgent/#FunctionAgent","start":5,"end":18},{"name":"TInput","start":19,"end":25},{"name":"TOutput","start":27,"end":34}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"FunctionAgent<TInput, TOutput>","references":[{"name":"FunctionAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/FunctionAgent/#FunctionAgent","start":0,"end":13},{"name":"TInput","start":14,"end":20},{"name":"TOutput","start":22,"end":29}]},{"text":"\"execute\" | \"name\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/LLMAgent","sourcePath":"src/agent-utils/LLMAgent.ts","declarations":[{"kind":"class","name":"LLMAgent","description":"LLMAgent uses a language model to generate its output based on a provided prompt template and optional tools.\nIt supports structured input and output through Zod schemas, allowing for validation and type safety. The agent's logic is defined by the prompt and the tools it has access to, making it a flexible option for a wide range of use cases.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseAgent","module":"agent-utils/BaseAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#BaseAgent","typeArguments":[{"text":"AgentCustomState<TInput, TOutput>","references":[{"name":"AgentCustomState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCustomState","start":0,"end":16},{"name":"TInput","start":17,"end":23},{"name":"TOutput","start":25,"end":32}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","optional":true,"type":{"text":"ConstructProperties<TInput, TOutput>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/LLMAgent/#ConstructProperties","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}}]},{"kind":"field","name":"createGraph","description":"The createGraph function defines the internal graph structure of the agent,\nincluding its nodes, edges, and associated state.","docsTags":[{"name":"internal"}],"type":{"text":"AgentCreateGraph<TCustomState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TCustomState","start":17,"end":29}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"description","description":"Description of the agent's purpose and functionality. This can be used in registration metadata to provide context about the agent's functionality. A good description is clear and concise. Use bullet points to describe tasks the agent can accomplish. Provide examples of user questions or prompts that could be answered by the agent.","type":{"text":"string"},"default":"\"\"","inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"id","description":"The unique identifier for the agent, derived from the name property. This ID is used for registration and invocation purposes.","type":{"text":"string"},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"inputSchema","description":"The inputSchema property is an optional Zod schema describing the expected structured input for the agent.\nThis can be used for validation of the input state before execution and also to extract variables from the input\nstate for prompt formatting.","type":{"text":"ZodObjectSchema<TInput> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15},{"name":"TInput","start":16,"end":22}]}},{"kind":"field","name":"middlewares","description":"An optional array of middleware functions that can be used to extend or modify the agent's\nbehavior during execution.\nThis allows for flexible customization of the agent's execution logic. For example, middlewares\ncan be used to implement trace messages (i.e. logging), human-in-the-loop interrupts, or other custom actions.","type":{"text":"AgentMiddleware<TCustomState>[]","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"modelTier","description":"The tier of the model to use for the agent. This can affect the capabilities and performance of the agent.","type":{"text":"\"advanced\" | \"default\" | \"fast\""},"default":"\"default\""},{"kind":"field","name":"name","description":"A name for the agent, which is used in the registration metadata and can be displayed in tooling.\nIt should be unique across agents to avoid registration conflicts. A good agent name clearly\nindicates the scope and purpose of the agent. For example, \"WeatherAgent\" or \"CustomerSupportAgent\"\nare descriptive names that convey the agent's functionality as opposed to generic names like\n\"Agent1\" or \"MyAgent\".\n\nThe name is also used to generate the agent's [id](https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#id).","docsTags":[{"name":"required"}],"type":{"text":"string"},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"outputSchema","description":"The outputSchema property is an optional Zod schema describing the expected structured output from the agent.\nIf provided, the agent will attempt to parse the language model's response according to this schema and return structured data.\nIf not provided, the agent will treat the language model's response as an unstructured string message.","type":{"text":"ZodObjectSchema<TOutput> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15},{"name":"TOutput","start":16,"end":23}]}},{"kind":"field","name":"prompt","description":"Defines the prompt template the agent will use to generate its output.\nThis prompt can include variables that are populated from the agent's state at runtime through the input schema,\nallowing for dynamic and context-aware responses from the language model.\n\nIn this example below, {location} and {weather} would be variables extracted from the agent's state according to the input schema.","docsTags":[{"name":"example","text":"\"Generate a weather report for {location} based on the current {weather} conditions.\""},{"name":"required"}],"type":{"text":"string"}},{"kind":"field","name":"registration","description":"The registration property assembles the necessary metadata and graph definition for this agent,\nwhich is consumed by the orchestrator during registration.","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"tools","description":"The tools property is an optional array of FunctionTools that the agent can use during execution.","type":{"text":"FunctionToolLike[] | undefined","references":[{"name":"FunctionToolLike","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolLike","start":0,"end":16}]}},{"kind":"field","name":"workspace","description":"The workspace property serves as the agent's internal state storage, which is used to maintain\ncontext across graph node executions.\nThis is where the agent's state is read from and written to during graph execution, allowing for\ndynamic behavior based on previous steps in the graph.","docsTags":[{"name":"internal"}],"type":{"text":"AgentStateAnnotation<TCustomState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"method","name":"generate","description":"Rebuilds internal workspace and createGraph wiring. This is automatically called during initialization and whenever\nthe name or description properties change, but can also be called manually if needed to refresh the agent's graph definition.\n\nThe agent implementation is responsible for defining the createGraph function and workspace structure in this method, which are then used during execution.","docsTags":[{"name":"internal"}],"return":{"type":{"text":"void"}}},{"kind":"method","name":"getSchemas","description":"Returns all schemas required by this agent implementation.","docsTags":[{"name":"internal"}],"return":{"description":"An array of Zod object schemas that define the structure of the agent's expected input and output data.\nThese schemas are used for validation and type inference during graph execution.","type":{"text":"ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}}},{"kind":"method","name":"initialize","return":{"type":{"text":"void"}}},{"kind":"method","name":"run","description":"Executes the agent's graph with the provided state and configuration. This method is responsible\nfor invoking the compiled graph and returning the resulting state after execution.","parameters":[{"name":"state","description":"An optional partial state object to initialize the graph execution. This can include any custom fields defined by the agent.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"An optional execution configuration that can influence the agent's behavior during invocation.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"A promise that resolves to the updated agent graph state after execution.","type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<LLMAgent<TInput, TOutput>, \"description\" | \"inputSchema\" | \"middlewares\" | \"modelTier\" | \"outputSchema\" | \"tools\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"LLMAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/LLMAgent/#LLMAgent","start":5,"end":13},{"name":"TInput","start":14,"end":20},{"name":"TOutput","start":22,"end":29}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"LLMAgent<TInput, TOutput>","references":[{"name":"LLMAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/LLMAgent/#LLMAgent","start":0,"end":8},{"name":"TInput","start":9,"end":15},{"name":"TOutput","start":17,"end":24}]},{"text":"\"name\" | \"prompt\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/WorkflowAgent","sourcePath":"src/agent-utils/WorkflowAgent.ts","declarations":[{"kind":"class","name":"WorkflowAgent","description":"WorkflowAgent wraps agents and workflows so they can be executed and registered as a single agent.\nThe workflow defines the internal graph structure and logic of the agent, while WorkflowAgent provides the interface for integration with the broader agent system.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseAgent","module":"agent-utils/BaseAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#BaseAgent","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/WorkflowAgent/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"createGraph","description":"The createGraph function defines the internal graph structure of the agent,\nincluding its nodes, edges, and associated state.","docsTags":[{"name":"internal"}],"type":{"text":"AgentCreateGraph<TCustomState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TCustomState","start":17,"end":29}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"description","description":"Description of the agent's purpose and functionality. This can be used in registration metadata to provide context about the agent's functionality. A good description is clear and concise. Use bullet points to describe tasks the agent can accomplish. Provide examples of user questions or prompts that could be answered by the agent.","type":{"text":"string"},"default":"\"\"","inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"id","description":"The unique identifier for the agent, derived from the name property. This ID is used for registration and invocation purposes.","type":{"text":"string"},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"inputSchema","description":"Optional structured input schema for the workflow wrapper.","type":{"text":"ZodObjectSchema<object> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}},{"kind":"field","name":"middlewares","description":"An optional array of middleware functions that can be used to extend or modify the agent's\nbehavior during execution.\nThis allows for flexible customization of the agent's execution logic. For example, middlewares\ncan be used to implement trace messages (i.e. logging), human-in-the-loop interrupts, or other custom actions.","type":{"text":"AgentMiddleware<TCustomState>[]","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"name","description":"A name for the agent, which is used in the registration metadata and can be displayed in tooling.\nIt should be unique across agents to avoid registration conflicts. A good agent name clearly\nindicates the scope and purpose of the agent. For example, \"WeatherAgent\" or \"CustomerSupportAgent\"\nare descriptive names that convey the agent's functionality as opposed to generic names like\n\"Agent1\" or \"MyAgent\".\n\nThe name is also used to generate the agent's [id](https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/BaseAgent/#id).","docsTags":[{"name":"required"}],"type":{"text":"string"},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"outputSchema","description":"Optional structured output schema for the workflow wrapper.","type":{"text":"ZodObjectSchema<object> | undefined","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}},{"kind":"field","name":"registration","description":"The registration property assembles the necessary metadata and graph definition for this agent,\nwhich is consumed by the orchestrator during registration.","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"field","name":"workflow","description":"The workflow to execute when generating and running this agent's graph.","docsTags":[{"name":"required"}],"type":{"text":"BaseWorkflow<TState>","references":[{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","start":0,"end":12},{"name":"TState","start":13,"end":19}]}},{"kind":"field","name":"workspace","description":"The workspace property serves as the agent's internal state storage, which is used to maintain\ncontext across graph node executions.\nThis is where the agent's state is read from and written to during graph execution, allowing for\ndynamic behavior based on previous steps in the graph.","docsTags":[{"name":"internal"}],"type":{"text":"AgentStateAnnotation<TCustomState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]},"readonly":true,"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}},{"kind":"method","name":"generate","description":"Rebuilds internal workspace and createGraph wiring. This is automatically called during initialization and whenever\nthe name or description properties change, but can also be called manually if needed to refresh the agent's graph definition.\n\nThe agent implementation is responsible for defining the createGraph function and workspace structure in this method, which are then used during execution.","docsTags":[{"name":"internal"}],"return":{"type":{"text":"void"}}},{"kind":"method","name":"getSchemas","description":"Returns all schemas required by this agent implementation.","docsTags":[{"name":"internal"}],"return":{"description":"An array of Zod object schemas that define the structure of the agent's expected input and output data.\nThese schemas are used for validation and type inference during graph execution.","type":{"text":"ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}}},{"kind":"method","name":"initialize","return":{"type":{"text":"void"}}},{"kind":"method","name":"run","description":"Executes the agent's graph with the provided state and configuration. This method is responsible\nfor invoking the compiled graph and returning the resulting state after execution.","parameters":[{"name":"state","description":"An optional partial state object to initialize the graph execution. This can include any custom fields defined by the agent.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"An optional execution configuration that can influence the agent's behavior during invocation.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"A promise that resolves to the updated agent graph state after execution.","type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},"inheritedFrom":{"name":"BaseAgent","module":"agent-utils/BaseAgent"}}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<WorkflowAgent<TState>, \"description\" | \"inputSchema\" | \"middlewares\" | \"outputSchema\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"WorkflowAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/WorkflowAgent/#WorkflowAgent","start":5,"end":18},{"name":"TState","start":19,"end":25}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"WorkflowAgent<TState>","references":[{"name":"WorkflowAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/WorkflowAgent/#WorkflowAgent","start":0,"end":13},{"name":"TState","start":14,"end":20}]},{"text":"\"name\" | \"workflow\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/types","sourcePath":"src/agent-utils/types.ts","declarations":[{"kind":"interface","name":"AgentData","docsTags":[{"name":"internal"}],"supertypes":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","typeArguments":[{"text":"string"},{"text":"unknown"}]}]},{"kind":"interface","name":"EmptyAgentData","docsTags":[{"name":"internal"}],"supertypes":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","typeArguments":[{"text":"never"},{"text":"never"}]}]},{"kind":"interface","name":"AgentRuntimeState","docsTags":[{"name":"privateRemark","text":"All ADK agents are orchestrator-driven, so these channels exist for every agent graph."}],"members":[{"kind":"field","name":"agentExecutionContext","type":{"text":"AgentExecutionContext","references":[{"name":"AgentExecutionContext","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentExecutionContext","start":0,"end":21}]}},{"kind":"field","name":"outputMessage","description":"The outputMessage is a string representing the output of an agent execution.","type":{"text":"string"}},{"kind":"field","name":"summary","description":"The summary is a string providing a brief overview of the agent execution.","type":{"text":"string"}},{"kind":"field","name":"status","description":"The status field represents the current status of the agent execution, which can be used to indicate success, failure, or other relevant states.","type":{"text":"AgentStatus | undefined","references":[{"name":"AgentStatus","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentStatus","start":0,"end":11}]}}]},{"kind":"interface","name":"AgentGraphState","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"supertypes":[{"name":"AgentRuntimeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentRuntimeState"},{"name":"Omit","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#omittype-keys","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]},{"text":"keyof AgentRuntimeState","references":[{"name":"AgentRuntimeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentRuntimeState","start":6,"end":23}]}]}]},{"kind":"interface","name":"BaseAgentLike","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"members":[{"kind":"field","name":"id","description":"Stable ID derived from the agent name and used for graph node and registration identity.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}},{"kind":"field","name":"inputSchema","description":"Optional schema used to validate and shape agent input state.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"ZodObjectSchema<object> | undefined","references":[{"name":"ZodObjectSchema","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}},{"kind":"field","name":"name","description":"Human-readable name shown in registration metadata and tooling.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}},{"kind":"field","name":"outputSchema","description":"Optional schema used to validate structured agent output.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"ZodObjectSchema<object> | undefined","references":[{"name":"ZodObjectSchema","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":0,"end":15}]}},{"kind":"field","name":"registration","description":"Registration payload consumed by the orchestrator.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"field","name":"generate","description":"Regenerates workspace and graph wiring for this agent.","type":{"text":"() => void"}},{"kind":"field","name":"getSchemas","description":"Returns all schemas the agent contributes to state/input/output validation.","type":{"text":"() => ZodObjectSchema<object>[]","references":[{"name":"ZodObjectSchema","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#ZodObjectSchema","start":6,"end":21}]}},{"kind":"method","name":"run","description":"Executes the compiled graph for this agent.","docsTags":[{"name":"return","text":"The resulting graph state after execution."},{"name":"since","text":"5.1"}],"parameters":[{"name":"state","description":"Optional partial state used as graph input.","optional":true,"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}},{"name":"config","description":"Optional runtime execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<AgentGraphState<TCustomState>>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}}}]},{"kind":"interface","name":"AgentExecutionConfig","description":"AgentExecutionConfig defines the shape of the configuration object that can be passed to agent execution methods to influence their behavior at runtime.","members":[{"kind":"field","name":"configurable","description":"The configurable field allows passing arbitrary key-value pairs that can be used by agents during execution to modify their behavior or provide additional context.\nThis can include flags, parameters, or any other relevant information that an agent might need to access at runtime.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"Record<string, unknown> | undefined","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}},{"kind":"field","name":"metadata","type":{"text":"Record<string, unknown> | undefined","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}},{"kind":"field","name":"recursionLimit","type":{"text":"number | undefined"}},{"kind":"field","name":"runName","type":{"text":"string | undefined"}},{"kind":"field","name":"signal","description":"The signal property is an optional AbortSignal that can be used to cancel the execution of an agent. Agents should listen for the abort signal and gracefully handle cancellation when it is triggered.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AbortSignal | undefined","references":[{"name":"AbortSignal","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/AbortSignal","start":0,"end":11}]}},{"kind":"field","name":"tags","type":{"text":"string[] | undefined"}}]},{"kind":"interface","name":"AgentCustomState","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Omit","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#omittype-keys","typeArguments":[{"text":"TInput","references":[{"name":"TInput","start":0,"end":6}]},{"text":"keyof AgentRuntimeState","references":[{"name":"AgentRuntimeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentRuntimeState","start":6,"end":23}]}]},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Omit<TOutput, keyof AgentRuntimeState>","references":[{"name":"Omit","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#omittype-keys","start":0,"end":4},{"name":"TOutput","start":5,"end":12},{"name":"AgentRuntimeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentRuntimeState","start":20,"end":37}]}]}]},{"kind":"interface","name":"AgentNodeState","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","typeArguments":[{"text":"AgentCustomState<TInput, TOutput>","references":[{"name":"AgentCustomState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCustomState","start":0,"end":16},{"name":"TInput","start":17,"end":23},{"name":"TOutput","start":25,"end":32}]}]}]},{"kind":"interface","name":"AgentNodeUpdate","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"AgentNodeState<TInput, TOutput>","references":[{"name":"AgentNodeState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentNodeState","start":0,"end":14},{"name":"TInput","start":15,"end":21},{"name":"TOutput","start":23,"end":30}]}]}]},{"kind":"interface","name":"AgentStateAnnotation","description":"AgentStateAnnotation defines the shape of the agent state used in LangGraph nodes, including both the built-in runtime channels\nand any custom fields defined by the agent.","docsTags":[{"name":"internal"},{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"AnnotationRoot","module":"web","package":"@langchain/langgraph","typeArguments":[{"text":"{\n [K in keyof TState]: BinaryOperatorAggregate<TState[K] | undefined, TState[K] | undefined>;\n} & {\n agentExecutionContext: BaseChannel<AgentExecutionContext, unknown, unknown>;\n outputMessage: BaseChannel<string, unknown, unknown>;\n summary: BaseChannel<string, unknown, unknown>;\n status: BaseChannel<AgentStatus | undefined, unknown, unknown>;\n}","references":[{"name":"TState","start":18,"end":24},{"name":"BinaryOperatorAggregate","module":"channels","package":"@langchain/langgraph","start":27,"end":50},{"name":"TState","start":51,"end":57},{"name":"TState","start":74,"end":80},{"name":"BaseChannel","module":"channels","package":"@langchain/langgraph","start":131,"end":142},{"name":"AgentExecutionContext","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentExecutionContext","start":143,"end":164},{"name":"BaseChannel","module":"channels","package":"@langchain/langgraph","start":204,"end":215},{"name":"BaseChannel","module":"channels","package":"@langchain/langgraph","start":256,"end":267},{"name":"BaseChannel","module":"channels","package":"@langchain/langgraph","start":307,"end":318},{"name":"AgentStatus","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentStatus","start":319,"end":330}]}]}]},{"kind":"interface","name":"RunnableUpdate","description":"State update shape produced by graph nodes.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"type":{"text":"Partial<TState> extends object ? Partial<TState> & Record<string, any> : Partial<TState>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"TState","start":8,"end":14},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":33,"end":40},{"name":"TState","start":41,"end":47},{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":51,"end":57},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":73,"end":80},{"name":"TState","start":81,"end":87}]}},{"kind":"interface","name":"TypedStateGraph","description":"Internal type representing the compiled graph used for agent execution.","docsTags":[{"name":"internal"},{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"StateGraph","module":"web","package":"@langchain/langgraph","typeArguments":[{"text":"StateDefinitionInit","references":[{"name":"StateDefinitionInit","module":"web","package":"@langchain/langgraph","start":0,"end":19}]},{"text":"AgentGraphState<TState>","references":[{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TState","start":16,"end":22}]},{"text":"RunnableUpdate<AgentGraphState<TState>>","references":[{"name":"RunnableUpdate","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#RunnableUpdate","start":0,"end":14},{"name":"AgentGraphState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":15,"end":30},{"name":"TState","start":31,"end":37}]},{"text":"string"}]}]},{"kind":"interface","name":"AgentCreateGraph","description":"The shape of the `createGraph` function used by agents to generate their internal graph representation.\nThis function is responsible for defining the nodes and edges of the graph, as well as any associated state and middleware.","docsTags":[{"name":"internal"},{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","return":{"type":{"text":"TypedStateGraph<TState>","references":[{"name":"TypedStateGraph","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#TypedStateGraph","start":0,"end":15},{"name":"TState","start":16,"end":22}]}}}]},{"kind":"interface","name":"ZodObjectSchema","description":"ZodObjectSchema is a simplified type representing Zod object schemas used for input and output validation in agents.","typeParameters":[{"name":"T","constraint":{"text":"object"},"default":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"z.ZodType<T>","references":[{"name":"default","package":"zod","start":0,"end":1},{"name":"T","start":10,"end":11}]},{"text":"\"safeParse\""}]},{"name":"default","package":"zod"}]},{"kind":"interface","name":"GraphNodes","typeParameters":[{"name":"S","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","typeArguments":[{"text":"string"},{"text":"(state: S, config?: AgentExecutionConfig) => Partial<S> | Promise<Partial<S> | S> | S","references":[{"name":"S","start":8,"end":9},{"name":"AgentExecutionConfig","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":20,"end":40},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":45,"end":52},{"name":"S","start":53,"end":54},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":58,"end":65},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":66,"end":73},{"name":"S","start":74,"end":75},{"name":"S","start":79,"end":80},{"name":"S","start":84,"end":85}]}]}]},{"kind":"interface","name":"GraphEdge","typeParameters":[{"name":"S","constraint":{"text":"AgentData","references":[{"name":"AgentData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"type":{"text":"{\n from: string;\n decide: (state: S, config?: AgentExecutionConfig) => Promise<string | undefined> | string | undefined;\n} | {\n from: string;\n to: string;\n}","references":[{"name":"S","start":40,"end":41},{"name":"AgentExecutionConfig","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":52,"end":72},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":77,"end":84}]}}]},{"kind":"javascript-module","path":"agent-utils/middlewares/humanInTheLoop","sourcePath":"src/agent-utils/middlewares/humanInTheLoop.ts","declarations":[{"kind":"interface","name":"HumanInTheLoopInterruptRequest","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"AgentRunRequest","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentRunRequest","typeArguments":[{"text":"TCustomState","references":[{"name":"TCustomState","start":0,"end":12}]}]}],"members":[{"kind":"field","name":"agentId","description":"The ID of the agent requesting human intervention. This can be used to correlate the\ninterrupt with a specific agent, especially in cases where\nmultiple agents may be running concurrently and using the same middleware.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}}]},{"kind":"interface","name":"HumanInTheLoopInterrupt","docsTags":[{"name":"since","text":"5.1"}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"UiInterrupt","references":[{"name":"UiInterrupt","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UiInterrupt","start":0,"end":11}]}]}]},{"kind":"interface","name":"HumanInTheLoopMiddlewareOptions","description":"Options for configuring the HumanInTheLoopMiddleware.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"method","name":"interrupt","description":"An optional function that generates a custom interrupt object based on the agent run request. This allows for dynamic messages and\nmetadata to be included in the interrupt, providing context to the user when prompting for input or approval.\n\nIf not provided, a default interrupt with a generic approval message will be used.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"request","description":"The agent run request that triggered the interrupt, containing details about the agent, node, and execution context.","type":{"text":"HumanInTheLoopInterruptRequest<TCustomState>","references":[{"name":"HumanInTheLoopInterruptRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterruptRequest","start":0,"end":30},{"name":"TCustomState","start":31,"end":43}]}}],"return":{"description":"An object containing the interrupt details, which will be thrown as a NodeInterrupt to pause the agent's execution.","type":{"text":"HumanInTheLoopInterrupt | Promise<HumanInTheLoopInterrupt>","references":[{"name":"HumanInTheLoopInterrupt","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterrupt","start":0,"end":23},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":26,"end":33},{"name":"HumanInTheLoopInterrupt","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterrupt","start":34,"end":57}]}}},{"kind":"field","name":"outputKey","description":"An optional key in the agent state where the human response should be stored.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"keyof AgentGraphState<TCustomState> | undefined","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":6,"end":21},{"name":"TCustomState","start":22,"end":34}]}}]},{"kind":"interface","name":"HumanInTheLoopToolMessageRequest","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"FunctionToolMiddlewareRequest","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareRequest","typeArguments":[{"text":"TInput","references":[{"name":"TInput","start":0,"end":6}]}]}],"members":[{"kind":"field","name":"args","description":"The arguments passed to the tool that is requesting human intervention.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"object"}},{"kind":"field","name":"toolCallId","description":"The id of the tool call that is requesting human intervention.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string | undefined"}},{"kind":"field","name":"toolName","description":"The name of the tool that is requesting human intervention.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}}]},{"kind":"interface","name":"HumanInTheLoopToolMiddlewareOptions","description":"This middleware is designed to allow for human intervention during agent execution by throwing an interrupt that can be handled by the orchestrator to pause the agent and\nprompt the user for input or approval.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"method","name":"interrupt","description":"An optional function that generates a custom interrupt object based on the tool middleware request. This allows for dynamic messages and\nmetadata to be included in the interrupt, providing context to the user when prompting for input or approval at the tool execution level.","docsTags":[{"name":"since","text":"5.1"},{"name":"return","text":"An object containing the interrupt details, which will be thrown as a NodeInterrupt to pause the tool's execution."}],"parameters":[{"name":"request","description":"The tool middleware request that triggered the interrupt, containing details about the tool, input arguments, and execution context.","type":{"text":"HumanInTheLoopToolMessageRequest<TInput>","references":[{"name":"HumanInTheLoopToolMessageRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopToolMessageRequest","start":0,"end":32},{"name":"TInput","start":33,"end":39}]}}],"return":{"type":{"text":"HumanInTheLoopInterrupt | Promise<HumanInTheLoopInterrupt>","references":[{"name":"HumanInTheLoopInterrupt","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterrupt","start":0,"end":23},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":26,"end":33},{"name":"HumanInTheLoopInterrupt","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopInterrupt","start":34,"end":57}]}}},{"kind":"field","name":"outputKey","description":"An optional key in the tool input where the human response should be stored.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"keyof TInput | undefined","references":[{"name":"TInput","start":6,"end":12}]}}]},{"kind":"function","name":"createHumanInTheLoopMiddleware","description":"This middleware allows for human intervention during agent execution by throwing an interrupt\nto pause the agent and prompt the user for input or approval prior to proceeding. It can be used\nto implement a human-in-the-loop workflow, where certain decisions or actions require human approval before proceeding.\n\nThe interrupt includes customizable messages and metadata to provide context to the user.","docsTags":[{"name":"since","text":"5.1"},{"name":"example","text":"```ts\nconst agent = new WorkflowAgent({\n workflow: myWorkflow,\n middlewares: [\n createHumanInTheLoopMiddleware({\n interrupt: async ({ agentId }) => ({\n message: `Agent ${agentId} is requesting approval to continue. Do you approve?`,\n }),\n }),\n ],\n});\n```"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"parameters":[{"name":"options","description":"Configuration options for the middleware, including the interrupt handler and optional output key for storing the human response in\nthe agent state.","optional":true,"type":{"text":"HumanInTheLoopMiddlewareOptions<TCustomState>","references":[{"name":"HumanInTheLoopMiddlewareOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopMiddlewareOptions","start":0,"end":31},{"name":"TCustomState","start":32,"end":44}]}}],"return":{"description":"An agent middleware that can be added to an agent's middleware stack.","type":{"text":"AgentMiddleware<TCustomState>","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}}},{"kind":"function","name":"createHumanInTheLoopToolMiddleware","description":"This middleware is designed to wrap tool calls within an agent, allowing for human intervention at the tool execution level. When a tool wrapped with this middleware is invoked,\nit will throw an interrupt similar to the agent-level middleware, prompting the user for input or approval before the tool executes.","docsTags":[{"name":"since","text":"5.1"},{"name":"example","text":"```ts\nconst myTool = new FunctionTool({\n name: \"sensitiveOperation\",\n execute: async (input) => {\n // perform sensitive operation\n },\n middlewares: [\n createHumanInTheLoopToolMiddleware({\n interrupt: async ({ toolName, args }) => ({\n message: `Tool ${toolName} is requesting approval to execute with arguments: ${JSON.stringify(args)}. Do you approve?`,\n }),\n }),\n ],\n});\n```"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"parameters":[{"name":"options","description":"Configuration options for the middleware, including the interrupt handler and optional output key for storing the human response in the tool input.","optional":true,"type":{"text":"HumanInTheLoopToolMiddlewareOptions<TInput>","references":[{"name":"HumanInTheLoopToolMiddlewareOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/humanInTheLoop/#HumanInTheLoopToolMiddlewareOptions","start":0,"end":35},{"name":"TInput","start":36,"end":42}]}}],"return":{"description":"A function tool middleware that can be added to a tool's middleware stack.","type":{"text":"FunctionToolMiddleware<TInput, TOutput>","references":[{"name":"FunctionToolMiddleware","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddleware","start":0,"end":22},{"name":"TInput","start":23,"end":29},{"name":"TOutput","start":31,"end":38}]}}},{"kind":"function","name":"getHumanInTheLoopPayload","description":"This function retrieves the human-in-the-loop (HITL) response payload from the agent execution configuration.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TPayload","default":{"text":"unknown"}}],"parameters":[{"name":"config","description":"The agent execution configuration that may contain a HITL response.","type":{"text":"AgentExecutionConfig | undefined","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"description":"The payload from the HITL response if available; otherwise, undefined.","type":{"text":"TPayload | undefined","references":[{"name":"TPayload","start":0,"end":8}]}}}]},{"kind":"javascript-module","path":"agent-utils/middlewares/middleware","sourcePath":"src/agent-utils/middlewares/middleware.ts","declarations":[{"kind":"function","name":"createAgentMiddleware","description":"Creates an agent middleware with the specified hooks and options.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"parameters":[{"name":"name","description":"The name of the middleware.","type":{"text":"string"}},{"name":"hooks","description":"The hooks to be used in the middleware.","type":{"text":"AgentMiddlewareHooks<TCustomState>","references":[{"name":"AgentMiddlewareHooks","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareHooks","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]}},{"name":"options","description":"Optional configuration for the middleware, such as the output key.","optional":true,"type":{"text":"{ outputKey?: keyof AgentGraphState<TCustomState>; }","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":20,"end":35},{"name":"TCustomState","start":36,"end":48}]}}],"return":{"description":"The created agent middleware.","type":{"text":"AgentMiddleware<TCustomState>","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}}},{"kind":"function","name":"createToolMiddleware","description":"Creates a tool middleware with the specified hooks and options.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"parameters":[{"name":"name","description":"The name of the middleware.","type":{"text":"string"}},{"name":"hooks","description":"The hooks to be used in the middleware.","type":{"text":"ToolMiddlewareHooks<TInput, TOutput>","references":[{"name":"ToolMiddlewareHooks","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#ToolMiddlewareHooks","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}},{"name":"options","description":"Optional configuration for the middleware, such as the output key.","optional":true,"type":{"text":"{ outputKey?: string; }"}}],"return":{"description":"The created function tool middleware.","type":{"text":"FunctionToolMiddleware<TInput, TOutput>","references":[{"name":"FunctionToolMiddleware","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddleware","start":0,"end":22},{"name":"TInput","start":23,"end":29},{"name":"TOutput","start":31,"end":38}]}}}]},{"kind":"javascript-module","path":"agent-utils/middlewares/trace","sourcePath":"src/agent-utils/middlewares/trace.ts","declarations":[{"kind":"function","name":"createAgentTraceMiddleware","description":"This middleware is responsible for sending trace messages whenever the agent makes a call to the language model or executes a tool.\n\nIt uses the `sendTraceMessage` function from the orchestrator to send messages that include\ndetails about the model calls and tool\nexecutions, which can be useful for debugging and monitoring the agent's behavior.","docsTags":[{"name":"since","text":"5.1"}],"return":{"description":"An agent middleware that wraps model calls and sends trace messages.","type":{"text":"AgentMiddleware","references":[{"name":"AgentMiddleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddleware","start":0,"end":15}]}}},{"kind":"function","name":"createToolTraceMiddleware","description":"This middleware is responsible for sending trace messages whenever a tool is executed by the agent. It wraps tool calls and uses the `sendTraceMessage`\nfunction from the orchestrator to send messages that include details about the tool execution, such as the tool name and its result. This can be useful for\ndebugging and monitoring the behavior of tools within the agent's execution.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"return":{"description":"A function tool middleware that wraps tool calls and sends trace messages.","type":{"text":"FunctionToolMiddleware<TInput, TOutput>","references":[{"name":"FunctionToolMiddleware","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddleware","start":0,"end":22},{"name":"TInput","start":23,"end":29},{"name":"TOutput","start":31,"end":38}]}}}]},{"kind":"javascript-module","path":"agent-utils/middlewares/types","sourcePath":"src/agent-utils/middlewares/types.ts","declarations":[{"kind":"interface","name":"MiddlewareHandler","description":"Handles a middleware request and returns the resulting value.","typeParameters":[{"name":"TRequest"},{"name":"TResult"}],"members":[{"kind":"call-signature","parameters":[{"name":"request","description":"The request payload for the current middleware stage.","type":{"text":"TRequest","references":[{"name":"TRequest","start":0,"end":8}]}}],"return":{"type":{"text":"Promise<TResult> | TResult","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TResult","start":8,"end":15},{"name":"TResult","start":19,"end":26}]}}}]},{"kind":"interface","name":"Middleware","description":"Wraps a middleware request and delegates to the next handler.","typeParameters":[{"name":"TRequest"},{"name":"TResult"}],"members":[{"kind":"call-signature","parameters":[{"name":"request","description":"The request payload for the current middleware stage.","type":{"text":"TRequest","references":[{"name":"TRequest","start":0,"end":8}]}},{"name":"handler","description":"The next handler in the middleware chain.","type":{"text":"MiddlewareHandler<TRequest, TResult>","references":[{"name":"MiddlewareHandler","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#MiddlewareHandler","start":0,"end":17},{"name":"TRequest","start":18,"end":26},{"name":"TResult","start":28,"end":35}]}}],"return":{"type":{"text":"Promise<TResult> | TResult","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TResult","start":8,"end":15},{"name":"TResult","start":19,"end":26}]}}}]},{"kind":"interface","name":"AgentMiddlewareAgent","members":[{"kind":"field","name":"description","description":"Description of the agent, which can be used to provide context in middleware hooks and interrupts.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string | undefined"}},{"kind":"field","name":"id","description":"Unique identifier for the agent, used for registration and invocation purposes.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}},{"kind":"field","name":"name","description":"Name of the agent, used for display and identification purposes.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}}]},{"kind":"interface","name":"AgentRunRequest","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"members":[{"kind":"field","name":"agent","description":"The agent that is being executed. This can be used in middleware hooks to access agent metadata and provide context for interrupts or other middleware behavior.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentMiddlewareAgent","references":[{"name":"AgentMiddlewareAgent","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareAgent","start":0,"end":20}]}},{"kind":"field","name":"config","description":"The current execution configuration for the agent run, which may include configurable parameters, metadata, and other contextual information. This can be used in middleware\nhooks to make decisions based on the execution context or to store and retrieve information related to the agent run.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentExecutionConfig | undefined","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}},{"kind":"field","name":"nodeName","description":"The name of the current node being executed in the agent's workflow. This can be used in middleware hooks to provide context or make decisions based on the specific node.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string"}},{"kind":"field","name":"state","description":"The current state of the agent's workflow, which may include custom data and intermediate results. This can be used in middleware hooks to access or modify the agent's state during execution.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"Partial<AgentGraphState<TCustomState>>","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36}]}}]},{"kind":"interface","name":"AgentMiddlewareHandler","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"supertypes":[{"name":"Middleware","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#Middleware","typeArguments":[{"text":"AgentRunRequest<TCustomState>","references":[{"name":"AgentRunRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentRunRequest","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]},{"text":"AgentGraphState<TCustomState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}]}]},{"kind":"interface","name":"AgentMiddleware","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"members":[{"kind":"field","name":"name","type":{"text":"string"}},{"kind":"field","name":"handler","type":{"text":"AgentMiddlewareHandler<TCustomState>","references":[{"name":"AgentMiddlewareHandler","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareHandler","start":0,"end":22},{"name":"TCustomState","start":23,"end":35}]}},{"kind":"field","name":"hooks","type":{"text":"AgentMiddlewareHooks<TCustomState> | undefined","references":[{"name":"AgentMiddlewareHooks","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareHooks","start":0,"end":20},{"name":"TCustomState","start":21,"end":33}]}},{"kind":"field","name":"outputKey","type":{"text":"keyof AgentGraphState<TCustomState> | undefined","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":6,"end":21},{"name":"TCustomState","start":22,"end":34}]}}]},{"kind":"interface","name":"AfterAgentRequest","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"supertypes":[{"name":"AgentRunRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentRunRequest","typeArguments":[{"text":"TCustomState","references":[{"name":"TCustomState","start":0,"end":12}]}]}],"members":[{"kind":"field","name":"result","type":{"text":"AgentGraphState<TCustomState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}}]},{"kind":"interface","name":"AgentMiddlewareHooks","typeParameters":[{"name":"TCustomState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"EmptyAgentData","references":[{"name":"EmptyAgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#EmptyAgentData","start":0,"end":14}]}}],"members":[{"kind":"method","name":"afterAgent","description":"An optional hook that is called after the agent has executed, allowing for modification of the result or additional side effects.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"request","description":"The request payload for the afterAgent hook, including the original request and the result of the agent's execution.","type":{"text":"AfterAgentRequest<TCustomState>","references":[{"name":"AfterAgentRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AfterAgentRequest","start":0,"end":17},{"name":"TCustomState","start":18,"end":30}]}}],"return":{"description":"A partial update to the agent's state or other modifications to be applied to the final result, or a promise that resolves to such an update.","type":{"text":"Partial<AgentGraphState<TCustomState>> | Promise<Partial<AgentGraphState<TCustomState>> | void> | void","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":41,"end":48},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":49,"end":56},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":57,"end":72},{"name":"TCustomState","start":73,"end":85}]}}},{"kind":"field","name":"afterModel","type":{"text":"ModelLifecycleHook | undefined","references":[{"name":"ModelLifecycleHook","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#ModelLifecycleHook","start":0,"end":18}]},"readonly":true},{"kind":"field","name":"beforeModel","type":{"text":"ModelLifecycleHook | undefined","references":[{"name":"ModelLifecycleHook","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#ModelLifecycleHook","start":0,"end":18}]},"readonly":true},{"kind":"method","name":"beforeAgent","description":"An optional hook that is called before the agent executes, allowing for modification of the request or additional side effects.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"request","description":"The request payload for the beforeAgent hook, including the original request.","type":{"text":"AgentRunRequest<TCustomState>","references":[{"name":"AgentRunRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentRunRequest","start":0,"end":15},{"name":"TCustomState","start":16,"end":28}]}}],"return":{"description":"A partial update to the agent's state or other modifications to be applied to the request, or a promise that resolves to such an update.","type":{"text":"Partial<AgentGraphState<TCustomState>> | Promise<Partial<AgentGraphState<TCustomState>> | void> | void","references":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":0,"end":7},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":8,"end":23},{"name":"TCustomState","start":24,"end":36},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":41,"end":48},{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","start":49,"end":56},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":57,"end":72},{"name":"TCustomState","start":73,"end":85}]}}},{"kind":"field","name":"wrapAgent","description":"An optional hook that wraps the entire agent execution, allowing for complete control over the execution flow.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentMiddlewareHandler<TCustomState> | undefined","references":[{"name":"AgentMiddlewareHandler","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#AgentMiddlewareHandler","start":0,"end":22},{"name":"TCustomState","start":23,"end":35}]},"readonly":true},{"kind":"field","name":"wrapModelCall","type":{"text":"LangChainMiddlewareHooks[\"wrapModelCall\"] | undefined","references":[{"name":"LangChainMiddlewareHooks","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#LangChainMiddlewareHooks","start":0,"end":24}]},"readonly":true},{"kind":"field","name":"wrapToolCall","type":{"text":"LangChainMiddlewareHooks[\"wrapToolCall\"] | undefined","references":[{"name":"LangChainMiddlewareHooks","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#LangChainMiddlewareHooks","start":0,"end":24}]},"readonly":true}]},{"kind":"interface","name":"ToolMiddlewareHooks","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"members":[{"kind":"field","name":"wrapToolCall","description":"Hook that wraps a tool call, allowing you to intercept and modify the request and response of a tool execution. This can be used for logging, modifying inputs/outputs, or implementing custom behavior around tool calls.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"FunctionToolMiddlewareHandler<TInput, TOutput> | undefined","references":[{"name":"FunctionToolMiddlewareHandler","module":"agent-utils/tools/FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareHandler","start":0,"end":29},{"name":"TInput","start":30,"end":36},{"name":"TOutput","start":38,"end":45}]},"readonly":true}]},{"kind":"interface","name":"LangChainMiddlewareHooks","supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"LangChainAgentMiddleware","references":[{"name":"AgentMiddleware","package":"langchain","start":0,"end":24}]},{"text":"\"afterModel\" | \"beforeModel\" | \"wrapModelCall\" | \"wrapToolCall\""}]}]},{"kind":"interface","name":"ModelLifecycleHook","supertypes":[{"name":"NonNullable","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#extracttype-union","typeArguments":[{"text":"LangChainMiddlewareHooks[\"beforeModel\"]","references":[{"name":"LangChainMiddlewareHooks","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#LangChainMiddlewareHooks","start":0,"end":24}]}]}]}]},{"kind":"javascript-module","path":"agent-utils/tools/FunctionTool","sourcePath":"src/agent-utils/tools/FunctionTool.ts","declarations":[{"kind":"interface","name":"FunctionToolExecute","description":"Execute function used by `FunctionTool`.","typeParameters":[{"name":"TInput","constraint":{"text":"object"}},{"name":"TOutput"}],"members":[{"kind":"call-signature","parameters":[{"name":"input","description":"Structured tool input.","type":{"text":"TInput","references":[{"name":"TInput","start":0,"end":6}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<TOutput> | TOutput","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TOutput","start":8,"end":15},{"name":"TOutput","start":19,"end":26}]}}}]},{"kind":"interface","name":"FunctionToolResult","typeParameters":[{"name":"TOutput","default":{"text":"unknown"}}],"type":{"text":"TOutput | string","references":[{"name":"TOutput","start":0,"end":7}]}},{"kind":"interface","name":"FunctionToolMiddlewareRequest","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"field","name":"config","type":{"text":"AgentExecutionConfig | undefined","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}},{"kind":"field","name":"input","type":{"text":"TInput","references":[{"name":"TInput","start":0,"end":6}]}},{"kind":"field","name":"tool","type":{"text":"FunctionToolMiddlewareTool","references":[{"name":"FunctionToolMiddlewareTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareTool","start":0,"end":26}]}},{"kind":"field","name":"toolCallId","type":{"text":"string | undefined"}}]},{"kind":"interface","name":"FunctionToolMiddlewareHandler","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"supertypes":[{"name":"Middleware","module":"agent-utils/middlewares/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/middlewares/types/#Middleware","typeArguments":[{"text":"FunctionToolMiddlewareRequest<TInput>","references":[{"name":"FunctionToolMiddlewareRequest","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareRequest","start":0,"end":29},{"name":"TInput","start":30,"end":36}]},{"text":"FunctionToolResult<TOutput>","references":[{"name":"FunctionToolResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolResult","start":0,"end":18},{"name":"TOutput","start":19,"end":26}]}]}]},{"kind":"interface","name":"FunctionToolMiddleware","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"members":[{"kind":"field","name":"name","type":{"text":"string"}},{"kind":"field","name":"handler","type":{"text":"FunctionToolMiddlewareHandler<TInput, TOutput>","references":[{"name":"FunctionToolMiddlewareHandler","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddlewareHandler","start":0,"end":29},{"name":"TInput","start":30,"end":36},{"name":"TOutput","start":38,"end":45}]}},{"kind":"field","name":"outputKey","type":{"text":"keyof TInput | undefined","references":[{"name":"TInput","start":6,"end":12}]}}]},{"kind":"interface","name":"ToolResultMode","type":{"text":"\"continue\" | \"terminal\""}},{"kind":"interface","name":"FunctionToolLike","members":[{"kind":"field","name":"name","description":"Name of the tool, used for invocation by agents. This should be unique among the tools available to an agent.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string | undefined"}},{"kind":"field","name":"resultMode","description":"Result mode determines how the agent should treat the output of this tool. If set to \"terminal\", the agent will return the tool's output directly as its final response. If set to \"continue\", the agent will continue processing after invoking the tool, allowing for further reasoning or tool calls.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"ToolResultMode | undefined","references":[{"name":"ToolResultMode","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#ToolResultMode","start":0,"end":14}]}},{"kind":"field","name":"getTool","type":{"text":"() => StructuredToolInterface","references":[{"name":"StructuredToolInterface","module":"tools","package":"@langchain/core","start":6,"end":29}]}}]},{"kind":"class","name":"FunctionTool","description":"FunctionTool is a tool implementation that allows users to define custom logic through a provided execute function,\nalong with input/output schemas for validation and optional middleware for extensibility.\n\nThe FunctionTool is passed to LLMAgents as part of their tools array, and can be invoked by the agent during execution\nbased on the agent's prompt and reasoning process. The resultMode property allows the tool to either return\na final response directly or continue the agent's processing after execution, providing flexibility in how the tool's\noutput is used within the agent's workflow.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput","default":{"text":"unknown"}}],"superclass":{"name":"default","module":"core/Accessor.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Accessor/"},"members":[{"kind":"constructor","parameters":[{"name":"properties","optional":true,"type":{"text":"ConstructProperties<TInput, TOutput>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#ConstructProperties","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}}]},{"kind":"field","name":"description","description":"A concise, but clear description of the tool's functionality.\nThis should provide enough information for the agent to understand when and why to use the tool.\nYou can include examples of a user's input that would trigger the tool, the values to extract, and\nsample output to illustrate its purpose.","docsTags":[{"name":"required"}],"type":{"text":"string"}},{"kind":"field","name":"execute","description":"The execute function contains the custom logic that will be executed when the tool is invoked\nby an agent. It receives\nthe input object and an optional execution configuration, and returns either a result directly\nor a promise that resolves to the result.\n\nThe result is validated against the output schema, if provided.","docsTags":[{"name":"required"},{"name":"since","text":"5.1"}],"type":{"text":"FunctionToolExecute<TInput, TOutput>","references":[{"name":"FunctionToolExecute","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolExecute","start":0,"end":19},{"name":"TInput","start":20,"end":26},{"name":"TOutput","start":28,"end":35}]}},{"kind":"field","name":"inputSchema","description":"The input schema defines the expected structure of the input object when invoking the tool.\nThis should be a Zod schema object.\nThe agent will validate the input against this schema before execution.","type":{"text":"z.ZodType<TInput> | undefined","references":[{"name":"default","package":"zod","start":0,"end":1},{"name":"TInput","start":10,"end":16}]}},{"kind":"field","name":"middlewares","description":"Middleware that can wrap this tool's execution.","type":{"text":"FunctionToolMiddleware<TInput, TOutput>[]","references":[{"name":"FunctionToolMiddleware","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionToolMiddleware","start":0,"end":22},{"name":"TInput","start":23,"end":29},{"name":"TOutput","start":31,"end":38}]}},{"kind":"field","name":"name","description":"The name of the tool, which will be used to invoke it. This should be unique among the tools\navailable to an agent. It should also be descriptive of the tool's functionality to make it\nclear to the agent when to use it.","docsTags":[{"name":"required"}],"type":{"text":"string"}},{"kind":"field","name":"outputSchema","description":"The output schema defines the expected structure of the result returned by the tool.\nThis should be a Zod schema object.\nThe agent will validate the output against this schema after execution.","type":{"text":"z.ZodType<TOutput> | undefined","references":[{"name":"default","package":"zod","start":0,"end":1},{"name":"TOutput","start":10,"end":17}]}},{"kind":"field","name":"resultMode","description":"The result mode determines how the agent should treat the output of this tool.\nIf set to `terminal`, the agent will\nreturn the tool's output directly as its final response. If set to `continue`,\nthe agent will continue processing after\ninvoking the tool, allowing for further reasoning or tool calls.","type":{"text":"ToolResultMode","references":[{"name":"ToolResultMode","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#ToolResultMode","start":0,"end":14}]},"default":"\"continue\""},{"kind":"method","name":"getTool","description":"Builds the LangChain tool adapter used by LLM agents.","return":{"type":{"text":"StructuredToolInterface","references":[{"name":"StructuredToolInterface","module":"tools","package":"@langchain/core","start":0,"end":23}]}}}]},{"kind":"interface","name":"FunctionToolMiddlewareTool","members":[{"kind":"field","name":"description","type":{"text":"string"}},{"kind":"field","name":"name","type":{"text":"string"}},{"kind":"field","name":"resultMode","type":{"text":"ToolResultMode","references":[{"name":"ToolResultMode","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#ToolResultMode","start":0,"end":14}]}}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TInput","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}},{"name":"TOutput"}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<FunctionTool<TInput, TOutput>, \"inputSchema\" | \"middlewares\" | \"outputSchema\" | \"resultMode\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionTool","start":5,"end":17},{"name":"TInput","start":18,"end":24},{"name":"TOutput","start":26,"end":33}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"FunctionTool<TInput, TOutput>","references":[{"name":"FunctionTool","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/tools/FunctionTool/#FunctionTool","start":0,"end":12},{"name":"TInput","start":13,"end":19},{"name":"TOutput","start":21,"end":28}]},{"text":"\"description\" | \"execute\" | \"name\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/BaseWorkflow","sourcePath":"src/agent-utils/workflows/BaseWorkflow.ts","declarations":[{"kind":"interface","name":"WorkflowGenerateResult","description":"Return payload from `BaseWorkflow.generate()`.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"field","name":"workspace","description":"Shared workflow state annotation.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentStateAnnotation<TState>","references":[{"name":"AgentStateAnnotation","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentStateAnnotation","start":0,"end":20},{"name":"TState","start":21,"end":27}]}},{"kind":"field","name":"createGraph","description":"Factory that creates the workflow graph.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"AgentCreateGraph<TState>","references":[{"name":"AgentCreateGraph","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentCreateGraph","start":0,"end":16},{"name":"TState","start":17,"end":23}]}}]},{"kind":"class","name":"BaseWorkflow","description":"BaseWorkflow is the foundational class for defining workflows. A workflow defines a sequence of\nagents that work together to accomplish a task. This class provides the structure and common\nbuilding blocks for constructing a workflow, including generating the shared workspace and\ncreating the graph that defines how agents are connected and executed.\n\nSpecific workflows extend this base class and implement the abstract methods to define\ntheir unique behavior and structure.\n\nThe following workflow types are supported:\n\n- `SequentialWorkflow` - executes agents in a sequence, where the output of one agent can be passed as input to the next.\n- `ConditionalWorkflow` - allows for branching logic based on conditions evaluated at runtime, enabling different paths of execution depending on user input or LLM output.\n- `LoopWorkflow` - supports repeating a set of agents until a certain condition is met, useful for iterative processes.\n- `ParallelWorkflow` - enables concurrent execution of multiple agents, allowing for tasks that can be performed simultaneously.\n- `RouterWorkflow` - dynamically routes execution to different agents based on the input or state, providing flexibility in handling various scenarios.\n- `SwitchWorkflow` - similar to RouterWorkflow but designed for cases where there are multiple distinct paths based on discrete values in the input or state.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"default","module":"core/Accessor.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Accessor/"},"members":[{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"string | undefined"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"name":"index","type":{"text":"number"}}],"return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/ConditionalWorkflow","sourcePath":"src/agent-utils/workflows/ConditionalWorkflow.ts","declarations":[{"kind":"interface","name":"ConditionDecider","description":"Condition function that routes execution to either the true branch or false branch.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","parameters":[{"name":"state","description":"Current workflow graph state.","type":{"text":"AgentGraphState<TState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TState","start":16,"end":22}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<boolean> | boolean","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}}]},{"kind":"class","name":"ConditionalWorkflow","description":"ConditionalWorkflow chooses between two branch agents based on a boolean condition and\nroutes execution through a simple true/false branch.\n\nUse when:\n- you want an if/else style decision or\n- only two branches are needed.\n\nHow it works:\n- evaluate `condition(state, config)`,\n- if true, run the first branch agent,\n- if false, run the second branch agent.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ConditionalWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agents","description":"Must contain exactly two agents: `[trueAgent, falseAgent]`. The first agent is executed when\nthe condition is true, the second when the condition is false.","docsTags":[{"name":"required"}],"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"field","name":"condition","description":"Predicate that chooses the next branch.","docsTags":[{"name":"required"}],"type":{"text":"ConditionDecider<TState>","references":[{"name":"ConditionDecider","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ConditionalWorkflow/#ConditionDecider","start":0,"end":16},{"name":"TState","start":17,"end":23}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"ConditionalWorkflow<TState>","references":[{"name":"ConditionalWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ConditionalWorkflow/#ConditionalWorkflow","start":0,"end":19},{"name":"TState","start":20,"end":26}]},{"text":"\"agents\" | \"condition\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/LoopWorkflow","sourcePath":"src/agent-utils/workflows/LoopWorkflow.ts","declarations":[{"kind":"interface","name":"LoopDecider","description":"Loop continuation predicate. Return true to run another iteration.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","parameters":[{"name":"state","description":"Current workflow graph state.","type":{"text":"AgentGraphState<TState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TState","start":16,"end":22}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<boolean> | boolean","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}}]},{"kind":"class","name":"LoopWorkflow","description":"LoopWorkflow repeatedly executes an inner workflow until a stop condition is met.\n\nUse in the following scenarios:\n\n- You need retry/refine loops,\n- You want iterative planning and execution.\n\nHow it works:\n- Runs the inner `workflow`,\n- Evaluates `decideContinue(state, config)`,\n- If true, runs again; if false (or unset), stops.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/LoopWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"decideContinue","description":"Function that decides whether the loop should continue.","docsTags":[{"name":"required"}],"type":{"text":"LoopDecider<TState>","references":[{"name":"LoopDecider","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/LoopWorkflow/#LoopDecider","start":0,"end":11},{"name":"TState","start":12,"end":18}]}},{"kind":"field","name":"workflow","description":"Inner workflow to execute on each loop iteration.","docsTags":[{"name":"required"}],"type":{"text":"BaseWorkflow<TState>","references":[{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","start":0,"end":12},{"name":"TState","start":13,"end":19}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"LoopWorkflow<TState>","references":[{"name":"LoopWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/LoopWorkflow/#LoopWorkflow","start":0,"end":12},{"name":"TState","start":13,"end":19}]},{"text":"\"decideContinue\" | \"workflow\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/ParallelWorkflow","sourcePath":"src/agent-utils/workflows/ParallelWorkflow.ts","declarations":[{"kind":"class","name":"ParallelWorkflow","description":"ParallelWorkflow fans out execution to multiple agents and merges branch outputs.\n\nUse in the following scenarios:\n- Branches can run independently from the same input,\n- You want fan-out/fan-in behavior.\n\nHow it works:\n- Fan out - every agent receives the same input snapshot,\n- Each branch collects its result in a hidden state key,\n- Fan in - merge outputs in declared agent order.\n\nMerge rule:\n- If two branches set the same shared key to different values, an error is thrown,\nas this indicates a conflict the workflow cannot resolve on its own.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ParallelWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agents","description":"Agents to run in parallel from the same input snapshot.","docsTags":[{"name":"required"}],"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","parameters":[{"name":"_agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","parameters":[{"name":"_agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"name":"_index","type":{"text":"number"}}],"return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"ParallelWorkflow<TState>","references":[{"name":"ParallelWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/ParallelWorkflow/#ParallelWorkflow","start":0,"end":16},{"name":"TState","start":17,"end":23}]},{"text":"\"agents\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/RouterWorkflow","sourcePath":"src/agent-utils/workflows/RouterWorkflow.ts","declarations":[{"kind":"class","name":"RouterWorkflow","description":"RouterWorkflow runs a router agent, then dispatches to exactly one downstream agent.\n\nUse in the following scenarios:\n- A model (or routing step) should choose the destination,\n- Only one branch should run per request\n\nHow it works:\n- `routerAgent` always runs first,\n- `routerAgent` reads the selected route key from `routerOutputKey`,\n- The agent corresponding to the selected route key is dispatched from `agentsMap`.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/RouterWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agentsMap","description":"Mapping of route keys to destination agents.","docsTags":[{"name":"required"}],"type":{"text":"Record<string, BaseAgentLike<TState>>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6},{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":15,"end":28},{"name":"TState","start":29,"end":35}]}},{"kind":"field","name":"routerAgent","description":"The agent that decides which route key to select.","docsTags":[{"name":"required"}],"type":{"text":"BaseAgentLike<TState>","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"field","name":"routerOutputKey","description":"State key containing the selected route returned by the router agent.","docsTags":[{"name":"required"}],"type":{"text":"keyof AgentGraphState<TState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":6,"end":21},{"name":"TState","start":22,"end":28}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","parameters":[{"name":"_agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"name":"index","type":{"text":"number"}}],"return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"RouterWorkflow<TState>","references":[{"name":"RouterWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/RouterWorkflow/#RouterWorkflow","start":0,"end":14},{"name":"TState","start":15,"end":21}]},{"text":"\"agentsMap\" | \"routerAgent\" | \"routerOutputKey\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/SequentialWorkflow","sourcePath":"src/agent-utils/workflows/SequentialWorkflow.ts","declarations":[{"kind":"class","name":"SequentialWorkflow","description":"SequentialWorkflow executes agents in strict linear order.\n\nUse in the following scenarios:\n- Later steps depend on values produced by earlier steps,\n- You want a simple linear pipeline.\n\nHow it works:\n- First agent runs and passes shared state forward,\n- Each subsequent agent receives the updated shared state from the previous agent,\n- Run agent 2, then agent 3, and so on,\n- Stop after the final agent in the sequence runs.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SequentialWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agents","description":"A list of agents to execute in the specified order.","docsTags":[{"name":"required"}],"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"string | undefined"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"name":"index","type":{"text":"number"}}],"return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"SequentialWorkflow<TState>","references":[{"name":"SequentialWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SequentialWorkflow/#SequentialWorkflow","start":0,"end":18},{"name":"TState","start":19,"end":25}]},{"text":"\"agents\""}]}]}]},{"kind":"javascript-module","path":"agent-utils/workflows/SwitchWorkflow","sourcePath":"src/agent-utils/workflows/SwitchWorkflow.ts","declarations":[{"kind":"interface","name":"SwitchDecider","description":"Resolver function that chooses a switch case key from current graph state.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"members":[{"kind":"call-signature","parameters":[{"name":"state","description":"Current workflow graph state.","type":{"text":"AgentGraphState<TState>","references":[{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":0,"end":15},{"name":"TState","start":16,"end":22}]}},{"name":"config","description":"Optional execution configuration.","optional":true,"type":{"text":"AgentExecutionConfig","references":[{"name":"AgentExecutionConfig","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentExecutionConfig","start":0,"end":20}]}}],"return":{"type":{"text":"Promise<string | undefined> | string | undefined","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}}]},{"kind":"class","name":"SwitchWorkflow","description":"SwitchWorkflow routes execution to one of several branches based on a resolver function.\n\nUse in the following scenarios:\n- Branch selection should be based on complex logic that doesn't fit a simple true/false condition.\n- You want explicit case handling with optional fallback.\n\nHow it works:\n- Run `resolver(state, config)` to get a case key,\n- Route to matching `agentsMap` entry,\n- If unknown and `defaultAgent` exists, run default,\n- If unknown and no default, throw an error.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]},"default":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"superclass":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#BaseWorkflow","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]},"members":[{"kind":"constructor","parameters":[{"name":"properties","type":{"text":"ConstructProperties<TState>","references":[{"name":"ConstructProperties","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SwitchWorkflow/#ConstructProperties","start":0,"end":19},{"name":"TState","start":20,"end":26}]}}]},{"kind":"field","name":"agentsMap","description":"Mapping of keys to destination agents.","docsTags":[{"name":"required"}],"type":{"text":"Record<string, BaseAgentLike<TState>>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6},{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":15,"end":28},{"name":"TState","start":29,"end":35}]}},{"kind":"field","name":"defaultAgent","description":"Optional fallback agent used when the resolver returns an unknown case.","type":{"text":"BaseAgentLike<TState> | undefined","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"field","name":"resolver","description":"Resolver used to select the case key for routing.","docsTags":[{"name":"required"}],"type":{"text":"SwitchDecider<TState>","references":[{"name":"SwitchDecider","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SwitchWorkflow/#SwitchDecider","start":0,"end":13},{"name":"TState","start":14,"end":20}]}},{"kind":"method","name":"buildEdges","description":"Builds the workflow-specific edges.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphEdge<AgentGraphState<TState>>[]","references":[{"name":"GraphEdge","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphEdge","start":0,"end":9},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":10,"end":25},{"name":"TState","start":26,"end":32}]}},"privacy":"protected"},{"kind":"method","name":"buildNodes","description":"Builds the workflow's graph nodes.\n\nNode ids use the agent id plus its position (`agent.id_index`) instead of only the raw\nagent id. That prevents collisions when the same agent instance is used multiple times.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"GraphNodes<AgentGraphState<TState>>","references":[{"name":"GraphNodes","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#GraphNodes","start":0,"end":10},{"name":"AgentGraphState","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentGraphState","start":11,"end":26},{"name":"TState","start":27,"end":33}]}},"privacy":"protected"},{"kind":"method","name":"generate","description":"Generates the workflow's graph and shared workspace based on the defined agents and their schemas. This method is\ncalled by the WorkflowAgent when it generates its graph, and it orchestrates the creation of the workflow's structure,\nincluding validating the agents, deriving shared state from their schemas, and building the nodes and edges of the graph.","return":{"type":{"text":"WorkflowGenerateResult<TState>","references":[{"name":"WorkflowGenerateResult","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/BaseWorkflow/#WorkflowGenerateResult","start":0,"end":22},{"name":"TState","start":23,"end":29}]}},"inheritedFrom":{"name":"BaseWorkflow","module":"agent-utils/workflows/BaseWorkflow"}},{"kind":"method","name":"getAgents","description":"A list of agents that are part of this workflow.","return":{"type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}},{"kind":"method","name":"getEntryNode","description":"Returns the id of the first node in the workflow graph.","return":{"type":{"text":"string"}},"privacy":"protected"},{"kind":"method","name":"isTerminalAgent","description":"Returns whether the agent at this position should expose terminal runtime fields.","return":{"type":{"text":"boolean"}},"privacy":"protected"},{"kind":"method","name":"validateAgents","description":"Validates the workflow configuration and throws if invalid.","parameters":[{"name":"agents","type":{"text":"BaseAgentLike<TState>[]","references":[{"name":"BaseAgentLike","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#BaseAgentLike","start":0,"end":13},{"name":"TState","start":14,"end":20}]}}],"return":{"type":{"text":"void"}},"privacy":"protected"}]},{"kind":"interface","name":"ConstructProperties","typeParameters":[{"name":"TState","constraint":{"text":"AgentData","references":[{"name":"AgentData","module":"agent-utils/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/types/#AgentData","start":0,"end":9}]}}],"supertypes":[{"name":"Partial","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#partialtype","typeArguments":[{"text":"Pick<SwitchWorkflow<TState>, \"defaultAgent\">","references":[{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","start":0,"end":4},{"name":"SwitchWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SwitchWorkflow/#SwitchWorkflow","start":5,"end":19},{"name":"TState","start":20,"end":26}]}]},{"name":"Pick","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#picktype-keys","typeArguments":[{"text":"SwitchWorkflow<TState>","references":[{"name":"SwitchWorkflow","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/agent-utils/workflows/SwitchWorkflow/#SwitchWorkflow","start":0,"end":14},{"name":"TState","start":15,"end":21}]},{"text":"\"agentsMap\" | \"resolver\""}]}]}]},{"kind":"javascript-module","path":"components/arcgis-assistant","sourcePath":"src/components/assistant/assistant.tsx","declarations":[{"kind":"class","name":"ArcgisAssistant","customElement":true,"tagName":"arcgis-assistant","pascalCaseName":"ArcgisAssistant","description":"The ArcGIS Assistant component provides a chat-based natural language interface for interacting with\nweb map data via agents. This component uses an orchestrator, which relies on a large language model (LLM)\nfor determining user intent. Once the intent is determined, the assistant routes the user's request\nto an agent that uses an LLM to generate text and structured responses.\n\nBy default, the `arcgis-assistant` component does not include any agents. You must register at least one\nagent for the assistant to function. You can register agents declaratively using any of the\navailable agent components, or you can register custom agents.\n\n## Register agents\n\nTo register agents declaratively, include one or more agent components as children\nof the `arcgis-assistant` component. This can be done in HTML or programmatically using JavaScript.\n\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"#my-map\">\n <arcgis-assistant-navigation-agent></arcgis-assistant-navigation-agent>\n <arcgis-assistant-data-exploration-agent></arcgis-assistant-data-exploration-agent>\n <arcgis-assistant-help-agent></arcgis-assistant-help-agent>\n</arcgis-assistant>\n```\n\n```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst navigationAgent = document.createElement(\"arcgis-assistant-navigation-agent\");\nconst dataExplorationAgent = document.createElement(\"arcgis-assistant-data-exploration-agent\");\nassistant.appendChild(navigationAgent);\nassistant.appendChild(dataExplorationAgent);\n```\n\nNote that the `reference-element` property on the `arcgis-assistant` component must point to a valid `arcgis-map` element\nfor the included ArcGIS agents to function properly, as they rely on the map context to perform their tasks. This is not\na requirement for [custom agents](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/).\n\n## Context\n\nUse the [referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement) property to provide a web map as context to the assistant and its agents.\nThis should be a reference to the map that the assistant will interact with, and is required for the included ArcGIS\nagents to function properly.\n\nTo learn more about this component, try out the [demo](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#demos)\n\n## Important considerations and best practices\n\nDue to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents. Therefore, it is important to set clear expectations\nfor end users and provide guidance on how to interact with the assistant to help mitigate these issues. Some ways to do this include:\n\n- Provide [suggestedPrompts](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#suggestedPrompts). This helps users understand the bounds of the assistant\nand gives them an idea of how to phrase questions to get the best results.\n- Use the [entryMessage](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#entryMessage) property to provide an entry message with instructions and guidance.","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"},{"name":"see","text":"[arcgis-assistant-data-exploration-agent](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-data-exploration-agent/)"},{"name":"see","text":"[arcgis-assistant-navigation-agent](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-navigation-agent/)"},{"name":"see","text":"[arcgis-assistant-help-agent](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-help-agent/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/"},{"description":"Assistant Intro\nIntroduction to the Assistant component.","url":"https://developers.arcgis.com/javascript/latest/storybook/ai-components/index.html?path=/story/arcgis-assistant--demo&singleStory=true"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"awaitingResponse","description":"Indicates whether the assistant is currently processing a user message.\nThis value is `true` while the assistant is generating a response and `false` when idle.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","readonly":true},{"kind":"field","name":"awaitingResponseStep","description":"The current processing status message shown while the assistant is generating a response.\nThis can be used to display progress details such as the current step in processing.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"string","values":[{"type":"string"}]},"readonly":true},{"kind":"field","name":"copyEnabled","description":"When `true`, enables the copy action that, when clicked, copies the content of the message to the clipboard. This can be helpful for users to easily copy and share\ninformation provided by the assistant, such as a summary of findings, a set of instructions, or any other relevant details. Enabling this property can enhance the user experience by providing a convenient way for users to capture and utilize the information generated by the assistant.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant copy-enabled></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.copyEnabled = true;\n```"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"copy-enabled"},{"kind":"field","name":"description","description":"The description text displayed below the heading in the assistant. This text provides additional\ncontext about the assistant's capabilities and how users can interact with it.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant description=\"Explore parcel data ownership, zoning designations, and other relevant information.\"></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.description = \"Explore parcel data ownership, zoning designations, and other relevant information.\";\n```"}],"type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"description"},{"kind":"field","name":"entryMessage","description":"The instructions to display when the assistant is first loaded. This is intended to be a welcome or entry message that\nprovides guidance to users on how to interact with the assistant. Once the user submits their first message,\nthe entry message will be closed and replaced with the chat interface. You can use this property to provide\ninstructions, suggest prompts, or simply welcome users to the assistant.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant entry-message=\"I can answer questions about parcel ownership, zoning, and other relevant information.\"></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.entryMessage = \"I can answer questions about parcel ownership, zoning, and other relevant information.\";\n```"}],"type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"entry-message"},{"kind":"field","name":"feedbackEnabled","description":"When `true`, enables the feedback action in the chat interface, allowing developers to capture user feedback on the assistant's responses.\nThe action simply provides a thumbs up and thumbs down experience for users to indicate whether a response was helpful or not. When the\nuser submits feedback, the [@arcgisFeedback](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#event-arcgisFeedback) event is emitted allowing the app developer to capture additional feedback\nthrough a custom interface and log it to a database or service for later analysis.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant feedback-enabled></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.feedbackEnabled = true;\nassistant.addEventListener(\"arcgisFeedback\", (event) => {\n const feedback = event.detail;\n // Capture additional feedback from the user and log it to a database or service for later analysis\n});\n```"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"feedback-enabled"},{"kind":"field","name":"heading","description":"The heading text displayed at the top of the assistant. This name should be concise and\ndescriptive of the assistant's purpose.\n\nFor applications where the primary interface is the assistant, this heading could also be used as the\napplication title. In cases where the assistant could be collapsed or is a secondary interface to a standard\nGUI, the heading should be more specific to the assistant's function to avoid confusion with the overall\napplication title.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant heading=\"Parcel Viewer\"></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.heading = \"Zoning Assistant\";\n```"}],"type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"heading"},{"kind":"field","name":"interrupt","description":"The active interrupt, if the assistant is waiting for additional user input.\nApplications rendering custom interrupt UI through the `interrupt` slot can read this value\nand call [submitInterrupt()](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#submitInterrupt) or [cancelInterrupt()](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#cancelInterrupt)\nto respond.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"Interrupt | null","references":[{"name":"Interrupt","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#Interrupt","start":0,"end":9}]},"readonly":true},{"kind":"field","name":"keepSuggestedPrompts","description":"When `true`, keeps suggested prompts displayed in the UI after the user submits a message. By default, suggested prompts are cleared,\nwhen the user submits a message.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant keep-suggested-prompts></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.keepSuggestedPrompts = true;\n```"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"keep-suggested-prompts"},{"kind":"field","name":"logEnabled","description":"When `true`, enables the log action that when clicked displays log messages in the chat interface. Log messages provide detailed messages including\nwhich agents or tools were invoked, the parameters generated by the LLM, and any relevant details about how the assistant arrived at its response.\nEnabling logs can be helpful for developers for debugging during the development of an assistant or agentic web application.\nIt may also be useful to end users for transparency purposes, allowing them to understand the assistant's behavior and decision-making process.\n\nEnabling this property for a production app depends on the role of the audience. More technical audiences may benefit from having access to these\nlogs while non-technical audiences may find them overwhelming or confusing.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-assistant log-enabled></arcgis-assistant>\n```"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.logEnabled = true;\n```"}],"type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"log-enabled"},{"kind":"field","name":"messages","description":"The collection of messages exchanged between the user and the assistant. Each message includes the role\n(user or assistant), along with any relevant logs or errors. These messages are rendered in the chat interface\nand are used to provide context for the conversation. When a user submits a message, it is added to this\ncollection with the role of \"user\". When the assistant generates a response, it is added to this collection\nwith the role of \"assistant\", along with any logs or errors that occurred during processing.","docsTags":[{"name":"since","text":"5.0"}],"type":{"text":"Collection<ChatMessage>","references":[{"name":"default","module":"core/Collection.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Collection/","start":0,"end":10},{"name":"ChatMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessage","start":11,"end":22}]}},{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the assistant and its agents. Currently,\nthis is only scoped to `arcgis-map` elements. This is required when ArcGIS agents are registered to the assistant.\nFor example, this allows the navigation agent to execute a map navigation tool for a specific map.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"my-map\"></arcgis-assistant>\n```"}],"type":{"text":"ArcgisMap | string | null","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"field","name":"suggestedPrompts","description":"Prompts to suggest to the end user on load. These are intended to help users understand which questions they can ask.\nThis property should be set to establish boundaries for the end user. As all agents have limitations and LLMs can\nbe unpredictable, it's important to set clear expectations for users to give them a better chance to succeed.\nBy providing suggested prompts, you can guide users towards asking questions that are relevant to the data being\nused and the capabilities of the registered agents, which can help to ensure that the assistant provides accurate\nand helpful responses.\n\nYou should typically provide 2-3 suggested prompts.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.suggestedPrompts = [\n \"What city has the highest population?\",\n \"What is the highest point in this area?\"\n];\n```"}],"type":{"text":"string[]"}},{"kind":"method","name":"cancelInterrupt","description":"Cancels the active interrupt, if one is pending.","docsTags":[{"name":"since","text":"5.1"}],"return":{"type":{"text":"void"}},"signature":"(): void"},{"kind":"method","name":"clearChatHistory","description":"Clears the chat history between the user and the assistant. This method can be used to programmatically reset the conversation,\nremoving all messages from the chat interface.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.clearChatHistory();\n```"}],"return":{"type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}},"signature":"(): Promise<void>"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistant = document.createElement(\"arcgis-assistant\");\ndocument.body.append(arcgisAssistant);\nawait arcgisAssistant.componentOnReady();\nconsole.log(\"arcgis-assistant is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"},{"kind":"method","name":"submitInterrupt","description":"Submits a response for the active interrupt.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"response","description":"The response payload expected by the active interrupt type.","type":{"text":"string[] | boolean | string"}}],"return":{"type":{"text":"void"}},"signature":"(response: string[] | boolean | string): void"},{"kind":"method","name":"submitMessage","description":"Programmatically submits a message to the assistant. This method can be used to submit messages from outside the component,\nsuch as from another component or from custom JavaScript code. When a message is submitted using this method, it is added\nto the messages collection with the role of \"user\", and then processed by the assistant in the same way as if it were submitted\nthrough the chat interface. This allows for greater flexibility in how messages are sent to the assistant and can enable more\ncomplex interactions and integrations with other components or services.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.submitMessage(\"What is the population of New York City?\");\n```"}],"parameters":[{"name":"message","description":"The message to submit to the assistant. This should be a string containing the user's input or question they want to ask the assistant.","type":{"text":"string"}}],"return":{"type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}},"signature":"(message: string): Promise<void>"}],"attributes":[{"name":"copy-enabled","description":"When `true`, enables the copy action that, when clicked, copies the content of the message to the clipboard. This can be helpful for users to easily copy and share\ninformation provided by the assistant, such as a summary of findings, a set of instructions, or any other relevant details. Enabling this property can enhance the user experience by providing a convenient way for users to capture and utilize the information generated by the assistant.","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"copyEnabled"},{"name":"description","description":"The description text displayed below the heading in the assistant. This text provides additional\ncontext about the assistant's capabilities and how users can interact with it.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"description"},{"name":"entry-message","description":"The instructions to display when the assistant is first loaded. This is intended to be a welcome or entry message that\nprovides guidance to users on how to interact with the assistant. Once the user submits their first message,\nthe entry message will be closed and replaced with the chat interface. You can use this property to provide\ninstructions, suggest prompts, or simply welcome users to the assistant.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"entryMessage"},{"name":"feedback-enabled","description":"When `true`, enables the feedback action in the chat interface, allowing developers to capture user feedback on the assistant's responses.\nThe action simply provides a thumbs up and thumbs down experience for users to indicate whether a response was helpful or not. When the\nuser submits feedback, the [@arcgisFeedback](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#event-arcgisFeedback) event is emitted allowing the app developer to capture additional feedback\nthrough a custom interface and log it to a database or service for later analysis.","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"feedbackEnabled"},{"name":"heading","description":"The heading text displayed at the top of the assistant. This name should be concise and\ndescriptive of the assistant's purpose.\n\nFor applications where the primary interface is the assistant, this heading could also be used as the\napplication title. In cases where the assistant could be collapsed or is a secondary interface to a standard\nGUI, the heading should be more specific to the assistant's function to avoid confusion with the overall\napplication title.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"heading"},{"name":"keep-suggested-prompts","description":"When `true`, keeps suggested prompts displayed in the UI after the user submits a message. By default, suggested prompts are cleared,\nwhen the user submits a message.","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"keepSuggestedPrompts"},{"name":"log-enabled","description":"When `true`, enables the log action that when clicked displays log messages in the chat interface. Log messages provide detailed messages including\nwhich agents or tools were invoked, the parameters generated by the LLM, and any relevant details about how the assistant arrived at its response.\nEnabling logs can be helpful for developers for debugging during the development of an assistant or agentic web application.\nIt may also be useful to end users for transparency purposes, allowing them to understand the assistant's behavior and decision-making process.\n\nEnabling this property for a production app depends on the role of the audience. More technical audiences may benefit from having access to these\nlogs while non-technical audiences may find them overwhelming or confusing.","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"logEnabled"},{"name":"reference-element","description":"The reference element to the map that provides context for the assistant and its agents. Currently,\nthis is only scoped to `arcgis-map` elements. This is required when ArcGIS agents are registered to the assistant.\nFor example, this allows the navigation agent to execute a map navigation tool for a specific map.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"events":[{"name":"arcgisCancel","description":"Emitted when the user cancels a message. This is typically invoked when a user submits a question while a previous question is still being processed.\nThis allows app developers to capture messages cancelled by the user and respond to them in custom ways, such as by providing additional information,\ntriggering other actions in the app, or logging them for analysis.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisCancel\", (event) => {\n // Handle the cancelled message\n});\n```"}],"type":{"text":"void"}},{"name":"arcgisError","description":"Emitted when the assistant encounters an error. The event detail includes an Error object with information about the error that occurred.\nThis allows app developers to capture errors that occur within the assistant and respond to them in custom ways, such as by displaying an\nerror message to the user, logging the error for analysis, or triggering other actions in the app.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisError\", (event) => {\n const error = event.detail;\n // Handle the error, such as by displaying an error message to the user or logging it for analysis\n});\n```"}],"type":{"text":"Error","references":[{"name":"Error","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Error","start":0,"end":5}]}},{"name":"arcgisFeedback","description":"Emitted when the user clicks the thumbs up or thumbs down feedback action that is displayed when [feedbackEnabled](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#feedbackEnabled) is `true`.\nThe event detail includes an AssistantMessage object that includes a feedback property with an object indicating whether the feedback is positive or negative.\nThis allows the application to capture user feedback on the assistant's responses and respond to it in custom ways, such as by providing additional\ninformation, adjusting the assistant's behavior, logging the feedback for analysis, or triggering other actions in the app.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisFeedback\", (event) => {\n const feedback = event.detail;\n // Handle the feedback, such as by providing additional information, adjusting the assistant's behavior, or logging it for analysis\n});\n```"}],"type":{"text":"AssistantMessage","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"name":"arcgisInterrupt","description":"Emitted when an agent triggers an interrupt. An interrupt is a human-in-the-loop mechanism that provides a UI component prompting\nthe user for additional information.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisInterrupt\", (event) => {\n const interrupt = event.detail;\n // Handle the interrupt\n});\n```"}],"type":{"text":"Interrupt","references":[{"name":"Interrupt","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#Interrupt","start":0,"end":9}]}},{"name":"arcgisInterruptCancel","description":"Emitted when the user cancels an interrupt. This is typically invoked when a user clicks the cancel button displayed in an interrupt message","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisInterruptCancel\", (event) => {\n // Handle the interrupt cancellation such as logging it for analysis\n});\n```"}],"type":{"text":"void"}},{"name":"arcgisInterruptSubmit","description":"Emitted when the user submits a message during an interrupt. For example, this will be invoked if the user clicks the submit button\nin an interrupt message asking for confirmation, or when the user submits additional text or selects an option provided in an interrupt.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisInterruptSubmit\", (event) => {\n const message = event.detail; // The message or option selected by the user for the interrupt\n // Do something with the interrupt submission\n});\n```"}],"type":{"text":"string[] | boolean | string"}},{"name":"arcgisPromptSelect","description":"Emitted when a suggested prompt is selected from the assistant UI.\nApplications that provide a custom `chat-entry` slot can listen for this event to sync\nthe selected prompt into their own entry implementation.","docsTags":[{"name":"since","text":"5.1"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisPromptSelect\", (event) => {\n const { prompt } = event.detail;\n // Sync prompt into a custom chat entry\n});\n```"}],"type":{"text":"AssistantPromptSelectDetail","references":[{"name":"AssistantPromptSelectDetail","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantPromptSelectDetail","start":0,"end":27}]}},{"name":"arcgisReady","description":"Emitted when the assistant is ready to receive messages from the end user. This indicates that the assistant has been successfully\ninitialized and is ready to process user input.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisReady\", (event) => {\n // Handle the assistant being ready, such as by hiding a loading indicator,\n // displaying a welcome message, or enabling certain UI elements for user interaction\n});\n```"}],"type":{"text":"void"}},{"name":"arcgisSlottableRequest","description":"Emitted when the assistant requests custom slotted content for an assistant message.\n\nUse this event to render app-provided content into dynamic slot targets created at runtime\nfor assistant responses. The event detail includes:\n- name: conceptual request type\n- slotName: concrete slot target to render into\n- data: payload needed to render or update content\n\nDynamic slot name formats:\n- name = \"message\" -> slotName = \"message-{messageId}\"\n- name = \"block\" -> slotName = \"block-{messageId}-{index}\"","docsTags":[{"name":"since","text":"5.1"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisSlottableRequest\", (event) => {\n const { name, slotName, data } = event.detail;\n\n if (!data) {\n // Remove previously rendered slotted content for this slotName.\n return;\n }\n\n // Render or update app-provided content and set slot=slotName.\n // Optionally branch on name (\"message\" or \"block\") for different rendering.\n});\n```"}],"type":{"text":"AssistantSlottableRequestDetail","references":[{"name":"AssistantSlottableRequestDetail","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantSlottableRequestDetail","start":0,"end":31}]},"bubbles":false,"composed":false},{"name":"arcgisSubmit","description":"Emitted when the user submits a message. This is typically invoked when a user clicks the submit button in the chat interface or hits the Enter key.","docsTags":[{"name":"since","text":"5.0"},{"name":"example","text":"```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nassistant.addEventListener(\"arcgisSubmit\", (event) => {\n const message = event.detail;\n // Do something with the submitted message, such as logging it for analysis or triggering other actions in the app\n});\n```"}],"type":{"text":"string"}}],"slots":[{"name":"header-actions-start","description":"Slot for adding actions to the start of the header."},{"name":"header-actions-end","description":"Slot for adding actions to the end of the header."},{"name":"message-starter","description":"Slot for adding content before the message list."},{"name":"messages","description":"Slot for customizing the rendered message list."},{"name":"message-loading","description":"Slot for customizing the in-progress assistant loading state."},{"name":"entry-message","description":"Slot for adding a welcome or entry message on load."},{"name":"interrupt","description":"Slot for customizing the interrupt UI."},{"name":"chat-entry","description":"Slot for customizing the chat entry UI."},{"name":"entry-actions-start","description":"Slot for adding actions to the start of the chat entry."},{"name":"entry-actions-end","description":"Slot for adding actions to the end of the chat entry."},{"name":"footer-content","description":"Slot for adding content below the chat entry."}],"importPath":"components/arcgis-assistant"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant","declaration":{"name":"ArcgisAssistant"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant/types","sourcePath":"src/components/assistant/types.ts","declarations":[{"kind":"interface","name":"Interrupt","description":"An interrupt is a UI mechanism used by an agent to prompt the user for additional input or clarification.","members":[{"kind":"field","name":"id","description":"The unique identifier of the message associated with the interrupt. This is used to associate the interrupt\nwith specific messages.","type":{"text":"string | undefined"}},{"kind":"field","name":"type","description":"The type of interrupt, which determines how the assistant will prompt the user for input. The available types are:\n\n- `boolean-choice`: Presents the user with a yes/no question.\n- `multi-select`: Allows the user to select multiple options from a list using a checkbox interface.\n- `single-select`: Allows the user to select a single option from a list using a radio button interface.\n- `text-input`: Prompts the user to enter free-form text input.\n\nThe assistant will use the specified type to determine how to display the prompt and collect the user's response.\nFor example, a `boolean-choice` interrupt might be used to confirm an action, while a `text-input`\ninterrupt could be used to ask for more details about a request.","type":{"text":"\"boolean-choice\" | \"multi-select\" | \"single-select\" | \"text-input\""}},{"kind":"field","name":"message","description":"The message to display to the user when prompting for input. This should provide clear instructions or questions\nrelated to the interrupt, guiding the user on what information is needed or what action they should take in response\nto the prompt.\n\nFor example, if the interrupt type is `boolean-choice`, the message might be \"Do you want to proceed with this\naction?\" If the type is `text-input`, the message could be \"Please provide more details about your request.\"","type":{"text":"string | undefined"}},{"kind":"field","name":"options","description":"The options to present to the user for selection when the interrupt type is `multi-select` or `single-select`.\nThis should be an array of strings representing the available choices. For `boolean-choice`,\nthe options are implicitly \"Yes\" and \"No\" and do not need to be provided.\nFor `text-input`, options are not applicable and should be omitted.\n\nFor example, if the interrupt type is `multi-select`, the options might be [\"Option 1\", \"Option 2\", \"Option 3\"].\nIf the type is `single-select`, the options could be [\"Choice A\", \"Choice B\", \"Choice C\"].","type":{"text":"string[] | undefined"}}]},{"kind":"interface","name":"AssistantMessage","description":"A chat message sent by the assistant.","supertypes":[{"name":"ChatMessageBase","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessageBase"}],"members":[{"kind":"field","name":"role","type":{"text":"\"assistant\""}},{"kind":"field","name":"content","description":"The content of the assistant's message. This can include text generated by the assistant in response to the user's message. The content is displayed in the chat interface for the user to read and interact with.","type":{"text":"string | undefined"}},{"kind":"field","name":"blocks","description":"Structured response UI blocks associated with the assistant message. These blocks are rendered as interactive\nUI elements separate from the plain text transcript and can be used to display actions, follow-up prompts,\nor app-registered custom content.","type":{"text":"UXSuggestion[] | undefined","references":[{"name":"UXSuggestion","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UXSuggestion","start":0,"end":12}]}},{"kind":"field","name":"log","description":"Log messages related to the assistant's processing of the user's request. This can include information about\nthe agents or tools it invoked, the parameters generated by the LLM, and any relevant details about how it\narrived at its response. Log messages are primarily intended for debugging and transparency purposes, allowing\ndevelopers and users to understand the assistant's behavior and decision-making process.","type":{"text":"string[] | undefined"}},{"kind":"field","name":"error","description":"An error message indicating any issues that occurred while the assistant was processing the user's request.\nThe error message may be displayed in the chat interface to inform the user of the issue and can also be used for\ndebugging and improving the assistant's performance.","type":{"text":"string | undefined"}},{"kind":"field","name":"feedback","description":"Feedback provided by the user for this specific assistant message. This allows users to indicate whether the\nassistant's response was helpful or not, which the app developer can capture and use to improve the assistant's\nperformance over time.","type":{"text":"Feedback | undefined","references":[{"name":"Feedback","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#Feedback","start":0,"end":8}]}}]},{"kind":"interface","name":"ChatMessage","description":"A chat message from the user or the assistant. Messages include all relevant information such as content,\nlogs, errors, and feedback.","type":{"text":"AssistantMessage | UserMessage","references":[{"name":"AssistantMessage","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16},{"name":"UserMessage","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#UserMessage","start":19,"end":30}]}},{"kind":"interface","name":"AssistantPromptSelectDetail","description":"Detail payload emitted when a suggested prompt is selected.","members":[{"kind":"field","name":"prompt","description":"The selected suggested prompt value.","type":{"text":"string"}}]},{"kind":"interface","name":"AssistantSlottableRequestDetail","description":"Detail payload emitted by the assistant slottable request event.","members":[{"kind":"field","name":"name","description":"The request name describing the slot being requested.","type":{"text":"AssistantSlottableRequestName","references":[{"name":"AssistantSlottableRequestName","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantSlottableRequestName","start":0,"end":29}]}},{"kind":"field","name":"slotName","description":"The slot name consumers should target when appending light DOM content.","type":{"text":"string"}},{"kind":"field","name":"data","description":"Data describing the current slot request.","type":{"text":"AssistantSlottableRequestData | undefined","references":[{"name":"AssistantSlottableRequestData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantSlottableRequestData","start":0,"end":29}]}}]},{"kind":"interface","name":"ChatMessageBase","description":"The base interface for chat messages exchanged between the user and the assistant.","members":[{"kind":"field","name":"id","description":"The unique identifier for the message. This is used to associate messages with interrupts and feedback.\nIf not provided, a unique ID will be generated automatically.","type":{"text":"string"}}]},{"kind":"interface","name":"UserMessage","description":"A chat message sent by the user.","supertypes":[{"name":"ChatMessageBase","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessageBase"}],"members":[{"kind":"field","name":"role","type":{"text":"\"user\""}},{"kind":"field","name":"content","description":"The content of the user's message. This is the text input provided by the user in the chat interface.\nThis content is sent to the assistant and its agents for processing and generating responses.","type":{"text":"string"}}]},{"kind":"interface","name":"Feedback","description":"Feedback provided by the user for a specific message.","members":[{"kind":"field","name":"positive","description":"Indicates whether the feedback is positive or negative.","type":{"text":"boolean"}}]},{"kind":"interface","name":"AssistantSlottableRequestData","description":"Data emitted with an assistant slottable request.","members":[{"kind":"field","name":"message","description":"The assistant message associated with the slot request.","type":{"text":"AssistantMessage","references":[{"name":"AssistantMessage","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"field","name":"block","description":"The block associated with the slot request, when requesting block content.","type":{"text":"UXSuggestion | undefined","references":[{"name":"UXSuggestion","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UXSuggestion","start":0,"end":12}]}},{"kind":"field","name":"index","description":"Zero-based index of the block associated with the slot request.","type":{"text":"number | undefined"}}]},{"kind":"interface","name":"AssistantSlottableRequestName","description":"Supported assistant slottable request names.","type":{"text":"\"block\" | \"message\""}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-agent/assistant-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantAgent","customElement":true,"tagName":"arcgis-assistant-agent","pascalCaseName":"ArcgisAssistantAgent","description":"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\na custom agent, you must be familiar with [LangGraph](https://docs.langchain.com/oss/javascript/langgraph/overview). Custom agents must\ninclude a StateGraph that defines the agent's graph and subgraphs.\n\nBuilding custom agents can only be done using modern JavaScript/TypeScript tooling and cannot be done directly in HTML using\nCDN imports. Therefore, you must use a package manager like npm or yarn to install the required dependencies. Please refer to the\n[Custom Agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/) for more instructions on how to create a custom agent.\n\nUse the [utils](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/) module for helper functions and types related to building custom agents, including the `AgentRegistration`\ntype and functions for making LLM calls, managing agent state, and setting up human-in-the-loop workflows.\n\n> We recommend that developers building custom agents have experience working with LLMs and generative AI, and have a good\nunderstanding of the limitations of these technologies when building applications for end users.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in either HTML or JavaScript.\n\n```html\n<arcgis-assistant></arcgis-assistant>\n```\n\n```js\nconst myCustomAgent = {\n id: \"my-custom-agent\",\n name: \"My Custom Agent\",\n description: \"An agent that does custom things. Use this agent when users want to do custom things.\",\n createGraph: {\n // StateGraph definition using LangGraph\n },\n workspace: {\n // AnnotationRoot definition using LangGraph\n // relevant variables and context required by the agent\n },\n};\n\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst assistantAgent = document.createElement(\"arcgis-assistant-agent\");\n\nassistantAgent.agent = myCustomAgent;\nassistant.appendChild(assistantAgent);\n```","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"},{"name":"see","text":"[AgentRegistration](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration)"},{"name":"see","text":"[invokeStructuredPrompt](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#invokeStructuredPrompt)"},{"name":"see","text":"[invokeToolPrompt](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#invokeToolPrompt)"},{"name":"see","text":"[invokeTextPrompt](https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#invokeTextPrompt)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-agent/"}],"typeParameters":[{"name":"TContext","default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"agent","description":"The agent registration object that defines the AI agent's behavior and capabilities.\nThis must include a StateGraph definition (defined using\n[LangGraph](https://docs.langchain.com/oss/javascript/langgraph/overview)).\n\nThis is an agent defined in the client and can be invoked by the assistant from the browser to perform specific tasks\nusing functions defined in the client.\n\nSee the [Custom Agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/) for more instructions\nand links to samples demonstrating how to create custom agents.","docsTags":[{"name":"required"},{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"},{"name":"example","text":"```js\n// An example graph that updates a component property and replies with a confirmation message\nconst myCustomGraph = () => {\n const graph = new StateGraph(myCustomState)\n .addNode(\"updateComponentProperty\", updateComponentProperty)\n .addNode(\"replyComponentPropertyUpdate\", replyComponentPropertyUpdate)\n .addEdge(START, \"updateComponentProperty\")\n .addEdge(\"updateComponentProperty\", \"replyComponentPropertyUpdate\")\n .addEdge(\"replyComponentPropertyUpdate\", END);\n\n return graph;\n};\n\nconst myCustomAgentState = Annotation.Root({\n // This is required to keep track of chat messages between the user and the agent\n messages: Annotation<ChatHistory>({\n reducer: messagesStateReducer,\n default: () => [],\n }),\n // Accumulates user-visible output across graph nodes\n outputMessage: Annotation<string>({\n reducer: (current = \"\", update) =>\n typeof update === \"string\" && update.trim()\n ? current\n ? `${current}\\n\\n${update}`\n : update\n : current,\n default: () => \"\",\n }),\n // Result of the UI action performed by the agent\n // This is a custom type defined by the application\n result: Annotation<UIActionResult | null>({\n reducer: (_current, update) => update ?? null,\n default: () => null,\n }),\n});\n\nconst myCustomAgent = {\n id: \"my-custom-agent\",\n name: \"My Custom Agent\",\n description: \"An agent that does custom things. Use this agent when users want to do custom things.\",\n createGraph: myCustomGraph,\n workspace: myCustomAgentState,\n};\n\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst assistantAgent = document.createElement(\"arcgis-assistant-agent\");\n\nassistantAgent.agent = myCustomAgent;\nassistant.appendChild(assistantAgent);\n```"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"field","name":"context","description":"If the agent requires context provided by the application or user, it can be provided via this property and accessed in the\nagent's graph nodes.","docsTags":[{"name":"example","text":"```js\nassistantAgent.context = {\n myData: {\n // data required for the custom agent\n },\n};\n```"}],"type":{"text":"TContext | (() => Promise<TContext | undefined> | TContext | undefined) | undefined","references":[{"name":"TContext","start":0,"end":8},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":18,"end":25},{"name":"TContext","start":26,"end":34},{"name":"TContext","start":50,"end":58}]}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantAgent = document.createElement(\"arcgis-assistant-agent\");\ndocument.body.append(arcgisAssistantAgent);\nawait arcgisAssistantAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"importPath":"components/arcgis-assistant-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-agent","declaration":{"name":"ArcgisAssistantAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-data-exploration-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-data-exploration-agent/assistant-data-exploration-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantDataExplorationAgent","customElement":true,"tagName":"arcgis-assistant-data-exploration-agent","pascalCaseName":"ArcgisAssistantDataExplorationAgent","description":"The Data Exploration Agent enables the end user to query features, statistics, and spatial proximity\nto features in a layer within a web map. Currently, this is only scoped to querying feature layers within\na 2D web map. See the list of capabilities below for more details.\n\nThe data exploration agent is designed to answer questions about the data in the map, and does not have\naccess to external data sources or the user's location. It also cannot create visualizations in the form of charts,\nlayer renderers, new maps, or other visual outputs. It can currently only provide answers in text form based on the\ndata in the map.\n\nThis agent can change the state of the map by filtering features in a layer, but it cannot change the symbology of\nfeatures or create new layers or export results of a query to a file or external source.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in either HTML or JavaScript.\n\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"my-map\">\n <arcgis-assistant-data-exploration-agent></arcgis-assistant-data-exploration-agent>\n</arcgis-assistant>\n```\n\n```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst dataExplorationAgent = document.createElement(\"arcgis-assistant-data-exploration-agent\");\nassistant.appendChild(dataExplorationAgent);\n```\n\nOnce added to the assistant, the agent is loaded and ready to receive user messages related to data exploration.\n\n### Capabilities\n\nThe data exploration agent provides the following capabilities related to exploring data in the map:\n\n- **Query features** - Ask about the attributes of features in a layer, including a single feature or a set\n of features.\n- **Query statistics** - Ask about statistics related to features in a layer. Statistics that can be queried\n include count, average, minimum, maximum, and sum. This includes asking about the top number of features based on a\n particular attribute.\n- **Query spatial proximity** - Ask about the spatial proximity of features in a layer, such as\n the number of features that intersect a polygon, or information about features within a distance of a specified location or feature.\n This currently does not include questions about the closest feature, but this is planned to be included in a future release.\n- **Filter features** - Users can ask the agent to show a subset of features that filter by attributes, or spatial\n proximity to other features. This includes asking the agent to show features that intersect a particular area,\n or are within a certain distance of a location or feature.\n\n### Example questions\n\nThe following are example questions a user can ask within the bounds of the data exploration agent.\nThese questions assume a map with layers that include cities, states, and rivers.\n\n- \"What is the city with the largest population?\"\n- \"How does that population compare to the average population of the cities in this map?\"\n- \"How many cities are within 30 miles of the Colorado River?\"\n- \"Show all cities in the state of California.\"\n- \"List the top 5 rivers by length.\"\n- \"Emphasize the largest river on the map.\"\n\nThe following are examples of the types of questions that fall outside the bounds of the\ndata exploration agent and should therefore be avoided:\n\n- \"What is the closest restaurant to me?\" (the data exploration agent does not have access to the user's location,\nnor can it find the nearest feature from a location)\n- \"What is the projected growth of Phoenix in the next 10 years?\" (the data exploration agent can\nonly answer questions about the data in the map, not external data or projections)\n- \"Show me the population of cities in this map on a graph.\" (the data exploration agent can only\nprovide answers in text form, not visualizations)\n\n> Due to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents.","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-data-exploration-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the data exploration agent. Currently,\nthis is only scoped to `arcgis-map` elements. This provides the data exploration agent with the layers\nneeded for answering user questions about the data in the map.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","docsTags":[{"name":"see","text":"[arcgis-assistant.referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement)"},{"name":"example","text":"```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant>\n <arcgis-assistant-data-exploration-agent reference-element=\"my-map\"></arcgis-assistant-data-exploration-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"ArcgisMap | string | undefined","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantDataExplorationAgent = document.createElement(\"arcgis-assistant-data-exploration-agent\");\ndocument.body.append(arcgisAssistantDataExplorationAgent);\nawait arcgisAssistantDataExplorationAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-data-exploration-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","description":"The reference element to the map that provides context for the data exploration agent. Currently,\nthis is only scoped to `arcgis-map` elements. This provides the data exploration agent with the layers\nneeded for answering user questions about the data in the map.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"importPath":"components/arcgis-assistant-data-exploration-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-data-exploration-agent","declaration":{"name":"ArcgisAssistantDataExplorationAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-help-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-help-agent/assistant-help-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantHelpAgent","customElement":true,"tagName":"arcgis-assistant-help-agent","pascalCaseName":"ArcgisAssistantHelpAgent","description":"The Help Agent provides contextual assistance and guidance to the end user within an\nagentic web mapping application. It can provide answers to questions about the web map provided\nto the [referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-help-agent/#referenceElement) property and answer questions about other agents included\nas subcomponents to the [arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/) component.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in\neither HTML or JavaScript.\n\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"my-map\">\n <arcgis-assistant-help-agent></arcgis-assistant-help-agent>\n</arcgis-assistant>\n```\n\n```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst helpAgent = document.createElement(\"arcgis-assistant-help-agent\");\nassistant.appendChild(helpAgent);\n```\n\nOnce added to the assistant, the agent is loaded and ready to receive user messages related to help and guidance.\n\n### Example questions\n\nThe following are example questions a user can ask within the bounds of the help agent:\n\n- \"What kind of questions can I ask?\"\n- \"What layers are in this map?\"\n- \"What kind of data can I ask questions about?\"\n\nThe following are examples of the types of questions that fall outside the bounds of the\nhelp agent and should therefore be avoided:\n\n- \"Search the Esri documentation for ways that I can query my data.\"\n- \"Log a bug related to map navigation to the Esri support team.\"\n- \"How do I bake a cake?\"\n- \"How does map navigation work in ArcGIS?\"\n\n> Due to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents.","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-help-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the help agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the help agent which map for which to\nprovide assistance. This allows users to ask questions about the specific map provided to the agent.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","docsTags":[{"name":"see","text":"[arcgis-assistant.referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement)"},{"name":"example","text":"```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant>\n <arcgis-assistant-help-agent reference-element=\"my-map\"></arcgis-assistant-help-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"ArcgisMap | string | undefined","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantHelpAgent = document.createElement(\"arcgis-assistant-help-agent\");\ndocument.body.append(arcgisAssistantHelpAgent);\nawait arcgisAssistantHelpAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-help-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","description":"The reference element to the map that provides context for the help agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the help agent which map for which to\nprovide assistance. This allows users to ask questions about the specific map provided to the agent.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"importPath":"components/arcgis-assistant-help-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-help-agent","declaration":{"name":"ArcgisAssistantHelpAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-knowledge-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-knowledge-agent/assistant-knowledge-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantKnowledgeAgent","customElement":true,"tagName":"arcgis-assistant-knowledge-agent","pascalCaseName":"ArcgisAssistantKnowledgeAgent","description":"The Knowledge Agent enables the end user to explore knowledge graph data in a [link chart](https://developers.arcgis.com/javascript/latest/references/core/WebLinkChart/), a\n [knowledge graph service](https://developers.arcgis.com/javascript/latest/references/core/rest/knowledgeGraphService/), or a [knowledge graph layer](https://developers.arcgis.com/javascript/latest/references/core/layers/KnowledgeGraphLayer/) in a map via natural language queries. It also provides additional capabilities when used with a knowledge graph layer or link chart. See the list of capabilities below for more details.\n\nThe knowledge agent is designed to answer questions about data in the knowledge graph provided by the knowledge graph layer on map,\na link chart or a knowledge graph service url, and does not have access to external data sources or the user's location.\n\nIt cannot create visualizations in the form of charts, layer renderers, new maps, or other visual outputs.\nWhen provided a link chart as context, it can create new link charts based on queries generated from user prompts.\n\nThis agent can add to the knowledge graph data on a map or link chart if a user prompt generates a query that returns entities\nor relationships from the graph and asks for the returned results to be added to the view.\nIt can also change the layout of a link chart or toggle visibility of non-spatial data on a link chart.\nHowever, it cannot change the symbology of\nfeatures or create new layers or export results of a query to a file or external source.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in either HTML or JavaScript.\n\nLink Chart context example:\n```html\n<arcgis-link-chart id=\"my-link-chart\"></arcgis-link-chart>\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent reference-element=\"my-link-chart\"></arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```\n\nMap context example:\nNote: the map must contain one knowledge graph layer.\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent reference-element=\"my-map\"></arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```\n\nKnowledge Graph Service context example:\n```html\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent\n service-url=\"https://example.com/server/rest/services/Hosted/myKnowledgeGraph/KnowledgeGraphServer\"\n >\n </arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```\n\nOnce added to the assistant, the agent is loaded and ready to receive user messages directed to their knowledge graph related layers or data.\n\n### Capabilities\n\nThe knowledge agent provides the following capabilities related to a knowledge graph or associated knowledge graph layer or link chart layer:\n\n- **Query** - Ask about the entities and relationships in my graph. This includes questions about connections between entities and\npatterns in the graph, as well as questions about the structure of the graph such as the types of entities and relationships and the\nnumber of each type.\nReturns the results of the query in text form, and can optionally add returned\nentities or relationships to the map or link chart view if the user prompt requests it.\n- **Search** - Search for specific entities or relationships in the knowledge graph, or the closest matches based on their properties.\nReturns the results of the search in text form, and can optionally add returned entities or relationships to the map or link chart\nview if the user prompt requests it.\n- **Generate Cypher Query** - Generates and returns a cypher query based on a natural language question and the current knowledge\ngraph data model,\nwhich can be run against the knowledge graph service.\n\nAdditional capabilities with a map view with a knowledge graph layer or a link chart view\n\n- **Add entities and relationships** - Add entities or relationships the the knowledge graph or link chart layer based on results returned from searches or queries generated from user prompts.\n\nAdditional capabilities with a link chart view only\n\n- **Change link chart layout** - Change the layout of the link chart between different modes such as force directed, radial, or hierarchical.\n- **Toggle non-spatial visibility** - Show or hide non-spatial entities and relationships on the link chart.\n- **Create link chart from query** - Recreate the link chart with new entities and relationships based on a query generated from the\nuser prompt.\n\n\n### Example questions\n\nThe following are example questions a user can ask within the bounds of the knowledge agent:\n\n- \"What entities are in this graph, and what is the count of each entity type?\"\n- \"Who are the top 5 entities most connected to Company X?\"\n- \"Find all employees with the last name Smith.\"\n- \"What is the most influential company in this graph?\"\n- \"Generate a cypher query to find all employees of Company X that joined the company after 2022 who worked for a competitor before joining Company X.\"\n- \"Add all connections between Company X and Company Y to the link chart\"\n- \"Change the layout to hierarchical\"\n- \"Hide non spatial data on the link chart\"\n- \"Create a new link chart with all employees from Company X that joined the company after 2015 and are located in California\"\n\n> Due to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents.","docsTags":[{"name":"since","text":"5.1"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-knowledge-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"context","description":"Required and optional context for the knowledge agent. The knowledge agent requires either a link chart view,\na map view with at least one knowledge graph layer, or KnowledgeGraph instance in order to function.\n\nDepending on the context provided, different capabilities will be available.","type":{"text":"ArcgisKnowledgeContext | undefined","references":[{"name":"ArcgisKnowledgeContext","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-knowledge-agent/#ArcgisKnowledgeContext","start":0,"end":22}]}},{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the navigation agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the navigation agent which map on which to\nperform navigation actions. This is required for the navigation agent to function properly.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","docsTags":[{"name":"see","text":"[arcgis-assistant.referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement)"},{"name":"example","text":"```html\n<arcgis-link-chart id=\"my-link-chart\"></arcgis-link-chart>\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent reference-element=\"my-link-chart\"></arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"ArcgisLinkChart | ArcgisMap | string | undefined","references":[{"name":"ArcgisLinkChart","module":"components/arcgis-link-chart","package":"@arcgis/map-components","start":0,"end":15},{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":18,"end":27}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"field","name":"serviceUrl","description":"The URL of a Knowledge Graph Service. This can be set to use the agent without a map or link chart view.\n\nIf a map or link chart view reference element are provided, this property will be ignored.","docsTags":[{"name":"example","text":"```html\n<arcgis-assistant>\n <arcgis-assistant-knowledge-agent service-url=\"https://example.esri.com/server/rest/services/Hosted/KGS_Service_Name/KnowledgeGraphServer\"></arcgis-assistant-knowledge-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"null | undefined | string","values":[{"type":"string"}]},"attribute":"service-url","reflects":true},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantKnowledgeAgent = document.createElement(\"arcgis-assistant-knowledge-agent\");\ndocument.body.append(arcgisAssistantKnowledgeAgent);\nawait arcgisAssistantKnowledgeAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-knowledge-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","description":"The reference element to the map that provides context for the navigation agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the navigation agent which map on which to\nperform navigation actions. This is required for the navigation agent to function properly.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"},{"name":"service-url","description":"The URL of a Knowledge Graph Service. This can be set to use the agent without a map or link chart view.\n\nIf a map or link chart view reference element are provided, this property will be ignored.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"serviceUrl"}],"importPath":"components/arcgis-assistant-knowledge-agent"},{"kind":"interface","name":"ArcgisKnowledgeContext","description":"Context required by the Knowledge Link Chart agent.\nSupplied by the application via an agent `getContext()` provider.","type":{"text":"{\n knowledgeGraph: KnowledgeGraph;\n view?: never;\n} | {\n view: LinkChartView | MapView;\n knowledgeGraph?: never;\n}","references":[{"name":"default","module":"rest/knowledgeGraph/KnowledgeGraph.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/rest/knowledgeGraph/KnowledgeGraph/","start":22,"end":36},{"name":"default","module":"views/LinkChartView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/LinkChartView/","start":72,"end":85},{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":88,"end":95}]}}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-knowledge-agent","declaration":{"name":"ArcgisAssistantKnowledgeAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-layer-styling-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-layer-styling-agent/assistant-layer-styling-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantLayerStylingAgent","customElement":true,"tagName":"arcgis-assistant-layer-styling-agent","pascalCaseName":"ArcgisAssistantLayerStylingAgent","docsTags":[{"name":"internal"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-layer-styling-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"referenceElement","type":{"text":"ArcgisMap | string | undefined","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantLayerStylingAgent = document.createElement(\"arcgis-assistant-layer-styling-agent\");\ndocument.body.append(arcgisAssistantLayerStylingAgent);\nawait arcgisAssistantLayerStylingAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-layer-styling-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"importPath":"components/arcgis-assistant-layer-styling-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-layer-styling-agent","declaration":{"name":"ArcgisAssistantLayerStylingAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-navigation-agent","sourcePath":"src/components/assistant/assistant-agents/assistant-navigation-agent/assistant-navigation-agent.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantNavigationAgent","customElement":true,"tagName":"arcgis-assistant-navigation-agent","pascalCaseName":"ArcgisAssistantNavigationAgent","description":"The Navigation Agent enables the end user to navigate to different areas of a web map. See the list\nof capabilities below for more details.\n\nThis is an unrendered component that must be added as a child of the `arcgis-assistant` component in either HTML or JavaScript.\n\n```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant reference-element=\"my-map\">\n <arcgis-assistant-navigation-agent></arcgis-assistant-navigation-agent>\n</arcgis-assistant>\n```\n\n```js\nconst assistant = document.querySelector(\"arcgis-assistant\");\nconst navigationAgent = document.createElement(\"arcgis-assistant-navigation-agent\");\nassistant.appendChild(navigationAgent);\n```\n\nOnce added to the assistant, the agent is loaded and ready to receive user messages related to navigation.\n\n### Capabilities\n\nThe navigation agent provides the following capabilities related to map navigation:\n\n- **Geocoding** - Navigate to an address using Esri's World Geocoding Service.\n- **Go to extent** - Navigate to the extent of a bookmark in the map, the home extent of the web map,\n or the extent of a layer.\n- **Go to features** - Navigate to a specified feature or set of features.\n- **Go to viewpoint** - Navigate to a specified viewpoint, which can include center, zoom, and/or\n rotation.\n\n### Example questions\n\nThe following are example questions a user can ask within the bounds of the navigation agent:\n\n- \"Go to the Golden Gate Bridge\"\n- \"Zoom to a 1 to 24,000 scale\"\n- \"Zoom in\"\n- \"Go to the parks layer\"\n\nThe following are examples of the types of questions that fall outside the bounds of the\nnavigation agent and should therefore be avoided:\n\n- \"Rotate the map 45 degrees\" (this capability is not currently supported but may be in the future)\n- \"Make this map 3D and tilt the view to a 45 degree angle\" (3D navigation is currently not supported)\n- \"Where am I?\" (the navigation agent does not have access to the user's location)\n\n> Due to the non-deterministic nature of generative AI, there may be inaccuracies or unexpected behavior when using the\nout-of-the-box agents.","docsTags":[{"name":"since","text":"5.0"},{"name":"beta"},{"name":"see","text":"[arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/)"},{"name":"see","text":"[Intro to building agentic mapping applications](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-introduction/)"},{"name":"see","text":"[AI Assistant component sample](https://developers.arcgis.com/javascript/latest/sample-code/ai-assistant/)"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-navigation-agent/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"referenceElement","description":"The reference element to the map that provides context for the navigation agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the navigation agent which map on which to\nperform navigation actions. This is required for the navigation agent to function properly.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","docsTags":[{"name":"see","text":"[arcgis-assistant.referenceElement](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#referenceElement)"},{"name":"example","text":"```html\n<arcgis-map id=\"my-map\"></arcgis-map>\n<arcgis-assistant>\n <arcgis-assistant-navigation-agent reference-element=\"my-map\"></arcgis-assistant-navigation-agent>\n</arcgis-assistant>\n```"}],"type":{"text":"ArcgisMap | string | undefined","references":[{"name":"ArcgisMap","module":"components/arcgis-map","package":"@arcgis/map-components","start":0,"end":9}],"values":[{"type":"string"},{"type":"object"}]},"attribute":"reference-element"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantNavigationAgent = document.createElement(\"arcgis-assistant-navigation-agent\");\ndocument.body.append(arcgisAssistantNavigationAgent);\nawait arcgisAssistantNavigationAgent.componentOnReady();\nconsole.log(\"arcgis-assistant-navigation-agent is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"reference-element","description":"The reference element to the map that provides context for the navigation agent. Currently,\nthis is only scoped to `arcgis-map` elements. This shows the navigation agent which map on which to\nperform navigation actions. This is required for the navigation agent to function properly.\n\nSetting this property is not necessary if you set the reference element on the parent\n`arcgis-assistant` component.","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"referenceElement"}],"importPath":"components/arcgis-assistant-navigation-agent"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-navigation-agent","declaration":{"name":"ArcgisAssistantNavigationAgent"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-chat","sourcePath":"src/components/assistant/assistant-chat/assistant-chat.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantChat","customElement":true,"tagName":"arcgis-assistant-chat","pascalCaseName":"ArcgisAssistantChat","description":"Wraps and renders the conversation area. Use it as the container for message list content.\nOffers chat-level layout structure for message starter, message list, and loading regions.","docsTags":[{"name":"internal"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-chat/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"loading","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"loading"},{"kind":"field","name":"messages","type":{"text":"Collection<ChatMessage>","references":[{"name":"default","module":"core/Collection.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Collection/","start":0,"end":10},{"name":"ChatMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessage","start":11,"end":22}]}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantChat = document.createElement(\"arcgis-assistant-chat\");\ndocument.body.append(arcgisAssistantChat);\nawait arcgisAssistantChat.componentOnReady();\nconsole.log(\"arcgis-assistant-chat is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"loading","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"loading"}],"importPath":"components/arcgis-assistant-chat"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-chat","declaration":{"name":"ArcgisAssistantChat"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-chat-entry","sourcePath":"src/components/assistant/assistant-chat-entry/assistant-chat-entry.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantChatEntry","customElement":true,"tagName":"arcgis-assistant-chat-entry","pascalCaseName":"ArcgisAssistantChatEntry","description":"Provides the input bar and submit or cancel behavior. Use it to collect prompts and emit submit events.\nOffers keyboard submit/history behavior, entry action slots, and optional voice-input integration.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-chat-entry/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"awaitingResponse","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"awaiting-response"},{"kind":"field","name":"entryPlaceholder","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"entry-placeholder"},{"kind":"field","name":"inputValue","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","attribute":"input-value"},{"kind":"field","name":"keyboardShortcutsDisabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"keyboard-shortcuts-disabled"},{"kind":"field","name":"messages","type":{"text":"Collection<ChatMessage>","references":[{"name":"default","module":"core/Collection.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/core/Collection/","start":0,"end":10},{"name":"ChatMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessage","start":11,"end":22}]}},{"kind":"field","name":"status","type":{"text":"\"error\" | \"ready\" | \"working\" | undefined","values":[{"type":"string","value":"error"},{"type":"string","value":"ready"},{"type":"string","value":"working"}]},"attribute":"status"},{"kind":"field","name":"voiceInputEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"voice-input-enabled"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantChatEntry = document.createElement(\"arcgis-assistant-chat-entry\");\ndocument.body.append(arcgisAssistantChatEntry);\nawait arcgisAssistantChatEntry.componentOnReady();\nconsole.log(\"arcgis-assistant-chat-entry is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"},{"kind":"method","name":"submitMessage","return":{"type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}},"signature":"(): Promise<void>"}],"attributes":[{"name":"awaiting-response","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"awaitingResponse"},{"name":"entry-placeholder","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"entryPlaceholder"},{"name":"input-value","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","fieldName":"inputValue"},{"name":"keyboard-shortcuts-disabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"keyboardShortcutsDisabled"},{"name":"status","type":{"text":"\"error\" | \"ready\" | \"working\"","values":[{"type":"string","value":"error"},{"type":"string","value":"ready"},{"type":"string","value":"working"}]},"fieldName":"status"},{"name":"voice-input-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"voiceInputEnabled"}],"events":[{"name":"arcgisCancel","type":{"text":"void"}},{"name":"arcgisSubmit","type":{"text":"string"}}],"slots":[{"name":"entry-actions-start","description":"Slot for adding actions to the start of the entry area."},{"name":"entry-actions-end","description":"Slot for adding actions to the end of the entry area."}],"importPath":"components/arcgis-assistant-chat-entry"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-chat-entry","declaration":{"name":"ArcgisAssistantChatEntry"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-interrupt","sourcePath":"src/components/assistant/assistant-interrupt/assistant-interrupt.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantInterrupt","customElement":true,"tagName":"arcgis-assistant-interrupt","pascalCaseName":"ArcgisAssistantInterrupt","description":"Renders interrupt prompts for extra user input. Use it when an agent pauses for confirmation, choice, or text input.\nOffers interrupt-specific input modes and submit or cancel event handling.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-interrupt/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"message","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"message"},{"kind":"field","name":"options","type":{"text":"string[] | undefined"}},{"kind":"field","name":"type","type":{"text":"\"boolean-choice\" | \"multi-select\" | \"single-select\" | \"text-input\"","values":[{"type":"string","value":"boolean-choice"},{"type":"string","value":"multi-select"},{"type":"string","value":"single-select"},{"type":"string","value":"text-input"}]},"attribute":"type"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantInterrupt = document.createElement(\"arcgis-assistant-interrupt\");\ndocument.body.append(arcgisAssistantInterrupt);\nawait arcgisAssistantInterrupt.componentOnReady();\nconsole.log(\"arcgis-assistant-interrupt is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"message","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"message"},{"name":"type","type":{"text":"\"boolean-choice\" | \"multi-select\" | \"single-select\" | \"text-input\"","values":[{"type":"string","value":"boolean-choice"},{"type":"string","value":"multi-select"},{"type":"string","value":"single-select"},{"type":"string","value":"text-input"}]},"fieldName":"type"}],"events":[{"name":"arcgisCancel","type":{"text":"void"}},{"name":"arcgisSubmit","type":{"text":"string[] | boolean | string"}}],"importPath":"components/arcgis-assistant-interrupt"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-interrupt","declaration":{"name":"ArcgisAssistantInterrupt"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message","sourcePath":"src/components/assistant/assistant-message/assistant-message.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessage","customElement":true,"tagName":"arcgis-assistant-message","pascalCaseName":"ArcgisAssistantMessage","description":"Renders a single assistant response message shell. Pass one assistant message object and let it host body and footer actions.\nOffers a reusable assistant-message layout with icon, content, and footer slot regions.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"copyEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"copy-enabled"},{"kind":"field","name":"feedbackEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"feedback-enabled"},{"kind":"field","name":"footerDisabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"footer-disabled"},{"kind":"field","name":"logEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"log-enabled"},{"kind":"field","name":"message","type":{"text":"AssistantMessage | undefined","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"field","name":"readAloudEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"read-aloud-enabled"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessage = document.createElement(\"arcgis-assistant-message\");\ndocument.body.append(arcgisAssistantMessage);\nawait arcgisAssistantMessage.componentOnReady();\nconsole.log(\"arcgis-assistant-message is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"copy-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"copyEnabled"},{"name":"feedback-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"feedbackEnabled"},{"name":"footer-disabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"footerDisabled"},{"name":"log-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"logEnabled"},{"name":"read-aloud-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"readAloudEnabled"}],"importPath":"components/arcgis-assistant-message"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message","declaration":{"name":"ArcgisAssistantMessage"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-block","sourcePath":"src/components/assistant/assistant-message-block/assistant-message-block.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageBlock","customElement":true,"tagName":"arcgis-assistant-message-block","pascalCaseName":"ArcgisAssistantMessageBlock","description":"Renders one structured assistant block. Offers default block rendering for supported suggestion-style blocks.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-block/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"block","type":{"text":"UXSuggestion | undefined","references":[{"name":"UXSuggestion","module":"utils/index","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UXSuggestion","start":0,"end":12}]}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageBlock = document.createElement(\"arcgis-assistant-message-block\");\ndocument.body.append(arcgisAssistantMessageBlock);\nawait arcgisAssistantMessageBlock.componentOnReady();\nconsole.log(\"arcgis-assistant-message-block is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"importPath":"components/arcgis-assistant-message-block"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-block","declaration":{"name":"ArcgisAssistantMessageBlock"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-feedback","sourcePath":"src/components/assistant/assistant-message-feedback/assistant-message-feedback.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageFeedback","customElement":true,"tagName":"arcgis-assistant-message-feedback","pascalCaseName":"ArcgisAssistantMessageFeedback","description":"Handles thumbs up or down feedback UI. Use it to capture helpful or not helpful signals per response.\nOffers feedback toggle behavior and emits feedback updates for the associated assistant message.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-feedback/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"feedbackEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"feedback-enabled"},{"kind":"field","name":"message","type":{"text":"AssistantMessage | undefined","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageFeedback = document.createElement(\"arcgis-assistant-message-feedback\");\ndocument.body.append(arcgisAssistantMessageFeedback);\nawait arcgisAssistantMessageFeedback.componentOnReady();\nconsole.log(\"arcgis-assistant-message-feedback is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"feedback-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"feedbackEnabled"}],"events":[{"name":"arcgisFeedback","type":{"text":"AssistantMessage","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}}],"importPath":"components/arcgis-assistant-message-feedback"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-feedback","declaration":{"name":"ArcgisAssistantMessageFeedback"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-footer","sourcePath":"src/components/assistant/assistant-message-footer/assistant-message-footer.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageFooter","customElement":true,"tagName":"arcgis-assistant-message-footer","pascalCaseName":"ArcgisAssistantMessageFooter","description":"Renders the action row under an assistant message. Use it when you want feedback, log, copy, or read-aloud controls.\nOffers one footer surface that composes common assistant response actions.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-footer/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"copyEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"copy-enabled"},{"kind":"field","name":"feedbackEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"feedback-enabled"},{"kind":"field","name":"logEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"log-enabled"},{"kind":"field","name":"message","type":{"text":"AssistantMessage | undefined","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"field","name":"readAloudEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"read-aloud-enabled"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageFooter = document.createElement(\"arcgis-assistant-message-footer\");\ndocument.body.append(arcgisAssistantMessageFooter);\nawait arcgisAssistantMessageFooter.componentOnReady();\nconsole.log(\"arcgis-assistant-message-footer is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"copy-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"copyEnabled"},{"name":"feedback-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"feedbackEnabled"},{"name":"log-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"logEnabled"},{"name":"read-aloud-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"readAloudEnabled"}],"importPath":"components/arcgis-assistant-message-footer"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-footer","declaration":{"name":"ArcgisAssistantMessageFooter"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-loading","sourcePath":"src/components/assistant/assistant-message-loading/assistant-message-loading.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageLoading","customElement":true,"tagName":"arcgis-assistant-message-loading","pascalCaseName":"ArcgisAssistantMessageLoading","description":"Shows in-progress assistant response UI. Use it to display thinking or loading state while work is running.\nOffers a default loading message shell with icon/content slot overrides.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-loading/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"loading","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"loading"},{"kind":"field","name":"loadingMessage","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","attribute":"loading-message"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageLoading = document.createElement(\"arcgis-assistant-message-loading\");\ndocument.body.append(arcgisAssistantMessageLoading);\nawait arcgisAssistantMessageLoading.componentOnReady();\nconsole.log(\"arcgis-assistant-message-loading is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"loading","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"loading"},{"name":"loading-message","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","fieldName":"loadingMessage"}],"importPath":"components/arcgis-assistant-message-loading"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-loading","declaration":{"name":"ArcgisAssistantMessageLoading"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-log","sourcePath":"src/components/assistant/assistant-message-log/assistant-message-log.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageLog","customElement":true,"tagName":"arcgis-assistant-message-log","pascalCaseName":"ArcgisAssistantMessageLog","description":"Renders expandable execution log details. Use it when exposing agent or tool trace output.\nOffers collapsible log entry rendering for debugging and troubleshooting.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-log/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"log","type":{"text":"string[] | undefined"}},{"kind":"field","name":"logEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"log-enabled"},{"kind":"field","name":"showLog","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"show-log"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageLog = document.createElement(\"arcgis-assistant-message-log\");\ndocument.body.append(arcgisAssistantMessageLog);\nawait arcgisAssistantMessageLog.componentOnReady();\nconsole.log(\"arcgis-assistant-message-log is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"log-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"logEnabled"},{"name":"show-log","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"showLog"}],"importPath":"components/arcgis-assistant-message-log"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-log","declaration":{"name":"ArcgisAssistantMessageLog"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-read-aloud","sourcePath":"src/components/assistant/assistant-message-read-aloud/assistant-message-read-aloud.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageReadAloud","customElement":true,"tagName":"arcgis-assistant-message-read-aloud","pascalCaseName":"ArcgisAssistantMessageReadAloud","description":"Adds text-to-speech playback controls. Use it to read assistant responses aloud.\nOffers read-aloud start/stop behavior with supported-state handling.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-read-aloud/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"message","type":{"text":"AssistantMessage | undefined","references":[{"name":"AssistantMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantMessage","start":0,"end":16}]}},{"kind":"field","name":"readAloudEnabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"read-aloud-enabled"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageReadAloud = document.createElement(\"arcgis-assistant-message-read-aloud\");\ndocument.body.append(arcgisAssistantMessageReadAloud);\nawait arcgisAssistantMessageReadAloud.componentOnReady();\nconsole.log(\"arcgis-assistant-message-read-aloud is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"read-aloud-enabled","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"readAloudEnabled"}],"importPath":"components/arcgis-assistant-message-read-aloud"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-read-aloud","declaration":{"name":"ArcgisAssistantMessageReadAloud"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-message-text","sourcePath":"src/components/assistant/assistant-message-text/assistant-message-text.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantMessageText","customElement":true,"tagName":"arcgis-assistant-message-text","pascalCaseName":"ArcgisAssistantMessageText","description":"Renders assistant message text content. Use it when the block is plain text output.\nOffers sanitized rich-text rendering for assistant-generated message content.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-message-text/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"content","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"content"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantMessageText = document.createElement(\"arcgis-assistant-message-text\");\ndocument.body.append(arcgisAssistantMessageText);\nawait arcgisAssistantMessageText.componentOnReady();\nconsole.log(\"arcgis-assistant-message-text is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"content","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"content"}],"importPath":"components/arcgis-assistant-message-text"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-message-text","declaration":{"name":"ArcgisAssistantMessageText"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-speech-input","sourcePath":"src/components/assistant/assistant-speech-input/assistant-speech-input.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantSpeechInput","customElement":true,"tagName":"arcgis-assistant-speech-input","pascalCaseName":"ArcgisAssistantSpeechInput","description":"Captures voice input and drafts transcript text. Use it to support microphone-based prompt entry.\nOffers voice session lifecycle management and transcription event streams.","docsTags":[{"name":"internal"}],"demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"awaitingResponse","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","attribute":"awaiting-response"},{"kind":"field","name":"inputValue","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","attribute":"input-value"},{"kind":"field","name":"language","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"language"},{"kind":"field","name":"mode","type":{"text":"VoiceInputMode","references":[{"name":"VoiceInputMode","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputMode","start":0,"end":14}],"values":[{"type":"string","value":"disabled"},{"type":"string","value":"media-recorder"},{"type":"string","value":"web-speech"}]},"default":"\"web-speech\"","attribute":"mode"},{"kind":"method","name":"clearDraftSession","return":{"type":{"text":"void"}},"signature":"(): void"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantSpeechInput = document.createElement(\"arcgis-assistant-speech-input\");\ndocument.body.append(arcgisAssistantSpeechInput);\nawait arcgisAssistantSpeechInput.componentOnReady();\nconsole.log(\"arcgis-assistant-speech-input is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"awaiting-response","type":{"text":"boolean","values":[{"type":"boolean"}]},"default":"false","fieldName":"awaitingResponse"},{"name":"input-value","type":{"text":"string","values":[{"type":"string"}]},"default":"\"\"","fieldName":"inputValue"},{"name":"language","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"language"},{"name":"mode","type":{"text":"\"disabled\" | \"media-recorder\" | \"web-speech\"","values":[{"type":"string","value":"disabled"},{"type":"string","value":"media-recorder"},{"type":"string","value":"web-speech"}]},"default":"\"web-speech\"","fieldName":"mode"}],"events":[{"name":"arcgisVoiceInputDraftChange","type":{"text":"VoiceInputDraftChangeDetail","references":[{"name":"VoiceInputDraftChangeDetail","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputDraftChangeDetail","start":0,"end":27}]}},{"name":"arcgisVoiceInputError","type":{"text":"{ errorCode: VoiceInputErrorCode; }","references":[{"name":"VoiceInputErrorCode","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputErrorCode","start":13,"end":32}]}},{"name":"arcgisVoiceInputInterimTranscription","type":{"text":"VoiceInputTranscriptDetail","references":[{"name":"VoiceInputTranscriptDetail","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputTranscriptDetail","start":0,"end":26}]}},{"name":"arcgisVoiceInputStart","type":{"text":"void"}},{"name":"arcgisVoiceInputStop","type":{"text":"void"}},{"name":"arcgisVoiceInputTranscription","type":{"text":"VoiceInputTranscriptDetail","references":[{"name":"VoiceInputTranscriptDetail","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputTranscriptDetail","start":0,"end":26}]}},{"name":"arcgisVoiceInputTranscriptionStreamChunk","type":{"text":"VoiceInputTranscriptionStreamChunkDetail","references":[{"name":"VoiceInputTranscriptionStreamChunkDetail","module":"components/arcgis-assistant-speech-input/support/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-speech-input/support/types#VoiceInputTranscriptionStreamChunkDetail","start":0,"end":40}]}}],"importPath":"components/arcgis-assistant-speech-input"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-speech-input","declaration":{"name":"ArcgisAssistantSpeechInput"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-speech-input/support/types","sourcePath":"src/components/assistant/assistant-speech-input/support/types.ts","declarations":[{"kind":"interface","name":"VoiceInputMode","type":{"text":"\"disabled\" | \"media-recorder\" | \"web-speech\""}},{"kind":"interface","name":"VoiceInputErrorCode","type":{"text":"\"no-speech\" | \"not-allowed\" | \"not-supported\" | \"recording-failed\" | \"transcription-failed\" | \"transcription-unavailable\" | \"unhandled\""}},{"kind":"interface","name":"VoiceInputTranscriptDetail","members":[{"kind":"field","name":"transcript","type":{"text":"string"}}]},{"kind":"interface","name":"VoiceInputDraftChangeDetail","members":[{"kind":"field","name":"focusInput","type":{"text":"boolean | undefined"}},{"kind":"field","name":"value","type":{"text":"string"}}]},{"kind":"interface","name":"VoiceInputTranscriptionStreamChunkDetail","members":[{"kind":"field","name":"blob","type":{"text":"Blob","references":[{"name":"Blob","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/Blob","start":0,"end":4}]}},{"kind":"field","name":"chunkIndex","type":{"text":"number"}},{"kind":"field","name":"isFinal","type":{"text":"boolean"}},{"kind":"field","name":"mimeType","type":{"text":"string"}},{"kind":"field","name":"respondWithTranscript","type":{"text":"(transcript: string) => void"}}]}]},{"kind":"javascript-module","path":"components/arcgis-assistant-suggested-prompts","sourcePath":"src/components/assistant/assistant-suggested-prompts/assistant-suggested-prompts.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantSuggestedPrompts","customElement":true,"tagName":"arcgis-assistant-suggested-prompts","pascalCaseName":"ArcgisAssistantSuggestedPrompts","description":"Displays prompt chips and emits selection events. Use it to offer quick starter prompts.\nOffers selectable prompt chips with a prompt-select event for host synchronization.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-suggested-prompts/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"label","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"label"},{"kind":"field","name":"prompts","type":{"text":"string[]"}},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantSuggestedPrompts = document.createElement(\"arcgis-assistant-suggested-prompts\");\ndocument.body.append(arcgisAssistantSuggestedPrompts);\nawait arcgisAssistantSuggestedPrompts.componentOnReady();\nconsole.log(\"arcgis-assistant-suggested-prompts is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"label","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"label"}],"events":[{"name":"arcgisPromptSelect","type":{"text":"AssistantPromptSelectDetail","references":[{"name":"AssistantPromptSelectDetail","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#AssistantPromptSelectDetail","start":0,"end":27}]}}],"importPath":"components/arcgis-assistant-suggested-prompts"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-suggested-prompts","declaration":{"name":"ArcgisAssistantSuggestedPrompts"}}]},{"kind":"javascript-module","path":"components/arcgis-assistant-user-message","sourcePath":"src/components/assistant/assistant-user-message/assistant-user-message.tsx","declarations":[{"kind":"class","name":"ArcgisAssistantUserMessage","customElement":true,"tagName":"arcgis-assistant-user-message","pascalCaseName":"ArcgisAssistantUserMessage","description":"Renders one user-authored chat message row. Use it for displaying what the user sent.\nOffers a simple user message presentation primitive for custom message-list rendering.","demos":[{"description":"Docs","url":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-user-message/"}],"superclass":{"name":"HTMLElement","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/HTMLElement"},"members":[{"kind":"field","name":"content","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"content"},{"kind":"field","name":"message","type":{"text":"ChatMessage | undefined","references":[{"name":"ChatMessage","module":"components/arcgis-assistant/types","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/types#ChatMessage","start":0,"end":11}]}},{"kind":"field","name":"user","type":{"text":"string | undefined","values":[{"type":"string"}]},"attribute":"user"},{"kind":"method","name":"componentOnReady","description":"Creates a promise that resolves once the component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisAssistantUserMessage = document.createElement(\"arcgis-assistant-user-message\");\ndocument.body.append(arcgisAssistantUserMessage);\nawait arcgisAssistantUserMessage.componentOnReady();\nconsole.log(\"arcgis-assistant-user-message is ready to go!\");\n```"}],"return":{"type":{"text":"Promise<this>","references":[{"name":"Promise","module":"lib/lib.es5.d.ts","package":"typescript","start":0,"end":7}]}},"inheritedFrom":{"name":"this"},"signature":"(): Promise<this>"}],"attributes":[{"name":"content","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"content"},{"name":"user","type":{"text":"string","values":[{"type":"string"}]},"fieldName":"user"}],"importPath":"components/arcgis-assistant-user-message"}],"exports":[{"kind":"custom-element-definition","name":"arcgis-assistant-user-message","declaration":{"name":"ArcgisAssistantUserMessage"}}]},{"kind":"javascript-module","path":"utils/index","sourcePath":"src/utils/index.ts","declarations":[{"kind":"interface","name":"ChatModelTier","docsTags":[{"name":"internal"}],"type":{"text":"\"advanced\" | \"default\" | \"fast\""}},{"kind":"interface","name":"ChatHistory","description":"Represents the chat message history between the user and the assistant, including all messages sent and received during the conversation.\nThis structure is used to provide context for the assistant's responses and can be utilized when invoking prompts to ensure the model\nhas access to the full conversation history.","docsTags":[{"name":"since","text":"5.0"}],"type":{"text":"BaseMessage[]","references":[{"name":"BaseMessage","module":"messages","package":"@langchain/core","start":0,"end":11}]}},{"kind":"interface","name":"UiInterrupt","description":"Represents a user-facing interruption emitted by an agent that requires\ninput before execution can continue. This is used to implement human-in-the-loop workflows where\nthe agent needs to ask the user for clarification, confirmation, or additional information\nbefore proceeding with its tasks.\n\nUsed to pause an agent flow and request clarification, confirmation,\nor additional information from the user.","docsTags":[{"name":"since","text":"5.0"}],"members":[{"kind":"field","name":"id","description":"Unique identifier for this interrupt instance. This is used to associate the interrupt with a\nspecific message or action in the agent's workflow, allowing the system to track and manage the\ninterrupt effectively.","type":{"text":"string"}},{"kind":"field","name":"agentId","description":"Identifier of the agent requesting input (e.g. \"navigation\", \"myCustomAgent\", etc.).\nThis is used to associate the interrupt with the specific agent that emitted it, which\ncan be helpful for debugging, logging, and providing context to the user about which agent\nis requesting input.","type":{"text":"string"}},{"kind":"field","name":"kind","description":"The type of input being requested. See the list below for the currently supported input types. This is used\nto determine how to render the interrupt in the user interface and what kind of input to expect from the user.\n\n- `booleanChoice` - Presents the user with a yes or no option. This is typically used for confirmation\nprompts where the agent needs to confirm an action with the user before proceeding. For example, some actions\nmay have a high risk of being destructive, such as applying an edit, submitting a form, or deleting data.\nIn these cases, the agent might ask for confirmation before proceeding.\n- `multipleSelection` - Presents the user with multiple options that the user may choose from in a checkbox\ninterface.\n- `singleSelection` - Presents the user with a list of options in a radio button interface, prompting the user\nto select a single option from a list.\n- `textInput` - Prompts the user to enter free-form text before proceeding. This is a flexible input\ntype that can be used for a wide variety of purposes, such as asking the user for more details about\na request, requesting specific information needed to complete a task, or allowing the user to\nprovide feedback or additional context.","type":{"text":"\"booleanChoice\" | \"multipleSelection\" | \"singleSelection\" | \"textInput\""}},{"kind":"field","name":"message","description":"The message shown to the user when prompting for input. This should provide clear instructions or\nquestions related to the interrupt, guiding the user on what information is needed or what action\nthey should take in response to the prompt.","type":{"text":"string | undefined"}},{"kind":"field","name":"metadata","description":"Additional data required to render or handle the interrupt. This is typically an array of strings\nrepresenting options for selection when the `kind` is `multipleSelection` or `singleSelection`.\nFor `booleanChoice`, the options are implicitly \"Yes\" and \"No\" and do not need to be provided.\nFor `textInput`, options are not applicable and should be omitted.","type":{"text":"unknown | undefined"}}]},{"kind":"interface","name":"AgentRegistration","description":"Definition of a client-side agent to register to the [arcgis-assistant-agent](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant-agent/) component.\nTo construct an agent, you must build a state graph using LangGraph that defines the agent's\nnodes, edges, workspace variables, and tools.","docsTags":[{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"},{"name":"beta"},{"name":"since","text":"5.0"}],"members":[{"kind":"field","name":"id","description":"A unique identifier for the agent.","type":{"text":"string"}},{"kind":"field","name":"name","description":"A human-readable name for the agent. This must be unique, but also be semantically meaningful.","type":{"text":"string"}},{"kind":"field","name":"description","description":"A brief description of the agent's purpose and functionality. This is required for the agent to be\ndiscoverable in the orchestration of the [arcgis-assistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/). It should provide enough information\nfor the Assistant component and users to understand when to use this agent and what it can do.\nThis description should provide examples of user prompts that would indicate this agent should be used.","docsTags":[{"name":"example","text":"```js\nagentRegistration.description = \"This agent calculates service areas for a given location.\nUse this agent when users ask questions about drive or walk times from a specific location, or when they\nask for areas reachable within a certain time frame from a location.\";\n```"}],"type":{"text":"string"}},{"kind":"field","name":"createGraph","description":"A function that creates and returns the agent's state graph. This graph defines the agent's behavior,\nincluding how it processes inputs, makes decisions, and produces outputs. The graph consists of nodes and edges\nthat represent the agent's deterministic logic and flow. This is a structure defined using LangGraph's StateGraph.","docsTags":[{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[StateGraph documentation](https://langchain-ai.github.io/langgraphjs/reference/classes/langgraph.StateGraph.html)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"type":{"text":"() => StateGraph<unknown>","references":[{"name":"StateGraph","module":"web","package":"@langchain/langgraph","start":6,"end":16}]}},{"kind":"field","name":"workspace","description":"The workspace variables or context required by the agent's graph. This includes messages, results,\nand any other relevant data required by the LLM to make decisions and determine parameters for function calls.\nThis is a structure defined using LangGraph's AnnotationRoot.","docsTags":[{"name":"see","text":"[LangGraph documentation](https://docs.langchain.com/oss/javascript/langgraph/overview)"},{"name":"see","text":"[AnnotationRoot documentation](https://langchain-ai.github.io/langgraphjs/reference/modules/langgraph.Annotation.html)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"type":{"text":"AnnotationRoot<any>","references":[{"name":"AnnotationRoot","module":"web","package":"@langchain/langgraph","start":0,"end":14}]}}]},{"kind":"interface","name":"ArcgisPromptOptions","description":"Options for sending a prompt to an LLM.","docsTags":[{"name":"since","text":"5.0"}],"members":[{"kind":"field","name":"promptText","description":"The input prompt text to send to the model.","type":{"text":"string"}},{"kind":"field","name":"modelTier","description":"The model tier to use. See the following options:\n\n- `default` - The default model tier, which provides a balance of performance and cost.\n This is suitable for most general-purpose use cases. At JS SDK v5.0, this model\n tier corresponds to GPT-5 mini model.\n- `advanced` - An advanced model tier that may provide improved accuracy or capabilities compared to\n the default tier. However, it may also come with increased cost and slower performance. At\n JS SDK v5.0, this model tier corresponds to GPT-5.2 model.\n- `fast` - A lower cost model suitable for tasks like classification and summarization. This tier may have limitations in terms of response length and complexity.\n New at JS SDK v5.1, this model tier corresponds to GPT-5.4-nano model.\n\nThe specific models available in each tier may evolve over time as new models are released and existing\nmodels are retired. The dates models are retired depends on the model provider and therefore may not\nalign with the semantic versioning rules of the JS SDK. Therefore, the user experience of apps may break\nin a minor version update of the JS SDK. It is important to keep your implementation flexible and test your prompts\nregularly to ensure they continue to perform as expected, especially when updating the JS SDK version or\n when new models are released.\n\nNote that the same prompt will not necessarily produce the same results across different\nmodels. As models are updated, you will need to re-evaluate the prompts you send to the LLM, including\nagent descriptions and tool node descriptions to\nensure they still return the expected responses. You should adjust your implementation as needed.","type":{"text":"ChatModelTier | undefined","references":[{"name":"ChatModelTier","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ChatModelTier","start":0,"end":13}]}},{"kind":"field","name":"temperature","description":"The temperature to use for the model (a number between 0 and 1). Higher values will result in more\ncreative and varied responses, while lower values will produce more focused and deterministic responses.","type":{"text":"number | undefined"}},{"kind":"field","name":"messages","description":"The chat history used to provide context for the prompt. This should include the recent messages\nexchanged between the user and the assistant that are necessary for the model to generate an\ninformed response. Providing chat history can help the model understand the conversation context\nand produce more accurate and relevant responses.","type":{"text":"ChatHistory | undefined","references":[{"name":"ChatHistory","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ChatHistory","start":0,"end":11}]}},{"kind":"field","name":"abortSignal","description":"Abort signal for cooperative run cancellation.","type":{"text":"AbortSignal | undefined","references":[{"name":"AbortSignal","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/AbortSignal","start":0,"end":11}]}},{"kind":"field","name":"inputVariables","description":"Input variables for the prompt. This can include any relevant variables related to the context\nprovided to the agent. This may be necessary for determining tool parameters or for providing additional\ncontext to the model when generating a response.","type":{"text":"Record<string, unknown> | undefined","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}]},{"kind":"interface","name":"ArcgisStructuredPromptOptions","description":"Options when sending a prompt to an LLM that expects a structured response validated against a Zod schema.","docsTags":[{"name":"since","text":"5.0"}],"typeParameters":[{"name":"T"}],"supertypes":[{"name":"ArcgisPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisPromptOptions"}],"members":[{"kind":"field","name":"schema","description":"A Zod schema that defines the expected structure of the model's response. For example, if the expected\nresult from a prompt sent to an LLM is parameters for a tool function that executes specific JS SDK core\nAPI calls, the schema should define the structure of those parameters. This allows the response from the model\nto be validated and parsed according to the defined schema, ensuring type safety and consistency.","docsTags":[{"name":"see","text":"[Zod documentation](https://zod.dev/api)"}],"type":{"text":"ZodType<T>","references":[{"name":"ZodType","package":"zod","start":0,"end":7},{"name":"T","start":8,"end":9}]}}]},{"kind":"interface","name":"ArcgisToolPromptOptions","description":"Options when sending a prompt to an LLM when the node is expected to invoke tools (e.g. functions defined\nin the client). This includes the array of tools that the model can choose to invoke in response to the prompt.","docsTags":[{"name":"since","text":"5.0"}],"supertypes":[{"name":"ArcgisPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisPromptOptions"}],"members":[{"kind":"field","name":"tools","description":"An array of tools that the model can choose to invoke in response to the prompt.","docsTags":[{"name":"see","text":"[StructuredToolInterface documentation](https://reference.langchain.com/javascript/interfaces/_langchain_core.tools.StructuredToolInterface.html)"}],"type":{"text":"StructuredToolInterface[]","references":[{"name":"StructuredToolInterface","module":"tools","package":"@langchain/core","start":0,"end":23}]}}]},{"kind":"interface","name":"TraceEventData","description":"Data structure for trace messages emitted by agents during graph execution.\nThis is used to send trace messages to the log in the chat interface, allowing users to see the\nintermediate steps and thought processes of the agent as it executes its graph.\nThis log will only be visible if the [ArcGISAssistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#logEnabled) property is set to `true`.","docsTags":[{"name":"since","text":"5.0"},{"name":"see","text":"[ArcGISAssistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#logEnabled)"}],"members":[{"kind":"field","name":"text","description":"The text content of the trace message. This should provide information about the agent's current state,\nthe actions it is taking, the decisions it is making, or any other relevant details that can help users\nunderstand the agent's behavior and thought process.","type":{"text":"string"}},{"kind":"field","name":"agentName","description":"The name of the agent associated with this trace message. This can help provide\nadditional context to users about which agent is emitting the trace message, especially in scenarios\nwhere multiple agents are involved in a conversation or workflow.","type":{"text":"string | undefined"}},{"kind":"field","name":"toolName","description":"The name of the tool associated with the trace message. This can help provide\nadditional context to users about which tool (e.g. function defined in the client) is being invoked or\nreferenced in the trace message, especially when the agent is using multiple tools in its workflow.","type":{"text":"string | undefined"}}]},{"kind":"function","name":"invokeTextPrompt","description":"Sends a prompt to an LLM and returns a plain text response. This function should be used when you expect\na simple text response from the model without the need for structured parsing or tool invocation.","docsTags":[{"name":"since","text":"5.0"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"parameters":[{"name":"options","description":"Options for the prompt, including the prompt text, model tier,\n temperature, chat history, and input variables.","type":{"text":"ArcgisPromptOptions","references":[{"name":"ArcgisPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisPromptOptions","start":0,"end":19}]}}],"return":{"description":"The model response.","type":{"text":"Promise<string>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}},{"kind":"function","name":"invokeStructuredPrompt","description":"Sends a prompt to an LLM and returns a structured response validated against a Zod schema.","docsTags":[{"name":"see","text":"[Zod documentation](https://zod.dev/api)"},{"name":"since","text":"5.0"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"typeParameters":[{"name":"T"}],"parameters":[{"name":"options","description":"Prompt options, including a Zod schema for response validation.","type":{"text":"ArcgisStructuredPromptOptions<T>","references":[{"name":"ArcgisStructuredPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisStructuredPromptOptions","start":0,"end":29},{"name":"T","start":30,"end":31}]}}],"return":{"description":"The model response parsed into the structure defined by the provided Zod schema.","type":{"text":"Promise<T>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"T","start":8,"end":9}]}}},{"kind":"function","name":"invokeToolPrompt","description":"Invokes a prompt with tools enabled and returns the model's tool call response.","docsTags":[{"name":"since","text":"5.0"},{"name":"see","text":"[AIMessage documentation](https://reference.langchain.com/javascript/classes/_langchain_core.messages.AIMessage.html)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"parameters":[{"name":"options","description":"Prompt options, including an array of tools the model can invoke.","type":{"text":"ArcgisToolPromptOptions","references":[{"name":"ArcgisToolPromptOptions","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ArcgisToolPromptOptions","start":0,"end":23}]}}],"return":{"description":"Resolves to the model's response as an AIMessage as defined in LangChain.","type":{"text":"Promise<AIMessage>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"AIMessage","module":"messages","package":"@langchain/core","start":8,"end":17}]}}},{"kind":"function","name":"sendTraceMessage","description":"Dispatches a graph trace message to the log in the chat interface. This allows agents to emit trace\nmessages during graph execution, providing users with insights into the intermediate steps, decisions,\nand actions taken by the agent. These trace messages can help users understand the agent's thought\nprocess and behavior as it executes its graph. It can also be useful for debugging and\ntransparency purposes.","docsTags":[{"name":"since","text":"5.0"},{"name":"see","text":"[ArcGISAssistant](https://developers.arcgis.com/javascript/latest/references/ai-components/components/arcgis-assistant/#logEnabled)"},{"name":"see","text":"[RunnableConfig documentation](https://reference.langchain.com/javascript/interfaces/_langchain_core.runnables.RunnableConfig.html)"},{"name":"see","text":"[Custom agents guide](https://developers.arcgis.com/javascript/latest/agentic-apps/ai-custom-agents/)"}],"parameters":[{"name":"data","description":"Trace event data to display in the chat log, including the message, agent, and tool if applicable.","type":{"text":"TraceEventData","references":[{"name":"TraceEventData","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#TraceEventData","start":0,"end":14}]}},{"name":"config","description":"Optional runnable configuration\n [as defined in LangChain](https://reference.langchain.com/javascript/interfaces/_langchain_core.runnables.RunnableConfig.html),\n which can include additional context or variables to associate with the trace message.","optional":true,"type":{"text":"RunnableConfig","references":[{"name":"RunnableConfig","module":"runnables","package":"@langchain/core","start":0,"end":14}]}}],"return":{"description":"A promise that resolves once the event has been dispatched.","type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}},{"kind":"function","name":"getEmbeddings","description":"Generates vector embeddings for an array of strings.","parameters":[{"name":"inputs","description":"An array of text strings to be embedded.","type":{"text":"string[]"}}],"return":{"description":"A promise that resolves to an array of embedding vectors.","type":{"text":"Promise<number[][]>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}},{"kind":"function","name":"cosineSimilarity","description":"Calculates the cosine similarity between two numeric vectors. This is used to measure the similarity\nbetween two embedding vectors, where a score of 1 indicates identical vectors, 0 indicates orthogonal\nvectors, and -1 indicates opposite vectors.","parameters":[{"name":"vectorA","description":"The first vector array.","type":{"text":"number[]"}},{"name":"vectorB","description":"The second vector array.","type":{"text":"number[]"}}],"return":{"description":"A similarity score from -1 (opposite) to 1 (identical).","type":{"text":"number"}}},{"kind":"interface","name":"UXSuggestion","description":"The suggestions emitted by the agent to the user interface.","docsTags":[{"name":"since","text":"5.1"}],"members":[{"kind":"field","name":"type","description":"The type of suggestion being made.","type":{"text":"string"}},{"kind":"field","name":"data","description":"Optional additional data associated with the suggestion.","type":{"text":"Record<string, unknown> | undefined","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}]},{"kind":"interface","name":"AgentStatus","description":"Execution status returned by an agent run.","docsTags":[{"name":"since","text":"5.1"}],"type":{"text":"\"failed\" | \"success\" | \"unknown\""}},{"kind":"interface","name":"PriorStep","description":"Summary of a previously executed agent step.","docsTags":[{"name":"since","text":"5.1"}],"members":[{"kind":"field","name":"agentId","description":"The agent that handled the step.","type":{"text":"string"}},{"kind":"field","name":"assignedTask","description":"The task assigned to the agent for this step.","type":{"text":"string"}},{"kind":"field","name":"summary","description":"A brief summary of the step's execution.","type":{"text":"string"}},{"kind":"field","name":"status","description":"The execution status of the step.","type":{"text":"AgentStatus","references":[{"name":"AgentStatus","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentStatus","start":0,"end":11}]}}]},{"kind":"interface","name":"AgentExecutionContext","description":"Runtime execution context available to agent graph nodes and tools.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"members":[{"kind":"field","name":"userRequest","description":"The user's original request.","type":{"text":"string"}},{"kind":"field","name":"assignedTask","description":"The task assigned to the agent.","type":{"text":"string"}},{"kind":"field","name":"messages","description":"The message history for the run","type":{"text":"ChatHistory","references":[{"name":"ChatHistory","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ChatHistory","start":0,"end":11}]}},{"kind":"field","name":"priorSteps","description":"Previous steps","type":{"text":"PriorStep[]","references":[{"name":"PriorStep","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#PriorStep","start":0,"end":9}]}},{"kind":"field","name":"sharedState","description":"Shared state available to the agent.","type":{"text":"SharedState<TState>","references":[{"name":"SharedState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#SharedState","start":0,"end":11},{"name":"TState","start":12,"end":18}]}}]},{"kind":"variable","name":"NavigationAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"interface","name":"NavigationContext","docsTags":[{"name":"internal"}],"members":[{"kind":"field","name":"mapView","type":{"text":"MapView","references":[{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":0,"end":7}]}}]},{"kind":"variable","name":"LayerStylingAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"interface","name":"LayerStylingContext","docsTags":[{"name":"internal"}],"members":[{"kind":"field","name":"mapView","type":{"text":"MapView","references":[{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":0,"end":7}]}}]},{"kind":"variable","name":"DataExplorationAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"interface","name":"DataExplorationContext","docsTags":[{"name":"internal"}],"members":[{"kind":"field","name":"mapView","type":{"text":"MapView","references":[{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":0,"end":7}]}}]},{"kind":"variable","name":"HelpAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"variable","name":"ArcgisKnowledgeAgent","docsTags":[{"name":"internal"}],"type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"interface","name":"ArcgisKnowledgeContext","docsTags":[{"name":"internal"}],"type":{"text":"{\n knowledgeGraph: KnowledgeGraph;\n view?: never;\n} | {\n view: LinkChartView | MapView;\n knowledgeGraph?: never;\n}","references":[{"name":"default","module":"rest/knowledgeGraph/KnowledgeGraph.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/rest/knowledgeGraph/KnowledgeGraph/","start":22,"end":36},{"name":"default","module":"views/LinkChartView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/LinkChartView/","start":72,"end":85},{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":88,"end":95}]}},{"kind":"variable","name":"createWebmapEmbeddings","docsTags":[{"name":"internal"}],"type":{"text":"(mapView: MapView) => Promise<{\n schemaVersion: \"0.1\";\n modified: number;\n embeddings: {\n modelProvider: \"openai\";\n model: string;\n dimensions: 1536;\n templates: {\n layer: string;\n field: string;\n };\n };\n layers: Array<{\n id: string;\n name: string;\n title: string;\n description: string;\n vector: Array<number>;\n fields: Array<{\n name: string;\n alias: string;\n description: string;\n vector: Array<number>;\n }>;\n }>;\n}>","references":[{"name":"default","module":"views/MapView.js","package":"@arcgis/core","viewUrl":"https://developers.arcgis.com/javascript/latest/references/core/views/MapView/","start":10,"end":17},{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":22,"end":29},{"name":"Array","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array","start":285,"end":290},{"name":"Array","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array","start":403,"end":408},{"name":"Array","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array","start":434,"end":439},{"name":"Array","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array","start":548,"end":553}]}},{"kind":"interface","name":"GetContext","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TContext","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"members":[{"kind":"call-signature","return":{"type":{"text":"Promise<TContext> | TContext","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"TContext","start":8,"end":16},{"name":"TContext","start":20,"end":28}]}}}]},{"kind":"interface","name":"AgentWithContext","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TContext","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"members":[{"kind":"field","name":"agent","type":{"text":"AgentRegistration","references":[{"name":"AgentRegistration","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentRegistration","start":0,"end":17}]}},{"kind":"field","name":"getContext","description":"Lazily resolves runtime context.\nCan be sync or async, and may perform lifecycle checks (e.g. await view.when()).","type":{"text":"GetContext<TContext> | undefined","references":[{"name":"GetContext","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#GetContext","start":0,"end":10},{"name":"TContext","start":11,"end":19}]}}]},{"kind":"interface","name":"AgentExecutionContextWithSharedState","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"supertypes":[{"name":"AgentExecutionContext","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentExecutionContext","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]}]},{"kind":"interface","name":"StatelessAgentBaseState","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"members":[{"kind":"field","name":"agentExecutionContext","type":{"text":"BaseChannel<AgentExecutionContextWithSharedState<TState>, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11},{"name":"AgentExecutionContextWithSharedState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentExecutionContextWithSharedState","start":12,"end":48},{"name":"TState","start":49,"end":55}]}},{"kind":"field","name":"outputMessage","type":{"text":"BaseChannel<string, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11}]}},{"kind":"field","name":"summary","type":{"text":"BaseChannel<string, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11}]}},{"kind":"field","name":"status","type":{"text":"BaseChannel<AgentStatus | undefined, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11},{"name":"AgentStatus","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#AgentStatus","start":12,"end":23}]}}]},{"kind":"interface","name":"StatefulAgentBaseState","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"supertypes":[{"name":"StatelessAgentBaseState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#StatelessAgentBaseState","typeArguments":[{"text":"TState","references":[{"name":"TState","start":0,"end":6}]}]}],"members":[{"kind":"field","name":"sharedStatePatch","type":{"text":"BaseChannel<SharedStatePatch<TState> | undefined, unknown, unknown>","references":[{"name":"BaseChannel","module":"web","package":"@langchain/langgraph","start":0,"end":11},{"name":"SharedStatePatch","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#SharedStatePatch","start":12,"end":28},{"name":"TState","start":29,"end":35}]}}]},{"kind":"function","name":"createAgentRuntimeState","description":"Creates the standard runtime state for a custom agent graph.\nIncludes common fields used by the assistant flow (request context, output message, summary, and status), so you only add your agent-specific state.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"return":{"type":{"text":"StatelessAgentBaseState<TState>","references":[{"name":"StatelessAgentBaseState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#StatelessAgentBaseState","start":0,"end":23},{"name":"TState","start":24,"end":30}]}}},{"kind":"function","name":"createAgentRuntimeStateWithSharedState","description":"Creates the standard runtime state for a custom agent graph, plus support for shared state updates.\nUse this when your agent needs to write values that other agents can read later in the same orchestration flow.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"TState","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"return":{"type":{"text":"StatefulAgentBaseState<TState>","references":[{"name":"StatefulAgentBaseState","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#StatefulAgentBaseState","start":0,"end":22},{"name":"TState","start":23,"end":29}]}}},{"kind":"function","name":"sendUXSuggestion","description":"Sends an optional UX suggestion from an agent run to the host application.\nUse this for non-blocking hints (for example, recommended next actions or UI prompts) that the app may choose to display.","docsTags":[{"name":"since","text":"5.1"}],"parameters":[{"name":"suggestion","type":{"text":"UXSuggestion","references":[{"name":"UXSuggestion","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#UXSuggestion","start":0,"end":12}]}},{"name":"config","optional":true,"type":{"text":"RunnableConfig","references":[{"name":"RunnableConfig","module":"runnables","package":"@langchain/core","start":0,"end":14}]}}],"return":{"type":{"text":"Promise<void>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7}]}}},{"kind":"interface","name":"SharedStateEntry","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"T","default":{"text":"unknown"}}],"members":[{"kind":"field","name":"value","type":{"text":"T","references":[{"name":"T","start":0,"end":1}]}},{"kind":"field","name":"meta","type":{"text":"{\n updatedByAgentId: string;\n updatedAt: number;\n}"}}]},{"kind":"interface","name":"SharedStatePatchEntry","docsTags":[{"name":"internal"}],"typeParameters":[{"name":"T","default":{"text":"unknown"}}],"members":[{"kind":"field","name":"value","type":{"text":"T","references":[{"name":"T","start":0,"end":1}]}}]},{"kind":"interface","name":"SharedState","description":"Shared state that can be read and updated during agent execution.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"T","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"type":{"text":"{\n [K in keyof T]?: SharedStateEntry<T[K]>;\n}","references":[{"name":"T","start":18,"end":19},{"name":"SharedStateEntry","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#SharedStateEntry","start":23,"end":39},{"name":"T","start":40,"end":41}]}},{"kind":"interface","name":"SharedStatePatch","description":"Partial shared state returned by an agent for merging into the current run state.","docsTags":[{"name":"since","text":"5.1"}],"typeParameters":[{"name":"T","constraint":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]},"default":{"text":"Record<string, unknown>","references":[{"name":"Record","package":"global:","viewUrl":"https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type","start":0,"end":6}]}}],"type":{"text":"{\n [K in keyof T]?: SharedStatePatchEntry<T[K]>;\n}","references":[{"name":"T","start":18,"end":19},{"name":"SharedStatePatchEntry","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#SharedStatePatchEntry","start":23,"end":44},{"name":"T","start":45,"end":46}]}},{"kind":"function","name":"createChatModel","docsTags":[{"name":"internal"}],"parameters":[{"name":"parameter0","optional":true,"type":{"text":"{\n modelTier?: ChatModelTier;\n temperature?: number;\n abortSignal?: AbortSignal;\n}","references":[{"name":"ChatModelTier","viewUrl":"https://developers.arcgis.com/javascript/latest/references/ai-components/utils/index/#ChatModelTier","start":18,"end":31},{"name":"AbortSignal","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/API/AbortSignal","start":77,"end":88}]}}],"return":{"type":{"text":"Promise<ChatOpenAI>","references":[{"name":"Promise","package":"global:","viewUrl":"https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise","start":0,"end":7},{"name":"ChatOpenAI","package":"@langchain/openai","start":8,"end":18}]}}}]}]}
|