PHPackages                             njuptaaa/problem-recommendation - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. njuptaaa/problem-recommendation

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

njuptaaa/problem-recommendation
===============================

collaborative filtering recommender systems

00PHP

Since Mar 6Pushed 4y ago1 watchersCompare

[ Source](https://github.com/NJUPTAAA/problem-recommendation)[ Packagist](https://packagist.org/packages/njuptaaa/problem-recommendation)[ RSS](/packages/njuptaaa-problem-recommendation/feed)WikiDiscussions main Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

NOJ Problem Recommendation
==========================

[](#noj-problem-recommendation)

NOJ Problem Recommendation based on awesome algorithm by [tigoCaval](https://github.com/tigoCaval/recommendation-algorithm).

Getting started
---------------

[](#getting-started)

For PHP &gt;= 7.0, require package using composer:

```
composer require njuptaaa/problem-recommendation
```

Supporting Algorithms
---------------------

[](#supporting-algorithms)

- ranking
- euclidean
- slope one

Introduction
------------

[](#introduction)

Recommend a problem using collaborative filtering:

```
/**
 * $table gets the array from the database.
 * $user is the foreign key that represents the user who will receive the recommendation.
 */
use NJUPTAAA\ProblemRecommendation\Recommend;

$client = new Recommend();
$client->ranking($table, $user); // optional third parameter refers to the score not accepted
$client->euclidean($table, $user); // optional third parameter refers to the minimum accepted score
$client->slopeOne($table, $user); // optional third parameter refers to the minimum accepted score
```

### Configuration

[](#configuration)

```
$client = new Recommend('score', 'pid', 'uid');
```

###  Health Score

14

—

LowBetter than 1% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity0

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity27

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/19504567?v=4)[John Zhang](/maintainers/ZsgsDesign)[@ZsgsDesign](https://github.com/ZsgsDesign)

---

Top Contributors

[![ZsgsDesign](https://avatars.githubusercontent.com/u/19504567?v=4)](https://github.com/ZsgsDesign "ZsgsDesign (3 commits)")

### Embed Badge

![Health badge](/badges/njuptaaa-problem-recommendation/health.svg)

```
[![Health](https://phpackages.com/badges/njuptaaa-problem-recommendation/health.svg)](https://phpackages.com/packages/njuptaaa-problem-recommendation)
```

###  Alternatives

[thecodingmachine/safe

PHP core functions that throw exceptions instead of returning FALSE on error

2.5k112.2M560](/packages/thecodingmachine-safe)[league/iso3166

ISO 3166-1 PHP Library

69938.4M140](/packages/league-iso3166)[amphp/process

A fiber-aware process manager based on Amp and Revolt.

25760.7M67](/packages/amphp-process)[jsvrcek/ics-bundle

This bundle provides a dependency injection wrapper for the JsvrcekICS iCal library

11159.6k](/packages/jsvrcek-ics-bundle)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
