From bf36fa76529d729034421466bd067d30e502f96d Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Fri, 23 Jan 2026 19:16:47 +0000 Subject: [PATCH] docs: add extra operations to mermaid diagram Co-authored-by: ishaan --- .../docs/pass_through/architecture.md | 23 +++++++++++++------ 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/docs/my-website/docs/pass_through/architecture.md b/docs/my-website/docs/pass_through/architecture.md index 840f2d3e766..16e8377a3f9 100644 --- a/docs/my-website/docs/pass_through/architecture.md +++ b/docs/my-website/docs/pass_through/architecture.md @@ -16,23 +16,33 @@ sequenceDiagram rect rgb(240, 240, 240) Note over Proxy: 1. URL Construction - Note over Proxy: Build: https://us-central1-aiplatform.googleapis.com/... + Note over Proxy: Build regional/provider-specific URL end rect rgb(240, 240, 240) Note over Proxy: 2. Auth Header Replacement - Note over Proxy: Replace litellm key → provider credentials + Note over Proxy: LiteLLM key → provider credentials + end + + rect rgb(240, 240, 240) + Note over Proxy: 3. Extra Operations + Note over Proxy: • x-pass-* headers (strip prefix, forward) + Note over Proxy: • x-litellm-tags → metadata + Note over Proxy: • Guardrails (opt-in) + Note over Proxy: • Multipart form reconstruction end Proxy->>Provider: POST https://us-central1-aiplatform.googleapis.com/... Note over Proxy,Provider: Headers: Authorization: Bearer ya29.google-oauth... Note over Proxy,Provider: Body: { "contents": [...] } ← UNCHANGED - Provider-->>Proxy: Response - + Provider-->>Proxy: Response (streaming or non-streaming) + rect rgb(240, 240, 240) - Note over Proxy: 3. Logging (async, optional) - Note over Proxy: Parse response → calculate cost → log + Note over Proxy: 4. Response Handling (async) + Note over Proxy: • Collect streaming chunks for logging + Note over Proxy: • Cost injection (if enabled) + Note over Proxy: • Parse response → calculate cost → log end Proxy-->>Client: Response (unchanged) @@ -42,7 +52,6 @@ sequenceDiagram - **URL Construction** - Build correct provider URL (e.g., regional endpoints for Vertex AI, Bedrock) - **Auth Header Replacement** - Swap LiteLLM virtual key for actual provider credentials -- **Logging** (optional) - Parse response to extract usage and calculate cost ## Extra Operations