| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <title>Hugging Face Sentiment App</title> | |
| <link rel="stylesheet" href="{{ url_for('static', filename='style.css') }}"> | |
| </head> | |
| <body> | |
| <div class="container"> | |
| <h1>Sentiment Analysis</h1> | |
| <form method="POST"> | |
| <textarea name="text" placeholder="Enter text here..."></textarea> | |
| <button type="submit">Analyze</button> | |
| </form> | |
| {% if result %} | |
| <div class="result"> | |
| <strong>Label:</strong> {{ result.label }}<br> | |
| <strong>Score:</strong> {{ result.score | round(2) }} | |
| </div> | |
| {% endif %} | |
| </div> | |
| </body> | |
| </html> | |