How do I register a new model with a pipeline?

I added the model to the hub GeoV/GeoV-9b at main

I can initialize it it with AutoModelForCausalLM.from_pretrained it downloads and loads the model. However when I try to create a pipeline it fails.

generator = pipeline(model="GeoV/GeoV-9b", trust_remote_code=True)

This gives an error

The model 'GeoVForCausalLM' is not supported for text-generation. Supported models are ...

When uploading the model to the hub I registered with the following, is there anything else that I should do?

GeoVConfig.register_for_auto_class()
GeoVModel.register_for_auto_class("AutoModel")
GeoVForCausalLM.register_for_auto_class("AutoModelForCausalLM")
GeoVTokenizer.register_for_auto_class()
2 Likes