Feature Request: Router: upstream clients' GET /models?reload=1 is silently inert, and a client can't detect which reload route exists
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 25/100
調査の方向性
Start with the router's GET /props and GET /models handlers in the server sources, and find where reload=1 is read and where POST /models/reload is registered. The helper _get_model_ids(is_reload=...) in tests/unit/test_router.py (called around lines 511 and 523) and the note near lines 408-412 show the current behaviour. Work is already under way in open PR #193, so check it before starting. Done means a router props field names the reload endpoint, or the README documents the difference, and the router tests pass.
索引モデルが issue の本文から書いたものです。
説明
Prerequisites
- I am running the latest code. Mention the version if possible as well.
- I carefully followed the README.md.
- I searched using keywords relevant to my issue to make sure that I am creating a new issue that is not already open (or closed).
- I reviewed the Discussions, and have a new and useful enhancement to share.
Feature Description
Please give clients a way to tell which request reloads the router preset. In order of preference:
- Advertise the capability in
GET /props(router props), e.g. a list of supported router endpoints or a flag like"preset_reload": "POST /models/reload". Then a client picks the right request once and never guesses. - At minimum, a line in the README next to
POST /models/reloadsaying upstream does this withGET /models?reload=1and that the query form is intentionally inert here.
I am not asking you to make GET mutate state. I see test_router.py:408-412 and the README line stating that GET /models is read-only, and the reasoning is sound.
Motivation
BeeLlama's router reloads the preset on POST /models/reload. Upstream llama.cpp reloads it on GET /models?reload=1 and has no POST route (checked across all of tools/server at the commit BeeLlama branches from, 465e49b9, and at current master: models/reload appears only in a stale docstring in tests/unit/test_router.py). A client written for upstream sends GET /models?reload=1, gets 200 with a normal listing, and concludes the reload happened. Nothing reloaded: the file on disk is right, the model still starts with the old arguments, and only a router restart fixes it.
Measured on 0.4.7 (build 11860), Windows 10, one model, all unloaded:
status.args of model X -> --n-cpu-moe 14
edit the preset to n-cpu-moe = 15
GET /models?reload=1 -> 200, status.args still --n-cpu-moe 14
POST /models/reload -> 200 {"success": true}, status.args --n-cpu-moe 15
Same with a newly added section: invisible after the GET, present after the POST. preview-v0.4.8 behaves the same.
Affected client: LlamaForge — https://github.com/dadwritestech/LlamaForge/issues/37 (every Save, Scan, auto-tune round and preset apply goes through the query form there).
Related: test_router_models_status_args_preset keeps status.args/status.preset for exactly this kind of client compatibility (#117). This is the same class of problem, one layer up.
Possible Implementation
A field in router GET /props naming the reload endpoint would be enough; clients can fall back to today's behaviour when it is absent.
Minor, unrelated: the helper _get_model_ids(is_reload=...) in tests/unit/test_router.py still carries upstream's ?reload=1 branch and is called with is_reload=True at :511 and :523, where it now just lists models without reloading. Harmless, but the name claims something it no longer does.
- 主要言語
- C++
- スター
- 1.2k
- フォーク
- 80
- 平均マージ
- 4日 20時間
- マージ済み PR(30日)
- 2
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Anbeeld/beellama.cpp のほかの issue
-
[BUG] KVarN assertion failure in build_inp_mem_hybrid_iswa() due to uninitialized self_kvarn_rotオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
Anbeeld/beellama.cpp#205 ·
-
難易度 3/5 半日 初心者へのやさしさ 58/100
Anbeeld/beellama.cpp#206 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 57/100
Anbeeld/beellama.cpp#204 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 45/100
Anbeeld/beellama.cpp#203 · コメント 2 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 45/100
Anbeeld/beellama.cpp#202 · コメント 1 件 ·
Anbeeld/beellama.cpp の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
CachyOS/packageinstaller#144 ·
メンテナーはふだん 1 日以内に返信
-
documentation
難易度 1/5 1時間未満 初心者へのやさしさ 82/100
TomerAberbach/profiler-md#951 ·
メンテナーはふだん 1 日以内に返信
-
[Bug] Default key routing (JavaStringHash) picks a different partition than the Java client for about half of keys対応中かも @0z5a が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
apache/pulsar-client-go#1575 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
pocoproject/poco#5764 ·
メンテナーはふだん 2 日以内に返信
-
bug cpp-core-guidelines low-priority
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
NatronGitHub/openfx-supportext#164 ·
メンテナーはふだん 1 日以内に返信