less dicts more models

This commit is contained in:
lda
2026-05-18 02:19:35 +07:00 Verified
parent 9900b01965
commit cb8d43a158
5 changed files with 154 additions and 36 deletions
+1 -1
View File
@@ -213,7 +213,7 @@ class WfMcpService:
def list_sources(self) -> list[dict[str, Any]]:
"""Return every capability source with the names it currently owns."""
return [
source.as_inventory()
source.as_inventory().model_dump(mode="json")
for source in sorted(
self.capability_sources.values(),
key=lambda source: source.id,