diff options
author | Atemu <atemu.main@gmail.com> | 2024-02-01 16:59:28 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-01 16:59:28 +0100 |
commit | f38bca1ca559974b36863d0ff4bb710b7bc12890 (patch) | |
tree | 8950996221b92d6b810467d23b8d44432cb21210 /pkgs | |
parent | 2f61aff9ae76490380452d78a722ace1e71c5976 (diff) | |
parent | 6300f478e9d9a9a0f0d66004e50e67a107f9cea3 (diff) |
Merge pull request #279677 from leona-ya/paperless-nltk
nixos/paperless: use nltk_data package as NLTK data source
Diffstat (limited to 'pkgs')
-rw-r--r-- | pkgs/applications/office/paperless-ngx/default.nix | 2 | ||||
-rw-r--r-- | pkgs/tools/text/nltk_data/default.nix | 5 |
2 files changed, 7 insertions, 0 deletions
diff --git a/pkgs/applications/office/paperless-ngx/default.nix b/pkgs/applications/office/paperless-ngx/default.nix index afe241222068a..94b4ac77b68a7 100644 --- a/pkgs/applications/office/paperless-ngx/default.nix +++ b/pkgs/applications/office/paperless-ngx/default.nix @@ -18,6 +18,7 @@ , xcbuild , pango , pkg-config +, nltk-data }: let @@ -293,6 +294,7 @@ python.pkgs.buildPythonApplication rec { passthru = { inherit python path frontend; + nltkData = with nltk-data; [ punkt snowball_data stopwords ]; tests = { inherit (nixosTests) paperless; }; }; diff --git a/pkgs/tools/text/nltk_data/default.nix b/pkgs/tools/text/nltk_data/default.nix index 118598083d5df..6445dd8c06e21 100644 --- a/pkgs/tools/text/nltk_data/default.nix +++ b/pkgs/tools/text/nltk_data/default.nix @@ -48,6 +48,11 @@ lib.makeScope newScope (self: { location = "taggers"; hash = "sha256-ilTs4HWPUoHxQb4kWEy3wJ6QsE/98+EQya44gtV2inw="; }); + snowball_data = makeNltkDataPackage ({ + pname = "snowball_data"; + location = "stemmers"; + hash = "sha256-Y6LERPtaRbCtWmJCvMAd2xH02xdrevZBFNYvP9N4+3s="; + }); stopwords = makeNltkDataPackage ({ pname = "stopwords"; location = "corpora"; |