Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
C
coderai
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexlab
coderai
Commits
1cb7f4b3
Commit
1cb7f4b3
authored
Mar 09, 2026
by
Your Name
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix: Download model if not cached when using whisper.cpp CLI
parent
4af2538e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
3 deletions
+15
-3
coderai
coderai
+15
-3
No files found.
coderai
View file @
1cb7f4b3
...
...
@@ -2655,13 +2655,25 @@ async def create_transcription(
try:
import subprocess
# Determine the model path
model_path = model_to_use if os.path.isfile(model_to_use) else None
if not model_path:
# Determine the model path - check if it'
s
already
cached
or
needs
downloading
model_path
=
None
#
First
check
if
it
's a local file
if os.path.isfile(model_to_use):
model_path = model_to_use
print(f"DEBUG: Using local model file: {model_path}")
else:
# Check cache for downloaded model
cached = get_cached_model_path(model_to_use)
if cached and os.path.isfile(cached):
model_path = cached
print(f"DEBUG: Using cached model: {model_path}")
else:
# Download the model if not cached
print(f"DEBUG: Model not cached, downloading: {model_to_use}")
cache_dir = get_model_cache_dir()
model_path = download_model(model_to_use, cache_dir)
print(f"DEBUG: Downloaded model to: {model_path}")
print(f"DEBUG: Whisper model: {model_to_use}")
print(f"DEBUG: Whisper model path (resolved): {model_path}")
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment