Spaces:
Running
Running
Add LoRA strength slider, auto-set FLUX.2 defaults (CFG 2), show advanced settings for pod
Browse files
src/content_engine/api/ui.html
CHANGED
|
@@ -972,6 +972,8 @@ select { cursor: pointer; }
|
|
| 972 |
<select id="pod-lora-select">
|
| 973 |
<option value="">None (Base model only)</option>
|
| 974 |
</select>
|
|
|
|
|
|
|
| 975 |
<div style="font-size:11px;color:var(--text-secondary);margin-top:4px">
|
| 976 |
Start the pod in Status page first.
|
| 977 |
</div>
|
|
@@ -2194,7 +2196,18 @@ function updateCloudModelVisibility() {
|
|
| 2194 |
document.getElementById('cloud-edit-model-select').style.display = (isCloud && isImg2img) ? '' : 'none';
|
| 2195 |
// Show pod settings when pod backend selected (not in video mode)
|
| 2196 |
document.getElementById('pod-settings-section').style.display = isPod ? '' : 'none';
|
| 2197 |
-
if (isPod)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2198 |
// Show denoise slider only for local img2img (cloud edit doesn't use denoise)
|
| 2199 |
const denoiseRow = document.querySelector('#img2img-section .slider-row');
|
| 2200 |
const denoiseLabel = document.querySelector('#img2img-section label');
|
|
@@ -2374,7 +2387,7 @@ async function doGenerate() {
|
|
| 2374 |
width: parseInt(document.getElementById('gen-width').value) || 1024,
|
| 2375 |
height: parseInt(document.getElementById('gen-height').value) || 1024,
|
| 2376 |
lora_name: document.getElementById('pod-lora-select')?.value || null,
|
| 2377 |
-
lora_strength: 0.85,
|
| 2378 |
character_id: document.getElementById('gen-character').value || null,
|
| 2379 |
template_id: document.getElementById('gen-template').value || null,
|
| 2380 |
};
|
|
|
|
| 972 |
<select id="pod-lora-select">
|
| 973 |
<option value="">None (Base model only)</option>
|
| 974 |
</select>
|
| 975 |
+
<label style="margin-top:8px">LoRA Strength</label>
|
| 976 |
+
<input type="number" id="pod-lora-strength" value="0.85" min="0" max="1.5" step="0.05" style="width:80px">
|
| 977 |
<div style="font-size:11px;color:var(--text-secondary);margin-top:4px">
|
| 978 |
Start the pod in Status page first.
|
| 979 |
</div>
|
|
|
|
| 2196 |
document.getElementById('cloud-edit-model-select').style.display = (isCloud && isImg2img) ? '' : 'none';
|
| 2197 |
// Show pod settings when pod backend selected (not in video mode)
|
| 2198 |
document.getElementById('pod-settings-section').style.display = isPod ? '' : 'none';
|
| 2199 |
+
if (isPod) {
|
| 2200 |
+
loadPodLorasForGeneration();
|
| 2201 |
+
// Set FLUX.2 defaults (low CFG, 28 steps)
|
| 2202 |
+
document.getElementById('gen-cfg').value = '2';
|
| 2203 |
+
document.getElementById('gen-steps').value = '28';
|
| 2204 |
+
// Auto-open Advanced section so CFG/steps are visible
|
| 2205 |
+
const adv = document.querySelector('#local-settings-section details');
|
| 2206 |
+
if (adv) adv.open = true;
|
| 2207 |
+
} else if (!isCloud) {
|
| 2208 |
+
// Reset to local defaults
|
| 2209 |
+
document.getElementById('gen-cfg').value = '7';
|
| 2210 |
+
}
|
| 2211 |
// Show denoise slider only for local img2img (cloud edit doesn't use denoise)
|
| 2212 |
const denoiseRow = document.querySelector('#img2img-section .slider-row');
|
| 2213 |
const denoiseLabel = document.querySelector('#img2img-section label');
|
|
|
|
| 2387 |
width: parseInt(document.getElementById('gen-width').value) || 1024,
|
| 2388 |
height: parseInt(document.getElementById('gen-height').value) || 1024,
|
| 2389 |
lora_name: document.getElementById('pod-lora-select')?.value || null,
|
| 2390 |
+
lora_strength: parseFloat(document.getElementById('pod-lora-strength')?.value) || 0.85,
|
| 2391 |
character_id: document.getElementById('gen-character').value || null,
|
| 2392 |
template_id: document.getElementById('gen-template').value || null,
|
| 2393 |
};
|