Skip to content

Instantly share code, notes, and snippets.

View Dmoment's full-sized avatar
🏠
Working from home

Deepak Chauhan Dmoment

🏠
Working from home
View GitHub Profile
# cspell:Disable
require:
- rubocop-rails
AllCops:
TargetRubyVersion: 3.2.2
DisabledByDefault: true
NewCops: enable
Exclude:
- "app/javascript/**/*"
@Dmoment
Dmoment / gist:e123cc5abc81712ac831ea4ee5e43353
Created February 1, 2024 19:59
Explore how binary trees enhance personalized course recommendations! Discover our innovative approach of converting intricate keyword expressions into results and envision a future where machine learning minimizes manual input. Join us to transform the personalized learning experience!
Tailoring course recommendations for users is an integral part of today’s personalized learning experience. However, this process can be challenging due to its inherent complexity. In this talk, I will share my experience of transforming a complex recommendation engine into a manageable and efficient process by leveraging binary trees.
The system I will be discussing involves translating expressions like (“Controlled Substances” AND “Prescribing”) OR (“Controlled Substances” AND “Substance Use Disorder”) OR (“Controlled Substances” AND “Prescribing” AND “Pain Management”) OR (“Opioids” AND “Prescribing” AND “Pain Management”) into a binary tree. Here, the ‘AND’ and ‘OR’ operators, along with keywords like “Controlled Substances”, “Prescribing”, etc., were represented as nodes in our binary tree structure.
The first step of this process was to construct the binary tree where the leaf nodes contained operands and the nodes held operators. The expressions inside the brackets were given the highest priority, an