PathFinder AI: Architecture of an Evidence-Based Adaptive Learning Engine (HCLTech 3rd Place)
How Team PERCEPTRON built an evidence-based skill engine that won 3rd Place nationally at HCLTech AMPlified: Noisy-OR Bayesian verification, a 211-skill prerequisite DAG, and fine-tuning a retrieval bi-encoder lifting Recall@5 from 56.9% to 93.8%.
- ai-ml
- graph-theory
- nlp
- hackathon
- edtech
- system-design

Status: 3rd Place National Finalist (Season 1) — HCLTech AMPlified: The AI Challenge. Team Lead: Sabarish R (Team PERCEPTRON). Top 25 shortlisted out of 4,839 registered engineering students across 97 partner universities.
Every modern EdTech platform asks the same flawed question: "Rate your proficiency in Python from 1 to 5."
The result is what we call the self-report fallacy: learners consistently overestimate foundational skills, skip crucial prerequisites, and hit insurmountable cognitive walls three weeks into an advanced course. Conversely, static learning roadmaps treat all students identically, forcing a developer with 50 open-source Git commits through the same syntax lectures as a novice.
For HCLTech AMPlified: The AI Challenge, our five-member squad (Team PERCEPTRON) set out to replace self-assessment with cryptographic and empirical proof.
PathFinder AI is an evidence-based adaptive learning engine that parses actual work — GitHub commit histories, AST parses of pushed repositories, LeetCode/Codeforces submission telemetry, and verified technical credentials — and dynamically compiles a personalized prerequisite graph with zero manual questionnaire friction.
[Telemetry & Artifacts] [Probabilistic Engine] [Graph Scheduler] [Adaptive Delivery]
GitHub Commits & AST ──┐
LeetCode / Contest Stats ┼──> Noisy-OR Inference ───> 211-Node Skill DAG ───> ONNX Bi-Encoder ───> Socratic Nexus
Verified Credentials ──┘ (4-Tier Evidence) (Kahn's Topo-Sort) (Recall@5: 93.8%) (AI Mentor)
Here is how the architecture works under the hood.
1. The Four-Tier Noisy-OR Evidence Model
To verify competence without standardized multiple-choice tests, we implemented a probabilistic confidence model based on Noisy-OR factorization. Every candidate concept is assigned a mastery probability evaluated across four tiered evidence sources:
- Proven (Weight 0.95): Static AST analysis of public GitHub repositories verifying semantic syntax usage (e.g., recursive descent parsers, custom decorators, asyncio event loops), plus unit test passes.
- Verified (Weight 0.85): Third-party API telemetry — solved LeetCode problem IDs, contest ranking percentiles, and verified credentials (e.g., ServiceNow CSA, Azure AI Fundamentals).
- Claimed (Weight 0.35): Resume parsing with spaCy entity extraction linking stated competencies to historical project dates.
- Inferred (Weight 0.20): Latent skill propagation across graph neighbors in the prerequisite ontology.
Under the Noisy-OR assumption, failure to demonstrate mastery across independent evidence channels implies the skill is not yet internalized. The posterior confidence score for skill k given observed evidence events is calculated as:
P(Mastery_k | Evidence) = 1 - ∏_{i ∈ Evidence(k)} (1 - q_i · w_i)
where q_i ∈ [0, 1] represents the raw evidence strength (e.g., test coverage or problem difficulty rating) and w_i represents the tier-specific reliability factor.
- If
P(Mastery_k) >= 0.78, the skill is considered satisfied and bypassed. - If
0.35 <= P(Mastery_k) < 0.78, a targeted diagnostic micro-challenge is triggered. - If
P(Mastery_k) < 0.35, the prerequisite is flagged as an active learning gap.
2. The 211-Skill Prerequisite Graph & Kahn's Topological Scheduling
Curriculum sequencing is formalized as a Directed Acyclic Graph (DAG) G = (V, E), where V comprises 211 granular competencies across computer science and machine learning, and directed edge (u, v) denotes that competency u is a strict prerequisite for competency v.
[Discrete Math] ──────────────┐
│ ▼
▼ [Probability]
[Linear Algebra] │
│ ▼
▼ [Gradient Descent]
[Vectorized Matrix Ops] │
│ │
└───► [Multilayer Perceptron] ◄───┘
│
▼
[Backprop & Computation Graph]
Dynamic Topological Scheduling via Kahn's Algorithm
When a learner targets a terminal goal (e.g., "Fine-tune a Domain Bi-Encoder for RAG"), PathFinder AI extracts the induced subgraph containing all upstream dependencies.
Instead of standard topological ordering, we modified Kahn's algorithm to incorporate a Dynamic Yield Heuristic:
- Initialize in-degrees for all vertices in the target subgraph.
- Maintain a priority queue
Qof all nodes within-degree = 0. - When selecting the next competency from
Q, score each candidate nodeuby:
Priority(u) = λ · OutDegree(u) + (1 - λ) · (1 - P(Mastery_u))
where OutDegree(u) measures how many downstream competencies unlock once u is mastered, and λ = 0.65.
- Remove
u, add to the personalized schedule, and decrement in-degrees of adjacent dependencies.
This mathematical scheduling ensures that high-yield bottleneck concepts (e.g., Matrix Calculus or Vector Embeddings) are prioritized immediately, preventing downstream stalls and maximizing curriculum velocity.
3. The Retrieval Bi-Encoder: Recall@5 from 56.9% → 93.8%
Once the next competency node in the DAG is isolated, the engine must retrieve the highest-yield micro-lessons, open-source code repositories, and documentation chunks.
The Failure of Off-the-Shelf Embeddings
Initially, we deployed standard dense sentence transformers (all-MiniLM-L6-v2) computing cosine similarity between skill queries and course catalog representations. The results were unacceptably noisy:
- Baseline Recall@1: 31.4%
- Baseline Recall@5: 56.9%
- Mean Reciprocal Rank (MRR): 0.428
Off-the-shelf embeddings conflated superficial terminology. For instance, searching for "Graph Topological Sort" repeatedly returned generic tutorials on "Sorting Arrays in Python", because both documents shared lexical markers (sort, algorithms, linear).
Bi-Encoder Fine-Tuning Loss (MultipleNegativesRankingLoss):
L = -log( exp(sim(q_i, d_i^+) / τ) / Σ exp(sim(q_i, d_j) / τ) )
Contrastive Triplet Fine-Tuning
To fix this, we created a curated dataset of 2,400 technical skill queries mapped to verified curriculum targets, paired with hard negative mining:
- Anchor (
q): Precise DAG competency definition (e.g.,"Kahn's algorithm cycle detection topological order"). - Positive (
d+): Exact code snippets, algorithmic explanations, and implementation exercises. - Hard Negative (
d-): Lexically similar but semantically distinct topics (e.g.,"QuickSort divide and conquer partition"or"Depth First Search topological ordering differences").
We fine-tuned a domain-adapted bi-encoder architecture using MultipleNegativesRankingLoss with a temperature parameter τ = 0.05 across 12 epochs:
# Simplified training loop snippet
from sentence_transformers import SentenceTransformer, InputExample, losses
from torch.utils.data import DataLoader
model = SentenceTransformer("sentence-transformers/all-MiniLM-L6-v2")
train_examples = [
InputExample(texts=[anchor, positive, hard_negative])
for anchor, positive, hard_negative in training_triplets
]
train_dataloader = DataLoader(train_examples, shuffle=True, batch_size=32)
train_loss = losses.MultipleNegativesRankingLoss(model)
model.fit(
train_objectives=[(train_dataloader, train_loss)],
epochs=12,
warmup_steps=100,
optimizer_params={"lr": 2e-5}
)
Results & ONNX Deployment
| Metric | Stock all-MiniLM-L6-v2 | Fine-Tuned Bi-Encoder | Delta |
| :--- | :--- | :--- | :--- |
| Recall@1 | 31.4% | 78.2% | +46.8% |
| Recall@5 | 56.9% | 93.8% | +36.9% |
| MRR@10 | 0.428 | 0.864 | +0.436 |
| Latency (CPU) | 48 ms | 12 ms (ONNX quantized) | -75.0% |
To eliminate expensive cloud API dependencies during live user interactions, the fine-tuned bi-encoder was quantized into an ONNX INT8 runtime weighing only 32MB. This allows the retrieval engine to execute locally inside the browser or edge server in under 15 milliseconds.
4. Nexus: Socratic Diagnostic Mentor
When a student struggles with a project milestone or coding prompt, standard LLM chat interfaces suffer from premature answer leaking — the model outputs complete source code, robbing the learner of active problem-solving retention.
We engineered Nexus, an in-context Socratic mentor agent configured with strict stateful guardrails:
[Student Error Trace]
│
▼
[Nexus Prompt Guardrail]
│
┌─────────────────────────┴─────────────────────────┐
▼ ▼
[Diagnostic Inquiry] [Answer Leaking Check]
"What is the current in-degree Did the response leak full code?
of node C in your trace table?" │
│ ▼
▼ [Violations Quarantined]
[Socratic Scaffolding] Forced back to hint level 1
- Level 1 (Concept Ping): Clarifies prerequisite definitions without touching user variables.
- Level 2 (Diagnostic Question): Points to runtime discrepancies (e.g., "Notice line 24: what happens to your queue when a cycle is present in the graph?").
- Level 3 (Minimal Scaffolding): Provides a 2-line pseudocode abstraction. Direct production code emission is structurally disallowed.
5. Hackathon Verification Receipts
Out of 4,839 registered engineering students across 97 partner colleges in HCLTech AMPlified: The AI Challenge Season 1:
- Round 1 (Top 100): Team PERCEPTRON placed Rank #7 nationally in the initial algorithmic and systems assessment.
- Round 2 (National Pitch): Selected among the Top 25 National Finalists to present live before the senior technical leadership and jury panel of HCLTech.
- National Final: Placed 3rd Place Nationally, awarded a cash grant and executive recognition.

Official Round 2 National Leaderboard confirming Team PERCEPTRON at Rank #3.

Round 2 Top 25 National Finalist receipt awarded by HCLTech.

Round 1 Top 100 Rank #7 Elite Finisher receipt.
6. Full Tech Stack Summary
- Frontend & App Architecture: Next.js 16 (App Router), TypeScript, Tailwind CSS, Lucide icons.
- Inference Runtime: PyTorch (training), ONNX Runtime Web / CPU (32MB quantized bi-encoder).
- Database & Graph Storage: Supabase (PostgreSQL), Prisma ORM with adjacency list indexing.
- Vector Search: pgvector + in-process cosine indexing.
- Evaluation: Custom automated test harness measuring topological validity and Recall@K.
PathFinder AI proved that high-performance educational software does not need to treat learners like uniform black boxes. By anchoring skill evaluation to demonstrable code artifacts and pairing Kahn-scheduled DAGs with fine-tuned bi-encoders, we can build pathways that adapt to real engineering competence.
Filed under Sabarish R — Security & AI Notes.