If you replace “GPT-2” with my model, that may work. I’m not completely sure, though. Here is the training code you can use. You’ll have to change a few things like the directories.
HuggingFace established a new way to upload models this week and I haven’t yet checked if it’s compatible with Google Colab. That’s why I didn’t include in this snippet how to upload.
from transformers import (

    AutoModelWithLMHead,

    AutoConfig,

    Trainer,

    AutoTokenizer,

    TextDataset,

    DataCollatorForLanguageModeling,

    TrainingArguments)

def modelTrainer(batch_size=1, conf='gpt2'): #replace gpt2 with my model

    config = AutoConfig.from_pretrained(conf)

    model = AutoModelWithLMHead.from_config(config)

    tokenizer = AutoTokenizer.from_pretrained(conf)

    data_collator = DataCollatorForLanguageModeling(tokenizer=tokenizer, mlm=False)

    train_dataset = TextDataset(

        tokenizer=tokenizer,

        #block_size = tokenizer.max_len

        block_size = tokenizer.max_len,

        file_path ="/content/Para.txt",

        cache_dir="/content/",

    )

    training_args =TrainingArguments(

        output_dir="/content/ParaphraseAgain",

        num_train_epochs=3.0,

        per_device_train_batch_size=batch_size,

        warmup_steps=500,

        logging_steps = 100,

        save_steps=500,

        seed =random.randint(0,2**32-1),

    )

    trainer = Trainer(

        model=model,

        args=training_args,

        data_collator=data_collator,

        train_dataset=train_dataset,

        prediction_loss_only=True,

    )

    #trainer.train('/content/ParaphraseAgain/checkpoint-2000')

    trainer.train()

    trainer.save_model()

    modelTrainer()