Downloads · 30 days
0
mikaassa/temu-for-bundle
temu-for-bundle is a machine learning model from mikaassa. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as apache-2.0.
本仓库是一个本地商品组货检索包:图片输入后调用 Kimi 生成组货方向,再用训练好的 CLIP / FAISS listing 索引召回 Temu 商品。仓库包含运行所需的代码、模型、索引和 metadata,大文件通过 Hugging Face Git LFS 存储。
Downloads · 30 days
0
Access
Public
Updated Aug 21, 2026
Repo size
2.8 GB
Likes
0
Public
Click a slice to open those files.
.pt692 MB · 25%
From the Hugging Face model README
本仓库是一个本地商品组货检索包:图片输入后调用 Kimi 生成组货方向,再用训练好的 CLIP / FAISS listing 索引召回 Temu 商品。仓库包含运行所需的代码、模型、索引和 metadata,大文件通过 Hugging Face Git LFS 存储。
app/listing_search.html # 9990 前端页面
work/full_listing_server.py # 纯 listing CLIP + Kimi 组货服务
work/full_clip_server.py # 旧版 image/listing CLIP 服务
work/build_full_listing_index.py # listing 索引构建脚本
models/open_clip_pytorch_model.bin # OpenCLIP 基础权重
data/yunqi_clip_training/last_checkpoint.pt # 训练 checkpoint
data/full_listing_index/products_listing.index # FAISS listing 索引
data/full_listing_index/products_listing_embeddings.npy
data/full_listing_index/products_listing_meta.json
data/full_clip_index/products_full_prices.json
config.example.json # 配置模板
需要安装 Git LFS:
git lfs install
git clone https://huggingface.co/mikaassa/temu-for-bundle
cd temu-for-bundle
git lfs pull
复制配置模板:
copy config.example.json config.json
编辑 config.json:
{
"kimi": {
"api_key": "你的 Kimi / Moonshot API Key",
"endpoint": "https://api.moonshot.cn/v1/chat/completions",
"model": "kimi-k2.6",
"temperature": 0.6,
"max_completion_tokens": 1200
}
}
config.json 已被 .gitignore 忽略,不要提交真实 API key。
也可以使用环境变量覆盖:
$env:MOONSHOT_API_KEY="你的 key"
$env:KIMI_ENDPOINT="https://api.moonshot.cn/v1/chat/completions"
$env:KIMI_MODEL="kimi-k2.6"
建议使用已有 PyTorch / FAISS / OpenCLIP 环境。如果本机环境已经装好依赖:
cd temu-for-bundle
python .\work\full_listing_server.py
然后打开:
http://127.0.0.1:9990/
图片 -> Kimi 生成 10 个组货方向 -> 英文 listing prompt -> FAISS/CLIP 召回 -> 商品卡片
前端支持两个模式:
商品主图会从 Excel metadata 中记录的 MAINIMAGE CDN 地址加载;CDN 失败的图片会被前端过滤掉。
git lfs pullconfig.json 提交到仓库data/ 和 models/,否则才回退到历史本地路径