Instructions to use SceneWorks/scail2-dpo-lora with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- SCAIL-2
How to use SceneWorks/scail2-dpo-lora with SCAIL-2:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- MLX
How to use SceneWorks/scail2-dpo-lora with MLX:
# Download the model from the Hub pip install huggingface_hub[hf_xet] huggingface-cli download --local-dir scail2-dpo-lora SceneWorks/scail2-dpo-lora
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
Upload README.md with huggingface_hub
Browse files
README.md
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
base_model: zai-org/SCAIL-2
|
| 4 |
+
library_name: safetensors
|
| 5 |
+
tags:
|
| 6 |
+
- lora
|
| 7 |
+
- video
|
| 8 |
+
- character-animation
|
| 9 |
+
- scail-2
|
| 10 |
+
- wan2.1
|
| 11 |
+
- mlx
|
| 12 |
+
- sceneworks
|
| 13 |
+
---
|
| 14 |
+
|
| 15 |
+
# SCAIL-2 Bias-Aware DPO LoRA (inference-format)
|
| 16 |
+
|
| 17 |
+
A quality-refinement **LoRA** for [zai-org/SCAIL-2](https://huggingface.co/zai-org/SCAIL-2) — the
|
| 18 |
+
end-to-end controlled character-animation / cross-identity-replacement model (Wan2.1-14B I2V). This is
|
| 19 |
+
the **Bias-Aware DPO** adapter zai-org ships on the `sat-scail2` branch, **converted from its native
|
| 20 |
+
DeepSpeed / SwissArmyTransformer (SAT) checkpoint to an inference-named `.safetensors`** so it loads
|
| 21 |
+
directly into native-MLX inference engines (e.g. SceneWorks) as a standard `lora_down` / `lora_up`
|
| 22 |
+
adapter.
|
| 23 |
+
|
| 24 |
+
- **Rank 128**, 400 LoRA pairs covering every transformer block:
|
| 25 |
+
`blocks.N.{self_attn,cross_attn}.{q,k,v,o}` and `blocks.N.ffn.{0,2}`.
|
| 26 |
+
- A clean low-rank LoRA (no diff-patch tensors) — applies as a forward-time residual over the
|
| 27 |
+
(optionally Q4 / Q8-quantized) base.
|
| 28 |
+
- `bf16`, ~1.2 GB.
|
| 29 |
+
|
| 30 |
+
## Conversion
|
| 31 |
+
|
| 32 |
+
The upstream `model/bias-aware-dpo-lora.pt` is a DeepSpeed checkpoint (the LoRA state lives under the
|
| 33 |
+
top-level `["module"]` key) with SAT module names and fused `query_key_value` / `key_value` projections
|
| 34 |
+
already split into per-projection `lora_layer.{idx}` sub-LoRAs. The conversion is a pure key rename to
|
| 35 |
+
the inference `SCAIL2Model` module names — q/k/v from `query_key_value`; k/v from `key_value`; `dense`
|
| 36 |
+
→ the output projection `o`; `mlp.dense_h_to_4h` / `dense_4h_to_h` → `ffn.0` / `ffn.2`; `down` / `up`
|
| 37 |
+
→ `lora_down` / `lora_up`. The dims confirm the mapping (e.g. `mlp.dense_h_to_4h`
|
| 38 |
+
`down[128,5120]` / `up[13824,128]` == SCAIL-2's `ffn.0` `[13824,5120]`).
|
| 39 |
+
|
| 40 |
+
The converter is `scripts/convert_scail2_dpo_lora.py` in the SceneWorks repository.
|
| 41 |
+
|
| 42 |
+
## License & attribution
|
| 43 |
+
|
| 44 |
+
Apache-2.0, inherited from [zai-org/SCAIL-2](https://github.com/zai-org/SCAIL-2). All credit for the
|
| 45 |
+
underlying model and the DPO adapter belongs to zai-org; this repository only re-hosts a format
|
| 46 |
+
conversion of their published weights.
|