This package contains python bindings for Stanford CoreNLP’s protobuf specifications, as generated by protoc. These bindings can used to parse binary data produced by, e.g., the Stanford CoreNLP server.
Usage:
from corenlp_protobuf import Document, parseFromDelimitedString
# document.dat contains a serialized Document.
with open('document.dat', 'r') as f:
buf = f.read()
doc = Document()
parseFromDelimitedString(doc, buf)
# You can access the sentences from doc.sentence.
sentence = doc.sentence[0]
# You can access any property within a sentence.
print(sentence.text)
# Likewise for tokens
token = sentence.token[0]
print(token.lemma)
See test_read.py for more examples.
Release files for corenlp-protobuf 3.8.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| corenlp-protobuf-3.8.0.tar.gz | 19.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| corenlp_protobuf-3.8.0-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details |
Total release size: 34.6 kB
Release files / corenlp-protobuf-3.8.0.tar.gz
| Download URL | corenlp-protobuf-3.8.0.tar.gz |
|---|---|
| Size | 19.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0fb0eff902e2a4cd175d75b4fe4e3ea366a7e5b5646bfe7b799dc6a7072717fb
|
|
BLAKE2b-256 checksum How to use checksums |
f42a7eda92896cc518aabad31393b02bb27ef774fad729db76165f71969e5bb0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / corenlp_protobuf-3.8.0-py2.py3-none-any.whl
| Download URL | corenlp_protobuf-3.8.0-py2.py3-none-any.whl |
|---|---|
| Size | 15.2 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
fac9341b41b92c1413dc8847721c0b7d62600f06768b965880390d4a7d455e53
|
|
BLAKE2b-256 checksum How to use checksums |
7893cc40d521cf6635fffa400b62799ddc761159302643d400cee72bd910efa9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |