proxy

package
v1.13.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 11, 2026 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

Package proxy implements an OpenAI-compatible reverse proxy that intercepts LLM calls, vaults content, emits OTel spans, and writes AIR records.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handler

func Handler(cfg Config) http.Handler

Handler returns an http.Handler that proxies OpenAI-compatible requests.

Types

type Config

type Config struct {
	ProviderURL string                         // e.g. https://api.openai.com
	Vault       *vault.Client                  // S3 vault for content (nil = disabled)
	Recorder    *recorder.Writer               // AIR file writer (nil = disabled)
	GatewayKey  string                         // optional API key required to use the gateway
	Guardrails  *guardrails.Config             // guardrails configuration (nil = disabled)
	Sessions    *guardrails.Manager            // session state for guardrails (nil = disabled)
	Analytics   *guardrails.PerformanceTracker // optimization analytics (nil = disabled)
	AuditChain  *trust.AuditChain              // cryptographic audit chain (nil = disabled)
}

Config holds proxy configuration.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL