Model dropdown stays empty for OpenAI-compatible providers whose /v1/models is not OpenAI-shaped (e.g. Anthropic) — please allow manual model entry

Open
#484 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
68/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active

Research direction

Start at Settings → Summary → New Summary Template and trace how the Model dropdown is populated from GET /v1/models. Compare that flow with the working POST /v1/chat/completions path. Done means a user can enter a model id manually when listing fails or is empty and save a template for an OpenAI-compatible provider.

Written by the indexing model from the issue text.

Description

Summary

Scriberr can talk to Anthropic through the OpenAI-compatible provider setting, but no summary
template can be created because the Model dropdown stays empty. The chat endpoint works
fine — only the model listing fails, and it appears the dropdown is populated from it.

Same situation would hit any OpenAI-compatible provider that does not expose a /v1/models
endpoint in OpenAI's shape.

Setup

  • Scriberr v1.2.0, CPU Docker image, Linux (Synology DSM)
  • Settings → LLMs → provider OpenAI
  • OpenAI API Key: an Anthropic API key (sk-ant-…)
  • OpenAI Base URL: https://api.anthropic.com/v1
  • Configuration saved successfully

What works

POST /v1/chat/completions against that base URL returns a normal OpenAI-shaped response:

$ curl -s https://api.anthropic.com/v1/chat/completions \
    -H "Authorization: Bearer sk-ant-…" \
    -H "Content-Type: application/json" \
    -d '{"model":"claude-haiku-4-5-20251001","messages":[{"role":"user","content":"Sag Hallo"}],"max_tokens":20}'

{"id":"msg_011Cekh25Yqts4rmvPJ9ATkx","choices":[{"finish_reason":"length","index":0,
"message":{"role":"assistant","content":"Hallo! Wie geht's dir? Wie kann ich"}}],
"created":1788629478,"model":"claude-haiku-4-5-20251001","object":"chat.completion",
"usage":{"completion_tokens":20,"prompt_tokens":13,"total_tokens":33}}

So authentication, billing and the request/response format are all fine.

What fails

GET /v1/models on the same base URL, with the same Bearer token, is rejected because Anthropic
requires an extra header that an OpenAI client does not send:

$ curl -s https://api.anthropic.com/v1/models \
    -H "Authorization: Bearer sk-ant-…"

{"type":"error","error":{"type":"invalid_request_error",
"message":"anthropic-version: header is required"},"request_id":"req_011Cekh5vZxSfqhUs3GDBMPP"}

Effect

Settings → Summary → New Summary Template: the Model dropdown offers nothing, and the
template cannot be saved. The provider is therefore unusable even though summarization requests
themselves would succeed.

Suggested fix

Either of these would solve it:

  1. Make the Model field a combobox that accepts a free-text model id when the listing is empty or
    fails. The model name is all the chat endpoint needs.
  2. Add an optional "extra headers" field per provider, so users can supply e.g.
    anthropic-version: 2023-06-01 and the listing starts working.

Option 1 is the smaller change and helps every OpenAI-compatible backend with a non-standard or
missing models endpoint.

Happy to test a build.

Dominant language
Go
Stars
3.1k
Forks
264
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from rishikanthc/Scriberr

All issues in rishikanthc/Scriberr

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.