kuroshiro
kuroshiro copied to clipboard
Not found errors in Browser
GET http://localhost:3000/url/to/dictFiles/base.dat.gz 404 (Not Found)
GET http://localhost:3000/url/to/dictFiles/unk_pos.dat.gz404 (Not Found)
I am getting about 30 errors such as the ones above in my console when I try to use kuroshiro.
I have installed kuroshiro, kuroshiro-analyzer-kuromoji, and kuromiji through npm. Framework: Next.js
import Kuroshiro from "kuroshiro";
import KuromojiAnalyzer from "kuroshiro-analyzer-kuromoji";
export const kanjiToRomaji = async (kanji: string) => {
const kuroshiro = new Kuroshiro();
await kuroshiro.init(new KuromojiAnalyzer());
const romaji = await kuroshiro.convert(kanji, { to: "romaji" });
return romaji;
};
did you solve this?
also looking for a solution to this
You can clone the dicts file from kuromoji's npm