Unrecognized configuration class GPT2Config for AutoModelForSeq2SeqLM | Microsoft DialoGPT no longer working
See original GitHub issueInformation
Model I am using: Microsoft’s DialoGPT
The problem arises when using:
- the official example scripts:
Since the morning of July 14th, the inference API has been outputting errors on Microsoft’s DialoGPT. It was working fine before July 14th.
Error
{'error': "Unrecognized configuration class <class 'transformers.models.gpt2.configuration_gpt2.GPT2Config'>
for this kind of AutoModel: AutoModelForSeq2SeqLM.\nModel type should be one of
BigBirdPegasusConfig, M2M100Config, LEDConfig, BlenderbotSmallConfig, MT5Config, T5Config, PegasusConfig, MarianConfig, MBartConfig, BlenderbotConfig, BartConfig, FSMTConfig, EncoderDecoderConfig, XLMProphetNetConfig, ProphetNetConfig."}
Query script as given on Hugging Face’s site:
import requests
API_URL = "https://api-inference.huggingface.co/models/microsoft/DialoGPT-medium"
headers = {"Authorization": "Bearer API_TOKEN"}
def query(payload):
response = requests.post(API_URL, headers=headers, json=payload)
return response.json()
output = query({
"inputs": {
"past_user_inputs": ["Which movie is the best ?"],
"generated_responses": ["It's Die Hard for sure."],
"text": "Can you explain why ?",
},
})
@patrickvonplaten, @LysandreJik I’m mentioning these two people as the guide says they are working on gpt2. Sorry if I pinged the wrong people!
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Unrecognized configuration class in mT5-small-finetuned ...
Hi, I tried to run the multilingual question-answering with the mt5 model at https://huggingface.co/mrm8488/mT5-small-finetuned-tydiqa-for-xqa.
Read more >How should I format my dataset to avoid this? "Input is not ...
I'm training dialoGPT on my own dataset, following this tutorial. ... .com/models.huggingface.co/bert/microsoft/DialoGPT-small/config.json ...
Read more >Unrecognized configuration class <class 'transformers.models ...
Describe the bug I want to use a german GPT-2 model of answer genereting. So I use a code like this: from haystack.nodes...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi everyone.
Not really sure what happened here (the error is pretty confusing). It is fixed now anyway.
dbmdz/german-gpt2 seems to be working https://huggingface.co/dbmdz/german-gpt2?text=Heute+ist+sehr+schönes+Wetter+in
It doesn’t seem to be defined as
conversation
, is that what you’re referring to ? I am not sure how this model was defined and so if it actually works with conversation, but it doesn’t seem to be the case.The API works with text-generation for this model and it works fine.
benjamin/gerpt2
seems to be exactly the same.If you want to mark them as conversational you need to update the
pipeline_tag
https://huggingface.co/docs/hub/models-widgets#enabling-a-widgetOtherwise do you mind creating a new issue with the new error you’re receiving to be able to reproduce (you can ping me) ?
Hope this helps.