An article-based social platform for creative writers and inquisitive readers.
Webiste URL: https://headache.services
-
Test Account
- Email:
author_0@ReaderLand.com
- Password:
password
To simulate real user experience, crontab scheduler executes the PseudoWorker.js to mimic other user interaction with the test account every minute. User will be notified of these action by the notification on the header.
- Email:
Table of Conetents
Browse through the articles derived from the personalized newsfeed algorithm.
Readers can leisurely skim through aritcles newsfeeds displayed by time-series, categories, or customized newsfeed. Board on the left side lists subscritions and weights of the categories for the articles, user can adjust it in their own profile page.
In each article card, user can scan the summary of the article. Click the title to enjoy whole article, or save it to your favorite list by clicking book mark icon on the top-right corner. Hover on the author's avatar to see author's brief introduction. Click the avatar to see the author's page and start to follow him by hit the follow button.
More Article cards will be rendered at the bottom when scrolling down the page, or reload the newsfeed by clicking refresh button on the right side of each tab.
Enjoy the beauty of knowledge and take part in a real-time discussion with author and other readers.
In addition to just reading article, readers can hit the like button, save it to their favorite list, share the article with the link copy button, and participate in real-time discussion on the comment board with author and other readers.
Author will receive notification when readers like the article or leave a comment, and readers will be notified if the author replies their comments as well.
A User-friendly editing interface featured auto-saving and intuitive operation.
ReaderLand provides a concise interface and fluent user experice that help writer concentrate on the content production.
When editing, writers can output their ideas efficiently and effortlessly without moving their hand away from the keyboard: you can move the cusor among paragraphs with page-up and page-down keys, insert new paragraph right below the current one with enter, and remove the paragrapg with backspace if it's empty.
Linked-list structured paragraphs allows accurate auto-saving for every updated contents, users can reload the draft and resume their works without the concern of losing progress.
Adjust subscription of categories and weights to design the algorithm best matching your preference.
In profile page, users can:
- Edit their avatar, username and introduction.
- Manage favorited articles, draft and published articles.
- Check the followrs and fans.
- Adjust categories and weight they subscribed.
ReaderLand features user-defined newsfeed algorithm, which release readers from the black box algorithm tyranny. In subscription tab, readers can subscribe cateogories interest them and adjust the weight of each category. Server will then filter and sort articles by the subscription and author they follow, generating their personalized newsfeed contents on the index page.
To see detailed explanations on the newsfeed algorithm, please check EdgeRank-like Weight Algorithm section below.
After submitting the sign up form, user's will reveive an validation mail titled "ReaderLand 信箱驗證". Click the link in the mail context to finish the registration validation, then start your journey of knowledge in the ReaderLand!
Please note that the unvalidated account will be remove 10 minutes after registration, and user can't register with email already validated in ReaderLand.
Note: In the developemnt environemnt, crontab refreshes the database twice a day to keep the data size and articles status, so the registered account would be flushed as well every 12 hours.
In newsfeed generation, the server will filter articles written by the user's followers or categories matching one of user's subscription, then sort articles by a preference weight derived from this EdgeRank-like weight algorithm and store it in Redis.
The algorithm is composed of 3 parameters:
-
Preference Weight = ( 1 + SUM_OF_CAT_WEIGHT ) * ( FOLLOWER_WEIGHT )
Every article will start with a base weight of 1, then add the category weight derived from the user's subscription to it, and finally, multiply the total weight by follower weight if the article was written by one of the user's followers.
For instance, if one article is categorized as "投資理財" and "職場產業" while the reader subscribes "投資理財" with the weight of 5, the preference weight of the article is 1 + 5 = 6;
If author of the article is also followed by the user, multiply the number by FOLLOWER_WEIGHT ( 3 in current environment ) to get the final preference weight.
FOLLOWER_WIGHT is editable in
.env
.
-
Popularity Weight =
READ_WEIGHT(READ_COUNT / READ_DIV) * LIKE_WEIGHT(LIKE_COUNT / LIKE_DIV) * COMMENT_WEIGHT(COMMENT_COUNT / COMMENT_DIV)
Popularity weight is the product of 3 feedback weights (views, likes, and comments) each derived from their original weight to the power of count/divisor.
Original weights and count divisor for each kind of feedback can be adjusted in
.env
.
-
Time Decayer
Briefly speaking, the time decay parameter raises the importance of the freshness of the articles: the more fresh the article was, the less time decayer value would be, and hence the greater the final weight article would get.
To see detailed calculation of time decayer, check
timeDecayer
function in util.js.
To update the newsfeed with articles posted after generation, instead of regenerating it, ReaderLand implements Push-Pull model scheduled by crontab to insert new articles into newsfeeds.
When an author publish a new article, server will retrieve the fans' id of the author and "Push" the article to their newsfeed array randomly.
Every 15 minutes, pullWorker.js will "Pull" the articles that meet the user's subscription (but not written by their followers) and was published after the newsfeed was generated, then sort the articls by newsfeed algorithm.
Finally, the worker will insert these articles into the newsfeed array. Currently the ReaderLand adopts a completely random-distributed strategy for insertion, but website maitainer can switch to a more even-distributed strategy by changing the strategy code in .env
.
{
_id: ObjectId,
role: Number,
valid: Boolean,
email: String,
password: String,
picture: String,
provider: String,
follower: [ ObjectId ],
followee: [ ObjectId ],
subscribe: {
"Category": Number
},
bio: String,
favorite: [{ articleId: ObjectId, createdAt: ISOString }]
}
{
_id: ObjectId,
category: String,
}
{
_id: ObjectId,
title: String,
context: {
"ISOString": {
content: String,
type: String,
nexr: ISOString
}
},
preview: String,
createdAt: ISOString,
readCount: Number,
likes: [ ObjectId ],
comments: [ {
_id: ObjectID,
context: String,
createdAt: ISOString,
reader: ObjectId,
authorReply: {
context: String,
createdAt: ISOString
}
} ],
category: [ String ],
head: ISOString
}
{
_id: ObjectId,
title: String,
author: ObjectId,
context: {
"ISOString": {
type: String,
content: String,
next: ISOString
}
},
head: ISOString,
createdAt: ISOString,
lastUpdatedAt: ISOString
}
{
_id: ObjectId,
unread: Number,
notifications: [ {
type: String,
createdAt: ISOString,
subject: ObjectId,
articleId: ObjectId,
commentId: ObjectId,
isread: Boolean
} ]
}