Skip to content

Improve spam detection with profile photo check & account age #2

Description

@SaharPak

Context

Current spam detection in spam_checker.py uses basic heuristics (username presence, name length, bio patterns). We can improve accuracy with more signals.

Requirements

  • Use bot.get_user_profile_photos(user_id) to check if user has a profile photo
  • Check account age if available (newer accounts = higher risk)
  • Add configurable weight system for each signal
  • Track false positive/negative rate in DB (Phase 1 DB issue dependency)

Signals to add

  • No profile photo: +0.15 spam score
  • Account created < 7 days ago: +0.25
  • Username matches common spam patterns (e.g., user12345678): +0.2
  • Name contains emojis/special chars excessively: +0.1

Acceptance Criteria

  • Profile photo check integrated
  • Spam scoring is configurable via config
  • Unit tests for each signal

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestphase-1Phase 1: Join approval & moderation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions