NVIDIA / NVIDIA/nvcf

Support per-target shadow policies in vanity gateway

Open
#1,243 0 comments 0 reactions 1 assignee View on GitHub

@along-2017 is already working on this.

Since Sep 8, 2026.

Dominant language
Go
Stars
218
Forks
72
Avg merge
1d 12h
Merged PRs (30d)
427

Description

Is this related to a problem? Please describe.

The vanity gateway can send a primary request to multiple shadow models, but every target currently shares one percentage, sampling method, and cancellation policy. Operators cannot independently control traffic volume or request lifetime for each shadow target.

Describe the solution you'd like

Add an additive shadows list to each OpenAI model route. Each entry should define its target model and may set its own percentage, sampling method, and cancellation policy.

Keep the existing shadowModelName, shadowModelNames, shadowPercentage, shadowSamplingMethod, and shadowCancelOnClientDisconnect fields working with their current shared-policy behavior. Reject configurations that mix the new and legacy forms on one route so precedence remains unambiguous.

Describe alternatives you've considered

Changing shadowModelNames from a string list to an object list would break existing configuration types. Adding parallel policy arrays would also be difficult to validate and could associate policies with the wrong target.

Additional context

Example:

shadows:
  - modelName: private/example/shadow-a
    percentage: 10
    samplingMethod: perBearerKey
    cancelOnClientDisconnect: true
  - modelName: private/example/shadow-b
    percentage: 50
    samplingMethod: random

Shadow targets must continue to reference another model in the same OpenAI endpoint section. Multipart image edit and variation routes remain unsupported for effective shadow configuration.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.