| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 | |
| 21 | |
| 22 | |
| 23 | |
| 24 | |
| 25 | |
| 26 | |
| 27 | |
| 28 | |
| 29 | |
| 30 | |
| 31 | |
| 32 | |
| 33 | |
| 34 | |
| 35 |
|
| 36 | (define-module (gnu packages language)
|
| 37 | #:use-module (gnu packages)
|
| 38 | #:use-module (gnu packages anthy)
|
| 39 | #:use-module (gnu packages audio)
|
| 40 | #:use-module (gnu packages autotools)
|
| 41 | #:use-module (gnu packages base)
|
| 42 | #:use-module (gnu packages check)
|
| 43 | #:use-module (gnu packages cmake)
|
| 44 | #:use-module (gnu packages compiler-tools)
|
| 45 | #:use-module (gnu packages compression)
|
| 46 | #:use-module (gnu packages dbm)
|
| 47 | #:use-module (gnu packages dictionaries)
|
| 48 | #:use-module (gnu packages docbook)
|
| 49 | #:use-module (gnu packages fontutils)
|
| 50 | #:use-module (gnu packages freedesktop)
|
| 51 | #:use-module (gnu packages fribidi)
|
| 52 | #:use-module (gnu packages gd)
|
| 53 | #:use-module (gnu packages gettext)
|
| 54 | #:use-module (gnu packages glib)
|
| 55 | #:use-module (gnu packages gnome)
|
| 56 | #:use-module (gnu packages gtk)
|
| 57 | #:use-module (gnu packages ibus)
|
| 58 | #:use-module (gnu packages java)
|
| 59 | #:use-module (gnu packages libffi)
|
| 60 | #:use-module (gnu packages linux)
|
| 61 | #:use-module (gnu packages llvm)
|
| 62 | #:use-module (gnu packages man)
|
| 63 | #:use-module (gnu packages ncurses)
|
| 64 | #:use-module (gnu packages ocr)
|
| 65 | #:use-module (gnu packages pcre)
|
| 66 | #:use-module (gnu packages perl)
|
| 67 | #:use-module (gnu packages perl-check)
|
| 68 | #:use-module (gnu packages pkg-config)
|
| 69 | #:use-module (gnu packages pulseaudio)
|
| 70 | #:use-module (gnu packages python)
|
| 71 | #:use-module (gnu packages python-build)
|
| 72 | #:use-module (gnu packages python-xyz)
|
| 73 | #:use-module (gnu packages qt)
|
| 74 | #:use-module (gnu packages ruby)
|
| 75 | #:use-module (gnu packages rust)
|
| 76 | #:use-module (gnu packages scheme)
|
| 77 | #:use-module (gnu packages serialization)
|
| 78 | #:use-module (gnu packages sqlite)
|
| 79 | #:use-module (gnu packages swig)
|
| 80 | #:use-module (gnu packages texinfo)
|
| 81 | #:use-module (gnu packages web)
|
| 82 | #:use-module (gnu packages xdisorg)
|
| 83 | #:use-module (gnu packages xml)
|
| 84 | #:use-module (gnu packages xorg)
|
| 85 | #:use-module (guix build-system cargo)
|
| 86 | #:use-module (guix build-system cmake)
|
| 87 | #:use-module (guix build-system copy)
|
| 88 | #:use-module (guix build-system glib-or-gtk)
|
| 89 | #:use-module (guix build-system gnu)
|
| 90 | #:use-module (guix build-system perl)
|
| 91 | #:use-module (guix build-system pyproject)
|
| 92 | #:use-module (guix build-system qt)
|
| 93 | #:use-module (guix deprecation)
|
| 94 | #:use-module (guix download)
|
| 95 | #:use-module (guix gexp)
|
| 96 | #:use-module (guix git-download)
|
| 97 | #:use-module ((guix licenses) #:prefix license:)
|
| 98 | #:use-module (guix modules)
|
| 99 | #:use-module (guix packages)
|
| 100 | #:use-module (guix utils)
|
| 101 | #:use-module (srfi srfi-1))
|
| 102 |
|
| 103 | (define-public nimf
|
| 104 | (package
|
| 105 | (name "nimf")
|
| 106 | (version "1.4.19")
|
| 107 | (source
|
| 108 | (origin
|
| 109 | (method git-fetch)
|
| 110 | (uri (git-reference
|
| 111 | (url "https://github.com/hamonikr/nimf")
|
| 112 | (commit (string-append "v" version))))
|
| 113 | (file-name (git-file-name name version))
|
| 114 | (sha256
|
| 115 | (base32 "0p88y1v4wngy9bn5xikcrljjd2wg7s73fg9gw839n3q8061qamk0"))))
|
| 116 | (build-system glib-or-gtk-build-system)
|
| 117 | (outputs '("out" "gtk" "qt" "doc"))
|
| 118 | (arguments
|
| 119 | (list
|
| 120 | #:imported-modules `(,@%glib-or-gtk-build-system-modules
|
| 121 | (guix build cmake-build-system)
|
| 122 | (guix build qt-build-system)
|
| 123 | (guix build qt-utils))
|
| 124 | #:modules `(((guix build qt-build-system) #:prefix qt:)
|
| 125 | ,@%glib-or-gtk-build-system-default-modules)
|
| 126 | #:configure-flags
|
| 127 | #~(list "--with-im-config-data"
|
| 128 | "--with-imsettings-data"
|
| 129 | (string-append "--with-html-dir=" #$output:doc
|
| 130 | "/share/gtk-doc/html")
|
| 131 | (string-append "GTK_QUERY_IMMODULES3="
|
| 132 | (search-input-file
|
| 133 | %build-inputs "/bin/gtk-query-immodules-3.0"))
|
| 134 | (string-append "GTK_QUERY_IMMODULES2="
|
| 135 | (search-input-file
|
| 136 | %build-inputs "/bin/gtk-query-immodules-2.0"))
|
| 137 | (string-append "GTK_UPDATE_ICON_CACHE="
|
| 138 | (search-input-file
|
| 139 | %build-inputs "/bin/gtk-update-icon-cache")))
|
| 140 | #:phases
|
| 141 | #~(modify-phases %standard-phases
|
| 142 | (add-after 'unpack 'patch-paths
|
| 143 | (lambda* (#:key inputs #:allow-other-keys)
|
| 144 | (substitute* "configure.ac"
|
| 145 | (("/usr/share/anthy/anthy.dic")
|
| 146 | (search-input-file inputs "/share/anthy/anthy.dic")))
|
| 147 | (substitute* "configure.ac"
|
| 148 | (("ayatana-appindicator3-0.1")
|
| 149 | "appindicator3-0.1")
|
| 150 | (("-Werror")
|
| 151 | "-Wno-error"))
|
| 152 | (substitute* "modules/services/indicator/nimf-indicator.c"
|
| 153 | (("libayatana-appindicator/app-indicator.h")
|
| 154 | "libappindicator/app-indicator.h"))
|
| 155 | (substitute* "modules/clients/gtk/Makefile.am"
|
| 156 | (("\\$\\(GTK3_LIBDIR\\)")
|
| 157 | (string-append #$output:gtk "/lib"))
|
| 158 | (("\\$\\(GTK2_LIBDIR\\)")
|
| 159 | (string-append #$output:gtk "/lib")))
|
| 160 | (substitute* "modules/clients/qt5/Makefile.am"
|
| 161 | (("\\$\\(QT5_IM_MODULE_DIR\\)")
|
| 162 | (string-append #$output:qt
|
| 163 | "/lib/qt5/plugins/inputmethods")))
|
| 164 | (substitute* '("bin/nimf-settings/Makefile.am"
|
| 165 | "data/apparmor-abstractions/Makefile.am"
|
| 166 | "data/Makefile.am" "data/im-config/Makefile.am"
|
| 167 | "data/imsettings/Makefile.am")
|
| 168 | (("/etc")
|
| 169 | (string-append #$output "/etc"))
|
| 170 | (("/usr/share")
|
| 171 | (string-append #$output "/share")))))
|
| 172 | (add-after 'install 'qt-wrap
|
| 173 | (assoc-ref qt:%standard-phases 'qt-wrap)))))
|
| 174 | (native-inputs
|
| 175 | (list autoconf
|
| 176 | automake
|
| 177 | docbook-xml-4.3
|
| 178 | gettext-minimal
|
| 179 | gobject-introspection
|
| 180 | `(,gtk+-2 "bin")
|
| 181 | `(,gtk+ "bin")
|
| 182 | gtk-doc/stable
|
| 183 | intltool
|
| 184 | libtool
|
| 185 | perl
|
| 186 | pkg-config
|
| 187 | which))
|
| 188 | (inputs
|
| 189 | (list anthy
|
| 190 | libappindicator
|
| 191 | gtk+-2
|
| 192 | gtk+
|
| 193 | libhangul
|
| 194 | m17n-db
|
| 195 | m17n-lib
|
| 196 | qtbase-5
|
| 197 | librime
|
| 198 | (librsvg-for-system)
|
| 199 | wayland
|
| 200 | wayland-protocols
|
| 201 | libx11
|
| 202 | libxkbcommon
|
| 203 | libxklavier))
|
| 204 | (propagated-inputs (list glib))
|
| 205 | (synopsis "Lightweight input method framework")
|
| 206 | (description "Nimf is a lightweight, fast and extensible input method
|
| 207 | framework. This package provides a fork of the original nimf project, that
|
| 208 | focuses especially on Korean input (Hangul, Hanja, ...).")
|
| 209 | (home-page "https://github.com/hamonikr/nimf/")
|
| 210 | (license license:lgpl3+)))
|
| 211 |
|
| 212 | (define-public hime
|
| 213 | (package
|
| 214 | (name "hime")
|
| 215 | (version "0.9.11")
|
| 216 | (source
|
| 217 | (origin
|
| 218 | (method git-fetch)
|
| 219 | (uri
|
| 220 | (git-reference
|
| 221 | (url "https://github.com/hime-ime/hime.git")
|
| 222 | (commit
|
| 223 | (string-append "v" version))))
|
| 224 | (file-name
|
| 225 | (git-file-name name version))
|
| 226 | (sha256
|
| 227 | (base32 "1wn0ici78x5qh6hvv50bf76ld7ds42hzzl4l5qz34hp8wyvrwakw"))))
|
| 228 | (build-system glib-or-gtk-build-system)
|
| 229 | (arguments
|
| 230 | (list
|
| 231 | #:tests? #f |
| 232 | #:imported-modules
|
| 233 | `(,@%glib-or-gtk-build-system-modules
|
| 234 | (guix build cmake-build-system)
|
| 235 | (guix build qt-build-system)
|
| 236 | (guix build qt-utils))
|
| 237 | #:modules
|
| 238 | `(((guix build qt-build-system) #:prefix qt:)
|
| 239 | ,@%glib-or-gtk-build-system-default-modules)
|
| 240 | #:configure-flags
|
| 241 | #~(list
|
| 242 | |
| 243 | |
| 244 | "--disable-system-tray")
|
| 245 | #:phases
|
| 246 | #~(modify-phases %standard-phases
|
| 247 | (add-before 'configure 'relax-gcc-14-strictness
|
| 248 | (lambda _
|
| 249 | (setenv
|
| 250 | "CFLAGS"
|
| 251 | (string-append "-g -O2"
|
| 252 | " -Wno-error=incompatible-pointer-types"
|
| 253 | " -Wno-error=int-conversion"
|
| 254 | " -Wno-error=implicit-function-declaration"))))
|
| 255 | (add-after 'unpack 'patch-std
|
| 256 | (lambda _
|
| 257 | (substitute* "configure"
|
| 258 | (("gnu17")
|
| 259 | "gnu11")
|
| 260 | (("gnu++17")
|
| 261 | "gnu++11"))))
|
| 262 | (add-after 'install 'qt-wrap
|
| 263 | (assoc-ref qt:%standard-phases 'qt-wrap)))))
|
| 264 | (native-inputs
|
| 265 | (list gettext-minimal
|
| 266 | pkg-config
|
| 267 | util-linux))
|
| 268 | (inputs
|
| 269 | (list anthy
|
| 270 | libappindicator
|
| 271 | libchewing
|
| 272 | gtk+
|
| 273 | qtbase-5
|
| 274 | libxtst))
|
| 275 | (synopsis "HIME Input Method Editor")
|
| 276 | (description "Hime is an extremely easy-to-use input method framework. It
|
| 277 | is lightweight, stable, powerful and supports many commonly used input methods,
|
| 278 | including Cangjie, Zhuyin, Dayi, Ranked, Shrimp, Greek, Anthy, Korean, Latin,
|
| 279 | Random Cage Fighting Birds, Cool Music etc.")
|
| 280 | (home-page "https://hime-ime.github.io/")
|
| 281 | (license (list license:gpl2+ license:lgpl2.1+
|
| 282 | license:fdl1.2+)))) |
| 283 |
|
| 284 | (define-public libchewing
|
| 285 | (package
|
| 286 | (name "libchewing")
|
| 287 | (version "0.11.0")
|
| 288 | (source
|
| 289 | (origin
|
| 290 | (method git-fetch)
|
| 291 | (uri (git-reference
|
| 292 | (url "https://github.com/chewing/libchewing")
|
| 293 | (commit (string-append "v" version))
|
| 294 | |
| 295 | (recursive? #t)))
|
| 296 | (file-name (git-file-name name version))
|
| 297 | (sha256
|
| 298 | (base32 "08734i3xyq3wv5vimki7cz438v56ywk3x3assgfjlrngj1ijw0y8"))))
|
| 299 | (build-system cmake-build-system)
|
| 300 | (arguments
|
| 301 | (list
|
| 302 | #:modules '(((guix build cargo-build-system) #:prefix cargo:)
|
| 303 | (guix build utils)
|
| 304 | (guix build cmake-build-system))
|
| 305 | #:imported-modules `((guix build cmake-build-system)
|
| 306 | ,@%cargo-build-system-modules)
|
| 307 | #:out-of-source? #f |
| 308 | #:phases
|
| 309 | #~(modify-phases %standard-phases
|
| 310 | (add-after 'unpack 'prepare-cargo-build-system
|
| 311 | (lambda args
|
| 312 | (for-each
|
| 313 | (lambda (phase)
|
| 314 | (format #t "Running cargo phase: ~a~%" phase)
|
| 315 | (apply (assoc-ref cargo:%standard-phases phase)
|
| 316 | |
| 317 | #:vendor-dir "../guix-vendor"
|
| 318 | #:cargo-target #$(cargo-triplet)
|
| 319 | args))
|
| 320 | '(unpack-rust-crates
|
| 321 | configure
|
| 322 | check-for-pregenerated-files
|
| 323 | patch-cargo-checksums))))
|
| 324 | (add-after 'unpack 'work-around-genkeystroke
|
| 325 | (lambda _
|
| 326 | |
| 327 | (substitute* "tests/CMakeLists.txt"
|
| 328 | (("CURSES_FOUND") "FALSE")))))))
|
| 329 | (native-inputs
|
| 330 | (append
|
| 331 | (list rust `(,rust "cargo") )
|
| 332 | (or (and=> (%current-target-system)
|
| 333 | (compose list make-rust-sysroot))
|
| 334 | '())))
|
| 335 | (inputs
|
| 336 | (cons* corrosion ncurses sqlite (cargo-inputs 'libchewing)))
|
| 337 | (synopsis "Chinese phonetic input method")
|
| 338 | (description "Chewing is an intelligent phonetic (Zhuyin/Bopomofo) input
|
| 339 | method, one of the most popular choices for Traditional Chinese users.")
|
| 340 | (home-page "https://chewing.im/")
|
| 341 | (license license:lgpl2.1+)))
|
| 342 |
|
| 343 | (define-public liblouis
|
| 344 | (package
|
| 345 | (name "liblouis")
|
| 346 | (version "3.34.0")
|
| 347 | (source
|
| 348 | (origin
|
| 349 | (method git-fetch)
|
| 350 | (uri
|
| 351 | (git-reference
|
| 352 | (url "https://github.com/liblouis/liblouis")
|
| 353 | (commit (string-append "v" version))))
|
| 354 | (file-name (git-file-name name version))
|
| 355 | (sha256
|
| 356 | (base32 "1p6ihaxnbwqi8vk471h7v71lkrknk6ahxggm3p7v7l6hal7n6smq"))))
|
| 357 | (build-system gnu-build-system)
|
| 358 | (outputs '("out" "bin" "doc" "python"))
|
| 359 | (arguments
|
| 360 | (list
|
| 361 | #:configure-flags #~(list "--disable-static" "--enable-ucs4")
|
| 362 | #:phases
|
| 363 | #~(modify-phases %standard-phases
|
| 364 | (add-after 'unpack 'fix-python-lib-path
|
| 365 | (lambda _
|
| 366 | (with-directory-excursion "python"
|
| 367 | (substitute* "louis/__init__.py.in"
|
| 368 | (("###LIBLOUIS_SONAME###")
|
| 369 | (string-append #$output "/lib/###LIBLOUIS_SONAME###"))))))
|
| 370 | (add-after 'install 'install-python-extension
|
| 371 | (lambda _
|
| 372 | (with-directory-excursion "python"
|
| 373 | (invoke "python3" "setup.py" "install" "--root=/"
|
| 374 | (string-append "--prefix=" #$output:python))))))))
|
| 375 | (native-inputs
|
| 376 | (list autoconf
|
| 377 | automake
|
| 378 | clang-13
|
| 379 | help2man
|
| 380 | libtool
|
| 381 | libyaml
|
| 382 | texinfo
|
| 383 | perl
|
| 384 | pkg-config
|
| 385 | python-minimal
|
| 386 | python-setuptools))
|
| 387 | (synopsis "Braille translator and back-translator")
|
| 388 | (description "Liblouis is a braille translator and back-translator named in
|
| 389 | honor of Louis Braille. It features support for computer and literary braille,
|
| 390 | supports contracted and uncontracted translation for many languages and has
|
| 391 | support for hyphenation. New languages can easily be added through tables that
|
| 392 | support a rule- or dictionary based approach. Tools for testing and debugging
|
| 393 | tables are also included. Liblouis also supports math braille, Nemeth and
|
| 394 | Marburg.")
|
| 395 | (home-page "https://liblouis.io/")
|
| 396 | (license (list license:lgpl2.1+ |
| 397 | license:gpl3+)))) |
| 398 |
|
| 399 | (define-public liblouisutdml
|
| 400 | (let ((commit "84916f523709855a2d845645cb52a8b3d9b6197e")
|
| 401 | (revision "2"))
|
| 402 | (package
|
| 403 | (name "liblouisutdml")
|
| 404 | (version (git-version "2.12.0" revision commit))
|
| 405 | (source
|
| 406 | (origin
|
| 407 | (method git-fetch)
|
| 408 | (uri
|
| 409 | (git-reference
|
| 410 | (url "https://github.com/liblouis/liblouisutdml")
|
| 411 | (commit commit)))
|
| 412 | (file-name (git-file-name name version))
|
| 413 | (sha256
|
| 414 | (base32 "09azlyj32xzrwbaykkllfmjy0wd686ncxz5iy8na7crqvh2bs90z"))))
|
| 415 | (build-system gnu-build-system)
|
| 416 | (outputs '("out" "bin" "doc"))
|
| 417 | (arguments
|
| 418 | (list #:configure-flags
|
| 419 | #~(list "--disable-static"
|
| 420 | "CFLAGS=-Wno-error=incompatible-pointer-types")))
|
| 421 | (native-inputs
|
| 422 | (list autoconf
|
| 423 | automake
|
| 424 | help2man
|
| 425 | `(,icedtea "jdk")
|
| 426 | libtool
|
| 427 | texinfo
|
| 428 | pkg-config))
|
| 429 | (inputs
|
| 430 | (list libxml2))
|
| 431 | (propagated-inputs
|
| 432 | (list liblouis
|
| 433 | `(,liblouis "bin")))
|
| 434 | (synopsis "Braille transcription services")
|
| 435 | (description "Liblouisutdml is a library providing complete braille
|
| 436 | transcription services for xml, html and text documents. It translates into
|
| 437 | appropriate braille codes and formats according to its style sheet and the
|
| 438 | specifications in the document.")
|
| 439 | (home-page "https://liblouis.io/")
|
| 440 | (license (list license:lgpl3+ |
| 441 | license:gpl3+))))) |
| 442 |
|
| 443 | (define-public libstemmer
|
| 444 | (package
|
| 445 | (name "libstemmer")
|
| 446 | (version "2.2.0")
|
| 447 | (source
|
| 448 | (origin
|
| 449 | (method url-fetch)
|
| 450 | (uri (string-append "https://snowballstem.org/dist/libstemmer_c-"
|
| 451 | version ".tar.gz"))
|
| 452 | (sha256
|
| 453 | (base32 "1hvphdl8pfq1q3cgh7bshsabsxc7id6wswrqilplwszkkkzdjhdr"))))
|
| 454 | (build-system gnu-build-system)
|
| 455 | (arguments
|
| 456 | `(#:tests? #f |
| 457 | #:make-flags
|
| 458 | (list
|
| 459 | (string-append "CC=" ,(cc-for-target))
|
| 460 | "CFLAGS=-fPIC")
|
| 461 | #:phases
|
| 462 | (modify-phases %standard-phases
|
| 463 | (delete 'configure)
|
| 464 | (replace 'install
|
| 465 | (lambda* (#:key outputs #:allow-other-keys)
|
| 466 | (let* ((out (assoc-ref outputs "out"))
|
| 467 | (out-bin (string-append out "/bin"))
|
| 468 | (out-include (string-append out "/include"))
|
| 469 | (out-lib (string-append out "/lib")))
|
| 470 | (install-file "stemwords" out-bin)
|
| 471 | (install-file "include/libstemmer.h" out-include)
|
| 472 | (install-file "libstemmer.a" out-lib)))))))
|
| 473 | (synopsis "Stemming Library")
|
| 474 | (description "LibStemmer provides stemming library, supporting several
|
| 475 | languages.")
|
| 476 | (home-page "https://snowballstem.org/")
|
| 477 | (properties
|
| 478 | '((release-monitoring-url . "https://snowballstem.org/download.html")
|
| 479 | (upstream-name . "libstemmer_c")))
|
| 480 | (license license:bsd-3)))
|
| 481 |
|
| 482 | (define-public perl-lingua-en-findnumber
|
| 483 | (package
|
| 484 | (name "perl-lingua-en-findnumber")
|
| 485 | (version "1.32")
|
| 486 | (source
|
| 487 | (origin
|
| 488 | (method url-fetch)
|
| 489 | (uri (string-append "mirror://cpan/authors/id/N/NE/NEILB/"
|
| 490 | "Lingua-EN-FindNumber-" version ".tar.gz"))
|
| 491 | (sha256
|
| 492 | (base32
|
| 493 | "015ximzdp42v824llwlg2pd77vd0d172lb4xs55q9f9zhqf6s5qx"))))
|
| 494 | (build-system perl-build-system)
|
| 495 | (propagated-inputs
|
| 496 | (list perl-lingua-en-words2nums))
|
| 497 | (home-page "https://metacpan.org/release/Lingua-EN-FindNumber")
|
| 498 | (synopsis "Locate (written) numbers in English text")
|
| 499 | (description "This module provides a regular expression for finding
|
| 500 | numbers in English text. It also provides functions for extracting and
|
| 501 | manipulating such numbers.")
|
| 502 | (license license:perl-license)))
|
| 503 |
|
| 504 | (define-public perl-lingua-en-inflect
|
| 505 | (package
|
| 506 | (name "perl-lingua-en-inflect")
|
| 507 | (version "1.903")
|
| 508 | (source
|
| 509 | (origin
|
| 510 | (method url-fetch)
|
| 511 | (uri (string-append "mirror://cpan/authors/id/D/DC/DCONWAY/"
|
| 512 | "Lingua-EN-Inflect-" version ".tar.gz"))
|
| 513 | (sha256
|
| 514 | (base32
|
| 515 | "0j8d1f1wvmgc11d71pc8xp8fv5a1nb2yfw1dgd19xhscn1klpvzw"))))
|
| 516 | (build-system perl-build-system)
|
| 517 | (native-inputs (list perl-module-build))
|
| 518 | (home-page "https://metacpan.org/release/Lingua-EN-Inflect")
|
| 519 | (synopsis "Convert singular to plural")
|
| 520 | (description "Lingua::EN::Inflect provides plural inflections,
|
| 521 | \"a\"/\"an\" selection for English words, and manipulation of numbers as
|
| 522 | words. Plural forms of all nouns, most verbs, and some adjectives are
|
| 523 | provided. Where appropriate, \"classical\" variants (for example: \"brother\"
|
| 524 | -> \"brethren\", \"dogma\" -> \"dogmata\", etc.) are also provided.")
|
| 525 | (license license:perl-license)))
|
| 526 |
|
| 527 | (define-public perl-lingua-en-inflect-number
|
| 528 | (package
|
| 529 | (name "perl-lingua-en-inflect-number")
|
| 530 | (version "1.12")
|
| 531 | (source
|
| 532 | (origin
|
| 533 | (method url-fetch)
|
| 534 | (uri (string-append "mirror://cpan/authors/id/N/NE/NEILB/"
|
| 535 | "Lingua-EN-Inflect-Number-" version ".tar.gz"))
|
| 536 | (sha256
|
| 537 | (base32
|
| 538 | "1gxccynkaqav43ww43jp4rzkyr36x97jd03yb5f6yx0jhn1k7yv6"))))
|
| 539 | (build-system perl-build-system)
|
| 540 | (propagated-inputs
|
| 541 | (list perl-lingua-en-inflect))
|
| 542 | (home-page "https://metacpan.org/release/Lingua-EN-Inflect-Number")
|
| 543 | (synopsis "Force number of words to singular or plural")
|
| 544 | (description "This module extends the functionality of Lingua::EN::Inflect
|
| 545 | with three new functions for determining plurality of a word and forcefully
|
| 546 | converting a word to singular or plural.")
|
| 547 | (license license:perl-license)))
|
| 548 |
|
| 549 | (define-public perl-lingua-en-inflect-phrase
|
| 550 | (package
|
| 551 | (name "perl-lingua-en-inflect-phrase")
|
| 552 | (version "0.20")
|
| 553 | (source
|
| 554 | (origin
|
| 555 | (method url-fetch)
|
| 556 | (uri (string-append "mirror://cpan/authors/id/R/RK/RKITOVER/"
|
| 557 | "Lingua-EN-Inflect-Phrase-" version ".tar.gz"))
|
| 558 | (sha256
|
| 559 | (base32
|
| 560 | "1a6y1l2pjim2242wcpgz066di4pbzfgsjjdl7vg5a5wzm48qj1am"))))
|
| 561 | (build-system perl-build-system)
|
| 562 | (native-inputs
|
| 563 | (list perl-test-nowarnings))
|
| 564 | (propagated-inputs
|
| 565 | (list perl-lingua-en-findnumber perl-lingua-en-inflect
|
| 566 | perl-lingua-en-inflect-number perl-lingua-en-number-isordinal
|
| 567 | perl-lingua-en-tagger))
|
| 568 | (home-page "https://metacpan.org/release/Lingua-EN-Inflect-Phrase")
|
| 569 | (synopsis "Inflect short English phrases")
|
| 570 | (description "This module attempts to pluralize or singularize short
|
| 571 | English phrases.")
|
| 572 | (license license:perl-license)))
|
| 573 |
|
| 574 | (define-public perl-lingua-en-number-isordinal
|
| 575 | (package
|
| 576 | (name "perl-lingua-en-number-isordinal")
|
| 577 | (version "0.05")
|
| 578 | (source
|
| 579 | (origin
|
| 580 | (method url-fetch)
|
| 581 | (uri (string-append "mirror://cpan/authors/id/R/RK/RKITOVER/"
|
| 582 | "Lingua-EN-Number-IsOrdinal-" version ".tar.gz"))
|
| 583 | (sha256
|
| 584 | (base32
|
| 585 | "1mhqjvh2ad30gjab5b3a6mbr4aysyrscp4wp42yy5x6001a6km98"))))
|
| 586 | (build-system perl-build-system)
|
| 587 | (native-inputs
|
| 588 | (list perl-try-tiny perl-test-fatal))
|
| 589 | (propagated-inputs
|
| 590 | (list perl-lingua-en-findnumber))
|
| 591 | (home-page "https://metacpan.org/release/Lingua-EN-Number-IsOrdinal")
|
| 592 | (synopsis "Detect if English number is ordinal or cardinal")
|
| 593 | (description "This module will tell you if a number, either in words or as
|
| 594 | digits, is a cardinal or ordinal number.")
|
| 595 | (license license:perl-license)))
|
| 596 |
|
| 597 | (define-public perl-lingua-en-tagger
|
| 598 | (package
|
| 599 | (name "perl-lingua-en-tagger")
|
| 600 | (version "0.30")
|
| 601 | (source
|
| 602 | (origin
|
| 603 | (method url-fetch)
|
| 604 | (uri (string-append "mirror://cpan/authors/id/A/AC/ACOBURN/"
|
| 605 | "Lingua-EN-Tagger-" version ".tar.gz"))
|
| 606 | (sha256
|
| 607 | (base32
|
| 608 | "0nrnkvsf9f0a7lp82sanmy89ms2nqq1lvjqicvsagsvzp513bl5b"))))
|
| 609 | (build-system perl-build-system)
|
| 610 | (propagated-inputs
|
| 611 | (list perl-memoize-expirelru perl-lingua-stem perl-html-parser
|
| 612 | perl-html-tagset))
|
| 613 | (home-page "https://metacpan.org/release/Lingua-EN-Tagger")
|
| 614 | (synopsis "Part-of-speech tagger for English natural language processing")
|
| 615 | (description "This module is a probability based, corpus-trained tagger
|
| 616 | that assigns part-of-speech tags to English text based on a lookup dictionary
|
| 617 | and a set of probability values. The tagger assigns appropriate tags based on
|
| 618 | conditional probabilities - it examines the preceding tag to determine the
|
| 619 | appropriate tag for the current word. Unknown words are classified according
|
| 620 | to word morphology or can be set to be treated as nouns or other parts of
|
| 621 | speech. The tagger also extracts as many nouns and noun phrases as it can,
|
| 622 | using a set of regular expressions.")
|
| 623 | (license license:gpl3)))
|
| 624 |
|
| 625 | (define-public perl-lingua-en-words2nums
|
| 626 | (package
|
| 627 | (name "perl-lingua-en-words2nums")
|
| 628 | (version "0.18")
|
| 629 | (source
|
| 630 | (origin
|
| 631 | (method url-fetch)
|
| 632 | (uri (string-append "mirror://cpan/authors/id/J/JO/JOEY/"
|
| 633 | "Lingua-EN-Words2Nums-" version ".tar.gz"))
|
| 634 | (sha256
|
| 635 | (base32
|
| 636 | "118xx8qr1zbx30psv7ic55w65h15mc1vz6zicshfm96jgiwmcrb8"))))
|
| 637 | (build-system perl-build-system)
|
| 638 | (home-page "https://metacpan.org/release/Lingua-EN-Words2Nums")
|
| 639 | (synopsis "Convert English text to numbers")
|
| 640 | (description "This module converts English text into numbers. It supports
|
| 641 | both ordinal and cardinal numbers, negative numbers, and very large numbers.")
|
| 642 | (license license:perl-license)))
|
| 643 |
|
| 644 | (define-public perl-lingua-pt-stemmer
|
| 645 | (package
|
| 646 | (name "perl-lingua-pt-stemmer")
|
| 647 | (version "0.02")
|
| 648 | (source
|
| 649 | (origin
|
| 650 | (method url-fetch)
|
| 651 | (uri (string-append "mirror://cpan/authors/id/N/NE/NEILB/"
|
| 652 | "Lingua-PT-Stemmer-" version ".tar.gz"))
|
| 653 | (sha256
|
| 654 | (base32
|
| 655 | "17c48sfbgwd2ivlgf59sr6jdhwa3aim8750f8pyzz7xpi8gz0var"))))
|
| 656 | (build-system perl-build-system)
|
| 657 | (home-page "https://metacpan.org/release/Lingua-PT-Stemmer")
|
| 658 | (synopsis "Portuguese language stemming")
|
| 659 | (description "This module implements a Portuguese stemming algorithm
|
| 660 | proposed in the paper A Stemming Algorithm for the Portuguese Language by
|
| 661 | Moreira, V. and Huyck, C.")
|
| 662 | (license license:perl-license)))
|
| 663 |
|
| 664 | (define-public perl-lingua-stem
|
| 665 | (package
|
| 666 | (name "perl-lingua-stem")
|
| 667 | (version "0.84")
|
| 668 | (source
|
| 669 | (origin
|
| 670 | (method url-fetch)
|
| 671 | (uri (string-append "mirror://cpan/authors/id/S/SN/SNOWHARE/"
|
| 672 | "Lingua-Stem-" version ".tar.gz"))
|
| 673 | (sha256
|
| 674 | (base32
|
| 675 | "12avh2mnnc7llmmshrr5bgb473fvydxnlqrqbl2815mf2dp4pxcg"))))
|
| 676 | (build-system perl-build-system)
|
| 677 | (native-inputs
|
| 678 | (list perl-module-build))
|
| 679 | (propagated-inputs
|
| 680 | (list perl-lingua-pt-stemmer
|
| 681 | perl-lingua-stem-fr
|
| 682 | perl-lingua-stem-it
|
| 683 | perl-lingua-stem-ru
|
| 684 | perl-lingua-stem-snowball-da
|
| 685 | perl-snowball-norwegian
|
| 686 | perl-snowball-swedish
|
| 687 | perl-text-german))
|
| 688 | (home-page "https://metacpan.org/release/Lingua-Stem")
|
| 689 | (synopsis "Stemming of words in various languages")
|
| 690 | (description "This routine applies stemming algorithms to its parameters,
|
| 691 | returning the stemmed words as appropriate to the selected locale.")
|
| 692 | (license license:perl-license)))
|
| 693 |
|
| 694 | (define-public perl-lingua-stem-fr
|
| 695 | (package
|
| 696 | (name "perl-lingua-stem-fr")
|
| 697 | (version "0.02")
|
| 698 | (source
|
| 699 | (origin
|
| 700 | (method url-fetch)
|
| 701 | (uri (string-append "mirror://cpan/authors/id/S/SD/SDP/"
|
| 702 | "Lingua-Stem-Fr-" version ".tar.gz"))
|
| 703 | (sha256
|
| 704 | (base32
|
| 705 | "0vyrspwzaqjxm5mqshf4wvwa3938mkajd1918d9ii2l9m2rn8kwx"))))
|
| 706 | (build-system perl-build-system)
|
| 707 | (home-page "https://metacpan.org/release/Lingua-Stem-Fr")
|
| 708 | (synopsis "Porter's stemming algorithm for French")
|
| 709 | (description "This module uses a modified version of the Porter Stemming
|
| 710 | Algorithm to return a stemmed French word.")
|
| 711 | (license license:perl-license)))
|
| 712 |
|
| 713 | (define-public perl-lingua-stem-it
|
| 714 | (package
|
| 715 | (name "perl-lingua-stem-it")
|
| 716 | (version "0.02")
|
| 717 | (source
|
| 718 | (origin
|
| 719 | (method url-fetch)
|
| 720 | (uri (string-append "mirror://cpan/authors/id/A/AC/ACALPINI/"
|
| 721 | "Lingua-Stem-It-" version ".tar.gz"))
|
| 722 | (sha256
|
| 723 | (base32
|
| 724 | "1207r183s5hlh4mfwa6p46vzm0dhvrs2dnss5s41a0gyfkxp7riq"))))
|
| 725 | (build-system perl-build-system)
|
| 726 | (home-page "https://metacpan.org/release/Lingua-Stem-It")
|
| 727 | (synopsis "Porter's stemming algorithm for Italian")
|
| 728 | (description "This module applies the Porter Stemming Algorithm to its
|
| 729 | parameters, returning the stemmed Italian word.")
|
| 730 | (license license:perl-license)))
|
| 731 |
|
| 732 | (define-public perl-lingua-stem-ru
|
| 733 | (package
|
| 734 | (name "perl-lingua-stem-ru")
|
| 735 | (version "0.04")
|
| 736 | (source
|
| 737 | (origin
|
| 738 | (method url-fetch)
|
| 739 | (uri (string-append "mirror://cpan/authors/id/N/NE/NEILB/"
|
| 740 | "Lingua-Stem-Ru-" version ".tar.gz"))
|
| 741 | (sha256
|
| 742 | (base32
|
| 743 | "0a2jmdz7jn32qj5hyiw5kbv8fvlpmws8i00a6xcbkzb48yvwww0j"))))
|
| 744 | (build-system perl-build-system)
|
| 745 | (home-page "https://metacpan.org/release/Lingua-Stem-Ru")
|
| 746 | (synopsis "Porter's stemming algorithm for Russian")
|
| 747 | (description "This module applies the Porter Stemming Algorithm to its
|
| 748 | parameters, returning the stemmed Russian (KOI8-R only) word.")
|
| 749 | (license license:perl-license)))
|
| 750 |
|
| 751 | (define-public perl-lingua-stem-snowball-da
|
| 752 | (package
|
| 753 | (name "perl-lingua-stem-snowball-da")
|
| 754 | (version "1.01")
|
| 755 | (source
|
| 756 | (origin
|
| 757 | (method url-fetch)
|
| 758 | (uri (string-append "mirror://cpan/authors/id/C/CI/CINE/"
|
| 759 | "Lingua-Stem-Snowball-Da-" version ".tar.gz"))
|
| 760 | (sha256
|
| 761 | (base32
|
| 762 | "0mm0m7glm1s6i9f6a78jslw6wh573208arxhq93yriqmw17bwf9f"))))
|
| 763 | (build-system perl-build-system)
|
| 764 | (home-page "https://metacpan.org/release/Lingua-Stem-Snowball-Da")
|
| 765 | (synopsis "Porters stemming algorithm for Danish")
|
| 766 | (description "Lingua::Stem::Snowball::Da is a perl port of the danish
|
| 767 | stemmer at http://snowball.sourceforge.net, it was originally altered from the
|
| 768 | Lingua::Stem::Snowball::Se.")
|
| 769 | (license license:gpl2)))
|
| 770 |
|
| 771 | (define-public perl-snowball-norwegian
|
| 772 | (package
|
| 773 | (name "perl-snowball-norwegian")
|
| 774 | (version "1.2")
|
| 775 | (source
|
| 776 | (origin
|
| 777 | (method url-fetch)
|
| 778 | (uri (string-append "mirror://cpan/authors/id/A/AS/ASKSH/"
|
| 779 | "Snowball-Norwegian-" version ".tar.gz"))
|
| 780 | (sha256
|
| 781 | (base32
|
| 782 | "0675v45bbsh7vr7kpf36xs2q79g02iq1kmfw22h20xdk4rzqvkqx"))))
|
| 783 | (build-system perl-build-system)
|
| 784 | (native-inputs (list perl-module-build))
|
| 785 | (home-page "https://metacpan.org/release/Snowball-Norwegian")
|
| 786 | (synopsis "Porters stemming algorithm for Norwegian")
|
| 787 | (description "Lingua::Stem::Snowball::No is a perl port of the norwegian
|
| 788 | stemmer at http://snowball.tartarus.org.")
|
| 789 | (license license:perl-license)))
|
| 790 |
|
| 791 | (define-public perl-snowball-swedish
|
| 792 | (package
|
| 793 | (name "perl-snowball-swedish")
|
| 794 | (version "1.2")
|
| 795 | (source
|
| 796 | (origin
|
| 797 | (method url-fetch)
|
| 798 | (uri (string-append "mirror://cpan/authors/id/A/AS/ASKSH/"
|
| 799 | "Snowball-Swedish-" version ".tar.gz"))
|
| 800 | (sha256
|
| 801 | (base32
|
| 802 | "0agwc12jk5kmabnpsplw3wf4ii5w1zb159cpin44x3srb0sr5apg"))))
|
| 803 | (build-system perl-build-system)
|
| 804 | (native-inputs (list perl-module-build))
|
| 805 | (home-page "https://metacpan.org/release/Snowball-Swedish")
|
| 806 | (synopsis "Porters stemming algorithm for Swedish")
|
| 807 | (description "Lingua::Stem::Snowball::Se is a perl port of the swedish
|
| 808 | stemmer at http://snowball.sourceforge.net.")
|
| 809 | (license license:perl-license)))
|
| 810 |
|
| 811 | (define-public perl-string-toidentifier-en
|
| 812 | (package
|
| 813 | (name "perl-string-toidentifier-en")
|
| 814 | (version "0.12")
|
| 815 | (source
|
| 816 | (origin
|
| 817 | (method url-fetch)
|
| 818 | (uri (string-append "mirror://cpan/authors/id/R/RK/RKITOVER/"
|
| 819 | "String-ToIdentifier-EN-" version ".tar.gz"))
|
| 820 | (sha256
|
| 821 | (base32
|
| 822 | "12nw7h2yiybhdw0vnnpc7bif8ylhsn6kqf6s39dsrf9h54iq9yrs"))))
|
| 823 | (build-system perl-build-system)
|
| 824 | (propagated-inputs
|
| 825 | (list perl-lingua-en-inflect-phrase perl-text-unidecode
|
| 826 | perl-namespace-clean))
|
| 827 | (home-page "https://metacpan.org/release/String-ToIdentifier-EN")
|
| 828 | (synopsis "Convert strings to English program identifiers")
|
| 829 | (description "This module provides a utility method, \"to_identifier\" for
|
| 830 | converting an arbitrary string into a readable representation using the ASCII
|
| 831 | subset of \"\\w\" for use as an identifier in a computer program. The intent
|
| 832 | is to make unique identifier names from which the content of the original
|
| 833 | string can be easily inferred by a human just by reading the identifier.")
|
| 834 | (license license:perl-license)))
|
| 835 |
|
| 836 | (define-public perl-text-german
|
| 837 | (package
|
| 838 | (name "perl-text-german")
|
| 839 | (version "0.06")
|
| 840 | (source
|
| 841 | (origin
|
| 842 | (method url-fetch)
|
| 843 | (uri (string-append "mirror://cpan/authors/id/U/UL/ULPFR/"
|
| 844 | "Text-German-" version ".tar.gz"))
|
| 845 | (sha256
|
| 846 | (base32
|
| 847 | "1p87pgap99lw0nv62i3ghvsi7yg90lhn8vsa3yqp75rd04clybcj"))))
|
| 848 | (build-system perl-build-system)
|
| 849 | (home-page "https://metacpan.org/release/Text-German")
|
| 850 | (synopsis "German grundform reduction")
|
| 851 | (description "This module is a rather incomplete implementation of work
|
| 852 | done by Gudrun Putze-Meier.")
|
| 853 | (license license:perl-license)))
|
| 854 |
|
| 855 | (define-public link-grammar
|
| 856 | (package
|
| 857 | (name "link-grammar")
|
| 858 | (version "5.13.0")
|
| 859 | (source (origin
|
| 860 | (method git-fetch)
|
| 861 | (uri (git-reference
|
| 862 | (url "https://github.com/opencog/link-grammar")
|
| 863 | (commit (string-append "link-grammar-" version))))
|
| 864 | (file-name (git-file-name name version))
|
| 865 | (sha256
|
| 866 | (base32
|
| 867 | "028szynag4jqj24cw9kadzd4gs9a292aiqfxg37m5g7z95ds9nd1"))))
|
| 868 | (build-system gnu-build-system)
|
| 869 | (inputs (list automake
|
| 870 | autoconf
|
| 871 | autoconf-archive
|
| 872 | flex
|
| 873 | libtool
|
| 874 | pcre2
|
| 875 | pkg-config))
|
| 876 | (home-page "https://opencog.github.io/link-grammar-website/")
|
| 877 | (synopsis "Link grammar parser")
|
| 878 | (description "The Link Grammar Parser is a syntactic parser of English,
|
| 879 | Russian, Arabic and Persian (and other languages as well), based on Link
|
| 880 | Grammar, an original theory of syntax and morphology. Given a sentence, the
|
| 881 | system assigns to it a syntactic structure, which consists of a set of
|
| 882 | labelled links connecting pairs of words. The parser also produces a
|
| 883 | \"constituent\" (HPSG style phrase tree) representation of a sentence (showing
|
| 884 | noun phrases, verb phrases, etc.).")
|
| 885 | (license license:lgpl2.1+)))
|
| 886 |
|
| 887 | (define-public praat
|
| 888 | (package
|
| 889 | (name "praat")
|
| 890 | (version "6.6.30")
|
| 891 | (source (origin
|
| 892 | (method git-fetch)
|
| 893 | (uri (git-reference
|
| 894 | (url "https://github.com/praat/praat.github.io")
|
| 895 | (commit (string-append "v" version))))
|
| 896 | (file-name (git-file-name name version))
|
| 897 | (sha256
|
| 898 | (base32
|
| 899 | "0a5cvb5iyq8v887czyx7dii8jfaih7ypbkg89zablrd1yfg8szq6"))))
|
| 900 | (build-system gnu-build-system)
|
| 901 | (arguments
|
| 902 | (list #:make-flags #~(list (string-append "CC="
|
| 903 | #$(cc-for-target)))
|
| 904 | #:phases #~(modify-phases %standard-phases
|
| 905 | (add-after 'unpack 'delete-failing-tests
|
| 906 | (lambda _
|
| 907 | (substitute* "test/script/fileReadable.praat"
|
| 908 | (("assert folderExists: \"~/?\"")
|
| 909 | ""))))
|
| 910 | (delete 'configure)
|
| 911 | (replace 'check
|
| 912 | (lambda* (#:key tests? #:allow-other-keys)
|
| 913 | (when tests?
|
| 914 | (invoke "./praat" "--run"
|
| 915 | "test/runAllTests_batch.praat"))))
|
| 916 | (replace 'install
|
| 917 | (lambda* (#:key outputs #:allow-other-keys)
|
| 918 | (let* ((out (assoc-ref outputs "out"))
|
| 919 | (bin (string-append out "/bin")))
|
| 920 | (mkdir-p bin)
|
| 921 | (copy-file "praat"
|
| 922 | (string-append bin "/praat"))))))))
|
| 923 | (inputs (list alsa-lib gtk+ jack-1 pulseaudio))
|
| 924 | (native-inputs (list pkg-config))
|
| 925 | (home-page "https://praat.org/")
|
| 926 | (synopsis "Doing phonetics by computer")
|
| 927 | (description
|
| 928 | "Praat is a tool to perform phonetics tasks. It can do speech
|
| 929 | analysis (pitch, formant, intensity, ...), speech synthesis, labelling, segmenting
|
| 930 | and manipulation.")
|
| 931 | (license license:gpl2+)))
|
| 932 |
|
| 933 | (define-public libskk
|
| 934 | (package
|
| 935 | (name "libskk")
|
| 936 | (version "1.1.1")
|
| 937 | (source (origin
|
| 938 | (method git-fetch)
|
| 939 | (uri (git-reference
|
| 940 | (url "https://github.com/ueno/libskk")
|
| 941 | (commit version)))
|
| 942 | (file-name (git-file-name name version))
|
| 943 | (sha256
|
| 944 | (base32
|
| 945 | "0x2fswxybc5ii821ydmm7bjn8cyr35zi3mdld2zmaqc7863hzhqq"))))
|
| 946 | (build-system gnu-build-system)
|
| 947 | (arguments
|
| 948 | (list #:parallel-tests? #f |
| 949 | #:phases
|
| 950 | #~(modify-phases %standard-phases
|
| 951 | (add-after 'install 'symlink-skk-jisyo
|
| 952 | (lambda* (#:key inputs #:allow-other-keys)
|
| 953 | (let ((dict-dir "share/skk"))
|
| 954 | (symlink (search-input-directory inputs dict-dir)
|
| 955 | (in-vicinity #$output dict-dir))))))))
|
| 956 | (native-inputs (list autoconf
|
| 957 | automake
|
| 958 | gettext-minimal
|
| 959 | gobject-introspection
|
| 960 | libtool
|
| 961 | pkg-config
|
| 962 | vala))
|
| 963 | (inputs (list json-glib libxkbcommon skk-jisyo))
|
| 964 | (propagated-inputs (list glib libgee)) |
| 965 | (home-page "https://github.com/ueno/libskk")
|
| 966 | (synopsis "Dealing with Japanese kana-to-kanji conversion")
|
| 967 | (description
|
| 968 | "libskk is a library to deal with Japanese kana-to-kanji conversion method.")
|
| 969 | (license license:gpl3+)))
|
| 970 |
|
| 971 | (define-public m17n-db
|
| 972 | (package
|
| 973 | (name "m17n-db")
|
| 974 | (version "1.8.0")
|
| 975 | (source
|
| 976 | (origin
|
| 977 | (method git-fetch)
|
| 978 | (uri (git-reference
|
| 979 | (url "https://https.git.savannah.gnu.org/git/m17n/m17n-db.git")
|
| 980 | (commit (string-append "REL-"
|
| 981 | (string-replace-substring version
|
| 982 | "." "-")))))
|
| 983 | (file-name (git-file-name name version))
|
| 984 | (sha256
|
| 985 | (base32 "0d43qrsc9fhk6f42bkvzzp8sycqpmav0vhs533k7p30nmvlwvq8m"))))
|
| 986 | (build-system gnu-build-system)
|
| 987 | (arguments
|
| 988 | (list
|
| 989 | #:configure-flags
|
| 990 | #~(list (string-append "--with-charmaps="
|
| 991 | (search-input-directory %build-inputs
|
| 992 | "/share/i18n/charmaps")))))
|
| 993 | (native-inputs
|
| 994 | (list autoconf
|
| 995 | automake
|
| 996 | gettext-minimal))
|
| 997 | |
| 998 | |
| 999 | |
| 1000 | (home-page "https://www.nongnu.org/m17n/")
|
| 1001 | (synopsis "Multilingual text processing library (database)")
|
| 1002 | (description
|
| 1003 | "The m17n library realizes multilingualization of many aspects of
|
| 1004 | applications. The m17n library represents multilingual text as an object
|
| 1005 | named M-text. M-text is a string with attributes called text properties, and
|
| 1006 | designed to substitute for string in C. Text properties carry any information
|
| 1007 | required to input, display and edit the text.
|
| 1008 |
|
| 1009 | This package contains the library database.")
|
| 1010 | (license license:lgpl2.1+)))
|
| 1011 |
|
| 1012 | (define-public m17n-lib
|
| 1013 | (package
|
| 1014 | (name "m17n-lib")
|
| 1015 | (version "1.8.0")
|
| 1016 | (source
|
| 1017 | (origin
|
| 1018 | (method git-fetch)
|
| 1019 | (uri (git-reference
|
| 1020 | (url "https://https.git.savannah.gnu.org/git/m17n/m17n-lib.git")
|
| 1021 | (commit (string-append "REL-"
|
| 1022 | (string-replace-substring version
|
| 1023 | "." "-")))))
|
| 1024 | (file-name (git-file-name name version))
|
| 1025 | (sha256
|
| 1026 | (base32 "0zvgs9xf9lnhab3n8r3ywc1zbpnz5548gm7g03r7r9b587pvz5zx"))
|
| 1027 | (patches
|
| 1028 | (search-patches "m17n-lib-1.8.0-use-pkg-config-for-freetype.patch"))))
|
| 1029 | (build-system gnu-build-system)
|
| 1030 | (arguments
|
| 1031 | (list
|
| 1032 | #:parallel-build? #f
|
| 1033 | #:phases
|
| 1034 | (if (%current-target-system)
|
| 1035 | #~(modify-phases %standard-phases
|
| 1036 | |
| 1037 | |
| 1038 | (add-after 'unpack 'fix-rpl_malloc
|
| 1039 | (lambda _
|
| 1040 | (substitute* "configure.ac"
|
| 1041 | (("AC_FUNC_MALLOC") "")
|
| 1042 | (("AC_FUNC_REALLOC") "")))))
|
| 1043 | #~%standard-phases)))
|
| 1044 | (native-inputs
|
| 1045 | (list autoconf
|
| 1046 | automake
|
| 1047 | gettext-minimal
|
| 1048 | libtool
|
| 1049 | pkg-config))
|
| 1050 | (inputs
|
| 1051 | (list fribidi
|
| 1052 | gd
|
| 1053 | libotf
|
| 1054 | libxft
|
| 1055 | libxml2
|
| 1056 | m17n-db))
|
| 1057 | |
| 1058 | |
| 1059 | |
| 1060 | (home-page "https://www.nongnu.org/m17n/")
|
| 1061 | (synopsis "Multilingual text processing library (runtime)")
|
| 1062 | (description "The m17n library realizes multilingualization of
|
| 1063 | many aspects of applications. The m17n library represents
|
| 1064 | multilingual text as an object named M-text. M-text is a string with
|
| 1065 | attributes called text properties, and designed to substitute for
|
| 1066 | string in C. Text properties carry any information required to input,
|
| 1067 | display and edit the text.
|
| 1068 |
|
| 1069 | This package contains the library runtime.")
|
| 1070 | (license license:lgpl2.1+)))
|
| 1071 |
|
| 1072 | (define-public mecab
|
| 1073 | (package
|
| 1074 | (name "mecab")
|
| 1075 | (version "0.996")
|
| 1076 | (source (origin
|
| 1077 | (method git-fetch)
|
| 1078 | (uri (git-reference
|
| 1079 | (url "https://github.com/taku910/mecab")
|
| 1080 | |
| 1081 | (commit "046fa78b2ed56fbd4fac312040f6d62fc1bc31e3")))
|
| 1082 | (file-name (git-file-name name version))
|
| 1083 | (sha256
|
| 1084 | (base32
|
| 1085 | "1hdv7rgn8j0ym9gsbigydwrbxa8cx2fb0qngg1ya15vvbw0lk4aa"))
|
| 1086 | (patches
|
| 1087 | (search-patches
|
| 1088 | "mecab-variable-param.patch"))))
|
| 1089 | (build-system gnu-build-system)
|
| 1090 | (native-search-paths
|
| 1091 | (list (search-path-specification
|
| 1092 | (variable "MECAB_DICDIR")
|
| 1093 | (separator #f)
|
| 1094 | (files '("lib/mecab/dic")))))
|
| 1095 | (arguments
|
| 1096 | `(#:phases
|
| 1097 | (modify-phases %standard-phases
|
| 1098 | (add-after 'unpack 'chdir
|
| 1099 | (lambda _
|
| 1100 | (chdir "mecab")))
|
| 1101 | (add-before 'build 'add-mecab-dicdir-variable
|
| 1102 | (lambda _
|
| 1103 | (substitute* "mecabrc.in"
|
| 1104 | (("dicdir = .*")
|
| 1105 | "dicdir = $MECAB_DICDIR"))
|
| 1106 | (substitute* "mecab-config.in"
|
| 1107 | (("echo @libdir@/mecab/dic")
|
| 1108 | "if [ -z \"$MECAB_DICDIR\" ]; then
|
| 1109 | echo @libdir@/mecab/dic
|
| 1110 | else
|
| 1111 | echo \"$MECAB_DICDIR\"
|
| 1112 | fi")))))))
|
| 1113 | (inputs (list libiconv))
|
| 1114 | (home-page "https://taku910.github.io/mecab")
|
| 1115 | (synopsis "Morphological analysis engine for texts")
|
| 1116 | (description "Mecab is a morphological analysis engine developed as a
|
| 1117 | collaboration between the Kyoto university and Nippon Telegraph and Telephone
|
| 1118 | Corporation. The engine is independent of any language, dictionary or corpus.")
|
| 1119 | (license (list license:gpl2+ license:lgpl2.1+ license:bsd-3))))
|
| 1120 |
|
| 1121 | (define-public mecab-ipadic
|
| 1122 | (package
|
| 1123 | (name "mecab-ipadic")
|
| 1124 | (version "2.7.0")
|
| 1125 | (source (package-source mecab))
|
| 1126 | (build-system gnu-build-system)
|
| 1127 | (arguments
|
| 1128 | `(#:configure-flags
|
| 1129 | (list (string-append "--with-dicdir=" (assoc-ref %outputs "out")
|
| 1130 | "/lib/mecab/dic")
|
| 1131 | "--with-charset=utf8")
|
| 1132 | #:phases
|
| 1133 | (modify-phases %standard-phases
|
| 1134 | (add-after 'unpack 'chdir
|
| 1135 | (lambda _
|
| 1136 | (chdir "mecab-ipadic")))
|
| 1137 | (add-before 'configure 'set-mecab-dir
|
| 1138 | (lambda* (#:key outputs #:allow-other-keys)
|
| 1139 | (setenv "MECAB_DICDIR" (string-append (assoc-ref outputs "out")
|
| 1140 | "/lib/mecab/dic")))))))
|
| 1141 | (native-inputs (list mecab)) |
| 1142 | (home-page "https://taku910.github.io/mecab")
|
| 1143 | (synopsis "Dictionary data for MeCab")
|
| 1144 | (description "This package contains dictionary data derived from
|
| 1145 | ipadic for use with MeCab.")
|
| 1146 | (license (license:non-copyleft "mecab-ipadic/COPYING"))))
|
| 1147 |
|
| 1148 | (define-public mecab-unidic
|
| 1149 | (package
|
| 1150 | (name "mecab-unidic")
|
| 1151 | (version "3.1.0")
|
| 1152 | (source (origin
|
| 1153 | (method url-fetch)
|
| 1154 | (uri (string-append "https://clrd.ninjal.ac.jp/unidic_archive/cwj/"
|
| 1155 | version "/unidic-cwj-" version ".zip"))
|
| 1156 | (sha256
|
| 1157 | (base32
|
| 1158 | "1z132p2q3bgchiw529j2d7dari21kn0fhkgrj3vcl0ncg2m521il"))))
|
| 1159 | (build-system copy-build-system)
|
| 1160 | (arguments
|
| 1161 | `(#:install-plan
|
| 1162 | '(("." "lib/mecab/dic"
|
| 1163 | #:include-regexp ("\\.bin$" "\\.def$" "\\.dic$" "dicrc")))))
|
| 1164 | (native-inputs (list unzip))
|
| 1165 | (home-page "https://clrd.ninjal.ac.jp/unidic/en/")
|
| 1166 | (synopsis "Dictionary data for MeCab")
|
| 1167 | (description "UniDic for morphological analysis is a dictionary for
|
| 1168 | analysis with the morphological analyser MeCab, where the short units exported
|
| 1169 | from the database are used as entries (heading terms).")
|
| 1170 | |
| 1171 | (license (list license:gpl2+ license:lgpl2.1 license:bsd-3))))
|
| 1172 |
|
| 1173 | (define-public python-lexilang
|
| 1174 | (package
|
| 1175 | (name "python-lexilang")
|
| 1176 | (version "1.0.7")
|
| 1177 | (source
|
| 1178 | (origin
|
| 1179 | (method git-fetch)
|
| 1180 | (uri (git-reference
|
| 1181 | (url "https://github.com/LibreTranslate/LexiLang")
|
| 1182 | (commit (string-append "v" version))))
|
| 1183 | (file-name (git-file-name name version))
|
| 1184 | (sha256 (base32 "0myrim1m9zq65y5c77wq4f9ix024lyw8dvjxws33qkfsd6xzvwz7"))
|
| 1185 | (modules '((guix build utils)))
|
| 1186 | (snippet |
| 1187 | #~(begin
|
| 1188 | (mkdir "src")
|
| 1189 | (rename-file "dictionaries" "src/dictionaries")
|
| 1190 | (rename-file "lexilang" "src/lexilang")
|
| 1191 | (substitute* "setup.py"
|
| 1192 | (("packages=" all)
|
| 1193 | (string-append "package_dir={'': 'src'}, " all)))))))
|
| 1194 | (build-system pyproject-build-system)
|
| 1195 | (arguments
|
| 1196 | (list
|
| 1197 | #:phases #~(modify-phases %standard-phases
|
| 1198 | (add-after 'unpack 'compile-data
|
| 1199 | (lambda _
|
| 1200 | (with-directory-excursion "src"
|
| 1201 | (invoke "python" "-c"
|
| 1202 | "from lexilang.utils import compile_data
|
| 1203 | compile_data()")))))
|
| 1204 | #:test-backend #~'custom
|
| 1205 | #:test-flags #~'("test.py")))
|
| 1206 | (native-inputs (list python-setuptools))
|
| 1207 | (home-page "https://github.com/LibreTranslate/LexiLang")
|
| 1208 | (synopsis "Dictionary-based language detector for short texts")
|
| 1209 | (description
|
| 1210 | "LexiLang is a natural language detector, designed for handling small text
|
| 1211 | (under 20 characters). It will probably not work reliably
|
| 1212 | for longer text sequences. As it relies on dictionaries,
|
| 1213 | if a word is missing or mispelled, the detection will fail.")
|
| 1214 | (license license:agpl3)))
|
| 1215 |
|
| 1216 | |
| 1217 | |
| 1218 | |
| 1219 | |
| 1220 | |
| 1221 | (define arnastofnun-dim
|
| 1222 | (let ((version "July2026"))
|
| 1223 | (origin
|
| 1224 | (method git-fetch)
|
| 1225 | (uri (git-reference
|
| 1226 | (url "https://codeberg.org/spencerking/DIM-mirror")
|
| 1227 | (commit version)))
|
| 1228 | (file-name (git-file-name "arnastofnun-dim" version))
|
| 1229 | (sha256
|
| 1230 | (base32 "00pmzhzyw43vh44qfdywdhirxgdbc3anayrxykfll0xfrg216rdn")))))
|
| 1231 |
|
| 1232 | (define-public python-islenska-bootstrap
|
| 1233 | (hidden-package
|
| 1234 | (package
|
| 1235 | (name "python-islenska-bootstrap")
|
| 1236 | (version "1.3.2")
|
| 1237 | |
| 1238 | (source
|
| 1239 | (origin
|
| 1240 | (method git-fetch)
|
| 1241 | (uri (git-reference
|
| 1242 | (url "https://github.com/mideind/BinPackage")
|
| 1243 | (commit version)))
|
| 1244 | (file-name (git-file-name "python-islenska" version))
|
| 1245 | (sha256
|
| 1246 | (base32 "1zc5pn0rd44dqsipc2i4w37a1ws7smhv81p8whl9ixamhp1rsbkl"))))
|
| 1247 | (build-system pyproject-build-system)
|
| 1248 | (arguments
|
| 1249 | (list
|
| 1250 | #:phases
|
| 1251 | |
| 1252 | |
| 1253 | |
| 1254 | |
| 1255 | #~(modify-phases %standard-phases
|
| 1256 | (add-after 'unpack 'create-manifest-in
|
| 1257 | (lambda* (#:key inputs #:allow-other-keys)
|
| 1258 | (with-output-to-file "MANIFEST.in"
|
| 1259 | (lambda ()
|
| 1260 | (display "graft src/islenska/resources")))))
|
| 1261 | (add-after 'unpack 'patch-setup-py
|
| 1262 | (lambda* (#:key inputs #:allow-other-keys)
|
| 1263 | (substitute* "setup.py"
|
| 1264 | (("(.*)cffi_modules=.*" cffi indent)
|
| 1265 | (string-append
|
| 1266 | cffi
|
| 1267 | indent "package_data={'islenska':['src/resources/*']},\n"
|
| 1268 | indent "include_package_data=True,\n"))))))
|
| 1269 | |
| 1270 | #:tests? #f))
|
| 1271 | (propagated-inputs (list python-cffi python-typing-extensions))
|
| 1272 | (native-inputs (list python-cffi python-pytest python-setuptools))
|
| 1273 | (home-page "https://github.com/mideind/BinPackage")
|
| 1274 | (synopsis
|
| 1275 | "The vocabulary of modern Icelandic, encapsulated in a Python package")
|
| 1276 | (description
|
| 1277 | "Islenska is a Python package that embeds the vocabulary of the Database
|
| 1278 | of Icelandic Morphology and offers various lookups and queries of the data.
|
| 1279 | The database contains over 6.5 million entries, over 3.1 million unique word
|
| 1280 | forms, and about 300,000 distinct lemmas.")
|
| 1281 | (license license:expat))))
|
| 1282 |
|
| 1283 | (define-public python-islenska
|
| 1284 | (package/inherit python-islenska-bootstrap
|
| 1285 | (name "python-islenska")
|
| 1286 | (arguments
|
| 1287 | (list
|
| 1288 | #:phases
|
| 1289 | #~(modify-phases %standard-phases
|
| 1290 | |
| 1291 | (delete 'create-manifest-in)
|
| 1292 | (delete 'patch-setup-py)
|
| 1293 | |
| 1294 | |
| 1295 | (add-after 'unpack 'unpack-resources
|
| 1296 | (lambda* (#:key inputs #:allow-other-keys)
|
| 1297 | (install-file
|
| 1298 | (search-input-file inputs "KRISTINsnid.csv/KRISTINsnid.csv")
|
| 1299 | "src/islenska/resources")))
|
| 1300 | |
| 1301 | (add-before 'build 'build-databases
|
| 1302 | (lambda _
|
| 1303 | (invoke "python" "tools/binpack.py")
|
| 1304 | (invoke "python" "tools/dawgbuilder.py"))))
|
| 1305 | #:tests? #t))
|
| 1306 | (native-inputs (list arnastofnun-dim
|
| 1307 | python-cffi
|
| 1308 | python-islenska-bootstrap
|
| 1309 | python-pytest
|
| 1310 | python-setuptools
|
| 1311 | unzip))
|
| 1312 | (license (list license:cc-by4.0 |
| 1313 | license:expat))
|
| 1314 | (properties
|
| 1315 | (alist-delete 'hidden? (package-properties python-islenska-bootstrap)))))
|
| 1316 |
|
| 1317 | (define-public python-icegrams
|
| 1318 | (package
|
| 1319 | (name "python-icegrams")
|
| 1320 | (version "1.1.7")
|
| 1321 | (source
|
| 1322 | (origin
|
| 1323 | (method git-fetch)
|
| 1324 | (uri (git-reference
|
| 1325 | |
| 1326 | (url "https://github.com/mideind/Icegrams")
|
| 1327 | (commit (string-append version))))
|
| 1328 | (file-name (git-file-name name version))
|
| 1329 | (sha256
|
| 1330 | (base32 "1wbjk0l8j0bm3wym6pkp25vnfj4mdxl7amybzgfpfg6d43rf0n4w"))))
|
| 1331 | (build-system pyproject-build-system)
|
| 1332 | (arguments
|
| 1333 | (list
|
| 1334 | #:test-flags
|
| 1335 | #~(list
|
| 1336 | |
| 1337 | |
| 1338 | "-k"
|
| 1339 | (string-append "not test_trigrams" " and not test_word_ids")
|
| 1340 | "test/test_ngrams.py")))
|
| 1341 | (propagated-inputs (list python-cffi))
|
| 1342 | (native-inputs (list python-pytest python-setuptools
|
| 1343 | python-setuptools-scm python-wheel))
|
| 1344 | (home-page "https://github.com/mideind/Icegrams")
|
| 1345 | (synopsis "Trigram statistics for Icelandic")
|
| 1346 | (description
|
| 1347 | "Icegrams is a Python package that encapsulates a large trigram
|
| 1348 | library for Icelandic. You can use Icegrams to obtain probabilities (relative
|
| 1349 | frequencies) of over a million different unigrams (single words or tokens), or of
|
| 1350 | bigrams (pairs of two words or tokens), or of trigrams. Icegrams is useful for
|
| 1351 | instance in spelling correction, predictive typing, to help disabled people
|
| 1352 | write text fast, and for various text generation, statistics, and modeling tasks.")
|
| 1353 | (license license:expat)))
|
| 1354 |
|
| 1355 | (define-public python-tokenizer
|
| 1356 | (package
|
| 1357 | (name "python-tokenizer")
|
| 1358 | (version "3.6.4")
|
| 1359 | (source
|
| 1360 | (origin
|
| 1361 | (method git-fetch)
|
| 1362 | (uri (git-reference
|
| 1363 | (url "https://github.com/mideind/Tokenizer")
|
| 1364 | (commit (string-append "v" version))))
|
| 1365 | (file-name (git-file-name name version))
|
| 1366 | (sha256
|
| 1367 | (base32 "0acfy1aqf1581vy4d5y6wkjfsx52c6azxx2hy85x9rqv6fpij0m2"))))
|
| 1368 | (build-system pyproject-build-system)
|
| 1369 | (native-inputs (list python-pytest
|
| 1370 | python-setuptools))
|
| 1371 | (home-page "https://github.com/mideind/Tokenizer")
|
| 1372 | (synopsis "Tokenizer for Icelandic text with sentence segmentation")
|
| 1373 | (description "This package provides a fast, compact, pure-Python tokenizer
|
| 1374 | for Icelandic text with sentence segmentation.")
|
| 1375 | (license license:expat)))
|
| 1376 |
|
| 1377 | (define-public python-sacremoses
|
| 1378 | (package
|
| 1379 | (name "python-sacremoses")
|
| 1380 | (version "0.1.0")
|
| 1381 | (source
|
| 1382 | (origin
|
| 1383 | (method git-fetch)
|
| 1384 | (uri (git-reference
|
| 1385 | (url "https://github.com/hplt-project/sacremoses")
|
| 1386 | (commit version)))
|
| 1387 | (file-name (git-file-name name version))
|
| 1388 | (sha256
|
| 1389 | (base32 "0g70vchfniknp65n4wnx7chg6g49d4xrz1wagv7f7ir2swdzyn9b"))))
|
| 1390 | (build-system pyproject-build-system)
|
| 1391 | (arguments
|
| 1392 | (let ((norvig-big-txt
|
| 1393 | (origin
|
| 1394 | (method url-fetch)
|
| 1395 | |
| 1396 | |
| 1397 | |
| 1398 | |
| 1399 | (uri "https://norvig.com/big.txt")
|
| 1400 | (sha256
|
| 1401 | (base32
|
| 1402 | "0yz80icdly7na03cfpl0nfk5h3j3cam55rj486n03wph81ynq1ps")))))
|
| 1403 | (list #:phases #~(modify-phases %standard-phases
|
| 1404 | (add-before 'check 'supply-big-txt
|
| 1405 | (lambda _
|
| 1406 | (symlink #$norvig-big-txt "big.txt"))))
|
| 1407 | #:test-backend #~'unittest
|
| 1408 | #:test-flags #~'("discover" "-s" "sacremoses/test"))))
|
| 1409 | (native-inputs (list python-setuptools))
|
| 1410 | (propagated-inputs (list python-click
|
| 1411 | python-joblib
|
| 1412 | python-regex
|
| 1413 | python-tqdm))
|
| 1414 | (home-page "https://github.com/hplt-project/sacremoses")
|
| 1415 | (synopsis "Natural language tokenizer, truecaser and normalizer")
|
| 1416 | (description
|
| 1417 | "SacreMoses is a Python port of Moses'
|
| 1418 | tokenizer, detokenizer, truecaser and punctuation normalizer.")
|
| 1419 | (license license:expat)))
|
| 1420 |
|
| 1421 | |
| 1422 | (define-deprecated/public-alias dparser
|
| 1423 | (@ (gnu packages compiler-tools) dparser))
|