• Stefy Lanza (nextime / spora )'s avatar
    Add acceleration/distillation support (Lightning/Turbo/LCM/Hyper-SD) · d27ebf43
    Stefy Lanza (nextime / spora ) authored
    Per-model `acceleration` config block fuses a distillation LoRA into the
    pipeline at load and supplies low step-count / guidance defaults at
    generation time, for a 5-10x speedup. Covers video (Wan), image diffusers
    (SD/SDXL), and sd.cpp (step/cfg defaults + <lora:> prompt injection).
    
    - New codai/models/acceleration.py: preset catalog (ACCEL_PRESETS),
      resolve_acceleration(), apply_accel_to_pipeline() (load->fuse->unload so
      it stays orthogonal to per-request character/env LoRAs), accel_call_defaults().
    - video.py: fuse accel LoRA after load; _generate_video / _generate_sdcpp_video
      use preset steps/guidance (request always wins).
    - images.py: _apply_image_acceleration on both diffusers load paths;
      _generate_image and _generate_with_sdcpp honour preset steps/guidance.
    - main.py: surface `acceleration` as a first-class runtime kwarg.
    - admin: persist `acceleration`; new GET /admin/api/accel-presets; models.html
      Acceleration/Distillation card (preset dropdown + manual override).
    
    Also fix a latent null-trap: float(cfg.get('balanced_gpu_percent', 80))
    crashed when the config stored an explicit null (written by the admin UI for
    blank fields) since .get(key, default) returns the stored None. Use `or 80`.
    Co-Authored-By: 's avatarClaude Opus 4.8 <noreply@anthropic.com>
    d27ebf43
Name
Last commit
Last update
codai Loading commit data...
docs/superpowers Loading commit data...
samples Loading commit data...
tests Loading commit data...
tools Loading commit data...
.gitignore Loading commit data...
AI.PROMPT Loading commit data...
CODERAI_API_DOCUMENTATION.md Loading commit data...
CoderAI.gif Loading commit data...
LICENSE.md Loading commit data...
MULTIMODAL_CAPABILITIES.md Loading commit data...
MULTIMODAL_UI_EXAMPLES.md Loading commit data...
README.md Loading commit data...
build.ps1 Loading commit data...
build.sh Loading commit data...
coderai Loading commit data...
coderai-broker-implementation-reference.md Loading commit data...
coderai-integration.md Loading commit data...
osxbuild.sh Loading commit data...
requirements-nvidia.txt Loading commit data...
requirements-vulkan.txt Loading commit data...
requirements.txt Loading commit data...
todo.md Loading commit data...