Minor lg changes (#2533)

* Minor lg change

* Update Documentation & Code Style

* Fix missing articles

* Update Documentation & Code Style

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This commit is contained in:
Agnieszka Marzec 2022-05-13 16:12:22 +02:00 committed by GitHub
parent 1ae5a1449b
commit 2d03a26045
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 8 deletions

View File

@ -125,18 +125,18 @@ or an entailment.
def predict(documents: List[Document], batch_size: Optional[int] = None) -> List[Document]
```
Returns documents containing classification result in meta field.
Returns documents containing classification result in a meta field.
Documents are updated in place.
**Arguments**:
- `documents`: List of Document to classify
- `batch_size`: Number of Documents to classify at a time.
- `documents`: A list of Documents to classify.
- `batch_size`: The number of Documents to classify at a time.
**Returns**:
List of Document enriched with meta information
A list of Documents enriched with meta information.
<a id="transformers.TransformersDocumentClassifier.predict_batch"></a>

View File

@ -136,12 +136,12 @@ class TransformersDocumentClassifier(BaseDocumentClassifier):
def predict(self, documents: List[Document], batch_size: Optional[int] = None) -> List[Document]:
"""
Returns documents containing classification result in meta field.
Returns documents containing classification result in a meta field.
Documents are updated in place.
:param documents: List of Document to classify
:param batch_size: Number of Documents to classify at a time.
:return: List of Document enriched with meta information
:param documents: A list of Documents to classify.
:param batch_size: The number of Documents to classify at a time.
:return: A list of Documents enriched with meta information.
"""
if batch_size is None:
batch_size = self.batch_size