Skip to content
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
Show all changes
97 commits
Select commit Hold shift + click to select a range
27afbce
feat(routing): add operator-managed model groups
seonghobae Aug 25, 2026
8118d1a
fix(api): enforce model group create semantics
seonghobae Aug 25, 2026
b1eb222
fix(routing): preserve eligibility and REST contracts
seonghobae Aug 25, 2026
6b069a0
docs(groups): remove ephemeral model example
seonghobae Aug 25, 2026
3b17ff0
fix(groups): route advertised aliases end to end
seonghobae Aug 25, 2026
f448175
ci: hourly OpenCode maintenance agent routed through this gateway (#835)
seonghobae Aug 25, 2026
b0ffb33
fix(groups): preserve internal dispatch default
seonghobae Aug 25, 2026
b1fdec6
fix: isolate model group routing evidence
seonghobae Aug 25, 2026
b498c43
fix: preserve conduct semantics for model groups
seonghobae Aug 25, 2026
356efc4
ci: minimize hourly loop permissions and installs
seonghobae Aug 25, 2026
e5b5095
fix: measure streamed group routing
seonghobae Aug 25, 2026
b353e6a
feat: route model groups across modalities (#837)
seonghobae Aug 25, 2026
fae8665
feat: normalize and edit model groups (#838)
seonghobae Aug 25, 2026
852fc1e
fix: preserve capability routing contracts
seonghobae Aug 25, 2026
19ab869
Merge pull request #839 from ContextualWisdomLab/fix/capability-routi…
seonghobae Aug 25, 2026
7c6f564
release: v0.2.0 — model groups, cost-aware discovery, changelog baseline
seonghobae Aug 25, 2026
c4896ae
fix(discovery): tolerate null modality arrays
seonghobae Aug 25, 2026
4bf5cf0
Merge pull request #841 from ContextualWisdomLab/fix/discovery-null-m…
seonghobae Aug 25, 2026
49d0940
docs: specify model group product and technical contracts
seonghobae Aug 25, 2026
4e0cbca
Merge pull request #842 from ContextualWisdomLab/docs/model-group-pro…
seonghobae Aug 25, 2026
0e6507e
Merge remote-tracking branch 'origin/feat/model-group-cost-aware-disc…
seonghobae Aug 25, 2026
fd6dde7
release: align v0.2.0 changelog and lock metadata
seonghobae Aug 25, 2026
6f49413
Merge pull request #840 from ContextualWisdomLab/release/v0.2.0-model…
seonghobae Aug 25, 2026
bc89d61
Merge remote-tracking branch 'origin/main' into stack-834
seonghobae Aug 25, 2026
43717d3
feat: stream orchestrated reasoning summaries
seonghobae Aug 25, 2026
5970a4d
Merge remote-tracking branch 'origin/feat/model-group-cost-aware-disc…
seonghobae Aug 25, 2026
5cde1ae
fix: keep free reasoning streams fail closed
seonghobae Aug 25, 2026
99ee64d
Merge remote-tracking branch 'origin/main' into feat/model-group-cost…
seonghobae Aug 25, 2026
8df2bfb
fix: preserve free routing evidence and analytics
seonghobae Aug 25, 2026
4f1e597
fix: distinguish failed Responses streams in analytics
seonghobae Aug 25, 2026
2cc49b0
fix: pin structured free judge to selected agent
seonghobae Aug 25, 2026
1fd7493
Merge branch 'feat/model-group-cost-aware-discovery' of https://githu…
seonghobae Aug 25, 2026
34f77ec
Merge remote-tracking branch 'origin/main' into stack834b
seonghobae Aug 25, 2026
ee8ff16
fix: lock container dependencies and virtual capabilities
seonghobae Aug 25, 2026
a0d5552
fix: keep free passthrough on zero-cost models
seonghobae Aug 25, 2026
8208f39
fix: prune removed routing measurements
seonghobae Aug 25, 2026
c262b8d
refactor: remove unreachable responses passthrough branch
seonghobae Aug 25, 2026
e38e959
fix: route virtual models across media capabilities
seonghobae Aug 25, 2026
18b5890
Merge remote-tracking branch 'origin/feat/model-group-cost-aware-disc…
seonghobae Aug 25, 2026
fd5fa8c
fix: retain reset candidate routing rows
seonghobae Aug 25, 2026
fefd6e0
fix: preserve Responses instructions in workflows
seonghobae Aug 25, 2026
f828a73
Merge remote-tracking branch 'origin/main' into feat/model-group-cost…
seonghobae Aug 25, 2026
21d47d1
test: align model-group missing-member code with canonical agent_not_…
seonghobae Aug 25, 2026
3d774fe
fix(api): model-group creation returns canonical agent_not_found for …
seonghobae Aug 25, 2026
1bc81de
ci: route hourly OpenCode loop through auto
seonghobae Aug 25, 2026
3a7f4a6
Merge branch 'feat/model-group-cost-aware-discovery' of https://githu…
seonghobae Aug 25, 2026
4f2daf0
fix: reject unsupported orchestrated structured output
seonghobae Aug 25, 2026
bccee78
docs: correct Responses stream options error
seonghobae Aug 25, 2026
63436f4
Merge remote-tracking branch 'origin/feat/model-group-cost-aware-disc…
seonghobae Aug 25, 2026
7181d3e
fix: retrieve URL-encoded model identifiers
seonghobae Aug 25, 2026
9a084d0
fix: measure free capability and failover routing
seonghobae Aug 25, 2026
3b0feb6
Merge pull request #843 from ContextualWisdomLab/feat/free-reasoning-…
seonghobae Aug 25, 2026
453c4de
Merge remote-tracking branch 'origin/main' into codex/pr834-review-fixes
seonghobae Aug 25, 2026
29915ef
fix: resolve model group review findings
seonghobae Aug 25, 2026
d4d1575
fix: close model group integration gaps
seonghobae Aug 25, 2026
40e00f8
fix: align provider inventory and session cache scope
seonghobae Aug 25, 2026
69cc674
fix: harden compose secrets and repeated reasoning summaries
seonghobae Aug 25, 2026
e2f4264
Merge remote-tracking branch 'origin/main' into codex/pr834-review-fixes
seonghobae Aug 25, 2026
5492f80
fix: contain binary response disconnects
seonghobae Aug 25, 2026
ce83f95
fix: ground Zen free discovery in structured costs
seonghobae Aug 25, 2026
bfc95d7
fix: keep group judge within allowed members
seonghobae Aug 25, 2026
4b1f2a8
fix: preserve free catalog evidence across reloads
seonghobae Aug 25, 2026
1b0d2dd
Merge remote-tracking branch 'origin/main' into codex/pr834-review-fixes
seonghobae Aug 25, 2026
f1fea50
docs: assign unique model-group ADR number
seonghobae Aug 25, 2026
098de8a
fix: preserve catalog capability evidence
seonghobae Aug 25, 2026
f9dc08b
fix: preserve declared Bytez endpoint capabilities
seonghobae Aug 25, 2026
8d27aa6
fix: validate batch model identity at ingress
seonghobae Aug 25, 2026
a11c541
fix(api): normalize missing model group errors
seonghobae Aug 25, 2026
9c02b19
docs(prd): align product bets with model groups
seonghobae Aug 25, 2026
a4269d9
fix(discovery): filter chat-only Bytez transports
seonghobae Aug 25, 2026
cb950a2
docs(adr): reserve model-group decision identifier
seonghobae Aug 25, 2026
8341ac6
Merge remote-tracking branch 'origin/main' into codex/pr834-review-fixes
seonghobae Aug 25, 2026
93b8016
feat: replace routing heuristics with measured evidence ledgers (#847)
seonghobae Aug 25, 2026
8b03206
fix(admin): tolerate unavailable model-group state
seonghobae Aug 25, 2026
c146d1e
docs(loop): require PRD and measured web capacity
seonghobae Aug 25, 2026
550c988
fix(admin): remove retired policy hint metric
seonghobae Aug 25, 2026
5ecdd3f
fix(routing): validate evidence before mutation
seonghobae Aug 25, 2026
7fa07ac
fix(discovery): remove model-name free inference guidance
seonghobae Aug 25, 2026
503365f
Merge remote-tracking branch 'origin/main' into pr834-work
seonghobae Aug 25, 2026
773caae
fix: complete #834 model-group persistence on the normalized agent-po…
seonghobae Aug 25, 2026
b03cd82
test: case-sensitive DDL pattern so prose cannot fake identifiers
seonghobae Aug 25, 2026
6201564
Merge remote-tracking branch 'origin/main' into codex/pr834-exact
seonghobae Aug 25, 2026
73f9a4f
docs: refresh protected-main gap evidence
seonghobae Aug 25, 2026
cef3498
docs: record exact provider regression suite
seonghobae Aug 26, 2026
daab699
docs: correct exact provider head
seonghobae Aug 26, 2026
a488687
fix(admin): make guidance customer-actionable
seonghobae Aug 26, 2026
a5f8d84
fix(admin): remove internal terms from customer copy
seonghobae Aug 26, 2026
6b6352e
docs(ui): record customer-copy screenshot audit
seonghobae Aug 26, 2026
ed0698d
test(ci): lock hourly orchestrator loop contract
seonghobae Aug 26, 2026
7896ac2
fix: replace synthetic admin status with truthful empty states
seonghobae Aug 26, 2026
d095eb4
docs: refresh exact-head remediation baseline
seonghobae Aug 26, 2026
e563920
fix(stream): cancel orchestration after Responses disconnect
seonghobae Aug 26, 2026
3bc37b4
test: align boundary contracts with current routing
seonghobae Aug 26, 2026
b189e10
docs: complete public boundary docstrings
seonghobae Aug 26, 2026
822a071
docs: refresh exact-head product gap queue
seonghobae Aug 26, 2026
7526fdb
test: enforce complete public docstrings
seonghobae Aug 26, 2026
ab3aab2
ci: enforce protected exact-head merge loop
seonghobae Aug 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions .github/opencode/hourly-loop-prompt.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
You are the hourly maintenance agent for ContextualWisdomLab/contextual-orchestrator,
running through the contextual-orchestrator gateway itself. Provider models and
operator-managed groups are discovered from the gateway; never infer that two
differently named provider models are equivalent.

Work autonomously for at most 45 minutes, then stop with a short summary. Never
post intermediate progress reports. Priorities, in order:

1. PR merge loop. For every OPEN pull request in this repository:
a. Read reviewer comments (CodeRabbit, Strix, noema-review, humans) and fix
valid findings on the branch; push fixes.
b. Re-check GitHub Checks. Retry transient provider/rate-limit failures
once before investigating.
c. When every required check is green and no unresolved blocking review
remains, merge (squash).
d. Move to the next open PR. Do not force-push; other agents may have
pushed concurrently — pull/rebase instead and respect their commits.

2. Failing checks on main or scheduled workflows: trace logs to root cause and
open a focused fix PR (one concern per PR).

3. Product gaps. If no PRs remain open, pick the highest-leverage gap from
docs/product-technical-gap-baseline.md, implement it with tests + docstrings,
and open a PR that updates the baseline file.

Rules:
- Keep each change minimal and reviewable; stack dependent PRs when natural.
- Follow AGENTS.md governance: KV credentials (never os.getenv at runtime),
snake_case two-word object names, 100% test/docstring coverage intent,
paper-grounded decisions with APA citations in docs.
- Never weaken security gates; never disable required workflows.
- Do not touch COPILOT_GITHUB_TOKEN or the existing review-agent key scheme.
118 changes: 118 additions & 0 deletions .github/workflows/opencode-hourly-loop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,118 @@
name: OpenCode hourly maintenance loop

# Hourly autonomous maintenance: an OpenCode agent whose model traffic is
# served by THIS repository's gateway (contextual-orchestrator) with
# auto-discovered providers and operator-managed model-group routing.
# The agent works the PR queue (review -> fix -> recheck -> merge), root-causes
# failing checks, and advances docs/product-technical-gap-baseline.md items.

on:
schedule:
- cron: "23 * * * *" # hourly at :23 UTC; offset avoids top-of-hour CI storms
workflow_dispatch:

permissions:
contents: read
pull-requests: write
issues: write

concurrency:
group: opencode-hourly-loop
cancel-in-progress: false

jobs:
loop:
name: Run OpenCode maintenance agent through the local gateway
runs-on: ubuntu-latest
timeout-minutes: 55
permissions:
contents: write # required for reviewed branch fixes; scoped to this job
pull-requests: write
issues: write
env:
# Bootstrap transport only: these flow into the process-local KV registry
# (see scripts/ci/serve_seeded_gateway.py); the gateway never reads them
# from the environment again after seeding. See docs/kv-credentials.md.
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
OPENROUTER_API_KEY: ${{ secrets.OPENROUTER_API_KEY }}
OPENCODE_ZEN_API_KEY: ${{ secrets.OPENCODE_ZEN_API_KEY }}
BYTEZ_API_KEY: ${{ secrets.BYTEZ_API_KEY }}
NVIDIA_NIM_API_KEY: ${{ secrets.NVIDIA_NIM_API_KEY }}
NVIDIA_NIM_API_KEY_SUB: ${{ secrets.NVIDIA_NIM_API_KEY_SUB }}
Comment thread
seonghobae marked this conversation as resolved.
Resolved
GATEWAY_BEARER_TOKEN: ${{ secrets.GATEWAY_BEARER_TOKEN || format('loop-{0}', github.run_id) }}
Comment thread
seonghobae marked this conversation as resolved.
Resolved
steps:
- name: Checkout repository
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # actions/checkout@v7
with:
persist-credentials: true # the agent needs to push fixes/branches

- name: Set up Python
uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # actions/setup-python@v6
with:
python-version: "3.12"

- name: Set up Node for the OpenCode CLI
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # actions/setup-node@v4
with:
node-version: "22"

- name: Install pinned runtime dependencies
run: python -m pip install --require-hashes -r fuzz/requirements-property.txt

- name: Install OpenCode CLI
run: npm install --global opencode-ai@1.18.22

Comment thread
github-advanced-security[bot] marked this conversation as resolved.
Fixed
Comment thread
seonghobae marked this conversation as resolved.
Fixed
- name: Start the contextual-orchestrator gateway with auto-discovery
run: |
set -euo pipefail
nohup python -m scripts.ci.serve_seeded_gateway \
--serve \
--agents examples/agents.mock.json \
--auto-discover-model-agents \
--auth-token "$GATEWAY_BEARER_TOKEN" \
--host 127.0.0.1 --port 8000 \
> /tmp/gateway.log 2>&1 &
for _attempt in $(seq 1 30); do
if curl -fsS -H "Authorization: Bearer ${GATEWAY_BEARER_TOKEN}" \
http://127.0.0.1:8000/healthz >/dev/null 2>&1; then
echo "gateway ready"
exit 0
fi
sleep 2
done
echo "::error::gateway did not become healthy"; tail -50 /tmp/gateway.log; exit 1

- name: Point OpenCode at the local gateway
run: |
set -euo pipefail
mkdir -p ~/.config/opencode
cat > ~/.config/opencode/opencode.json <<JSON
{
"\$schema": "https://opencode.ai/config.json",
"model": "contextual_orchestrator_gateway/contextual-orchestrator",
"provider": {
"contextual_orchestrator_gateway": {
"npm": "@ai-sdk/openai-compatible",
"name": "Contextual Orchestrator Gateway",
"options": {
"baseURL": "http://127.0.0.1:8000/v1",
"apiKey": "${GATEWAY_BEARER_TOKEN}"
},
"models": {
"contextual-orchestrator": { "name": "gateway default" }
}
}
}
}
JSON

- name: Run the hourly loop agent
env:
GH_TOKEN: ${{ github.token }}
run: |
opencode run --model contextual_orchestrator_gateway/contextual-orchestrator \
"$(cat .github/opencode/hourly-loop-prompt.md)"
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Resolved

- name: Dump gateway log on failure
if: failure()
run: tail -100 /tmp/gateway.log
27 changes: 21 additions & 6 deletions contextual_orchestrator/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
agent_from_discovered,
agent_id_for,
discover_all_models,
free_discovered_models,
refresh_price_book,
select_top_n_cheapest_discovered_agents,
)
Expand Down Expand Up @@ -216,34 +217,48 @@ def _discover_models_command(argv: list[str]) -> None:
help="Enable the N cheapest discovered agents in --agents-db (auto-optimization bootstrap; "
"requires --agents-db; 0 disables, the default, leaving every discovered agent inert).",
)
parser.add_argument(
"--free-only",
action="store_true",
help="Report only models whose provider metadata marks them zero-cost "
"(reported 0 price or an explicit -free/:free id suffix); the full report keeps every model.",
)
args = parser.parse_args(argv)
if args.enable_cheapest and not args.agents_db:
parser.error("--enable-cheapest requires --agents-db")

discovered, errors = discover_all_models()
free_models = free_discovered_models(discovered)
reported = free_models if args.free_only else discovered
price_book = PriceBook(InMemoryConfigStore())
priced_count = refresh_price_book(discovered, price_book)
priced_count = refresh_price_book(reported, price_book)

enabled_agent_ids: list[str] = []
if args.agents_db:
bootstrap = TaskOrchestrator(
[ModelAgent("bootstrap_agent", "bootstrap-model")], agents_db=args.agents_db
)
bootstrap.sync_discovered_agents([agent_from_discovered(model) for model in discovered])
bootstrap.sync_discovered_agents([agent_from_discovered(model) for model in reported])
if args.enable_cheapest:
for model in select_top_n_cheapest_discovered_agents(discovered, price_book, args.enable_cheapest):
for model in select_top_n_cheapest_discovered_agents(reported, price_book, args.enable_cheapest):
agent_id = agent_id_for(model)
bootstrap.patch_agent("default", agent_id, {"status": "active"})
enabled_agent_ids.append(agent_id)

report = {
"discovered_count": len(discovered),
"discovered_count": len(reported),
"free_tier_count": len(free_models),
"priced_count": priced_count,
"providers_with_errors": sorted({error.provider_name for error in errors}),
"enabled_agent_ids": enabled_agent_ids,
"models": [
{"provider": model.provider_name, "model": model.model_id, "agent_id": agent_id_for(model)}
for model in discovered
{
"provider": model.provider_name,
"model": model.model_id,
"agent_id": agent_id_for(model),
"is_free": model.is_free,
}
for model in reported
],
}
print(json.dumps(report, ensure_ascii=False, sort_keys=True))
Expand Down
12 changes: 6 additions & 6 deletions contextual_orchestrator/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@
"model_header": "Model",
"tags_header": "Tags",
"status_header": "Status",
"capacity_header": "Capacity",
"capacity_header": "EWMA latency",
"success_header": "Success",
"status_healthy": "Healthy",
"status_degraded": "Degraded",
Expand Down Expand Up @@ -441,7 +441,7 @@
"model_header": "모델",
"tags_header": "태그",
"status_header": "상태",
"capacity_header": "용량",
"capacity_header": "EWMA 지연 시간",
"success_header": "성공률",
"status_healthy": "정상",
"status_degraded": "저하",
Expand Down Expand Up @@ -865,7 +865,7 @@
</div>
<table>
<thead>
<tr><th data-i18n="agent_header">Agent</th><th data-i18n="model_header">Model</th><th data-i18n="tags_header">Tags</th><th data-i18n="status_header">Status</th><th data-i18n="capacity_header">Capacity</th><th data-i18n="success_header">Success</th></tr>
<tr><th data-i18n="agent_header">Agent</th><th data-i18n="model_header">Model</th><th data-i18n="tags_header">Tags</th><th data-i18n="status_header">Status</th><th data-i18n="capacity_header">EWMA latency</th><th data-i18n="success_header">Success</th></tr>
</thead>
<tbody id="agents"></tbody>
</table>
Expand Down Expand Up @@ -1070,11 +1070,11 @@
els.agents.innerHTML = rows.map(({agent, index, status}) => `
<tr>
<td><span class="dot ${status.dot}"></span><strong>${escapeHtml(agent.id)}</strong><br><small>${escapeHtml(agent.base_url)}</small></td>
<td>${escapeHtml(agent.model)}</td>
<td>${escapeHtml(agent.model)}${agent.group_name ? `<br><span class="chip">${escapeHtml(agent.group_name)}</span>` : ""}</td>
<td>${tags(agent.tags)}</td>
<td><span class="chip ${status.chip}">${status.label}</span></td>
<td><div>${72 - index * 8}%</div><div class="bar"><span style="width:${72 - index * 8}%"></span></div></td>
<td>${(99.2 - index * .4).toFixed(1)}%</td>
<td>${agent.group_routing?.ewma_latency_seconds == null ? "—" : `${escapeHtml(agent.group_routing.ewma_latency_seconds)}s`}</td>
Comment thread
seonghobae marked this conversation as resolved.
Resolved
<td>${agent.group_routing ? `${(agent.group_routing.success_posterior_mean * 100).toFixed(1)}%` : "—"}</td>
Comment thread
seonghobae marked this conversation as resolved.
Resolved
</tr>`).join("") || `<tr><td colspan="6" class="empty" data-i18n="no_agents_match">${t("no_agents_match")}</td></tr>`;
}
function renderTrace(result) {
Expand Down
82 changes: 81 additions & 1 deletion contextual_orchestrator/api_contract.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,22 @@
"securitySchemes": {
"admin_bearer_auth": {"type": "http", "scheme": "bearer"},
"inference_bearer_auth": {"type": "http", "scheme": "bearer"},
}
},
"schemas": {
"ModelGroupWrite": {
"type": "object",
"required": ["group_name", "member_agent_ids"],
"properties": {
"group_name": {"type": "string"},
"member_agent_ids": {
"type": "array",
"minItems": 1,
"uniqueItems": True,
"items": {"type": "string"},
},
},
}
},
},
"paths": {
"/openapi.json": {
Expand Down Expand Up @@ -208,6 +223,7 @@
"priority": {"type": "integer"},
"tags": {"type": "array", "items": {"type": "string"}},
"provider_exclusions": {"type": "array", "items": {"type": "string"}},
"group_name": {"type": "string"},
},
},
},
Expand All @@ -216,6 +232,70 @@
"responses": {"200": {"description": "Worker agent updated"}},
}
},
"/api/v1/model_groups": {
"get": {
"operationId": "list_model_groups",
"summary": "List logical model groups and measured member evidence",
"security": [{"admin_bearer_auth": []}],
"responses": {"200": {"description": "Model group collection"}},
},
"post": {
"operationId": "create_model_group",
"summary": "Create a logical model group from configured agents",
"security": [{"admin_bearer_auth": []}],
"requestBody": {
"required": True,
"content": {
"application/json": {
"schema": {"$ref": "#/components/schemas/ModelGroupWrite"}
}
},
},
"responses": {"201": {"description": "Model group created"}},
},
},
"/api/v1/model_groups/{group_name}": {
"get": {
"operationId": "get_model_group",
"summary": "Get one logical model group",
"security": [{"admin_bearer_auth": []}],
"parameters": [{"name": "group_name", "in": "path", "required": True, "schema": {"type": "string"}}],
"responses": {"200": {"description": "Model group"}, "404": {"description": "Not found"}},
},
"patch": {
"operationId": "replace_model_group_members",
"summary": "Replace group membership",
"security": [{"admin_bearer_auth": []}],
"parameters": [{"name": "group_name", "in": "path", "required": True, "schema": {"type": "string"}}],
"requestBody": {
"required": True,
"content": {
"application/json": {
"schema": {
"type": "object",
"required": ["member_agent_ids"],
"properties": {
"member_agent_ids": {
"type": "array",
"minItems": 1,
"uniqueItems": True,
"items": {"type": "string"},
}
},
}
}
},
},
"responses": {"200": {"description": "Model group updated"}},
},
"delete": {
"operationId": "delete_model_group",
"summary": "Delete group membership without deleting agents",
"security": [{"admin_bearer_auth": []}],
"parameters": [{"name": "group_name", "in": "path", "required": True, "schema": {"type": "string"}}],
"responses": {"200": {"description": "Model group deleted"}},
},
},
"/api/v1/orchestration_policies/default_policy": {
"get": {
"operationId": "get_default_policy",
Expand Down
7 changes: 6 additions & 1 deletion contextual_orchestrator/cost_router.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,12 @@ def complete(
"request_count": job.request_count,
}

result = self.orchestrator.run(messages, mode=mode, workflow_run_id=workflow_run_id)
result = self.orchestrator.run(
messages,
mode=mode,
workflow_run_id=workflow_run_id,
model_name=model_name,
)
Comment thread
seonghobae marked this conversation as resolved.
Resolved
record = self._record_completion(
messages=messages,
answer=result.get("answer", ""),
Expand Down
Loading
Loading