Comments (10)
I vote to move the integers to the underscored attributes. I use them less often, so it will save my left pinky a lot of work!
from spacy.
I agree, I think it would be more intuitive to have the integer value as the underscored name rather than as the main name.
from spacy.
👍 on swapping them.
from spacy.
I don't think they should be swapped. While I would prefer to have ints underscored, changing it now breaks the API, and it is really not a very difficult convention to get used to.
from spacy.
I get that it breaks the API, and this is unfortunate. But I'd rather introduce breaking changes now than live with them forever.
from spacy.
Sure...
Also, after some more consideration, I think that having ints as default values for each tag makes a lot of sense since most of the time it's ints one wants to work with, and not unicode strings.
from spacy.
Yeah, agreed that the keyword_ should represent ints and keyword should be the string value. It's going to cause some pain to change APIs though 🎱
from spacy.
I guess I would vote for the change as well. When I first started using spaCy, I was initially confused why using .lemma/.lower/etc was giving me a number and not a string as expected. I think it makes more sense for the string value to be named "foo", and the integer value to be named "foo_", especially for new users.
from spacy.
Two weeks ago I would have said "yes, please swap" but now I'm thinking "please keep as is". The reason is less that I got used to it but more that my work focus has shifted from "data exploration" to "data processing". For the exploratory work the underscores where a bit of a pain but for the processing (which I believe will be the bigger portion) the current convention makes perfect sense.
from spacy.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
from spacy.
Related Issues (20)
- Fail to train openai-community / gpt2 model for custom NER on SpaCy framework HOT 1
- Summary HOT 1
- Sharding Warning HOT 1
- nlp.pipe() with multiple processes on Windows VSCode HOT 2
- `Spacy` has inconsistency when dividing sentences HOT 5
- Incorrect detection of sentence boundaries, if last sentence missing eos symbol for trf model
- Enable override of existing custom pipe HOT 1
- Check that filter_spans input is a Span HOT 3
- Tokenizer Incorrectly Splitting "M1M" HOT 1
- Version incompatibility between Spacy, Cuda, Pytorch and Python HOT 3
- Accessing private transformer models HOT 1
- Problems converting Doc object to/from json HOT 1
- The word transitions to the wrong prototype HOT 1
- Fuzzy Matching not working HOT 1
- Unable to finetune transformer based ner model after initial tuning
- Undesired whitespace normalization of Korean text
- Suggestion: Normalize or Translate the parsing labels for German and English dependency labelling
- Code example discrepancy for `Span.lemma_` in API docs HOT 1
- Signature docs error in API docs for `MorphAnalysis.__contains__` HOT 2
- Import broken python 3.9 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from spacy.