Skip to content

feat(ai): add project recommendation engine#213

Open
vineet1cg wants to merge 1 commit into
nensii21:mainfrom
vineet1cg:feat/project-recommendation-engine
Open

feat(ai): add project recommendation engine#213
vineet1cg wants to merge 1 commit into
nensii21:mainfrom
vineet1cg:feat/project-recommendation-engine

Conversation

@vineet1cg

Copy link
Copy Markdown

Closes #196

Summary

Adds a personalized project recommendation engine that suggests projects to users based on their profile and platform activity.

Recommendation Factors & Weights

Factor Weight Source
Shared Skills 40% User skills ∩ Project skills
Previous Contributions 25% Project membership history
Bookmarked Projects 20% Saved bookmarks
Organization Affiliation 15% Following/org ownership

API

GET /recommendations/projects (authenticated)

  • Returns ranked list of recommended projects (score 0-100)
  • Supports pagination via limit (default 20) and offset
  • Response includes score breakdown per recommendation

Performance

  • Batch-loads all project skills in a single SQL query
  • Uses set() lookups for O(1) user reference data checks
  • Excludes user's own projects from results

Files Changed

  • backend/app/main.py - Register recommendations router
  • backend/app/routers/recommendations.py - New endpoint
  • backend/app/services/recommendation_service.py - Scoring engine
  • backend/app/schemas/recommendation.py - Pydantic schemas

Validation

  • ✅ Ruff lint: 0 errors on new files
  • ✅ Black/isort formatting clean
  • ✅ All Python files parse and import correctly
  • ✅ Follows existing project patterns (static services, FastAPI conventions)

Implement personalized project recommendations for users based on:
- Shared skills (40% weight) - matching user_skills with project_skills
- Previous contributions (25% weight) - project_membership history
- Bookmarked projects (20% weight) - saved/bookmarked projects
- Followed organizations (15% weight) - followed users & owned orgs

New endpoint:
  GET /recommendations/projects - Ranked recommendations with scoring

The scoring engine uses efficient batch queries (single SQL for project skills)
and set-based O(1) lookups for user reference data.

Closes nensii21#196

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 Thank you for your first Pull Request to DevLink!

We appreciate your contribution to our open-source community.

Before your PR is reviewed, please ensure:

  • ✅ The project builds successfully.
  • ✅ Your code follows the project's coding standards.
  • ✅ You have tested your changes.
  • ✅ Related documentation has been updated if necessary.

Our maintainers will review your PR as soon as possible.

Thank you for helping improve DevLink! 💙

@nensii21

nensii21 commented Jul 8, 2026

Copy link
Copy Markdown
Owner

attached videos and screenshots showing what changes have been made also some CI jobs are failing update it.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Project Recommendation Engine

2 participants