Gorse is an open-source recommendation system written in Go. Gorse aims to be a universal open-source recommender system that can be quickly introduced into a wide variety of online services. By importing items, users, and interaction data into Gorse, the system will automatically train models to generate recommendations for each user. Project features are as follows.
The playground mode has been prepared for beginners. Just set up a recommender system for GitHub repositories by the following commands.
curl -fsSL https://gorse.io/playground | bash
docker run -p 8088:8088 zhenghaoz/gorse-in-one --playground
The playground mode will download data from GitRec and import it into Gorse. The dashboard is available at http://localhost:8088
.
After the "Find neighbors of items" task is completed on the "Tasks" page, try to insert several feedbacks into Gorse. Suppose Bob is a frontend developer who starred several frontend repositories in GitHub. We insert his star feedback to Gorse.
read -d '' JSON << EOF
[
{ \"FeedbackType\": \"star\", \"UserId\": \"bob\", \"ItemId\": \"vuejs:vue\", \"Timestamp\": \"2022-02-24\" },
{ \"FeedbackType\": \"star\", \"UserId\": \"bob\", \"ItemId\": \"d3:d3\", \"Timestamp\": \"2022-02-25\" },
{ \"FeedbackType\": \"star\", \"UserId\": \"bob\", \"ItemId\": \"dogfalo:materialize\", \"Timestamp\": \"2022-02-26\" },
{ \"FeedbackType\": \"star\", \"UserId\": \"bob\", \"ItemId\": \"mozilla:pdf.js\", \"Timestamp\": \"2022-02-27\" },
{ \"FeedbackType\": \"star\", \"UserId\": \"bob\", \"ItemId\": \"moment:moment\", \"Timestamp\": \"2022-02-28\" }
]
EOF
curl -X POST http://127.0.0.1:8088/api/feedback \
-H 'Content-Type: application/json' \
-d "$JSON"
Then, fetch 10 recommended items from Gorse. We can find that frontend-related repositories are recommended for Bob.
curl http://127.0.0.1:8088/api/recommend/bob?n=10
The exact output might be different from the example since the playground dataset changes over time.
For more information:
Gorse is a single-node training and distributed prediction recommender system. Gorse stores data in MySQL, MongoDB, Postgres, or ClickHouse, with intermediate results cached in Redis, MySQL, MongoDB and Postgres.
In addition, the administrator can perform system monitoring, data import and export, and system status checking via the dashboard on the master node.
Any contribution is appreciated: report a bug, give advice or create a pull request. Read CONTRIBUTING.md for more information.
gorse
is inspired by the following projects: