fix letting user type too low or high emphasis

This commit is contained in:
Tropfchen
2023-10-21 23:49:28 +02:00
parent 18097c3048
commit 4d763f419b
+1
View File
@@ -39,6 +39,7 @@ class EmbeddingPicker:
CATEGORY = "utils"
def concat_embedding(self, text, embedding, emphasis, append):
emphasis = min(max(emphasis, 0.001), 3)
emb = "embedding:" + Path(embedding).stem
emphasis = f"{emphasis:.3f}"