mirror of
https://github.com/explosion/spaCy.git
synced 2025-05-29 02:03:18 +03:00
Merge branch 'explosion:master' into master
This commit is contained in:
commit
d5cc009faf
|
@ -56,7 +56,7 @@ def build_tb_parser_model(
|
||||||
non-linearity if use_upper=False.
|
non-linearity if use_upper=False.
|
||||||
use_upper (bool): Whether to use an additional hidden layer after the state
|
use_upper (bool): Whether to use an additional hidden layer after the state
|
||||||
vector in order to predict the action scores. It is recommended to set
|
vector in order to predict the action scores. It is recommended to set
|
||||||
this to False for large pretrained models such as transformers, and False
|
this to False for large pretrained models such as transformers, and True
|
||||||
for smaller networks. The upper layer is computed on CPU, which becomes
|
for smaller networks. The upper layer is computed on CPU, which becomes
|
||||||
a bottleneck on larger GPU-based models, where it's also less necessary.
|
a bottleneck on larger GPU-based models, where it's also less necessary.
|
||||||
nO (int or None): The number of actions the model will predict between.
|
nO (int or None): The number of actions the model will predict between.
|
||||||
|
|
|
@ -795,7 +795,7 @@ if there's no state to be passed through – spaCy can just take care of this fo
|
||||||
you. The following two code examples are equivalent:
|
you. The following two code examples are equivalent:
|
||||||
|
|
||||||
```python
|
```python
|
||||||
# Statless component with @Language.factory
|
# Stateless component with @Language.factory
|
||||||
@Language.factory("my_component")
|
@Language.factory("my_component")
|
||||||
def create_my_component():
|
def create_my_component():
|
||||||
def my_component(doc):
|
def my_component(doc):
|
||||||
|
|
|
@ -3285,15 +3285,17 @@
|
||||||
"slogan": "Forte is a toolkit for building Natural Language Processing pipelines, featuring cross-task interaction, adaptable data-model interfaces and composable pipelines.",
|
"slogan": "Forte is a toolkit for building Natural Language Processing pipelines, featuring cross-task interaction, adaptable data-model interfaces and composable pipelines.",
|
||||||
"description": "Forte provides a platform to assemble state-of-the-art NLP and ML technologies in a highly-composable fashion, including a wide spectrum of tasks ranging from Information Retrieval, Natural Language Understanding to Natural Language Generation.",
|
"description": "Forte provides a platform to assemble state-of-the-art NLP and ML technologies in a highly-composable fashion, including a wide spectrum of tasks ranging from Information Retrieval, Natural Language Understanding to Natural Language Generation.",
|
||||||
"github": "asyml/forte",
|
"github": "asyml/forte",
|
||||||
"pip": "forte.spacy torch",
|
"pip": "forte.spacy stave torch",
|
||||||
"code_example": [
|
"code_example": [
|
||||||
"from forte.spacy import SpacyProcessor",
|
"from fortex.spacy import SpacyProcessor",
|
||||||
|
"from forte.processors.stave import StaveProcessor",
|
||||||
"from forte import Pipeline",
|
"from forte import Pipeline",
|
||||||
"from forte.data.readers import StringReader",
|
"from forte.data.readers import StringReader",
|
||||||
"",
|
"",
|
||||||
"pipeline = Pipeline()",
|
"pipeline = Pipeline()",
|
||||||
"pipeline.set_reader(StringReader())",
|
"pipeline.set_reader(StringReader())",
|
||||||
"pipeline.add(SpacyProcessor())",
|
"pipeline.add(SpacyProcessor())",
|
||||||
|
"pipeline.add(StaveProcessor())",
|
||||||
"pipeline.run('Running SpaCy with Forte!')"
|
"pipeline.run('Running SpaCy with Forte!')"
|
||||||
],
|
],
|
||||||
"code_language": "python",
|
"code_language": "python",
|
||||||
|
|
Loading…
Reference in New Issue
Block a user