Fix ratio (#162)

* fix: fixed the issue where an error would be reported when only setting the proportioning quantity when creating a proportioning task

* fix: prevent adding the same file multiple times

* fix: implement a more flexible matching strategy, allowing only the tag name to be configured for matching
This commit is contained in:
hefanli
2025-12-11 17:45:16 +08:00
committed by GitHub
parent bb8641bea2
commit 8f529952f6
2 changed files with 21 additions and 10 deletions

View File

@@ -46,7 +46,7 @@ class DatasetFileTag(BaseModel):
tags.append(tag_values)
# 如果 from_name 不为空,添加前缀
if self.from_name:
tags = [f"{self.from_name}@{tag}" for tag in tags]
tags = [{"label": self.from_name, "value": tag} for tag in tags]
return tags