How to add words to sphinx?

2020-07-24 04:30发布

问题:

How to add my words to sphinx using java? Iam a new learner for learning sphinx,I just know how to use it.I want to learn adding my words.anybody can help me.

回答1:

Add the word to the dictionary file sphinx4/models/acoustic/wsj/dict/cmudict.0.6d:

ABACK AH B AE K

ABACO AE B AH K OW

ABACUS AE B AH K AH S

PINTREST P IH N T R EH S T

Then add the word to the grammar sphinx4/src/apps/edu/cmu/sphinx/demo/helloworld/hello.gram:

#JSGF V1.0;

grammar hello;

public = (Good morning | Hello) ( Bhiksha | Evandro | Paul | Philip | Rita | Will | Pintrest );

Recompile and run HelloWorld demo, it will understand a new word.

If the word is already in the dictionary, you can just add it to the grammar.



标签: sphinx4