arXiv:2602.05266cs.AI2026-02被引 1

提出新相似度度量recos,更好捕捉语义向量间的非线性关系。

Beyond Cosine Similarity

  • 基于更紧的点积上界,设计新相似度recos,用排序后分量归一化。
  • 在11种嵌入模型上测试,recos与人工判断相关性更高。
  • 适合需要精准语义匹配的场景,如文本相似度分析。

余弦相似度作为向量空间中语义相似性的标准度量,其数学基础源于柯西-施瓦茨不等式,本质上仅能捕捉线性关系,难以建模真实语义空间中的复杂非线性结构。本文推导出比经典柯西-施瓦茨界更紧的点积上界,由此直接导出recos:一种将点积按向量分量排序后归一化的相似度度量。recos将完全相似的条件从严格的线性依赖放宽为序数一致性,从而能捕捉更广泛的关联模式。在11种嵌入模型(涵盖静态、上下文和通用类型)上的大量实验表明,recos在标准语义文本相似性(STS)基准上始终优于传统余弦相似度,与人类判断的相关性更高。本工作确立了recos作为一种数学严谨且实证优越的替代方案,显著提升复杂嵌入空间中的语义分析精度。

原文摘要 · Abstract (English)

Cosine similarity, the standard metric for measuring semantic similarity in vector spaces, is mathematically grounded in the Cauchy-Schwarz inequality, which inherently limits it to capturing linear relationships--a constraint that fails to model the complex, nonlinear structures of real-world semantic spaces. We advance this theoretical underpinning by deriving a tighter upper bound for the dot product than the classical Cauchy-Schwarz bound. This new bound leads directly to recos, a similarity metric that normalizes the dot product by the sorted vector components. recos relaxes the condition for perfect similarity from strict linear dependence to ordinal concordance, thereby capturing a broader class of relationships. Extensive experiments across 11 embedding models--spanning static, contextualized, and universal types--demonstrate that recos consistently outperforms traditional cosine similarity, achieving higher correlation with human judgments on standard Semantic Textual Similarity (STS) benchmarks. Our work establishes recos as a mathematically principled and empirically superior alternative, offering enhanced accuracy for semantic analysis in complex embedding spaces.

语义相似度向量表示相似度度量

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。