How to Enable Hugging Face#

This guide will walk you through the process of generating a Hugging Face access token and enabling relevant repository access on Hugging Face.

Generate Hugging Face Access Token#

Step 1: Create a Hugging Face Account#

Visit the Hugging Face Website#

Sign Up or Log In:#

  • If you don’t have an account, click on “Sign Up” and follow the instructions to create one.

  • If you already have an account, click on “Log In” and enter your credentials.

Step 2: Generate an Access Token#

  1. Once logged in, click on your profile picture or username in the top-right corner to open the dropdown menu.

  2. From the dropdown menu, select ‘Settings’.

    Select Settings from dropdown on Hugging Face

  3. In the settings menu, find and click on ‘Access Tokens’ on the left-hand side.

    Access Tokens from the sidebar

  4. Click on the ‘Create new token’ button.

    Create new token button

  5. Select token type as ‘Read’ and provide a name for your token (e.g., “esq”).

    Select token type

  6. Once done, click ‘Create token’.

  7. Copy and store your access token securely, as you won’t be able to see it again.

  8. Click ‘Done’ to exit.

  9. Export the Hugging Face token in your terminal. Ensure the same terminal is used to run the application.

    export HF_TOKEN=<your-huggingface-token>
    

    Copy and save access token

    Note: Remember to copy, export, and store the generated access token so that it can be retrieved in the future.

Enable Relevant Repository Access on Hugging Face#

Follow the steps below to enable relevant repositories in Hugging Face.

Step 1: Browse Relevant Repositories#

  1. Visit Hugging Face and log in to your account.

  2. Go to the repository of the desired model.

  3. Submit request to access the model if needed. For example, for Llama-2-13b-hf, click ‘Expand to review and access’. Expand to review and access

  4. Read through the license agreement and fill in the details as needed. Once completed, tick to acknowledge the terms of the license and click ‘Submit’. Submit model access request

  5. After submission, check and confirm whether the submission is successful. Submission of access request successful

Step 2: Check for Successful Repository Access#

  • Hugging Face will send an email to your registered email address notifying that access to the repository has been granted.

  • You should receive the approval email within 1 working day. Model access approval email notification