gui: pi-default-note's agents are connected, so their row pickers list every choice — #709's test was written against the row before 「接入」, where the model field stood in the row; now the model a connected agent starts on is picked beside its switch, and Default there says Pi picks the model itself, as before

This commit is contained in:
yetone committed 2026-10-04 02:14:54 +08:00
1 parent df27f0882a
commit be832ff01b
1 file changed
+5 -3
+5 -3
View File
@@ -5,7 +5,8 @@
// a model Pi would keep. Pi's and OmO's Default says it clears the default
// and Pi picks one itself; other agents' says what it said. Pi's
// openai-codex models are rows of their own beside openai's of the same
// name. In English and Chinese; no backend, the API is faked here.
// name. Both connected to magpie, so the pickers in their rows list every
// choice there is. In English and Chinese; no backend, the API is faked here.
const assert = require("node:assert/strict");
const fs = require("node:fs/promises");
const path = require("node:path");
@@ -17,11 +18,12 @@ const piOptions = [
{ value: "openai/gpt-6-astra", note: "GPT-6 Astra", group: "OpenAI" },
{ value: "openai-codex/gpt-6-astra", note: "GPT-6 Astra", group: "OpenAI Codex" },
{ value: "openai-codex/gpt-5.5", note: "GPT-5.5", group: "OpenAI Codex" },
{ value: "magpie/relay/m1", label: "m1", ref: "relay/m1", note: "Relay · via magpie" },
];
const state = {
agents: [
{ id: "pi", name: "Pi", icon: "generic", path: "/fixture/pi", fields: [{ key: "model", label: "model", value: "openai/gpt-6-astra", options: piOptions }] },
{ id: "claude", name: "Claude Code", icon: "generic", path: "/fixture/claude", fields: [{ key: "model", label: "model", value: "opus", options: [{ value: "opus" }, { value: "sonnet" }] }] },
{ id: "pi", name: "Pi", icon: "generic", path: "/fixture/pi", wired: true, fields: [{ key: "model", label: "model", value: "openai/gpt-6-astra", options: piOptions }] },
{ id: "claude", name: "Claude Code", icon: "generic", path: "/fixture/claude", wired: true, fields: [{ key: "model", label: "model", value: "opus", options: [{ value: "opus" }, { value: "sonnet" }, { value: "relay/m1", label: "m1", ref: "relay/m1", note: "Relay · via magpie" }] }] },
],
profiles: [],
};