Development
GitHub Connector
Index a GitHub repository (its Markdown files, its README and its issues) so the assistant answers from your codebase and your tracker.
Prerequisites
- A GitHub repository you can read
- A Personal Access Token with the `repo` scope: only needed for a private repository
Data ingested
When you connect GitHub, the following content becomes searchable. Every answer that uses it cites it.
| Content | What is kept |
|---|---|
| Markdown files | Every `.md` file of the default branch, path and content kept |
| README | The repository README, indexed even when it is the only document |
| Issues | Title and description of each issue, with their labels |
Setup
Configuration happens in the dashboard, under Integrations. No API call is needed for a normal setup.
Create a token
github.com/settings/tokens → Generate new token, scope `repo`. Skip this step for a public repository.
Pick the repository
Integrations → Add source → GitHub, then choose the repository from the list. The list is read with the token you entered, so a token without access shows nothing.
Choose what to index
Two switches: source code, and issues. A code-only index answers about the implementation; adding issues makes it answer about what was reported.
Connect, then wait for the sync
Indexing starts immediately. The source row shows progress and turns to *ready* when the last document is embedded.
Configuration options
| Field | Description | Required |
|---|---|---|
| Repository | `owner/repo` of the repository to index | Yes |
| Token | Personal Access Token with `repo` scope. Empty for a public repository | No |
| Include source code | Index the Markdown files of the default branch | No |
| Include issues | Index issue titles and descriptions | No |
Best practices
- •Index the repository that holds the documentation, not the one that holds the code, unless you want answers about the implementation itself.
- •A README alone makes a thin corpus: add the `docs/` folder, or connect a second source.
- •Issues age badly. If most of them are closed and outdated, leave them out: an old ticket quoted as current is worse than no ticket.
Troubleshooting
The token has no access to any repository. Check the `repo` scope, and that the token belongs to an account that can read the repository.
The default branch has no `.md` file and no README. Rename the documentation to Markdown, or index the folder that holds it.
Run a sync from the source row. The index follows the branch, so a page deleted upstream disappears at the next sync.
Next steps
Once the source is connected and indexed, ask a question from the chat and check that the answer cites this source. A source that never appears in a citation is usually a source with nothing indexed: see Troubleshooting above.
