WEM AI Agent
The AI Agent Resource Tab in your WEM Project
The AI Agent tab in the resource pane is where Agents are created and managed within the WEM Modeler. This interface provides an intuitive way to configure AI Agents, define their properties, and integrate them into your application workflows.
Below is an image illustrating the location of the AI Agent tab in the resource pane. This tab serves as the central hub for managing agents, allowing developers to orchestrate application agents efficiently.

Adding a New Agent
A new AI Agent can be added by right-clicking and selecting the New AI Agent option from the context menu. This will open the "New AI Agent" Wizard, where you can configure the following options:

Name: This serves as the identifier for the AI Agent. Choose a meaningful name to easily recognize the Agent's role within your application.
Instruction: This defines the behaviour and purpose of the Agent. It's essentially a description of what the Agent should do, guiding its decision-making process and responses within the application. This instruction is very important to setup correctly - like Prompt-Engineering for Generative AI is a newly emerging "art" to get better results and ensure security.
Provider: The AI provider powering the agent. WEM now supports multiple providers — select the one that matches your organisation's license and use case:
OpenAI — industry-standard models including the GPT-4.1 and GPT-5 series, with support for hosted tools (File search, Web search, Code interpreter) and reasoning models.
AzureOpenAI — the same OpenAI models hosted on Microsoft Azure, suited for organisations with existing Azure agreements or data residency requirements.
Anthropic — Claude model series, supporting extended context and thinking/reasoning capabilities.
Google — Gemini model series, including flash variants optimised for speed and cost.
Cerebras — high-speed inference on dedicated hardware, suited for latency-sensitive applications.
The provider can also be changed on an existing agent after creation.
Model: The specific AI model assigned to the agent. The available models update automatically based on the selected Provider. Each model has different strengths around reasoning capability, response speed, context window size, and cost — choose based on the agent's role and expected workload.
The model can be changed on an existing agent after creation. Note that changing the provider or model of an agent that already has active conversations will clear any provider-specific conversation state.
For an up-to-date overview of available models and their capabilities, refer to your provider's documentation:
Model version: Allows you to pin the agent to a specific version of the selected model, or leave it on Latest to always use the most recent release. Pinning a version is recommended for production agents where consistent, predictable behaviour is important. Using Latest is useful during development or when you want to benefit from model improvements automatically.
Options: Available options depend on the selected Provider, Model, and Model version. Each option's Default value reflects the provider's recommended setting for general-purpose use — a good starting point unless you have a specific reason to change it.
For details on what an option does, refer to your provider's documentation (OpenAI, Anthropic, Google Gemini, Azure OpenAI, Cerebras) — or just ask the agent itself in a test conversation.
Properties of an Agent
After creating an AI Agent, its properties can be configured to define its behaviour and enhance its capabilities through functions. These properties determine how the Agent interacts with the application, which information it can process and what functionalities it can execute.


Conversation Context
The conversation context acts as a "session field" where relevant information is stored throughout an interaction. This data is not directly processed by the AI, but is part of the WEM Agent's context, allowing the application runtime to utilize it for continuity between exchanges. This enables the Agent to maintain context within a session without increasing token usage.
File Sources
Agents can be assigned files, which are stored in a vectorised format for efficient retrieval. These files function as an additional knowledge base, providing structured information that the Agent can reference. While the AI does not treat the entire file content as tokens, any quoted sections may count towards response tokens. This allows for efficient, context-aware responses without excessive computational costs. Files uploaded as part of the File sources are accessible for all instances of this agent, be mindful of what you include as part of the Files sources. This can best be used to supply the agent with documentation or company policies but should not be used to upload files containing personal or proprietary data.
File fields from the datamodel can only be used when the file type validation is set on the field itself. This is to make sure documents can be interpreted correctly and safely.
Functions
Functions extend an Agent's capabilities by enabling it to execute predefined actions. These functions operate similarly to flowcharts in the Modeler but are specifically designed for the Agent to follow. By defining structured flows, the Agent can perform tasks beyond text generation, such as triggering processes, interacting with data sources, or modifying system states based a users input. Because the agent knows which functions it has available to them it best practise to instruct the agent to not share this with users in the agent instructions.
Function parameters
Function parameters define specific fields or lists used by a function to execute correctly. Parameters can be simple values such as strings or numbers, or more complex objects containing multiple fields or even lists. When a user makes a request, the Agent identifies the relevant function and populates its parameters with data extracted from the conversation, file sources, or other context. This ensures that the function operates with precise and relevant information, enabling accurate automation and reducing ambiguity. Parameters may have defined types, required/optional status, and default values, ensuring consistent behaviour across different Agent interactions. Using the required property on certain fields can help to force the agent query the user on all relevant information.
AI Agent Conversation field type
A dedicated AI agent conversation field type is now available in the Data Model. This replaces the previous practice of using a plain text field to store a conversation ID.
When adding a new field, select AI agent conversation as the type and link it to the specific AI agent the conversation belongs to. This makes it immediately clear in the data model that a field represents a conversation, rather than an arbitrary text value.
AI Agent configuration
For AI agents to function in a specific environment, every provider used in your project must be configured with valid credentials.
This configuration is managed in the DevOps portal on a per-portal, per-environment basis; meaning you will need to set it up separately for each environment (e.g. staging and live).

Opening the configuration
In the DevOps portal, navigate to your portal and open the AI agent configuration panel. Any providers already configured are listed here. Click + Add configuration to add a new provider.
Adding a provider
Clicking + Add configuration opens a Choose a provider dialog with the currently available model providers. Each provider has its own set of required credentials, and each provider will have its own authentication options. There can be multiple providers configured at the same time, allowing you to use different agents from different providers in the same project.
Notes
The same provider configuration can be shared across multiple agents within the same portal.
Configuration must be set up per environment — a configuration added to staging is not automatically available on live.
This configuration is only accessible to users with DevOps portal access. If you need a provider configured, contact your portal administrator.
The model selection in the modeler chooses the credentials used, ensure developers are aware of the cost implications.
Below per provider the necessary information to setup in DevOps (or ask WEM Support to setup in DevOps in case your project runs in a Shared Runtime).
API Key only
Resource Name (ending in .openai.azure.com)
and
Authentication Mode API Key:
API Key
Authentication Mode Client Secret:
Tenant ID
Client ID
Client Secret
API Key only
Gemini Developer API
API Key
Vertex AI
Project
Location
Service Account Key
Organization ID
Project ID
API Key
Last updated
Was this helpful?