句向量是指将语句映射至固定维度的实数向量。
将不定长的句子用定长的向量表示,为NLP下游任务提供服务。
句向量应用:
运行成功后,命令行应该看到下面的信息:
... # 测试语句: [INFO ] - input Sentence1: This model generates embeddings for input sentence [INFO ] - input Sentence2: This model generates embeddings # 向量维度: [INFO ] - Vector dimensions: 384 # 生成向量: [INFO ] - Sentence1 embeddings: [-0.14147712, -0.025930656, -0.18829542,..., -0.11860573, -0.13064586] [INFO ] - Sentence2 embeddings: [-0.43392915, -0.23374224, -0.12924, ..., 0.0916177, 0.080070406] #计算相似度: [INFO ] - Similarity: 0.7306041
http://www.aias.top/
https://github.com/mymagicpower/AIAS
https://gitee.com/mymagicpower/AIAS