Skip to content

[Feat] Add Fastino GLiDE as a served System One decision backend - #133

Open
Birfy wants to merge 1 commit into
mainfrom
issue-129-glide
Open

Birfy wants to merge 1 commit into
mainfrom
issue-129-glide

Conversation

@Birfy

@Birfy Birfy commented Nov 25, 2026

Copy link
Copy Markdown
Collaborator

Required human contributor answers

Per the repo owner's (Danyang, @Birfy) standing instruction, these are filled from the issue (#129) instead of waiting for separate human answers.

  1. What outcome are you trying to achieve?

    Answer: Agents can call Fastino GLiDE as a served System One decision model over HTTP (--model glide) for text, and for screenshots when the observation has images, without loading weights in process ([Feat] Add Fastino GLiDE as a served System One decision backend #129).

  2. What is the highest-leverage variable for that outcome?

    Answer: Whether the HTTP body matches the official Fastino / local glide.server schema (model required, state, named questions, hosted store: false) with GLiDE's state image parts (not Clef images or OneJev media), X-API-Key auth, and Fastino retries (425 / 429 / 503), failing closed on a missing URL/key or a bad body — without inventing a second unused shaping layer or a score path our interface does not have.

  3. How will this work move that variable rather than create busywork?

    Answer: It adds a dedicated served adapter (same shape as clm / onejev / clef): one deadline per decision, provenance (url, request_id, served model name, usage, path), and contract tests against a stub server so CI does not call Fastino or a GPU.

  4. Who is the customer or user, and what do they actually need?

    Answer: People who want --model glide against hosted Fastino or a local glide.server for choice/noul decisions, including optional screenshots, without waiting for a live qualification run.

After answering the four questions: is a PR needed at all to achieve this outcome?

Human decision and rationale (or explicit source reference): Yes; #129 proposes this adapter as the scope of one PR and distinguishes "adapter wired" from "qualified on this checkpoint and path".

For a bug fix: link actual observed failure evidence.

Evidence: Not a bug fix: a new served backend (#129).

Why

system1-agents has no --model glide. GLiDE cannot ride the existing jev client unchanged: auth is X-API-Key, the request model must be fastino/GLiDE (values with / are rejected as OpenRouter ids on the TypeSafe path), hosted requests default to store: true, retries include 425 model_warming, and images are state image_url parts. Closes #129.

How

Start with s1a/decision_models/glide.py, then factory.py and the fronts, and tests/test_decision_models_glide.py.

  • --model glide → GlideModel.from_env(): GLIDE_URL (local /v1/systemone) or FASTINO_API_KEY (hosted https://api.fastino.ai/v1/systemone). GLIDE_URL wins when both are set. GLIDE_MODEL defaults to fastino/GLiDE. Optional GLIDE_API_KEY / GLIDE_TIMEOUT_S.
  • Hosted auth is X-API-Key (not Bearer). Hosted evals send store: false.
  • Question bodies reuse jev_question (instructions as a JSON object, which Fastino accepts). An empty instructions object becomes a short fallback string (Fastino rejects empty instructions). Browser element rows in choice criteria are flattened to description strings.
  • Screenshots become state image_url data-URL parts (JPEG/PNG/GIF/WebP, max 4, 3.75 MiB each). A text observation still runs. No images, media, or videos fields.
  • Retries: one transport / 502 / 504 retry, plus bounded Fastino 425 / 429 / 503 retries that respect Retry-After within the decision deadline.
  • raw keeps served_by (including path: local or hosted), url, request_id, server_timing, optional Fastino retention / request-id headers, and sent_images digests (never image bytes). The hosted response model name is glide.
  • Registered in DECISION_MODEL_NAMES and on the tool, browser, rails, CLI decide/probe, and MCP decide fronts (GLiDE is text-capable; images are optional).
  • score questions are unsupported on our interface and are not sent. Weights are under the Fastino Community License and are not vendored.

What

  • New env vars GLIDE_URL, FASTINO_API_KEY, GLIDE_MODEL, GLIDE_API_KEY, GLIDE_TIMEOUT_S in docs/configuration.md and .env.example.
  • Docs: docs/decision-models.md (backend row + optional smoke recipe), docs/capabilities.md (adapter wired vs not qualified; no Decision Index / Artificial Analysis figures copied as ours), docs/agents.md, docs/architecture.md.
  • NOTICE / THIRD_PARTY_LICENSES for GLiDE (Community License; weights not vendored).
  • CHANGELOG Unreleased entry.

Verification

  • ruff format --check . && ruff check . && ty check: all clean (run with the box's existing dev environment; this box was out of inodes so a fresh uv sync could not be completed here)
  • pytest -q and scripts/smoke.sh: 1406 passed, 134 skipped, 270 subtests passed; smoke OK
  • CHANGELOG.md and the docs say what the code does now

Offline tests cover the text path (no images/media/videos/store on the local path), hosted X-API-Key + store: false, screenshot state image parts, Fastino header provenance, more than 4 images, oversize / empty / unknown media types, transport error (after retry), malformed answers, HTTP 500 / 422, 425/429/503 retry-after, one decision deadline across the permitted retry, from_env / build_model (local vs hosted, local URL wins), and front registration.

Demo / evidence

  • Video link, or exemption/blocker with follow-up: exempt for this PR — [Feat] Add Fastino GLiDE as a served System One decision backend #129 distinguishes "adapter wired" from "qualified"; acceptance is CI-complete with a stub server. No Fastino key or local GLiDE server was available on this box, so no live Fastino or GPU run was performed and nothing was invented under docs/results/. Hardware / path qualification remains unmarked in the capability matrix until a pinned run lands.
  • Application/task → agent actions → independently checked result: not recorded (no live path).
  • System1-Agents / System1-Omni commits, checkpoint and worker/frontend provenance: Agents branch issue-129-glide at 4823999; no System1-Omni involved (hosted Fastino or a local glide.server).

Closes #129. --model glide talks to hosted Fastino or a local
glide.server; contract tests use a stub HTTP server.

@Birfy Birfy left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review (Birfy) — comment only, own PR, not approving

Head 48239991, CI green (core 3.11/3.13, full, benchmarks). This matches #129: --model glide against hosted Fastino (FASTINO_API_KEY, X-API-Key, https://api.fastino.ai/v1/systemone, store: false) or a local glide.server (GLIDE_URL, path /v1/systemone). GLIDE_URL wins when both are set. Images are Fastino state image_url data-URL parts (JPEG/PNG/GIF/WebP, max 4, 3.75 MiB), not Clef images or OneJev media. Empty instructions become a short fallback string; browser element criteria are flattened. Retries cover one transport / 502 / 504 plus bounded 425 / 429 / 503 with Retry-After, still inside the decision deadline. Score questions are not sent. Provenance keeps path, URL, request id, optional Fastino retention headers, and image digests.

Offline stub tests cover the hosted vs local body, auth header, image layout, transient retries, and config errors. No live Fastino or GPU run in this PR, as stated. Do not copy Fastino / Decision Index percentages as Agents results. I did not find a blocker in the adapter.

One non-blocking note: retry_after_s parses Retry-After only as a delay in seconds and uses the default when the value is an HTTP-date. That is documented. If a first live hosted run sees 425/429 with a date-style header, the wait will be the 30 s / 1 s default — fine inside the deadline, just do not treat a short default wait as "the server asked for that delay".

I am not approving this PR (it is mine). The adapter looks ready for review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feat] Add Fastino GLiDE as a served System One decision backend

1 participant