Skip to content

feat(recommender): add skill progression graph with gap scoring#829

Open
parinaB wants to merge 1 commit into
komalharshita:mainfrom
parinaB:main
Open

feat(recommender): add skill progression graph with gap scoring#829
parinaB wants to merge 1 commit into
komalharshita:mainfrom
parinaB:main

Conversation

@parinaB

@parinaB parinaB commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Summary [required]

Added a skill progression graph to the recommendation engine. Instead of only matching what the user already knows, the engine now computes reachable next skills using BFS on a directed graph and boosts projects that target those gap skills giving returning users a clear sense of what to learn next.

Related Issue [required]

Closes #390

Type of Change [required]

  • Bug fix — resolves a broken behaviour
  • Feature — adds new functionality
  • Data — adds new projects to data/projects.json
  • Documentation — updates docs, README, or code comments only
  • Style — CSS or visual changes only, no logic change
  • Refactor — restructures code without changing behaviour
  • Test — adds or updates tests

What Was Changed [required]

  • Added data/skill_graph.json — directed skill dependency graph covering all skills in projects.json plus Java extensions (spring, sql)
  • Added _load_skill_graph() — loads graph from disk with soft failure
  • Added _hops_to_skill() — BFS to find minimum hops from known skills to a target skill
  • Added gap_boost() — boosts project score by 1/hops for each reachable missing skill
  • Added get_progression() — returns up to 3 projects that are 1 hop away from user's current skills, not already recommended
  • Updated get_recommendations() — now returns progression key alongside recommendations and related
  • Added VALID_INTERESTS constant that was missing from validation
  • Fixed duplicate project ID 10 in projects.json
  • Updated test_recommender.py — added skill graph progression test section

How to Test This PR [required]

  1. Clone this branch: git checkout your-branch-name
  2. Install dependencies: pip install -r requirements.txt
  3. Run the recommender tests:: python test_recommender.py

Expected test output:

Input validation
----------------
  PASS  empty skills caught
  PASS  empty level caught
  PASS  valid inputs pass through cleanly

Return shape
------------
  PASS  get_recommendations returns a dict
  PASS  dict has 'recommendations' key
  PASS  dict has 'related' key

Recommendations
---------------
  PASS  recommendations is a list  (3 result(s))
  PASS  respects MAX_RESULTS cap  (got 3)
  PASS  all results have required fields
  PASS  High time availability returns >= results than Low
  PASS  no-match input returns empty recommendations

Skill alias normalisation
-------------------------
  PASS  'js' alias resolves to 'javascript'

Skill graph progression
-----------------------
  PASS  dict has 'progression' key
  PASS  progression is a list  (1 result(s))
  PASS  progression projects don't repeat recommended ones
        → API ETL Pipeline  (gap_score: 2.0)

Done.

Test Results [required]

Screenshot 2026-06-09 at 4 10 41 PM

Self-Review Checklist [required]

  • I have read CONTRIBUTING.md and followed all guidelines
  • My branch name follows the convention: feat/, fix/, docs/, data/, style/, test/
  • I have run python tests/test_basic.py and all 27 tests pass
  • I have run flake8 . locally and there are no errors
  • I have not introduced any print() or console.log() debug statements
  • Every new function I wrote has a docstring
  • I have not modified files outside the scope of the linked issue
  • If I changed the UI, I tested it at 375px (mobile) and 1280px (desktop)
  • If I added a project to the dataset, it has all required JSON fields

@vercel

vercel Bot commented Jun 9, 2026

Copy link
Copy Markdown

@parinaB is attempting to deploy a commit to the komalsony234-1530's projects Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: Add skill gap detection to recommend projects that advance user learning

1 participant