Agent Edit Property Dialog
Overview
Custome Agents are composed of two dialogs, the Edit Property dialog
and Edit Agent dialog
. The Property dialog settings will control what UX exist on the Edit Agent dialog
.
The Edit Property dialog is used to define or modify the core attributes and behaviors of a custom agent. By specifying a unique name, descriptive purpose, data retrieval methods, response handling, and optional post-processing logic, you can create an agent that seamlessly integrates with your data sources and delivers meaningful results.
Fields and Descriptions
-
Name
- Purpose: Assign a unique, descriptive identifier to your agent.
- Guidance:
Choose a name that clearly reflects the agent’s role or function to ensure easy identification by both team members and the LLM reasoning engine.
-
Description
- Purpose: Provide a concise explanation of the agent’s purpose and functionality. Limit to 1000 characters
- Guidance:
Focus on the agent’s primary role and the type of data or tasks it handles. This helps the Language Learning Model (LLM) invoke the agent at the appropriate times and scenarios.
-
Data Source
- Purpose: Specify the type of API from which the agent will receive its data.
- Options:
- None: The agent does not fetch any external data. Example you want the agent to be a Template (HTML) i.e. a widget that needs no data, like an iFrame or Calculator
- GraphQL: Data is retrieved from a GraphQL API.
- REST API: Data is retrieved from a RESTful API.
- Guidance:
Select the data source that best matches the service you request date to. If your agent needs dynamic, real-time information, use REST or GraphQL. If it doesn’t require external data, select None. Example would be a Template (HTML widget)
-
Handle Response
-
Purpose: Determine how the agent’s returned JSON data to.
-
Options:
- LLM to process data (Default): The JSON is returned to the Reasoning Engine LLM for processing.
- Carousel: JSON is passed directly to the client to render as a visual carousel or list.
- Template (HTML): JSON and LLM-generated data are injected into a custom HTML template for rich, formatted output. Example a Google Chart.
- Form: Dynamically creates a form, leveraging the ai12z form control for user input or data processing.
-
Process (Optional; controlled by the endpoint) When the Handle Resonse is set to carousel. The data source can override the Handle Response property by setting the
process
field in the returned object tocarousel
,llm
, orboth
. For example, if you’re interacting with a ticketing system and only one event is returned, you might setprocess
toboth
so the LLM can provide additional context while the event also appears in the carousel. If your request returns zero results, setprocess
tollm
so the LLM can display a helpful message instead of simply “No results.” And if you have many results, you can bypass the LLM entirely by settingprocess
tocarousel
and sending the data straight to the client’s carousel. -
Guidance:
Choose the format that best suits your application’s user experience.
-
-
Custom Function (Python)
- Purpose: Optionally apply Python code to further refine or manipulate the JSON or GraphQL response data. This is An optional final processing step where Python code can modify or process the JSON data before returning results to the LLM, HTML widget or to the client, depending on how Handle Response is configured.
- Guidance:
Best practice it is often easier to use JSONata, but there are some cases Python might be a better fit. GraphQL, usually it filters the results and typically do not need JSONata or Python.
After updating this dialog, click the Next
to go to the Edit Agent dialog
Best Practices
- Be Descriptive, Yet Concise:
Use the Name and Description fields to clearly convey the agent’s purpose. A well-defined name and description help ensure the LLM leverages the agent effectively. - Select the Right Data Source:
Align the Data Source with your backend infrastructure. GraphQL and REST are ideal for real-time data retrieval and updating. - Tailor the Response Handling:
Think about how end-users will interact with the returned data. For direct, processed answers, stick to LLM processing. For visually rich or interactive experiences, leverage Carousel, Template HTML. Use a Form if you need to collect data, but you can also uset a Template HTML widget to collect data - Leverage the Custom Function Wisely:
If your use case demands additional logic beyond the standard flows, take advantage of the Custom Function to clean, transform, or enhance the data before it’s rendered.
Conclusion
The Edit Property dialog provides a flexible, customizable framework for defining how your custom agent will behave within the ai12z platform. By thoughtfully configuring each field—Name, Description, Data Source, Handle Response, and Custom Function—you ensure your agent not only gathers the right data but also presents it in the most engaging and contextually relevant form for your users.