Repository Analysis

HabitRPG/habitica

A habit tracker app which treats your goals like a Role Playing Game.

14.4 Low AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of HabitRPG/habitica, a JavaScript project with 14,033 GitHub stars. SynthScan v2.0 examined 538,298 lines of code across 2742 source files, recording 811 pattern matches distributed across 6 syntactic categories. The overall adjusted score of 14.4 places this repository in the Low AI signal band.

The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).

14.4
Adjusted Score
14.4
Raw Score
100%
Time Factor
2026-07-30
Last Push
14.0K
Stars
JavaScript
Language
538.3K
Lines of Code
2.7K
Files
811
Pattern Hits
2026-08-02
Scan Date
0.26
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

Longitudinal tracking requires multiple scan runs. Once this repository is re-scanned after new commits land, this chart will visualise how the synthetic code signal evolves over time — enabling you to detect whether AI authorship is growing, stabilising, or being actively corrected by human engineers.

No multi-scan history yet — run the scanner again to build trend data.

Severity Breakdown

Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.

CRITICAL 717HIGH 0MEDIUM 1LOW 93

Directory Score Breakdown

This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.

Pattern Findings

The scanner identified 811 distinct pattern matches across 6 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.

Hallucination Indicators717 hits · 7675 pts
SeverityFileLineSnippetContext
CRITICALtest/api/unit/models/group.test.js687 await expect(Group.validateInvitations({}, res)).to.eventually.be.rejected.and.eql({CODE
CRITICALtest/api/unit/models/group.test.js697 await expect(Group.validateInvitations({ uuids: 'user-id' }, res)).to.eventually.be.rejected.and.eql({CODE
CRITICALtest/api/unit/models/group.test.js707 await expect(Group.validateInvitations({ emails: 'user@example.com' }, res)).to.eventually.be.rejected.and.eql({CODE
CRITICALtest/api/unit/models/group.test.js718 .to.eventually.be.rejected.and.eql({CODE
CRITICALtest/api/unit/models/group.test.js729 .to.eventually.be.rejected.and.eql({CODE
CRITICALtest/api/unit/models/group.test.js740 .to.eventually.be.rejected.and.eql({CODE
CRITICALtest/api/unit/models/group.test.js761 .to.eventually.be.rejected.and.eql({CODE
CRITICALtest/api/unit/models/group.test.js1232 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/models/group.test.js1248 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js63 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js79 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js93 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js201 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js213 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js284 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js297 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js374 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/google.test.js402 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js73 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js85 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js95 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js115 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js269 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js292 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js501 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js525 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js551 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js591 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js640 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js655 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/apple.test.js668 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/cancel.test.js104 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/cancel.test.js139 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/cancel.test.js150 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/subscribe.test.js129 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/subscribe.test.js144 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/subscribe.test.js162 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/subscribe.test.js188 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/checkout.test.js152 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/checkout.test.js164 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/amazon/checkout.test.js176 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…api/unit/libs/payments/paypal/subscribe-cancel.test.js66 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…api/unit/libs/payments/paypal/subscribe-cancel.test.js75 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…api/unit/libs/payments/paypal/subscribe-cancel.test.js86 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/paypal/subscribe.test.js35 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/paypal/subscribe.test.js54 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/paypal/checkout.test.js80 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/paypal/checkout.test.js92 .to.eventually.be.rejected.and.to.eql({CODE
CRITICALtest/api/unit/libs/payments/paypal/checkout.test.js103 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…ibs/payments/group-plans/group-payments-create.test.js133 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…ibs/payments/group-plans/group-payments-cancel.test.js153 .eventually.be.rejected.and.to.eql({CODE
CRITICAL…/api/unit/libs/payments/stripe/oneTimePayments.test.js34 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…/api/unit/libs/payments/stripe/oneTimePayments.test.js44 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…/api/unit/libs/payments/stripe/oneTimePayments.test.js63 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…/api/unit/libs/payments/stripe/oneTimePayments.test.js84 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…/api/unit/libs/payments/stripe/oneTimePayments.test.js103 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…/api/unit/libs/payments/stripe/oneTimePayments.test.js197 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…/api/unit/libs/payments/stripe/oneTimePayments.test.js209 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…/api/unit/libs/payments/stripe/oneTimePayments.test.js229 .to.eventually.be.rejected.and.to.eql({CODE
CRITICAL…st/api/unit/libs/payments/stripe/subscriptions.test.js31 .to.eventually.be.rejected.and.to.eql({CODE
657 more matches not shown…
Hyper-Verbose Identifiers76 hits · 78 pts
SeverityFileLineSnippetContext
LOWtest/api/unit/middlewares/blocker.test.js12function checkIPBlockedErrorThrown (next) {CODE
LOWtest/api/unit/middlewares/blocker.test.js19function checkClientBlockedErrorThrown (next) {CODE
LOWtest/api/unit/libs/payments/paymentHelpers.js3export async function createNonLeaderGroupMember (group) { // eslint-disable-line import/prefer-default-export, max-lenCODE
LOWtest/api/unit/libs/payments/amazon/cancel.test.js29 function expectAmazonCancelSubscriptionSpy (groupId, lastBillingDate) {CODE
LOWtest/api/unit/libs/payments/amazon/cancel.test.js40 function expectAmazonCancelUserSubscriptionSpy () {CODE
LOWtest/api/unit/libs/payments/amazon/cancel.test.js45 function expectAmazonCancelGroupSubscriptionSpy (groupId) {CODE
LOWtest/api/unit/libs/payments/amazon/cancel.test.js50 function expectBillingAggreementDetailSpy () {CODE
LOWtest/api/unit/libs/payments/amazon/subscribe.test.js74 function expectAmazonAuthorizeBillingAgreementSpy () {CODE
LOWtest/api/unit/libs/payments/amazon/subscribe.test.js94 function expectAmazonSetBillingAgreementDetailsSpy () {CODE
LOW…ration/quests/POST-groups_groupid_quests_leave.test.js92 async function letPartyMemberLeaveAndCheckChanges (partyMember) {CODE
LOWtest/helpers/content.helper.js10export function expectValidTranslationString (attribute, contextKey) {CODE
LOWwebsite/server/middlewares/auth.js162 return function chatPrivilegesRequiredHandler (req, res, next) {CODE
LOWwebsite/server/middlewares/domain.js5export default function implementDomainMiddleware (server, mongoose) {CODE
LOWwebsite/server/models/pushDevice.js29schema.statics.cleanupCorruptData = function cleanupCorruptPushDevicesData (pushDevices) {CODE
LOWwebsite/server/models/newsPost.js81function getAndUpdateLastNewsPost () {CODE
LOWwebsite/server/models/task.js250TaskSchema.statics.sanitizeUserChallengeTask = function sanitizeUserChallengeTask (taskObj) {CODE
LOWwebsite/server/models/userNotification.js127schema.statics.cleanupCorruptData = function cleanupCorruptNotificationsData (notifications) {CODE
LOWwebsite/server/models/group.js511schema.methods.getParticipatingQuestMembers = function getParticipatingQuestMembers () {CODE
LOWwebsite/server/models/group.js863schema.methods.sendGroupChatReceivedWebhooks = function sendGroupChatReceivedWebhooks (chat) {CODE
LOWwebsite/server/models/user/methods.js93schema.methods.getObjectionsToInteraction = function getObjectionsToInteraction (interaction, receiver) { // eslint-disaCODE
LOWwebsite/server/models/user/methods.js316schema.statics.addComputedStatsToJSONObj = function addComputedStatsToUserJSONObj (CODE
LOWwebsite/server/libs/mongodb.js14export function getDevelopmentConnectionUrl (originalConnectionUrl) {CODE
LOWwebsite/server/libs/mongodb.js25export function getDefaultConnectionOptions () {CODE
LOWwebsite/server/libs/stringUtils.js5export function removePunctuationFromString (str) {CODE
LOWwebsite/server/libs/cron.js58function removeTerminatedSubscription (user) {CODE
LOWwebsite/server/libs/password.js70export async function validatePasswordResetCodeAndFindUser (code) {CODE
LOWwebsite/server/libs/slack.js115function sendInboxFlagNotification ({CODE
LOWwebsite/server/libs/slack.js179function sendChallengeFlagNotification ({CODE
LOWwebsite/server/libs/slack.js214function sendProfileFlagNotification ({CODE
LOWwebsite/server/libs/slack.js251function sendSubscriptionNotification ({CODE
LOWwebsite/server/libs/slack.js283function sendShadowMutedPostNotification ({CODE
LOWwebsite/server/libs/slack.js328function sendProfileSlurNotification ({CODE
LOWwebsite/server/libs/slack.js361function sendChallengeSlurNotification ({CODE
LOWwebsite/server/libs/content.js82export function getLocalizedContentResponse (langCode, removedKeys = {}) {CODE
LOWwebsite/server/libs/chat.js5export async function getAuthorEmailFromMessage (message) {CODE
LOWwebsite/server/libs/chat.js20export async function sendChatPushNotifications (user, group, message, mentions, translate) {CODE
LOWwebsite/server/libs/language.js17function checkForApplicableLanguageVariant (originalLanguageOptions) {CODE
LOWwebsite/server/libs/email.js165export function convertVariableObjectToArray (variableObject) {CODE
LOWwebsite/server/libs/payments/subscriptions.js71async function prepareSubscriptionValues (data) {CODE
LOWwebsite/server/libs/payments/paypal.js226api.getSubscriptionPaymentDetails = async function getSubscriptionPaymentDetails (options = {}) {CODE
LOW…/libs/payments/calculateSubscriptionTerminationDate.js6export default function calculateSubscriptionTerminationDate (CODE
LOWwebsite/server/libs/payments/groupPayments.js36async function addSubscriptionToGroupUsers (group) {CODE
LOWwebsite/server/libs/payments/groupPayments.js207async function cancelGroupUsersSubscription (group) {CODE
LOWwebsite/server/libs/payments/groupPayments.js221async function cancelGroupSubscriptionForUser (user, group, userWasRemoved = false) {CODE
LOWwebsite/server/libs/payments/amazon.js81api.authorizeOnBillingAgreement = function authorizeOnBillingAgreement (inputSet) {CODE
LOWwebsite/server/libs/payments/amazon.js367api.chargeForAdditionalGroupMember = async function chargeForAdditionalGroupMember (group) {CODE
LOWwebsite/server/libs/payments/stripe/subscriptions.js36export async function getSubscriptionPaymentDetails (user) {CODE
LOWwebsite/server/libs/payments/stripe/subscriptions.js81export async function handlePaymentMethodChange (session, stripeInc) {CODE
LOWwebsite/server/libs/payments/stripe/subscriptions.js99export async function chargeForAdditionalGroupMember (group, stripeInc) {CODE
LOWwebsite/server/libs/payments/stripe/checkout.js129export async function createEditCardCheckoutSession (options, stripeInc) {CODE
LOWwebsite/server/libs/tasks/index.js319function groupSubscriptionNotFound (group) {CODE
LOWwebsite/server/libs/inbox/index.js123export async function getInboxMessagesByUniqueId (uniqueMessageId) {CODE
LOW…server/libs/challenges/handleGetMembersForChallenge.js12async function getMembersTasksForChallenge (members, challenge) {CODE
LOW…server/libs/challenges/handleGetMembersForChallenge.js24export async function handleGetMembersForChallenge (req, res) {CODE
LOWwebsite/server/libs/challenges/index.js21export function addUserJoinChallengeNotification (user) {CODE
LOWwebsite/server/libs/challenges/index.js27export function getChallengeGroupResponse (group) {CODE
LOWwebsite/server/libs/user/validation.js36function usernameContainsInvalidCharacters (username) {CODE
LOWwebsite/server/libs/invites/index.js20async function sendInvitePushNotification (userToInvite, groupLabel, group, publicGuild, res) {CODE
LOWwebsite/server/controllers/api-v3/quests.js27function canStartQuestAutomatically (group) {CODE
LOWwebsite/common/script/content/hatching-potions.js9function hasQuestAchievementFunction (key) {CODE
16 more matches not shown…
Over-Commented Block11 hits · 11 pts
SeverityFileLineSnippetContext
LOWtest/helpers/api-integration/v4/object-generators.js101COMMENT
LOWtest/helpers/api-integration/v3/object-generators.js101 'x-client': 'habitica-web',COMMENT
LOWwebsite/server/models/user/methods.js421 if (daysMissedOldZone > 0 && daysMissedNewZone > 0) {COMMENT
LOWwebsite/server/models/user/methods.js441 // you reinterpret that time in the new timezone, it looks like itCOMMENT
LOWwebsite/server/libs/bannedWords.js1/* eslint-disable no-multiple-empty-lines */COMMENT
LOWwebsite/server/libs/bannedWords.js61// Legitimate place names: 'Dyke'COMMENT
LOWwebsite/server/libs/bannedSlurs.js1/* eslint-disable no-multiple-empty-lines */COMMENT
LOWwebsite/server/libs/payments/paypal.js41});COMMENT
LOWwebsite/server/libs/payments/stripe/constants.js1export default {COMMENT
LOWwebsite/client/src/components/hall/heroes.vue381 // let questsFormat = this.getFormattedItemReferenceCOMMENT
LOWwebsite/client/src/components/hall/heroes.vue401 // .{head/headAccessory/eyewear/armor/body/back/shield/weapon}.{gearKey}\n';COMMENT
Fake / Example Data5 hits · 6 pts
SeverityFileLineSnippetContext
LOWtest/api/unit/models/group.test.js707 await expect(Group.validateInvitations({ emails: 'user@example.com' }, res)).to.eventually.be.rejected.and.eql({CODE
LOWwebsite/client/src/components/ui/validatedTextInput.vue35 :placeholder="placeholder"CODE
LOW…ponents/tasks/modal-controls/selectTranslatedArray.vue12 :placeholder="placeholder"CODE
LOWwebsite/client/src/components/groups/chat.vue22 :placeholder="placeholder"CODE
LOWwebsite/client/src/components/groups/chat.vue119 props: ['label', 'group', 'placeholder'],CODE
AI Slop Vocabulary1 hit · 2 pts
SeverityFileLineSnippetContext
MEDIUMwebsite/common/locales/pt_BR/faq.json5 "webFaqStillNeedHelp": "Se você tiver alguma dúvida que não esteja listada aqui ou na [FAQ da Wiki](https://habiticaCODE
Verbosity Indicators1 hit · 2 pts
SeverityFileLineSnippetContext
LOWwebsite/server/libs/email.js95 // as we need to check if he unsubscribedCOMMENT