From 76e7668ab0c0bbffcebce19c989a5762f5c911c3 Mon Sep 17 00:00:00 2001 From: goulustis Date: Mon, 13 Oct 2025 21:44:15 +0800 Subject: [PATCH] pass in direction --- lang_agent/rag/emb.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lang_agent/rag/emb.py b/lang_agent/rag/emb.py index 675ced3..9143fd7 100644 --- a/lang_agent/rag/emb.py +++ b/lang_agent/rag/emb.py @@ -14,8 +14,8 @@ class QwenEmbeddings(Embeddings): api_key: str, model: str = "text-embedding-v4", max_workers: int = 5, - embedding_dimension: int = 512, - batch_size: int = 10, # DashScope supports up to 10 texts per batch + embedding_dimension: int = 512, + batch_size: int = 10, # NOTE: DashScope supports up to 10 texts per batch rate_limit_delay: float = 0.00001): """ Initialize Qwen embeddings @@ -45,7 +45,8 @@ class QwenEmbeddings(Embeddings): # DashScope supports batch processing natively response = TextEmbedding.call( model=self.model, - input=texts # Pass list directly + input=texts, # Pass list directly + dimension=self.embedding_dimension ) if response.status_code == 200: