Skip to content
This repository has been archived by the owner on May 25, 2020. It is now read-only.

When the training model is successfully restarted, the start-up service fails to find the model. #63

Closed
Spring12111 opened this issue Jul 9, 2019 · 8 comments
Labels

Comments

@Spring12111
Copy link

Spring12111 commented Jul 9, 2019

The custom training model was successful, and an error occurred when running the python bin/cakechat_server.py command to start the service.
TIM图片20190709163956
The operating system is Centos7.

@nicolas-ivanov
Copy link
Contributor

@Spring1212, the size of vocabulary that you are trying to use is only 26 tokens - not good. Apparently you rewrote the default vocabulary file by running prepare_index_files.py. See the corresponding section of our Readme for a fix guideline: https://github.com/lukalabs/cakechat#training-the-model-from-scratch

@Spring12111
Copy link
Author

Is this due to too little training data?

@Spring12111
Copy link
Author

Can adding training data avoid this problem?

@nicolas-ivanov
Copy link
Contributor

Is this due to too little training data?

You got a different index files because apparently you run prepare_index_files.py and it rewrote the original index files. Even if you had training data in abundance, running this script would still result in overwriting index files, so won't be able to use our pretrained model.

If you just want to use our pretrained model without finetuning on you own data, you don't need to run prepare_index_files.py script. Restore the default index files following the link I send you in the previous message and run the server with our pretrained model after that.

And in case you do want to tune our model or to train your own from scratch, please, read carefully the corresponding sections from our Readme: https://github.com/lukalabs/cakechat#training-the-model

@Spring12111
Copy link
Author

According to the self-report file training model from scratch, every step of adding training data into the file is operated.
AZZJT LIW5_4V$RH4WAHY`2

@Spring12111
Copy link
Author

Is this still a pre-training model?

@nicolas-ivanov
Copy link
Contributor

nicolas-ivanov commented Jul 10, 2019

Seems like I got the problem: the server is trying to use a reverse model for sampling_reranking mode of generating answers and, I assume, you didn't train it, since it's not mentioned in this section of our Readme.

Option 1: change sampling_reranking to sampling here: https://github.com/lukalabs/cakechat/blob/master/cakechat/api/config.py#L4

Option 2: run python tools/train.py -r to train the reverse model.

In either case, please, note that you'll need to use a larger training set with larger vocabulary to get any meaningful results after training.

@stale
Copy link

stale bot commented Jul 17, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the staled label Jul 17, 2019
@stale stale bot closed this as completed Jul 27, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants