kuroshiro icon indicating copy to clipboard operation
kuroshiro copied to clipboard

Not found errors in Browser

Open Code-Kat opened this issue 3 years ago • 3 comments

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;
};

Code-Kat avatar Nov 10 '21 02:11 Code-Kat

did you solve this?

jgaynor17 avatar Apr 02 '23 16:04 jgaynor17

also looking for a solution to this

owen-will-m avatar Apr 25 '23 00:04 owen-will-m

You can clone the dicts file from kuromoji's npm

cyfung1031 avatar May 26 '23 07:05 cyfung1031