Skip to content

Commit

Permalink
feat: change openrank value function to sigmod
Browse files Browse the repository at this point in the history
Signed-off-by: frank-zsy <[email protected]>
  • Loading branch information
frank-zsy committed Oct 22, 2024
1 parent d217378 commit 620c33f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cron/tasks/global_openrank.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const task: Task = {
const backgroundRententionFactor = 0.15;
const openrankAttenuationFactor = 0.85;
const openrankMinValue = 1;
const acitivityToOpenrank = activity => Math.min(1, activity / 88.17); // 75% quantile of monthly activity
const acitivityToOpenrank = activity => 1 / (1 + Math.exp(0.10425 * (-activity + 44.08)));

const createTable = async () => {
const sql = `CREATE TABLE IF NOT EXISTS ${globalOpenrankTableName}
Expand Down

0 comments on commit 620c33f

Please sign in to comment.