https://github.com/apertium/apertium-init
Scripts to bootstrap Apertium language modules and pairs
Science Score: 26.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (11.9%) to scientific vocabulary
Keywords
Keywords from Contributors
Repository
Scripts to bootstrap Apertium language modules and pairs
Basic Info
Statistics
- Stars: 9
- Watchers: 12
- Forks: 15
- Open Issues: 14
- Releases: 0
Topics
Metadata Files
README.md
Apertium-Init (a.k.a. Apertium Bootstrap)
Bootstrap Apertium language modules and pairs using apertium-init.py.
Installation
There are 3 ways to obtain Apertium-Init:
- Download the script from https://apertium.org/apertium-init to your local directory
- Clone this repository and run
make install - Install from PyPi with
pip install apertium-init
If the script was downloaded directly, it can be run with python3 apertium-init.py. Otherwise it will be installed as apertium-init.
Usage
Usage depends on the desired module and is described below. Remember to
search for TODO in the generated module to add example sentences, etc.
Monolingual Lttoolbox module
To bootstrap a monolingual language module apertium-foo using the
lttoolbox formalism,
bash
$ python3 apertium-init.py foo
To bootstrap and compile it at the same time,
bash
$ python3 apertium-init.py foo && ( cd apertium-foo/ && make )
Monlingual HFST module
To bootstrap a monolingual language module apertium-foo using the
HFST formalism,
bash
$ python3 apertium-init.py foo --analyser=hfst
To bootstrap and compile it at the same time,
bash
$ python3 apertium-init.py foo --analyser=hfst && ( cd apertium-foo/ && make )
To include a twoc file for handling prefixes,
bash
$ python3 apertium-init.py foo --analyser=hfst --with-twoc
To include a spellrelax file for handling typographical variance,
bash
$ python3 apertium-init.py foo --analyser=hfst --with-spellrelax
Bilingual Lttoolbox module
To bootstrap a bilingual language module apertium-foo-bar where the
monolingual packages apertium-foo and apertium-bar both use the
lttoolbox formalism,
bash
$ python3 apertium-init.py foo-bar
To bootstrap and compile it at the same time,
bash
$ python3 apertium-init.py foo-bar && ( cd apertium-foo-bar/ && ./autogen.sh && make test)
Bilingual HFST/Lttoolbox module
To bootstrap a bilingual language module apertium-foo-bar where the
monolingual packages apertium-foo and apertium-bar use the
HFST formalism and/or the
lttoolbox formalism,
bash
$ python3 apertium-init.py foo-bar --analysers=hfst # Both foo and bar use HFST
$ python3 apertium-init.py foo-bar --analyser1=hfst # Only foo (first language) uses HFST
$ python3 apertium-init.py foo-bar --analyser2=hfst # Only bar (second language) uses HFST
To bootstrap and compile it at the same time,
bash
$ python3 apertium-init.py foo-bar --analysers=hfst && ( cd apertium-foo-bar/ && ./autogen.sh && make test) # Both foo and bar use HFST
$ python3 apertium-init.py foo-bar --analyser1=hfst && ( cd apertium-foo-bar/ && ./autogen.sh && make test) # Only foo (first language) uses HFST
$ python3 apertium-init.py foo-bar --analyser2=hfst && ( cd apertium-foo-bar/ && ./autogen.sh && make test) # Only bar (second language) uses HFST
Bilingual module for monolinguals that don't use apertium-tagger or CG
To bootstrap a bilingual module when one or both of the monolingual modules don't use apertium-tagger,
bash
$ python3 apertium-init.py foo-bar --no-prob1 # Only foo doesn't have .prob
$ python3 apertium-init.py foo-bar --no-prob2 # Only bar doesn't have .prop
$ python3 apertium-init.py foo-bar --no-prob1 --no-prob2 # Neither foo nor bar have .prob
To bootstrap a bilingual module when one or both of the monolingual modules don't use CG,
bash
$ python3 apertium-init.py foo-bar --no-rlx1 # Only foo doesn't have .rlx
$ python3 apertium-init.py foo-bar --no-rlx2 # Only bar doesn't have .rlx
$ python3 apertium-init.py foo-bar --no-rlx1 --no-rlx2 # Neither foo nor bar have .rlx
Bilingual module using recursive transfer
To bootstrap a bilingual module which uses apertium-recursive,
bash
$ python3 apertium-init.py foo-bar --transfer=rtx
Bilingual module with anaphora resolution
To bootstrap a bilingual module which uses apertium-anaphora,
bash
$ python3 apertium-init.py foo-bar --with-anaphora
Bilingual module with discontiguous multiwords
To bootstrap a bilingual module which uses apertium-separable,
bash
$ python3 apertium-init.py foo-bar --with-separable
Adding features to an existing module
Apertium-init can reconfigure an existing module or pair. For example, to add apertium-separable to an existing pair:
bash
$ python3 apertium-init.py foo-bar -r --with-separable
Note that all desired options must be specified. If the foo-bar pair used apertium-anaphora, the above command would remove it.
Pushing to Github
To bootstrap a module or pair and also add it to the apertium incubator,
bash
$ python3 apertium-init.py foo -p # Bootstrap module apertium-foo and push to Github
$ python3 apertium-init.py foo-bar -p # Bootstrap pair apertium-foo-bar and push to Github
To specify what username to push as (rather than relying on git config),
bash
$ python3 apertium-init.py foo -p -u bar # Bootstrap module apertium-foo and push to Github under username bar
Development
After updating vanilla files, run make in the root of the repository to
generate apertium-init.py.
You can also do sudo make install to install to /usr/local/bin/apertium-init
or e.g. PREFIX=$HOME/local make install to install to
$HOME/local/bin/apertium-init.
Use pipenv install --dev to install the requirements required for development,
e.g. linters.
Releasing
After installing development resources following the instructions above, deploying to PyPi is relatively straightforward.
Use make dist to create a source distributable inside the dist directory
that can be installed locally via pip.
Use make test-release and make release to deploy to the testing PyPi
instance and the production PyPi
instance respectively. Either step requires PyPi
authentication credentials with access to the apertium-init package.
Owner
- Name: Apertium
- Login: apertium
- Kind: organization
- Email: apertium-contact@lists.sourceforge.net
- Website: https://wiki.apertium.org/
- Repositories: 630
- Profile: https://github.com/apertium
Free/open-source platform for developing rule-based machine translation systems and language technology
GitHub Events
Total
- Issues event: 1
- Delete event: 2
- Issue comment event: 2
- Push event: 5
- Pull request review event: 2
- Pull request event: 7
- Create event: 3
Last Year
- Issues event: 1
- Delete event: 2
- Issue comment event: 2
- Push event: 5
- Pull request review event: 2
- Pull request event: 7
- Create event: 3
Committers
Last synced: about 1 year ago
Top Committers
| Name | Commits | |
|---|---|---|
| Sushain Cherivirala | s****n@s****e | 147 |
| Daniel Swanson | p****e@g****m | 31 |
| Kevin Brubeck Unhammer | u****r@f****g | 25 |
| dependabot[bot] | 4****] | 16 |
| jonorthwash | j****n@g****m | 14 |
| Tino Didriksen | m****l@t****m | 6 |
| Tanmai Khanna | k****i@g****m | 3 |
| Flammie A Pirinen | f****e@i****i | 2 |
| Andi Qu | 3****c | 1 |
| Francis Tyers | f****s | 1 |
| Herman Yanush | h****2@g****m | 1 |
| Itai Steinherz | i****z@g****m | 1 |
| Nick Howell | n****l@g****m | 1 |
| Shardul Chiplunkar | s****r@g****m | 1 |
| E | e****i@e****t | 1 |
| Jonathan North Washington | j****n@l****n | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 11 months ago
All Time
- Total issues: 56
- Total pull requests: 68
- Average time to close issues: over 1 year
- Average time to close pull requests: about 1 month
- Total issue authors: 13
- Total pull request authors: 10
- Average comments per issue: 1.61
- Average comments per pull request: 2.24
- Merged pull requests: 57
- Bot issues: 0
- Bot pull requests: 26
Past Year
- Issues: 0
- Pull requests: 17
- Average time to close issues: N/A
- Average time to close pull requests: 15 days
- Issue authors: 0
- Pull request authors: 3
- Average comments per issue: 0
- Average comments per pull request: 0.24
- Merged pull requests: 11
- Bot issues: 0
- Bot pull requests: 12
Top Authors
Issue Authors
- sushain97 (10)
- jonorthwash (10)
- ApertiumBot (7)
- ftyers (6)
- unhammer (5)
- mr-martian (5)
- flammie (5)
- TinoDidriksen (3)
- xavivars (1)
- MarcRiera (1)
- Guy-Mav (1)
- rueter (1)
- e-shere (1)
Pull Request Authors
- dependabot[bot] (35)
- mr-martian (25)
- sushain97 (7)
- khannatanmai (3)
- TinoDidriksen (3)
- dolphingarlic (1)
- itaisteinherz (1)
- nlhowell (1)
- flammie (1)
- jiffygist (1)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- pypi 72 last-month
- Total dependent packages: 0
- Total dependent repositories: 1
- Total versions: 9
- Total maintainers: 2
pypi.org: apertium-init
Bootstrap Apertium language modules and pairs
- Homepage: https://github.com/apertium/apertium-init
- Documentation: https://apertium-init.readthedocs.io/
- License: GPLv3+
-
Latest release: 3.0.0
published over 5 years ago
Rankings
Maintainers (2)
Dependencies
- coverage * develop
- coveralls * develop
- flake8 * develop
- flake8-commas * develop
- flake8-polyfill * develop
- flake8-quotes * develop
- mypy * develop
- pep8-naming * develop
- twine * develop
- bleach ==3.3.0 develop
- certifi ==2021.5.30 develop
- cffi ==1.14.5 develop
- chardet ==4.0.0 develop
- colorama ==0.4.4 develop
- coverage ==5.5 develop
- coveralls ==3.0.1 develop
- cryptography ==3.4.7 develop
- docopt ==0.6.2 develop
- docutils ==0.17.1 develop
- flake8 ==3.9.1 develop
- flake8-commas ==2.0.0 develop
- flake8-polyfill ==1.0.2 develop
- flake8-quotes ==3.2.0 develop
- idna ==2.10 develop
- importlib-metadata ==4.4.0 develop
- jeepney ==0.6.0 develop
- keyring ==23.0.1 develop
- mccabe ==0.6.1 develop
- mypy ==0.812 develop
- mypy-extensions ==0.4.3 develop
- packaging ==20.9 develop
- pep8-naming ==0.11.1 develop
- pkginfo ==1.7.0 develop
- pycodestyle ==2.7.0 develop
- pycparser ==2.20 develop
- pyflakes ==2.3.1 develop
- pygments ==2.9.0 develop
- pyparsing ==2.4.7 develop
- readme-renderer ==29.0 develop
- requests ==2.25.1 develop
- requests-toolbelt ==0.9.1 develop
- rfc3986 ==1.5.0 develop
- secretstorage ==3.3.1 develop
- six ==1.16.0 develop
- tqdm ==4.61.0 develop
- twine ==3.4.1 develop
- typed-ast ==1.4.3 develop
- typing-extensions ==3.10.0.0 develop
- urllib3 ==1.26.5 develop
- webencodings ==0.5.1 develop
- zipp ==3.4.1 develop