mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-07-26 09:52:11 +03:00
Scopes the Antigravity 404 model-not-found lockout to the exact model (not the whole family) so one missing bare model no longer hijacks the family cooldown, plus bare-model autopick via resolveModelByProviderInference dedup. The thinking-signature-recovery portion was dropped — #7899 is already fixed and merged on the release via #7906. Co-authored-by: AndrianBalanescu <AndrianBalanescu@users.noreply.github.com> Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
22 lines
963 B
TypeScript
22 lines
963 B
TypeScript
import test from "node:test";
|
|
import assert from "node:assert/strict";
|
|
|
|
import { getModelInfoCore } from "../../open-sse/services/model.ts";
|
|
|
|
test("gpt-oss-120b-medium auto-picks antigravity provider via canonical deduplication", async () => {
|
|
const info = await getModelInfoCore("gpt-oss-120b-medium", null);
|
|
|
|
assert.equal(info.provider, "antigravity");
|
|
assert.equal(info.model, "gpt-oss-120b-medium");
|
|
assert.equal((info as Record<string, unknown>).errorType, undefined);
|
|
});
|
|
|
|
test("unprefixed model with no active providers falls back to ambiguous_model when multiple distinct providers exist", async () => {
|
|
const info = await getModelInfoCore("gpt-oss-120b", null);
|
|
|
|
assert.equal(info.provider, null);
|
|
assert.equal((info as Record<string, unknown>).errorType, "ambiguous_model");
|
|
assert.ok(Array.isArray((info as Record<string, unknown>).candidateProviders));
|
|
assert.ok((info as Record<string, unknown>).candidateProviders.length > 1);
|
|
});
|