-
Notifications
You must be signed in to change notification settings - Fork 372
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Advanced Spacy Course: Bowie is a word #127
Comments
It can be reproduced on any platform. The problem is that "Bowie" is a valid English word, and also a hash can't be used in a different nlp object with a different vocabulary.
|
Sorry, I'm not sure exactly what you're asking? Looking at this example (in chapter 2, section 3 under "Vocab, hashes and lexemes") this example code is supposed to throw an error. |
Yes, but the documentation indicates the error should be on this line.
bowie_id = nlp.vocab.strings["Bowie"]
Quote:
Answer explosion/spaCy#2: "Bowie" is not a regular word in the English or German
dictionary, so it can’t be hashed.
But "Bowie" is a regular word in English and can be hashed.
Answer explosion/spaCy#2 is the listed as the correct answer, yet answer explosion/spaCy#3 is the correct
answer.
nlp_de is not a valid name. The vocab can only be shared if the nlp objects
have the same name.
The hash for "Bowie" cannot be used in the german vocabulary object.
On Thu, Mar 31, 2022 at 12:29 PM Adriane Boyd ***@***.***> wrote:
Sorry, I'm not sure exactly what you're asking? Looking at this example
(in chapter 2, section 3 under "Vocab, hashes and lexemes") this example
code is supposed to throw an error.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID:
***@***.***>
…--
David Johnson
www.breadstand.com
|
Maybe we're not looking at the same version of the course? Here's the current version: https://course.spacy.io/en/chapter2 The correct answer is: "The string Where does the documentation indicate that this particular line should throw an error? You can always hash any string with This question is about the other direction: you can only convert hash -> string for strings that have already been added to that pipeline's string store. Usually this happens automatically when you process texts, but you can also add any string explicitly with |
How to reproduce the behaviour
Your Environment
The text was updated successfully, but these errors were encountered: