images: every pointer names Settings › Models › Images, where the page is
The image models moved under Settings › Models, but the Library's Magpie
Image sheet, the MCP server's instructions to agents, the gateway's
"no image model" errors, the video tool's text and the docs still sent
users to "Settings › Images", a tab that no longer exists (the scattered
settings audit after netube99 on X). Every user-facing string now names
Settings › Models › Images in en, zh, zh-TW, ja and de, as do the site's
Qwen docs (en, zh, ja), llms-full.txt, the subsystem pages and comments.
Run in the tree with this change and the rest of the audit's fixes
(mote, base cd0ba05c2):
- go vet ./internal/gui ./internal/gateway ./internal/agent
./internal/provider ./internal/settingsapi: ok
- go test -run 'Image|Draw|Video|Hidden|Group|Settings' ./internal/gui
./internal/gateway ./internal/settingsapi: ok; ./internal/imagemcp,
./internal/library, ./internal/catalog: ok
- GUI: i18n-keys, i18n-en-no-cjk, image-models-hide,
library-browser-setup: pass in Chromium and WebKit
- gofmt -l: nothing
Not tried: a real agent reading the new MCP instructions (text only).
This commit is contained in:
+1
-1
@@ -573,7 +573,7 @@ resets are still used on bigmodel.cn.
|
||||
|
||||
Codex's native image tool first asks the provider that served its conversation
|
||||
turn for the requested image model. If that provider does not list the model,
|
||||
or the turn cannot be identified, it uses Settings → Images → Image generation
|
||||
or the turn cannot be identified, it uses Settings → Models → Images → Image generation
|
||||
(including Automatic). Off disables this fallback, not a matching model on the
|
||||
turn's provider. An explicit `provider/model` keeps its destination; an upstream
|
||||
image error does not retry through the setting. Magpie Image MCP is not required.
|
||||
|
||||
@@ -147,7 +147,7 @@ something else shows up as drift.
|
||||
- omp's `enabledModels` in `config.yml` is the list it holds its default role to: a model left out of it isn't used, whatever `modelRoles.default` says (#1769). So a model picked for the default role is added to a list that is there and doesn't take it in already, by name or by one of omp's globs (`*` not crossing `/`, as `Bun.Glob`), and once nothing in `config.yml` is on magpie its plain `magpie/…` entries are taken out (a list left empty goes, never `[]`); a renamed provider's entries are renamed once, and folder-scoped entries are left alone (`ompScope*` in [`omp_scope.go`](../../internal/agent/omp_scope.go)). No list, no change: omp then takes every model. A list that leaves the default role's model out is drift, which Reapply mends.
|
||||
- Pi's `enabledModels` in `settings.json` (and OmO's and Prime Agent's, `piLike`) is the Ctrl+P list a new session starts from. A picked model the list doesn't take in is added (`piScopeWith` in [`pi.go`](../../internal/agent/pi.go)), and a renamed provider's `magpie/<old>/` entries are renamed with it, a glob or a thinking level included, the copy the pick just added dropped (`renameRefList` in [`rename.go`](../../internal/agent/rename.go), #1919, `TestPiEnabledModelsFollowRename`). The user's other entries stay; a list naming none of the provider's models isn't rewritten.
|
||||
- After the catalog sync, an entry in Pi's (and its forks'), StepCode's or omp's `enabledModels` that names one of magpie's models outright (no glob; a thinking level read off) whose model magpie no longer gives the agent is taken out: Pi warned "No models match pattern" for each one at every start (#2055). It may be the user's own, so it is remembered in `stash.json` (`<agent>.scope.gone`) and goes back on the list's end when the model is offered again; a rename moves the remembered entries too, and a disconnect forgets them. Globs, other providers' entries and omp's folder-scoped entries stay. A list left empty is removed and made again when its entries come back, with the model picked meanwhile; one the user removed isn't. When magpie's model list in the agent's file can't be read, nothing is taken out ([`scope_gone.go`](../../internal/agent/scope_gone.go), `TestPiEnabledModelsLoseDeselected`). For StepCode, the wiring state's last-written scope follows, so a disconnect still puts the user's own list back.
|
||||
- Pi's codemode calls classifier and image models (`models.classify`, `models.generateImages`; Pi's docs/models.md "Use classifier models" and "Use image models"), which Pi's `models.json` can't define: its model entries have no `type`, so every one is a chat model, and a custom provider's classifier and image models come from an extension alone (docs/custom-provider.md, "Register mixed-operation models"). So while `models.json` has `providers.magpie`, magpie writes `extensions/magpie.ts` in Pi's agent folder, which Pi loads by itself (`piExtensionSynced` in [`pi_extension.go`](../../internal/agent/pi_extension.go), its source [`pi_extension.ts`](../../internal/agent/pi_extension.ts); wangbinyq on Discord). It registers magpie's decision models (`provider.OfferedDeciders`, labelled as `/v1/models` labels them) as provider `magpie-systemone` on Pi's own `typesafe-system-one` client, which posts TypeSafe's System One body to the gateway's `/v1/systemone`, and its image models (`gateway.ImageModels`: what generate_image may use, the Settings › Images default first, none while it is off) as `magpie-images`, drawn by `/v1/images/generations` with the input's images as data URLs. Separate provider ids, because an extension's `models` replace those `models.json` gives a provider of the same id: registered as `magpie`, Pi 1.4.0 lost magpie's chat models. Classifier input is text only, as the gateway hands a TypeSafe body's `assets` on as they are. The extension does nothing on a Pi older than its classifier models (no `@earendil-works/pi-ai/providers/all`, or a TypeSafe provider without `classify`; Pi 0.87.1 and 1.0.0 start and chat with it). It is rewritten at each Sync and on a pick, and removed with `providers.magpie` (a pick of none, Disconnect, a Sync that finds it gone). A `magpie.ts` whose first line isn't magpie's mark is the user's, never written over or removed. Pi only, not OmO or Prime Agent. Codemode itself stays off unless the user turns it on (`"defaultTools": ["+codemode"]`). Tried with real Pi 1.4.0 in a sandbox home against a fake gateway: both lists, a classify and a drawing reached `/v1/systemone` and `/v1/images/generations` with magpie's key (`TestPiExtensionListsDecisionAndImageModels`, `TestPiExtensionFollowsSync`, `TestPiExtensionLeavesTheUsersOwn`, `TestPiExtensionPiOnly`).
|
||||
- Pi's codemode calls classifier and image models (`models.classify`, `models.generateImages`; Pi's docs/models.md "Use classifier models" and "Use image models"), which Pi's `models.json` can't define: its model entries have no `type`, so every one is a chat model, and a custom provider's classifier and image models come from an extension alone (docs/custom-provider.md, "Register mixed-operation models"). So while `models.json` has `providers.magpie`, magpie writes `extensions/magpie.ts` in Pi's agent folder, which Pi loads by itself (`piExtensionSynced` in [`pi_extension.go`](../../internal/agent/pi_extension.go), its source [`pi_extension.ts`](../../internal/agent/pi_extension.ts); wangbinyq on Discord). It registers magpie's decision models (`provider.OfferedDeciders`, labelled as `/v1/models` labels them) as provider `magpie-systemone` on Pi's own `typesafe-system-one` client, which posts TypeSafe's System One body to the gateway's `/v1/systemone`, and its image models (`gateway.ImageModels`: what generate_image may use, the Settings › Models › Images default first, none while it is off) as `magpie-images`, drawn by `/v1/images/generations` with the input's images as data URLs. Separate provider ids, because an extension's `models` replace those `models.json` gives a provider of the same id: registered as `magpie`, Pi 1.4.0 lost magpie's chat models. Classifier input is text only, as the gateway hands a TypeSafe body's `assets` on as they are. The extension does nothing on a Pi older than its classifier models (no `@earendil-works/pi-ai/providers/all`, or a TypeSafe provider without `classify`; Pi 0.87.1 and 1.0.0 start and chat with it). It is rewritten at each Sync and on a pick, and removed with `providers.magpie` (a pick of none, Disconnect, a Sync that finds it gone). A `magpie.ts` whose first line isn't magpie's mark is the user's, never written over or removed. Pi only, not OmO or Prime Agent. Codemode itself stays off unless the user turns it on (`"defaultTools": ["+codemode"]`). Tried with real Pi 1.4.0 in a sandbox home against a fake gateway: both lists, a classify and a drawing reached `/v1/systemone` and `/v1/images/generations` with magpie's key (`TestPiExtensionListsDecisionAndImageModels`, `TestPiExtensionFollowsSync`, `TestPiExtensionLeavesTheUsersOwn`, `TestPiExtensionPiOnly`).
|
||||
- A model's price goes into every agent file that takes one, in USD per million tokens: Pi's and its forks' `cost`, omp's `cost` (omp 18.9.1 prices a custom provider's call by it alone; without it a `group/*` id matched no bundled model and cost 0, taotao7 on Discord), OpenCode's `cost` (`cache_read`, `cache_write`) and Crush's `cost_per_1m_*` (`in_cached` is a write, `out_cached` a read). A group whose members cost the same is priced at that; one whose members differ at the member it sends to first, a manual group's pick, else its first not switched off (`provider.AgentPricer`), and none when that member is in a fast mode or has no price. The gateway's `/v1/models` keeps `EntryPricer`, which prices only a group of one price. The price is read at each Sync, so it follows the group's members ([`route.go`](../../internal/agent/route.go), `TestGroupModelsCarryTheirFirstMembersPrice`).
|
||||
- A value an agent spells as its own provider's model is never taken for one of magpie's, even when magpie has a provider of the same name (`Spelled`, #835).
|
||||
- The other way round, a value that names one of magpie's models the agent isn't shown (kept from it by `magpie visible` or a model not ticked for it), a model of one of magpie's providers that isn't on its list (a remote magpie's group added there since the list was fetched), or a `group/…` magpie has no group for, is refused by `Spell` (`notOffered`), and nothing changes. It used to be written as the agent's own: Pi read `remote/group/smart` as its own provider `remote` and model `group/smart`, and was taken out of magpie (#2376). A model shown the agent that a field offers fewer of (Claude Desktop's tiers) is still taken, and so is a value whose provider part one of the agent's own models goes by (`openai/…` in Pi) ([`agent.go`](../../internal/agent/agent.go), `TestSpellRefusesMagpieModelNotOffered`).
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -69,7 +69,7 @@ and lists, switches and copies each Pi's extensions and packages.
|
||||
- With the MCP router on (`MCPHub`), an agent that takes a Streamable HTTP server is given magpie's one `magpie` entry in place of the Library servers ticked for it, and each server's own entry again when it is turned off. One that can't, or has an entry called magpie of its own, or whose library has a server called magpie, keeps each server's own entry, and the page says why ([MCP router](mcp-router.md)).
|
||||
- A gateway key held to some MCP servers and tools (wakaka on Discord) reaches through the router only those: the gateway holds each hub tool to the Library server behind it (see [gateway routing](gateway-routing.md)). The key editor lists every Library server, the hub's or not, with the tools it last listed (`KeyMCPServers`, from the router's cards); a server that never listed shows no tools and can still be given whole.
|
||||
- magpie's own MCP servers (`magpie-image`, `magpie-browser`, `magpie-web-search`, `magpie-vision`, and any `mcp …` run by a program named magpie) run this computer's magpie (#1439). `InstallServer` gives it magpie by full path (`update.Program`: the AppImage, not its mount; Homebrew's opt link, not the Cellar), and that path is right only on this computer. When the library is read, and after every change, `heal` points such a server whose program isn't on this computer (another system's path, a magpie moved out of Downloads, a bare `magpie`) at this magpie, so the agents and `CheckServers` get it; a magpie program that is here (another build) and a server run by any other program stay as they are. A carried library (`Collect`, for a backup or a WebDAV or S3 sync) names it as plain `magpie`, so two computers carry the same bundle and a sync doesn't write one's path over the other's; `Put` then reads it as that computer's magpie. [`self_here.go`](../../internal/library/self_here.go)
|
||||
- Magpie Web Search (`magpie-web-search`, `searchServer` in [`market.go`](../../internal/library/market.go)) is the featured, opt-in server for magpie's web search: `magpie mcp search` (`RunSearch` in [`browsermcp.go`](../../internal/browsermcp/browsermcp.go)) passes each stdio message to the gateway's `/mcp/magpie/web-search`, as `magpie mcp browser` does to its own path, with no browser session. Its sheet says each search goes where Settings › Models › Web search sends it. That page's MCP server row (`#searchMcpRow`) keeps the address to copy, and under its words Give agents Magpie Web Search… opens the sheet in the Library (`magpie.call("library", "server", "magpie-web-search")`), Turn on the Library when the Library is off, and nothing in gateway mode, as Settings › Images does for Magpie Image (lutra_fs on Discord: the search was in Settings and not in the Library; `search-mcp-library.test.cjs`). Each agent is given a 120-second tool timeout for it (`selfTimeout`). An agent in WSL is not given it directly, as with Magpie Browser; the MCP router serves it there.
|
||||
- Magpie Web Search (`magpie-web-search`, `searchServer` in [`market.go`](../../internal/library/market.go)) is the featured, opt-in server for magpie's web search: `magpie mcp search` (`RunSearch` in [`browsermcp.go`](../../internal/browsermcp/browsermcp.go)) passes each stdio message to the gateway's `/mcp/magpie/web-search`, as `magpie mcp browser` does to its own path, with no browser session. Its sheet says each search goes where Settings › Models › Web search sends it. That page's MCP server row (`#searchMcpRow`) keeps the address to copy, and under its words Give agents Magpie Web Search… opens the sheet in the Library (`magpie.call("library", "server", "magpie-web-search")`), Turn on the Library when the Library is off, and nothing in gateway mode, as Settings › Models › Images does for Magpie Image (lutra_fs on Discord: the search was in Settings and not in the Library; `search-mcp-library.test.cjs`). Each agent is given a 120-second tool timeout for it (`selfTimeout`). An agent in WSL is not given it directly, as with Magpie Browser; the MCP router serves it there.
|
||||
- Magpie Browser (`magpie-browser`) is opt-in, added with no agents, so the router offers it to none until one is ticked (an agent asked to use the browser reached for AppleScript instead). While its extension is connected (`GET /api/library/browser`, read again every 3 seconds while the row is shown) and no agent has it, its row in the MCP list asks which agents may use it, on a line of its own under the row's name, command and chips (from the name's left edge to the row's right one, the row's `lib-asking`), a button per agent whose chip can be clicked; a button clicks that chip, so the choice goes through `servers/agents` as a chip's does, and the row asks nothing more (`browserAsk` in [`client.js`](../../internal/gui/assets/plugins/library/client.js); `library-browser-ask.test.cjs`).
|
||||
- A page whose browser can't reach magpie's folders (magpie in a container, `gateway.InContainer`, or a page from another computer) is told so (`browserJSON.Away`), and the sheet's button is Download the extension: `POST /api/library/browser/extension` with the page's origin answers a zip of the extension (`browserext.Zip`) pointed at that origin, with the secret of the On gateway key named Magpie Browser, made by the first download (`browserKey`). It is a POST so a cross-site link can't mint a key. The zip lands in Downloads, so the key is a browser key (`access.Key.Browser`): it opens the extension's socket and nothing else, no model, MCP server or stat (`readOnlyGuard`, see [gateway routing](gateway-routing.md); Gateway → Gateway keys tags it Browser only and offers no access to change). One a magpie from before made with full access is held so with the same secret as the gateway starts and on the next download (`ScopeOwnBrowserKey`, `access.ScopeBrowser`), so the extension keeps connecting. A browser connecting from elsewhere with a key belongs to it: the gateway's relay gives it only to sessions tagged `key:<id>/` (`browserOwner`, `keyedSession` in [`browser.go`](../../internal/gateway/browser.go)), which is what a remote caller's session is forced to. The key the page makes is recorded as this magpie's own browser's (`SetOwnBrowserKey`, a file in the settings folder), and a browser connecting with it serves this computer's sessions too when it connects from this computer (`browserConn.own`: the key and `local`, so not through a proxy or the page port; `serves`). From another computer, the Docker bridge's 172.17.0.1 included, the key proves nothing: a copy of the zip could connect a browser there, and this computer's agents' calls would go to it, so it serves only its key's sessions (#5529). A record that can't be read names no key. A keyed connection lasts while its key does: `watchKey` looks every 5 seconds and closes the socket once the key is turned off, removed, expired or rotated (`access.Current`), and a call looks first too (`TestBrowserIsItsKeys`; `TestOwnBrowserKeyIsThisComputers`; `TestBrowserKeyOffClosesItsBrowser`; `TestBrowserExtensionDownload`; `library-browser-away.test.cjs`; `gateway-key-readonly.test.cjs`).
|
||||
- Magpie Image Recognition (`magpie-vision`, `visionServer` in [`market.go`](../../internal/library/market.go)) is the featured, opt-in server for image recognition, beside Magpie Image and Magpie Web Search (matrix0487 on Discord: Discover had two of magpie's three): `magpie mcp vision` (`RunVision` in [`browsermcp.go`](../../internal/browsermcp/browsermcp.go)) passes each stdio message to the gateway's `/mcp/magpie/vision`, and makes `analyze_image`'s relative `image` path one in the agent's own folder on the way (`imageFrom`), since the gateway can't know where the agent runs; an absolute path, `~`, a URL or a drive goes as written. Its sheet says each image goes to Settings › Models › Images › Image recognition's model. That row has Give agents Magpie Image Recognition… (`libWay` in app.js, shared with Images' and Web search's links), Turn on the Library with the Library off, and nothing with recognition off or in gateway mode (`vision-mcp-library.test.cjs`). It gets the same 120-second tool timeout and the same WSL rule as Magpie Web Search.
|
||||
|
||||
@@ -362,7 +362,7 @@ and `TestHistoricalWindowHoldsUsesEachWindowsOwnReading`.
|
||||
- The scheduled warm-up warms each window a Claude account is expected to have (`withExpected`), the 5-hour and the week, also one its reading left out: Anthropic leaves a window out until the request that starts it. A window left out while a shorter one is running is one the account doesn't have, since any use starts every window it has (a Claude Enterprise account with only the 5-hour, koohoko5924 on Discord, whose week was warmed over and over and its state read Idle): the warmer marks it `Absent` in `codex-warmup.json` and sends it nothing, and `usageRead` doesn't count it as due (`windowAbsent`, `shorterRunning` in [`codex_warmup.go`](../../internal/provider/codex_warmup.go)). A week once seen running, or left out of a reading that is only part of the plan's, is still warmed; one never read before is not. `TestClaudeWarmLeavesAWeekTheAccountHasnt`, `TestClaudeWarmStartsAWeekThatReset`, `TestUsageReadLeavesAWeekTheAccountHasnt`.
|
||||
- An Antigravity subscription offers the union of its On accounts' models (`antigravityPoolModels` in [`antigravity_pool.go`](../../internal/provider/antigravity_pool.go)), each account's own list kept beside it (`accountModels`, read by `Account.Lists` for routing). The lists are fetched at the first listing, a probe, a sync or a Refetch, and also at each account's quota reading, which asks `fetchAvailableModels` anyway: a reading whose models differ from the account's saved list saves it and merges the pooled list again from every On account's own (`noteAntigravityList`), so a model Google gives one account of several later (01huadalang on Discord: Gemini 4) is offered, routed to and given its bar without that account made preferred or probed. A switched-off account's reading changes nothing. `TestAntigravityQuotaReadingListsNewModels`. Each `fetchAvailableModels` names the account's paid and current tier first (`entitlement.userTier`, `askTiers`), then none; a tier Google answers 400 (a Google AI Pro account's g1-pro-tier, #1553) is left out of that account's lists and quota readings for `tierRefusedFor` (a day), and the refused request is no row of the request log.
|
||||
- A provider removed or switched off takes its models out of the catalog. [Agent wiring](agent-wiring.md)'s `Reseat` moves agents off them.
|
||||
- A preset marked `NoList` uses its preset model list instead of requesting `/models`, and ignores previously fetched lists, including their protocol and key restrictions, unless the user sets `ModelsURL` or chooses a region marked `Lists`. Each region can carry a different list. Volcengine Ark's Coding Plan and Agent Plan use separate preset lists. Both plans include their embedding model separately from agents' chat-model lists; Agent Plan additionally exposes its image- and video-generation models to Settings → Images; Ark itself refuses video generation on Small and Medium Agent Plans, which include it only in the Large and Max tiers. Models magpie does not yet serve (Agent Plan's speech models) are not advertised. Ark's pay-as-you-go region still fetches its own list. Coding's `/api/coding/v3/models` returns a general Ark catalog instead of the plan's model ids, while Agent's `/api/plan/v3/models` returns 404. A preset with no regions may name its embedding and rerank models itself (`PresetDef.Embeddings`, `Rerankers`): Voyage AI (`voyage`, heatonz on Discord) has no `/models` and serves only those, so they are its whole list, each marked with what it serves (`catalog.Model.Serves`), kept out of chat lists, and found on `/v1/embeddings` or `/v1/rerank` alone by `PlanRetrieval(kind)` (`TestVoyagePreset`, `TestVoyageModelsStayOnTheirRoutes`). [`presets.go`](../../internal/provider/presets.go) defines these choices; `List`, `fetch`, `live`, `planModels`, `PlanEmbeddings`, `PlanRerankers`, `PlanRetrieval`, `PlanDrawers` and `PlanVideos` in [`models.go`](../../internal/provider/models.go) apply them when adding, refreshing and reading cached models. `TestVolcengineModelLists` checks that the plans make no list requests, ignore old cached lists and return their own preset models; pay-as-you-go and an explicit list URL still make requests.
|
||||
- A preset marked `NoList` uses its preset model list instead of requesting `/models`, and ignores previously fetched lists, including their protocol and key restrictions, unless the user sets `ModelsURL` or chooses a region marked `Lists`. Each region can carry a different list. Volcengine Ark's Coding Plan and Agent Plan use separate preset lists. Both plans include their embedding model separately from agents' chat-model lists; Agent Plan additionally exposes its image- and video-generation models to Settings → Models → Images; Ark itself refuses video generation on Small and Medium Agent Plans, which include it only in the Large and Max tiers. Models magpie does not yet serve (Agent Plan's speech models) are not advertised. Ark's pay-as-you-go region still fetches its own list. Coding's `/api/coding/v3/models` returns a general Ark catalog instead of the plan's model ids, while Agent's `/api/plan/v3/models` returns 404. A preset with no regions may name its embedding and rerank models itself (`PresetDef.Embeddings`, `Rerankers`): Voyage AI (`voyage`, heatonz on Discord) has no `/models` and serves only those, so they are its whole list, each marked with what it serves (`catalog.Model.Serves`), kept out of chat lists, and found on `/v1/embeddings` or `/v1/rerank` alone by `PlanRetrieval(kind)` (`TestVoyagePreset`, `TestVoyageModelsStayOnTheirRoutes`). [`presets.go`](../../internal/provider/presets.go) defines these choices; `List`, `fetch`, `live`, `planModels`, `PlanEmbeddings`, `PlanRerankers`, `PlanRetrieval`, `PlanDrawers` and `PlanVideos` in [`models.go`](../../internal/provider/models.go) apply them when adding, refreshing and reading cached models. `TestVolcengineModelLists` checks that the plans make no list requests, ignore old cached lists and return their own preset models; pay-as-you-go and an explicit list URL still make requests.
|
||||
- A key's provider can have its model list off (`Provider.ListOff`, `ListsOff()`; axelburks on Discord: Ark's pay-as-you-go list names models that can't be asked for, each is asked by an endpoint id the user made). Nothing asks its vendor for a list: `Fetch`, `Refetch`, `List`, `RefreshLists`, a test, a new key's prefill and a resting key's probe (`ListAsks`) skip it, and `Fetch`/`List` return `ErrListOff`. A list fetched before and models.dev's are not read, so only the ids the user added are served. A signed-in account and a plugin list their models as their sign-in does, so the switch is a key provider's alone (`takesListOff` in `/api/providers`). The editor shows it as Fetch the model list, ticked by default; unticked, Fetch models and Forget go. A save that doesn't name `listOff` keeps it. The CLI takes `list=off|on`. Tests: `TestListOffAsksNoListAndServesTheIDsAdded`, `TestProviderSaveListOff`, `provider-list-off.test.cjs`.
|
||||
- A gateway key held to some accounts (#905) is held to those of the providers its list names: a provider it names no account of, the key uses as its models allow. A key that lists accounts and no model may use only those accounts' providers' models (`access.HeldModels`, applied where `access.Authenticate` makes the request's `Identity`, so every route's model check holds it; Linka on Discord: ticking only an account let the key list and use every other provider's models; `TestGatewayKeyAccountsOnlyHoldTheModels`). The key's menu says so on each account of such a provider ("Used: no … account is picked" when its models reach the provider, "Not used: no … model or account is picked" when they don't), and its badge's tooltip that a key is kept off a provider by its models (#2077: unticking every Codex account left Codex's models served), or, with no model picked, that only the picked accounts' providers' models are the key's. The list keeps an account by its stable id — `logins.json`'s `id`, set once written and kept through renames; the agents that keep no logins (and plugins) are known by a hash of the account's name, so an account renamed there drops out of a key's list, holding it closer, never wider. Storing an id for every agent is a larger change, not this one's.
|
||||
- A routing group may be held to some accounts the same way (`Group.Accounts`, duanckham on X): a request through it uses only those of a provider it names, and with a gateway key only those both allow. Entries are resolved and checked when the group is saved (`cleanGroupAccounts`, `ResolveAccount`), and dropped from a shared or imported group. See [gateway-routing](gateway-routing.md#a-route-group-held-to-chosen-accounts).
|
||||
|
||||
@@ -730,7 +730,7 @@ func ompProviderAt(gw, version string) ompProviderEntry {
|
||||
// the whole file away over an api it doesn't list.
|
||||
const ompKindSince = "18.7.0"
|
||||
|
||||
// ompImageModels are magpie's image models (Settings › Images, as
|
||||
// ompImageModels are magpie's image models (Settings › Models › Images, as
|
||||
// generate_image offers them) as omp's image role takes them (treeman_26897
|
||||
// on Discord): kind image on openai-images, which omp's generate_image
|
||||
// posts to the provider's baseUrl + /images/generations, or /images/edits
|
||||
|
||||
@@ -120,7 +120,7 @@ type Model struct {
|
||||
// ChatGPT account answers for (provider.Entry's).
|
||||
AgentsV2 bool `json:",omitempty"`
|
||||
// Draws is set on a vendor-listed model that makes images (gpt-image-1,
|
||||
// a relay's flux): kept with the list for Settings → Images, never
|
||||
// a relay's flux): kept with the list for Settings → Models → Images, never
|
||||
// offered to agents as a model to talk to.
|
||||
Draws bool `json:",omitempty"`
|
||||
// Films is set on a model another magpie lists as one it makes videos
|
||||
|
||||
@@ -128,7 +128,7 @@ func drawerMissing(v string) string {
|
||||
|
||||
// GroupDraws is whether the routing group ref ("group/<id>") has a member
|
||||
// that draws: a model among its provider's Drawers. Such a group may be
|
||||
// picked in Settings › Images, and draws on those members in its routing's
|
||||
// picked in Settings › Models › Images, and draws on those members in its routing's
|
||||
// order, moving on while one fails (drawingGroup, #2005).
|
||||
func GroupDraws(ref string) bool {
|
||||
_, ms, ok := drawingMembers(ref)
|
||||
@@ -429,7 +429,7 @@ func DrawersOf(p provider.Provider, avail func() []catalog.Model) []catalog.Mode
|
||||
// (provider.HiddenDrawers, 321sssrt on X): the image models a list offers
|
||||
// to pick from and Automatic picks among. A request that names a hidden
|
||||
// one still draws with it (resolveDrawing reads Drawers), as does a
|
||||
// Settings › Images pick of one made before it was hidden.
|
||||
// Settings › Models › Images pick of one made before it was hidden.
|
||||
func OfferedDrawers(p provider.Provider) []catalog.Model {
|
||||
ms := Drawers(p)
|
||||
if len(p.HiddenDrawers) == 0 {
|
||||
@@ -438,7 +438,7 @@ func OfferedDrawers(p provider.Provider) []catalog.Model {
|
||||
return slices.DeleteFunc(slices.Clone(ms), func(m catalog.Model) bool { return p.DrawerHidden(m.ID) })
|
||||
}
|
||||
|
||||
// DrawerHidden is whether ref (provider/model), a model Settings › Images
|
||||
// DrawerHidden is whether ref (provider/model), a model Settings › Models › Images
|
||||
// names, is one the user unticked in its provider's editor: it still draws,
|
||||
// and the Settings row says it is hidden. A ChatGPT account's other GPT
|
||||
// Image names stand for its one (ListedDrawer).
|
||||
@@ -674,7 +674,7 @@ func (s *Server) images(edit bool) http.HandlerFunc {
|
||||
fail(400, fmt.Sprintf("no model to draw with: the Image generation model picked in magpie's Settings, %q, isn't set up any more: pick another in Settings → Models → Image generation, or name one", v))
|
||||
return
|
||||
}
|
||||
fail(400, "no model to draw with: pick one in magpie's Settings → Images → Image generation, or name one")
|
||||
fail(400, "no model to draw with: pick one in magpie's Settings → Models → Images → Image generation, or name one")
|
||||
return
|
||||
}
|
||||
d.Model, call.Model = m, m
|
||||
@@ -682,7 +682,7 @@ func (s *Server) images(edit bool) http.HandlerFunc {
|
||||
p, model, ok := s.drawingModel(r, d.Model)
|
||||
if !ok {
|
||||
if agentOf(r) == "codex" && !strings.Contains(d.Model, "/") {
|
||||
fail(400, "no model to draw with: Codex's provider has no matching image model and magpie's Settings → Images → Image generation has none enabled")
|
||||
fail(400, "no model to draw with: Codex's provider has no matching image model and magpie's Settings → Models → Images → Image generation has none enabled")
|
||||
return
|
||||
}
|
||||
if off, isOff := provider.SwitchedOff(d.Model); isOff {
|
||||
|
||||
@@ -80,7 +80,7 @@ func TestImageGroupOfUnpickedImageModelsDraws(t *testing.T) {
|
||||
t.Fatalf("group/pix-images: %d %s", code, raw)
|
||||
}
|
||||
|
||||
// picked in Settings › Images, it draws a request naming no model
|
||||
// picked in Settings › Models › Images, it draws a request naming no model
|
||||
st := settings.Load()
|
||||
st.ImageGen = "group/pix-images"
|
||||
if err := settings.Save(st); err != nil {
|
||||
|
||||
@@ -13,7 +13,7 @@ import (
|
||||
|
||||
// 321sssrt on X: an image model unticked in its provider's editor
|
||||
// (HiddenDrawers) leaves what lists image models to pick from, and
|
||||
// Automatic, but still draws when named or picked in Settings › Images.
|
||||
// Automatic, but still draws when named or picked in Settings › Models › Images.
|
||||
func TestHiddenDrawerLeavesListsButStillDraws(t *testing.T) {
|
||||
fresh(t)
|
||||
drawingRelay(t, "hd", "gpt-image-hidden", "gpt-image-shown")
|
||||
|
||||
@@ -1492,7 +1492,7 @@ func drawerObjects(r *http.Request) []map[string]any {
|
||||
if !p.On() || p.DecideOnly() {
|
||||
continue
|
||||
}
|
||||
// less those unticked in its editor, as Settings › Images lists them
|
||||
// less those unticked in its editor, as Settings › Models › Images lists them
|
||||
for _, m := range OfferedDrawers(p) {
|
||||
if held && (!modelAllowed(who, p, m.ID) || !accountServes(who, p, m.ID)) {
|
||||
continue
|
||||
|
||||
@@ -24,7 +24,7 @@ import (
|
||||
"github.com/yetone/magpie/internal/settings"
|
||||
)
|
||||
|
||||
// magpie's image generation, the model Settings › Images › Image generation
|
||||
// magpie's image generation, the model Settings › Models › Images › Image generation
|
||||
// names, is also an MCP server the gateway serves itself, beside image
|
||||
// recognition's (JonahFu on X): Magpie Image (internal/imagemcp) is a stdio
|
||||
// server the Library gives an agent on this computer, which a gateway in
|
||||
@@ -141,7 +141,7 @@ func imageMCPTools(r *http.Request) []any {
|
||||
map[string]any{
|
||||
"name": GenerateImageTool,
|
||||
"title": "Generate image",
|
||||
"description": "Generate an image from a text prompt, or edit/combine images given as reference_images, with the image model set in Magpie (Settings → Images → Image generation) or the one model names. " +
|
||||
"description": "Generate an image from a text prompt, or edit/combine images given as reference_images, with the image model set in Magpie (Settings → Models → Images → Image generation) or the one model names. " +
|
||||
"The image comes back in the answer and at a URL Magpie keeps it at for an hour (the link opens without a header, in a browser too, until it expires); nothing is saved in your project, so save it there yourself if you need it. " +
|
||||
"When it is not ready within about 20 seconds, the answer is an id to wait on with " + GenerationResultTool + " instead. Write a detailed prompt: subject, style, composition, colours, any text to render exactly.",
|
||||
"inputSchema": ro(ImageToolProps(imageMCPFrom+"s"), false),
|
||||
@@ -212,7 +212,7 @@ func (s *Server) imageMCPCall(r *http.Request, m mcpMessage) (any, map[string]an
|
||||
"protocolVersion": mcpVersion(m),
|
||||
"capabilities": map[string]any{"tools": map[string]any{}},
|
||||
"serverInfo": map[string]any{"name": "magpie-image", "title": "Magpie Image", "version": Version},
|
||||
"instructions": GenerateImageTool + " draws with the image model set in magpie (Settings → Images → Image generation) and " + GenerateVideoTool + " makes a short video; images come back in the answer and at a URL, videos at a URL, nothing is saved in your project.",
|
||||
"instructions": GenerateImageTool + " draws with the image model set in magpie (Settings → Models → Images → Image generation) and " + GenerateVideoTool + " makes a short video; images come back in the answer and at a URL, videos at a URL, nothing is saved in your project.",
|
||||
}, nil
|
||||
case "ping":
|
||||
return map[string]any{}, nil
|
||||
@@ -265,7 +265,7 @@ func imageGenOff() (map[string]any, bool) {
|
||||
if settings.Load().ImageGen != "off" {
|
||||
return nil, false
|
||||
}
|
||||
return toolResult("Image generation is off in magpie: pick a model for it in Settings → Images → Image generation", true), true
|
||||
return toolResult("Image generation is off in magpie: pick a model for it in Settings → Models → Images → Image generation", true), true
|
||||
}
|
||||
|
||||
// imageMCPDraw starts generate_image's drawing and answers with what it
|
||||
|
||||
@@ -14,7 +14,7 @@ import (
|
||||
|
||||
// generate_image and generate_video take the model to use (XYenon on
|
||||
// Discord): one of those set up for it, as provider/model, else the one
|
||||
// Settings › Images picks. The tool's schema lists those the caller may use
|
||||
// Settings › Models › Images picks. The tool's schema lists those the caller may use
|
||||
// (mediaModelsFor), and a model none of them is, is a tool error naming
|
||||
// them, never a drawing with another. The model chosen is named to the
|
||||
// images and videos APIs, so a gateway key's models hold it there as they
|
||||
@@ -74,7 +74,7 @@ type ImageModel struct {
|
||||
}
|
||||
|
||||
// ImageModels are the models generate_image may be asked for
|
||||
// (mediaModels), the Settings › Images default first, each with its label;
|
||||
// (mediaModels), the Settings › Models › Images default first, each with its label;
|
||||
// none when image generation is off.
|
||||
func ImageModels() []ImageModel {
|
||||
all, _ := mediaModels(false)
|
||||
@@ -141,7 +141,7 @@ func mediaModelProp(video bool, shown []string, def string) map[string]any {
|
||||
case video:
|
||||
d += " Leave it out to use the video model set up in Magpie (now " + def + ")."
|
||||
default:
|
||||
d += " Leave it out to use the one set in Magpie (Settings → Images → Image generation; now " + def + ")."
|
||||
d += " Leave it out to use the one set in Magpie (Settings → Models → Images → Image generation; now " + def + ")."
|
||||
}
|
||||
prop := map[string]any{"type": "string"}
|
||||
switch n := len(shown); {
|
||||
|
||||
@@ -282,7 +282,7 @@ func Videomaker() string {
|
||||
return m
|
||||
}
|
||||
|
||||
// VideomakerMissing is the model Settings › Images › Video generation
|
||||
// VideomakerMissing is the model Settings › Models › Images › Video generation
|
||||
// names when magpie can't make videos with it any more, so that
|
||||
// AutoVideomaker's makes them in its place, as DrawerMissing is Image
|
||||
// generation's. "" when none is named or it resolves.
|
||||
@@ -1063,7 +1063,7 @@ func (s *Server) videosCreate(w http.ResponseWriter, r *http.Request) {
|
||||
if f.Model == "" {
|
||||
m, ok := videomaker()
|
||||
if !ok {
|
||||
fail(400, "no model to make videos with: sign in to a Grok subscription or set up a provider that makes videos (a MiniMax API key makes them with MiniMax-H3), and leave Settings → Images → Image generation on, or name one")
|
||||
fail(400, "no model to make videos with: sign in to a Grok subscription or set up a provider that makes videos (a MiniMax API key makes them with MiniMax-H3), and leave Settings → Models → Images → Image generation on, or name one")
|
||||
return
|
||||
}
|
||||
f.Model, call.Model = m, m
|
||||
|
||||
@@ -435,7 +435,7 @@ func TestCustomProviderVideoKeepsTheCallersFields(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
// Settings › Images › Video generation (the reporter's "custom providers
|
||||
// Settings › Models › Images › Video generation (the reporter's "custom providers
|
||||
// still can't pick a video model"): a custom provider's model the user
|
||||
// marked a video model, picked there, makes the video a request that names
|
||||
// none gets, and is generate_video's default, though Automatic would take
|
||||
|
||||
@@ -4919,7 +4919,7 @@ input[type="checkbox"]:disabled { opacity: .45; }
|
||||
|
||||
/* a disabled model's pattern, as typed (#1867): an id or a glob */
|
||||
.disabled-model .name { font-family: var(--code); font-size: 12px; overflow-wrap: anywhere; }
|
||||
/* Settings › Images: the way to the Magpie Image tool, under its words (#2091) */
|
||||
/* Settings › Models › Images: the way to the Magpie Image tool, under its words (#2091) */
|
||||
.lib-way .link { padding-left: 0; padding-right: 0; white-space: normal; text-align: start; }
|
||||
/* Settings › Proxy's Test result (#2076): under the row's text */
|
||||
.row.pref .sub.proxy-check { margin-top: 3px; white-space: normal; overflow-wrap: anywhere; }
|
||||
|
||||
@@ -11473,7 +11473,7 @@ function renderModels(p) {
|
||||
if (!p.models.length && !draft.chosen.length) chips.append(el("span", "hint", t(emptyModelsHint(p))));
|
||||
// the list is of models agents chat with: image, embedding and speech
|
||||
// models are left out of it, and an image model is set in Settings
|
||||
else if (f && !chips.children.length) chips.append(el("span", "hint", t("No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Images.", { q: q.value.trim() })));
|
||||
else if (f && !chips.children.length) chips.append(el("span", "hint", t("No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Models → Images.", { q: q.value.trim() })));
|
||||
drawNames();
|
||||
drawFold();
|
||||
drawWorkOn();
|
||||
@@ -12110,7 +12110,7 @@ function renderModels(p) {
|
||||
}
|
||||
|
||||
function renderDrawers(p) {
|
||||
return field(t("Image models"), mediaChips("mchips drawers", p.drawIds, "hiddenDrawers", p, p.drawNames), p.drawPicks ? t("ChatGPT's image backend picks the GPT Image version itself and doesn't say which; to choose one, use an OpenAI API key") : t("Settings → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models."));
|
||||
return field(t("Image models"), mediaChips("mchips drawers", p.drawIds, "hiddenDrawers", p, p.drawNames), p.drawPicks ? t("ChatGPT's image backend picks the GPT Image version itself and doesn't say which; to choose one, use an OpenAI API key") : t("Settings → Models → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models."));
|
||||
}
|
||||
|
||||
// renderVideomakers: its video models, ticked to be offered (axelburks on Discord)
|
||||
|
||||
+12
-12
@@ -1159,7 +1159,7 @@ const I18N = {
|
||||
"no images generated": "不生成图片",
|
||||
"ChatGPT's image backend picks the GPT Image version itself and doesn't say which; to choose one, use an OpenAI API key": "ChatGPT 的生图后端自己决定用哪个 GPT Image 版本,也不告诉是哪个;要自己选版本,请用 OpenAI API Key",
|
||||
"ChatGPT picks the model": "ChatGPT 自己决定模型",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.": "用 Magpie 设置的生图模型(设置 → 图像)生成和编辑图片,并可用 Magpie 里配置的视频模型(Grok Imagine、Seedance)生成短视频,保存在项目目录。",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Models → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.": "用 Magpie 设置的生图模型(设置 → 模型 → 图像)生成和编辑图片,并可用 Magpie 里配置的视频模型(Grok Imagine、Seedance)生成短视频,保存在项目目录。",
|
||||
"Use your own browser: your tabs, signed in to the sites you use. Open pages, click, type, upload, read and take screenshots, through the Magpie Browser extension.": "使用你自己的浏览器:你的标签页,登录着你常用的网站。通过 Magpie Browser 扩展打开网页、点击、输入、上传、读取和截图。",
|
||||
"Observability": "可观测性",
|
||||
"OTLP export": "OTLP 导出",
|
||||
@@ -1728,7 +1728,7 @@ const I18N = {
|
||||
"{n} image model": "{n} 个图像模型",
|
||||
"{n} image models": "{n} 个图像模型",
|
||||
"Image models": "图像模型",
|
||||
"Settings → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models.": "设置 → 图像 只列出已勾选的。Agent 不与它们对话,故不在模型列表中。",
|
||||
"Settings → Models → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models.": "设置 → 模型 → 图像 只列出已勾选的。Agent 不与它们对话,故不在模型列表中。",
|
||||
"Video models": "视频模型",
|
||||
"Only the ticked ones are offered when making a video. Agents don't chat with these, so they aren't among its models.": "生成视频时只提供已勾选的。Agent 不与它们对话,故不在模型列表中。",
|
||||
"{model}, picked here, is unticked in its provider's Image models: it still draws, but leaves this list once another is picked. Tick it there to keep it listed.": "{model} 是此处选中的,但在其供应商的“图像模型”中未勾选:它仍用于生图,改选其他模型后便不再列在这里。在那里勾选它即可留在列表中。",
|
||||
@@ -2714,7 +2714,7 @@ const I18N = {
|
||||
"Show the other {n}": "显示其余 {n} 个",
|
||||
"Added by hand": "手动添加",
|
||||
"The vendor's list is empty. Fetch models again, or type a model id.": "供应商列表为空。重新获取模型,或输入一个模型 ID。",
|
||||
"No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Images.": "没有匹配“{q}”的模型。生图、向量和语音模型无法对话,不在此列出;生图模型请在 设置 → 图像 中选择。",
|
||||
"No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Models → Images.": "没有匹配“{q}”的模型。生图、向量和语音模型无法对话,不在此列出;生图模型请在 设置 → 模型 → 图像 中选择。",
|
||||
"add a model id…": "添加模型 ID…",
|
||||
"Add model": "添加模型",
|
||||
"Add a model the list doesn't have, by its id (several: comma separated)": "按 ID 添加列表里没有的模型(多个用逗号分隔)",
|
||||
@@ -5932,7 +5932,7 @@ const I18N = {
|
||||
"no images generated": "不生成圖片",
|
||||
"ChatGPT's image backend picks the GPT Image version itself and doesn't say which; to choose one, use an OpenAI API key": "ChatGPT 的生圖後端自己決定用哪個 GPT Image 版本,也不告訴是哪個;要自己選版本,請用 OpenAI API Key",
|
||||
"ChatGPT picks the model": "ChatGPT 自己決定模型",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.": "用 Magpie 設定的生圖模型(設定 → 影像)生成和編輯圖片,並可用 Magpie 裡設定的影片模型(Grok Imagine、Seedance)生成短影片,儲存在專案目錄。",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Models → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.": "用 Magpie 設定的生圖模型(設定 → 模型 → 影像)生成和編輯圖片,並可用 Magpie 裡設定的影片模型(Grok Imagine、Seedance)生成短影片,儲存在專案目錄。",
|
||||
"Use your own browser: your tabs, signed in to the sites you use. Open pages, click, type, upload, read and take screenshots, through the Magpie Browser extension.": "使用你自己的瀏覽器:你的分頁,登入著你常用的網站。透過 Magpie Browser 擴充功能開啟網頁、點擊、輸入、上傳、讀取和截圖。",
|
||||
"Observability": "可觀測性",
|
||||
"OTLP export": "OTLP 匯出",
|
||||
@@ -6492,7 +6492,7 @@ const I18N = {
|
||||
"{n} image model": "{n} 個影像模型",
|
||||
"{n} image models": "{n} 個影像模型",
|
||||
"Image models": "影像模型",
|
||||
"Settings → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models.": "設定 → 影像 只列出已勾選的。Agent 不與它們對話,故不在模型列表中。",
|
||||
"Settings → Models → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models.": "設定 → 模型 → 影像 只列出已勾選的。Agent 不與它們對話,故不在模型列表中。",
|
||||
"Video models": "影片模型",
|
||||
"Only the ticked ones are offered when making a video. Agents don't chat with these, so they aren't among its models.": "生成影片時只提供已勾選的。Agent 不與它們對話,故不在模型列表中。",
|
||||
"{model}, picked here, is unticked in its provider's Image models: it still draws, but leaves this list once another is picked. Tick it there to keep it listed.": "{model} 是此處選取的,但在其供應商的「影像模型」中未勾選:它仍用於生圖,改選其他模型後便不再列在這裡。在那裡勾選它即可留在列表中。",
|
||||
@@ -7454,7 +7454,7 @@ const I18N = {
|
||||
"Show the other {n}": "顯示其餘 {n} 個",
|
||||
"Added by hand": "手動新增",
|
||||
"The vendor's list is empty. Fetch models again, or type a model id.": "供應商列表為空。重新取得模型,或輸入一個模型 ID。",
|
||||
"No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Images.": "沒有匹配「{q}」的模型。生圖、向量和語音模型無法對話,不在此列出;生圖模型請在 設定 → 影像 中選擇。",
|
||||
"No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Models → Images.": "沒有匹配「{q}」的模型。生圖、向量和語音模型無法對話,不在此列出;生圖模型請在 設定 → 模型 → 影像 中選擇。",
|
||||
"add a model id…": "新增模型 ID…",
|
||||
"Add model": "新增模型",
|
||||
"Add a model the list doesn't have, by its id (several: comma separated)": "按 ID 新增列表裡沒有的模型(多個用逗號分隔)",
|
||||
@@ -10676,7 +10676,7 @@ const I18N = {
|
||||
"no images generated": "画像を生成しない",
|
||||
"ChatGPT's image backend picks the GPT Image version itself and doesn't say which; to choose one, use an OpenAI API key": "ChatGPT の画像生成バックエンドは GPT Image のバージョンを自分で選び、どれを使ったかは返しません。バージョンを選ぶには OpenAI API キーを使ってください",
|
||||
"ChatGPT picks the model": "モデルは ChatGPT が選択",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.": "Magpie で設定した画像モデル(設定 → 画像)で画像を生成・編集し、Magpie で設定した動画モデル(Grok Imagine、Seedance)で短い動画を作成します。プロジェクトに保存されます。",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Models → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.": "Magpie で設定した画像モデル(設定 → モデル → 画像)で画像を生成・編集し、Magpie で設定した動画モデル(Grok Imagine、Seedance)で短い動画を作成します。プロジェクトに保存されます。",
|
||||
"Use your own browser: your tabs, signed in to the sites you use. Open pages, click, type, upload, read and take screenshots, through the Magpie Browser extension.": "いつものブラウザを使います:あなたのタブで、普段のサイトにサインインしたまま。Magpie Browser 拡張機能を通じて、ページを開き、クリック、入力、アップロード、読み取り、スクリーンショットを行います。",
|
||||
"Observability": "オブザーバビリティ",
|
||||
"OTLP export": "OTLP エクスポート",
|
||||
@@ -11230,7 +11230,7 @@ const I18N = {
|
||||
"{n} image model": "{n} 件の画像モデル",
|
||||
"{n} image models": "{n} 件の画像モデル",
|
||||
"Image models": "画像モデル",
|
||||
"Settings → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models.": "設定 → 画像 にはチェックしたものだけが表示されます。エージェントはこれらと会話しないため、モデル一覧には含まれません。",
|
||||
"Settings → Models → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models.": "設定 → モデル → 画像 にはチェックしたものだけが表示されます。エージェントはこれらと会話しないため、モデル一覧には含まれません。",
|
||||
"Video models": "動画モデル",
|
||||
"Only the ticked ones are offered when making a video. Agents don't chat with these, so they aren't among its models.": "動画を作るときは、チェックしたものだけが候補になります。エージェントはこれらと会話しないため、モデル一覧には含まれません。",
|
||||
"{model}, picked here, is unticked in its provider's Image models: it still draws, but leaves this list once another is picked. Tick it there to keep it listed.": "ここで選んだ {model} は、プロバイダの「画像モデル」でチェックが外されています。描画には引き続き使われますが、別のモデルを選ぶとこの一覧から消えます。一覧に残すには、そちらでチェックしてください。",
|
||||
@@ -12212,7 +12212,7 @@ const I18N = {
|
||||
"Show the other {n}": "残り {n} 個を表示",
|
||||
"Added by hand": "手動で追加",
|
||||
"The vendor's list is empty. Fetch models again, or type a model id.": "ベンダーの一覧が空です。モデルを再取得するか、モデル ID を入力してください。",
|
||||
"No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Images.": "「{q}」に一致するモデルはありません。画像、埋め込み、音声のモデルはエージェントが会話できないため一覧にありません。画像モデルは 設定 → 画像 で選んでください。",
|
||||
"No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Models → Images.": "「{q}」に一致するモデルはありません。画像、埋め込み、音声のモデルはエージェントが会話できないため一覧にありません。画像モデルは 設定 → モデル → 画像 で選んでください。",
|
||||
"add a model id…": "モデル ID を追加…",
|
||||
"Add model": "モデルを追加",
|
||||
"Add a model the list doesn't have, by its id (several: comma separated)": "一覧にないモデルを ID で追加します(複数の場合はカンマ区切り)",
|
||||
@@ -15435,7 +15435,7 @@ const I18N = {
|
||||
"no images generated": "keine Bilderzeugung",
|
||||
"ChatGPT's image backend picks the GPT Image version itself and doesn't say which; to choose one, use an OpenAI API key": "Das Bild-Backend von ChatGPT wählt die GPT-Image-Version selbst und sagt nicht, welche; um eine zu wählen, nimm einen OpenAI-API-Schlüssel",
|
||||
"ChatGPT picks the model": "ChatGPT wählt das Modell",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.": "Bilder mit dem in Magpie festgelegten Bildmodell (Einstellungen → Bilder) erzeugen und bearbeiten sowie kurze Videos mit einem in Magpie eingerichteten Videomodell (Grok Imagine, Seedance) erstellen, gespeichert im Projekt.",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Models → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.": "Bilder mit dem in Magpie festgelegten Bildmodell (Einstellungen → Modelle → Bilder) erzeugen und bearbeiten sowie kurze Videos mit einem in Magpie eingerichteten Videomodell (Grok Imagine, Seedance) erstellen, gespeichert im Projekt.",
|
||||
"Use your own browser: your tabs, signed in to the sites you use. Open pages, click, type, upload, read and take screenshots, through the Magpie Browser extension.": "Deinen eigenen Browser nutzen: deine Tabs, angemeldet bei den Seiten, die du nutzt. Seiten öffnen, klicken, tippen, hochladen, lesen und Screenshots machen – über die Erweiterung Magpie Browser.",
|
||||
"Observability": "Observability",
|
||||
"OTLP export": "OTLP-Export",
|
||||
@@ -15999,7 +15999,7 @@ const I18N = {
|
||||
"{n} image model": "{n} Bildmodell",
|
||||
"{n} image models": "{n} Bildmodelle",
|
||||
"Image models": "Bildmodelle",
|
||||
"Settings → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models.": "Einstellungen → Bilder listet die angehakten. Agenten chatten nicht mit diesen Modellen, daher stehen sie nicht bei seinen Modellen.",
|
||||
"Settings → Models → Images lists the ticked ones. Agents don't chat with these, so they aren't among its models.": "Einstellungen → Modelle → Bilder listet die angehakten. Agenten chatten nicht mit diesen Modellen, daher stehen sie nicht bei seinen Modellen.",
|
||||
"Video models": "Videomodelle",
|
||||
"Only the ticked ones are offered when making a video. Agents don't chat with these, so they aren't among its models.": "Beim Erstellen eines Videos werden nur die angehakten angeboten. Agenten chatten nicht mit diesen Modellen, daher stehen sie nicht bei seinen Modellen.",
|
||||
"{model}, picked here, is unticked in its provider's Image models: it still draws, but leaves this list once another is picked. Tick it there to keep it listed.": "{model}, hier gewählt, ist bei den Bildmodellen seines Anbieters abgehakt: Es zeichnet weiter, verschwindet aber aus dieser Liste, sobald ein anderes gewählt ist. Haken Sie es dort an, damit es gelistet bleibt.",
|
||||
@@ -16981,7 +16981,7 @@ const I18N = {
|
||||
"Show the other {n}": "Die übrigen {n} anzeigen",
|
||||
"Added by hand": "Manuell hinzugefügt",
|
||||
"The vendor's list is empty. Fetch models again, or type a model id.": "Die Liste des Anbieters ist leer. Rufen Sie die Modelle erneut ab oder geben Sie eine Modell-ID ein.",
|
||||
"No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Images.": "Kein Modell hier passt zu „{q}“. Bild-, Embedding- und Sprachmodelle werden nicht aufgeführt, da Agenten nicht mit ihnen chatten können: Wählen Sie ein Bildmodell unter Einstellungen → Bilder.",
|
||||
"No model here matches “{q}”. Image, embedding and speech models aren't listed, as agents can't chat with them: pick an image model in Settings → Models → Images.": "Kein Modell hier passt zu „{q}“. Bild-, Embedding- und Sprachmodelle werden nicht aufgeführt, da Agenten nicht mit ihnen chatten können: Wählen Sie ein Bildmodell unter Einstellungen → Modelle → Bilder.",
|
||||
"add a model id…": "Modell-ID hinzufügen…",
|
||||
"Add model": "Modell hinzufügen",
|
||||
"Add a model the list doesn't have, by its id (several: comma separated)": "Ein Modell, das in der Liste fehlt, über seine ID hinzufügen (mehrere: kommagetrennt)",
|
||||
|
||||
@@ -6713,7 +6713,7 @@ magpie.plugin("library", (ctx) => {
|
||||
ed.append(hint);
|
||||
} else if (x.name === "magpie-vision") {
|
||||
ed.append(el("p", "mk-hint", t("Pick the agents that may read images with it: each image goes to the Image recognition model set in Settings → Models → Images, and costs what that model charges.")));
|
||||
} else if (x.optIn) ed.append(el("p", "mk-hint", t("Pick the agents that may generate images: each image costs what the model set in Settings → Images charges.")));
|
||||
} else if (x.optIn) ed.append(el("p", "mk-hint", t("Pick the agents that may generate images: each image costs what the model set in Settings → Models → Images charges.")));
|
||||
// one of magpie's own that can't answer yet says why, and is added all
|
||||
// the same: it answers once that is set up, its tools saying how
|
||||
if (x.unready) ed.append(el("p", "mk-hint mk-unready", t(x.unready)));
|
||||
|
||||
@@ -174,7 +174,7 @@ magpie.strings({
|
||||
"The copy in {agents} differs from the library's skill. Click to copy it again.": "{agents} 里的副本和资源库里的 Skill 不一样了。点一下重新复制。",
|
||||
"Copies updated": "副本已更新",
|
||||
"It will be removed from the library and the agents it was given to.": "这将从资源库及使用它的 Agent 中移除它。",
|
||||
"Pick the agents that may generate images: each image costs what the model set in Settings → Images charges.": "选择可以生图的 Agent:每张图按 设置 → 图像 里所选模型的价格计费。",
|
||||
"Pick the agents that may generate images: each image costs what the model set in Settings → Models → Images charges.": "选择可以生图的 Agent:每张图按 设置 → 模型 → 图像 里所选模型的价格计费。",
|
||||
"Pick the agents that may search with it: each search goes where Settings → Models → Web search sends it, and costs what that charges.": "选择可以用它搜索的 Agent:每次搜索都交给 设置 → 模型 → 网页搜索 所设的搜索,按其价格计费。",
|
||||
"Pick the agents that may read images with it: each image goes to the Image recognition model set in Settings → Models → Images, and costs what that model charges.": "选择可以用它识图的 Agent:每张图都交给 设置 → 模型 → 图像 里所设的识图模型,按该模型的价格计费。",
|
||||
"Not set up yet": "尚未设置",
|
||||
@@ -1021,7 +1021,7 @@ magpie.strings({
|
||||
"The copy in {agents} differs from the library's skill. Click to copy it again.": "{agents} 裡的副本和資源庫裡的 Skill 不一樣了。點一下重新複製。",
|
||||
"Copies updated": "副本已更新",
|
||||
"It will be removed from the library and the agents it was given to.": "這將從資源庫及使用它的 Agent 中移除它。",
|
||||
"Pick the agents that may generate images: each image costs what the model set in Settings → Images charges.": "選擇可以生圖的 Agent:每張圖按 設定 → 影像 裡所選模型的價格計費。",
|
||||
"Pick the agents that may generate images: each image costs what the model set in Settings → Models → Images charges.": "選擇可以生圖的 Agent:每張圖按 設定 → 模型 → 影像 裡所選模型的價格計費。",
|
||||
"Pick the agents that may search with it: each search goes where Settings → Models → Web search sends it, and costs what that charges.": "選擇可以用它搜尋的 Agent:每次搜尋都交給 設定 → 模型 → 網頁搜尋 所設的搜尋,按其價格計費。",
|
||||
"Pick the agents that may read images with it: each image goes to the Image recognition model set in Settings → Models → Images, and costs what that model charges.": "選擇可以用它識圖的 Agent:每張圖都交給 設定 → 模型 → 影像 裡所設的識圖模型,按該模型的價格計費。",
|
||||
"Not set up yet": "尚未設定",
|
||||
@@ -1859,7 +1859,7 @@ magpie.strings({
|
||||
"Copy out of date": "コピーが古い",
|
||||
"The copy in {agents} differs from the library's skill. Click to copy it again.": "{agents} のコピーがライブラリのスキルと異なります。クリックしてコピーし直します。",
|
||||
"Copies updated": "コピーを更新しました",
|
||||
"Pick the agents that may generate images: each image costs what the model set in Settings → Images charges.": "画像を生成できるエージェントを選んでください:画像 1 枚ごとに、設定 → 画像 で選んだモデルの料金がかかります。",
|
||||
"Pick the agents that may generate images: each image costs what the model set in Settings → Models → Images charges.": "画像を生成できるエージェントを選んでください:画像 1 枚ごとに、設定 → モデル → 画像 で選んだモデルの料金がかかります。",
|
||||
"Pick the agents that may search with it: each search goes where Settings → Models → Web search sends it, and costs what that charges.": "これで検索できるエージェントを選んでください:検索はそれぞれ 設定 → モデル → Web 検索 の送り先に送られ、その料金がかかります。",
|
||||
"Pick the agents that may read images with it: each image goes to the Image recognition model set in Settings → Models → Images, and costs what that model charges.": "これで画像を読み取れるエージェントを選んでください:画像はそれぞれ 設定 → モデル → 画像 で設定した画像認識モデルに送られ、そのモデルの料金がかかります。",
|
||||
"Not set up yet": "未設定",
|
||||
@@ -2702,7 +2702,7 @@ magpie.strings({
|
||||
"Copy out of date": "Kopie veraltet",
|
||||
"The copy in {agents} differs from the library's skill. Click to copy it again.": "Die Kopie in {agents} weicht vom Skill der Bibliothek ab. Klicken, um sie neu zu kopieren.",
|
||||
"Copies updated": "Kopien aktualisiert",
|
||||
"Pick the agents that may generate images: each image costs what the model set in Settings → Images charges.": "Agenten wählen, die Bilder erzeugen dürfen: jedes Bild kostet, was das unter Einstellungen → Bilder festgelegte Modell berechnet.",
|
||||
"Pick the agents that may generate images: each image costs what the model set in Settings → Models → Images charges.": "Agenten wählen, die Bilder erzeugen dürfen: jedes Bild kostet, was das unter Einstellungen → Modelle → Bilder festgelegte Modell berechnet.",
|
||||
"Pick the agents that may search with it: each search goes where Settings → Models → Web search sends it, and costs what that charges.": "Agenten wählen, die damit suchen dürfen: Jede Suche geht dorthin, wohin Einstellungen → Modelle → Websuche sie schickt, und kostet, was das kostet.",
|
||||
"Pick the agents that may read images with it: each image goes to the Image recognition model set in Settings → Models → Images, and costs what that model charges.": "Agenten wählen, die damit Bilder lesen dürfen: Jedes Bild geht an das unter Einstellungen → Modelle → Bilder eingestellte Bilderkennungsmodell und kostet, was dieses Modell berechnet.",
|
||||
"Not set up yet": "Noch nicht eingerichtet",
|
||||
|
||||
@@ -7431,7 +7431,7 @@ function routingPage(part) {
|
||||
// free: the vendor's word, zero: listed at $0 there (jiangguochao666 on X)
|
||||
const ref = (x) => ({ value: x.id, label: x.name || x.id, note: noted(x.providerName, x.id), icon: x.icon, group: x.providerName, ref: x.id, context: x.context, free: x.free, zero: x.zero });
|
||||
// the image models after them, said as such (jzw690 on X): a group
|
||||
// of them is picked in Settings › Images, or named at the images API
|
||||
// of them is picked in Settings › Models › Images, or named at the images API
|
||||
const drawRef = (x) => ({ ...ref(x), note: noted(`${x.providerName} · ${t("Image model")}`, x.id) });
|
||||
const options = [...subs, ...(decides ? [] : groups.models.map(ref)), ...(decides ? [] : (groups.drawers || []).map(drawRef)), ...(chats ? [] : (groups.deciders || []).map(ref))];
|
||||
// the member a model is in the group as: itself, or with its
|
||||
|
||||
@@ -12,7 +12,7 @@ import (
|
||||
// jzw690 on X: the group editor's "Add a model" offers a provider's
|
||||
// image models (its live list's gpt-image-2) beside its chat models, as
|
||||
// drawers apart from them; a group holding one, from a provider whose
|
||||
// picks leave it out, shows it ready, and Settings › Images offers that
|
||||
// picks leave it out, shows it ready, and Settings › Models › Images offers that
|
||||
// group. One unticked in its provider's editor isn't offered, unless a
|
||||
// group names it already.
|
||||
func TestGroupEditorOffersImageModels(t *testing.T) {
|
||||
@@ -71,6 +71,6 @@ func TestGroupEditorOffersImageModels(t *testing.T) {
|
||||
}
|
||||
}
|
||||
if !slices.ContainsFunc(settingsState().ImageGenModels, func(m modelRef) bool { return m.ID == "group/pix-images" }) {
|
||||
t.Fatal("Settings › Images doesn't offer the group")
|
||||
t.Fatal("Settings › Models › Images doesn't offer the group")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -333,7 +333,7 @@ func groupsState() groupsJSON {
|
||||
out.Models = append(out.Models, servedRef(e, set))
|
||||
}
|
||||
}
|
||||
// the image models, as Settings › Images lists them: each provider's
|
||||
// the image models, as Settings › Models › Images lists them: each provider's
|
||||
// Drawers less those unticked in its editor, but one a group names
|
||||
// already, so its card still reads it. draws: every one, an unticked
|
||||
// one included, which draws all the same
|
||||
|
||||
@@ -12,7 +12,7 @@ import (
|
||||
"github.com/yetone/magpie/internal/settings"
|
||||
)
|
||||
|
||||
// #1865: Settings › Images lists a ChatGPT account's one GPT Image, marked
|
||||
// #1865: Settings › Models › Images lists a ChatGPT account's one GPT Image, marked
|
||||
// as the vendor's pick, and a gpt-image-2.5 saved when it was listed shows
|
||||
// as that entry while the saved value is kept as it is.
|
||||
func TestImageGenCodexOneEntry(t *testing.T) {
|
||||
|
||||
@@ -8,7 +8,7 @@ import (
|
||||
"github.com/yetone/magpie/internal/settings"
|
||||
)
|
||||
|
||||
// 7up6666 on X: Settings › Images offers each routing group with a member
|
||||
// 7up6666 on X: Settings › Models › Images offers each routing group with a member
|
||||
// that draws, under the group's name with no provider of its own (the
|
||||
// picker puts it with Routing groups); a group of chat models only isn't
|
||||
// offered, and a picked group none of whose members draws is said missing.
|
||||
|
||||
@@ -15,7 +15,7 @@ import (
|
||||
|
||||
// 321sssrt on X: image models unticked in a provider's editor are saved
|
||||
// as HiddenDrawers, kept by a Save that leaves them out and cleared by [];
|
||||
// Settings › Images leaves them out, except the one picked there, which
|
||||
// Settings › Models › Images leaves them out, except the one picked there, which
|
||||
// stays listed as picked with the row saying it is hidden.
|
||||
func TestImageModelsHidden(t *testing.T) {
|
||||
t.Setenv("HOME", t.TempDir())
|
||||
@@ -63,7 +63,7 @@ func TestImageModelsHidden(t *testing.T) {
|
||||
t.Fatalf("saved %v", got)
|
||||
}
|
||||
if got := listed(); !slices.Equal(got, []string{"pics/img-b"}) {
|
||||
t.Fatalf("Settings › Images lists %v", got)
|
||||
t.Fatalf("Settings › Models › Images lists %v", got)
|
||||
}
|
||||
if settingsState().ImageGenHidden {
|
||||
t.Fatal("hidden note with nothing hidden picked")
|
||||
|
||||
@@ -1104,7 +1104,7 @@ func providerInfoWith(p provider.Provider, ls provider.Listing, agents []agentUs
|
||||
}
|
||||
}
|
||||
// its image models aren't among those agents chat with; the editor
|
||||
// lists them apart, as Settings → Images is where one is picked
|
||||
// lists them apart, as Settings → Models → Images is where one is picked
|
||||
for _, m := range gateway.DrawersOf(p, func() []catalog.Model { return ls.Available }) {
|
||||
out.DrawIDs = append(out.DrawIDs, m.ID)
|
||||
if m.Name != "" && m.Name != m.ID {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Run with Node's test runner and Playwright on the module path; see README.md.
|
||||
// jzw690 on X: a group's Add a model picker didn't list the providers'
|
||||
// image models, so a group of them, to pick in Settings › Images, couldn't
|
||||
// image models, so a group of them, to pick in Settings › Models › Images, couldn't
|
||||
// be made.
|
||||
// - The picker offers each image model in /api/groups' drawers, its note
|
||||
// saying it is one; a click adds it, and its row says so and offers no
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
// 321sssrt on X: "openai有几十个图片模型,我没办法像是llm一样屏蔽他们". A
|
||||
// provider's editor listed its image models as plain chips nothing could
|
||||
// change. Now each is ticked, a click unticks it (and ticks it back), and
|
||||
// Save writes the unticked ones as hiddenDrawers, which Settings › Images
|
||||
// then leaves out. A pick in Settings › Images that was unticked since
|
||||
// Save writes the unticked ones as hiddenDrawers, which Settings › Models › Images
|
||||
// then leaves out. A pick in Settings › Models › Images that was unticked since
|
||||
// still draws, and its row says so and how to keep it listed. Every
|
||||
// language, wide and at a phone's width; the API is faked here.
|
||||
const assert = require("node:assert/strict");
|
||||
@@ -74,11 +74,11 @@ function serve(lang, saves, cur) {
|
||||
}
|
||||
|
||||
const words = {
|
||||
en: { save: "Save", field: "Image models", hint: /Settings → Images lists the ticked ones/, note: [/dall-e-3 · OpenAI, picked here, is unticked/, /it still draws/] },
|
||||
zh: { save: "保存", field: "图像模型", hint: /设置 → 图像 只列出已勾选的/, note: [/dall-e-3 · OpenAI 是此处选中的/, /它仍用于生图/] },
|
||||
"zh-TW": { save: "儲存", field: "影像模型", hint: /設定 → 影像 只列出已勾選的/, note: [/dall-e-3 · OpenAI 是此處選取的/, /它仍用於生圖/] },
|
||||
ja: { save: "保存", field: "画像モデル", hint: /設定 → 画像 にはチェックしたものだけ/, note: [/ここで選んだ dall-e-3 · OpenAI は/, /描画には引き続き使われます/] },
|
||||
de: { save: "Speichern", field: "Bildmodelle", hint: /Einstellungen → Bilder listet die angehakten/, note: [/dall-e-3 · OpenAI, hier gewählt, ist/, /Es zeichnet weiter/] },
|
||||
en: { save: "Save", field: "Image models", hint: /Settings → Models → Images lists the ticked ones/, note: [/dall-e-3 · OpenAI, picked here, is unticked/, /it still draws/] },
|
||||
zh: { save: "保存", field: "图像模型", hint: /设置 → 模型 → 图像 只列出已勾选的/, note: [/dall-e-3 · OpenAI 是此处选中的/, /它仍用于生图/] },
|
||||
"zh-TW": { save: "儲存", field: "影像模型", hint: /設定 → 模型 → 影像 只列出已勾選的/, note: [/dall-e-3 · OpenAI 是此處選取的/, /它仍用於生圖/] },
|
||||
ja: { save: "保存", field: "画像モデル", hint: /設定 → モデル → 画像 にはチェックしたものだけ/, note: [/ここで選んだ dall-e-3 · OpenAI は/, /描画には引き続き使われます/] },
|
||||
de: { save: "Speichern", field: "Bildmodelle", hint: /Einstellungen → Modelle → Bilder listet die angehakten/, note: [/dall-e-3 · OpenAI, hier gewählt, ist/, /Es zeichnet weiter/] },
|
||||
};
|
||||
|
||||
for (const engine of (process.env.BROWSER ? [process.env.BROWSER] : ["chromium", "webkit"])) {
|
||||
@@ -131,7 +131,7 @@ for (const engine of (process.env.BROWSER ? [process.env.BROWSER] : ["chromium",
|
||||
assert.deepEqual(page.errors, []);
|
||||
await page.context().close();
|
||||
});
|
||||
await t.test(`${lang} at ${width}px: Settings › Images says a hidden pick still draws`, async () => {
|
||||
await t.test(`${lang} at ${width}px: Settings › Models › Images says a hidden pick still draws`, async () => {
|
||||
const page = await open(lang, width, "settings&tab=models", [], settingsPayload(lang, { imageGen: "openai/dall-e-3", imageGenHidden: true }));
|
||||
await page.locator("#imageGenRow").waitFor();
|
||||
const note = page.locator("#imageGenRow .image-gen-hidden");
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Run with Node's test runner and Playwright on the module path; see README.md.
|
||||
// #2091 (nailuoGG): under the Essentials preset the Library is switched off
|
||||
// and leaves the window, but Settings › Images' Image generation still said
|
||||
// and leaves the window, but Settings › Models › Images' Image generation still said
|
||||
// "Give an agent the tool from Library → MCP servers → Discover → Magpie
|
||||
// Image", a page that isn't there. The row now says where the tool comes
|
||||
// from as things are: with the Library off it says it is off and offers
|
||||
|
||||
@@ -109,7 +109,7 @@ for (const engine of (process.env.BROWSER ? [process.env.BROWSER] : ["chromium",
|
||||
const hints = await sheet.locator(".mk-hint").allTextContents();
|
||||
assert(hints.includes(w("Pick the agents that may use your browser: they act in your tabs, signed in as you are.")), hints.join(" | "));
|
||||
// not the image server's word about what each image costs
|
||||
assert(!hints.some((h) => h.includes(w("Pick the agents that may generate images: each image costs what the model set in Settings → Images charges."))));
|
||||
assert(!hints.some((h) => h.includes(w("Pick the agents that may generate images: each image costs what the model set in Settings → Models → Images charges."))));
|
||||
|
||||
const box = sheet.locator(".mk-browser");
|
||||
const state = box.locator(".mk-browser-state");
|
||||
|
||||
@@ -9,7 +9,7 @@ import (
|
||||
"github.com/yetone/magpie/internal/settings"
|
||||
)
|
||||
|
||||
// Settings › Images › Video generation lists a custom provider's model the
|
||||
// Settings › Models › Images › Video generation lists a custom provider's model the
|
||||
// user marked a video model (#1399), and none of its others; one unticked
|
||||
// in its editor is left out unless it is the one picked; a pick no longer
|
||||
// marked is said missing, with Automatic's named.
|
||||
|
||||
@@ -1047,7 +1047,7 @@ func (s *server) ask(method string, params any) (json.RawMessage, int, error) {
|
||||
// asked.
|
||||
func (s *server) modelProps() map[string]any {
|
||||
out := map[string]any{
|
||||
tool: map[string]any{"type": "string", "description": "The image model to use, as provider/model. Leave it out to use the one set in Magpie (Settings → Images → Image generation)."},
|
||||
tool: map[string]any{"type": "string", "description": "The image model to use, as provider/model. Leave it out to use the one set in Magpie (Settings → Models → Images → Image generation)."},
|
||||
videoTool: map[string]any{"type": "string", "description": "The video model to use, as provider/model. Leave it out to use the video model set up in Magpie."},
|
||||
}
|
||||
res, _, err := s.ask("tools/list", map[string]any{})
|
||||
|
||||
@@ -195,7 +195,7 @@ func TestGenerateSavesInTheProject(t *testing.T) {
|
||||
func TestGatewayRefusalIsAToolError(t *testing.T) {
|
||||
up := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
w.WriteHeader(400)
|
||||
io.WriteString(w, `{"error":{"message":"no model draws: pick one in Settings → Images → Image generation"}}`)
|
||||
io.WriteString(w, `{"error":{"message":"no model draws: pick one in Settings → Models → Images → Image generation"}}`)
|
||||
}))
|
||||
defer up.Close()
|
||||
s := &server{gateway: up.URL, client: http.DefaultClient, agent: "x", pending: map[string]chan rpc{}}
|
||||
|
||||
@@ -172,12 +172,12 @@ const magpieCommand = "magpie"
|
||||
const selfServerName = "magpie-image"
|
||||
|
||||
// selfServer is magpie's own image generation server: generate_image makes
|
||||
// an image with the model Settings → Images → Image generation names, saved
|
||||
// an image with the model Settings → Models → Images → Image generation names, saved
|
||||
// in the project. It costs what the model does, so it is given only to the
|
||||
// agents picked for it.
|
||||
func selfServer() MarketServer {
|
||||
m := localServer(selfServerName, "Magpie Image", "Magpie", "https://usemagpie.ai/favicon.png", "https://usemagpie.ai",
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.", magpieCommand, []string{"mcp", "image"})
|
||||
"Generate and edit images with the image model set in Magpie (Settings → Models → Images), and make short videos with a video model set up in Magpie (Grok Imagine, Seedance), saved in the project.", magpieCommand, []string{"mcp", "image"})
|
||||
m.OptIn = true
|
||||
return m
|
||||
}
|
||||
|
||||
@@ -620,13 +620,13 @@ type Provider struct {
|
||||
Unlisted bool `json:"unlisted,omitempty"`
|
||||
// HiddenDrawers are the provider's image models the user unticked in
|
||||
// its editor (321sssrt on X: an OpenAI key lists a dozen): left out of
|
||||
// every list one is picked from (Settings › Images, another magpie's
|
||||
// every list one is picked from (Settings › Models › Images, another magpie's
|
||||
// list, Aside's) and of Automatic's choice, as an unticked chat model
|
||||
// is left out of the agents' lists. A deny list beside Models, not in
|
||||
// it: Models is what agents chat with, empty meaning the vendor's list,
|
||||
// so an image model put there would be offered to chat with, and
|
||||
// hiding one would mean picking every chat model. A request that names
|
||||
// one still draws with it, and so does the one Settings › Images
|
||||
// one still draws with it, and so does the one Settings › Models › Images
|
||||
// names: a hidden pick is shown as picked, and said to be hidden.
|
||||
HiddenDrawers []string `json:"hiddenDrawers,omitempty"`
|
||||
// HiddenVideomakers are its video models unticked in its editor, as
|
||||
|
||||
@@ -144,7 +144,7 @@ func videoModel(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
// Settings › Images' video model: a model that makes videos is saved, one
|
||||
// Settings › Models › Images' video model: a model that makes videos is saved, one
|
||||
// that doesn't (a chat model, or none such) is refused, and a save from
|
||||
// another row, which doesn't send it, keeps it.
|
||||
func TestVideoGenCheckedAndKept(t *testing.T) {
|
||||
|
||||
@@ -208,7 +208,7 @@ magpie opencode qwen/qwen3.8-max</pre></div>
|
||||
<ul>
|
||||
<li><b>ストリーミングしない返答。</b>思考する Qwen モデルは DashScope ではストリーミングでしか返答せず、返答をまとめて求めるリクエストは断られます。ツールやルーティンググループの分類器がまとめた返答を求めたとき、magpie は DashScope にストリーミングで求め、思考を含めた返答全体をツールに渡します。</li>
|
||||
<li><b>常に思考するモデル。</b>DashScope の <code>glm-5.3</code> のように、思考をオフにできないモデルがあります。ツールがオフを求めてモデルが断ったとき、magpie は思考をオンのまま聞き直します。</li>
|
||||
<li><b>画像。</b>Qwen-Image と <code>wan2.7-image</code> モデルは DashScope 自身の画像 API で描きます。6 つのプリセットのどれでも使えます。magpie の <span class="ui">設定 → 画像</span> で選びます。サイズは <code>幅x高さ</code> で、最大 2048×2048 です。</li>
|
||||
<li><b>画像。</b>Qwen-Image と <code>wan2.7-image</code> モデルは DashScope 自身の画像 API で描きます。6 つのプリセットのどれでも使えます。magpie の <span class="ui">設定 → モデル → 画像</span> で選びます。サイズは <code>幅x高さ</code> で、最大 2048×2048 です。</li>
|
||||
</ul>
|
||||
|
||||
<h2 id="usage"><a class="anchor" href="#usage">残高と使用量</a></h2>
|
||||
|
||||
@@ -216,7 +216,7 @@ magpie opencode qwen/qwen3.8-max</pre></div>
|
||||
<ul>
|
||||
<li><b>Whole replies.</b> DashScope answers a thinking Qwen model only as a stream, and turns away a request for one whole reply. When an agent or a routing group’s classifier asks for one, magpie asks DashScope for a stream and gives the agent the whole reply, thinking included.</li>
|
||||
<li><b>Models that always think.</b> Some models on DashScope refuse to have thinking turned off, such as its <code>glm-5.3</code>. When an agent asks for it off and the model refuses, magpie asks again with thinking left on.</li>
|
||||
<li><b>Images.</b> The Qwen-Image and <code>wan2.7-image</code> models draw through DashScope’s own image API, on any of the six presets. Choose one in magpie’s <span class="ui">Settings → Images</span>. Give a size as <code>WIDTHxHEIGHT</code>, at most 2048×2048.</li>
|
||||
<li><b>Images.</b> The Qwen-Image and <code>wan2.7-image</code> models draw through DashScope’s own image API, on any of the six presets. Choose one in magpie’s <span class="ui">Settings → Models → Images</span>. Give a size as <code>WIDTHxHEIGHT</code>, at most 2048×2048.</li>
|
||||
</ul>
|
||||
|
||||
<h2 id="usage"><a class="anchor" href="#usage">Balance and usage</a></h2>
|
||||
|
||||
@@ -216,7 +216,7 @@ magpie opencode qwen-cn/qwen3.8-max</pre></div>
|
||||
<ul>
|
||||
<li><b>一次性返回的回复。</b>会思考的千问模型在 DashScope 上只能流式返回,要求一次性返回整个回复的请求会被拒绝。工具或路由分组的分类器要一次性回复时,magpie 向 DashScope 要流式回复,再把完整回复(含思考)交给工具。</li>
|
||||
<li><b>一直思考的模型。</b>DashScope 上有的模型不允许关掉思考,比如它的 <code>glm-5.3</code>。工具要求关掉思考而模型拒绝时,magpie 会保持思考开启再问一次。</li>
|
||||
<li><b>图片。</b>Qwen-Image 和 <code>wan2.7-image</code> 模型通过 DashScope 自己的图片接口生成图片,六个预设都可以。在 magpie 的 <span class="ui">设置 → 图像</span> 里选用。尺寸写成 <code>宽x高</code>,最大 2048×2048。</li>
|
||||
<li><b>图片。</b>Qwen-Image 和 <code>wan2.7-image</code> 模型通过 DashScope 自己的图片接口生成图片,六个预设都可以。在 magpie 的 <span class="ui">设置 → 模型 → 图像</span> 里选用。尺寸写成 <code>宽x高</code>,最大 2048×2048。</li>
|
||||
</ul>
|
||||
|
||||
<h2 id="usage"><a class="anchor" href="#usage">余额与用量</a></h2>
|
||||
|
||||
@@ -1411,7 +1411,7 @@ Qwen Code is one of the agents magpie connects too: its row takes Qwen’s model
|
||||
|
||||
- **Whole replies..** DashScope answers a thinking Qwen model only as a stream, and turns away a request for one whole reply. When an agent or a routing group’s classifier asks for one, magpie asks DashScope for a stream and gives the agent the whole reply, thinking included.
|
||||
- **Models that always think..** Some models on DashScope refuse to have thinking turned off, such as its `glm-5.3`. When an agent asks for it off and the model refuses, magpie asks again with thinking left on.
|
||||
- **Images..** The Qwen-Image and `wan2.7-image` models draw through DashScope’s own image API, on any of the six presets. Choose one in magpie’s Settings → Images. Give a size as `WIDTHxHEIGHT`, at most 2048×2048.
|
||||
- **Images..** The Qwen-Image and `wan2.7-image` models draw through DashScope’s own image API, on any of the six presets. Choose one in magpie’s Settings → Models → Images. Give a size as `WIDTHxHEIGHT`, at most 2048×2048.
|
||||
|
||||
## Balance and usage
|
||||
|
||||
|
||||
Reference in New Issue
Block a user