Skip to content

Commit

Permalink
Rename modules for consistency (explosion#11286)
Browse files Browse the repository at this point in the history
* rename Python module to entity_ruler

* rename Python module to attribute_ruler
  • Loading branch information
Sofie Van Landeghem authored and jikanter committed May 10, 2024
1 parent 45b815d commit 8ac71f0
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 10 deletions.
6 changes: 3 additions & 3 deletions spacy/pipeline/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from .attributeruler import AttributeRuler
from .attribute_ruler import AttributeRuler
from .dep_parser import DependencyParser
from .edit_tree_lemmatizer import EditTreeLemmatizer
from .entity_linker import EntityLinker
from .entityruler import EntityRuler
from .functions import merge_entities, merge_noun_chunks, merge_subtokens
from .ner import EntityRecognizer
from .entity_ruler import EntityRuler
from .lemmatizer import Lemmatizer
from .morphologizer import Morphologizer
from .ner import EntityRecognizer
Expand Down
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions website/docs/api/attributeruler.mdx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
title: AttributeRuler
tag: class
source: spacy/pipeline/attributeruler.py
version: 3
source: spacy/pipeline/attribute_ruler.py
new: 3
teaser: 'Pipeline component for rule-based token attribute assignment'
api_string_name: attribute_ruler
api_trainable: false
Expand Down Expand Up @@ -34,7 +34,7 @@ how the component should be configured. You can override its settings via the
| `validate` | Whether patterns should be validated (passed to the `Matcher`). Defaults to `False`. ~~bool~~ |
```python
%%GITHUB_SPACY/spacy/pipeline/attributeruler.py
%%GITHUB_SPACY/spacy/pipeline/attribute_ruler.py
```
## AttributeRuler.\_\_init\_\_ {id="init",tag="method"}
Expand Down
6 changes: 3 additions & 3 deletions website/docs/api/entityruler.mdx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
title: EntityRuler
tag: class
source: spacy/pipeline/entityruler.py
version: 2.1
source: spacy/pipeline/entity_ruler.py
new: 2.1
teaser: 'Pipeline component for rule-based named entity recognition'
api_string_name: entity_ruler
api_trainable: false
Expand Down Expand Up @@ -65,7 +65,7 @@ how the component should be configured. You can override its settings via the
| `scorer` | The scoring method. Defaults to [`spacy.scorer.get_ner_prf`](/api/scorer#get_ner_prf). ~~Optional[Callable]~~ |
```python
%%GITHUB_SPACY/spacy/pipeline/entityruler.py
%%GITHUB_SPACY/spacy/pipeline/entity_ruler.py
```
## EntityRuler.\_\_init\_\_ {id="init",tag="method"}
Expand Down
2 changes: 1 addition & 1 deletion website/docs/usage/saving-loading.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ the data to and from a JSON file.
>
> To see custom serialization methods in action, check out the new
> [`EntityRuler`](/api/entityruler) component and its
> [source](%%GITHUB_SPACY/spacy/pipeline/entityruler.py). Patterns added to the
> [source](%%GITHUB_SPACY/spacy/pipeline/entity_ruler.py). Patterns added to the
> component will be saved to a `.jsonl` file if the pipeline is serialized to
> disk, and to a bytestring if the pipeline is serialized to bytes. This allows
> saving out a pipeline with a rule-based entity recognizer and including all
Expand Down

0 comments on commit 8ac71f0

Please sign in to comment.