stemedb/applications/aphoria-dashboard
jml e95c978481 feat(aphoria): add inline claim markers and claim enrichment infrastructure
This commit implements Phase 17 of the Aphoria roadmap, adding:

**Inline Claim Markers (@aphoria:claim):**
- New extractor for detecting inline markers in comments
- Pending markers tracked in .aphoria/pending_markers.toml
- CLI commands: list-markers, formalize-marker, reject-marker
- Support for all major comment styles (Rust, Python, SQL, etc.)
- Auto-sync during scan (configurable)

**Claim Enrichment:**
- ClaimEnrichment type with source attribution (inline, extractor, manual)
- EnrichedClaimInfo with full enrichment metadata
- Extended AuthoredClaim with optional enrichment field
- API endpoints for enriched claim queries
- Dashboard UI components (enrichment badge, verdict badge)

**Enhanced Extractor Trait:**
- verifiable_predicates() method for declaring (tail_path, predicate) pairs
- 10 security extractors now implement verifiable_predicates
- Enables claim suggester skill to find unclaimed patterns

**Documentation:**
- Phase 17 summary with complete implementation details
- Gap fixes summary documenting 8 closed vision gaps
- Updated CLI reference with new commands
- New aphoria-docs skill for documentation maintenance
- Updated roadmap with Phase 17 completion

**Integration:**
- ClaimsFile support for claim enrichment persistence
- Pattern aggregate store support for enrichment queries
- Dashboard filters and display for enrichment metadata
- API handlers for list-markers and enrichment queries

**Tests:**
- New gap_fixes_integration test suite
- Corpus enricher module with best practices ingestion

Closes: VG-005, VG-017, VG-018, VG-019, VG-020, VG-021, VG-022, VG-023

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-08 20:18:20 +00:00
..
src feat(aphoria): add inline claim markers and claim enrichment infrastructure 2026-02-08 20:18:20 +00:00
.gitignore feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
components.json feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
CORPUS_STATUS.md feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
DOCUMENTATION_INDEX.md feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
next.config.ts feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
package.json feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
postcss.config.mjs feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
QUICK_REFERENCE.md feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
README.md feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00
tsconfig.json feat(aphoria): add git commit tracking + comprehensive documentation 2026-02-08 18:36:46 +00:00

Aphoria Dashboard

Code quality assurance dashboard for Aphoria - the code-level truth linter powered by Episteme.

Features

  • Scans: Run and view Aphoria code scans with conflict detection
  • Claims: Manage authored claims (architectural decisions, safety invariants, policy requirements)
  • Corpus: Browse and filter the community corpus of authoritative sources (RFCs, OWASP, CWEs)

Quick Start

# Install dependencies
npm install

# Run development server (port 18189)
npm run dev

# Build for production
npm run build

# Start production server (port 18189)
npm start

Architecture

  • Framework: Next.js 16 with App Router
  • UI: TailwindCSS 4 + shadcn/ui components
  • Port: 18189 (Aphoria Dashboard)
  • API Integration: Proxies requests to StemeDB API at port 18180

API Integration

The dashboard uses Next.js rewrites to proxy API requests:

// All /v1/* requests are proxied to http://localhost:18180/v1/*
// This is configured in next.config.ts

Leave NEXT_PUBLIC_STEMEDB_API_URL empty in .env.local to use proxy mode.

Project Structure

src/
├── app/                    # Next.js app router pages
│   ├── scans/             # Aphoria scans route
│   ├── claims/            # Claims management route
│   ├── corpus/            # Corpus browser route
│   └── layout.tsx         # Root layout with Aphoria branding
├── components/
│   ├── corpus/            # Corpus browser components
│   ├── scans/             # Scans panel components
│   ├── claims/            # Claims management components
│   ├── layout/            # Sidebar, header, theme toggle
│   ├── shared/            # Shared components (error, api-status)
│   └── ui/                # shadcn/ui components
└── lib/
    ├── api/               # API client (includes both StemeDB + Aphoria)
    └── utils.ts           # Utilities
  • Aphoria Backend: applications/aphoria/ - Rust CLI and extractor engine
  • StemeDB Dashboard: Port 18188 - Database admin dashboard
  • StemeDB API: Port 18180 - Backend API

Development

The dashboard shares some infrastructure with StemeDB Dashboard (UI components, API client, utilities). See applications/DASHBOARD_SYNC.md for sync procedures if you update shared code.