segmentit icon indicating copy to clipboard operation
segmentit copied to clipboard

建议出个像nodejieba和node-segment差不多的关键词提取模式

Open LehaoLin opened this issue 3 years ago • 1 comments

建议出个像nodejieba和node-segment差不多的关键词提取模式

通过不同词的权重来对关键词进行提取 nodejieba关键词提取:

var nodejieba = require("nodejieba");
var topN = 4;
console.log(nodejieba.extract("升职加薪,当上CEO,走上人生巅峰。", topN));
//[ { word: 'CEO', weight: 11.739204307083542 },
//  { word: '升职', weight: 10.8561552143 },
//  { word: '加薪', weight: 10.642581114 },
//  { word: '巅峰', weight: 9.49395840471 } ]

LehaoLin avatar Apr 02 '21 10:04 LehaoLin

好主意,不过我最近在开发别的开源项目,这个排期排到明年去了(

linonetwo avatar Apr 03 '21 12:04 linonetwo