index.html 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <!doctype html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <meta name="viewport" content="width=device-width, initial-scale=1" />
  6. <title>Agent Lab</title>
  7. <link rel="stylesheet" href="/static/styles.css" />
  8. </head>
  9. <body>
  10. <header class="topbar">
  11. <h1>Agent Lab</h1>
  12. <div id="connection-status" class="status">Idle</div>
  13. </header>
  14. <main class="layout">
  15. <aside class="panel controls">
  16. <section>
  17. <div class="section-head">
  18. <h2>System Prompts</h2>
  19. <button id="add-system-prompt" type="button">Add</button>
  20. </div>
  21. <div id="system-prompts" class="stack">
  22. <textarea class="system-prompt" rows="4">You are a debugging assistant.</textarea>
  23. </div>
  24. </section>
  25. <section>
  26. <div class="section-head">
  27. <h2>Pre Messages</h2>
  28. <button id="add-pre-message" type="button">Add</button>
  29. </div>
  30. <div id="pre-messages" class="stack"></div>
  31. </section>
  32. <section>
  33. <h2>Chat Agent</h2>
  34. <label>Model <input id="model" placeholder="Backend default" /></label>
  35. <label>Temperature <input id="temperature" type="number" min="0" max="2" step="0.1" value="0.2" /></label>
  36. <label>Max Tokens <input id="max-tokens" type="number" min="1" step="1" value="800" /></label>
  37. </section>
  38. <section>
  39. <h2>Event Agent</h2>
  40. <label>Max Loops <input id="max-event-loops" type="number" min="1" step="1" value="3" /></label>
  41. <div id="tool-list" class="stack">Loading tools...</div>
  42. </section>
  43. </aside>
  44. <section class="workspace">
  45. <div id="messages" class="messages"></div>
  46. <div class="stats">
  47. <div><span>Tokens</span><strong id="stat-tokens">0</strong></div>
  48. <div><span>Cached</span><strong id="stat-cached">0</strong></div>
  49. <div><span>TTFT</span><strong id="stat-ttft">-</strong></div>
  50. <div><span>Elapsed</span><strong id="stat-elapsed">-</strong></div>
  51. </div>
  52. <form id="chat-form" class="composer">
  53. <textarea id="user-message" rows="3" placeholder="Send a debug message"></textarea>
  54. <button type="submit">Run</button>
  55. </form>
  56. </section>
  57. </main>
  58. <template id="pre-message-template">
  59. <div class="pre-message">
  60. <select class="pre-role">
  61. <option value="user">user</option>
  62. <option value="assistant">assistant</option>
  63. <option value="system">system</option>
  64. </select>
  65. <textarea class="pre-content" rows="3"></textarea>
  66. </div>
  67. </template>
  68. <script src="/static/app.js"></script>
  69. </body>
  70. </html>