Open boomker opened 1 week ago
如下代码:
local word_yin_code = input:sub(1, 4) local wd = env.mem:dictiter_lookup(word_yin_code, true, 50) -- expand_search for entry in wd:iter() do local et = entry.text logger.writeLog("xx: " .. et) end
发现日志里没有打印出词典里的词组,可以打印出单字,这是为什么呢,是姿势不对,还是说本来就不支持 @shewer ,大佬有空帮忙指点一下,多谢🙏
看不出有什麼問題,會不會是 word_yin_code 的字根 沒有詞組 或是 權重排不上 50個之內
Dictionary::LookupWords () 會經過 prism 轉換再查 table 字典 如果 prism 轉換出多套字根 再去查table 說不定 50個不夠
我用的是双拼,两个编码字符为音码,比如 输入 uiui 会出现二字词组,我现在想按下 /xy后, 过滤词组中形码包含xy 条目
uiui
/xy
xy
如下代码:
发现日志里没有打印出词典里的词组,可以打印出单字,这是为什么呢,是姿势不对,还是说本来就不支持 @shewer ,大佬有空帮忙指点一下,多谢🙏