Skip to content

Commit

Permalink
ランキングを調整
Browse files Browse the repository at this point in the history
  • Loading branch information
eatski committed Apr 9, 2024
1 parent a3a7de7 commit 8553235
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/server/services/story/ranking/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,12 @@ export const getStoriesRecommended = async (
(story.publishedAt ? now - story.publishedAt.getTime() : 0) + ONE_DAY;

const score =
((Math.pow(correctSolutionsLength, 1.3) + 1) *
Math.pow(Math.abs(total + 3) + 1, 0.7) *
(Math.pow(questionLogsLength, 0.5) + 100) *
((Math.pow(correctSolutionsLength, 0.5) + 1) *
Math.pow(Math.max(total, 0) + 1, 0.8) *
(Math.pow(questionLogsLength, 0.5) + 1) *
Math.pow(questionExamplesLength + 1, 0.3) *
Math.pow(Math.random(), 2)) /
Math.pow(timeFromPublished, 0.8);
Math.pow(timeFromPublished, 0.5);

return {
story: omitted,
Expand Down

0 comments on commit 8553235

Please sign in to comment.