Skip to content
New issue

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

fix #1963 pretokenized sequences as input for flair.data.Sentence #1965

Merged
merged 7 commits into from
Nov 23, 2020
Merged

fix #1963 pretokenized sequences as input for flair.data.Sentence #1965

merged 7 commits into from
Nov 23, 2020

Conversation

ulf1
Copy link
Contributor

@ulf1 ulf1 commented Nov 12, 2020

No description provided.

flair/data.py Show resolved Hide resolved
@ulf1
Copy link
Contributor Author

ulf1 commented Nov 12, 2020

What means?

error: sentencepiece 0.1.94 is installed but sentencepiece==0.1.91 is required by {'transformers'}
The command "python setup.py develop -q" failed and exited with 1 during .
Your build has been stopped.

requirements.txt Show resolved Hide resolved
use_tokenizer: Union[bool, Tokenizer] = True,
language_code: str = None,
start_position: int = None
):
"""
Class to hold all meta related to a text (tokens, predictions, language code, ...)
:param text: original string
:param text: original string (sentence), or a list of string tokens (words)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How to make it more clear?

:param text: original string (Alternatively, `text` can be a token list, i.e. a list of strings. In this case there is no tokenization by flair and the parameter `use_tokenizer` is ignored.)

@alanakbik
Copy link
Collaborator

@ulf1 thanks for adding this!

@alanakbik alanakbik merged commit 79014b0 into flairNLP:master Nov 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants