v148 · on-device AI

Quality Control Panel

Run all three performance modes — fast, balanced, quality — on the same text simultaneously. Compare latency, word-count reduction, and output quality side by side to decide which mode is right for each call site.

Fastest mode (ms)
Best compression %
Inference mode
Input
Sample text
fast
Not run
balanced
Not run
quality
Not run
// Run all three modes in parallel const MODES = ['fast', 'balanced', 'quality']; const [fastResult, balancedResult, qualityResult] = await Promise.all( MODES.map(async pref => { const t0 = performance.now(); const s = await Summarizer.create({ performancePreference: pref, type: 'tl;dr' }); const text = await s.summarize(inputText); return { pref, text, latency: performance.now() - t0 }; }) );

see also

implementation reference

Need the exact API surface, compatibility boundaries, errors, lifecycle, and source links? Read the matching gendn reference ↗