Skip to main content

Framework Integration Overview

AxonFlow integrates with popular AI and ML frameworks to add governance, policy enforcement, and audit logging to your existing AI applications. Add compliance guardrails without rewriting your agent code.

Looking for:

  • Governance for LangChain / LangGraph / CrewAI
  • Audit trail for agent workflows
  • PII/PHI redaction before LLM calls
  • Policy enforcement for multi-agent systems
  • Cost controls and token budgets for agents
  • Human approval gates for agent actions
  • SQL injection prevention in AI pipelines

→ You're in the right place.

Supported Frameworks

LLM Orchestration Frameworks

FrameworkLanguageIntegration TypeDocumentation
LangChainPythonSDK + Raw HTTPMost comprehensive guide
LangChainGoGoGo SDKNative Go integration
LangGraphTypeScriptTypeScript SDKGraph-based workflows
LlamaIndex.TSTypeScriptTypeScript SDKNode.js/TypeScript apps
CrewAIPythonPython SDKMulti-agent crews
AutoGenPythonPython SDKMicrosoft multi-agent
DSPyPythonPython SDKProgrammatic LLM pipelines
LyzrPythonPython SDKEnterprise AI agents

AI Assistants & CLI Tools

ToolIntegration TypeUse CaseDocumentation
Claude CodeHTTP HooksCLI governanceAgentic coding assistant

Enterprise Platforms

PlatformIntegration TypeUse CaseDocumentation
Microsoft Copilot StudioHTTP APILow-code AI appsPower Platform integration
Semantic KernelJavaMicrosoft AI orchestrationJava enterprise apps
ObotTypeScript SDKMCP GatewayMCP-based agents

Integration Patterns

Gateway Mode

The recommended pattern for existing framework integrations (LangChain, CrewAI, LlamaIndex):

Your Framework → AxonFlow Pre-check → LLM Provider → AxonFlow Audit

Benefits:

  • Policy enforcement before LLM calls
  • Complete audit trail of all operations
  • Token usage and cost tracking
  • Works with any LLM provider

Proxy Mode

For simpler integrations:

Your Framework → AxonFlow Proxy → LLM Provider

Benefits:

  • Single API endpoint
  • Automatic policy enforcement
  • Simpler integration (one call)

SDK Coverage

SDKFrameworks Using It
Python SDKLangChain, CrewAI, AutoGen, DSPy, Lyzr
Go SDKLangChainGo
TypeScript SDKLangGraph, LlamaIndex.TS, Obot
Java SDKSemantic Kernel
Raw HTTPAll frameworks (Copilot Studio uses Power Automate HTTP)

Quick Start by Framework

Python Frameworks (LangChain, CrewAI, Lyzr)

from axonflow import AxonFlow

with AxonFlow.sync(
endpoint="http://localhost:8080",
client_id="your-client-id",
client_secret="your-client-secret"
) as client:
# Pre-check before LLM call
ctx = client.get_policy_approved_context(
user_token="user-123",
query="Your prompt here"
)

if ctx.approved:
# Make your framework's LLM call here
response = your_framework_llm_call(ctx.query)

# Audit the result
client.audit_llm_call(
context_id=ctx.context_id,
provider="openai",
model="gpt-4",
response_summary=response[:200]
)

Go Frameworks (LangChainGo, Obot)

import "github.com/getaxonflow/axonflow-sdk-go/v3"

client := axonflow.NewClient(axonflow.AxonFlowConfig{
Endpoint: "http://localhost:8080",
ClientID: "your-client-id",
ClientSecret: "your-client-secret",
})

// Pre-check (ExecuteQuery handles policy check)
result, _ := client.ExecuteQuery("user-123", "Your prompt here", "chat", nil)

if !result.Blocked {
// Your framework LLM call
response := yourFrameworkLLMCall(result.Query)

// Audit
client.AuditLLMCall(axonflow.AuditRequest{
ContextID: result.ContextID,
ResponseSummary: response[:200],
Provider: "openai",
Model: "gpt-4",
})
}

TypeScript Frameworks (LlamaIndex.TS)

import { AxonFlow } from '@axonflow/sdk';

const client = new AxonFlow({
endpoint: 'http://localhost:8080',
tenant: 'your-client-id',
});

// Pre-check
const ctx = await client.getPolicyApprovedContext({
userToken: 'user-123',
query: 'Your prompt here'
});

if (ctx.approved) {
// Your framework LLM call
const response = await yourFrameworkLLMCall(ctx.query);

// Audit
await client.auditLLMCall({
contextId: ctx.contextId,
responseSummary: response.slice(0, 200),
provider: 'openai',
model: 'gpt-4',
});
}

What AxonFlow Adds

CapabilityDescription
PII Detection12+ PII types automatically detected and optionally redacted
SQL Injection Scanning37+ attack patterns blocked in prompts and responses
Policy EnforcementCustom rules in Rego/OPA with single-digit ms evaluation
Audit LoggingComplete request/response logging with compliance retention
Cost TrackingToken usage and cost per request
Multi-Model RoutingRoute to different LLM providers based on policy

Community vs Enterprise

FeatureCommunityEnterprise
Framework integrationsAllAll
PII detection
SQL injection (basic)
SQL injection (advanced)
Audit logging
Policy enforcement
HITL approval queue
Compliance exports
Customer Portal

Choosing a Framework Guide

If you're using...Start with...
Python + multi-agent orchestrationCrewAI Guide or AutoGen Guide
Python + RAG/chainsLangChain Guide
Python + programmatic pipelinesDSPy Guide
Python + enterprise agentsLyzr Guide
Go backendLangChainGo Guide
TypeScript + graph workflowsLangGraph Guide
TypeScript + RAGLlamaIndex.TS Guide
TypeScript + MCPObot Guide
Java enterpriseSemantic Kernel Guide
Low-code/Power PlatformCopilot Studio Guide
Claude Code CLIClaude Code Guide

Need a Different Framework?

AxonFlow's SDK and HTTP APIs work with any framework. Use the LangChain guide as a reference - it includes both SDK and raw HTTP examples that can be adapted to any framework.

For framework-specific integration help: