Fix doc errors and typos across the board (#8139)

* Fix doc errors and typos across the board

* Fix a typo

* Fix the CI

* Fix more typos

* Fix CI

* More fixes

* Fix CI

* More fixes

* More fixes
This commit is contained in:
Santiago Castro
2020-10-29 10:33:33 -04:00
committed by GitHub
parent 4731a00c3e
commit 969859d5f6
160 changed files with 342 additions and 364 deletions

View File

@@ -45,7 +45,7 @@ from utils_squad import (
write_predictions_extended,
)
# The follwing import is the official SQuAD evaluation script (2.0).
# The following import is the official SQuAD evaluation script (2.0).
# You can remove it from the dependencies if you are using this script outside of the library
# We've added it here for automated tests (see examples/test_examples.py file)
from utils_squad_evaluate import EVAL_OPTS

View File

@@ -426,8 +426,8 @@ def _improve_answer_span(doc_tokens, input_start, input_end, tokenizer, orig_ans
#
# However, this is not always possible. Consider the following:
#
# Question: What country is the top exporter of electornics?
# Context: The Japanese electronics industry is the lagest in the world.
# Question: What country is the top exporter of electronics?
# Context: The Japanese electronics industry is the largest in the world.
# Answer: Japan
#
# In this case, the annotator chose "Japan" as a character sub-span of

View File

@@ -57,7 +57,7 @@ class XxxConfig(PretrainedConfig):
If string, :obj:`"gelu"`, :obj:`"relu"`, :obj:`"swish"` and :obj:`"gelu_new"` are supported.
hidden_dropout_prob (:obj:`float`, `optional`, defaults to 0.1):
The dropout probabilitiy for all fully connected layers in the embeddings, encoder, and pooler.
The dropout probability for all fully connected layers in the embeddings, encoder, and pooler.
attention_probs_dropout_prob (:obj:`float`, `optional`, defaults to 0.1):
The dropout ratio for the attention probabilities.
max_position_embeddings (:obj:`int`, `optional`, defaults to 512):

View File

@@ -352,7 +352,7 @@ XXX_INPUTS_DOCSTRING = r"""
@add_start_docstrings(
"The bare XXX Model transformer outputing raw hidden-states without any specific head on top.",
"The bare XXX Model transformer outputting raw hidden-states without any specific head on top.",
XXX_START_DOCSTRING,
)
class TFXxxModel(TFXxxPreTrainedModel):

View File

@@ -237,7 +237,7 @@ class XxxTokenizer(PreTrainedTokenizer):
if token_ids_1 is not None:
raise ValueError(
"You should not supply a second sequence if the provided sequence of "
"ids is already formated with special tokens for the model."
"ids is already formatted with special tokens for the model."
)
return list(map(lambda x: 1 if x in [self.sep_token_id, self.cls_token_id] else 0, token_ids_0))