Instructions to use intm/codet5-small-go_generation with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use intm/codet5-small-go_generation with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSeq2SeqLM tokenizer = AutoTokenizer.from_pretrained("intm/codet5-small-go_generation") model = AutoModelForSeq2SeqLM.from_pretrained("intm/codet5-small-go_generation", device_map="auto") - Notebooks
- Google Colab
- Kaggle
modify readme
Browse files18 unmodified lines1920212223242518 unmodified lines# 加载模型和tokenizermodel_path = "intm/codet5-small-go_generation"tokenizer = RobertaTokenizer.from_pretrained('Salesforce/codet5-base')model = T5ForConditionalGeneration.from_pretrained(model_path)# 使用模型进行推理18 unmodified lines1920212223242518 unmodified lines# 加载模型和tokenizermodel_path = "intm/codet5-small-go_generation"tokenizer = RobertaTokenizer.from_pretrained('intm/codet5-small-go_generation')model = T5ForConditionalGeneration.from_pretrained(model_path)# 使用模型进行推理
README.md+1-1