Skip to main content
Back to Portfolio ProjectsBhavya Gupta · Case Study
Product / ToolsAI / ML

CalibrAI — Trust Calibration Signals for AI Assistants

Chrome Manifest V3 extension & consent-aware FastAPI backend rendering non-invasive reliability signals below LLM responses.

3 Platforms

Supported AI Surfaces

ChatGPT, Claude, and Gemini adapters

24 Passed

Automated Tests

12 extension Vitest + 12 FastAPI pytest tests

Minimal (storage)

Extension Permissions

Zero history, tabs, or unrestricted host scopes

Deterministic Mock

Current Provider Mode

Phase 2A foundation ready for Phase 2B judging

The Problem

Users routinely over-trust fluent AI assistant outputs because chat UIs present uncertain guesses and verified answers with identical visual confidence. Researching trust calibration across ChatGPT, Claude, and Gemini requires consistent UI instrumentation without breaking host pages or leaking user text.

What I Built

Built a Manifest V3 Chrome extension (WXT + React 18 + strict TypeScript) with provider-neutral site adapters and an isolated Shadow DOM signal overlay, paired with a consent-enforced FastAPI + SQLAlchemy + PostgreSQL/SQLite backend and statistical calibration helpers.

Technical Architecture

Content scripts detect completed answers via MutationObserver + two-sample stability checks, compute SHA-256 answer hashes, and pass typed captures only to the background service worker—which enforces HTTPS, short-lived HMAC-SHA256 tokens, and explicit consent before invoking a replaceable SignalProvider (currently a deterministic mock).

01

Isolated Platform Adapters

ChatGPT, Claude, and Gemini DOM adapters share a single typed capture contract.

02

Shadow DOM Signal Overlay

Renders confidence & explanation pills non-invasively without host CSS collisions.

03

Worker Network Boundary

Content script never touches network; worker enforces HTTPS + HMAC-SHA256 tokens.

04

Consent-Bound FastAPI

Versioned consent, cascade deletion, rate limits, and AUROC/ECE/Brier eval helpers.

Verification & Key Takeaways

  • Built with security-first boundaries: raw prompt/answer persistence disabled in production/study environments.
  • Includes deterministic evaluation tooling for AUROC, fixed-bin ECE, Brier score, and isotonic calibration.
TypeScript (Strict)React 18 & WXT (MV3)Shadow DOMFastAPISQLAlchemy & AlembicPostgreSQL / SQLiteVitest & Pytest