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
de9a6cdc
Commit
de9a6cdc
authored
Mar 17, 2026
by
Your Name
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Re-add image_model property to MultiModelManager
parent
e06dba80
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
2 deletions
+9
-2
manager.py
codai/models/manager.py
+9
-2
No files found.
codai/models/manager.py
View file @
de9a6cdc
...
@@ -381,16 +381,23 @@ class MultiModelManager:
...
@@ -381,16 +381,23 @@ class MultiModelManager:
self
.
tts_model
:
Optional
[
str
]
=
None
self
.
tts_model
:
Optional
[
str
]
=
None
self
.
image_models
:
List
[
str
]
=
[]
self
.
image_models
:
List
[
str
]
=
[]
self
.
vision_models
:
List
[
str
]
=
[]
self
.
vision_models
:
List
[
str
]
=
[]
self
.
config
:
Dict
=
{}
# Store model configurations
self
.
config
:
Dict
[
str
,
Dict
]
=
{}
# Store model configurations
self
.
tool_parser
=
ModelParserAdapter
()
self
.
current_model_key
:
Optional
[
str
]
=
None
self
.
config
:
Dict
[
str
,
Dict
]
=
{}
# Store model configurations
self
.
tool_parser
=
ModelParserAdapter
()
self
.
tool_parser
=
ModelParserAdapter
()
self
.
current_model_key
:
Optional
[
str
]
=
None
self
.
current_model_key
:
Optional
[
str
]
=
None
self
.
config
:
Dict
[
str
,
Dict
]
=
{}
self
.
load_mode
:
str
=
"ondemand"
self
.
load_mode
:
str
=
"ondemand"
self
.
active_in_vram
:
Optional
[
str
]
=
None
self
.
active_in_vram
:
Optional
[
str
]
=
None
self
.
model_aliases
:
Dict
[
str
,
str
]
=
{}
self
.
model_aliases
:
Dict
[
str
,
str
]
=
{}
self
.
whisper_server
:
Optional
[
WhisperServerManager
]
=
None
self
.
whisper_server
:
Optional
[
WhisperServerManager
]
=
None
self
.
model_backend_types
:
Dict
[
str
,
str
]
=
{}
self
.
model_backend_types
:
Dict
[
str
,
str
]
=
{}
@
property
def
image_model
(
self
)
->
Optional
[
str
]:
"""Return the first image model or None."""
return
self
.
image_models
[
0
]
if
self
.
image_models
else
None
def
_aggressive_vram_cleanup
(
self
,
model_manager
):
def
_aggressive_vram_cleanup
(
self
,
model_manager
):
"""Aggressively cleanup VRAM when switching between different model types."""
"""Aggressively cleanup VRAM when switching between different model types."""
try
:
try
:
...
...
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