Discover Agents
Agent Discovery
The Agent Discovery endpoint enables the identification of available agents and their capabilities within the Agent Connect Framework (ACF), eliminating the need for hardcoded knowledge of their existence.
Overview
The GET /v1/agents
endpoint provides a detailed list of agents, including their metadata and capabilities, allowing clients to:
- Identify available agents within the ecosystem.
- Understand each agent’s capabilities and areas of expertise.
- Determine interaction protocols for each agent.
- Make informed decisions regarding agent selection for specific tasks.
Agent Cards
Each agent is represented by an “Agent Card” containing essential information:
Key Fields
name
: Unique identifier for the agent.description
: Human-readable description of the agent’s functionality.provider
: Information about the organization providing the agent.version
: Agent version.documentation_url
: URL to the agent’s documentation.capabilities
: List of supported capabilities.streaming
: Indicates if the agent supports streaming responses.
Implementation
To implement the Agent Discovery endpoint, create a GET /v1/agents
endpoint that returns a list of agent cards:
Planning for the implementation
Consider the following concepts and guidance when implementing the Agent Discovery endpoint:
-
Accurate Descriptions: Provide clear and precise descriptions of your agent’s capabilities to help clients understand its functionality and appropriate use cases.
-
Version Information: Include version information to inform clients about the specific version of your agent they are interacting with, especially when breaking changes occur.
-
Documentation Links: Include links to comprehensive documentation detailing your agent’s capabilities and usage instructions.
-
Capability Flags: Use capability flags to indicate supported features, aiding clients in determining the suitability of your agent for their needs.
-
Metadata: Include relevant metadata to provide insights into your agent’s specialties, limitations, and other critical characteristics.
Using Agent Discovery
Clients can use the Agent Discovery endpoint to find and interact with agents:
Integration with watsonx Orchestrate
When you register your agent with watsonx Orchestrate, it automatically discovers your agent’s capabilities through this endpoint. This enables watsonx Orchestrate to:
- Display your agent in the agent catalog
- Show accurate information about your agent’s capabilities
- Enable appropriate interaction patterns based on your agent’s supported features
- Facilitate collaboration between your agent and other agents in the ecosystem
Example Response
Here’s an example response from the Agent Discovery endpoint:
Next Steps
After implementing the Agent Discovery endpoint, you should:
- Implement the Chat Completion endpoint to enable agent-to-agent communication
- Consider how your agent will interact with the AI Gateway
- Test your agent’s discovery and interaction capabilities with watsonx Orchestrate
Response
Successful Response