Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add misspell command to CLI #1057

Open
wants to merge 4 commits into
base: dev
Choose a base branch
from
Open

Conversation

wannaphong
Copy link
Member

Fixes #615

Add command line interface for generating misspelled texts.

  • Add misspell command to pythainlp/cli/__init__.py and pythainlp/__main__.py.
  • Implement App class in pythainlp/cli/misspell.py to handle misspelling generation.
  • Add argument parsing for --file, --seed, --misspell-ratio, and --output.
  • Read input file, apply misspelling, and save output file.
  • Update docs/notes/command_line.rst to include documentation for the new misspell command.
  • Add tests for the new command in tests/core/test_cli.py.

For more details, open the Copilot Workspace session.

Fixes #615

Add command line interface for generating misspelled texts.

* Add `misspell` command to `pythainlp/cli/__init__.py` and `pythainlp/__main__.py`.
* Implement `App` class in `pythainlp/cli/misspell.py` to handle misspelling generation.
* Add argument parsing for `--file`, `--seed`, `--misspell-ratio`, and `--output`.
* Read input file, apply misspelling, and save output file.
* Update `docs/notes/command_line.rst` to include documentation for the new `misspell` command.
* Add tests for the new command in `tests/core/test_cli.py`.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/PyThaiNLP/pythainlp/issues/615?shareId=XXXX-XXXX-XXXX-XXXX).
Copy link

sonarqubecloud bot commented Jan 8, 2025

@coveralls
Copy link

Coverage Status

coverage: 52.888% (+0.1%) from 52.753%
when pulling 3367c03 on wannaphong/add-misspell-command
into 7332984 on dev.

@coveralls
Copy link

Coverage Status

coverage: 52.914% (+0.2%) from 52.753%
when pulling 3367c03 on wannaphong/add-misspell-command
into 7332984 on dev.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Command line for generating misspell texts
2 participants
  NODES
COMMUNITY 2
Note 2
Project 5
USERS 1