mrjackspade commited on
Commit
a2213cd
·
verified ·
1 Parent(s): c493770

Add technical model card and step-510 release metadata

Browse files
COMPATIBILITY.md ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Compatibility and provenance notice
2
+
3
+ This repository distributes only modified Qwen3-VL text-encoder weights derived from the Apache-2.0
4
+ `Comfy-Org/Qwen3-VL` checkpoint whose SHA-256 is:
5
+
6
+ ```text
7
+ 4ba424cf62e51392e4d1a39933e803706f4e823c1065f36aaf149c6453f66bcd
8
+ ```
9
+
10
+ No Ideogram model weights, parameters, code, VAE, sampler, or tokenizer implementation are included.
11
+
12
+ The training harness connected this Qwen text encoder to a separately obtained, frozen Ideogram 4 model
13
+ through the model's ordinary conditioning interface. Ideogram was used as a differentiable downstream
14
+ evaluator for velocity loss. Ideogram parameters were never trainable and are not present in the LoRA or
15
+ merged text encoder.
16
+
17
+ These Qwen weights cannot generate images or replace Ideogram on their own. Ideogram 4 is a separately
18
+ distributed third-party model. Users who combine the components must obtain Ideogram separately and are
19
+ responsible for its license and usage requirements.
20
+
21
+ This project is independent and is not affiliated with, endorsed by, approved by, or validated by
22
+ Ideogram, Inc., Alibaba/Qwen, or Comfy Org.
23
+
LICENSE ADDED
@@ -0,0 +1,201 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [yyyy] [name of copyright owner]
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
README.md ADDED
@@ -0,0 +1,241 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ base_model: Comfy-Org/Qwen3-VL
4
+ pipeline_tag: text-to-image
5
+ tags:
6
+ - comfyui
7
+ - ideogram4
8
+ - qwen3-vl
9
+ - text-encoder
10
+ - lora
11
+ - fp8
12
+ - flow-matching
13
+ - experimental
14
+ ---
15
+
16
+ # Ideogram 4 Natural-Language Text Encoder — S020 v1
17
+
18
+ This repository contains an experimental, stock-shaped replacement for the Qwen3-VL 8B text encoder
19
+ used by Ideogram 4, plus the matching training LoRA. It is intended to make Ideogram 4 respond to
20
+ ordinary natural-language prompts more like the stock model responds to structured Magic-Prompt JSON,
21
+ without a runtime prompt rewriter, custom node, companion language model, or patched ComfyUI.
22
+
23
+ This release is the first strength-0.2 milestone. The nominal 500-step milestone resolved to the first
24
+ complete checkpoint in that checkpoint band, **optimizer step 510**.
25
+
26
+ ## Files
27
+
28
+ | File | Purpose | Size | SHA-256 |
29
+ |---|---|---:|---|
30
+ | `text_encoders/qwen3vl_8b_ideogram4_nl_s020_v1_step_00000510_fp8_scaled.safetensors` | Standalone drop-in scaled-FP8 text encoder | 10,588,637,800 bytes | `f0d1009af7407b60bda169967bb5e4c3e8ea264042b70f3d7b667bb0c2404ece` |
31
+ | `loras/qwen3vl_8b_ideogram4_nl_s020_v1_step_00000510_r64_a64.safetensors` | Matching unmerged research LoRA | 698,404,608 bytes | `85359811e619276f85742072c2b3327915bbb56bcefb874f2f3101a5d1216eef` |
32
+ | `manifests/checkpoint_step_00000510.json` | Training checkpoint and controller metadata | — | See `SHA256SUMS` |
33
+ | `manifests/merge_step_00000510.json` | Merge inputs, output hash, and per-projection quantization metrics | — | See `SHA256SUMS` |
34
+ | `COMPATIBILITY.md` | Component boundary, provenance, and third-party compatibility notice | — | See `SHA256SUMS` |
35
+
36
+ The LoRA uses this project's native tensor names (`layers.N.<projection>.lora_a` and `lora_b`) and is
37
+ not advertised as a PEFT or generic ComfyUI LoRA. Most users should use the merged text encoder.
38
+
39
+ ## Installation
40
+
41
+ Download the merged file into the normal ComfyUI text-encoder directory:
42
+
43
+ ```text
44
+ ComfyUI/models/text_encoders/
45
+ ```
46
+
47
+ Select it in the same Ideogram 4 text-encoder loader used for the stock
48
+ `qwen3vl_8b_fp8_scaled.safetensors`. No inference-time LoRA loader or source-code modification is
49
+ required.
50
+
51
+ ## What was trained
52
+
53
+ ### Task definition
54
+
55
+ Observed stock behavior motivated the following target:
56
+
57
+ ```text
58
+ short natural language -> weak/broken stock conditioning
59
+ detailed natural language -> weak/broken stock conditioning
60
+ structured Magic-Prompt JSON -> functional stock conditioning
61
+ ```
62
+
63
+ Each natural-language prompt therefore has a structured teacher target. The adapted text encoder is
64
+ not trained to reproduce the teacher's token sequence or Qwen activations. Natural-language and JSON
65
+ sequences differ in length, so the student is instead optimized at Ideogram's image-side response:
66
+
67
+ ```text
68
+ c_T = stock_text_encoder(teacher_json)
69
+ c_S = adapted_text_encoder(natural_language)
70
+
71
+ v_T = ideogram_conditional(z_t, t, c_T)
72
+ v_S = ideogram_conditional(z_t, t, c_S)
73
+
74
+ loss = mean((v_S - v_T) ** 2)
75
+ ```
76
+
77
+ Ideogram parameters are frozen, but gradients remain enabled through the student conditional forward
78
+ so the velocity loss can update the text-encoder adapters. There is no stock-natural-language retention
79
+ term: preserving stock NL behavior would preserve the behavior this project is replacing.
80
+
81
+ ### Stock text-encoder path
82
+
83
+ The stock Ideogram path uses Qwen3-VL 8B as a contextual feature extractor. Hidden states from 13 taps
84
+ (`0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33, 35`) are concatenated to 53,248 features per text token,
85
+ then projected to the 4,608-wide Ideogram DiT. The student preserves this architecture and tensor layout.
86
+
87
+ ### Dataset and teacher
88
+
89
+ - 4,000 source prompts from public Civitai generation metadata.
90
+ - Exactly 1,000 prompts from each source rating group: SFW, R, X, and XXX.
91
+ - Exact MaxMin diversity selection in Ideogram's own conditioning space, after literal cleanup,
92
+ provenance filtering, and exclusion of edit/image-input records.
93
+ - 3,900 training prompts and 100 deterministic owner-reviewed holdouts (25 per rating group).
94
+ - Eight cached behavior states per training prompt: 31,200 training examples.
95
+ - Teacher JSON generated by `accounts/fireworks/models/nemotron-3-ultra-nvfp4` through Fireworks,
96
+ temperature 0, high reasoning effort, using the project's Magic-Prompt system instructions.
97
+ - Teacher conditioning encoded through the exact stock Comfy tokenizer, Qwen taps, and Ideogram ingress
98
+ projection, stored as float16.
99
+
100
+ The source prompts, teacher JSON, and adult-content corpus are not distributed in this model repository.
101
+
102
+ ### Eight-state trajectory supervision
103
+
104
+ Teacher trajectories use the stock `V4_DEFAULT_20` 20-step schedule at 512×512. Eight deterministic
105
+ pre-step states are captured at loop indices:
106
+
107
+ ```text
108
+ [19, 16, 14, 11, 8, 5, 3, 0]
109
+ ```
110
+
111
+ Each cache entry stores the pre-step latent and exact positive conditional teacher velocity. All eight
112
+ states are independent velocity-matching examples during training. The unconditional branch is a
113
+ separate text-free model and is identical for teacher and student, so conditional velocity matching is
114
+ sufficient for the text-encoder objective.
115
+
116
+ ### Strength-0.2 first-step steering target
117
+
118
+ The teacher trajectory includes one first-conditional-pass spatial correction derived from the
119
+ authoritative Ideogram 4 debanner direction:
120
+
121
+ - correction tensor SHA-256: `5ce873adae5701e9d5f05ebfa8f8b923a1622745c6e9a2bcb3e22fd090ed30c3`;
122
+ - Ideogram blocks: 25, 26, 27, and 28;
123
+ - distillation strength: `0.2`;
124
+ - first denoising step and first positive conditional pass only;
125
+ - image tokens only;
126
+ - subtract the nearest-neighbor-resized 8×8 spatial direction, then restore each image token's
127
+ original L2 norm;
128
+ - unconditional model unchanged.
129
+
130
+ Only the first cached target velocity is directly corrected. The later seven target velocities are
131
+ uncorrected but evaluated on the trajectory produced by the corrected first update. The student always
132
+ uses an unpatched stock Ideogram conditional model; the behavior is distilled into the text encoder.
133
+
134
+ The cache contract fingerprints the correction tensor, metadata, strength, block set, schedule,
135
+ resolution, conditional checkpoint, conditioning, and all eight target velocities. Incompatible caches
136
+ are rejected before model loading.
137
+
138
+ ## Adapter geometry
139
+
140
+ The geometry is fixed and was not reduced for this checkpoint:
141
+
142
+ - rank: 64;
143
+ - alpha: 64;
144
+ - blocks: all 36 Qwen text blocks (`0–35`);
145
+ - projections per block: `q_proj`, `k_proj`, `v_proj`, `o_proj`, `gate_proj`, `up_proj`, `down_proj`;
146
+ - adapted projections: 252;
147
+ - trainable parameters: 174,587,904;
148
+ - LoRA tensors: 504.
149
+
150
+ Per block, the adapter contains 4,849,664 parameters. The all-block topology is intentional: the task is
151
+ a distributed change in how the 13 tapped Qwen layers express conditioning, not memorization in a small
152
+ upper-block adapter.
153
+
154
+ ## Optimization and numerics
155
+
156
+ - Optimizer: AdamW, FP32 adapter parameters and optimizer state.
157
+ - Weight decay: `0.01`.
158
+ - Physical batch size: 2.
159
+ - Gradient accumulation: 8.
160
+ - Effective optimizer batch: 16 behavior examples.
161
+ - Adaptive packing: batch 2 through 1,017 student tokens; longer examples use singleton microbatches.
162
+ - Gradient clipping: global norm `1.0`.
163
+ - Optimizer state is held on CPU between updates.
164
+ - Unused multimodal Qwen components are pruned from the training graph; all 36 text blocks remain.
165
+ - Initial learning rate: `3.2e-4`.
166
+
167
+ Training is quantization-aware for the final deployment format. For each adapted projection, the forward
168
+ path forms the dequantized stock weight plus the LoRA delta, then requantizes using the stock per-tensor
169
+ scale to `float8_e4m3fn`. A straight-through estimator supplies LoRA gradients without constructing a
170
+ dense base-weight gradient.
171
+
172
+ Learning rate is not tied to a fixed step horizon. A transactional controller evaluates fixed 50-step
173
+ windows every 10 steps, estimates log-loss descent relative to robust residual noise, confirms a failed
174
+ window for 20 additional steps, locates the elbow, restores the complete optimizer/sampler/RNG state at
175
+ the rollback boundary, and continues at half the LR. A rollback is issued only when both deterministic
176
+ held-out loss and interval-averaged training loss fail their descent tests. The LR floor is positive and
177
+ does not terminate training.
178
+
179
+ ## Step-510 checkpoint metrics
180
+
181
+ | Metric | Value |
182
+ |---|---:|
183
+ | Optimizer step | 510 |
184
+ | Training velocity MSE | 0.0179036569 |
185
+ | Held-out velocity MSE | 0.0171197626 |
186
+ | Learning rate | `8e-5` |
187
+ | LR reductions completed | 2 |
188
+ | Gradient norm | 0.0149142 |
189
+ | Step time on RTX 5090 | 12.94 s |
190
+ | Peak reserved VRAM | 24.463 GiB |
191
+ | Behavior microbatches | 8 batch-2, 0 singleton |
192
+
193
+ Velocity MSE is a training/health proxy, not a complete image-quality metric. The release decision was
194
+ made from fixed-seed stock/teacher/checkpoint image comparisons and owner visual review. No standardized
195
+ perceptual benchmark, OCR benchmark, or broad safety evaluation is claimed for this checkpoint.
196
+
197
+ ## Merge and deployment format
198
+
199
+ The standalone file was merged on CPU into the exact stock Comfy scaled-FP8 checkpoint layout:
200
+
201
+ - stock base SHA-256: `4ba424cf62e51392e4d1a39933e803706f4e823c1065f36aaf149c6453f66bcd`;
202
+ - adapter SHA-256: `85359811e619276f85742072c2b3327915bbb56bcefb874f2f3101a5d1216eef`;
203
+ - output SHA-256: `f0d1009af7407b60bda169967bb5e4c3e8ea264042b70f3d7b667bb0c2404ece`;
204
+ - output tensors: 1,254;
205
+ - merged projections: 252;
206
+ - stock per-tensor FP8 scales preserved;
207
+ - no training-only adapter keys added to the merged file.
208
+
209
+ The base file is byte-identical to the text encoder published in `Comfy-Org/Qwen3-VL` and
210
+ `Comfy-Org/Ideogram-4` under the base SHA above.
211
+
212
+ ## Limitations
213
+
214
+ - This is an early step-510 research checkpoint, not the end of the longer training lineage.
215
+ - The learned conditioning is specific to Ideogram 4's frozen conditional model and Comfy text-encoder
216
+ ingress path. It is not a general-purpose Qwen3-VL chat model.
217
+ - Training and validation use cached 512×512 trajectories from one fixed sampler contract. Behavior at
218
+ other resolutions, schedules, samplers, and seeds requires independent evaluation.
219
+ - Teacher targets can be imperfect or semantically inconsistent despite validation.
220
+ - The corpus deliberately spans adult source-rating groups. The model has not been safety-aligned or
221
+ certified for unrestricted deployment.
222
+ - Static text conditioning may only approximate a first-step, latent-dependent spatial intervention.
223
+ - FP8 requantization does not retain every low-magnitude LoRA delta exactly; per-projection retention
224
+ metrics are included in the merge manifest.
225
+
226
+ ## Component and licensing boundary
227
+
228
+ The files in this repository contain only modified Qwen3-VL text-encoder parameters. They start from
229
+ the independently published `Comfy-Org/Qwen3-VL` scaled-FP8 checkpoint and are released under its
230
+ Apache-2.0 license. They contain no Ideogram DiT, VAE, sampler, tokenizer implementation, source code,
231
+ or other Ideogram model parameters.
232
+
233
+ During training, a separately obtained, frozen Ideogram 4 model was used as a differentiable downstream
234
+ evaluator of the conditioning interface. Its weights were never trainable, copied into the adapter, or
235
+ included in either release file. The released text encoder cannot generate images or substitute for
236
+ Ideogram by itself.
237
+
238
+ Ideogram 4 is third-party software/modeling infrastructure and is not distributed here. Anyone choosing
239
+ to use these Qwen weights with Ideogram must obtain Ideogram separately and is independently responsible
240
+ for reviewing and complying with Ideogram's license and usage policy. This repository is not affiliated
241
+ with or endorsed by Ideogram, Inc.
configs/phase2_8state_s020_v1.yaml ADDED
@@ -0,0 +1,90 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ project:
2
+ seed: 12345
3
+ resolution: [512, 512]
4
+ output_dir: artifacts/phase2_balanced_4000_8state
5
+
6
+ paths:
7
+ comfyui: vendor/ComfyUI
8
+ ideogram4: vendor/ideogram4
9
+ stock_text_encoder: checkpoints/text_encoders/qwen3vl_8b_fp8_scaled.safetensors
10
+ conditional: checkpoints/diffusion_models/ideogram4_fp8_scaled.safetensors
11
+ teacher_pairs: artifacts/civitai_balanced_teacher_generation/nemotron_3_ultra_nvfp4_v1/teacher_pairs_4000.jsonl
12
+ holdout_approval: data/civitai_balanced/teacher_v1/teacher_pairs_sfw_r_x_xxx_4000.approval.json
13
+ training_index: artifacts/phase2_balanced_4000_training_dataset/index.jsonl
14
+
15
+ teacher:
16
+ provider: fireworks
17
+ base_url: https://api.fireworks.ai/inference/v1
18
+ model: accounts/fireworks/models/nemotron-3-ultra-nvfp4
19
+ temperature: 0.0
20
+ max_tokens: 16384
21
+ reasoning_effort: high
22
+ aspect_ratio_placeholder: "1:1"
23
+ strip_bboxes: true
24
+
25
+ conditioning:
26
+ dtype: float16
27
+ taps: [0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33, 35]
28
+ cache_dir: artifacts/phase2_balanced_4000_teacher_conditioning
29
+
30
+ trajectory:
31
+ # Full-trajectory contract: eight evenly distributed pre-step states from
32
+ # V4_DEFAULT_20. The computed capture steps are [19, 16, 14, 11, 8, 5, 3, 0].
33
+ # Cache manifests are checked before model load, so one-state data is rejected.
34
+ state_mode: trajectory
35
+ states_per_prompt: 8
36
+ sampling_steps: 20
37
+ sampler_preset: V4_DEFAULT_20
38
+ seed: 12345
39
+ cache_dir: artifacts/phase2_balanced_4000_teacher_trajectories_8state_debanner_s020_v1
40
+ generation_batch_size: 1
41
+ parallel_cfg: true
42
+ correction:
43
+ tensor: checkpoints/debanner/ideogram4_correction_v1.safetensors
44
+ metadata: checkpoints/debanner/ideogram4_correction_v1.json
45
+ # Same authoritative direction and operation, explicitly downscaled for
46
+ # distillation after the 0.6 target produced an excessive first-state bias.
47
+ strength: 0.2
48
+
49
+ training:
50
+ # Adapter geometry is invariant across all production runs: rank/alpha 64,
51
+ # all seven projection families, and all 36 Qwen blocks (inclusive range).
52
+ lora_rank: 64
53
+ lora_alpha: 64
54
+ qwen_blocks: [0, 35]
55
+ deployment_quantization: scaled_fp8_ste
56
+ batch_size: 2
57
+ gradient_accumulation: 8
58
+ adaptive_behavior_batching:
59
+ enabled: true
60
+ max_padded_student_tokens: 1017
61
+ first_oom_student_tokens: 1223
62
+ benchmark_dir: artifacts/phase2_microbatch_cutoff
63
+ optimizer: adamw
64
+ optimizer_state_offload: cpu
65
+ prune_unused_multimodal: true
66
+ learning_rate: 0.00032
67
+ weight_decay: 0.01
68
+ default_session_steps: 50
69
+ lr_control:
70
+ mode: windowed_descent_rollback
71
+ factor: 0.5
72
+ minimum_learning_rate: 0.000001
73
+ window_steps: 50
74
+ probe_every_steps: 10
75
+ confirmation_steps: 20
76
+ minimum_descent_to_noise: 1.0
77
+ minimum_relative_descent: 0.0
78
+ validation_every: 50
79
+ validation_states_per_record: 1
80
+ gradient_clip_norm: 1.0
81
+ lambda_velocity: 1.0
82
+ lambda_states: 0.0
83
+
84
+ checkpointing:
85
+ directory: artifacts/phase2_balanced_4000_8state_debanner_s020_v1_checkpoints
86
+ every_optimizer_steps: 50
87
+ save_first_optimizer_step: true
88
+ save_on_interrupt: true
89
+ resume: auto
90
+ optimizer_boundary_only: true
manifests/checkpoint_step_00000510.json ADDED
@@ -0,0 +1,115 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "schema_version": 1,
3
+ "status": "complete",
4
+ "config_fingerprint": "0667d4ea7a9eeb08101909c8f4b52860faadd491ce6d4ceb8094405e04a5f75e",
5
+ "dataset_fingerprint": "6cf9eb3d777a338eb007dcc5606b2aac6605bf899a191ea399ccd77d5527acfb",
6
+ "cursor": {
7
+ "global_step": 510,
8
+ "micro_step": 4094,
9
+ "dataset_epoch": 0,
10
+ "sample_offset": 8160,
11
+ "accumulation_step": 0
12
+ },
13
+ "extra": {
14
+ "last_metrics": {
15
+ "global_step": 510,
16
+ "behavior_loss": 0.017903656873386353,
17
+ "behavior_microbatches": 8,
18
+ "behavior_singleton_microbatches": 0,
19
+ "oom_replayed_as_singletons": false,
20
+ "gradient_norm": 0.014914182014763355,
21
+ "learning_rate_used": 8e-05,
22
+ "step_seconds": 12.94,
23
+ "peak_reserved_gib": 24.463,
24
+ "optimizer_state_device": "cpu_between_updates",
25
+ "weighted_behavior_objective": 0.017903656873386353,
26
+ "validation_behavior_loss": 0.017119762562215327,
27
+ "lr_window_phase": "continue",
28
+ "lr_window_start_step": 460,
29
+ "lr_window_end_step": 510,
30
+ "lr_window_point_count": 6,
31
+ "lr_window_log_slope_per_step": -0.00037796895479860206,
32
+ "lr_window_fitted_log_descent": 0.018898447739930102,
33
+ "lr_window_relative_descent": 0.018720991715869606,
34
+ "lr_window_residual_mad_scale": 0.0037479312671825525,
35
+ "lr_window_descent_to_noise": 5.0423677470843025,
36
+ "lr_window_accepted": true,
37
+ "lr_window_elbow_step": 510,
38
+ "lr_training_window_start_step": 470,
39
+ "lr_training_window_end_step": 510,
40
+ "lr_training_window_point_count": 5,
41
+ "lr_training_window_log_slope_per_step": 0.0058621381370863365,
42
+ "lr_training_window_fitted_log_descent": -0.23448552548345347,
43
+ "lr_training_window_relative_descent": -0.2642581727774924,
44
+ "lr_training_window_residual_mad_scale": 0.05576780509580324,
45
+ "lr_training_window_descent_to_noise": -4.204675530633345,
46
+ "lr_training_window_accepted": false,
47
+ "lr_training_window_elbow_step": 480,
48
+ "lr_window_any_signal_accepted": true,
49
+ "validation_interval": 10,
50
+ "next_validation_step": 520,
51
+ "learning_rate": 8e-05
52
+ },
53
+ "reason": "periodic",
54
+ "parent": null,
55
+ "lr_control": {
56
+ "version": 3,
57
+ "config": {
58
+ "factor": 0.5,
59
+ "minimum_learning_rate": 1e-06,
60
+ "window_steps": 50,
61
+ "probe_every_steps": 10,
62
+ "confirmation_steps": 20,
63
+ "minimum_descent_to_noise": 1.0,
64
+ "minimum_relative_descent": 0.0
65
+ },
66
+ "state": {
67
+ "learning_rate": 8e-05,
68
+ "points": [
69
+ {
70
+ "step": 510,
71
+ "loss": 0.017119762562215327
72
+ }
73
+ ],
74
+ "training_points": [],
75
+ "training_loss_sum": 0.0,
76
+ "training_loss_count": 0,
77
+ "last_training_step": 510,
78
+ "window_start_step": 510,
79
+ "next_validation_step": 520,
80
+ "last_analysis": {
81
+ "start_step": 460,
82
+ "end_step": 510,
83
+ "point_count": 6,
84
+ "log_slope_per_step": -0.00037796895479860206,
85
+ "fitted_log_descent": 0.018898447739930102,
86
+ "relative_descent": 0.018720991715869606,
87
+ "residual_mad_scale": 0.0037479312671825525,
88
+ "descent_to_noise": 5.0423677470843025,
89
+ "accepted": true,
90
+ "elbow_step": 510
91
+ },
92
+ "last_training_analysis": {
93
+ "start_step": 470,
94
+ "end_step": 510,
95
+ "point_count": 5,
96
+ "log_slope_per_step": 0.0058621381370863365,
97
+ "fitted_log_descent": -0.23448552548345347,
98
+ "relative_descent": -0.2642581727774924,
99
+ "residual_mad_scale": 0.05576780509580324,
100
+ "descent_to_noise": -4.204675530633345,
101
+ "accepted": false,
102
+ "elbow_step": 480
103
+ },
104
+ "confirming": false,
105
+ "pending_rollback": null,
106
+ "reductions": 2
107
+ }
108
+ },
109
+ "rollback_replay": null
110
+ },
111
+ "files": {
112
+ "adapters.safetensors": "85359811e619276f85742072c2b3327915bbb56bcefb874f2f3101a5d1216eef",
113
+ "training_state.pt": "ddf75f2fc8f599e9fa4ad7c14e3a807b5c1f4e8c3b639796819485b7fc20840f"
114
+ }
115
+ }
manifests/merge_step_00000510.json ADDED
The diff for this file is too large to render. See raw diff