Hackur45 / competitive-programming-stats-collector

πŸ“Š Competitive Programming Profile Tracker Automatically fetches and version-controls your Codeforces and LeetCode profile data using Python and GitHub Actions β€” perfect for building dashboards, tracking progress, and showcasing your CP journey.

Repository from Github https://github.comHackur45/competitive-programming-stats-collectorRepository from Github https://github.comHackur45/competitive-programming-stats-collector

Competitive Programming Profile Data Collector

This repository automates the collection of your competitive programming profile data from Codeforces and LeetCode, storing it in a structured, versioned format within your GitHub repository.


🎯 Purpose of Data Collection

The primary goal of collecting this data is to build a personal data dashboard. This dashboard provides a comprehensive and evolving overview of your competitive programming journey. By centralizing this information, you can:

  • To use as api in my personal portfolio

  • πŸ“ˆ Visualize Progress and Trends
    Track your rating changes, submission patterns, problem-solving distribution across difficulties, and overall performance over time. This helps in identifying strengths and areas for improvement.

  • πŸ“Š Analyze Performance Metrics
    Gain insights into your problem-solving speed, accuracy, and consistency. Understand which types of problems you excel at and where you might need more practice.

  • πŸ† Showcase Achievements
    Create a dynamic portfolio of your competitive programming accomplishments, which can be valuable for personal reflection, sharing with peers, or demonstrating skills to potential employers.

  • πŸ“š Identify Learning Opportunities
    By analyzing your submission history and problem statistics, you can pinpoint specific topics or problem types where you frequently struggle, guiding your future learning efforts.


πŸ“¦ Data Collected

Currently, this repository collects and stores versioned data under the data/ directory:

βœ… Codeforces:

  • data/codeforces/codeforces_info_*.json β€” User Information (Rating, Rank, Max Rating, etc.)
  • data/codeforces/codeforces_submissions_*.json β€” Submission Status (all your submission data)

βœ… LeetCode:

  • data/leetcode/leetcode_info_*.json β€” User Profile Statistics (Total Solved, Ranking, Difficulty-wise Stats, etc.)
  • data/leetcode/leetcode_recent_submissions_*.json β€” Recent Accepted Submissions (latest successful problem attempts)

Each time the script runs, new files are generated with an incremented version number (e.g., _1.json, _2.json, etc.), preserving your full history over time.


βš™οΈ Automation with GitHub Actions

The data collection process is fully automated using GitHub Actions:

  • A workflow runs on a schedule (e.g., every hour or once a day)
  • It executes the update_profile_data.py script
  • Fresh data is fetched from Codeforces and LeetCode
  • Results are saved as versioned JSON files under the appropriate folders
  • Changes are committed and pushed automatically to the repository

πŸš€ Setup Instructions

To set up this automation for your own profile:

  1. ⭐ Fork this repository
    Click "Fork" on the top right of this repo to copy it to your GitHub account.

  2. πŸ›  Update update_profile_data.py:
    Edit this section with your handles:

    CODEFORCES_HANDLE = "your_codeforces_handle"
    LEETCODE_USERNAME = "your_leetcode_username"

About

πŸ“Š Competitive Programming Profile Tracker Automatically fetches and version-controls your Codeforces and LeetCode profile data using Python and GitHub Actions β€” perfect for building dashboards, tracking progress, and showcasing your CP journey.


Languages

Language:Python 100.0%