Skip to content

Instantly share code, notes, and snippets.

@sshleifer
Last active March 15, 2020 14:08
Show Gist options
  • Save sshleifer/e57b27ccf7b08e08f72e7c0cb19851af to your computer and use it in GitHub Desktop.
Save sshleifer/e57b27ccf7b08e08f72e7c0cb19851af to your computer and use it in GitHub Desktop.

Bart Checklist (Completed):

  • add model/configuration/tokenization classes
  • add conversion scripts
  • add tests
  • finalize
  • copy the python files from the present folder to the main folder and rename them, replacing xxx with your model name,
  • edit the files to replace XXX (with various casing) with your model name
  • copy-paste or create a simple configuration class for your model in the configuration_... file
  • copy-paste or create the code for your model in the modeling_... files (PyTorch and TF 2.0) copy-paste or create a tokenizer class for your model in the tokenization_... file
  • copy the python files from the tests sub-folder of the present folder to the tests subfolder of the main folder and rename them, replacing xxx with your model name,
  • edit the tests files to replace XXX (with various casing) with your model name
  • edit the tests code as needed
  • add import for all the relevant classes in init.py
  • add your configuration in configuration_auto.py
  • add your tokenizer in tokenization_auto.py
  • add your models and tokenizer to pipeline.py add a link to your conversion script in the main conversion utility (in commands/convert.py)
  • add a mention of your model in the doc: README.md and the documentation itself at docs/source/pretrained_models.rst.
  • upload the pretrained weigths, configurations and vocabulary files.
  • add your PyTorch to modeling_auto.py

Bart Checklist (Incomplete):

  • make TF model
  • add TF 2.0 model to modeling_tf_auto.py
  • edit the PyTorch to TF 2.0 conversion script to add your model in the convert_pytorch_checkpoint_to_tf2.py file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment