Google I/O is a wrap! Catch up on TensorFlow sessions View sessions

Submit a pull request

This page is about submitting a pull request containing Markdown documentation files to the tensorflow/hub.tensorflow.google.cn. GitHub Repo. For more information on how to write the Markdown files in the first place, please see the writing documentation guide.

GitHub Actions checks

The tensorflow/hub.tensorflow.google.cn repo uses GitHub Actions to validate the format of the files in a PR. The workflow used to validate PRs is defined in .github/workflows/contributions-validator.yml. You can run the validator script on your own branch outside of the workflow, but you will need to ensure you have all the correct pip package dependencies installed.

First time contributors are only able to run automated checks with the approval of a repo maintainer, per GitHub policy. Publishers are encouraged to submit a small PR fixing typos, otherwise improving model documentation, or submitting a PR containing only their publisher page as their first PR to be able to run automated checks on subsequent PRs.

Submitting the PR

The complete Markdown files can be pulled into the master branch of tensorflow/hub.tensorflow.google.cn by one of the following methods.

Git CLI submission

Assuming the identified markdown file path is assets/docs/publisher/model/1.md, you can follow the standard Git[Hub] steps to create a new Pull Request with a newly added file.

This starts with forking the TensorFlow Hub GitHub repository, then creating a Pull Request from this fork into the TensorFlow Hub master branch.

The following are typical CLI git commands needed to adding a new file to a master branch of the forked repository.

git clone https://github.com/[github_username]/hub.tensorflow.google.cn.git
cd hub.tensorflow.google.cn
mkdir -p assets/docs/publisher/model
cp my_markdown_file.md ./assets/docs/publisher/model/1.md
git add *
git commit -m "Added model file."
git push origin master

GitHub GUI submission

A somewhat more straightforward way of submitting is via GitHub graphical user interface. GitHub allows creating PRs for new files or file edits directly through GUI.

  1. On the TensorFlow Hub GitHub page, press Create new file button.
  2. Set the right file path: assets/docs/publisher/model/1.md
  3. Copy-paste the existing markdown.
  4. At the bottom, select "Create a new branch for this commit and start a pull request."