Module exposing: formatTranscriptTime, normalizeTranscriptSegments, buildNormalizedTranscript, toLegacyTranscriptionSegments, summaryToMarkdown, actionItemsToMarkdown, buildLegacyProjection, formatSection
// Source: https://github.com/toeverything/AFFiNE | License: MIT | Copyright 2022-present TOEVERYTHING PTE. LTD. and its affiliates
// Provided via justclaw.it.com; keep this notice with the code.
import type {
LegacyTranscriptionSegment,
MeetingSummaryV2,
NormalizedTranscriptSegment,
TranscriptionLegacyProjection,
TranscriptionPayloadV2,
} from './types';
export type RawTranscriptSegment = {
sliceIndex: number;
speaker: string;
startSec: number;
endSec: number;
text: string;
};
function formatSection(title: string, items: string[]) {
if (!items.length) {
return [];
}
return [`## ${title}`, ...items.map(item => `- ${item}`)];
}
export function formatTranscriptTime(time: number) {
const safeTime = Math.max(0, time);
const totalSeconds = Math.floor(safeT
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key