Skip to content

Migrate custom LLM to LLM Gateway Passthrough API#38

Open
Sarath1018 wants to merge 2 commits intofeature/darwinfrom
sarath/change-prompt
Open

Migrate custom LLM to LLM Gateway Passthrough API#38
Sarath1018 wants to merge 2 commits intofeature/darwinfrom
sarath/change-prompt

Conversation

@Sarath1018
Copy link
Copy Markdown
Collaborator

Summary

  • Migrated custom_llm.py to use the LLM Gateway Passthrough API (/{accountId}/{tenantId}/llmgateway_/api/raw/vendor/openai/model/gpt-4o-2024-11-20/completions)
  • Added GEN_AI_ACCOUNT_ID and GEN_AI_TENANT_ID env vars to model_configs.py and docker-compose files
  • Account and tenant IDs are now embedded in the URL path (header-based routing via X-UiPath-Internal-AccountId/X-UiPath-Internal-TenantId does not work — gateway ignores those headers for routing)
  • Updated request headers to match working passthrough API spec: ApiFlavor: chat-completions, ApiVersion: 2024-10-21, X-UIPATH-STREAMING-ENABLED: false

Test plan

  • Set GEN_AI_ACCOUNT_ID, GEN_AI_TENANT_ID, GEN_AI_CLIENT_ID, GEN_AI_CLIENT_SECRET in .env
  • Start services and verify LLM calls succeed via the passthrough endpoint
  • Verify 200 response with chat completion from gpt-4o-2024-11-20

🤖 Generated with Claude Code

… tenant routing

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Sarath1018 Sarath1018 force-pushed the sarath/change-prompt branch from d2fd12b to 8b07b87 Compare April 30, 2026 14:17
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant