Skip to main content

GitHub repositories

Add GitHub repositories to include documentation, README files, and code comments in your assistant's knowledge base.

Tip

Repository file links are omitted from assistant citations. To restrict who can query the content, use project access control.

Add a repository​

  1. In the Biel.ai dashboard, select your project.

  2. Go to Settings > Sources > GitHub.

    GitHub repositories with shared credentials and selected branch or tag

  3. Enter the repository URL (e.g., https://github.com/owner/repo).

  4. Click Save.

  5. Click Refresh sources to index the repository. Check the loading status and Logs in the project dashboard.

Choose a branch or tag​

Repositories use Default branch unless you choose another version. Open the repository’s Advanced options to change Version:

  • Default branch follows the repository's default branch.
  • Branch reads a named branch, such as docs/latest.
  • Tag reads a release tag, such as v1.0.0.

For Branch or Tag, enter the exact Branch or tag name. Click Save, then Refresh sources. You can add the same repository more than once to read different versions, using the same credentials.

Choose Default branch to switch back. The name field clears automatically.

Private repositories​

Private repositories require Professional or higher. They require a GitHub personal access token:

  1. Go to GitHub Settings > Personal access tokens.
  2. Click Generate new token (classic).
  3. Select the repo scope and click Generate token.
  4. Copy the token.
  5. In Biel.ai, open the repository’s Advanced options and click Create GitHub credentials.
  6. In the new tab, enter a name and paste the token into Access token. Click Save credentials.
  7. Return to Sources and select the credentials for each repository that needs them.
  8. Click Save, then Refresh sources.

Several repositories and projects in the same team can use the same credentials. For a public repository, choose Public access. See Credentials to update credentials, disable access or delete credentials.

Filter files​

Control which files get indexed using include and exclude patterns.

Open the repository's Advanced options and enter comma-separated values in Include patterns or Exclude patterns. Click Save, then Refresh sources to apply them.

PatternActionEffect
*.mdIncludeOnly Markdown files
docs/IncludeOnly files in docs folder
*.rstIncludeOnly reStructuredText files
node_modules/ExcludeSkip dependencies
.git/ExcludeSkip Git metadata
*.test.*ExcludeSkip test files
build/ExcludeSkip build artifacts

Advanced options​

Add each repository as a separate source, including any submodules you want to index.

Troubleshooting​

Repository not found​

  • Check URL format: https://github.com/owner/repo.
  • For private repos, verify the token has repo scope and hasn't expired.

Files not indexing​

  • Check that include patterns match your file paths.
  • Review exclude patterns for over-exclusion.
  • Verify files are in supported formats (Markdown, plain text, reStructuredText).

Token issues​

  • Confirm the token has repo scope.
  • Regenerate the token if it has expired.
  • Check that repository permissions haven't changed.