Skip to content

feat(friendli): add GLM-5.3-Flash provider support - #5605

Open
Lee-Si-Yoon wants to merge 5 commits into
anomalyco:devfrom
Lee-Si-Yoon:friendli/glm-5.3-flash
Open

feat(friendli): add GLM-5.3-Flash provider support#5605
Lee-Si-Yoon wants to merge 5 commits into
anomalyco:devfrom
Lee-Si-Yoon:friendli/glm-5.3-flash

Conversation

@Lee-Si-Yoon

@Lee-Si-Yoon Lee-Si-Yoon commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds Friendli as a provider host for zai-org/GLM-5.3-Flash (base_model = zhipuai/glm-5.3-flash, override-only).

available at https://api.friendli.ai/serverless/v1/models

Reasoning

reasoning_effort values low / high / max per chat_template.jinja:

{%- set effective_reasoning_effort = reasoning_effort if reasoning_effort is defined and reasoning_effort in ['low', 'high'] else 'max' -%}

Reasoning is always enabled (no toggle) — unrecognized/omitted values fall back to max.

Cost (USD/MTok)

  • input: $0.15
  • output: $0.5
  • cache_read: $0.03

Checklist

  • Non-lab host uses base_model
  • Provider file is override-only (cost + reasoning_options + interleaved only)
  • reasoning = truereasoning_options set
  • Costs in USD/MTok
  • bun validate passes

base_model = zhipuai/glm-5.3-flash (override-only file).
reasoning_options: effort [low, high, max] per chat_template.jinja
(reasoning_effort defaults to max unless low/high passed).
cost: input $0.15, output $0.5, cache_read $0.03 /MTok.
@github-actions

Copy link
Copy Markdown
Contributor

Action items

  • [low] [possible mistake] providers/friendli/models/zai-org/GLM-5.3-Flash.toml:10 - Check: Data-changing PRs should cite direct provider pricing (or equivalent) mapped to the claimed values. Why: The file sets Friendli cost at input 0.15 / output 0.5 / cache_read 0.03 USD/MTok, and the PR body restates those numbers, but neither points to a Friendli pricing/docs/API source for this host. Those figures match common list rates on other hosts and cannot be confirmed as Friendli’s rates from the PR alone. Action: Add a Friendli-first-party pricing (or catalog) citation in the PR body and/or a leading TOML comment stating what it supports, or correct the costs if Friendli differs.

Friendli /v1/models reports input_modalities: ["text"] for
zai-org/GLM-5.3-Flash even though the upstream model is multimodal.
Override modalities instead of inheriting image/video/pdf input.
anomalyco#5605
Vision-capable upstream checkpoint; Friendli endpoint will serve
image input. Keep modalities override minimal instead of inheriting
video/pdf from the lab entry.
anomalyco#5605
@github-actions

Copy link
Copy Markdown
Contributor

The PR has a concrete modalities contradiction that needs fixing before merge.

## Action items
- **[medium] [possible mistake]** `providers/friendli/models/zai-org/GLM-5.3-Flash.toml:11` - **Check:** Provider modality overrides must reflect what this host actually serves, not only the upstream lab. **Why:** Patch 2 cited Friendli `GET /serverless/v1/models` (2026-08-27) reporting `input_modalities: ["text"]` for `zai-org/GLM-5.3-Flash`, then patch 3 set `input = ["text", "image"]` with only a future-tense claim that Friendli “will serve” image input and no Friendli-side confirmation. That can mislabel the host as vision-capable when the catalog API said text-only. **Action:** Verify Friendli’s live modalities for this model ID. If the API still reports text-only, set `input = ["text"]` (and `attachment = false` if attachments are not served). If image is actually supported, keep the override and add a leading top-of-file comment citing the Friendli source that confirms image input (not only the lab checkpoint).
- **[low] [possible mistake]** `providers/friendli/models/zai-org/GLM-5.3-Flash.toml:14` - **Check:** Material cost changes should cite a direct provider pricing source. **Why:** Costs (`0.15` / `0.5` / `0.03`) match common third-party list prices but the PR body does not point to Friendli pricing or docs for this model, so host-specific pricing cannot be reviewed from the submission alone. **Action:** Add a Friendli pricing/docs citation (PR body and/or leading TOML comment) that maps to these USD/MTok values, or confirm they are intentional list prices from a named Friendli source.

@github-actions

Copy link
Copy Markdown
Contributor

Action items

  • [medium] [possible mistake] providers/friendli/models/zai-org/GLM-5.3-Flash.toml:11 - Check: Provider [modalities] must match what this host actually accepts, not the lab defaults or planned support. Why: The PR first overrode to text-only citing Friendli GET /serverless/v1/models (input_modalities: ["text"]), then added image and video in later commits while dropping that API citation and giving no new Friendli evidence (only “upstream is multimodal” / “will serve”). Lab base includes pdf; peers disagree (text+image vs text+image+video). Wrong modalities mislead clients on attachments. Check: Confirm live Friendli model metadata or docs for zai-org/GLM-5.3-Flash, set input to the verified set, drop the override entirely only if it fully matches the lab entry, and set attachment if the resolved input is text-only.

- Confirmed input_modalities=[text,image,video] against live
  GET /serverless/v1/models — resolves the bot's modality-churn
  complaint with real evidence instead of another guess.
- Added budget_tokens (min=-1, max=1_048_576) matching the live
  reasoning_options and https://friendli.ai/docs/openapi/model-apis/chat-completions#body-reasoning-budget-one-of-0.
- Added [limit] override (context=1_048_576, output=1_048_576):
  live max_completion_tokens/context_length exceed the lab file's
  rounded 1_000_000.
- Leading comment now cites the live API response for cost/modalities/
  reasoning_options, resolving the bot's pricing-citation complaint.
@Lee-Si-Yoon

Copy link
Copy Markdown
Contributor Author

Pushed 7f28c9573 addressing all three bot comments with live evidence:

  1. Pricing citation: leading comment now cites live GET /serverless/v1/models for cost — confirmed input=0.00000015, output=0.0000005, input_cache_read=0.00000003 USD-per-token, converting to input=0.15, output=0.5, cache_read=0.03 USD/MTok exactly as authored.
  2. Modality contradiction: verified live input_modalities: ["text","image","video"] for zai-org/GLM-5.3-Flash — matches the file's [modalities].input, so no change needed there, just the citation.
  3. Added budget_tokens (min=-1, max=1_048_576) and a [limit] override (context=1_048_576, output=1_048_576) — live context_length/max_completion_tokens exceed the inherited lab file's rounded 1_000_000, and reasoning_budget is a documented request field per the chat-completions OpenAPI docs.

bun validate exit 0.

@github-actions

Copy link
Copy Markdown
Contributor

No actionable findings.

@github-actions github-actions Bot added the reviewer: ready Automated review found no actionable items label Aug 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

reviewer: ready Automated review found no actionable items

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant