mirror of
https://github.com/theroyallab/tabbyAPI.git
synced 2026-03-14 15:57:27 +00:00
[fix] Bring draft progress and model progress in sync with model loader (#125)
* Bring draft progress and model progress in sync with model loader * Fix formatting
This commit is contained in:
@@ -62,14 +62,15 @@ async def load_model_gen(model_path: pathlib.Path, **kwargs):
|
||||
)
|
||||
else:
|
||||
progress.advance(loading_task)
|
||||
|
||||
yield module, modules, model_type
|
||||
|
||||
if module == modules:
|
||||
# Switch to model progress if the draft model is loaded
|
||||
if model_type == "draft":
|
||||
model_type = "model"
|
||||
else:
|
||||
progress.stop()
|
||||
|
||||
yield module, modules, model_type
|
||||
finally:
|
||||
progress.stop()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user