Spaces:
Running
Running
develope app with this plan: Project Structure ``` teaching-notes-agent/ βββ src/ # Core application code β βββ teaching_agent.py # Main agent class β βββ ai_providers.py # AI provider implementations β βββ note_templates.py # Note format templates β βββ exporters.py # Export functionality β βββ cli.py # Command-line interface βββ examples/ # Example usage scripts βββ docs/ # Documentation βββ exports/ # Generated notes output βββ templates/ # Custom template storage βββ config.yaml # Configuration file βββ requirements.txt # Dependencies βββ main.py # Main entry point βββ setup.py # Setup script βββ README.md # Complete documentation - Initial Deployment
69e7374
verified
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Teaching Notes Agent</title> | |
| <script src="https://cdn.tailwindcss.com"></script> | |
| <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"> | |
| <style> | |
| .sidebar { | |
| transition: all 0.3s ease; | |
| } | |
| .sidebar.collapsed { | |
| width: 70px; | |
| } | |
| .sidebar.collapsed .sidebar-text { | |
| display: none; | |
| } | |
| .sidebar.collapsed .sidebar-icon { | |
| margin-right: 0; | |
| } | |
| .content-area { | |
| transition: margin-left 0.3s ease; | |
| } | |
| .template-card:hover { | |
| transform: translateY(-5px); | |
| box-shadow: 0 10px 20px rgba(0,0,0,0.1); | |
| } | |
| .note-editor { | |
| min-height: 300px; | |
| } | |
| .dropdown-content { | |
| display: none; | |
| position: absolute; | |
| z-index: 1; | |
| } | |
| .dropdown:hover .dropdown-content { | |
| display: block; | |
| } | |
| </style> | |
| </head> | |
| <body class="bg-gray-50"> | |
| <div class="flex h-screen overflow-hidden"> | |
| <!-- Sidebar --> | |
| <div class="sidebar bg-indigo-700 text-white w-64 flex flex-col"> | |
| <div class="p-4 flex items-center justify-between border-b border-indigo-600"> | |
| <div class="flex items-center"> | |
| <i class="fas fa-chalkboard-teacher text-2xl sidebar-icon mr-3"></i> | |
| <span class="sidebar-text text-xl font-bold">Teaching Notes</span> | |
| </div> | |
| <button id="toggleSidebar" class="text-white focus:outline-none"> | |
| <i class="fas fa-bars"></i> | |
| </button> | |
| </div> | |
| <div class="flex-1 overflow-y-auto"> | |
| <nav class="p-4"> | |
| <div class="mb-6"> | |
| <h3 class="sidebar-text uppercase text-xs font-semibold text-indigo-300 mb-2">Main</h3> | |
| <ul> | |
| <li class="mb-1"> | |
| <a href="#" class="flex items-center p-2 rounded hover:bg-indigo-600"> | |
| <i class="fas fa-home sidebar-icon mr-3"></i> | |
| <span class="sidebar-text">Dashboard</span> | |
| </a> | |
| </li> | |
| <li class="mb-1"> | |
| <a href="#" class="flex items-center p-2 rounded bg-indigo-800"> | |
| <i class="fas fa-file-alt sidebar-icon mr-3"></i> | |
| <span class="sidebar-text">Create Notes</span> | |
| </a> | |
| </li> | |
| <li class="mb-1"> | |
| <a href="#" class="flex items-center p-2 rounded hover:bg-indigo-600"> | |
| <i class="fas fa-folder sidebar-icon mr-3"></i> | |
| <span class="sidebar-text">Templates</span> | |
| </a> | |
| </li> | |
| <li class="mb-1"> | |
| <a href="#" class="flex items-center p-2 rounded hover:bg-indigo-600"> | |
| <i class="fas fa-download sidebar-icon mr-3"></i> | |
| <span class="sidebar-text">Exports</span> | |
| </a> | |
| </li> | |
| </ul> | |
| </div> | |
| <div class="mb-6"> | |
| <h3 class="sidebar-text uppercase text-xs font-semibold text-indigo-300 mb-2">Settings</h3> | |
| <ul> | |
| <li class="mb-1"> | |
| <a href="#" class="flex items-center p-2 rounded hover:bg-indigo-600"> | |
| <i class="fas fa-cog sidebar-icon mr-3"></i> | |
| <span class="sidebar-text">Configuration</span> | |
| </a> | |
| </li> | |
| <li class="mb-1"> | |
| <a href="#" class="flex items-center p-2 rounded hover:bg-indigo-600"> | |
| <i class="fas fa-plug sidebar-icon mr-3"></i> | |
| <span class="sidebar-text">AI Providers</span> | |
| </a> | |
| </li> | |
| </ul> | |
| </div> | |
| <div> | |
| <h3 class="sidebar-text uppercase text-xs font-semibold text-indigo-300 mb-2">Help</h3> | |
| <ul> | |
| <li class="mb-1"> | |
| <a href="#" class="flex items-center p-2 rounded hover:bg-indigo-600"> | |
| <i class="fas fa-question-circle sidebar-icon mr-3"></i> | |
| <span class="sidebar-text">Documentation</span> | |
| </a> | |
| </li> | |
| <li class="mb-1"> | |
| <a href="#" class="flex items-center p-2 rounded hover:bg-indigo-600"> | |
| <i class="fas fa-book sidebar-icon mr-3"></i> | |
| <span class="sidebar-text">Examples</span> | |
| </a> | |
| </li> | |
| </ul> | |
| </div> | |
| </nav> | |
| </div> | |
| <div class="p-4 border-t border-indigo-600"> | |
| <div class="flex items-center"> | |
| <img src="https://via.placeholder.com/40" alt="User" class="rounded-full mr-3"> | |
| <div class="sidebar-text"> | |
| <div class="font-medium">Teacher</div> | |
| <div class="text-xs text-indigo-300">[email protected]</div> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Main Content --> | |
| <div class="content-area flex-1 flex flex-col overflow-hidden"> | |
| <!-- Top Navigation --> | |
| <header class="bg-white border-b border-gray-200 p-4 flex items-center justify-between"> | |
| <h1 class="text-2xl font-bold text-gray-800">Create Teaching Notes</h1> | |
| <div class="flex items-center space-x-4"> | |
| <div class="relative"> | |
| <button class="p-2 rounded-full hover:bg-gray-100"> | |
| <i class="fas fa-bell text-gray-600"></i> | |
| </button> | |
| <span class="absolute top-0 right-0 h-2 w-2 rounded-full bg-red-500"></span> | |
| </div> | |
| <div class="dropdown relative"> | |
| <button class="flex items-center space-x-2 focus:outline-none"> | |
| <span class="text-gray-700">Settings</span> | |
| <i class="fas fa-chevron-down text-gray-500"></i> | |
| </button> | |
| <div class="dropdown-content right-0 mt-2 w-48 bg-white rounded-md shadow-lg py-1"> | |
| <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">Profile</a> | |
| <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">Settings</a> | |
| <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">Log out</a> | |
| </div> | |
| </div> | |
| </div> | |
| </header> | |
| <!-- Main Content Area --> | |
| <main class="flex-1 overflow-y-auto p-6 bg-gray-50"> | |
| <div class="max-w-6xl mx-auto"> | |
| <!-- Form Section --> | |
| <div class="bg-white rounded-lg shadow-md p-6 mb-6"> | |
| <h2 class="text-xl font-semibold mb-4">Note Generation Parameters</h2> | |
| <div class="grid grid-cols-1 md:grid-cols-2 gap-6 mb-6"> | |
| <div> | |
| <label class="block text-sm font-medium text-gray-700 mb-1">Subject</label> | |
| <select class="w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500"> | |
| <option>Mathematics</option> | |
| <option>Science</option> | |
| <option>Language Arts</option> | |
| <option>History</option> | |
| <option>Computer Science</option> | |
| </select> | |
| </div> | |
| <div> | |
| <label class="block text-sm font-medium text-gray-700 mb-1">Grade Level</label> | |
| <select class="w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500"> | |
| <option>Elementary (K-5)</option> | |
| <option>Middle School (6-8)</option> | |
| <option>High School (9-12)</option> | |
| <option>College</option> | |
| </select> | |
| </div> | |
| <div> | |
| <label class="block text-sm font-medium text-gray-700 mb-1">Topic</label> | |
| <input type="text" class="w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500" placeholder="Enter topic..."> | |
| </div> | |
| <div> | |
| <label class="block text-sm font-medium text-gray-700 mb-1">Template</label> | |
| <select class="w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500"> | |
| <option>Standard Lesson Plan</option> | |
| <option>Lecture Notes</option> | |
| <option>Discussion Guide</option> | |
| <option>Activity Plan</option> | |
| <option>Assessment Guide</option> | |
| </select> | |
| </div> | |
| </div> | |
| <div class="mb-6"> | |
| <label class="block text-sm font-medium text-gray-700 mb-1">Additional Instructions</label> | |
| <textarea class="w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500 note-editor" rows="4" placeholder="Provide any specific instructions for the note generation..."></textarea> | |
| </div> | |
| <div class="flex justify-end space-x-3"> | |
| <button class="px-4 py-2 border border-gray-300 rounded-md text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"> | |
| Reset | |
| </button> | |
| <button class="px-4 py-2 bg-indigo-600 text-white rounded-md hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"> | |
| Generate Notes | |
| </button> | |
| </div> | |
| </div> | |
| <!-- Output Section --> | |
| <div class="bg-white rounded-lg shadow-md p-6 mb-6"> | |
| <div class="flex justify-between items-center mb-4"> | |
| <h2 class="text-xl font-semibold">Generated Notes</h2> | |
| <div class="flex space-x-2"> | |
| <button class="p-2 text-gray-600 hover:text-indigo-600 hover:bg-gray-100 rounded"> | |
| <i class="fas fa-copy"></i> | |
| </button> | |
| <div class="dropdown relative"> | |
| <button class="p-2 text-gray-600 hover:text-indigo-600 hover:bg-gray-100 rounded"> | |
| <i class="fas fa-download"></i> | |
| </button> | |
| <div class="dropdown-content right-0 mt-2 w-48 bg-white rounded-md shadow-lg py-1"> | |
| <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">PDF</a> | |
| <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">Word</a> | |
| <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">Markdown</a> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="border border-gray-200 rounded-md p-4 note-editor"> | |
| <div class="text-center py-10 text-gray-400"> | |
| <i class="fas fa-file-alt text-4xl mb-3"></i> | |
| <p>Your generated notes will appear here</p> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Templates Section --> | |
| <div class="bg-white rounded-lg shadow-md p-6"> | |
| <h2 class="text-xl font-semibold mb-4">Available Templates</h2> | |
| <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4"> | |
| <!-- Template Card 1 --> | |
| <div class="template-card bg-white border border-gray-200 rounded-lg p-4 hover:shadow-md transition duration-300"> | |
| <div class="flex items-center mb-3"> | |
| <div class="bg-indigo-100 p-2 rounded-full mr-3"> | |
| <i class="fas fa-book text-indigo-600"></i> | |
| </div> | |
| <h3 class="font-medium">Standard Lesson Plan</h3> | |
| </div> | |
| <p class="text-sm text-gray-600 mb-3">Comprehensive template with objectives, activities, and assessment sections.</p> | |
| <button class="text-sm text-indigo-600 hover:text-indigo-800">Use Template</button> | |
| </div> | |
| <!-- Template Card 2 --> | |
| <div class="template-card bg-white border border-gray-200 rounded-lg p-4 hover:shadow-md transition duration-300"> | |
| <div class="flex items-center mb-3"> | |
| <div class="bg-blue-100 p-2 rounded-full mr-3"> | |
| <i class="fas fa-chalkboard text-blue-600"></i> | |
| </div> | |
| <h3 class="font-medium">Lecture Notes</h3> | |
| </div> | |
| <p class="text-sm text-gray-600 mb-3">Structured format for presenting lecture content with key points.</p> | |
| <button class="text-sm text-blue-600 hover:text-blue-800">Use Template</button> | |
| </div> | |
| <!-- Template Card 3 --> | |
| <div class="template-card bg-white border border-gray-200 rounded-lg p-4 hover:shadow-md transition duration-300"> | |
| <div class="flex items-center mb-3"> | |
| <div class="bg-green-100 p-2 rounded-full mr-3"> | |
| <i class="fas fa-comments text-green-600"></i> | |
| </div> | |
| <h3 class="font-medium">Discussion Guide</h3> | |
| </div> | |
| <p class="text-sm text-gray-600 mb-3">Template for facilitating classroom discussions with questions.</p> | |
| <button class="text-sm text-green-600 hover:text-green-800">Use Template</button> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| </main> | |
| </div> | |
| </div> | |
| <script> | |
| // Toggle sidebar | |
| document.getElementById('toggleSidebar').addEventListener('click', function() { | |
| const sidebar = document.querySelector('.sidebar'); | |
| sidebar.classList.toggle('collapsed'); | |
| const contentArea = document.querySelector('.content-area'); | |
| if (sidebar.classList.contains('collapsed')) { | |
| contentArea.classList.add('ml-16'); | |
| } else { | |
| contentArea.classList.remove('ml-16'); | |
| } | |
| }); | |
| // Simulate note generation | |
| document.querySelector('button:contains("Generate Notes")').addEventListener('click', function() { | |
| const outputArea = document.querySelector('.note-editor:not(textarea)'); | |
| outputArea.innerHTML = ` | |
| <div class="prose max-w-none"> | |
| <h2>Introduction to Algebra</h2> | |
| <h3>Grade Level: Middle School (6-8)</h3> | |
| <h4>Lesson Objectives:</h4> | |
| <ul> | |
| <li>Understand basic algebraic concepts</li> | |
| <li>Solve simple linear equations</li> | |
| <li>Apply algebraic thinking to word problems</li> | |
| </ul> | |
| <h4>Key Concepts:</h4> | |
| <p>Variables, equations, expressions, solving for x</p> | |
| <h4>Activities:</h4> | |
| <ol> | |
| <li>Warm-up: Number patterns (10 min)</li> | |
| <li>Direct instruction: Variables and equations (20 min)</li> | |
| <li>Guided practice: Solving equations (15 min)</li> | |
| <li>Independent practice: Worksheet (15 min)</li> | |
| </ol> | |
| <h4>Assessment:</h4> | |
| <p>Exit ticket with 3 problems solving for x</p> | |
| <h4>Differentiation:</h4> | |
| <p>Provide visual aids for visual learners, extended time for students who need it</p> | |
| </div> | |
| `; | |
| // Show success message | |
| const notification = document.createElement('div'); | |
| notification.className = 'fixed top-4 right-4 bg-green-500 text-white px-4 py-2 rounded shadow-lg'; | |
| notification.innerHTML = '<i class="fas fa-check-circle mr-2"></i> Notes generated successfully!'; | |
| document.body.appendChild(notification); | |
| setTimeout(() => { | |
| notification.remove(); | |
| }, 3000); | |
| }); | |
| // Template selection | |
| document.querySelectorAll('.template-card button').forEach(button => { | |
| button.addEventListener('click', function() { | |
| const templateName = this.closest('.template-card').querySelector('h3').textContent; | |
| const templateSelect = document.querySelector('select:contains("Template")'); | |
| // Find and select the matching option | |
| for (let option of templateSelect.options) { | |
| if (option.text === templateName) { | |
| option.selected = true; | |
| break; | |
| } | |
| } | |
| // Show success message | |
| const notification = document.createElement('div'); | |
| notification.className = 'fixed top-4 right-4 bg-blue-500 text-white px-4 py-2 rounded shadow-lg'; | |
| notification.innerHTML = `<i class="fas fa-check-circle mr-2"></i> "${templateName}" template selected!`; | |
| document.body.appendChild(notification); | |
| setTimeout(() => { | |
| notification.remove(); | |
| }, 3000); | |
| }); | |
| }); | |
| </script> | |
| <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 𧬠<a href="https://enzostvs-deepsite.hf.space?remix=Godito/notes-generator" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body> | |
| </html> |