Repository navigation
Local AI images and video on this computer's GPU; per-platform captions and scheduling for auto-publish - #2
Merged
Merged
Conversation
Adds a "Local AI (this computer)" image source. The WebUI detects the GPUs and memory, recommends the best model that fits, installs a separate PyTorch runtime for the detected driver, downloads the model and starts the image server when a video needs images. - local_ai/: standard-library hardware detection (nvidia-smi, including the newer "CUDA UMD Version" header), a model catalog with fit rules (GPU, CPU offload, CPU), downloads with progress and completion markers, the runtime installer, and an OpenAI-compatible server that hands the GPU back to Ollama between images (from docs/local-image-server, now model-agnostic). - Catalog: RealVisXL V5.0 Lightning (SDXL), DreamShaper 8 (SD 1.5) and FLUX.1 schnell (gated). Offloading SDXL ranks above SD 1.5 on the GPU, since it costs seconds per image but looks much better. - Downloads go to plain folders: the Hugging Face cache needs symlinks, which Windows refuses without Developer Mode. - app/services/local_ai.py manages the runtime, downloads and server. The venv's python.exe on Windows is a launcher, so stopping the server ends the pid the server reports, not only the Popen handle. - New "local_image" source reuses the image-to-clip pipeline. Requests bypass proxies and never send cloud image API keys to localhost, and tasks fail in preflight when the runtime or model is missing. - Settings > AI Image > Local AI: hardware, GPU choice, runtime install, model download/use/delete with progress, server start/stop, and a Hugging Face token stored as a credential. Verified on an RTX 4070 Ti SUPER: about 6 s per image once the model is loaded, and the material stage turned 3 scenes into zoom clips. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…'s GPU Adds a "Local AI video (this computer)" source. The local image model paints every scene, then a video model animates each image into a short clip; a clip that fails falls back to its image with a slow zoom. - Catalog: Wan 2.2 TI2V 5B (image-to-video, Apache-2.0) and Wan 2.1 T2V 1.3B (text-to-video for 8 GB cards). Wan publishes 5 GB float32 shards; loading them failed with Windows os error 1455 when WSL held most of the commit limit. On first load the weights are rewritten as bfloat16 shards of at most 1 GB, and the transformer and T5 encoder load in 4-bit (bitsandbytes NF4), so Wan 2.2 runs fully on a 16 GB card. - The VAE decode always runs tiled: untiled, it spilled into Windows shared GPU memory and a clip took 11 minutes instead of 2. - The server keeps one image and one video pipeline, unloads the other kind before loading a model, and frees memory after a failed load. The material flow paints all scenes first, then animates them, so a video swaps models once instead of twice per scene. - The runtime marker records a digest of the requirements, so a runtime installed before the video packages (ftfy, imageio, bitsandbytes) counts as missing and reinstalls incrementally. - Settings show image and video models in both AI Image and AI Video sections, with widget keys per section. Measured on an RTX 4070 Ti SUPER: about 2 minutes per 3-second 480p clip (denoise 93 s, decode 32 s); a 3-scene material stage took 9 minutes including both model loads. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…osts TikTok and Instagram posts used one caption chosen for the first platform, and hashtags were dropped because the caption excludes them. - Generate metadata once per selected platform and send it in Upload-Post's tiktok_title and instagram_title fields as the caption followed by its hashtags. YouTube keeps its own title, description and tags; the generic title remains the fallback. - Send is_ai_generated for TikTok and Instagram, as YouTube uploads already send containsSyntheticMedia. On by default, with a setting to turn it off, since Instagram's label cannot be removed after publishing. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The previous commit generates metadata for TikTok and Instagram separately; this test still expected a single generation. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Streamlit also calls a selectbox's format_func outside the script run, where tr() cannot read the session language and raises. Precompute the labels, as the YouTube audience selector already does. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Adds "When to publish" to the Auto-Publish settings: right after the video is ready (the default and previous behaviour), the next free slot in the Upload-Post queue, or a set number of hours later. Upload-Post stores scheduled posts and publishes them itself, so this computer can be off at that time. - The choice is captured when the post is queued, like the YouTube privacy and audience settings, and a delay counts from that moment. - Uploads send add_to_queue or scheduled_date (UTC, within the 365 days Upload-Post accepts). - A scheduled upload returns 202 with a job_id and no platform results yet. It is recorded as a successful, scheduled result instead of being polled as a background upload for an hour and reported as failed; a 202 without a job_id is reported as unconfirmed. - The roadmap now notes what Upload-Post covers, and defers the Publisher protocol until a second publisher needs it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
norbsss
changed the base branch from
claude/caveman-feature-planning-8c9d5d
to
main
November 4, 2026 16:35
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #1 (WebUI split). Merge that first; this PR's diff shows only the 6 commits on top of it.
Local AI (this computer)
Two new material sources that run on the local GPU, free and offline:
Settings > AI Image / AI Video > Local AI detects the GPUs and memory, recommends the best model that fits, installs a separate PyTorch runtime that matches the GPU driver, and downloads models with progress. The image server starts on its own when a video needs it.
local_ai/: hardware detection with no torch needed (parses both the oldCUDA Versionand newCUDA UMD Versionnvidia-smi headers), a model catalog with fit rules (GPU, CPU offload, CPU), downloads with completion markers, the runtime installer, and the GPU server. The server is OpenAI-compatible for images and adds/v1/videos/generations.os error 1455(commit limit) while WSL was running. On first load they are rewritten as bf16 shards of at most 1 GB, and the transformer and T5 load in 4-bit (bitsandbytes NF4).python.exeis a launcher, so stopping the server ends the pid the server reports.Auto-publish (Upload-Post)
tiktok_titleandinstagram_title. Before, both got one caption and no hashtags.is_ai_generatedis sent for TikTok and Instagram, matching YouTube's existingcontainsSyntheticMedia. It is on by default and can be turned off, because Instagram's label cannot be removed after publishing.202+job_idresponse is recorded as a scheduled post instead of being polled for an hour and reported as failed.Tests
test_local_ai.py,test_local_ai_service.py,test_upload_post_platform_text.py,test_upload_post_schedule.py, plus a settings AppTest.🤖 Generated with Claude Code