PHP音节检测

编程入门 行业动态 更新时间:2024-10-18 14:15:04
本文介绍了PHP音节检测的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我想找到一种方法,可以用PHP将单词拆分成音节.例如,单词"nevermore"遍历了detect_syllables(),将返回"nev-er-more".有没有好的API或其他东西?

I would like to find a way to be able to split a word into syllables with PHP. For example, the word "nevermore" ran through detect_syllables(), would return "nev-er-more." Are there any good APIs or something out there?

推荐答案

Frank Liang撰写了一篇有用的 PHd论文对此描述了一种非常精确的算法:它写在25年前,仍然有效.但是我不知道在PHP中有任何实现方式

There's a useful PHd thesis paper by Frank Liang that describes an exceptionally accurate algorithm for this: written over 25 years ago, it's still valid. But I'm not aware of any implementation in PHP

编辑

一个快速的Google已经识别出此链接,该链接指向PHP中的文本统计库,其中包括用于单词内音节计数的算法(以及其他可读性测量算法).您应该可以在这里找到用于音节分割的代码.

A quick google has identified this link to a Text Statistics library in PHP, which includes algorithms for syllable counting within words (among other readability measuring algorithms). You should be able to find the code for syllable splitting here.

更多推荐

PHP音节检测

本文发布于:2023-11-29 20:21:20,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1647526.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:音节   PHP

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!