From 2ad76fecb61104914a761b752015af95954483a4 Mon Sep 17 00:00:00 2001 From: Vladimir Mandic Date: Wed, 1 Jul 2026 11:16:58 +0200 Subject: [PATCH] audit: api signature Signed-off-by: Vladimir Mandic --- CHANGELOG.md | 11 +++++++---- modules/api/models.py | 10 +++++----- modules/api/server.py | 5 +++-- 3 files changed, 15 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 330021344..f2f282324 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,15 +1,16 @@ # Change Log for SD.Next -## Update for 2026-06-29 +## Update for 2026-07-01 -### Highlights for 2026-06-29 +### Highlights for 2026-07-01 Service-pack update with several fixes and quality-of-life improvements -Plus new **Krea 2** model and **SDNQ** improvements: now with *NPU* support and its own native *attention* kernels! +Plus few new models: **Krea 2** +And **SDNQ** improvements: now with *NPU* support and its own native *attention* kernels! [Home](https://vladmandic.github.io/sdnext/) | [ChangeLog](https://github.com/vladmandic/automatic/blob/master/CHANGELOG.md) | [Docs](https://vladmandic.github.io/sdnext-docs/) | [Discord](https://discord.com/invite/sd-next-federal-batch-inspectors-1101998836328697867) | [Sponsor](https://github.com/sponsors/vladmandic) -### Details for 2026-06-29 +### Details for 2026-07-01 - **Models** - [Krea 2](https://www.krea.ai/blog/krea-2-image-model) in *base* and *turbo* (distilled) variants @@ -20,6 +21,7 @@ Plus new **Krea 2** model and **SDNQ** improvements: now with *NPU* support and - **SDNQ-Attention** modelled after *sage-attention*, but modified to support AMD and Intel GPUs in addition to nVidia - **SDNQ** support for NPU during quantization and inference + - **First-Last-Frame** (FLF2V) support for Wan-2.2-I2V and LTX - add option: *compute settings -> force dtype on load* use to force model components to override loading with desired dtype regardless of component config - add option: *backend settings -> force sychronize* @@ -55,6 +57,7 @@ Plus new **Krea 2** model and **SDNQ** improvements: now with *NPU* support and - options: handle compatibility options - log: strip ansi sequences from ring buffer and client side logging - model metadata: handle invalid metadata and strip workflows + - ui debounce aspect-ratio linked width/height controls ## Update for 2026-06-16 diff --git a/modules/api/models.py b/modules/api/models.py index 989300fb6..f879609ec 100644 --- a/modules/api/models.py +++ b/modules/api/models.py @@ -153,11 +153,11 @@ class ItemUNet(BaseModel): class ItemExtraNetwork(BaseModel): name: str = Field(title="Name", description="Network short name") type: str = Field(title="Type", description="Network type (lora, checkpoint, embedding, etc.)") - title: str | None = Field(title="Title", description="Display title") - fullname: str | None = Field(title="Fullname", description="Fully qualified network name") - filename: str | None = Field(title="Filename", description="Path to the network file") - hash: str | None = Field(title="Hash", description="Short hash identifier") - preview: str | None = Field(title="Preview image URL", description="URL to the preview thumbnail") + title: str | None = Field(default=None, title="Title", description="Display title") + fullname: str | None = Field(default=None, title="Fullname", description="Fully qualified network name") + filename: str | None = Field(default=None, title="Filename", description="Path to the network file") + hash: str | None = Field(default=None, title="Hash", description="Short hash identifier") + preview: str | None = Field(default=None, title="Preview image URL", description="URL to the preview thumbnail") version: str | None = Field(default=None, title="Model version or class", description="Model version string or architecture class") tags: str | None = Field(default=None, title="Tags", description="Pipe-separated tag list") diff --git a/modules/api/server.py b/modules/api/server.py index 1dee86409..fb7e2c2b2 100644 --- a/modules/api/server.py +++ b/modules/api/server.py @@ -90,8 +90,9 @@ def get_cmd_flags(): return vars(shared.cmd_opts) def get_history(req: models.ReqHistory = Depends()): - if req.id is not None and len(req.id) > 0: - res = [item for item in shared.state.state_history if item['id'] == req.id] + if req.id is not None and (isinstance(req.id, str) and len(req.id) > 0 or isinstance(req.id, int)): + id = str(req.id) if isinstance(req.id, int) else req.id + res = [item for item in shared.state.state_history if item['id'] == id] else: res = shared.state.state_history res = [models.ResHistory(**item) for item in res]