Skip to content

Commit c9dd115

Browse files
feat(mm): omit model description instead of making it "base type filename model"
1 parent 3f82c38 commit c9dd115

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

invokeai/backend/model_manager/config.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -258,16 +258,13 @@ def from_model_on_disk(cls, mod: ModelOnDisk, **overrides):
258258
cls.cast_overrides(overrides)
259259
fields.update(overrides)
260260

261-
type = fields.get("type") or cls.model_fields["type"].default
262-
base = fields.get("base") or cls.model_fields["base"].default
263-
264261
fields["path"] = mod.path.as_posix()
265262
fields["source"] = fields.get("source") or fields["path"]
266263
fields["source_type"] = fields.get("source_type") or ModelSourceType.Path
267-
fields["name"] = name = fields.get("name") or mod.name
264+
fields["name"] = fields.get("name") or mod.name
268265
fields["hash"] = fields.get("hash") or mod.hash()
269266
fields["key"] = fields.get("key") or uuid_string()
270-
fields["description"] = fields.get("description") or f"{base.value} {type.value} model {name}"
267+
fields["description"] = fields.get("description")
271268
fields["repo_variant"] = fields.get("repo_variant") or mod.repo_variant()
272269
fields["file_size"] = fields.get("file_size") or mod.size()
273270

0 commit comments

Comments
 (0)