4 ms·
FWIW, I'm no fan of giving my email either, so I tried to load the transformer on my own system. Would you mind to put a bit more, eg an example, than just foll
by desmap 6y ago
FWIW, I'm no fan of giving my email either, so I tried to load the transformer on my own system. Would you mind to put a bit more, eg an example, than just following three lines there?
from transformers import AutoTokenizer, AutoModelWithLMHead
tokenizer = AutoTokenizer.from_pretrained("mbien/recipenlg")
model = AutoModelWithLMHead.from_pretrained("mbien/recipenlg")
FYI, I got this from running above lines:
...AutoModelWithLMHead is deprecated and will be removed in a future version...
FYI2, I just entered on your huggingface page "Get salt, apples and sugar and you get" and got "Get salt, apples and sugar and you get a soft, sticky mess. Then add water, add a lemon or lime and add a 1/8 teaspoon vanilla. Add a pinch of cinnamon and a dash of nutmeg. When you are ready", where is the recipe, what is this?? A bit more docs would be nice...
- mbien 6y agoHi, after gathering the model and tokenizer, you can use the generic huggingface tutorial for text generation: https://huggingface.co/blog/how-to-generate https://huggingface.co/blog/how-to-generate We use custom control tokens, so you have to provide the specific structure of the recipe, simply typing it in the huggingface prompt won't work. The details are available in our papers about the solution.
- desmap 6y ago> in our papers A link would be kind.
- mbien 6y agoShort version: https://www.aclweb.org/anthology/2020.inlg-1.4.pdf https://www.aclweb.org/anthology/2020.inlg-1.4.pdf Long version: https://www.researchgate.net/publication/345308878_Cooking_recipes_generator_utilizing_a_deep_learning-based_language_model https://www.researchgate.net/publication/345308878_Cooking_r... They're both in README.md