The Alation AI Agent SDK enables AI agents to access and leverage metadata from the Alation Data Catalog.
This SDK empowers AI agents to:
- Retrieve contextual information from Alation's Data Catalog
- Use natural language to search for relevant metadata
- Customize response formats using flexible signature specifications
- Integrate seamlessly with AI frameworks like LangChain and MCP
The project is organized into multiple components:
- Core SDK - Foundation with API client and context tools
- LangChain Integration - Adapters for the LangChain framework
- MCP Integration - Server implementation for Model Context Protocol
The core SDK provides the foundation for interacting with the Alation API. It handles authentication, request formatting, and response parsing.
This component integrates the SDK with the LangChain framework, enabling the creation of sophisticated AI agents that can reason about your data catalog.
Learn more about the LangChain Integration
The MCP integration provides an MCP-compatible server that exposes Alation's context capabilities to any MCP client.
Learn more about the MCP Integration
- Python 3.10 or higher
- Access to an Alation Data Catalog instance
- A valid refresh token or client_id and secret. For more details, refer to the Authentication Guide.
# Install core SDK
pip install alation-ai-agent-sdk
# Install LangChain integration
pip install alation-ai-agent-langchain
# Install MCP integration
pip install alation-ai-agent-mcp
The library needs to be configured with your Alation instance credentials:
from alation_ai_agent_sdk import AlationAIAgentSDK
alation_ai_sdk = AlationAIAgentSDK(
base_url="https://your-alation-instance.com",
user_id=12345, # Your numeric user ID
refresh_token="your_refresh_token"
)
A retrieval tool that pulls contextual information from the Alation catalog based on natural language queries.
Functionality
- Accepts user questions in natural language
- Performs query rewrites to optimize search results
- Returns relevant catalog data in JSON format
- Can return multiple object types in a single response
Usage
response = alation_ai_sdk.get_context(
"What certified data set is used to make decisions on providing credit for customers?"
)
Input Parameters
question
(string): The natural language querysignature
(optional dict): The configuration controlling which objects and their fields
Returns
- JSON-formatted response of relevant catalog objects
The SDK's alation-context
tool supports customizing response content using signatures. This powerful feature allows you to specify which fields to include and how to filter the catalog results. For instance:
# Define a signature for searching only tables that optionally
# include joins and filters if relevant to the user question
signature = {
"table": {
"fields_required": ["name", "title", "description"],
"fields_optional": ["common_joins", "common_filters"]
}
}
# Use the signature with your query
response = sdk.get_context(
"What are our sales tables?",
signature
)
For more information about signatures, refer to Using Signatures.
- Planning an Integration - Practical considerations for getting the most out of your agents and the Alation Data Catalog.
- Using Signatures - How to customize your agent with concrete examples.
- Supported Object Types and Fields - See what's available.
Direct usage examples for the Alation AI Agent SDK:
- Basic Usage Example - Simple example showing SDK initialization and context queries.
- QA Chatbot Example - Interactive chatbot demonstrating conversation context and signature usage.
Enable agentic experiences with the Alation Data Catalog.
- MCP Integration - Getting the Alation MCP server up and running.
- Testing with MCP Inspector - Steps for debugging and verification.
- Claude Desktop Integration - Leverage the Alation MCP server within Claude Desktop.
- LibreChat Integration - Create assistants and agents alike.
Harness the SDK to build complex agents and workflows.
- LangChain Integration - How to integrate the SDK into your LangChain agents.
- Basic Usage Example - A simple example.
- Multi Agent Example - A multi agent workflow with several SDK integration points.
The number of published agent frameworks and toolkits appears to be increasing every day. If you don't happen to see the framework or toolkit you're using here, it's still possible to adapt alation-ai-agent-sdk
to your needs. It may be as simple as writing a wrapping function where a decorator is applied.
While we want to reach as many developers as possible and make it as convenient as possible, we anticipate a long tail distribution of toolkits and won't be able to write adapters for every case. If you'd like support for a specific toolkit, please create an issue to discuss.