Repository navigation
Add GitHub as a Composio memory provider (joining gmail / notion / slack / clickup / linear) #62
Description
Original issue tinyhumansai#2408 by @justinhsu1477 on 2026-05-21T04:03:32Z
Summary
Add GitHubProvider under src/openhuman/composio/providers/github/, lifting the existing catalog-only GitHub module into a full native memory-ingest provider. Until now github/mod.rs declares itself "curated tool catalog only — no native ComposioProvider implementation yet"; this change closes that gap so the connected user's GitHub issues stream into the Memory Tree on the periodic scheduler.
Problem
composio/providers/ already has memory-ingest providers for gmail, notion, slack, clickup, and (pending merge of tinyhumansai#2402) linear. github/ is in the same providers/ folder but is structurally one level lower — only tools.rs is populated; there's no ComposioProvider impl, no entry in init_default_providers, no has_native_provider match.
For an open-source AI assistant whose own contributors live on GitHub, this is the most obviously high-leverage missing provider: every maintainer / reviewer / external contributor can dogfood it within minutes of merge.
Solution
Promote composio/providers/github/ to a full provider by adding the three companion files that already exist for gmail / notion / clickup / linear:
src/openhuman/composio/providers/github/
mod.rs — UPDATED to declare provider/sync/tests modules + re-export
tools.rs — KEEPS existing GITHUB_CURATED (no changes needed —
GITHUB_GET_AUTHENTICATED_USER and GITHUB_SEARCH_ISSUES
are already curated, which is the minimum the sync path needs)
provider.rs — NEW: impl ComposioProvider for GitHubProvider
sync.rs — NEW: payload-shape helpers (extract_issues,
extract_issue_title, extract_issue_updated,
extract_repo_qualified_identifier, extract_viewer_login)
tests.rs — NEW: unit tests
Plus the standard registration touchpoints (same six places ClickUp landed in tinyhumansai#2291 and Linear in tinyhumansai#2402):
composio/providers/mod.rs:has_native_providermatches"github"(already inCAPABILITY_TOOLKITS).composio/providers/mod.rs::native_provider_sync_interval: add"github" => ...arm.composio/providers/mod.rs::catalog_for_toolkit: stays — already points togithub::GITHUB_CURATED.composio/providers/registry.rs::init_default_providers:register_provider(Arc::new(GitHubProvider::new())).composio/providers/descriptions.rs: update GitHub description to mention Memory Tree sync (matches the clickup / linear shape).github/mod.rsdocstring: remove the "no native impl yet" disclaimer.
Sync model (mirroring Linear)
SyncState::load("github", connection_id)from the shared KV store.- Daily request budget check.
- Resolve viewer login via
GITHUB_GET_AUTHENTICATED_USER— needed for theassignee:<login>search filter. - Re-check budget between viewer probe and search call (same discipline ClickUp/Linear got after CodeRabbit feedback).
- Page through
GITHUB_SEARCH_ISSUESwith queryassignee:<viewer_login> sort:updated-desc. GitHub's search API caps at 1000 results, so pagination is naturally bounded. - Per issue, persist as one memory document via
persist_single_item. Dedupe by compositeissue_id@updated_at. - Advance cursor to newest
updated_atseen, save state.
Source-id convention
composio-github-issue-<global_id> — GitHub's id (integer) is globally unique across all of GitHub, so it's a stable key. The document title uses the human-readable form GitHub <owner>/<repo>#<number>: <title> (e.g. GitHub tinyhumansai/openhuman#2400: Add Linear...) so search hits surface the way contributors refer to issues in conversation.
Privacy posture
Same "fetch-what-the-user-sees" stance as gmail / notion / clickup / linear: only issues where the connected user is the assignee are pulled, never the whole watched-repos' issue graphs. The assignee:<viewer_login> qualifier is constructed inside the provider, never accepted from a caller, so the boundary can't be tunnelled around.
Acceptance criteria
-
GitHubProviderregistered ininit_default_providersalongside gmail / notion / slack / clickup / linear. - First
sync()afteron_connection_created()ingests one page of GitHub issues into the Memory Tree asDocumentchunks with source-idcomposio-github-issue-<…>. - Incremental sync respects the
updated_atcursor. - Daily request budget check fires.
- Assignee-scoped fetch — no issue is pulled unless
viewer_loginis inassignees. - Unit tests cover cursor advancement, dedup, canonicalize, viewer extraction.
- Diff coverage ≥ 80% — changed-lines coverage gate.
-
github/mod.rsdocstring updated to reflect new native-provider status.
Out of scope (follow-ups)
- PR ingest (
pulls/) — issues only for v1; PR-as-memory-doc is a separate, larger surface decision. - Comments-as-separate-docs — v1 folds key issue context into the issue document via
GITHUB_LIST_ISSUE_COMMENTSif pulled, but doesn't create one chunk per comment. - Notifications inbox (
notifications/) — different sync model, separate provider follow-up. - Repo / Releases / Discussions ingest — out of scope for v1.
Related
- Closest templates:
composio/providers/linear/(feat(composio): add Linear provider for Memory Tree ingest tinyhumansai/openhuman#2402, open),composio/providers/clickup/(feat(composio): add ClickUp provider for Memory Tree ingest tinyhumansai/openhuman#2291, merged). - Provider trait:
composio/providers/traits.rs. - Shared sync state:
composio/providers/sync_state.rs. - Current
GITHUB_CURATED:composio/providers/github/tools.rs(7081 bytes, ~30 actions across Read / Write / Admin).
Activity