In /Users/userc042661f/Documents/reigh-workspace/Astrid, investigate the vendored AI…
- User
In /Users/user_c042661f/Documents/reigh-workspace/Astrid, investigate the vendored AI Toolkit code under astrid/packs/seinfeld/ai_toolkit/upstream for LTX video LoRA training. Focus on: (1) how dataset captions are loaded when dataset config has caption_ext: caption.json and the files are JSON objects with a top-level 'caption' field, (2) whether trigger_word is injected into captions before cache_text_embeddings, (3) whether sampling-only configs with network.pretrained_lora_path actually attach/apply LoRA weights during LTX2.3 sampling. Do not edit files. Return concrete file/function references and the most likely failure points, especially anything that would make training learn from raw JSON/empty captions or sampling ignore the LoRA.
- Assistant
I’ll inspect the vendored toolkit only and keep this read-only. I’m going to map the dataset caption path, text embedding cache path, and LTX sampling/network-load path so the answer can point at exact code locations.
- Assistant
The first search confirms the relevant code is in the vendored
toolkitplus the built-inltx2extension. I’m narrowing now to the dataset item construction, trigger replacement, text embedding cache, and the sample generation code paths instead of broad LoRA matches. - Assistant
A key distinction is emerging: folder datasets with sidecar
.caption.jsonare handled differently from a dataset-path JSON manifest. The sidecar path extracts thecaptionfield; the manifest path only works if the caption dict is supplied, and one text-cache helper does not pass it. - Assistant
For text embedding cache, the actual training path uses
batch.prompt_embedswhen present, so anything wrong at cache time becomes baked in and bypasses later prompt processing. I’m now checking the LoRA construction/loading path and whether sampling-only jobs ever create a network fromnetwork.pretrained_lora_path.