CAIRA (Composable AI Reference Architecture) helps you fast-track an AI Foundry deployment. You can choose from four reference architectures, which you can deploy using Terraform with just a few commands.
The result is a fast, secure, and observable environment where you can develop and deploy agents, models, and workflows.
CAIRA’s is a Microsoft GitHub project to help enterprises deploy AI environments on Azure in a secure, scalable, and governed way. Microsoft aimed to provide a modular, repeatable approach to setting up AI environments.
Reference Architectures
CAIRA is really setup as a reference architecture methodology, where you can choose between different ways of implementing, depending on the need of your use case!
There are Basic and Standard architectures:
- Basic: Azure-managed data storage. You have no control over where the data is stored.
- Standard: Allows control over where Microsoft Foundry stores operational and stateful data for data sovereignty purposes.
Microsoft Foundry’s data consists of:
- Conversation history (threads & messages) stored in Cosmos DB
- File uploads stored in a Storage Account
- Vector stores in Azure AI Search
For each Basic and Standard architecture, you can choose a public or private variant. The private variant is ideal for network integrated solutions with endpoints to access Microsoft Foundry services.
Basic
Public Networking
- Project and deployment for getting started
- Public networking
- Microsoft-managed file storage
- Microsoft-managed resources for storing agent threads and messages
- Built-in observability via Log Analytics and Application Insights
Basic AI Foundry (Private Networking)
- Basic configuration with network isolation
- Project and deployment for getting started
- Bring-your-own private networking
- Microsoft-managed file storage
- Microsoft-managed resources for storing Agent threads and messages
- Built-in observability via Log Analytics and Application Insights
Standard
Public Networking
- Enterprise features with Bring Your Own Resource (BYOR) approach
- Project and default model deployments
- Explicit agent capability host connections to Azure Cosmos DB, Azure AI Search, and Azure Storage
- Built-in observability via Log Analytics and Application Insights
Private Networking
- Enterprise features with Bring Your Own Resource (BYOR) and network isolation
- Project and default model deployments
- Explicit agent capability host connections to Azure Cosmos DB, Azure AI Search, and Azure Storage
- Bring-your-own network for capability hosts and agents to be connected to.
- Built-in observability via Log Analytics and Application Insights
More information here: https://github.com/microsoft/CAIRA/blob/main/reference_architectures/README.md
Deployment Example
1. Clone the repository:
cd reference_architectures/foundry_basic
2. Login to your Azure subscription
3. Set your active subscription
4. Export the subscription ID as an environment variable to make it available to the AzureRM and AzAPI Terraform providers
5. Initialize Terraform:
6. Review the plan:
7. Deploy the infrastructure:
Terraform
CAIRA is relying on Terraform for it’s Infra-as-code. There are currently (as of writing this blog) no concrete plans to also make this available via bicep. But anyhow, it really makes it suitable for production setup. You can fine-tune the Terraform scripts to fit your needs.
Codit is open to Terraform and Bicep. Most of our customers currently rely on bicep for various reasons, so it quite odd that Microsoft doesn’t use it’s own stack directly & it also might be odd to switch between bicep & terraform in your pipelines. But in short, what are the high level advantages of Terraform:
Multi-cloud support: Terraform is cloud-agnostic and supports Azure, AWS, and GCP: ideal for hybrid or multi-cloud strategies.
State Management: Maintains a state file to track deployed resources and their attributes. This allows for Drift Detection, identify changes made outside Terraform and allows for plan previews to see exactly what will change before applying. (Bicep is trying to get to same level with this with Deployment Stacks!)
Support for Workspaces: Manage multiple environments (dev, test, prod).
Vendor-Neutral approach: Reduces lock-in to a single cloud provider. Useful for organizations that want portability and consistency across platforms.
Usage Scenarios
CAIRA can be used to set up your production environment or quickly spin up a secure, observable AI environment for developers. It also enables ephemeral environments for testing.
Conclusion
Ready to build? By utilizing one of the provided reference architectures, you have everything you need to spin up your AI Foundry quickly and correctly.
Subscribe to our RSS feed
Talk to the author
Contact Alex
Azure Architect