Skip to main content

JPFreq

Tests Docs License: MIT Code Style: Black Ruff

JPFreq is a frequency processor for Japanese text. It uses the Cython wrapper for MeCab Fugashi to process Japanese text.

Installation

  1. Install Fugashi and Unidic
    pip install fugashi[unidic]
    python3 -m unidic download
    
  2. Install JPFreq
    pip install jpfreq
    

Usage

For detailed usage, see the documentation.

Getting the most frequent words

from jpfreq.jp_frequency_list import JapaneseFrequencyList

freq_list = JapaneseFrequencyList()
freq_list.process_line("私は猫です。")

print(freq_list.get_most_frequent())

Reading from a file

from jpfreq.jp_frequency_list import JapaneseFrequencyList

freq_list = JapaneseFrequencyList()
freq_list.process_file("path/to/file.txt")

print(freq_list.get_most_frequent())

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jpfreq-0.4.0.tar.gz (38.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jpfreq-0.4.0-py3-none-any.whl (14.5 kB view details)

Uploaded Python 3

File details

Details for the file jpfreq-0.4.0.tar.gz.

File metadata

  • Download URL: jpfreq-0.4.0.tar.gz
  • Upload date:
  • Size: 38.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.18

File hashes

Hashes for jpfreq-0.4.0.tar.gz
Algorithm Hash digest
SHA256 ae927217f06cfe621f1a36c71acb91e3e70877d5f53ac7dd2e2abbe5d5337d36
MD5 c5cec3d64b8348ab52c436a4029b375e
BLAKE2b-256 68e50fafb1636da1486298b584eabccb81db5f8413811a5c65e14eb7b7b7985e

See more details on using hashes here.

File details

Details for the file jpfreq-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: jpfreq-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 14.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.18

File hashes

Hashes for jpfreq-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3d070e1aae4e22816650f6ca274598c32225b2ed413d63f43434960b165045fb
MD5 44a846872b7a897199322656f42f1e5e
BLAKE2b-256 9a545298d70a1bce3f5d4d6e72c4bb2405cf4ef124cb46bf4e12ac592f584877

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.4.0 This release

2 files

0.3.0

2 files

0.2.2

2 files

0.2.1

2 files

0.1.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page