Skip to content

feat(proxy): Bob (BobShell) gateway — reduce model calls, pass control-plane through#12

Merged
OsherElhadad merged 3 commits into
mainfrom
feat/bob-gateway
Jul 21, 2026
Merged

feat(proxy): Bob (BobShell) gateway — reduce model calls, pass control-plane through#12
OsherElhadad merged 3 commits into
mainfrom
feat/bob-gateway

Conversation

@OsherElhadad

Copy link
Copy Markdown
Collaborator

What

Adds an opt-in Bob (BobShell) gateway to the proxy so IBM Bob's traffic can be routed through context-guru — the way the winnow prototype already does. Enabled only when BOB_UPSTREAM (or --bob-upstream) is set; default proxy behavior is unchanged.

Why

Bob is OpenAI-compatible via CUSTOM_BASE_URL, but it calls Bob-specific paths: the model call is POST /inference/v1/chat/completions, and it makes control-plane calls (GET /admin/v1/profile, /inference/v1/model/info, …) that must reach the backend unmodified or the CLI won't boot. The proxy previously exposed only /openai/v1/chat/completions and /anthropic/v1/messages, so Bob couldn't be pointed at it.

How it works

  • POST /inference/v1/chat/completions → reduced through the pipeline like any OpenAI chat, forwarded to the same path on BOB_UPSTREAM; Bob's own auth passes through (no key injection).
  • / catch-all → transparently proxies Bob's control-plane calls verbatim to BOB_UPSTREAM. Less specific than every existing route, and only registered when BOB_UPSTREAM is set.

Usage

BOB_UPSTREAM=https://api.us-east.bob.ibm.com context-guru-proxy --preset balanced

CUSTOM_BASE_URL=http://localhost:4000/v1 BOBSHELL_DEFAULT_AUTH_TYPE=custom \
BOBSHELL_API_KEY=<key> bob --yolo "your task"

Verified

  • New proxy test: model call on /inference/v1/chat/completions is reduced (dedup) and forwarded to the right path; a GET /admin/v1/profile control-plane call is passed through verbatim.
  • Live end-to-end against the Bob backend with deterministic components (format+toon): Bob authenticated and answered correctly through the proxy, with its model call reduced.

Notes

Osher-Elhadad added 3 commits July 21, 2026 14:45
Bob is OpenAI-compatible but calls Bob-specific paths. Add an opt-in gateway
(enabled by BOB_UPSTREAM / --bob-upstream):

- POST /inference/v1/chat/completions is reduced through the pipeline like any
  OpenAI chat and forwarded to the Bob backend, passing Bob's own auth through.
- A "/" catch-all transparently proxies Bob's control-plane calls
  (/admin/v1/profile, /inference/v1/model/info, …) verbatim so the CLI boots and
  authenticates. Less specific than every existing route, and only registered
  when BOB_UPSTREAM is set, so default behavior is unchanged.

Point Bob's CUSTOM_BASE_URL at this proxy. Verified end-to-end against the Bob
backend with deterministic components. Ports winnow's bob profile.

Assisted-By: Claude <noreply@anthropic.com>
Signed-off-by: Osher-Elhadad <Osher.Elhadad@ibm.com>
The kagenti->rossoctl rename string-replaced import paths without re-sorting, so
github.com/rossoctl/... now sorts after github.com/maximhq/...; gofmt re-orders
the import groups. Fixes `make lint` (gofmt check) on this branch.

Assisted-By: Claude <noreply@anthropic.com>
Signed-off-by: Osher-Elhadad <Osher.Elhadad@ibm.com>
Add an integrations section covering the opt-in Bob gateway: enable with
BOB_UPSTREAM, point Bob's CUSTOM_BASE_URL at the proxy, model calls reduced /
control-plane passed through. Notes the verified deterministic setup.

Assisted-By: Claude <noreply@anthropic.com>
Signed-off-by: Osher-Elhadad <Osher.Elhadad@ibm.com>
@OsherElhadad
OsherElhadad merged commit 544db53 into main Jul 21, 2026
4 checks passed
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