Git Product home page Git Product logo

fitfriend's Introduction

FitFriend

Fitness Telegram bot

FitFriend Telegram BotFitFriend is a Telegram bot that acts as a personal fitness coach. It provides personalized workout plans, tracks progress, and offers motivation and support to users. The bot uses the latest OpenAI models (GPT-3.5 Turbo and DALL-E 3) for generating workout instructions and images.FeaturesUser Profiling: Collects user information (fitness goals, current fitness level, age, gender) to create personalized profiles.Workout Planning: Generates customized workout plans based on user profiles and selected workout frequency (daily, weekly, monthly).Progress Tracking: Tracks user progress and provides feedback.Motivation: Offers motivational quotes and advice to keep users engaged.Image Generation: Uses DALL-E 3 to generate images illustrating workout exercises.PrerequisitesPython 3.6+A Telegram bot token from BotFatherOpenAI API keyInstallationClone the repository:git clone https://github.com/whiteraven/fitfriend-bot.git cd fitfriend-bot Install the dependencies:pip install -r requirements.txt Set up the database:import sqlite3

conn = sqlite3.connect('fitfriend.db') cursor = conn.cursor()

cursor.execute(''' CREATE TABLE IF NOT EXISTS user_profiles ( user_id INTEGER PRIMARY KEY, goal TEXT, fitness_level TEXT, age INTEGER, gender TEXT ) ''')

cursor.execute(''' CREATE TABLE IF NOT EXISTS user_progress ( user_id INTEGER, progress TEXT, FOREIGN KEY (user_id) REFERENCES user_profiles (user_id) ) ''')

conn.commit() conn.close() Update the script with your API keys:Replace YOUR_TELEGRAM_API_TOKEN with your Telegram bot token.Replace YOUR_OPENAI_API_KEY with your OpenAI API key.Run the bot:python bot.py UsageStart the bot: Use the /start command in your Telegram bot to initialize the interaction.Set Profile: Follow the prompts to provide your fitness goal, current fitness level, age, and gender.Start Workout: Choose your workout frequency (daily, weekly, monthly) to receive a personalized workout plan.Track Progress: Check your progress anytime using the "Track Progress" option.Get Motivation: Get motivational quotes and advice to keep you going.Filesbot.py: Main script for the FitFriend bot.requirements.txt: List of dependencies.README.md: This README file.ContributingFeel free to fork this repository and submit pull requests. For major changes, please open an issue first to discuss what you would like to change.LicenseThis project is licensed under

fitfriend's People

Contributors

whiterven avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.