Social Media Chat Bot Marvin
Undergraduate dissertation: An AI-powered Telegram chatbot providing real-time social media marketing insights and analytics.
AI/MLDissertation
# features
Key Features
Core technologies and system features.
Interactive Chatbot
Telegram-based bot for querying social media marketing insights.
Data Analytics
Integration with Pandas for processing and analyzing large marketing datasets.
AI/ML Integration
Leverages AI to interpret trends and offer automated marketing recommendations.
# source
Project Source Code
Explore the primary logical modules.
EXPLORER
srctelegram_bot.py
1import pandas as pd2from telegram import Update3from telegram.ext import Application, CommandHandler, ContextTypes45# Load social media dataset6df = pd.read_csv('marketing_data.csv')78async def start(update: Update, context: ContextTypes.DEFAULT_TYPE):9 """Send a message when the command /start is issued."""10 await update.message.reply_text('Hello! I am Marvin, your Social Media Chat Bot.')1112async def get_insights(update: Update, context: ContextTypes.DEFAULT_TYPE):13 """Analyze and return marketing insights."""14 top_campaign = df.loc[df['engagement_rate'].idxmax()]15 response = f"Top Campaign: {top_campaign['name']}\nEngagement Rate: {top_campaign['engagement_rate']}%"16 await update.message.reply_text(response)1718def main():19 application = Application.builder().token("YOUR_TOKEN").build()20 application.add_handler(CommandHandler("start", start))21 application.add_handler(CommandHandler("insights", get_insights))22 application.run_polling()2324if __name__ == '__main__':25 main()# simulation
Live Simulation Output
Simulated console execution.
simulation
$_▋
# repositories
Source Code
GitHub repositories for this project.