Sherlok is a flexible and powerful open source, distributed, real-time text-mining engine.
pip install --upgrade sherlok
from sherlok import Sherlok
s = Sherlok('neuroner')
# returns a list of tuples (begin, end, text, annotation_type, attributes{})
print s.annotate('layer 4 neuron')
[(0, 14, 'layer 4 neuron', u'Neuron', {}),
(8, 14, 'neuron', u'Neuron', {}),
(8, 14, 'neuron', u'NeuronTrigger', {}),
(0, 7, 'layer 4', u'Layer', {u'ontologyId': u'HBP_LAYER:0000004'})]
# filtering and finding the text back
txt = 'parvalbumin-positive fast-spiking basket cells, somatostatin-positive regular-spiking bipolar and multipolar cells, and cholecystokinin-positive irregular-spiking bipolar and multipolar cells'
morphology = s.annotate(txt, u'Morphology')
for (start, end, text, _type, properties) in morphology:
print text, properties[u'ontologyId']
basket HBP_MORPHOLOGY:0000019
bipolar HBP_MORPHOLOGY:0000006
multipolar HBP_MORPHOLOGY:0000035
bipolar HBP_MORPHOLOGY:0000006
multipolar HBP_MORPHOLOGY:0000035
Metadata
Release files for sherlok 0.1.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| sherlok-0.1.6.tar.gz | 2.8 kB | Without provenance | Details |
Release files / sherlok-0.1.6.tar.gz
| Download URL | sherlok-0.1.6.tar.gz |
|---|---|
| Size | 2.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6f11805d5b9cac9c6cee06661859908f187964f30c216ac3928eef4dc56b07dc
|
|
BLAKE2b-256 checksum How to use checksums |
37b336b0d32264d54edb67c0a1c34068671e963a7671ece558941f774e7c4912
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for sherlok 0.1.6
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.