[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M798WMEHX4M2Q1C31TY38FAK":3,"skill-same:01M798WMEHX4M2Q1C31TY38FAK":105},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":38,"commitSha":39,"skillDirectory":40,"forksCount":41,"repositoryHtmlUrl":42,"repositoryHomepageUrl":6,"ownerHtmlUrl":43,"ownerBlogUrl":44,"ownerDescription":45,"updatedAt":46,"install":47,"resources":60},"01M798WMEHX4M2Q1C31TY38FAK","tao-finetune-cosmos-embed",null,"Cosmos-Embed1 video-text embedding for text-to-video retrieval, video-to-video search, semantic deduplication, and fine-tuning. Use when the user asks to \"fine-tune Cosmos-Embed1\", \"run cosmos-embed inference\", \"export Cosmos-Embed1\", \"embed videos\", or \"search videos with text\".","jukeyman\u002Fjukeyman-skills","jukeyman","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F142960420?v=4","01M78FR4Y3DHMMCBCC0GXXNB3F","RICK JEFFERSON","01M78FR4Z8RVQRAD31Y5J7V6EB",1,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: tao-finetune-cosmos-embed\ndescription: >-\n  Cosmos-Embed1 video-text embedding for text-to-video retrieval, video-to-video search, semantic deduplication, and\n  fine-tuning. Use when the user asks to \"fine-tune Cosmos-Embed1\", \"run cosmos-embed inference\", \"export Cosmos-Embed1\",\n  \"embed videos\", or \"search videos with text\".\nlicense: Apache-2.0\ncompatibility: Requires docker + nvidia-container-toolkit, the published Cosmos-Embed TAO container from versions.yaml, and a HuggingFace token when downloading pretrained `nvidia\u002FCosmos-Embed1-*` weights.\nmetadata:\n  author: NVIDIA Corporation\n  version: \"0.1.0\"\nallowed-tools: Read Bash\ntags:\n- video\n- vision-language\n- vlm\n- multimodal\n- retrieval\n- embedding\n- cosmos\n- fine-tuning\n---\n\n# Cosmos-Embed\n\nCosmos-Embed1 is a joint video-text embedder for text-to-video retrieval, video-to-video search, zero-shot\u002FkNN classification, and semantic deduplication. The packaged CLI is `cosmos-embed1` and supports `train`, `evaluate`, `inference`, and `export`.\n\nContainer image and per-action commands are in `references\u002Fskill_info.yaml`. Compact starting specs are in `references\u002Fspec_template_*.yaml`.\n\n## Train Action Policy\n\nThis model is AutoML-enabled at the model layer. Before handling any train-stage request, read `references\u002Fskill_info.yaml` and resolve the run override from either an explicit `automl_policy` value or the user's workflow request. Treat phrases like \"turn off AutoML\", \"disable AutoML\", \"no HPO\", or \"plain training\" as `automl_policy: off` for this run only; otherwise default to `auto`. When `automl_policy: auto`, `automl_enabled: true`, and both `schemas\u002Ftrain.schema.json` and `references\u002Fspec_template_train.yaml` are packaged, route the train action through `tao-skill-bank:tao-run-automl` by default with this model's `skill_dir`. Preserve workflow\u002Fapplication overrides for datasets, specs, output directories, GPU\u002Fplatform settings, parent checkpoints, and `automl_policy`. Use direct model training only when `automl_policy: off` or the packaged train schema\u002Ftemplate is missing; in the missing-schema case, report that AutoML is enabled but not runnable for this model until schemas are generated.\n\nNon-train actions such as `evaluate`, `inference`, `export`, and deploy flows stay in this model skill. The per-run `automl_policy` override does not change model metadata.\n\n## Quick Start\n\nUse the published Cosmos-Embed container declared by `references\u002Fskill_info.yaml`\nand resolved through `versions.yaml`. Do not build from the private\nCosmos-Embed1 source tree for normal skill use; build from source only when\ndeveloping the container itself.\n\n```bash\nTAO_SKILL_BANK_PATH=\"${TAO_SKILL_BANK_PATH:-$PWD}\"\nCOSMOS_EMBED_IMAGE=\"${COSMOS_EMBED_IMAGE:-$(\n  python \"$TAO_SKILL_BANK_PATH\u002Fscripts\u002Fresolve_tao_image.py\" \\\n    --skill-bank \"$TAO_SKILL_BANK_PATH\" \\\n    --model cosmos-embed \\\n    --action train \\\n    --format json |\n  python -c 'import json,sys; print(json.load(sys.stdin)[\"image\"])'\n)}\"\ndocker pull \"$COSMOS_EMBED_IMAGE\"\n```\n\nExpected local workspace layout:\n\n```text\nworkspace\u002F\n├── data\u002F\n│   ├── msrvtt_test_1k.json\n│   └── video\u002F\n│       ├── video7020.mp4\n│       └── ...\n├── model\u002F\n│   └── Cosmos-Embed1-224p\u002F        # optional if using HF repo id\n├── specs\u002F\n│   ├── train.yaml\n│   ├── evaluate.yaml\n│   ├── inference.yaml\n│   ├── export_onnx.yaml\n│   └── export_hf.yaml\n└── results\u002F\n```\n\nUse these Docker options for all actions unless the local Docker\u002Fplatform skill gives a stricter environment-specific command:\n\n```bash\nTAO_SKILL_BANK_PATH=\"${TAO_SKILL_BANK_PATH:-$PWD}\"\nCOSMOS_EMBED_IMAGE=\"${COSMOS_EMBED_IMAGE:-$(\n  python \"$TAO_SKILL_BANK_PATH\u002Fscripts\u002Fresolve_tao_image.py\" \\\n    --skill-bank \"$TAO_SKILL_BANK_PATH\" \\\n    --model cosmos-embed \\\n    --action train \\\n    --format json |\n  python -c 'import json,sys; print(json.load(sys.stdin)[\"image\"])'\n)}\"\nRUN_ROOT=\"${RUN_ROOT:-$PWD}\"\nDOCKER_COMMON=(\n  --rm --gpus all --ipc=host --network=host\n  --shm-size=64g\n  --ulimit memlock=-1\n  --ulimit stack=67108864\n  -e HF_TOKEN\n  -v \"$RUN_ROOT\u002Fdata:\u002Fdata:ro\"\n  -v \"$RUN_ROOT\u002Fmodel:\u002Fmodel\"\n  -v \"$RUN_ROOT\u002Fspecs:\u002Fspecs:ro\"\n  -v \"$RUN_ROOT\u002Fresults:\u002Fresults\"\n)\n```\n\nTrain:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 train -e \u002Fspecs\u002Ftrain.yaml results_dir=\u002Fresults\n```\n\nEvaluate:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 evaluate -e \u002Fspecs\u002Fevaluate.yaml results_dir=\u002Fresults\n```\n\nInference:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 inference -e \u002Fspecs\u002Finference.yaml \\\n  'inference.query.input_texts=[\"a man is singing on stage\"]' \\\n  inference.k=5 \\\n  results_dir=\u002Fresults\n```\n\nExport ONNX:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 export -e \u002Fspecs\u002Fexport_onnx.yaml \\\n  export.checkpoint=\u002Fresults\u002Ftrain\u002Fcosmos_embed1_model_latest.pth \\\n  export.onnx_file=\u002Fresults\u002Fexport\u002Fcosmos_embed1_combined.onnx \\\n  results_dir=\u002Fresults\n```\n\nExport HuggingFace format:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 export -e \u002Fspecs\u002Fexport_hf.yaml \\\n  export.checkpoint=\u002Fresults\u002Ftrain\u002Fcosmos_embed1_model_latest.pth \\\n  export.hf_output_dir=\u002Fresults\u002Fexport_hf\u002Fcosmos_embed1_hf \\\n  results_dir=\u002Fresults\n```\n\n## Smoke Overrides\n\nFor a small functional check, keep the same specs and override the expensive knobs:\n\n```bash\ntrain.max_iter=1\ntrain.validation_iter=2\ntrain.checkpoint_iter=1\ntrain.optim.optim=adamw\ndataset.train_dataset.batch_size=1\ndataset.val_dataset.batch_size=1\ndataset.train_dataset.workers=0\ndataset.val_dataset.workers=0\n```\n\nIf no local Cosmos-Embed1 pretrained checkpoint or HuggingFace token is available, set `model.pretrained_model_path=null` for a plumbing-only smoke train. The model quality is meaningless in that mode, but the train\u002Fevaluate\u002Finference\u002Fexport action paths can still be exercised.\n\nFor evaluation and inference smoke tests on a tiny subset:\n\n```bash\nevaluate.callbacks.embedding_visualization=false\nevaluate.callbacks.max_eval_samples=8\ndataset.test_dataset.batch_size=1\ndataset.test_dataset.workers=0\ninference.k=2\ndataset.inference_dataset.batch_size=1\ndataset.inference_dataset.workers=0\n```\n\n## Data Format\n\nThe MSR-VTT path expects a local video glob and a JSON metadata file:\n\n```yaml\ndataset:\n  train_dataset:\n    dataset_type: msrvtt\n    mp4_urls: \u002Fdata\u002Fvideo\u002F*.mp4\n    metadata: \u002Fdata\u002Fmsrvtt_test_1k.json\n```\n\nList-format metadata rows must include at least `video` and `caption`:\n\n```json\n{\"video_id\": \"video7020\", \"video\": \"video7020.mp4\", \"caption\": \"a woman creating a fondant baby and flower\"}\n```\n\nThe dataset loader derives the video id from the local `.mp4` filename and filters to videos present in the metadata. If a run finds zero videos, check that `mp4_urls` points to a container-local glob and that metadata `video` names match the filenames.\n\n## Model Weights\n\n- Local HF directory: mount it under `\u002Fmodel` and set `model.pretrained_model_path=\u002Fmodel\u002FCosmos-Embed1-224p`.\n- HuggingFace repo: set `model.pretrained_model_path=nvidia\u002FCosmos-Embed1-224p` and pass `HF_TOKEN` if access is gated.\n- Fine-tuned checkpoint: downstream actions default to `\u002Fresults\u002Ftrain\u002Fcosmos_embed1_model_latest.pth`.\n\nVariants:\n\n| Variant | Resolution | Frames | Embedding dim |\n|---|---:|---:|---:|\n| `Cosmos-Embed1-224p` | 224 x 224 | 8 | 256 |\n| `Cosmos-Embed1-336p` | 336 x 336 | 8 | 768 |\n| `Cosmos-Embed1-448p` | 448 x 448 | 8 | 768 |\n\nKeep `model.network.embed_dim`, `model.input_hw`, and `model.network.spatial_resolution` aligned with the selected variant.\n\n## Important Parameters\n\n| Parameter | Notes |\n|---|---|\n| `train.num_gpus` | `1` for single GPU, `>1` auto-launches `torchrun`, `-1` auto-detects visible GPUs. |\n| `train.max_iter` | Main training length. Use `1` only for smoke testing. |\n| `train.optim.optim` | `fused_adamw` is faster when available; `adamw` is safer for smoke and portability. |\n| `model.lora.enabled` | Enables LoRA. Set `model.network.visual_encoder.transformer_engine=false` when LoRA is on. |\n| `model.lora.lora_rank` | LoRA rank. Start with `8`; try `4`, `8`, or `16` for manual or AutoML-style sweeps. |\n| `model.lora.lora_alpha` | LoRA scaling factor. Start with `16`; keep near `2 * lora_rank` unless experiments show otherwise. |\n| `model.lora.lora_dropout` | LoRA dropout. Start with `0.1`; sweep `0.0`, `0.05`, and `0.1` for small datasets. |\n| `model.lora.bias` | Bias policy: `none`, `all`, or `lora_only`. Keep `none` unless intentionally training biases. |\n| `model.lora.use_rslora` \u002F `use_dora` | Optional LoRA variants. Enable one at a time and record the setting with the checkpoint. |\n| `model.lora.target_modules` | Optional module-name patterns for LoRA injection. Leave empty for the default ViT + Q-Former attention\u002FMLP targets. |\n| `model.lora.modules_to_save` | Optional modules to keep fully trainable alongside LoRA. Leave empty unless preserving a task-specific head. |\n| `evaluate.load_dataset_pkl` \u002F `save_dataset_pkl` | Cache evaluation embeddings. |\n| `inference.load_dataset_pkl` \u002F `save_dataset_pkl` | Cache the search database for repeated retrieval. |\n| `export.mode` | `video`, `text`, `combined`, or `huggingface`. |\n| `export.on_cpu` | Recommended for export to avoid device mismatch issues. |\n\n### LoRA and AutoML Notes\n\nFor parameter-efficient fine-tuning, set `model.lora.enabled=true` and keep\n`model.network.visual_encoder.transformer_engine=false`; TAO Core's\nCosmos-Embed1 config notes that PEFT cannot inject adapters into Transformer\nEngine layers. Treat the LoRA fields above as the first candidate parameters\nfor manual tuning or AutoML-style search before unfreezing larger model blocks.\nAvoid changing `target_modules` or `modules_to_save` unless the user explicitly\nneeds custom adapter placement.\n\n## S3 Staging\n\nThe Cosmos-Embed1 CLI consumes local paths and Python globs, not raw `s3:\u002F\u002F...\u002F*.mp4` URIs. For S3-backed runs, first stage a subset or full dataset to the execution host\u002Fcontainer filesystem, then use local paths such as `\u002Fdata\u002Fvideo\u002F*.mp4` in the spec.\n\nRecommended S3 layout for staged MSR-VTT data:\n\n```text\ns3:\u002F\u002Fbucket\u002Fpath\u002Fcosmos-embed\u002Fmsrvtt-subset\u002F\n├── msrvtt_test_1k.json\n└── video\u002F\n    ├── video7020.mp4\n    └── ...\n```\n\nAfter downloading\u002Fsyncing that prefix into the mounted `data\u002F` directory, use the same Docker commands above.\n\n## Outputs\n\n```text\nresults\u002F\n├── train\u002F\n│   ├── cosmos_embed1_model_latest.pth\n│   ├── cosmos_embed1_model_\u003Citer>.pth\n│   └── experiment.yaml\n├── evaluate\u002F\n│   ├── metrics.json\n│   └── experiment.yaml\n├── inference\u002F\n│   ├── results.json\n│   └── experiment.yaml\n├── export\u002F\n│   ├── cosmos_embed1_combined.onnx\n│   └── export_config.yaml\n└── export_hf\u002F\n    └── cosmos_embed1_hf\u002F\n```\n\n## Known Pitfalls\n\n| Symptom | Cause | Fix |\n|---|---|---|\n| `MSRVTTDataset: 0 videos found` | `mp4_urls` is not a local glob or metadata filenames do not match videos. | Mount data into the container and set `mp4_urls=\u002Fdata\u002Fvideo\u002F*.mp4`. |\n| HF download\u002Fauth failure | Missing or invalid `HF_TOKEN`, or model agreement not accepted. | Accept the model terms and pass `-e HF_TOKEN`. |\n| LoRA injection failure | Transformer Engine visual encoder is enabled. | Set `model.network.visual_encoder.transformer_engine=false`. |\n| ONNX\u002FHF export complains about missing components | Export checkpoint is partial or adapter-only. | Use a full checkpoint or configure pretrained visual\u002Ftext sources before export. |\n| CUDA OOM | Batch\u002Fresolution too high for the GPU. | Reduce batch size, use 224p, enable LoRA, or use more GPUs. |\n","# Cosmos-Embed\n\nCosmos-Embed1 is a joint video-text embedder for text-to-video retrieval, video-to-video search, zero-shot\u002FkNN classification, and semantic deduplication. The packaged CLI is `cosmos-embed1` and supports `train`, `evaluate`, `inference`, and `export`.\n\nContainer image and per-action commands are in `references\u002Fskill_info.yaml`. Compact starting specs are in `references\u002Fspec_template_*.yaml`.\n\n## Train Action Policy\n\nThis model is AutoML-enabled at the model layer. Before handling any train-stage request, read `references\u002Fskill_info.yaml` and resolve the run override from either an explicit `automl_policy` value or the user's workflow request. Treat phrases like \"turn off AutoML\", \"disable AutoML\", \"no HPO\", or \"plain training\" as `automl_policy: off` for this run only; otherwise default to `auto`. When `automl_policy: auto`, `automl_enabled: true`, and both `schemas\u002Ftrain.schema.json` and `references\u002Fspec_template_train.yaml` are packaged, route the train action through `tao-skill-bank:tao-run-automl` by default with this model's `skill_dir`. Preserve workflow\u002Fapplication overrides for datasets, specs, output directories, GPU\u002Fplatform settings, parent checkpoints, and `automl_policy`. Use direct model training only when `automl_policy: off` or the packaged train schema\u002Ftemplate is missing; in the missing-schema case, report that AutoML is enabled but not runnable for this model until schemas are generated.\n\nNon-train actions such as `evaluate`, `inference`, `export`, and deploy flows stay in this model skill. The per-run `automl_policy` override does not change model metadata.\n\n## Quick Start\n\nUse the published Cosmos-Embed container declared by `references\u002Fskill_info.yaml`\nand resolved through `versions.yaml`. Do not build from the private\nCosmos-Embed1 source tree for normal skill use; build from source only when\ndeveloping the container itself.\n\n```bash\nTAO_SKILL_BANK_PATH=\"${TAO_SKILL_BANK_PATH:-$PWD}\"\nCOSMOS_EMBED_IMAGE=\"${COSMOS_EMBED_IMAGE:-$(\n  python \"$TAO_SKILL_BANK_PATH\u002Fscripts\u002Fresolve_tao_image.py\" \\\n    --skill-bank \"$TAO_SKILL_BANK_PATH\" \\\n    --model cosmos-embed \\\n    --action train \\\n    --format json |\n  python -c 'import json,sys; print(json.load(sys.stdin)[\"image\"])'\n)}\"\ndocker pull \"$COSMOS_EMBED_IMAGE\"\n```\n\nExpected local workspace layout:\n\n```text\nworkspace\u002F\n├── data\u002F\n│   ├── msrvtt_test_1k.json\n│   └── video\u002F\n│       ├── video7020.mp4\n│       └── ...\n├── model\u002F\n│   └── Cosmos-Embed1-224p\u002F        # optional if using HF repo id\n├── specs\u002F\n│   ├── train.yaml\n│   ├── evaluate.yaml\n│   ├── inference.yaml\n│   ├── export_onnx.yaml\n│   └── export_hf.yaml\n└── results\u002F\n```\n\nUse these Docker options for all actions unless the local Docker\u002Fplatform skill gives a stricter environment-specific command:\n\n```bash\nTAO_SKILL_BANK_PATH=\"${TAO_SKILL_BANK_PATH:-$PWD}\"\nCOSMOS_EMBED_IMAGE=\"${COSMOS_EMBED_IMAGE:-$(\n  python \"$TAO_SKILL_BANK_PATH\u002Fscripts\u002Fresolve_tao_image.py\" \\\n    --skill-bank \"$TAO_SKILL_BANK_PATH\" \\\n    --model cosmos-embed \\\n    --action train \\\n    --format json |\n  python -c 'import json,sys; print(json.load(sys.stdin)[\"image\"])'\n)}\"\nRUN_ROOT=\"${RUN_ROOT:-$PWD}\"\nDOCKER_COMMON=(\n  --rm --gpus all --ipc=host --network=host\n  --shm-size=64g\n  --ulimit memlock=-1\n  --ulimit stack=67108864\n  -e HF_TOKEN\n  -v \"$RUN_ROOT\u002Fdata:\u002Fdata:ro\"\n  -v \"$RUN_ROOT\u002Fmodel:\u002Fmodel\"\n  -v \"$RUN_ROOT\u002Fspecs:\u002Fspecs:ro\"\n  -v \"$RUN_ROOT\u002Fresults:\u002Fresults\"\n)\n```\n\nTrain:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 train -e \u002Fspecs\u002Ftrain.yaml results_dir=\u002Fresults\n```\n\nEvaluate:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 evaluate -e \u002Fspecs\u002Fevaluate.yaml results_dir=\u002Fresults\n```\n\nInference:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 inference -e \u002Fspecs\u002Finference.yaml \\\n  'inference.query.input_texts=[\"a man is singing on stage\"]' \\\n  inference.k=5 \\\n  results_dir=\u002Fresults\n```\n\nExport ONNX:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 export -e \u002Fspecs\u002Fexport_onnx.yaml \\\n  export.checkpoint=\u002Fresults\u002Ftrain\u002Fcosmos_embed1_model_latest.pth \\\n  export.onnx_file=\u002Fresults\u002Fexport\u002Fcosmos_embed1_combined.onnx \\\n  results_dir=\u002Fresults\n```\n\nExport HuggingFace format:\n\n```bash\ndocker run \"${DOCKER_COMMON[@]}\" \"$COSMOS_EMBED_IMAGE\" \\\n  cosmos-embed1 export -e \u002Fspecs\u002Fexport_hf.yaml \\\n  export.checkpoint=\u002Fresults\u002Ftrain\u002Fcosmos_embed1_model_latest.pth \\\n  export.hf_output_dir=\u002Fresults\u002Fexport_hf\u002Fcosmos_embed1_hf \\\n  results_dir=\u002Fresults\n```\n\n## Smoke Overrides\n\nFor a small functional check, keep the same specs and override the expensive knobs:\n\n```bash\ntrain.max_iter=1\ntrain.validation_iter=2\ntrain.checkpoint_iter=1\ntrain.optim.optim=adamw\ndataset.train_dataset.batch_size=1\ndataset.val_dataset.batch_size=1\ndataset.train_dataset.workers=0\ndataset.val_dataset.workers=0\n```\n\nIf no local Cosmos-Embed1 pretrained checkpoint or HuggingFace token is available, set `model.pretrained_model_path=null` for a plumbing-only smoke train. The model quality is meaningless in that mode, but the train\u002Fevaluate\u002Finference\u002Fexport action paths can still be exercised.\n\nFor evaluation and inference smoke tests on a tiny subset:\n\n```bash\nevaluate.callbacks.embedding_visualization=false\nevaluate.callbacks.max_eval_samples=8\ndataset.test_dataset.batch_size=1\ndataset.test_dataset.workers=0\ninference.k=2\ndataset.inference_dataset.batch_size=1\ndataset.inference_dataset.workers=0\n```\n\n## Data Format\n\nThe MSR-VTT path expects a local video glob and a JSON metadata file:\n\n```yaml\ndataset:\n  train_dataset:\n    dataset_type: msrvtt\n    mp4_urls: \u002Fdata\u002Fvideo\u002F*.mp4\n    metadata: \u002Fdata\u002Fmsrvtt_test_1k.json\n```\n\nList-format metadata rows must include at least `video` and `caption`:\n\n```json\n{\"video_id\": \"video7020\", \"video\": \"video7020.mp4\", \"caption\": \"a woman creating a fondant baby and flower\"}\n```\n\nThe dataset loader derives the video id from the local `.mp4` filename and filters to videos present in the metadata. If a run finds zero videos, check that `mp4_urls` points to a container-local glob and that metadata `video` names match the filenames.\n\n## Model Weights\n\n- Local HF directory: mount it under `\u002Fmodel` and set `model.pretrained_model_path=\u002Fmodel\u002FCosmos-Embed1-224p`.\n- HuggingFace repo: set `model.pretrained_model_path=nvidia\u002FCosmos-Embed1-224p` and pass `HF_TOKEN` if access is gated.\n- Fine-tuned checkpoint: downstream actions default to `\u002Fresults\u002Ftrain\u002Fcosmos_embed1_model_latest.pth`.\n\nVariants:\n\n| Variant | Resolution | Frames | Embedding dim |\n|---|---:|---:|---:|\n| `Cosmos-Embed1-224p` | 224 x 224 | 8 | 256 |\n| `Cosmos-Embed1-336p` | 336 x 336 | 8 | 768 |\n| `Cosmos-Embed1-448p` | 448 x 448 | 8 | 768 |\n\nKeep `model.network.embed_dim`, `model.input_hw`, and `model.network.spatial_resolution` aligned with the selected variant.\n\n## Important Parameters\n\n| Parameter | Notes |\n|---|---|\n| `train.num_gpus` | `1` for single GPU, `>1` auto-launches `torchrun`, `-1` auto-detects visible GPUs. |\n| `train.max_iter` | Main training length. Use `1` only for smoke testing. |\n| `train.optim.optim` | `fused_adamw` is faster when available; `adamw` is safer for smoke and portability. |\n| `model.lora.enabled` | Enables LoRA. Set `model.network.visual_encoder.transformer_engine=false` when LoRA is on. |\n| `model.lora.lora_rank` | LoRA rank. Start with `8`; try `4`, `8`, or `16` for manual or AutoML-style sweeps. |\n| `model.lora.lora_alpha` | LoRA scaling factor. Start with `16`; keep near `2 * lora_rank` unless experiments show otherwise. |\n| `model.lora.lora_dropout` | LoRA dropout. Start with `0.1`; sweep `0.0`, `0.05`, and `0.1` for small datasets. |\n| `model.lora.bias` | Bias policy: `none`, `all`, or `lora_only`. Keep `none` unless intentionally training biases. |\n| `model.lora.use_rslora` \u002F `use_dora` | Optional LoRA variants. Enable one at a time and record the setting with the checkpoint. |\n| `model.lora.target_modules` | Optional module-name patterns for LoRA injection. Leave empty for the default ViT + Q-Former attention\u002FMLP targets. |\n| `model.lora.modules_to_save` | Optional modules to keep fully trainable alongside LoRA. Leave empty unless preserving a task-specific head. |\n| `evaluate.load_dataset_pkl` \u002F `save_dataset_pkl` | Cache evaluation embeddings. |\n| `inference.load_dataset_pkl` \u002F `save_dataset_pkl` | Cache the search database for repeated retrieval. |\n| `export.mode` | `video`, `text`, `combined`, or `huggingface`. |\n| `export.on_cpu` | Recommended for export to avoid device mismatch issues. |\n\n### LoRA and AutoML Notes\n\nFor parameter-efficient fine-tuning, set `model.lora.enabled=true` and keep\n`model.network.visual_encoder.transformer_engine=false`; TAO Core's\nCosmos-Embed1 config notes that PEFT cannot inject adapters into Transformer\nEngine layers. Treat the LoRA fields above as the first candidate parameters\nfor manual tuning or AutoML-style search before unfreezing larger model blocks.\nAvoid changing `target_modules` or `modules_to_save` unless the user explicitly\nneeds custom adapter placement.\n\n## S3 Staging\n\nThe Cosmos-Embed1 CLI consumes local paths and Python globs, not raw `s3:\u002F\u002F...\u002F*.mp4` URIs. For S3-backed runs, first stage a subset or full dataset to the execution host\u002Fcontainer filesystem, then use local paths such as `\u002Fdata\u002Fvideo\u002F*.mp4` in the spec.\n\nRecommended S3 layout for staged MSR-VTT data:\n\n```text\ns3:\u002F\u002Fbucket\u002Fpath\u002Fcosmos-embed\u002Fmsrvtt-subset\u002F\n├── msrvtt_test_1k.json\n└── video\u002F\n    ├── video7020.mp4\n    └── ...\n```\n\nAfter downloading\u002Fsyncing that prefix into the mounted `data\u002F` directory, use the same Docker commands above.\n\n## Outputs\n\n```text\nresults\u002F\n├── train\u002F\n│   ├── cosmos_embed1_model_latest.pth\n│   ├── cosmos_embed1_model_\u003Citer>.pth\n│   └── experiment.yaml\n├── evaluate\u002F\n│   ├── metrics.json\n│   └── experiment.yaml\n├── inference\u002F\n│   ├── results.json\n│   └── experiment.yaml\n├── export\u002F\n│   ├── cosmos_embed1_combined.onnx\n│   └── export_config.yaml\n└── export_hf\u002F\n    └── cosmos_embed1_hf\u002F\n```\n\n## Known Pitfalls\n\n| Symptom | Cause | Fix |\n|---|---|---|\n| `MSRVTTDataset: 0 videos found` | `mp4_urls` is not a local glob or metadata filenames do not match videos. | Mount data into the container and set `mp4_urls=\u002Fdata\u002Fvideo\u002F*.mp4`. |\n| HF download\u002Fauth failure | Missing or invalid `HF_TOKEN`, or model agreement not accepted. | Accept the model terms and pass `-e HF_TOKEN`. |\n| LoRA injection failure | Transformer Engine visual encoder is enabled. | Set `model.network.visual_encoder.transformer_engine=false`. |\n| ONNX\u002FHF export complains about missing components | Export checkpoint is partial or adapter-only. | Use a full checkpoint or configure pretrained visual\u002Ftext sources before export. |\n| CUDA OOM | Batch\u002Fresolution too high for the GPU. | Reduce batch size, use 224p, enable LoRA, or use more GPUs. |\n",{"name":5,"tags":24,"license":15,"metadata":33,"description":7,"allowed-tools":36,"compatibility":37},[25,26,27,28,29,30,31,32],"video","vision-language","vlm","multimodal","retrieval","embedding","cosmos","fine-tuning",{"author":34,"version":35},"NVIDIA Corporation","0.1.0","Read Bash","Requires docker + nvidia-container-toolkit, the published Cosmos-Embed TAO container from versions.yaml, and a HuggingFace token when downloading pretrained `nvidia\u002FCosmos-Embed1-*` weights.","main","99825ad3f3bcc6597ddcc7294a14e6e922f2b67b","skills\u002Ftao-finetune-cosmos-embed",0,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills","https:\u002F\u002Fgithub.com\u002Fjukeyman","https:\u002F\u002FRJBUSINESSSOLUTIONS.ORG","Credit and Finance Expert | Developer\r\n\r\nI'm Rick Jefferson, a seasoned credit and finance expert with over a decade of experience in financial literacy,","2026-07-13 07:03:29",{"source":8,"skillName":5,"commands":48,"prompt":58,"zipAvailable":59},[49,52,55],{"tool":50,"command":51},"npx","npx skills add jukeyman\u002Fjukeyman-skills --skill tao-finetune-cosmos-embed",{"tool":53,"command":54},"bunx","bunx skills add jukeyman\u002Fjukeyman-skills --skill tao-finetune-cosmos-embed",{"tool":56,"command":57},"pnpm","pnpm dlx skills add jukeyman\u002Fjukeyman-skills --skill tao-finetune-cosmos-embed","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002FSKILL.md",true,[61,67,71,75,79,83,87,91,95,99],{"path":62,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":65,"sourceHtmlUrl":66},"BENCHMARK.md","REFERENCE","参考文档",4387,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002FBENCHMARK.md",{"path":68,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":69,"sourceHtmlUrl":70},"evals\u002Fevals.json",787,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Fevals\u002Fevals.json",{"path":72,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":73,"sourceHtmlUrl":74},"references\u002Fskill_info.yaml",2515,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Freferences\u002Fskill_info.yaml",{"path":76,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":77,"sourceHtmlUrl":78},"references\u002Fspec_template_evaluate.yaml",1201,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Freferences\u002Fspec_template_evaluate.yaml",{"path":80,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":81,"sourceHtmlUrl":82},"references\u002Fspec_template_export_hf.yaml",775,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Freferences\u002Fspec_template_export_hf.yaml",{"path":84,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":85,"sourceHtmlUrl":86},"references\u002Fspec_template_export_onnx.yaml",847,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Freferences\u002Fspec_template_export_onnx.yaml",{"path":88,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":89,"sourceHtmlUrl":90},"references\u002Fspec_template_inference.yaml",1156,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Freferences\u002Fspec_template_inference.yaml",{"path":92,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":93,"sourceHtmlUrl":94},"references\u002Fspec_template_train.yaml",2261,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Freferences\u002Fspec_template_train.yaml",{"path":96,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":97,"sourceHtmlUrl":98},"skill-card.md",4089,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Fskill-card.md",{"path":100,"resourceType":101,"resourceTypeDesc":102,"sizeBytes":103,"sourceHtmlUrl":104},"skill.oms.sig","OTHER","其他",6113,"https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Ftao-finetune-cosmos-embed\u002Fskill.oms.sig",[106,114,121,128,135,143],{"skillNo":107,"name":108,"nameZh":6,"description":109,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":110,"licenseFileUrl":6,"sourceHtmlUrl":111,"categories":112,"keywords":113,"publishedAt":19},"01M79ANS2SM329NEP5ZCX106RR","zustand-store-creator","Create zustand store creator operations. Auto-activating skill for Frontend Development.\nTriggers on: zustand store creator, zustand store creator\nPart of the Frontend Development skill category. Use when working with zustand store creator functionality. Trigger with phrases like \"zustand store creator\", \"zustand creator\", \"zustand\".","MIT","https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzustand-store-creator\u002FSKILL.md",[],[],{"skillNo":115,"name":116,"nameZh":6,"description":117,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":110,"licenseFileUrl":6,"sourceHtmlUrl":118,"categories":119,"keywords":120,"publishedAt":19},"01M79AMZKP4YDEZ7EHG1Y7PP74","zero-trust-config-helper","Configure with zero trust config helper operations. Auto-activating skill for Security Advanced.\nTriggers on: zero trust config helper, zero trust config helper\nPart of the Security Advanced skill category. Use when configuring systems or services. Trigger with phrases like \"zero trust config helper\", \"zero helper\", \"zero\".","https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzero-trust-config-helper\u002FSKILL.md",[],[],{"skillNo":122,"name":123,"nameZh":6,"description":124,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":110,"licenseFileUrl":6,"sourceHtmlUrl":125,"categories":126,"keywords":127,"publishedAt":19},"01M79AMJSBCEJQNBTYNAHYN5HM","zapier-integration-helper","Assist with zapier integration helper operations. Auto-activating skill for Business Automation.\nTriggers on: zapier integration helper, zapier integration helper\nPart of the Business Automation skill category. Use when working with APIs or building integrations. Trigger with phrases like \"zapier integration helper\", \"zapier helper\", \"zapier\".","https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fzapier-integration-helper\u002FSKILL.md",[],[],{"skillNo":129,"name":130,"nameZh":6,"description":131,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":110,"licenseFileUrl":6,"sourceHtmlUrl":132,"categories":133,"keywords":134,"publishedAt":19},"01M79AHJZGVMARS13VFQYRR1MP","yaml-config-validator","Validate yaml config validator operations. Auto-activating skill for DevOps Basics.\nTriggers on: yaml config validator, yaml config validator\nPart of the DevOps Basics skill category. Use when configuring systems or services. Trigger with phrases like \"yaml config validator\", \"yaml validator\", \"yaml\".","https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fyaml-config-validator\u002FSKILL.md",[],[],{"skillNo":136,"name":137,"nameZh":6,"description":138,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":110,"licenseFileUrl":139,"sourceHtmlUrl":140,"categories":141,"keywords":142,"publishedAt":19},"01M79AHGDZRN0020RDQSQDPAM8","xvary-stock-research","Thesis-driven equity analysis from public SEC EDGAR and market data; \u002Fanalyze, \u002Fscore, \u002Fcompare workflows with bundled Python tools (Claude Code, Cursor, Codex).","https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fxvary-stock-research\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fxvary-stock-research\u002FSKILL.md",[],[],{"skillNo":144,"name":145,"nameZh":6,"description":146,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":110,"licenseFileUrl":6,"sourceHtmlUrl":147,"categories":148,"keywords":149,"publishedAt":19},"01M79AHCYJ9FV9RMHQ24HDRN33","xss-vulnerability-scanner","Scan xss vulnerability scanner operations. Auto-activating skill for Security Fundamentals.\nTriggers on: xss vulnerability scanner, xss vulnerability scanner\nPart of the Security Fundamentals skill category. Use when working with xss vulnerability scanner functionality. Trigger with phrases like \"xss vulnerability scanner\", \"xss scanner\", \"xss\".","https:\u002F\u002Fgithub.com\u002Fjukeyman\u002Fjukeyman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fxss-vulnerability-scanner\u002FSKILL.md",[],[]]