fix(models): route image input by preset capability (#6651)
* fix(providers): preserve images across retries and recovery Remove destructive text-only retries and validate tool image media at the boundary. Keep image identity across native transport preparation and compaction, and stop incomplete fallback or continuation without replaying tools. Resolves NAN-442 * fix(models): route image input by preset capability Replace the expanded image recovery and tool-format changes with an explicit supportsImages preset setting, capability-aware fallback selection, and an Image input switch in model settings. Keep original messages on retry and fail on actual non-transient image errors. * docs(models): introduce image input settings positively * test(agent): align image request fixtures with preset routing Cover successful image requests and direct validation errors when attributing model responses. Configure the image-capability check for the existing text-only provider mocks so governance and override-reuse tests exercise their scripted primary/fallback paths.
This commit is contained in:
1 parent
6a24b17629
commit
3f65a8f86c
36 files changed
+483
-444
No files matched your search
@@ -18,5 +18,19 @@ for (const width of [390, 1280]) {
|
||||
await model.hover();
|
||||
await expect(page.getByRole("tooltip")).toHaveText("openai-codex/gpt-6.1-sol");
|
||||
}
|
||||
|
||||
await page.getByRole("button", { name: "New preset", exact: true }).click();
|
||||
const dialog = page.getByRole("dialog", { name: "New preset", exact: true });
|
||||
const imageInput = dialog.getByRole("switch", { name: "Image input", exact: true });
|
||||
await expect(imageInput).toBeVisible();
|
||||
await expect(imageInput).toBeChecked();
|
||||
await imageInput.focus();
|
||||
await imageInput.press("Space");
|
||||
await expect(imageInput).not.toBeChecked();
|
||||
expect(await dialog.evaluate((element) => element.scrollWidth <= element.clientWidth + 1)).toBe(true);
|
||||
await dialog.getByRole("button", { name: "Cancel", exact: true }).click();
|
||||
await expect(dialog).not.toBeVisible();
|
||||
await page.getByRole("button", { name: "New preset", exact: true }).click();
|
||||
await expect(imageInput).toBeChecked();
|
||||
});
|
||||
}
|
||||
Reference in new issue
Block a user