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

chore: 1.x - nltk upgrade, use nltk.download('punkt_tab') #8254

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion haystack/nodes/preprocessor/preprocessor.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ def __init__(
nltk.data.find("tokenizers/punkt")
except LookupError:
try:
nltk.download("punkt")
nltk.download("punkt_tab")
except FileExistsError as error:
logger.debug("NLTK punkt tokenizer seems to be already downloaded. Error message: %s", error)
pass
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ crawler = [
"selenium>=4.11.0"
]
preprocessing = [
"nltk",
"nltk>=3.9",
"langdetect", # for language classification
]
file-conversion = [
Expand Down
2 changes: 2 additions & 0 deletions releasenotes/notes/upgrade-ntlk-1e94de2d6f5dd3b6.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fixes:
- Upgrades ntlk to 3.9 as prior versions are affect by https://nvd.nist.gov/vuln/detail/CVE-2024-39705
Loading