Open-source LLM knowledge platform: turn raw documents into a queryable RAG, an autonomous reasoning agent, and a self-maintaining Wiki.
Go agentagenticaichatbotdsh-pluginembeddingsevaluationgenerative-aigolangknowledge-basellmmulti-tenantollamaopenaiquestion-answeringragrerankingsemantic-searchvector-searchwiki
fix(embedding): remove hardcoded TruncatePromptTokens in BatchEmbed
begoniezhao5082460cc01c
diff --git a/internal/models/embedding/weknoracloud.go b/internal/models/embedding/weknoracloud.goindex 158d7af60..b49bfcb25 100644--- a/internal/models/embedding/weknoracloud.go+++ b/internal/models/embedding/weknoracloud.go@@ -78,7 +78,7 @@ func (e *WeKnoraCloudEmbedder) Embed(ctx context.Context, text string) ([]float3}func (e *WeKnoraCloudEmbedder) BatchEmbed(ctx context.Context, texts []string) ([][]float32, error) {- reqBody := weKnoraCloudEmbedRequest{Model: e.effectiveModelName(), Input: texts, TruncatePromptTokens: 512}+ reqBody := weKnoraCloudEmbedRequest{Model: e.effectiveModelName(), Input: texts}bodyBytes, err := json.Marshal(reqBody)if err != nil {return nil, fmt.Errorf("weknoracloud embedder: marshal: %w", err)