GapLens Logo
DiveAI presents
GapLens
AI-Powered Requirement Gap Detection
Local Transparent AI-Enhanced
Wenyan Yang · Tomáš Janovec · Samantha Bavautdin
COMP.CS.530-2025-2026-2
How it works
From problem to solution

Walk through the full story in our interactive slide deck.

"Did we cover
all the requirements?"
The question that keeps every PM, BA, and engineering lead up at night.
PM at 3am ? ? ? ? ? ?
The old way:
painful
Re-interviewing stakeholders is expensive. Manually cross-checking historical docs? Soul-crushing.
Doc 1 Doc 2 ...Doc 847 You, reading every single one Week 1: still readingWeek 2: eyes hurtWeek 3: "good enough" Spoiler: it wasn't good enough.
Why not just ask an LLM?
Generation-based approaches have fundamental issues for gap detection:
!
Hallucination
Generates plausible but nonexistent gaps
Data leakage risk
Sending proprietary specs to external APIs
Not reproducible
Different run, different gaps flagged
Our approach:
embeddings as geometry
No generation no hallucination risk phi close! Embed, then measure k-NN on S^(d-1), d=1024 Per-project z-score Soft Category x Topic grid deterministic, auditable Corpus point Your requirement Gap distance Embeddings for understanding. Geometry for detection.
Introducing
GapLens
k-NN geometric gap detection via soft cell aggregation
Requirements Embed (d=1024) k-NN gaps (k=1) Aggregate Report Deterministic. Reproducible. Auditable.
How gap detection works
"System shall encrypt data at rest" Qwen3 g(r) Encode each requirement into an embedding point
reference corpus phi phi small = covered phi large = deficit Measure distance, z-score against training projects
Encrypt. Auth Data Backup Security Perform. Portability 2.1 0.6 0.4 0.1 h(r) Assign scores to Category x Topic cells
Security / Encrypt. = 2.1 Portability / Auth = 1.8 Perform. / Data = 1.2 ... High score = gap, low score = covered Entire missing categories collapsed into single findings

Seeing the gaps in 3D

Each requirement becomes a point in space. Clusters form around topics. Red lines reveal where your project has blind spots.

Drag to orbit / scroll to zoom
Known topics Your project Gap
Open the black box
Unlike LLM chat, every gap has a visual explanation you can inspect, verify, and trust.
Gap heatmap Ranked findings1. Missing: Security / Encryption2. Missing: Portability / Backups3. Partial: Performance / Data+ example requirements from corpus
Your dataset.
Your rules.
Your machine.
Healthcare HIPAA safe Finance Audit ready Defense Air-gapped OK Automotive ISO 26262 Bring your own docs. The pipeline adapts. Flexible Private Transparent
What we learned
1 Ground-truth category labels enable centroid-based assignment (78.3% accuracy) 2 Gap detection in full d=1024 — UMAP only for topic clustering, not for k-NN scoring 3 k = 1 is optimal — AUROC decays monotonically from 0.87 (k=1) to 0.39 (k=20) for N>=50 projects 4 Soft topic assignment eliminates outlier loss — every requirement contributes to every topic 5 Per-project normalisation prevents false alarms on inherently sparse requirement categories
Built different
Safe
100% local deployment. Your data never leaves your machine. Zero telemetry.
Transparent
Every gap score is auditable. Visual heatmaps explain every finding.
Flexible
Any domain, any format. Bring your own dataset and the pipeline adapts.
Works with modern AI agents
MCP wrapper shares analysis results, never raw data. Your docs stay local — agents get the insights they need.
Stop guessing.
Start measuring.
Try GapLens today
Lightweight. Private. Explainable. AI-powered.
Requirement gap detection that actually works.
No cloud No GPU No hallucinations LLM embeddings 2 seconds
Features
Why GapLens?

We keep AI's brain but ditch its mouth. No generation. No cloud. No hallucinations.

100% local

Your data never leaves your machine. Zero telemetry. No cloud APIs. Deploy in air-gapped environments.

Transparent

Every gap score is auditable. Visual heatmaps and ranked findings explain exactly why each gap was flagged.

AI-enhanced

LLM embeddings provide deep semantic understanding. Geometric analysis on the full 1024-dimension space.

2-second analysis

CPU-only inference. No GPU required. Analyse your entire requirements spec in under two seconds.

No hallucinations

Pure geometry, not generation. Every finding is grounded in real data — no made-up requirements.

Stop guessing. Start measuring.

Requirement gap detection that actually works.

Source Code Full Report
Citation
Reference this work

If you use GapLens in your research or project, please cite us.

@article{yang2026geogap, title = {Detecting Underspecification in Software Requirements via $k$-NN Coverage Geometry}, author = {Yang, Wenyan and Janovec, Tom{\'a}{\v{s}} and Bavautdin, Samantha}, year = {2026}, note = {Project page: \url{https://uenian33.github.io/gaplens/}}, url = {https://github.com/uenian33/GeoGapSW}, }