Add provider-level round-robin proxy pools for keyless providers, with per-key and per-account overrides

Aperta
#9,102 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
25/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
typescript
Ambito
api, backend

Direzione di ricerca

Start from the provider-level outbound proxy introduced in #5289 and the routing discussion in #5324, which the issue cites for context. The issue names no concrete source files, so first locate where a provider's proxy is chosen per request and how streams are held open. Done means a keyless provider with a three-proxy round-robin pool sends successive requests through P1, P2, P3, P1, and an in-flight stream keeps its original proxy.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

account-pool enhancement
Area

Proxy and routing / Dashboard

What are you trying to accomplish?

I would like to manage outbound proxies in a Proxy tab under each provider. A provider that accepts unauthenticated requests should be able to rotate through multiple proxies without registering an API key, an OAuth account, or a dummy credential.

What prevents this today?

#5289 introduced a provider-level outbound proxy. A single fixed proxy does not cover a pool of exits for one provider. #5324 discussed per-account routing and invited a smaller opt-in proposal.

What should OpenCodex do?
  • Let a provider select a fixed proxy or an ordered round-robin proxy pool.
  • For a keyless provider, choose the next proxy when a new request starts. Keep the chosen proxy for the lifetime of that request, including its stream. Concurrent requests should retain their own selection.
  • For providers that use credentials, let each API key or stored OAuth account inherit the provider default, select a fixed proxy, or select its own round-robin pool. Proxy rotation should work independently of credential rotation.
Example usage or interface

In Providers → Example → Proxy, add P1, P2, and P3 and select Round robin. With zero credentials configured, four successive requests should exit through P1, P2, P3, and P1. If the first request is still streaming when the second starts, the first stream stays on P1.

For an authenticated provider, Key A could inherit that pool while Key B stays pinned to P2.

Suggested first slice

Start with an opt-in provider-level pool and the four-request keyless example above. Per-key and per-OAuth-account overrides can build on that provider default.

Lingua principale
TypeScript
Stelle
16.9k
Fork
1.3k
Merge medio
1g 4h
PR unite (30g)
814

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di lidge-jun/opencodex

Tutte le issue di lidge-jun/opencodex

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.