Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

Git Hooks for AI Pair Programming: Capturing, Indexing, and Searching Your AI Coding Sessions

说明与用途

Git 钩子自动记录 AI 伴侣编程会话,进行本地索引并提供可搜索的 CLI,支持审计和上下文恢复。

问题

AI pair programming sessions lose context between Git events, causing repeated work and lost reasoning.

结果

A local‑first, privacy‑preserving pipeline that captures AI pair programming sessions, indexes them, and provides instant search, enabling teams to audit AI‑assisted changes and recover lost context.

工作流

  • 1. Add bash scripts to .git/hooks/ for post-checkout, post-commit, and pre-push that emit JSONL events to .ai_sessions/events.jsonl
  • 2. Ensure hooks are non‑blocking and write minimal data (session_start, session_end, aggregation_checkpoint)
  • 3. Run a Rust indexer (indexer.rs) on demand or during pre-push to build an inverted index and semantic fingerprints in .ai_sessions/index/
  • 4. Use a Rust CLI (search.rs) to query the index by keyword, session hash, or date range
  • 5. Verify that session logs travel with code in PRs and can be bisected across commits

证据

Everything runs locally—no cloud telemetry, no third‑party APIs, pure version‑controlled observability.

来源

Hooks run on every relevant Git event without manual intervention.

来源

  • 记录日期: 2026-09-14T18:16:20.615Z