Compare commits

...

4 Commits

Author SHA1 Message Date
diegosouzapw
ab47088e8e Merge remote-tracking branch 'origin/release/v3.8.50' into HEAD 2026-08-07 21:38:35 -03:00
diegosouzapw
4929eb0b75 Merge remote-tracking branch 'fork-fenix/fix/release-v3.8.50-combo-compat-basered' into sync/pr-9621-fenix-combo-rebase
# Conflicts:
#	open-sse/services/combo/quotaStrategies.ts
#	tests/unit/combo-context-window-filter.test.ts
2026-08-07 11:59:09 -03:00
Alex
1d5c6170c5 Merge branch 'release/v3.8.50' into fix/release-v3.8.50-combo-compat-basered
Sync PR branch with latest base to resolve merge conflict in
comboStructure.ts (hasHardCapabilityFailure dead code removed by
base).

Co-authored-by: diegosouzapw <diegosouzapw@users.noreply.github.com>
2026-08-06 23:28:25 -03:00
alexey.nazarov@softmg.ru
b106fe7ac4 fix(combo): restore routing module load 2026-08-06 18:05:42 +03:00
4 changed files with 34 additions and 10 deletions

View File

@@ -0,0 +1 @@
- Restore combo routing module loading by removing a duplicate compatibility constant and an unresolved Antigravity helper import.

View File

@@ -19,7 +19,6 @@
* (D7a) so reset-aware tie rotation stays consistent with round-robin routing.
*
* @changes
* - [2026-07-24] [Composer] - Exclude Antigravity accounts without stored projectId from reset-aware pool
* - [2026-07-24] [Composer] - Skip quota-exhausted and rate-limited connections in reset-aware expansion
*
* Pure leaf: this module never imports from the combo barrel.
@@ -45,7 +44,7 @@ import {
type QuotaFetchCacheConfig,
} from "./quotaScoring.ts";
import { rankByHeadroom, type HeadroomSaturation } from "./headroomRanking.ts";
import { preferAntigravityConnectionsWithStoredProject } from "../antigravityProjectPersist.ts";
import { isQuotaExhaustedForRequest } from "../../../src/domain/quotaCache.ts";
const RESET_AWARE_CONNECTION_CACHE_TTL_MS = 30_000;
@@ -85,14 +84,9 @@ async function getQuotaAwareConnectionsForTarget(
(async () => {
try {
const connections = await getCachedProviderConnections({ provider, isActive: true });
let activeConnections = Array.isArray(connections)
const activeConnections = Array.isArray(connections)
? (connections as Array<Record<string, unknown>>)
: [];
if (provider === "antigravity" || provider === "agy") {
activeConnections = preferAntigravityConnectionsWithStoredProject(
activeConnections
) as Array<Record<string, unknown>>;
}
if (
!resetAwareConnectionCache.has(provider) &&
resetAwareConnectionCache.size >= MAX_RESET_AWARE_CACHE

View File

@@ -192,6 +192,26 @@ test("all known-too-small context targets still fall back to strategy order", ()
);
});
test("output-token limits remain a hard compatibility requirement", () => {
saveModelsDevCapabilities({
"unit-output-limit": {
insufficient: capabilityEntryWithLimits(128_000, 128_000, 128),
sufficient: capabilityEntryWithLimits(128_000, 128_000, 4_096),
},
});
const out = filterTargetsByRequestCompatibility(
[target("unit-output-limit/insufficient"), target("unit-output-limit/sufficient")],
{ messages: [{ role: "user", content: "hello" }], max_tokens: 512 },
noopLog
);
assert.deepEqual(
out.map((entry) => entry.modelStr),
["unit-output-limit/sufficient"]
);
});
test("known context overflow reports the largest target limit", () => {
saveModelsDevCapabilities({
"unit-known-context": {
@@ -415,8 +435,8 @@ test("without an override the small-catalog target is ordered last for the large
capped: capabilityEntry(8_000),
},
});
// No override: capped (8K) is genuinely too small and must be filtered out,
// guarding the override read-path from masking a real too-small target.
// No override: capped (8K) is catalog-too-small, so it stays behind the
// known-compatible target while remaining available as a runtime fallback.
const out = filterTargetsByRequestCompatibility(
[target("unit-override/capped"), target("unit-override/big")],
largeContextBody(),

View File

@@ -0,0 +1,9 @@
import test from "node:test";
import assert from "node:assert/strict";
test("combo routing module loads without unresolved symbols", async () => {
const combo = await import("../../open-sse/services/combo.ts");
assert.equal(typeof combo.filterTargetsByRequestCompatibility, "function");
assert.equal(typeof combo.handleComboChat, "function");
});