当前位置:网站首页>query词权重, 搜索词权重计算
query词权重, 搜索词权重计算
2022-07-02 02:13:00 【人工智能曾小健】
query词权重(term weighting)是为了计算query分词后,每个term的重要程度。常用的指标是tf*idf(query中term的tf大部分为1),即一个term的出现次数越多,表明信息量越少,相反一个term的次数越少,表明信息量越多。但是term的重要程度并不是和term的出现次数呈严格单调关系,并且idf缺乏上下文语境的考虑(比如“windows”在“windows应用软件”中比较重要,而在“windows xp系统iphone xs导照片”的重要性就比较低)。词权重计算作为一种基础资源在文本相关性,丢词等任务中有着重要作用,其优化方法主要分为下面三类:
1)基于语料统计
2)基于点击日志
3)基于有监督学习
本文首先介绍一些基于语料统计的计算方法。
一、imp(importance的缩写)
idf的一个缺点是仅仅依靠词频比较,imp从在query中的重要性占比基础上,采用迭代的计算方式优化词的静态赋权,其计算过程如下:

其中BT为term的imp值,初始值可设为1,Tmp_i是query中的第i个term的重要性占比,N指所有包含第i个term的query数目。
二、DIMP(Dynamic imp)
idf和imp的一个共同缺点是其都是静态的赋权。DIMP根据query的上下文计算每个term的动态赋权,其主要假设是任意query中的词权重可以由相关query 的词权重来计算,计算过程可分为两部分:
1) 自顶向下的query树构建
根据实际场景中采用不同的构建方法,这里介绍一种在搜索中的做法。如下图,给定query作为根节点,首先获取query的相关query作为第二层节点,在第二层的基础上,枚举相关query的子query作为第三层节点,最后一层为分词后的term节点。因此query树种的节点都是不同粒度的文本串,边都是文本串间的相关关系。在拍卖词推荐任务中,用户query都是比较短的关键词,其可以通过拍卖词间的共同购买关系构建对应的query树。
边栏推荐
- How to debug apps remotely and online?
- leetcode2305. Fair distribution of biscuits (medium, weekly, shaped pressure DP)
- leetcode373. 查找和最小的 K 对数字(中等)
- Calculation (computer) code of suffix expression
- If you want to rewind the video picture, what simple methods can you use?
- Sword finger offer 29 Print matrix clockwise
- 734. Energy stone (greed, backpack)
- From January 11, 2007 to January 11, 2022, I have been in SAP Chengdu Research Institute for 15 years
- Redis环境搭建和使用的方法
- DNS domain name resolution
猜你喜欢

Spend a week painstakingly sorting out the interview questions and answers of high-frequency software testing / automated testing

Opengauss database backup and recovery guide

MySQL约束与多表查询实例分析

Software development life cycle -- waterfall model

321. Chessboard segmentation (2D interval DP)

Selection of field types for creating tables in MySQL database

SQLite 3 of embedded database

RTL8189FS如何关闭Debug信息

CSDN article underlined, font color changed, picture centered, 1 second to understand

大厂裁员潮不断,双非本科出身的我却逆风翻盘挺进阿里
随机推荐
MySQL view concept, create view, view, modify view, delete view
No programming code technology! Four step easy flower store applet
Based on configured schedule, the given trigger will never fire
Cross domain? Homology? Understand what is cross domain at once
WebGPU(一):基本概念
CSDN article underlined, font color changed, picture centered, 1 second to understand
Cesium dynamic diffusion point effect
Parted command
As a software testing engineer, will you choose the bank post? Laolao bank test post
Golang lock
Open that kind of construction document
With the innovation and upgrading of development tools, Kunpeng promotes the "bamboo forest" growth of the computing industry
Quality means doing it right when no one is looking
Redis有序集合如何使用
OpenCASCADE7.6编译
Architecture evolution from MVC to DDD
Niuke - Huawei question bank (51~60)
Using mongodb in laravel
The difference between new and malloc
Construction and maintenance of business websites [12]