en: G2PEnPhonemizer calls nltk.download each time it is built
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 80/100
Research direction
Read scriptconv/phonemizers/en.py lines 166-168, where G2PEnPhonemizer.__init__ calls nltk.download twice, then compare with the no-download rule stated at scriptconv/phonemizers/mul.py line 77. Reproduce by constructing G2PEnPhonemizer() twice offline and watching the second build hit the network. Replace the downloads with a lookup of data already on disk, and raise an error naming the install command when a data set is missing. Done means two consecutive builds print no download error and a missing corpus produces that named error.
Written by the indexing model from the issue text.
Description
🤖 Auto-generated by Claude Opus 5.5 (claude-opus-5-5) via Claude Code — NOT human-reviewed. Verify before acting.
Verified against source: the lines and outputs below were read and run on scriptconv origin/dev 03b4c08.
Observed
G2PEnPhonemizer.__init__ calls nltk.download('averaged_perceptron_tagger_eng') and nltk.download('cmudict') each time a backend is built (scriptconv/phonemizers/en.py lines 166 to 168). Each call reaches the network or checks the local NLTK data, and offline it prints an error.
Expected
The backend loads the NLTK data that is already on disk, and downloads nothing. The other backends follow the rule in scriptconv/phonemizers/mul.py line 77: "scriptconv never downloads models". A missing data set gives an error that names the command that installs it.
Reproduce
from scriptconv.phonemizers.en import G2PEnPhonemizer
G2PEnPhonemizer()
G2PEnPhonemizer() # calls nltk.download again
Where
scriptconv/phonemizers/en.py lines 166 to 168.
- Dominant language
- Python
- Stars
- 4
- Forks
- 1
- Avg merge
- 8h 57m
- Merged PRs (30d)
- 118
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from TigreGotico/scriptconv
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
TigreGotico/scriptconv#412 ·
Maintainers usually reply within 1 day
-
docs: the ByT5 docstring says it downloads, and the _stress docstring says stressonnx is not on PyPIOpen
Difficulty 1/5 Under an hour Newbie friendliness 88/100
TigreGotico/scriptconv#411 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
TigreGotico/scriptconv#409 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
TigreGotico/scriptconv#408 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
TigreGotico/scriptconv#394 ·
Maintainers usually reply within 1 day
All issues in TigreGotico/scriptconv
Similar issues
-
eegprep-lean: set channel types from the Zarr group's channel_typePossibly taken @claude claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
sccn/eegprep#668 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
blacklanternsecurity/bbot#3679 ·
Maintainers usually reply within 2 days
-
Link Checker ReportOpenBot Type: Bug Type: Documentation
Difficulty 1/5 Under an hour Newbie friendliness 85/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
speakeasy-api/speakeasy#2159 ·
Maintainers usually reply within 1 day