1{
2 lib,
3 buildPythonPackage,
4 pythonOlder,
5 fetchFromGitHub,
6
7 pytestCheckHook,
8 regex,
9}:
10
11buildPythonPackage rec {
12 pname = "sentence-splitter";
13 version = "1.4";
14 format = "setuptools";
15
16 disabled = pythonOlder "3.5";
17
18 src = fetchFromGitHub {
19 owner = "mediacloud";
20 repo = "sentence-splitter";
21 rev = version;
22 hash = "sha256-FxRi8fhKB9++lCTFpCAug0fxjkSVTKChLY84vkshR34=";
23 };
24
25 propagatedBuildInputs = [ regex ];
26
27 nativeCheckInputs = [ pytestCheckHook ];
28
29 pythonImportsCheck = [ "sentence_splitter" ];
30
31 meta = with lib; {
32 description = "Text to sentence splitter using heuristic algorithm by Philipp Koehn and Josh Schroeder";
33 homepage = "https://github.com/mediacloud/sentence-splitter";
34 license = licenses.lgpl3Plus;
35 maintainers = [ ];
36 };
37}