[feature] Add Bifrost gateway support

オープン
#1,405 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
48/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
c, go, rust

調査の方向性

Start with Bifrost’s plugin documentation, then compare examples/litellm and crates/switchyard-nemo-relay-plugin for the integration pattern. Trace the gateway plugin configuration, Go bindings, C ABI, and response-translation export points described in the issue. Done means an experimental Bifrost plugin accepts routes, routes standard Chat Completions requests through Switchyard, and returns x-switchyard-selected-model, with matching host and plugin builds validated.

索引モデルが issue の本文から書いたものです。

説明

enhancement

Problem

Bifrost users lack a native way to use Switchyard routing. Deployments needing it must otherwise run a separate routing service or maintain a custom adapter. This applies to each request managed by a Switchyard route.

Proposed solution

Add an experimental native Bifrost plugin configured through its existing plugins list. A routes configuration maps public model names to Switchyard algorithms and Bifrost target models. Clients continue sending standard Chat Completions requests. Switchyard selects the target; Bifrost handles credentials, inference, retries, and accounting. The x-switchyard-selected-model response header reports the routing target.

Alternatives considered

A standalone Switchyard proxy adds another service and HTTP hop. A Python implementation would require a separate service or an embedded interpreter because Bifrost loads native Go plugins. Reimplementing algorithms in Go would duplicate routing logic. The proposed adapter instead reuses Switchyard’s Rust implementation through its shared Go bindings.

Scope notes

The change belongs to the gateway integration surface, with supporting Go binding, C ABI, and response-translation exports. It adds Bifrost plugin configuration without changing routing algorithms or existing public Rust, PyO3, Python, CLI, or deployment-TOML interfaces. Existing integrations retain their behavior. The integration is experimental and checkout-only; host and plugin builds must match. Prefill is excluded, HTTP hooks do not cover Bifrost Go SDK calls, and routing-produced answers are buffered.

Additional context

Related integration patterns are examples/litellm and crates/switchyard-nemo-relay-plugin. See [Bifrost’s plugin architecture](https://github.com/maximhq/bifrost/blob/HEAD/docs/plugins/getting-started.mdx). Validation covered macOS arm64 and a Linux amd64, including live JSON and streaming requests.

Codex authored

主要言語
Rust
スター
3.7k
フォーク
386
平均マージ
1日 16時間
マージ済み PR(30日)
113

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

NVIDIA-NeMo/Switchyard のほかの issue

NVIDIA-NeMo/Switchyard の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。