Giter Site home page Giter Site logo

umjammer / vavi-speech Goto Github PK

View Code? Open in Web Editor NEW
4.0 3.0 0.0 714 KB

๐Ÿ—ฃ Java Text to Speech (JSAPI) engines (google cloud, cocoa, aquestalk(ใ‚†ใฃใใ‚Š))

C 3.07% Java 95.39% Objective-C 1.54%
java text-to-speech google-cloud-text-to-speech rococoa jitpack aquestalk yukkuri

vavi-speech's Introduction

Release Java CI CodeQL Java Parent

vavi-speech

ใ‚†ใฃใใ‚ŠDuke

Text to Speech (JSAPI) engines for Java and Japanese phonemeizers

Staus

Type Description Staus SPI Status Quality Comment
AquesTalk JNI โœ… โœ… ๐Ÿ˜ 32bit only
AquesTalk JNA โœ… โœ… ๐Ÿ˜ 32bit only
AquesTalk2 JNI - - mac: intel only
AquesTalk10 JNA โœ… โœ… ๐Ÿ˜ mac: intel only
Google Cloud Text To Speech Google Cloud Text To Speech โœ… โœ… ๐Ÿ‘‘
Rococoa Rococoa, JNA โœ… โœ… ๐Ÿ˜ƒ
FreeTTS FreeTTS - โœ… ๐Ÿ’ฉ not included (test only)

Kanji to Kana converter

Type Description Staus Quality Comment
Kromoji โœ… ๐Ÿ˜ number, alphabet
Sen โœ… ๐Ÿ˜ number, alphabet
Sudachi โœ… ๐Ÿ˜ ๅŠฉ่ฉž(ใฏ,ใธ), number, alphabet
YahooJapan Furigana Web โœ… ๐Ÿ˜ ๅŠฉ่ฉž(ใฏ,ใธ)
YahooJapan MA Web -
Goo Furigana Web โœ… ๐Ÿ˜ ๅŠฉ่ฉž(ใฏ,ใธ)
Rococoa โœ… ๐Ÿ˜ƒ ๆ•ฐๅญ—+ๅŠฉๆ•ฐ่ฉž

selected by aquestalk10.properties

Yakuwarigo Converter

name type status qyality comment
simple SimpleConverter โœ… ๐Ÿ’ฉ
ojosama YakuearigoConverter โœ… ๐Ÿ˜
zundamon YakuearigoConverter ๐Ÿšง

Install

meven

AquesTalk10

  • place AquesTalk10.framework into ~/Library/Frameworks
  • create symbolic link AquesTalk10.framework/AquesTalk as AquesTalk10.framework/AquesTalk10
  • write aquesTalk10DevKey into local.properties

Google Cloud Text To Speech

  • get token as json
  • set environment variable "GOOGLE_APPLICATION_CREDENTIALS" your_json_path

Sen

$ git clone https://gitlab.com/umjammer/sen.git
$ mvn install
  • set $SEN/src/main/home as sen.home in local.properties
  • edit aquestalk10.properties like below
$ cat src/test/resources/aquestalk10.properties
phonemer=vavi.speech.phoneme.SenJaPhonemer

Sudachi

$ cd vavi-speech
$ curl -o sudachi-dictionary-20210802-full.zip http://sudachi.s3-website-ap-northeast-1.amazonaws.com/sudachidict/sudachi-dictionary-20210802-full.zip
$ tar zxvf sudachi-dictionary-20210802-full.zip src/test/resources/sudachi/
  • edit aquestalk10.properties like below
$ cat src/test/resources/aquestalk10.properties
phonemer=vavi.speech.phoneme.SudachiJaPhonemer

goo to hiragana

$ cat src/test/resources/aquestalk10.properties
phonemer=vavi.speech.phoneme.GooFuriganaJaPhonemer

yahoo! japan

$ cat src/test/resources/aquestalk10.properties
phonemer=vavi.speech.phoneme.YahooJapanJaPhonemer

Kuromoji

  • default
  • edit aquestalk10.properties like below
$ cat src/test/resources/aquestalk10.properties
phonemer=vavi.speech.phoneme.KuromojiJaPhonemer

a3rt

References

TODO

Morphological Analyzer

NLP

Alphabet -> Kana dictionary

Kanji -> Kana

Romaji -> Kana

Proofreading

vavi-speech's People

Contributors

umjammer avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

vavi-speech's Issues

maybe a java bug

old code (after the patch below)

diff --git a/src/main/java/vavi/speech/phonemizer/SudachiJaPhonemizer.java b/src/main/java/vavi/speech/phonemizer/SudachiJaPhonemizer.java
index c0045e2..8314106 100644
--- a/src/main/java/vavi/speech/phonemizer/SudachiJaPhonemizer.java
+++ b/src/main/java/vavi/speech/phonemizer/SudachiJaPhonemizer.java
@@ -38,12 +38,14 @@ public class SudachiJaPhonemizer implements JaPhonemizer {
 
     public SudachiJaPhonemizer() {
         try {
-            Config config = Config.fromClasspath("sudachi.json");
-            Dictionary dict = new DictionaryFactory().create(config);
+        Config config = Config.fromClasspath("sudachi.json");
+        try (
+            Dictionary dict = new DictionaryFactory().create(config)) {
             tokenizer = dict.create();
-            Runtime.getRuntime().addShutdownHook(new Thread(() -> {
-                try { dict.close(); } catch (IOException e) { throw new UncheckedIOException(e); }
-            }));
+//            Runtime.getRuntime().addShutdownHook(new Thread(() -> {
+//                try { dict.close(); } catch (IOException e) { throw new UncheckedIOException(e); }
+//            }));
+            }
         } catch (IOException e) {
             throw new UncheckedIOException(e);
         }

causes crash around java.nio.DirectIntBufferU#get(int).

hs_err_pid92309.log

after the patch above, this program will have a bug that closing dict before using that.

but on catalina the program after the patch works, it contains a bug though.

$ java -version                                                                                                                                                                                                master
java version "1.8.0_301"
Java(TM) SE Runtime Environment (build 1.8.0_301-b09)
Java HotSpot(TM) 64-Bit Server VM (build 25.301-b09, mixed mode)
nsano@nsanomac3 02:22:08 ~/src/java/vavi-speech2 
$ uname -a                                                                                                                                                                                                     master
Darwin nsanomac3 19.6.0 Darwin Kernel Version 19.6.0: Tue Jun 21 21:18:39 PDT 2022; root:xnu-6153.141.66~1/RELEASE_X86_64 x86_64 i386 Darwin

on the other hand, on monterey the program after patch cause crash. java should throw an exception.

$ java -version                                                                                                                                                                                                   0.1.7
java version "1.8.0_341"
Java(TM) SE Runtime Environment (build 1.8.0_341-b10)
Java HotSpot(TM) 64-Bit Server VM (build 25.341-b10, mixed mode)
$ uname -a                                                                                                                                                                                                        0.1.7
Darwin nsanomac4 21.6.0 Darwin Kernel Version 21.6.0: Thu Sep 29 20:12:57 PDT 2022; root:xnu-8020.240.7~1/RELEASE_X86_64 x86_64

i couldn't create a small sample bug reproducer. because there is no way to create a java.nio.DirectIntBufferU instance.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.