arrow_backAdmin Guides
~5 min setup
Connect GitHub
Index your repositories so Sandra can answer questions about your codebase, architecture, and documentation.
What Sandra can do with GitHub
| Code knowledge | Answer questions about your codebase, architecture, and APIs |
| Documentation lookup | Find and reference READMEs, docs, and inline comments |
| Repository browsing | Navigate directory structures and read file contents |
| Knowledge indexing | Chunk, embed, and index repo content for semantic search |
Prerequisites: A GitHub account with access to the repos you want to index, and Sandra Admin Portal access.
1. Create a Personal Access Token
1
2
Click Generate new token → Generate new token (classic)
3
Name:
Sandra AI - Repo Access, Expiration: 90 days recommended4
Check the
repo scope (for public-only repos, just public_repo)5
Click Generate token and copy it
2. Configure Sandra
Option A: Environment variable
env
GITHUB_TOKEN=ghp_xxxxxxxxxxxxxxxxxxxxOption B: Admin Portal
1
Admin Portal → Settings → GitHub Connection
2
Enter the Personal Access Token
3
Click Save
3. Register repositories
1
Admin Portal → Dashboard → System
2
Under Registered Repositories, click Add Repository
3
Enter repos in
owner/repo format (e.g. your-org/frontend-app)4. Index the repositories
1
Click Index Repositories in the System tab
2
Sandra will fetch files, filter by type, chunk content, generate embeddings, and store in the knowledge base
3
Initial indexing may take a few minutes. Re-indexes are faster thanks to content hash change detection.
syncHow indexing works
- • Change detection: Sandra hashes file content — only changed files are re-processed on re-index
- • File filtering: Only code and docs are indexed (no images, binaries, lock files, or node_modules)
- • Chunking: Large files are split into meaningful chunks for accurate search retrieval
- • Embeddings: Chunks are converted to vectors via OpenAI and stored in pgvector for semantic search
5. Verify
1
In the Sandra chat, try: “What does the main README say about getting started?”
2
Or: “How is authentication implemented in our API?”
Troubleshooting
Authentication failed
Verify the PAT hasn’t expired and has the repo scope.
Repository not found
The PAT owner must be a collaborator or org member. Use owner/repo format, not the full URL.
Sandra gives wrong answers about code
Re-index to pick up recent changes. Be specific about which repo or file you’re asking about.
shieldSecurity notes
- • PAT encrypted at rest; Sandra only reads — never pushes code or creates issues
- • Indexed content stored as vector embeddings, not raw files
- • Rotate the PAT before it expires — set a calendar reminder
← Connect Instagram
DM messaging channel.
External APIs →
Connect any REST API.