Instructions to use HopitAI/moda-duo with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- OpenCLIP
How to use HopitAI/moda-duo with OpenCLIP:
import open_clip model, preprocess_train, preprocess_val = open_clip.create_model_and_transforms('hf-hub:HopitAI/moda-duo') tokenizer = open_clip.get_tokenizer('hf-hub:HopitAI/moda-duo') - Notebooks
- Google Colab
- Kaggle
File size: 2,568 Bytes
326e3fb | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 | {
"name": "MODA Duo",
"artifact_type": "retrieval_system",
"description": "Two open constituents, one answer per query. Each query is routed to whichever constituent suits its shape: short catalogue titles to MODA Pro Lite+, longer descriptions to MODA. One text forward and one nearest-neighbour query per search.",
"additional_learned_parameters": 0,
"constituents": {
"moda": {
"base_model": "Marqo/marqo-fashionSigLIP",
"parameters": 203155970,
"embedding_dimension": 768,
"gallery": {
"views": {
"official": 1.0,
"pad_white": 0.25,
"center_crop": 0.25
},
"normalize": true
},
"query": {
"prompts": {
"raw": 1.0,
"product": 0.25
},
"normalize": true
},
"prompt_templates": {
"raw": "{query}",
"product": "a fashion product photo of {query}"
}
},
"moda_pro_lite_plus": {
"base_model": "HopitAI/moda-pro-lite",
"parameters": 213159938,
"embedding_dimension": 768,
"gallery": {
"views": {
"official": 1.0,
"pad": 0.25,
"foreground_pad": 0.25
},
"normalize": true
},
"query": {
"prompts": {
"raw": 1.0,
"photo": 0.25
},
"normalize": true
},
"prompt_templates": {
"raw": "{query}",
"photo": "a photo of {query}"
}
}
},
"router": {
"kind": "query_word_count",
"rule": "words(query) <= threshold -> moda_pro_lite_plus, else moda",
"threshold": 36,
"pluggable": true,
"note": "The router is a callable; any policy mapping a query to a constituent name may replace it."
},
"serving": {
"stored_vectors_per_item": 2,
"indexes": 2,
"text_forwards_per_query": 2,
"encoders_run_per_query": 1,
"ann_queries_per_search": 1,
"rerank": false
},
"selection": {
"criterion": "maximin regret against the per-regime oracle (better of the two constituents), tie-break mean regret",
"target_benchmarks_accessed_during_selection": false,
"frozen_before_target_evaluation": true,
"receipt": "results/multiview_recipe_rebuild/SELECTION_duo.json",
"threshold_selected_on": "development data only (OpenVTON validation 4,989 + GLAMI 2,000 x 3 query views)"
},
"evaluation": {
"protocol": "full corpus, all ground-truth queries, MAP@10, pytrec_eval map_cut.10, paired bootstrap 10000 @ 20260728",
"receipt": "results/duo_target_eval.json"
}
} |