diff --git a/llm-modules/local-embedding/src/main/kotlin/cc/unitmesh/cf/LocalEmbedding.kt b/llm-modules/local-embedding/src/main/kotlin/cc/unitmesh/cf/LocalEmbedding.kt index b67df7b..b94d3fd 100644 --- a/llm-modules/local-embedding/src/main/kotlin/cc/unitmesh/cf/LocalEmbedding.kt +++ b/llm-modules/local-embedding/src/main/kotlin/cc/unitmesh/cf/LocalEmbedding.kt @@ -68,7 +68,7 @@ open class LocalEmbedding( companion object { /** - * Create a new instance of [STEmbedding] with default model. + * Create a new instance of [LocalEmbedding] with default model. * We use official model: [all-MiniLM-L6-v2](https://huggingface.co/sentence-transformers/all-MiniLM-L6-v2) * We can use [optimum](https://github.com/huggingface/optimum) to transform the model to onnx. */ diff --git a/llm-modules/local-embedding/src/main/kotlin/cc/unitmesh/cf/STEmbedding.kt b/llm-modules/local-embedding/src/main/kotlin/cc/unitmesh/cf/STEmbedding.kt deleted file mode 100644 index b8a2d20..0000000 --- a/llm-modules/local-embedding/src/main/kotlin/cc/unitmesh/cf/STEmbedding.kt +++ /dev/null @@ -1,19 +0,0 @@ -package cc.unitmesh.cf - -import ai.djl.huggingface.tokenizers.HuggingFaceTokenizer -import ai.onnxruntime.OrtEnvironment -import ai.onnxruntime.OrtSession - -@Deprecated("Use LocalEmbedding instead") -class STEmbedding( - private val tokenizer: HuggingFaceTokenizer, - private val session: OrtSession, - private val env: OrtEnvironment, -) : LocalEmbedding(tokenizer, session, env) { - - companion object { - fun create(): LocalEmbedding { - return LocalEmbedding.create() - } - } -} diff --git a/server/src/test/kotlin/RagIntegrationTests.kt b/server/src/test/kotlin/RagIntegrationTests.kt index 7de3c8b..fbd0a4c 100644 --- a/server/src/test/kotlin/RagIntegrationTests.kt +++ b/server/src/test/kotlin/RagIntegrationTests.kt @@ -1,5 +1,4 @@ import cc.unitmesh.cf.LocalEmbedding -import cc.unitmesh.cf.STEmbedding import cc.unitmesh.cf.infrastructure.llms.embedding.SentenceTransformersEmbedding import cc.unitmesh.nlp.embedding.Embedding import cc.unitmesh.rag.document.Document