notes: 加「 清理润色」block + 转写原文默认折叠
deploy notes / build-and-deploy (push) Successful in 1m47s

- backend: schema 加 cleaned 列;process_recording 流程
  ASR → cleaning (LLM 分段+去口语+润色+**加粗高亮**) → summarizing → done
- cleanup LLM 失败不阻塞,继续 summary
- 前端三 block 顺序:纪要 → 清理润色 → 原文(details 折叠)
- 新 status 'cleaning' 也加进 statusLabel / progressText
This commit is contained in:
Fam Zheng
2026-05-18 01:22:33 +01:00
parent ca11a9bda7
commit e072109e91
2 changed files with 124 additions and 13 deletions
+41 -5
View File
@@ -118,9 +118,20 @@
</section>
<section class="block">
<h3>🎙 转写原文</h3>
<p v-if="!selected.transcript" class="muted">{{ selected.status === 'failed' ? '转写失败' : '尚未生成' }}</p>
<pre v-else class="transcript">{{ selected.transcript }}</pre>
<h3> 清理润色</h3>
<p v-if="!selected.cleaned && selected.status === 'done'" class="muted">cleanup step 失败看下方原文</p>
<p v-else-if="['pending','transcribing','cleaning','summarizing'].includes(selected.status)" class="muted">
{{ progressText(selected.status) }}
</p>
<div v-else class="prose" v-html="mdLite(selected.cleaned)"></div>
</section>
<section class="block">
<details>
<summary><h3 style="display:inline">🎙 转写原文默认折叠</h3></summary>
<p v-if="!selected.transcript" class="muted">{{ selected.status === 'failed' ? '转写失败' : '尚未生成' }}</p>
<pre v-else class="transcript">{{ selected.transcript }}</pre>
</details>
</section>
</template>
</main>
@@ -392,7 +403,8 @@ function statusLabel(s) {
return ({
pending: '⏳ 排队',
transcribing: '🎙️ 转写中',
summarizing: '✏️ 总结中',
cleaning: '✨ 清理润色中',
summarizing: '📋 总结中',
done: '✓ 完成',
failed: '✗ 失败',
})[s] || s
@@ -401,7 +413,8 @@ function progressText(s) {
return ({
pending: '等候处理',
transcribing: '语音转写中(视音频长度可能要几分钟)',
summarizing: 'LLM 生成纪要中',
cleaning: 'LLM 分段 + 去口语 + 润色 + 高亮',
summarizing: 'LLM 生成会议纪要',
})[s] || s
}
function fmtSize(b) {
@@ -740,6 +753,29 @@ input, textarea { font-family: inherit; background: transparent; border: none; c
}
.block.err pre { white-space: pre-wrap; color: var(--accent-red); font-size: 12px; }
.block details > summary {
cursor: pointer;
list-style: none;
user-select: none;
margin-bottom: 4px;
}
.block details > summary::-webkit-details-marker { display: none; }
.block details > summary::before {
content: '▶';
display: inline-block;
margin-right: 6px;
font-size: 11px;
color: var(--text-mute);
transition: transform 0.15s;
}
.block details[open] > summary::before { transform: rotate(90deg); }
.block details > summary h3 {
margin: 0 !important;
text-transform: none;
letter-spacing: normal;
font-size: 13px;
}
@media (max-width: 768px) {
.root { flex-direction: column; }
.sidebar { width: 100%; height: 45vh; border-right: none; border-bottom: 1px solid var(--border-soft); }