help@rskworld.in +91 93305 39277
RSK World
  • Home
  • Development
    • Web Development
    • Mobile Apps
    • Software
    • Games
    • Project
  • Technologies
    • Data Science
    • AI Development
    • Cloud Development
    • Blockchain
    • Cyber Security
    • Dev Tools
    • Testing Tools
  • Blog
  • About
  • Contact

Theme Settings

Color Scheme
Display Options
Font Size
100%
Back to Project
RSK World
weather-chatbot
RSK World
weather-chatbot
Weather Chatbot - Python + Flask + OpenWeatherMap + OpenAI + Weather Forecast + Weather Alerts + Natural Language Processing
weather-chatbot
  • __pycache__
  • cache
  • logs
  • scripts
  • sessions
  • static
  • templates
  • tests
  • utils
  • .dockerignore778 B
  • .env.example1.5 KB
  • .gitignore2.4 KB
  • .pre-commit-config.yaml1 KB
  • API.md7.9 KB
  • CHANGELOG.md2.4 KB
  • CHECKLIST.md5.4 KB
  • CONTRIBUTING.md1.9 KB
  • Dockerfile1.4 KB
  • FEATURES.md7.1 KB
  • FINAL_CHECK.md6.7 KB
  • GITHUB_RELEASE_INSTRUCTIONS.md5.4 KB
  • INSTALL.md4 KB
  • LICENSE1.3 KB
  • MANIFEST.in553 B
  • Makefile2 KB
  • PROJECT_SUMMARY.md12.9 KB
  • README.md7.2 KB
  • RELEASE_NOTES_v1.0.0.md8.9 KB
  • VERIFICATION_REPORT.md9.2 KB
  • app.py22.2 KB
  • chatbot.py1.7 KB
  • config.py4.9 KB
  • docker-compose.yml2.2 KB
  • nginx.conf2.3 KB
  • pytest.ini549 B
  • requirements.txt1.9 KB
  • run.py3.1 KB
  • setup.py3.1 KB
  • weather_api.py578 B
LICENSEindex.htmlrequirements.txt
LICENSE
Raw Download
Find: Go to:
MIT License

Copyright (c) 2026 RSK World

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

---

Author: RSK World (https://rskworld.in)
Founded by: Molla Samser
Designer & Tester: Rima Khatun
Contact: +91 93305 39277, hello@rskworld.in, support@rskworld.in
Location: Nutanhat, Mongolkote, Purba Burdwan, West Bengal, India, 713147
Year: 2026
31 lines•1.3 KB
text
templates/index.html
Raw Download
Find: Go to:
<!DOCTYPE html>
<html lang="en">
<head>
    <!--
    Weather Chatbot - Web Interface
    =================================
    
    Author: RSK World (https://rskworld.in)
    Founded by: Molla Samser
    Designer & Tester: Rima Khatun
    Contact: +91 93305 39277, hello@rskworld.in, support@rskworld.in
    Location: Nutanhat, Mongolkote, Purba Burdwan, West Bengal, India, 713147
    Year: 2026
    
    Description: Web interface for the Weather Chatbot application
    providing forecasts, alerts, and weather information.
    -->
    
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="Weather Chatbot - Get real-time weather forecasts, alerts, and weather information using natural language">
    <meta name="keywords" content="weather, chatbot, forecast, alerts, temperature, rain, storm, climate">
    <meta name="author" content="RSK World">
    
    <title>Weather Chatbot - RSK World</title>
    
    <!-- Bootstrap CSS -->
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet">
    <!-- Font Awesome -->
    <link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css" rel="stylesheet">
    <!-- Custom CSS -->
    <style>
        :root {
            --primary-color: #007bff;
            --secondary-color: #6c757d;
            --success-color: #28a745;
            --danger-color: #dc3545;
            --warning-color: #ffc107;
            --info-color: #17a2b8;
            --light-color: #f8f9fa;
            --dark-color: #343a40;
            --gradient-bg: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        }

        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background: var(--gradient-bg);
            min-height: 100vh;
            margin: 0;
            padding: 0;
        }

        .main-container {
            min-height: 100vh;
            display: flex;
            flex-direction: column;
        }

        .header {
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(10px);
            box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
            padding: 1rem 0;
        }

        .logo {
            font-size: 1.8rem;
            font-weight: bold;
            color: var(--primary-color);
            text-decoration: none;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .chat-container {
            flex: 1;
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 2rem;
        }

        .chat-card {
            background: white;
            border-radius: 20px;
            box-shadow: var(--card-shadow);
            width: 100%;
            max-width: 800px;
            height: 600px;
            display: flex;
            flex-direction: column;
            overflow: hidden;
        }

        .chat-header {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 1.5rem;
            text-align: center;
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        }

        .chat-messages {
            flex: 1;
            overflow-y: auto;
            padding: 1.5rem;
            background: #f8f9fa;
            display: flex;
            flex-direction: column;
            gap: 1rem;
        }

        .message {
            max-width: 80%;
            padding: 0.8rem 1.2rem;
            border-radius: 18px;
            word-wrap: break-word;
            animation: fadeIn 0.3s ease-in;
        }

        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(10px); }
            to { opacity: 1; transform: translateY(0); }
        }

        .user-message {
            align-self: flex-end;
            background: var(--primary-color);
            color: white;
            border-bottom-right-radius: 4px;
        }

        .bot-message {
            align-self: flex-start;
            background: white;
            color: var(--dark-color);
            border: 1px solid #e9ecef;
            border-bottom-left-radius: 4px;
        }

        .weather-info {
            background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
            color: white;
            padding: 1rem;
            border-radius: 12px;
            margin-top: 0.5rem;
        }

        .weather-details {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
            gap: 0.5rem;
            margin-top: 0.5rem;
        }

        .weather-detail {
            text-align: center;
            padding: 0.5rem;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 8px;
        }

        .chat-input-container {
            padding: 1.5rem;
            background: white;
            border-top: 1px solid #e9ecef;
        }

        .chat-input {
            border: 2px solid #e9ecef;
            border-radius: 25px;
            padding: 0.8rem 1.5rem;
            font-size: 1rem;
            transition: all 0.3s ease;
            width: 100%;
        }

        .chat-input:focus {
            outline: none;
            border-color: var(--primary-color);
            box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
        }

        .send-button {
            background: var(--primary-color);
            color: white;
            border: none;
            border-radius: 50%;
            width: 50px;
            height: 50px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s ease;
            margin-left: 1rem;
        }

        .send-button:hover {
            background: #0056b3;
            transform: scale(1.05);
        }

        .send-button:disabled {
            background: var(--secondary-color);
            cursor: not-allowed;
            transform: scale(1);
        }

        .typing-indicator {
            display: none;
            align-items: center;
            gap: 0.3rem;
            padding: 0.8rem 1.2rem;
            background: white;
            border: 1px solid #e9ecef;
            border-radius: 18px;
            border-bottom-left-radius: 4px;
            width: fit-content;
        }

        .typing-dot {
            width: 8px;
            height: 8px;
            background: var(--secondary-color);
            border-radius: 50%;
            animation: typing 1.4s infinite ease-in-out;
        }

        .typing-dot:nth-child(1) { animation-delay: -0.32s; }
        .typing-dot:nth-child(2) { animation-delay: -0.16s; }

        @keyframes typing {
            0%, 80%, 100% { transform: scale(0.8); opacity: 0.5; }
            40% { transform: scale(1); opacity: 1; }
        }

        .quick-actions {
            display: flex;
            gap: 0.5rem;
            margin-bottom: 1rem;
            flex-wrap: wrap;
        }

        .quick-action-btn {
            background: var(--light-color);
            border: 1px solid #dee2e6;
            border-radius: 20px;
            padding: 0.5rem 1rem;
            font-size: 0.9rem;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .quick-action-btn:hover {
            background: var(--primary-color);
            color: white;
            border-color: var(--primary-color);
        }

        .footer {
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(10px);
            text-align: center;
            padding: 1rem;
            color: var(--secondary-color);
            border-top: 1px solid rgba(0, 0, 0, 0.1);
        }

        .footer a {
            color: var(--primary-color);
            text-decoration: none;
        }

        .footer a:hover {
            text-decoration: underline;
        }

        @media (max-width: 768px) {
            .chat-container {
                padding: 1rem;
            }
            
            .chat-card {
                height: 500px;
                border-radius: 15px;
            }
            
            .message {
                max-width: 90%;
            }
            
            .weather-details {
                grid-template-columns: repeat(2, 1fr);
            }
        }

        .loading-spinner {
            display: none;
            width: 20px;
            height: 20px;
            border: 2px solid #f3f3f3;
            border-top: 2px solid var(--primary-color);
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }

        @keyframes spin {
            0% { transform: rotate(0deg); }
            100% { transform: rotate(360deg); }
        }
    </style>
</head>
<body>
    <div class="main-container">
        <!-- Header -->
        <header class="header">
            <div class="container">
                <div class="row align-items-center">
                    <div class="col-md-6">
                        <a href="https://rskworld.in" class="logo">
                            <i class="fas fa-cloud-sun"></i>
                            Weather Chatbot
                        </a>
                    </div>
                    <div class="col-md-6 text-md-end">
                        <small class="text-muted">
                            Powered by <a href="https://rskworld.in" target="_blank">RSK World</a> | © 2026
                        </small>
                    </div>
                </div>
            </div>
        </header>

        <!-- Chat Container -->
        <div class="chat-container">
            <div class="chat-card">
                <!-- Chat Header -->
                <div class="chat-header">
                    <h4 class="mb-0">
                        <i class="fas fa-robot me-2"></i>
                        Weather Assistant
                    </h4>
                    <small>Ask me about weather conditions, forecasts, and alerts!</small>
                </div>

                <!-- Chat Messages -->
                <div class="chat-messages" id="chatMessages">
                    <div class="message bot-message">
                        <div>👋 Hello! I'm your Weather Assistant. I can help you with:</div>
                        <ul class="mb-0 mt-2">
                            <li>Current weather conditions</li>
                            <li>Weather forecasts</li>
                            <li>Weather alerts and warnings</li>
                        </ul>
                        <div class="mt-2">Try asking: "What's the weather in London?"</div>
                    </div>
                </div>

                <!-- Typing Indicator -->
                <div class="typing-indicator" id="typingIndicator">
                    <div class="typing-dot"></div>
                    <div class="typing-dot"></div>
                    <div class="typing-dot"></div>
                </div>

                <!-- Chat Input -->
                <div class="chat-input-container">
                    <div class="quick-actions">
                        <button class="quick-action-btn" onclick="sendQuickMessage('What\'s the weather in London?')">
                            <i class="fas fa-city me-1"></i> London
                        </button>
                        <button class="quick-action-btn" onclick="sendQuickMessage('Weather forecast for New York')">
                            <i class="fas fa-calendar me-1"></i> NYC Forecast
                        </button>
                        <button class="quick-action-btn" onclick="sendQuickMessage('Any weather alerts for Delhi?')">
                            <i class="fas fa-exclamation-triangle me-1"></i> Delhi Alerts
                        </button>
                        <button class="quick-action-btn" onclick="sendQuickMessage('How\'s the weather in Tokyo today?')">
                            <i class="fas fa-sun me-1"></i> Tokyo Today
                        </button>
                    </div>
                    <div class="input-group">
                        <input type="text" 
                               class="chat-input" 
                               id="messageInput" 
                               placeholder="Ask about weather..." 
                               onkeypress="handleKeyPress(event)">
                        <button class="send-button" id="sendButton" onclick="sendMessage()">
                            <i class="fas fa-paper-plane"></i>
                            <div class="loading-spinner" id="loadingSpinner"></div>
                        </button>
                    </div>
                </div>
            </div>
        </div>

        <!-- Footer -->
        <footer class="footer">
            <div class="container">
                <div class="row">
                    <div class="col-md-6">
                        <small>
                            <strong>RSK World</strong> | 
                            <i class="fas fa-phone me-1"></i> +91 93305 39277 | 
                            <i class="fas fa-envelope me-1"></i> hello@rskworld.in
                        </small>
                    </div>
                    <div class="col-md-6 text-md-end">
                        <small>
                            <a href="https://rskworld.in" target="_blank">Website</a> | 
                            <a href="https://rskworld.in/contact.php" target="_blank">Contact</a> | 
                            <a href="https://rskworld.in/disclaimer.php" target="_blank">Disclaimer</a>
                        </small>
                    </div>
                </div>
                <div class="mt-2">
                    <small class="text-muted">
                        Nutanhat, Mongolkote, Purba Burdwan, West Bengal, India, 713147
                    </small>
                </div>
            </div>
        </footer>
    </div>

    <!-- Bootstrap JS -->
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
    
    <!-- Custom JavaScript -->
    <script src="{{ url_for('static', filename='script.js') }}"></script>
</body>
</html>
435 lines•14.5 KB
markup
requirements.txt
Raw Download
Find: Go to:
# Weather Chatbot Dependencies
# ==============================
#
# Author: RSK World (https://rskworld.in)
# Founded by: Molla Samser
# Designer & Tester: Rima Khatun
# Contact: +91 93305 39277, hello@rskworld.in, support@rskworld.in
# Location: Nutanhat, Mongolkote, Purba Burdwan, West Bengal, India, 713147
# Year: 2026
#
# Description: Required Python packages for the Weather Chatbot application
# providing forecasts, alerts, and weather information with advanced features.

# Web Framework
Flask==2.3.3
Werkzeug==2.3.7
Flask-CORS==4.0.0
Flask-Limiter==3.5.0

# HTTP Requests
requests==2.31.0

# Environment Variables
python-dotenv==1.0.0

# OpenAI API
openai>=1.0.0

# Database
SQLAlchemy==2.0.21

# Authentication & Security
PyJWT==2.8.0
cryptography==41.0.4
Werkzeug==2.3.7

# Natural Language Processing
textblob==0.17.1
spacy==3.6.1
nltk==3.8.1

# Data Processing & Analytics
pandas==2.1.1
numpy==1.25.2
scipy==1.11.3

# Data Visualization
matplotlib==3.7.2
plotly==5.17.0
seaborn==0.12.2

# Email & Notifications
email-validator==2.0.0
# Note: smtplib is built-in to Python, no need to install

# SMS (Optional)
twilio==8.8.0

# Push Notifications (Optional)
firebase-admin==6.2.0

# Caching
redis>=4.5.0
Flask-Caching==2.1.0

# Rate Limiting
flask-limiter==3.5.0

# Data Validation
marshmallow==3.20.1

# Logging
loguru==0.7.2

# Date/Time Processing
pytz==2023.3
python-dateutil==2.8.2

# Configuration Management
configparser==6.0.0

# Testing
pytest==7.4.2
pytest-flask==1.2.0
pytest-cov==4.1.0

# Code Quality
black==23.9.1
flake8==6.1.0
mypy==1.5.1

# Documentation
sphinx==7.2.6

# Development Tools
jupyter==1.0.0
ipython==8.15.0

# JSON Processing (built-in)
# json - included with Python

# Date/Time Processing (built-in)
# datetime - included with Python

# Operating System Interface (built-in)
# os - included with Python
107 lines•1.9 KB
text

About RSK World

Founded by Molla Samser, with Designer & Tester Rima Khatun, RSK World is your one-stop destination for free programming resources, source code, and development tools.

Founder: Molla Samser
Designer & Tester: Rima Khatun

Development

  • Game Development
  • Web Development
  • Mobile Development
  • AI Development
  • Development Tools

Legal

  • Terms & Conditions
  • Privacy Policy
  • Disclaimer

Contact Info

Nutanhat, Mongolkote
Purba Burdwan, West Bengal
India, 713147

+91 93305 39277

hello@rskworld.in
support@rskworld.in

© 2026 RSK World. All rights reserved.

Content used for educational purposes only. View Disclaimer