[help wanted] Building a new model vocab on spacy 2.0
I'm trying to build a spaCy 2.0 model for Russian language. I wrote tokenizer-related code, then I did all as described here, but replaced spaCy v1 with my build from master. So I tokenized my corpus, count freqs, compute w2v vectors and brown clusters. And then I realized that old cli command - model is outdated. Instead I can only found vocab command, which should be provided a jsonl-file with all lexemes and w2v vectors in numpy format, but as I can see in source code: there is no need to build manually lexemes file as I can simply update spacy.blank('ru').vocab object lexemes with words from my freqs list, and same way I can upload vectors and clusters. So, am I right and can do I've described to get a model (seems to need a cli command for this)?
Info about spaCy
- spaCy version: 2.0.3
- Platform: Linux-4.13.11-1-ARCH-x86_64-with-arch
- Python version: 3.6.3
Similarly, I'm trying to build a spaCy 2.0 model for Chinese language. After finishing tokenizer, I just don't know what to do next. Have you ever successfully built a model before? Recently I feel confused about what should be included in a language model. Can I build a sample model without ner, parser and tagger?(Maybe the model is almost useless)
Can I build a sample model without ner, parser and tagger?
As I understood, you can build model contains only vocab data. Then you can add any of tagger, ner or parser or all of them, but no one is required for model to work. Moreover, I don't know if it can be called "model", but language instance, created with spacy.blank with only working tokenizer is a valid object.
Have you ever successfully built a model before?
No, I haven't.
After finishing tokenizer, I just don't know what to do next.
I think you need to find a corpus, tokenize it and count words frequencies, at first. I'm almost sure it will be needed for building model. But, of course, I would like to see the confirmation of my words.
So, to build model I've combined two scripts: old cli.model and new cli.vocab - into a new one, which creates model from words freqs, w2v vectors and brown clusters - and stores it into disk.
I haven't tested yet model properly, but it loads and al least token.similarity works fine.
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.