Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sydney-informatics-hub/clause-segmenter
A clause segmenting tool utilising Python's SpaCy
https://github.com/sydney-informatics-hub/clause-segmenter
nlp python spacy
Last synced: 28 days ago
JSON representation
A clause segmenting tool utilising Python's SpaCy
- Host: GitHub
- URL: https://github.com/sydney-informatics-hub/clause-segmenter
- Owner: Sydney-Informatics-Hub
- License: mit
- Created: 2024-08-20T01:16:40.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-08-21T02:03:25.000Z (3 months ago)
- Last Synced: 2024-10-09T11:42:52.195Z (28 days ago)
- Topics: nlp, python, spacy
- Language: Python
- Homepage: https://pypi.org/project/clause-segmenter/
- Size: 104 KB
- Stars: 0
- Watchers: 5
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Clause Segmenter
A clause segmenting tool utilising Python's SpaCy
## Installation
```shell
python3 -m pip install clause-segmenter
```## Documentation
Documentation can be found [here](https://sydney-informatics-hub.github.io/clause-segmenter/DOCS.html)
## Usage
A code snippet example that uses the ClauseSegmenter
```python
from clause_segmenter import ClauseSegmentertext = "When I want to leave the house, I have to check if it's raining, so I know whether to bring an umbrella."
segmenter = ClauseSegmenter()
clauses_ls = segmenter.get_clauses_as_list(text)
for clause in clauses_ls:
print(clause)
```Output:
```
When I want to leave the house
I have to check if it's raining
so I know whether to bring an umbrella
```## Tests
```shell
python3 clause_segmenter/tests/tests.py
```## Contributing
The package for this project is hosted on PyPi: https://pypi.org/project/clause-segmenter/
Dependencies, publishing, and version numbering is handled by [Poetry](https://python-poetry.org)
To publish a new version:
```shell
poetry config pypi-token.pypi
poetry version minor
poetry publish --build
```## Authors
- **Hamish Croser** - [h-croser](https://github.com/h-croser)
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details