1{ lib
2, buildPythonPackage
3, fetchPypi
4, isPy3k
5, cython
6, numpy
7, srsly
8}:
9
10buildPythonPackage rec {
11 pname = "spacy-pkuseg";
12 version = "0.0.28";
13
14 disabled = !isPy3k;
15
16 src = fetchPypi {
17 inherit version;
18 pname = "spacy_pkuseg";
19 hash = "sha256-mmA/baY9ohvrM41ak5L+G8CUrSQeZCrzmMAoND4X/NI=";
20 };
21
22 # Does not seem to have actual tests, but unittest discover
23 # recognizes some non-tests as tests and fails.
24 doCheck = false;
25
26 nativeBuildInputs = [ cython ];
27
28 propagatedBuildInputs = [ numpy srsly ];
29
30 pythonImportsCheck = [ "spacy_pkuseg" ];
31
32 meta = with lib; {
33 description = "Toolkit for multi-domain Chinese word segmentation (spaCy fork)";
34 homepage = "https://github.com/explosion/spacy-pkuseg";
35 license = licenses.mit;
36 maintainers = with maintainers; [ ];
37 };
38}