We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
from ltp import StnSplit from ltp import LTP
ltp = LTP()
sents2 = StnSplit().batch_split(["南京市长江大桥。", "汤姆生病了。他去了医院。"]) sents2
['南京市长江大桥。', '汤姆生病了。', '他去了医院。']
segment = ltp.pipeline(sents2,tasks=['cws'], return_dict=False) segment
([['南京市', '长江', '大桥', '。'], ['汤姆', '生病', '了', '。'], ['他', '去', '了', '医院', '。']],)
segment = ltp.pipeline(sents2) segment['pos']
[['ns', 'ns', 'n', 'wp'], ['nh', 'v', 'u', 'wp'], ['r', 'v', 'u', 'n', 'wp']]
The text was updated successfully, but these errors were encountered:
No branches or pull requests
from ltp import StnSplit
from ltp import LTP
ltp = LTP()
sents2 = StnSplit().batch_split(["南京市长江大桥。", "汤姆生病了。他去了医院。"])
sents2
['南京市长江大桥。', '汤姆生病了。', '他去了医院。']
segment = ltp.pipeline(sents2,tasks=['cws'], return_dict=False)
segment
([['南京市', '长江', '大桥', '。'],
['汤姆', '生病', '了', '。'],
['他', '去', '了', '医院', '。']],)
segment = ltp.pipeline(sents2)
segment['pos']
[['ns', 'ns', 'n', 'wp'], ['nh', 'v', 'u', 'wp'], ['r', 'v', 'u', 'n', 'wp']]
The text was updated successfully, but these errors were encountered: