You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
RFC: a sanctioned, capped model call for plugins #517
A feature plugin has no way to make a model call of its own; #450 notes the codebase has no such pattern, so model-based work in a plugin either is not done or reaches into the host.
Expected behavior
flybot.model.ask({ prompt, system?, maxTokens?, model? }) resolves { ok: true, text } or { ok: false, code }.
Off by default: the host names trusted plugins in flybot.modelPlugins; an unnamed plugin gets not-allowed.
Capped: input/system length, output tokens and calls-per-minute.
Streams through the host's own model selection; text only (no side effect on Bots/rooms/memory); a short code, never provider text; refused on a read-only host.
Change scope
New core/src/host/plugin-model.js; core/src/host/hooks.js (one exposure line per scope); core/types/flybot.d.ts; tests core/test/plugin-model.test.js + a case in core/test/flybot.test.js; docs/subsystems/plugin-runtime.md. No new dependency; nothing calls a model unless the deployment opts in.
Why
A platform capability a plugin ecosystem needs (a plugin that can reason a little), and the seam #450 asks for. First intended use: the tree's model-based clustering (#450 item 2). This PR ships only the seam so the shape can be reviewed alone.
Triage (2026-10-20 16:05 Asia/Shanghai): HugoXK's PR #518 implements this RFC — flybot.model.ask, allow-list flybot.modelPlugins (empty by default), input/output/rate caps, text-only / short error codes, refused on read-only hosts. First consumer intended: tree model clustering (#519/#520).
Labeled enhancement + area:automation + needs-human. Not applying agent-ready — this is an external design PR; owner should accept (or revise) the API shape before merge.
Fork CI was action_required (0 checks / BLOCKED); workflows approved just now so Test should run.
Confirmation item: accept the flybot.model.ask API design in HugoXK #518 (allow-list + caps + text-only) as the #450 plugin model seam?
Closed as implemented: PR #518 ("Add a sanctioned, capped model call for plugins") merged into main as ce7881c6. The host seam, the cap and the plugin-side call the RFC asked for are in main now; any further design change belongs in a new issue.
Activity
Birfy commentedon Oct 20, 2026
Triage (2026-10-20 16:05 Asia/Shanghai): HugoXK's PR #518 implements this RFC —
flybot.model.ask, allow-listflybot.modelPlugins(empty by default), input/output/rate caps, text-only / short error codes, refused on read-only hosts. First consumer intended: tree model clustering (#519/#520).Labeled
enhancement+area:automation+ needs-human. Not applyingagent-ready— this is an external design PR; owner should accept (or revise) the API shape before merge.Fork CI was
action_required(0 checks / BLOCKED); workflows approved just now so Test should run.Confirmation item: accept the
flybot.model.askAPI design in HugoXK #518 (allow-list + caps + text-only) as the #450 plugin model seam?Birfy commentedon Oct 20, 2026
Triage: still
needs-human— the design questions in this RFC (what the model may be asked, caching, caps) are the owner's call.An implementation is already open as PR #518, so after that PR is approved and merged this RFC can be closed as implemented.
Birfy commentedon Oct 20, 2026
Closed as implemented: PR #518 ("Add a sanctioned, capped model call for plugins") merged into
mainasce7881c6. The host seam, the cap and the plugin-side call the RFC asked for are inmainnow; any further design change belongs in a new issue.