Keyword-matching search algorithms (like browser Ctrl+F or standard string grep) evaluate strictly identical characters. When users search for conceptual meaning (e.g. asking "How does memory compression improve model latency?" across a document using phrases like "quantization minimizes memory bandwidth"), traditional search returns zero hits.
DocuVector AI is a client-side semantic document intelligence engine created by Krishna Gupta. It constructs a high-dimensional vector space from arbitrary text, applies sublinear TF-IDF term weighting, and executes instantaneous cosine similarity scoring with interactive 2D vector space projection running entirely in the client's browser with zero backend servers and zero API costs.
The semantic proximity between the user query vector
Where:
-
$N$ represents the active corpus vocabulary dimension. - Each weight incorporates Inverse Document Frequency:
$\text{IDF}(t) = \ln\left(\frac{N_{docs} + 1}{DF(t) + 0.5}\right) + 1$ . - Vectors are
$L_2$ -normalized such that$|\vec{v}|_2 = 1.0$ .
flowchart LR
A["📄 Raw Unstructured Document / Notes"] --> B["✂️ Recursive Paragraph Chunker"]
B --> C["🔤 Tokenizer & Stopword Filtration"]
C --> D["📐 High-Dimensional TF-IDF Matrix"]
D --> E["⚡ L2 Normalized Chunk Vectors"]
F["🔍 Natural Language Concept Query"] --> G["🧮 Query Vector Transformation"]
E --> H["🎯 Cosine Similarity Dot-Product Engine"]
G --> H
H --> I["📊 Top-K Ranked Semantic Results"]
H --> J["🌐 2D Polar Vector Space Projection Canvas"]
- Sub-Millisecond In-Browser Vectorization: Generates high-dimensional vector spaces and computes cosine scores across dozens of chunks in
< 2 ms. - Interactive 2D Vector Radar: Maps multi-dimensional chunk vectors and the query vector onto a 2D polar projection canvas, rendering real-time vector connection lines.
- Dynamic Concept Highlighting: Automatically detects and highlights relevant keyword tokens inside retrieved passages.
- Pre-Loaded Multi-Domain Corpora: 1-click test datasets for AI & Machine Learning Research, Clinical Medical Trials, and Distributed Cloud Architecture.
- Clone this repository:
git clone https://github.com/KrishnaGupta-coder/DocuVector-AI.git cd DocuVector-AI - Open
index.htmlin any browser, or run via Python:python -m http.server 8000
- Ingest documents and explore semantic similarity!