From d9d037b9d070d0ecd20d67edfc5ea19169757c2d Mon Sep 17 00:00:00 2001 From: VC Date: Sat, 30 May 2026 10:47:52 -0400 Subject: [PATCH] Document Tuning Engines provider config --- README.md | 8 ++++++++ docs/providers.md | 21 +++++++++++++++++++++ 2 files changed, 29 insertions(+) diff --git a/README.md b/README.md index 78bafbc9..74e2a0bd 100644 --- a/README.md +++ b/README.md @@ -123,10 +123,18 @@ development: service: "Ollama" model: "llama3.2" + tuning_engines: + service: "OpenAI" + access_token: <%= Rails.application.credentials.dig(:tuning_engines, :api_key) %> + base_url: "https://api.tuningengines.com/v1" + model: "gpt-4o-mini" + ruby_llm: service: "RubyLLM" ``` +`tuning_engines` is an OpenAI-compatible gateway configuration for Rails teams that want centralized model routing, policy controls, audit logs, traces, approvals, and cost visibility without changing ActiveAgent code. + ## Features - **Agent-Oriented Programming**: Build AI applications using familiar Rails patterns diff --git a/docs/providers.md b/docs/providers.md index add6f66a..db19300d 100644 --- a/docs/providers.md +++ b/docs/providers.md @@ -54,6 +54,27 @@ GPT-4o, GPT-4.1, GPT-5, and o3 models. Two APIs available: Responses API (defaul **Choose when:** You need reliable, high-quality responses with strong reasoning. Vision support and structured output work well. Azure OpenAI compatible. +#### OpenAI-compatible gateways + +The OpenAI provider also accepts a custom `base_url`, so Rails apps can route ActiveAgent generations through a governed OpenAI-compatible endpoint. For example, [Tuning Engines](https://www.tuningengines.com/) can sit underneath ActiveAgent to centralize model routing, policy controls, audit logs, traces, approvals, and cost visibility: + +```yaml +production: + tuning_engines: + service: "OpenAI" + access_token: <%= Rails.application.credentials.dig(:tuning_engines, :api_key) %> + base_url: "https://api.tuningengines.com/v1" + model: "gpt-4o-mini" +``` + +Then use it like any other generation provider: + +```ruby +class SupportAgent < ApplicationAgent + generate_with :tuning_engines, model: "gpt-4o-mini" +end +``` + ### [OpenRouter](/providers/open_router) **Best for:** Multi-model flexibility, cost optimization, experimentation