Skip to main content
The Git backend provides the data foundation for transparency, enabling humans to see, understand, and respond to AI work.

The Core Connection

Work-Wiki’s purpose is not measuring what AI did, but building an environment where the Human-AI feedback loop can operate. Three elements are required:
  1. TRANSPARENCY: AI work is visible to human
  2. VISUALIZATION: Presented in a form human can understand
  3. FEEDBACK: Human can efficiently respond/correct/direct AI via prompt
The Git backend provides the data for all three elements.

Attribution Data Flow

WHO Changed What

╔═══════════════════════════════════════════════════════════════════════════════╗
║                                                                               ║
║  ATTRIBUTION DATA EXTRACTION                                                  ║
║                                                                               ║
╠═══════════════════════════════════════════════════════════════════════════════╣
║                                                                               ║
║  SOURCE: Git commits with author information                                  ║
║                                                                               ║
║  AI commits typically include:                                                ║
║  - Author: Human name (from git config)                                       ║
║  - Co-Authored-By: Claude <[email protected]>                             ║
║                                                                               ║
║  Git backend extracts this via:                                               ║
║                                                                               ║
║  1. Commit Detail                                                             ║
║     - Author and email from commit                                            ║
║     - Full message containing Co-Authored-By                                  ║
║     - Files changed with additions/deletions                                  ║
║                                                                               ║
║  2. Blame Tracking                                                            ║
║     - Line number                                                             ║
║     - Author who wrote THIS line                                              ║
║     - Commit hash that introduced it                                          ║
║     - Timestamp when it was written                                           ║
║     - Actual line content                                                     ║
║                                                                               ║
║  3. Author Timeline                                                           ║
║     - Total commits per author                                                ║
║     - Total additions/deletions                                               ║
║     - Time-ordered commit list                                                ║
║     - Most modified files                                                     ║
║                                                                               ║
║  4. Project Summary                                                           ║
║     - Top contributors                                                        ║
║     - Author count                                                            ║
║     - Contribution rankings                                                   ║
║                                                                               ║
╚═══════════════════════════════════════════════════════════════════════════════╝

WHAT Changed

╔═══════════════════════════════════════════════════════════════════════════════╗
║                                                                               ║
║  CHANGE VISUALIZATION DATA                                                    ║
║                                                                               ║
╠═══════════════════════════════════════════════════════════════════════════════╣
║                                                                               ║
║  1. Parsed Diff - Line-level changes                                          ║
║                                                                               ║
║     ParsedDiff {                                                              ║
║       path: String,                                                           ║
║       lines: Vec<ParsedDiffLine>,                                             ║
║       additions: usize,                                                       ║
║       deletions: usize                                                        ║
║     }                                                                         ║
║                                                                               ║
║     ParsedDiffLine {                                                          ║
║       line_type: String,    // "header", "hunk", "addition",                  ║
║                             //  "deletion", "context", "meta"                 ║
║       content: String,                                                        ║
║       old_line: Option<u32>,                                                  ║
║       new_line: Option<u32>                                                   ║
║     }                                                                         ║
║                                                                               ║
║  Frontend can directly render:                                                ║
║  ┌─────────────────────────────────────────────────────────────────────────┐  ║
║  │ Old  │ New  │ Content                                    │ Type         │  ║
║  ├──────┼──────┼─────────────────────────────────────────────┼─────────────┤  ║
║  │      │      │ @@ -10,5 +10,7 @@                           │ hunk        │  ║
║  │ 10   │ 10   │     function calculate() {                  │ context     │  ║
║  │ 11   │      │ -       return a + b;                       │ deletion    │  ║
║  │      │ 11   │ +       // AI: Adding validation            │ addition    │  ║
║  │      │ 12   │ +       if (a === undefined) return 0;      │ addition    │  ║
║  │      │ 13   │ +       return a + b;                       │ addition    │  ║
║  │ 12   │ 14   │     }                                       │ context     │  ║
║  └─────────────────────────────────────────────────────────────────────────┘  ║
║                                                                               ║
║  2. Commit Detail - Commit-level changes                                      ║
║                                                                               ║
║     CommitFile {                                                              ║
║       path: String,                                                           ║
║       status: String,    // "M", "A", "D", "R"                                ║
║       additions: usize,                                                       ║
║       deletions: usize                                                        ║
║     }                                                                         ║
║                                                                               ║
║  3. Branch Relationships - Merge topology                                     ║
║                                                                               ║
║     BranchRelationship {                                                      ║
║       nodes: Vec<BranchNode>,                                                 ║
║       merge_events: Vec<MergeEventInfo>                                       ║
║     }                                                                         ║
║                                                                               ║
╚═══════════════════════════════════════════════════════════════════════════════╝

WHEN and HOW

Timeline data shows work progression:
╔═══════════════════════════════════════════════════════════════════════════════╗
║                                                                               ║
║  TIMELINE DATA EXTRACTION                                                     ║
║                                                                               ║
╠═══════════════════════════════════════════════════════════════════════════════╣
║                                                                               ║
║  1. Commit Graph - Visual commit timeline                                     ║
║                                                                               ║
║     CommitGraph {                                                             ║
║       nodes: Vec<CommitGraphNode>,                                            ║
║       branches: Vec<BranchInfo>,                                              ║
║       total_commits: usize,                                                   ║
║       max_columns: usize                                                      ║
║     }                                                                         ║
║                                                                               ║
║     CommitGraphNode {                                                         ║
║       hash: String,                                                           ║
║       short_hash: String,                                                     ║
║       message: String,                                                        ║
║       author: String,                                                         ║
║       timestamp: i64,                                                         ║
║       relative_time: String,     // "5m ago", "2h ago", etc.                  ║
║       column: usize,             // Visual column for rendering               ║
║       parents: Vec<String>,                                                   ║
║       children: Vec<String>,                                                  ║
║       is_merge: bool,                                                         ║
║       is_branch_tip: bool,                                                    ║
║       connections: Vec<GraphConnection>                                       ║
║     }                                                                         ║
║                                                                               ║
║  2. Timeline Board - Time-bucketed view                                       ║
║                                                                               ║
║     TimelineData {                                                            ║
║       commits: Vec<TimelineCommit>,                                           ║
║       time_range: TimeRange                                                   ║
║     }                                                                         ║
║                                                                               ║
║  3. Branch Timeline - Branch-specific timeline                                ║
║                                                                               ║
║     BranchTimelineCommits {                                                   ║
║       branch: String,                                                         ║
║       buckets: Vec<CommitBucket>                                              ║
║     }                                                                         ║
║                                                                               ║
║     CommitBucket {                                                            ║
║       date: String,         // "2025-01-17"                                   ║
║       commits: Vec<...>,                                                      ║
║       count: usize                                                            ║
║     }                                                                         ║
║                                                                               ║
╚═══════════════════════════════════════════════════════════════════════════════╝

AI Contribution Detection

The backend provides data for detecting AI contributions through multiple patterns:

Pattern 1: Co-Authored-By Marker

commit abc123...
Author: John Doe <[email protected]>

Add new validation feature

- Added input validation
- Added error handling

Co-Authored-By: Claude <[email protected]>  <-- AI marker
Backend provides: Commit full message Frontend can parse for “Co-Authored-By”

Pattern 2: Author Email Detection

Some setups may have AI as direct author: Backend provides: Commit email, Blame author Frontend can match against known AI email patterns

Pattern 3: Commit Message Analysis

AI commits often contain specific patterns:
  • “Generated with [Claude Code]”
  • “Created by GitHub Copilot”
  • Tool-specific markers
Backend provides: Commit message Frontend can use regex matching

Data Refresh Strategy

Initial Page Load

Use batch refresh for fast loading:
┌───────────────────────────────────────────────────────────────────────┐
│  BATCH REFRESH: SINGLE IPC CALL                                       │
├───────────────────────────────────────────────────────────────────────┤
│                                                                       │
│  git_full_refresh({ path, commit_limit: 100 })                        │
│                                                                       │
│       │                                                               │
│       └──► Returns ALL initial data:                                  │
│            ├── status (current branch, staged/unstaged files)         │
│            ├── branches (all local and remote)                        │
│            ├── commits (last N commits)                               │
│            ├── worktrees (all worktrees)                              │
│            └── stashes (all stashes)                                  │
│                                                                       │
│  Benefit: One round-trip for initial load                             │
│                                                                       │
└───────────────────────────────────────────────────────────────────────┘

File Selection

On-demand loading when user selects a file:
┌───────────────────────────────────────────────────────────────────────┐
│  ON-DEMAND FILE LOADING                                               │
├───────────────────────────────────────────────────────────────────────┤
│                                                                       │
│  User selects file                                                    │
│       │                                                               │
│       ├──► git_blame({ path, file_path })                             │
│       │         └──► Line-by-line authorship                          │
│       │                                                               │
│       ├──► git_diff_parsed({ path, file_path, staged: false })        │
│       │         └──► Parsed diff with line types                      │
│       │                                                               │
│       └──► git_file_timeline({ path, file_path })                     │
│                 └──► Commit history for this file                     │
│                                                                       │
│  Each call loads only when needed (lazy loading)                      │
│                                                                       │
└───────────────────────────────────────────────────────────────────────┘

History Exploration

Incremental loading for commit history:
┌───────────────────────────────────────────────────────────────────────┐
│  INCREMENTAL HISTORY LOADING                                          │
├───────────────────────────────────────────────────────────────────────┤
│                                                                       │
│  STEP 1: Load graph structure                                         │
│  ─────────────────────────────                                        │
│  git_commit_graph({ path, limit: 500 })                               │
│       └──► Commit nodes with connections                              │
│            (lightweight, no diffs)                                    │
│                                                                       │
│  STEP 2: User clicks commit                                           │
│  ───────────────────────────────                                      │
│  git_commit_detail({ path, commit_id })                               │
│       └──► Full commit data:                                          │
│            ├── Message                                                │
│            ├── Author, date                                           │
│            ├── Files changed                                          │
│            └── Additions/deletions                                    │
│                                                                       │
│  Pattern: Overview first, details on demand                           │
│                                                                       │
└───────────────────────────────────────────────────────────────────────┘

The Complete Feedback Loop

╔═══════════════════════════════════════════════════════════════════════════════╗
║                                                                               ║
║  THE COMPLETE FEEDBACK LOOP WITH GIT BACKEND                                  ║
║                                                                               ║
╠═══════════════════════════════════════════════════════════════════════════════╣
║                                                                               ║
║       ┌───────────────────────────────────────────────────────────┐           ║
║       │                                                           │           ║
║       │    AI Work                                                │           ║
║       │       │                                                   │           ║
║       │       │ Creates commits with Co-Authored-By               │           ║
║       │       v                                                   │           ║
║       │  ╔═══════════════════════╗                                │           ║
║       │  ║  Git Repository       ║                                │           ║
║       │  ╚═══════════╦═══════════╝                                │           ║
║       │             │                                             │           ║
║       │             │ Git backend extracts                        │           ║
║       │             v                                             │           ║
║       │  ┌───────────────────────┐                                │           ║
║       │  │    TRANSPARENCY       │                                │           ║
║       │  ├───────────────────────┤                                │           ║
║       │  │ - Who: blame,         │                                │           ║
║       │  │   author_timeline     │                                │           ║
║       │  │ - What: diffs,        │                                │           ║
║       │  │   commit_detail       │                                │           ║
║       │  │ - When: log,          │                                │           ║
║       │  │   timeline_board      │                                │           ║
║       │  └───────────┬───────────┘                                │           ║
║       │             │                                             │           ║
║       │             │ Tauri IPC                                   │           ║
║       │             v                                             │           ║
║       │  ┌───────────────────────┐                                │           ║
║       │  │    VISUALIZATION      │                                │           ║
║       │  │    Work-Wiki          │                                │           ║
║       │  │    Frontend           │                                │           ║
║       │  └───────────┬───────────┘                                │           ║
║       │             │                                             │           ║
║       │             │ Human sees AI work                          │           ║
║       │             v                                             │           ║
║       │  ┌───────────────────────┐                                │           ║
║       │  │  Human Understands    │                                │           ║
║       │  ├───────────────────────┤                                │           ║
║       │  │ - What changed        │                                │           ║
║       │  │ - Who changed it      │                                │           ║
║       │  │ - Why/How             │                                │           ║
║       │  └───────────┬───────────┘                                │           ║
║       │             │                                             │           ║
║       │             │ FEEDBACK via prompt                         │           ║
║       │             v                                             │           ║
║       │  ┌───────────────────────┐                                │           ║
║       │  │   Human Responds      │                                │           ║
║       │  ├───────────────────────┤                                │           ║
║       │  │ - Corrections         │                                │           ║
║       │  │ - Directions          │                                │           ║
║       │  │ - Approvals           │                                │           ║
║       │  └───────────┬───────────┘                                │           ║
║       │             │                                             │           ║
║       │             │ Prompt to AI                                │           ║
║       │             │                                             │           ║
║       └─────────────┴─────────────────────────────────────────────┘           ║
║                     │                                                         ║
║                     v                                                         ║
║                AI Work                                                        ║
║            (loop continues)                                                   ║
║                                                                               ║
║  This loop as ONE MOTION = Monokinetics                                       ║
║                                                                               ║
╚═══════════════════════════════════════════════════════════════════════════════╝

THE CENTER

The Git backend is essential to THE CENTER. Without it:
  • No transparency (the loop is BLIND)
  • No visualization (the loop is INCOMPREHENSIBLE)
  • No efficient feedback (the loop is BROKEN)
The Git backend is not just a technical component. It is the foundation of Monokinetic transparency.