Explore Ratel integration examples
mainRatel provides several runnable demos that show how to wire Ratel into real agent frameworks and protocol surfaces. These examples are organized as private workspace packages and cover various integration patterns including adaptive ranking, Vercel AI SDK, Mastra, Pydantic AI, and OpenTelemetry.
Available Integration Patterns
Adaptive Ranking
- TypeScript:
adaptive-ranking-ts— Learn from invocations and persist/reload the graph. - Python:
adaptive-ranking-python— The Python mirror of the TS version, including model-swap recovery. - Configurable (TS):
configurable-adaptive-ranking-ts— Seed an intent graph from a baseline capture, then switch ranking on. - Configurable (Python):
configurable-adaptive-ranking-python— The Python mirror for seeding.
Agent Framework Integrations
- Vercel AI SDK:
ai-sdk— Demonstrates top-K filtering and capability tools withinToolLoopAgent.generate. - Mastra:
mastra— Demonstrates capability tools and per-turn recall processors via@ratel-ai/mastra. - Pydantic AI (Python):
pydantic-ai— Demonstrates top-K filtering and capability tools in the agent loop. - MCP Chat:
mcp-chat— An interactive REPL against an MCP-backed agent using Vercel AI SDK and OpenAI.
Telemetry
- TypeScript:
telemetry-ts— Emitsratel.*spans via the OpenTelemetry JS SDK. - Python:
telemetry-python— Emitsratel.*spans via the OpenTelemetry Python SDK.