251 lines
9.3 KiB
HTML
251 lines
9.3 KiB
HTML
<!doctype html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
<title>BoostAI FineTune Helper</title>
|
|
<link rel="stylesheet" href="/styles.css" />
|
|
</head>
|
|
<body>
|
|
<div class="page-shell">
|
|
<header class="hero">
|
|
<div>
|
|
<p class="eyebrow">Local helper app</p>
|
|
<h1>BoostAI FineTune Data Helper</h1>
|
|
<p class="hero-copy">
|
|
Create full assignment-review examples that match the real app shape: one assignment, many question-level labels, and one assignment-level summary.
|
|
</p>
|
|
</div>
|
|
<div class="hero-actions">
|
|
<button id="save-example" type="button">Save assignment example</button>
|
|
<button id="load-sample" type="button">Load sample</button>
|
|
<button id="clear-form" type="button" class="button-secondary">Clear</button>
|
|
</div>
|
|
</header>
|
|
|
|
<section class="status-bar">
|
|
<div>
|
|
<strong>Hosted AI:</strong>
|
|
<span id="ai-config-status">Checking…</span>
|
|
</div>
|
|
<div>
|
|
<strong>Assignment generator:</strong>
|
|
<span id="question-generator-status">Checking…</span>
|
|
</div>
|
|
<div>
|
|
<strong>Shared workspace:</strong>
|
|
<span id="collab-status">Connecting…</span>
|
|
</div>
|
|
<div>
|
|
<strong>Editors:</strong>
|
|
<span id="presence-status">1 connected</span>
|
|
</div>
|
|
<div id="save-status">Autosave ready</div>
|
|
</section>
|
|
|
|
<main class="layout-grid">
|
|
<section class="editor-shell span-2">
|
|
<aside class="card workspace-nav-card">
|
|
<div class="workspace-toolbar">
|
|
<div>
|
|
<h2>Assignments</h2>
|
|
<p class="section-copy">Search, sort, and switch between lots of in-progress assignment drafts without losing the shared editor.</p>
|
|
</div>
|
|
<button id="new-draft" type="button">New draft</button>
|
|
</div>
|
|
|
|
<div class="workspace-controls">
|
|
<label class="control-field workspace-search-field">
|
|
<span>Find an assignment</span>
|
|
<input id="draft-search" type="text" placeholder="Search by title, assignment ID, topic, or student" />
|
|
</label>
|
|
<label class="control-field control-field-compact">
|
|
<span>Sort</span>
|
|
<select id="draft-sort">
|
|
<option value="updated">Recently updated</option>
|
|
<option value="title">Title</option>
|
|
<option value="topic">Topic</option>
|
|
<option value="questions">Question count</option>
|
|
</select>
|
|
</label>
|
|
</div>
|
|
|
|
<div class="workspace-meta-row">
|
|
<div id="draft-status" class="summary-strip compact-strip">1 local draft</div>
|
|
<div class="workspace-actions">
|
|
<button id="duplicate-draft" type="button" class="button-secondary">Duplicate</button>
|
|
<button id="rename-draft" type="button" class="button-secondary">Rename</button>
|
|
<button id="delete-draft" type="button" class="button-danger">Delete</button>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="draft-list" class="draft-list" role="listbox" aria-label="Assignment drafts"></div>
|
|
</aside>
|
|
|
|
<section class="card editor-card">
|
|
<div class="section-heading">
|
|
<div>
|
|
<h2>Assignment builder</h2>
|
|
<p class="section-copy">Generate a multi-question assignment from the real backend, then edit the assignment metadata or any question before saving.</p>
|
|
</div>
|
|
<div class="hero-actions">
|
|
<button id="generate-assignment" type="button">Generate assignment</button>
|
|
<button id="add-question" type="button" class="button-secondary">Add blank question</button>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="form-grid three-up">
|
|
<label>
|
|
<span>Assignment ID</span>
|
|
<input id="assignmentId" type="text" placeholder="assignment-fractions-01" />
|
|
</label>
|
|
<label>
|
|
<span>Student ID</span>
|
|
<input id="studentId" type="text" placeholder="student-17" />
|
|
</label>
|
|
<label>
|
|
<span>Pass threshold</span>
|
|
<input id="passThreshold" type="number" min="0" max="1" step="0.01" placeholder="0.70" />
|
|
</label>
|
|
</div>
|
|
|
|
<div class="form-grid two-up">
|
|
<label>
|
|
<span>Assignment title</span>
|
|
<input id="assignmentTitle" type="text" placeholder="Fractions practice review" />
|
|
</label>
|
|
<label>
|
|
<span>Instructions</span>
|
|
<input id="instructions" type="text" placeholder="Show working for every question." />
|
|
</label>
|
|
</div>
|
|
|
|
<div class="form-grid four-up">
|
|
<label>
|
|
<span>Topic</span>
|
|
<select id="topic">
|
|
<option value="">Select…</option>
|
|
<option value="place_value">place_value</option>
|
|
<option value="arithmetic">arithmetic</option>
|
|
<option value="negative_numbers">negative_numbers</option>
|
|
<option value="bidmas">bidmas</option>
|
|
<option value="fractions">fractions</option>
|
|
<option value="algebra">algebra</option>
|
|
<option value="geometry">geometry</option>
|
|
<option value="data">data</option>
|
|
</select>
|
|
</label>
|
|
<label>
|
|
<span>Difficulty</span>
|
|
<select id="difficulty">
|
|
<option value="">Select…</option>
|
|
<option value="easy">easy</option>
|
|
<option value="medium">medium</option>
|
|
<option value="hard">hard</option>
|
|
</select>
|
|
</label>
|
|
<label>
|
|
<span>Question count</span>
|
|
<input id="questionCount" type="number" min="1" max="25" step="1" placeholder="4" />
|
|
</label>
|
|
<label>
|
|
<span>Generation seed (optional)</span>
|
|
<input id="generatorSeed" type="text" placeholder="auto-filled after generation" readonly />
|
|
</label>
|
|
</div>
|
|
|
|
<div class="question-toolbar">
|
|
<div class="question-toolbar-group">
|
|
<span class="question-toolbar-label">View</span>
|
|
<button id="filter-all" type="button" class="button-secondary is-active">All questions</button>
|
|
<button id="filter-attention" type="button" class="button-secondary">Needs attention</button>
|
|
<button id="filter-unlabeled" type="button" class="button-secondary">Unlabeled</button>
|
|
</div>
|
|
<div class="question-toolbar-group">
|
|
<span class="question-toolbar-label">Layout</span>
|
|
<button id="expand-all-questions" type="button" class="button-secondary">Expand all</button>
|
|
<button id="collapse-all-questions" type="button" class="button-secondary">Collapse all</button>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="question-summary" class="summary-strip">No questions yet.</div>
|
|
<div id="questions-container" class="question-stack"></div>
|
|
</section>
|
|
</section>
|
|
|
|
<section class="card">
|
|
<div class="section-heading">
|
|
<div>
|
|
<h2>Student submission</h2>
|
|
<p class="section-copy">Draft the whole student submission at once, then tweak any question manually.</p>
|
|
</div>
|
|
<button id="generate-students" type="button">AI draft student submission</button>
|
|
</div>
|
|
<div class="mini-note">
|
|
One student voice should carry across the full assignment. Each question stores <code>answerText</code>, <code>workingSteps</code>, and <code>solveMode</code>.
|
|
</div>
|
|
</section>
|
|
|
|
<section class="card">
|
|
<div class="section-heading">
|
|
<div>
|
|
<h2>Teacher review package</h2>
|
|
<p class="section-copy">Generate per-question review labels plus one assignment summary, matching the real production shape.</p>
|
|
</div>
|
|
<button id="generate-teacher" type="button">AI draft full teacher review</button>
|
|
</div>
|
|
|
|
<label>
|
|
<span>Assignment summary</span>
|
|
<textarea id="assignmentSummary" rows="5" placeholder="Short whole-assignment summary"></textarea>
|
|
</label>
|
|
<label>
|
|
<span>Recommended next step</span>
|
|
<textarea id="recommendedNextStep" rows="4" placeholder="What the teacher should do next"></textarea>
|
|
</label>
|
|
</section>
|
|
|
|
<section class="card preview-card">
|
|
<div class="section-heading">
|
|
<h2>Labeled record preview</h2>
|
|
<button id="copy-record" type="button" class="button-secondary">Copy JSON</button>
|
|
</div>
|
|
<pre id="recordPreview"></pre>
|
|
</section>
|
|
|
|
<section class="card preview-card">
|
|
<div class="section-heading">
|
|
<h2>Fine-tune example preview</h2>
|
|
<button id="copy-training" type="button" class="button-secondary">Copy JSON</button>
|
|
</div>
|
|
<pre id="trainingPreview"></pre>
|
|
</section>
|
|
|
|
<section class="card dataset-card span-2">
|
|
<div class="section-heading">
|
|
<div>
|
|
<h2>Saved dataset</h2>
|
|
<p id="datasetStatus" class="section-copy">No saved examples yet.</p>
|
|
</div>
|
|
<div class="hero-actions dataset-actions">
|
|
<button id="export-dataset" type="button" class="button-secondary">Export dataset.jsonl</button>
|
|
<button id="export-split" type="button" class="button-secondary">Export train/val split</button>
|
|
</div>
|
|
</div>
|
|
<div id="datasetEmpty" class="empty-state">
|
|
Save full assignment-review examples here. Each saved item becomes one training row.
|
|
</div>
|
|
<div id="datasetList" class="dataset-list"></div>
|
|
</section>
|
|
</main>
|
|
|
|
<section class="card footer-note">
|
|
<strong>Shape target:</strong> one assignment-level review call, question-level labels for every question, and one assignment summary. Treat AI drafts as prefill only.
|
|
</section>
|
|
</div>
|
|
|
|
<div id="toast" class="toast hidden"></div>
|
|
<script type="module" src="/app.js"></script>
|
|
</body>
|
|
</html>
|