Eidetic

AI Coauthor Badge

AI
Trust
Identifier

Lightweight component for displaying AI/human authorship attribution. Shows the percentage split between human and AI-generated content with badge, inline, and card variants.

Badge Variant

Compact authorship indicator with tooltip

Human
35% AI
80% AI
AI

Inline Variant

Horizontal layout for document headers

Co-authored
|
65%35%
|
Written by Human

Card Variant

Card with progress bar and stats

Authorship

Co-authored
Human55%
AI45%
Human
AI

Pure AI Content

Card showing 100% AI-generated content

Authorship

AI
Human0%
AI100%
Human
AI

Props

AICoauthorBadge component API reference

PropTypeDefaultDescription
stats*AuthorshipStatsAuthorship statistics with human/AI percentages
variant'badge' | 'inline' | 'card''badge'Display variant
showHighlightingbooleanfalseWhether authorship highlighting is active
onHighlightingChange(enabled: boolean) => voidCallback when highlighting toggle changes

Type Interface

AuthorshipStats data model

interface AuthorshipStats {
humanPercentage: number // 0-100
aiPercentage: number // 0-100
totalEdits?: number // Optional edit count
}

Usage

Import and basic examples

import { AICoauthorBadge } from '@/blocks/ai-transparency/ai-coauthor-badge'
// Simple badge
<AICoauthorBadge
stats={{ humanPercentage: 65, aiPercentage: 35 }}
/>
// Inline with highlighting toggle
<AICoauthorBadge
variant="inline"
stats={{ humanPercentage: 55, aiPercentage: 45 }}
showHighlighting={isHighlighting}
onHighlightingChange={setIsHighlighting}
/>
// Card variant
<AICoauthorBadge
variant="card"
stats={{ humanPercentage: 40, aiPercentage: 60, totalEdits: 8 }}
/>

Built With

3 components

This block uses the following UI components from the design system:

Simplification Note

Simplified from AI Coauthor Indicator

Simplified Component

This is a streamlined version of the original AI Coauthor Indicator (~500 lines reduced to ~250 lines). It focuses on the most common use case — showing authorship attribution — without the detailed segment-level editing features. For segment-level content tracking, consider using the original AI Coauthor Indicator directly.

Features

Built-in functionality

  • Three variants: Badge, inline, and card display modes
  • Auto-detection: Automatically determines human/AI/mixed authorship type
  • Progress visualization: Split progress bar showing human vs AI contribution
  • Highlighting toggle: Optional toggle for showing authorship highlighting
  • Tooltip details: Badge shows detailed breakdown on hover
  • Dark mode: Full dark mode support

Accessibility

Accessibility considerations

ARIA Attributes

Authorship values conveyed via text labelsTooltip accessible via keyboard focus

Keyboard Navigation

KeyAction
TabFocus interactive elements
Enter / SpaceToggle highlighting

Notes

  • Color-coded indicators always paired with text labels
  • Progress bar supplemented by percentage text