Collaborative Filtering (CF) is a classic category of algorithms in personalized recommendation systems. Its core idea is not to directly understand item content, but rather to discover “similar users” or “similar items” based on large-scale historical user behavior—and then recommend content that the current user may find interesting.
In e-commerce, it can be used to recommend products; on video platforms, to recommend movies or short videos; and in educational systems, to recommend concepts and exercises.
In early recommendation system research, GroupLens applied collaborative filtering based on user ratings to recommend news content; later, Amazon’s Item-to-Item Collaborative Filtering established “item-based collaborative filtering” as one of the most representative industrial recommendation approaches. [1][2]
I. Understanding Collaborative Filtering Through a Real-Life Example
Suppose there are three people:
| User | Liked Movies |
|---|---|
| User A | The Three-Body Problem, The Wandering Earth, Interstellar |
| User B | The Three-Body Problem, The Wandering Earth |
| User C | Empresses in the Palace, Knowing Whether, Nirvana in Fire |
The system observes:
User A and User B both like *The Three-Body Problem* and *The Wandering Earth*
So the system infers:
User A and User B have relatively similar interests.
Since User A also likes Interstellar, the system may recommend Interstellar to User B.
This is the most basic intuition behind collaborative filtering:
What similar users like, you may also like.
Or phrased differently:
Two items frequently liked by the same group of users are likely similar to each other.
II. What Data Does Collaborative Filtering Rely On?
Collaborative filtering does not depend on complex content understanding—it relies on user behavioral data.
Common behaviors include:
| Behavior | Meaning in Recommendation Systems |
|---|---|
| Click | Possible interest, but weak signal |
| View duration | Longer dwell time suggests stronger interest |
| Favorite/Bookmark | Explicit interest |
| Add to cart | Strong purchase intent |
| Purchase | Strong positive feedback |
| Like | Explicit preference |
| Comment | High engagement |
| Share | High interest and endorsement |
| Rating | Most direct preference signal |
These behaviors can be converted into numerical scores.
For example:
| Behavior | Score |
|---|---|
| Click | 1 |
| Favorite/Bookmark | 3 |
| Add to cart | 4 |
| Purchase | 5 |
We can thus construct a user–item rating matrix:
| User | Smartphone | Headphones | Laptop | Camera |
|---|---|---|---|---|
| Zhang San | 5 | 4 | ? | ? |
| Li Si | 5 | ? | 4 | ? |
| Wang Wu | ? | ? | 5 | 4 |
Here ? denotes no observed behavior yet. The recommendation algorithm’s task is to predict these missing entries:
Will Zhang San like laptops?
Will Li Si like cameras?
Will Wang Wu like headphones?
III. Three Common Types of Collaborative Filtering
Collaborative filtering is typically divided into three categories:
- User-Based Collaborative Filtering
- Item-Based Collaborative Filtering
- Matrix Factorization–Based Collaborative Filtering
All three fall under collaborative filtering—but differ in focus.
IV. User-Based Collaborative Filtering: Finding Similar Users
The core idea of user-based collaborative filtering is:
Find users similar to the target user, and recommend items those similar users like.
For example:
| User | Liked Items |
|---|---|
| User A | Item 1, Item 2, Item 3 |
| User B | Item 1, Item 2, Item 3, Item 4 |
The system concludes:
User A and User B are highly similar.
Since User B also likes Item 4, the system may recommend Item 4 to User A.
Implementation Steps
User-based collaborative filtering generally follows these steps:
- Collect user behavioral data.
- Convert behaviors into ratings or preference scores.
- Compute pairwise similarity between users.
- Identify the K most similar users to the target user.
- Select candidate items liked by those similar users but not yet interacted with by the target user.
- Rank candidates by recommendation score and return the top N.
How to Compute Similarity
Common similarity metrics include:
- Cosine Similarity
- Pearson Correlation Coefficient
- Jaccard Similarity
Cosine similarity can be interpreted as:
Treat each user as a vector; the closer their directions, the more similar the users.
In machine learning libraries, cosine similarity is typically defined as the dot product of two vectors divided by the product of their magnitudes. [3]
The formula is:
similarity(A, B) = A · B / (|A| × |B|)
Where:
A · Bis the dot product of vectors A and B.|A|is the magnitude (L2 norm) of vector A.|B|is the magnitude (L2 norm) of vector B.
Advantages
- Intuitive and easy to understand.
- Suitable for scenarios with moderate numbers of users and relatively complete behavioral data.
- Leverages collective experience from “similar user groups.”
Disadvantages
- Computationally expensive when the number of users is very large (quadratic complexity in pairwise comparisons).
- User interests evolve quickly, so similarity relationships may change rapidly.
- Cold-start problem: difficult to recommend for new users with no behavioral history.
V. Item-Based Collaborative Filtering: Finding Similar Items
The core idea of item-based collaborative filtering is:
Instead of finding similar users, find similar items.
If a user likes an item, recommend items similar to it.
For instance, many users commonly purchase together:
Smartphone + Phone case
Smartphone + Charger
Smartphone + Headphones
The system infers:
Phone cases, chargers, headphones, and smartphones exhibit strong co-purchase associations.
Thus, if a user purchases a smartphone, the system can recommend phone cases, chargers, and headphones.
Amazon’s seminal paper introduced Item-to-Item Collaborative Filtering: first build item–item similarity relationships, then generate recommendations based on items the user has already purchased or rated. This method is relatively stable and well-suited for large-scale product catalogs. [2:1]
Implementation Steps
Item-based collaborative filtering generally follows these steps:
- Collect user behavioral data.
- Build item–item co-occurrence relationships.
- Compute item similarity.
- Identify items the user has liked or purchased.
- Retrieve items similar to those.
- Filter out items the user has already viewed, purchased, or otherwise excluded per business rules.
- Rank and recommend.
A Simple Example
Suppose a user likes Item A:
| Similar Item | Similarity to Item A |
|---|---|
| Item B | 0.9 |
| Item C | 0.7 |
| Item D | 0.4 |
The system prioritizes recommending Item B, followed by Item C.
Advantages
- Item similarity tends to be more stable than user similarity.
- Similarity tables can be precomputed offline.
- Online recommendation latency is low.
- Widely adopted in industry during early recommender system development.
Disadvantages
- New items lacking behavioral history are hard to recommend (cold-start problem).
- Poor performance when user behavioral history is sparse.
- Risk of over-specialization—recommending only items extremely similar to previously consumed ones, narrowing the user’s exposure.
VI. Matrix Factorization: Representing Users and Items as Latent Vectors
Matrix factorization is a more advanced class of collaborative filtering methods.
Its goal is:
Represent both users and items as latent feature vectors, and use their inner product to predict user–item interaction scores.
For example, the system may learn latent dimensions such as:
User features:
- Degree of preference for science fiction
- Preference for low-cost items
- Preference for highly rated items
Item features:
- Science-fiction attribute
- Price attribute
- Rating attribute
These latent features are not manually defined—they are learned automatically from user behavioral data.
Assume:
User A = [0.9, 0.2, 0.7]
Movie X = [0.8, 0.1, 0.6]
The predicted score can be simply understood as:
User vector · Item vector = Recommendation score
Matrix factorization is a cornerstone technique in recommendation systems. Koren, Bell, and Volinsky systematically introduced its application in recommender systems—including its pivotal role in the Netflix Prize competition—in their 2009 paper. [4]
Advantages
- Uncovers deeper, non-obvious user interests and item relationships.
- More expressive than simple similarity-based methods.
- Scales well to large recommendation systems.
Disadvantages
- Higher conceptual barrier for beginners.
- Requires model training.
- Needs hyperparameter tuning.
- Sensitive to data quality and volume.
VII. Minimal User-Based CF Code Example
Below is a minimal Python example to illustrate the core logic of collaborative filtering.
import math
data = {
"Zhang San": {"Apple": 5, "Banana": 4, "Watermelon": 1},
"Li Si": {"Apple": 4, "Banana": 5},
"Wang Wu": {"Watermelon": 5, "Grape": 4},
}
def cosine_similarity(user1, user2):
common_items = set(user1.keys()) & set(user2.keys())
if not common_items:
return 0
dot = sum(user1[item] * user2[item] for item in common_items)
norm1 = math.sqrt(sum(score ** 2 for score in user1.values()))
norm2 = math.sqrt(sum(score ** 2 for score in user2.values()))
return dot / (norm1 * norm2)
def recommend(target_user):
scores = {}
for other_user, items in data.items():
if other_user == target_user:
continue
similarity = cosine_similarity(data[target_user], items)
for item, score in items.items():
if item not in data[target_user]:
scores[item] = scores.get(item, 0) + similarity * score
return sorted(scores.items(), key=lambda x: x[1], reverse=True)
print(recommend("Li Si"))
This code’s logic is:
- Compute similarity between “Li Si” and all other users.
- Identify fruits liked by similar users but not yet purchased by Li Si.
- Compute recommendation scores using similarity-weighted ratings.
- Return ranked recommendations.
VIII. How Real-World Recommendation Systems Typically Work
Production systems rarely rely on just one simple algorithm—they decompose the process into multiple stages:
User behavioral data
↓
Construct user–item relationships
↓
Candidate retrieval (recall)
↓
Ranking
↓
Filtering
↓
Display recommendations
1. Collect Behavioral Data
Example:
| user_id | item_id | behavior | weight | time |
|---|---|---|---|---|
| 1001 | 2001 | click | 1 | 2026-06-05 |
| 1001 | 2002 | favorite | 3 | 2026-06-05 |
| 1002 | 2001 | buy | 5 | 2026-06-05 |
2. Behavioral Scoring
Different behaviors indicate varying strengths:
Click: 1
Favorite/Bookmark: 3
Add to cart: 4
Purchase: 5
When incorporating recency, older interactions can be down-weighted:
Recent actions matter more; actions from months ago decay in weight.
3. Candidate Retrieval (Recall)
The recall stage aims not for precision, but to retrieve a broad set of “potentially relevant” candidates.
Example:
User purchased Item A
→ System retrieves similar items: B, C, D, E
4. Ranking
Ranking considers multiple factors:
- Predicted recommendation score
- Item popularity
- User interest alignment
- Recency/freshness
- Inventory status
- Price
- Whether user has already viewed it
5. Filtering
Remove:
- Items already purchased by the user
- Items explicitly disliked by the user
- Out-of-stock items
- Discontinued items
- Items violating business rules
IX. Advantages and Disadvantages of Collaborative Filtering
Advantages
The biggest advantage of collaborative filtering is:
It requires no understanding of item content—only user behavioral data.
It can uncover latent interests users themselves haven’t explicitly articulated.
For example:
Users who like Movie A often also like Movie B.
The system need not understand plot details to make accurate recommendations.
Disadvantages
Collaborative filtering faces several well-known challenges.
1. Cold-Start Problem
- New users lack behavioral history → system cannot infer preferences.
- New items lack interaction history → system cannot determine whom to recommend them to.
Solutions include:
- Asking new users to select interest tags.
- Recommending popular items to new users.
- Leveraging registration information (e.g., age, location).
- Hybridizing with content-based recommendation.
- Providing operational exposure for new items.
2. Data Sparsity Problem
Platforms may host millions of users and items, yet each user interacts with only a tiny fraction.
Example:
Platform hosts 1 million items; a typical user has purchased only 10.
This yields an extremely sparse user–item matrix.
3. Popularity Bias
Popular items receive more clicks, reinforcing their visibility and further increasing their popularity.
This leads to:
The popular get more popular; niche items become increasingly invisible.
4. Limited Explainability
The system can explain recommendations as:
“Because similar users liked it.”
But it struggles to provide pedagogically meaningful explanations like:
“Because this concept addresses your current learning gap.”
X. Applying Collaborative Filtering to Concept and Exercise Recommendation
Applying collaborative filtering to education essentially maps the e-commerce paradigm:
User → Item
to the educational context:
Student → Concept
Student → Exercise
Educational recommendation falls under Technology Enhanced Learning (TEL), a major direction in adaptive learning research. Related work focuses on personalizing recommendations based on learners’ historical behavior, learning goals, available resources, and learning outcomes. [^erdt2015][5]
XI. Key Difference Between Educational and E-Commerce Recommendations
In e-commerce:
Purchase = Like
Bookmark = Interested
Click = Possibly interested
In education:
Getting it wrong ≠ Dislike
Getting it wrong = Likely needs learning support
This is the most critical distinction.
Therefore, educational recommendation is not about recommending “exercises the student likes”—but rather:
- Concepts the student most urgently needs to review
- Exercises at the optimal difficulty level for the student right now
- Related concepts the student commonly confuses
- Content offering the highest learning return upon review
In other words, educational recommendation emphasizes:
- Weakness severity
- Mastery level
- Forgetting risk
- Exercise difficulty
- Concept interdependencies
- Learning pathways
XII. Behavioral Data in Educational Systems
Educational platforms can collect the following behaviors:
| Behavior | Potential Interpretation |
|---|---|
| Attempting an exercise | Student has encountered this exercise |
| Correct answer | Likely mastery achieved |
| Incorrect answer | Potential knowledge gap |
| Repeated incorrect answers | High-risk weakness |
| Viewing solution/explanation | Indicates lack of familiarity |
| Bookmarking an exercise | Student deems it important |
| Reviewing a concept | Signals active learning need |
| Long dwell time | Possible comprehension difficulty |
| Correct answer after repeated practice | Improved mastery |
These behaviors can be converted into learning signals.
For example:
| Behavior | Learning Signal |
|---|---|
| Correct answer | +1 |
| Incorrect answer | -2 |
| Viewing solution | -1 |
| Repeated incorrect answers | -3 |
| Bookmarking a wrong-answer exercise | -1 |
Note: Negative scores here do not represent dislike—they indicate:
“This area likely requires reinforcement.”
XIII. Recommending Concepts
The goal of concept recommendation is to answer:
Which concepts should this student review next?
```For example, the student recently got these questions wrong:
| Question | Related Concept |
|---|---|
| Question 1 | Coronary Artery Disease |
| Question 2 | Angina Pectoris |
| Question 3 | Myocardial Infarction |
The system identifies that many similar students later also tend to get these wrong:
```text
Acute Coronary Syndrome
Nitroglycerin Usage
ECG ST-Segment Changes
Therefore, the system can recommend these concepts.
In educational recommendation systems, learner performance, learning resources, learning activities, and recommendation strategies can be integrated. Some adaptive learning research also incorporates dimensions such as learners’ background information, learning preferences, cognitive level, and learning style into a learner model to support personalized recommendations.[6]
Fourteen: Recommended Questions
The goal of question recommendation is to answer:
Which questions should this student attempt next?
For example, suppose the student’s weak concept is:
Heart Failure Treatment
The system may recommend:
Foundational questions related to heart failure treatment
Commonly-mistaken questions related to heart failure treatment
Advanced questions related to heart failure treatment
However, question recommendation must consider not only relevance but also difficulty.
| Mastery Level | Recommended Question Type |
|---|---|
| 0 – 0.4 | Foundational questions; questions with detailed explanations |
| 0.4 – 0.7 | Standard practice questions |
| 0.7 – 0.9 | Commonly-mistaken or integrated questions |
| Above 0.9 | Minimal review questions—avoid redundant repetition |
Fifteen: How User-Based Collaborative Filtering (CF) Is Used in Learning Recommendations
In educational contexts, User-Based CF can be interpreted as:
Identify students whose learning performance is similar to the current student,
then recommend concepts or questions those students later practiced effectively.
For example:
| Student | Missed Concepts |
|---|---|
| Student A | Concept 1, Concept 2, Concept 3 |
| Student B | Concept 1, Concept 2, Concept 3, Concept 4 |
The system infers that Students A and B share similar knowledge gaps.
If Student B subsequently practices Concept 4 and shows improved accuracy, the system may recommend Concept 4 to Student A.
Suitable Scenarios
- Large number of students.
- Each student has relatively complete question-answering records.
- The system aims to recommend based on “learning pathways of similar students.”
Challenges
- New students have limited behavioral data, making it difficult to identify similar peers.
- Learner proficiency evolves over time; historical similarity does not guarantee ongoing similarity.
- Solely mimicking others’ activity may overlook the current student’s actual learning goals.
Sixteen: How Item-Based Collaborative Filtering (CF) Is Used for Concept and Question Recommendations
In educational contexts, Item-Based CF is often more practical to implement.
It can be interpreted as:
Identify similar questions or similar concepts,
then recommend related content based on the student’s current weaknesses.
For instance, if many students consistently miss:
Question A: Clinical Manifestations of Heart Failure
Question B: Diagnosis of Pulmonary Edema
Question C: Diuretic Use
The system concludes there is an association among these questions.
If a student misses Question A, the system can recommend Questions B and C.
The same applies to concepts:
If many students simultaneously struggle with “Clinical Manifestations of Heart Failure” and “Pulmonary Edema,”
the system infers a strong pedagogical linkage between these two concepts.
Thus, if a student performs poorly on “Clinical Manifestations of Heart Failure,” the system may recommend related content on “Pulmonary Edema.”
Why Item-Based CF Is More Suitable for Early-Stage Educational Systems
Because educational systems typically exhibit several characteristics:
- Question banks are relatively stable.
- Concept hierarchies are comparatively fixed.
- Concepts and questions can be pre-annotated.
- Question-to-question or concept-to-concept similarity can be computed offline.
- Online recommendations only require table lookups based on the student’s current weak points.
Seventeen: End-to-End Implementation Workflow
A simple concept- and question-recommendation system can be designed as follows:
Student question-answering records
↓
Mapping questions to concepts
↓
Computing mastery level per concept
↓
Computing similarity among concepts and among questions
↓
Retrieving candidate questions based on student’s weak concepts
↓
Ranking candidates by difficulty, quality, and mastery level
↓
Returning final recommendations
Eighteen: Step One — Linking Questions to Concepts
Each question should be linked to one or more concepts.
For example:
| question_id | Question | Concepts |
|---|---|---|
| Q001 | Pink frothy sputum in heart failure patients indicates what? | Heart Failure, Pulmonary Edema |
| Q002 | What should be monitored when using diuretics? | Heart Failure Treatment, Diuretics |
| Q003 | What are the manifestations of digoxin toxicity? | Heart Failure Treatment, Digoxin |
This step is critical.
Without concept linking, the system only knows which questions the student got wrong—not which underlying concepts the student struggles with.
Nineteen: Step Two — Recording Student Question-Answering Behavior
The following data can be recorded:
| student_id | question_id | result | duration | reviewed_explanation | time |
|---|---|---|---|---|---|
| S001 | Q001 | wrong | 80 sec | yes | 2026-06-05 |
| S001 | Q002 | right | 35 sec | no | 2026-06-05 |
| S002 | Q001 | wrong | 90 sec | yes | 2026-06-05 |
These data can be further transformed into concept-level mastery estimates.
Twenty: Step Three — Computing Concept Mastery
A simple mastery formula:
Mastery = Number of correct answers / Total attempts
For example:
Zhang San attempted 2 questions on “Heart Failure” and answered 1 correctly.
Mastery = 1 / 2 = 0.5
A weighted version may also be used:
Correct answer = +1
Incorrect answer = −2
Reviewed explanation = −1
Repeated incorrect answer = −3
This makes the model more sensitive to weak concepts.
For greater sophistication, Knowledge Tracing models can estimate the probability of mastery per concept. However, for beginners, simple accuracy and error frequency are sufficient.
Twenty-One: Step Four — Computing Concept Similarity
Concept similarity can be calculated from aggregated student error patterns.
For example:
| Student | Heart Failure | Pulmonary Edema | Hypertension | Diabetes |
|---|---|---|---|---|
| Zhang San | Incorrect | Incorrect | Correct | Correct |
| Li Si | Incorrect | Incorrect | Correct | — |
| Wang Wu | Correct | — | Incorrect | Incorrect |
We observe:
“Heart Failure” and “Pulmonary Edema” are frequently missed together.
Hence, their similarity score is high.
Subsequently, if a student performs poorly on “Heart Failure,” the system may recommend content on “Pulmonary Edema.”
Twenty-Two: Step Five — Retrieving Candidate Questions
Suppose the student’s weak concept is:
Heart Failure
The system retrieves similar concepts:
| Similar Concept | Similarity |
|---|---|
| Pulmonary Edema | 0.9 |
| Diuretics | 0.8 |
| Digoxin | 0.7 |
Then it selects corresponding questions from the question bank:
Question A: Diagnosis of Pulmonary Edema
Question B: Diuretic Use
Question C: Digoxin Toxicity
These become the candidate questions.
Twenty-Three: Step Six — Ranking Recommendations
Candidate questions shouldn’t be presented indiscriminately—they must be ranked.
A simple recommendation score formula:
Recommendation Score = Weakness Degree × Concept Similarity × Question Quality × Difficulty Match
For example:
Recommendation Score = 0.8 × 0.9 × 0.95 × 0.7
Where:
Weakness Degree: Higher score for lower mastery.Concept Similarity: Higher score for stronger conceptual linkage.Question Quality: Prioritize high-quality questions with detailed explanations.Difficulty Match: Higher score for questions well-aligned with the student’s current proficiency.
Twenty-Four: The Simplest Practical Version for Beginners
If you’re building your first system, avoid overly complex models initially.
Start with a minimal viable version:
- Link each question to one or more concepts.
- Record every student response.
- Compute accuracy per concept.
- Identify concepts with the lowest accuracy.
- Recommend unanswered questions associated with those concepts.
- Sort by question difficulty.
This approach isn’t strict collaborative filtering yet—but already solves many real-world problems.
Later, enhance it into collaborative filtering:
Don’t just rely on the current student’s errors—
also analyze shared error patterns across many students.
That is:
Concepts frequently missed collectively indicate pedagogical linkage;
questions frequently missed collectively are suitable for mutual recommendation.
Twenty-Five: Simplified Data Schema for an Educational Recommendation System
Questions Table (questions)
| Field | Description |
|---|---|
| id | Question ID |
| title | Question stem |
| difficulty | Difficulty level |
| quality_score | Question quality score |
Concepts Table (knowledge_points)
| Field | Description |
|---|---|
| id | Concept ID |
| name | Concept name |
| parent_id | Parent concept ID |
Question–Concept Mapping Table (question_knowledge_points)
| Field | Description |
|---|---|
| question_id | Question ID |
| knowledge_point_id | Concept ID |
Student Question Records Table (student_question_records)
| Field | Description |
|---|---|
| student_id | Student ID |
| question_id | Question ID |
| result | Correct/incorrect |
| duration | Time spent answering |
| reviewed_explanation | Whether explanation was viewed |
| created_at | Timestamp of attempt |
Concept Similarity Table (knowledge_point_similarity)
| Field | Description |
|---|---|
| knowledge_point_a | Concept A |
| knowledge_point_b | Concept B |
| similarity | Similarity score |
Twenty-Six: Pseudocode for Recommendation Workflow
def recommend_questions(student_id):
# 1. Compute student's concept mastery
mastery = calculate_mastery(student_id)
# 2. Identify weak concepts
weak_points = find_weak_knowledge_points(mastery)
# 3. Find related concepts based on similarity
related_points = find_related_knowledge_points(weak_points)
# 4. Retrieve candidate questions for weak + related concepts
candidate_questions = find_questions_by_knowledge_points(
weak_points + related_points
)
# 5. Filter out questions already attempted
candidate_questions = filter_done_questions(
student_id,
candidate_questions
)
# 6. Rank by weakness degree, similarity, quality, and difficulty match
ranked_questions = rank_questions(
student_id,
candidate_questions,
mastery
)
return ranked_questions[:10]
Twenty-Seven: Recommendation Strategies in Real Projects
Real-world educational recommendation systems often adopt a layered design:
1. Layer One: Weak Concept Recommendation
First inform the student:
Which concepts should you prioritize reviewing right now?
2. Layer Two: Related Question Recommendation
Then guide them:
Which questions should you attempt for each concept?
3. Layer Three: Difficulty Control
Determine appropriate question types based on current ability:
Foundational questions
Standard practice questions
Commonly-mistaken questions
Integrated questions
4. Layer Four: Spaced Repetition
Leverage forgetting curves to schedule periodic review of previously learned concepts.
5. Layer Five: Learning Pathways
Respect prerequisite relationships among concepts to avoid recommending overly advanced material prematurely.
For example:
Start with foundational concepts
→ Proceed to clinical manifestations
→ Then diagnosis
→ Then treatment
→ Finally integrated case-based questions
Twenty-Eight: Key Considerations When Applying Collaborative Filtering in Education
1. Don’t Equate “Incorrect Answer” With “Dislike”
This is the most common mistake in educational recommendation.
An incorrect answer usually means:
The student needs further instruction.
Not:
The student dislikes or avoids this content.
2. Avoid Overloading With Difficult Questions
If mastery is very low, immediately recommending hard questions harms motivation and learning experience.
A better progression is:
Foundational → Standard → Integrated
3. Don’t Rely Solely on Similarity
Question recommendation must jointly consider:
- Conceptual relevance
- Student’s mastery level
- Question difficulty
- Question quality
- Whether the student has already attempted it
- Whether similar questions were recently practiced
4. Prevent Repetitive Recommendations
If the system repeatedly recommends the same question type, students perceive it as mechanical and tedious.
Mitigation strategies include:
- Excluding recently attempted questions.
- Limiting the number of questions recommended per concept per session.
- Mixing new questions, review questions, and integrated questions.
5. Integrate Pedagogical Rules
Collaborative filtering relies on behavioral data—but education systems must also respect curriculum structure.
For example:
Although a concept is statistically similar to the current error,
it belongs to a higher-difficulty module and may be inappropriate at this stage.
In such cases, curriculum rules should participate in filtering and ranking.
Twenty-Nine: Which Algorithm to Start With?
For beginners or early-stage projects, follow this progression:
- Rule-Based Weak Concept Recommendation
- Item-Based CF for Question Recommendation
- Item-Based CF for Concept Recommendation
- User-Based CF for Learning Pathway Recommendation
- Matrix Factorization or Deep Learning–Based Recommendation
Why?
- Rule-based systems are fastest to deploy.
- Item-Based CF is highly interpretable.
- Question and concept similarities can be precomputed offline.
- Online inference remains fast during user interaction.
- Complex models can be incrementally introduced later.
Thirty: One-Sentence Summary
Collaborative filtering fundamentally means:
Discovering similar users or similar items via collective behavior, then making recommendations accordingly.
Applied to education, it means:
Using large-scale student question-answering behavior to identify
similar students, similar questions, and similar concepts,
then recommending the most needed concepts and best-suited questions to the current student.
For concept and question recommendation, the most practical starting point is:
First compute the student’s weak concepts,
then use Item-Based CF to retrieve related concepts and questions,
and finally rank results considering difficulty, quality, and learning pathway constraints.
This approach is both intuitive and readily implementable in real-world applications.
References
Resnick, P., Iacovou, N., Suchak, M., Bergstrom, P., & Riedl, J. GroupLens: An Open Architecture for Collaborative Filtering of Netnews. CSCW 1994. https://dl.acm.org/doi/10.1145/192844.192905 ↩︎
Linden, G., Smith, B., & York, J. Amazon.com Recommendations: Item-to-Item Collaborative Filtering. IEEE Internet Computing, 2003. https://www.cs.umd.edu/~samir/498/Amazon-Recommendations.pdf ↩︎ ↩︎
scikit-learn documentation,
cosine_similarity. https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.cosine_similarity.html[^erdt2015]: Erdt, M., Fernandez, A., & Rensing, C. Evaluating Recommender Systems for Technology Enhanced Learning: A Quantitative Survey. IEEE Transactions on Learning Technologies, 2015. Resource Conscious Diagnosis and Reconfiguration for NoC Permanent Faults | IEEE Journals & Magazine | IEEE Xplore ↩︎Koren, Y., Bell, R., & Volinsky, C. Matrix Factorization Techniques for Recommender Systems. IEEE Computer, 2009. https://datajobs.com/data-science-repo/Recommender-Systems-[Netflix].pdf ↩︎
Urdaneta-Ponte, M. C., Mendez-Zorrilla, A., & Oleagordia-Ruiz, I. Recommendation Systems for Education: Systematic Review. Electronics, 2021. https://www.mdpi.com/2079-9292/10/14/1611 ↩︎
Zhang, Y. Analysis and Construction of the User Characteristic Model in the Adaptive Learning System for Personalized Learning. Computational Intelligence and Neuroscience, 2022. Analysis and Construction of the User Characteristic Model in the Adaptive Learning System for Personalized Learning - PMC ↩︎