Custom agents

  • Tier: Premium, Ultimate
  • Add-on: GitLab Duo Core, Pro, or Enterprise
  • Offering: GitLab.com, GitLab Self-Managed
  • Status: Experiment

The availability of this feature is controlled by a feature flag. For more information, see the history.

Agents use AI to perform tasks and answer complex questions. Create custom agents to accomplish specific tasks, like creating merge requests or reviewing code. Or, use the AI Catalog to discover agents created by GitLab.

When you’re ready to interact with an agent, you can enable it to start using it with GitLab Duo Chat.

Agent visibility

When you create a custom agent, you select a project to manage it and choose whether the agent is public or private.

Public agents:

  • Can be viewed by anyone and can be enabled in any project that meets the prerequisites.

Private agents:

  • Can be viewed only by members of the managing project who have at least the Developer role.
  • Cannot be enabled in projects other than the managing project.

You cannot make a private agent public if the agent is currently enabled.

View the agents for your project

Prerequisites:

  • You must have at least the Developer role for the project.

To view a list of agents associated with your project:

  1. On the top bar, select Search or go to and find your project.
  2. Select Automate > Agents.
    • To view agents enabled in the project, select the Enabled tab.
    • To view agents managed by the project, select the Managed tab.

Select an agent to view its details.

Create an agent

You can create an agent from a project, or by using the AI Catalog.

Prerequisites:

  • You must have at least the Maintainer role for the project.

To create an agent:

  1. On the top bar, select Search or go to and find your project.

  2. Select Automate > Agents.

  3. Select New agent.

  4. Under Basic information:

    1. In Display name, enter a name for the agent.
    2. In Description, enter a description for the agent.
  5. Under Visibility & access, for Visibility, select Private or Public.

  6. Under Prompts, in System prompt, enter a prompt to define the agent’s personality, expertise, and behavior.

  7. Optional. Under Available tools, from the Tools dropdown list, select which tools the agent can access. For example, for the agent to create issues automatically, select Create issue.

    For a list of available tools, see the built-in tool definitions.

  8. Select Create agent.

To create an agent:

  1. On the top bar, select Search or go to > Explore.

  2. Select AI Catalog, then select the Agents tab.

  3. Select New agent.

  4. Under Basic information:

    1. In Display name, enter a name for the agent.
    2. In Description, enter a description for the agent.
  5. Under Visibility & access:

    1. From the Managed by dropdown list, select a project for the agent.
    2. For Visibility, select Private or Public.
  6. Under Prompts, in System prompt, enter a prompt to define the agent’s personality, expertise, and behavior.

  7. Optional. Under Available tools, from the Tools dropdown list, select which tools the agent can access. For example, for the agent to create issues automatically, select Create issue.

    For a list of available tools, see the built-in tool definitions.

  8. Select Create agent.

The agent appears in the AI Catalog. To use the agent with Chat, enable it in a project.

Enable an agent

Enable an agent in a project to use it with Chat.

Prerequisites:

  • You must have at least the Maintainer role for the project.
  1. On the top bar, select Search or go to > Explore.
  2. Select AI Catalog, then select the Agents tab.
  3. Select the agent you want to enable.
  4. In the upper-right corner, select Enable in project.
  5. From the Project dropdown list, select your project.
  6. Select Enable.

The agent appears on the project’s Automate > Agents page. In the project, you can start a new chat with the agent. For more information, see select an agent.

Disable an agent for a project

Prerequisites:

  • You must have at least the Maintainer role for the project.

To disable an agent:

  1. On the top bar, select Search or go to and find your project.
  2. Select Automate > Agents.
  3. Find the agent you want to disable and select Actions ( ellipsis_v ) > Disable.
  4. On the confirmation dialog, select Disable.

The agent no longer appears in the project, and is not available in Chat.

Duplicate an agent

To make changes to an agent without overwriting the original, create a copy of an existing agent.

Prerequisites:

  • You must have at least the Maintainer role for the project.

To duplicate an agent:

  1. On the top bar, select Search or go to > Explore.
  2. Select AI Catalog, then select the Agents tab.
  3. Select the agent you want to duplicate.
  4. In the upper-right corner, select Actions ( ellipsis_v ) > Duplicate.
  5. Optional. Edit any fields you want to change.
  6. Select Create agent.

Manage agents

Edit an agent to change its configuration, or delete it to remove it from the AI Catalog.

Prerequisites:

  • You must be a member of the managing project and have at least the Maintainer role.

To manage an agent:

  1. On the top bar, select Search or go to > Explore.
  2. Select AI Catalog, then select the Agents tab.
  3. Select the agent you want to manage.
    • To edit an agent:
      1. In the upper-right corner, select Edit.
      2. Edit any fields you want to change, then select Save changes.
    • To delete an agent:
      1. In the upper-right corner, select Actions ( ellipsis_v ) > Delete.
      2. On the confirmation dialog, select Delete.

Report an agent

You can report an agent if it contains potentially offensive material or poses a risk to your organization.

To report an agent:

  1. On the top bar, select Search or go to > Explore.
  2. Select AI Catalog, then select the Agents tab.
  3. Select the agent you want to report.
  4. In the upper-right corner, select Actions ( ellipsis_v ) > Report to admin.
  5. Complete the abuse report, then select Submit.

An administrator is notified and can choose to hide or delete the agent.