feat(playground): image & video generation tabs + real chat metrics
The infosave collection now ships media models (Lumina-Image-2.0, MiniMax-H3 Turbo) that cortiq runs via `imagine`/`animate` CLI, not `cortiq serve`. The gateway grows a media API: local .cmf files are classified by `cortiq info` (chat/image/video, cached), generations run as tracked jobs with step progress parsed from stdout, one at a time, cancellable, outputs under <data>/media. The playground becomes three tabs. Image: width/height/steps/CFG/seed, live progress, result rendered from P6 PPM to a canvas in the browser (PNG export via toBlob). Video: frames/steps/quality/seed plus optional first/last keyframes (rasterized to PPM client-side); the MJPEG+PCM AVI is decoded in JS and played on a canvas synced to the wav — no ffmpeg on either side (mp4 remux happens opportunistically when ffmpeg exists). A metrics card shows resolution, steps, seed, total time, time per step/frame and file size. Chat metrics: the local cortiq server sends no usage chunk in streams, so token counts showed 0/0. tap_stream now injects one OpenAI-shaped usage event ahead of [DONE] with the gateway's ~4-chars/token estimate, flagged `cortiq_estimated`; the UI renders it as "≈ N / M" and adds tok/s and time-to-first-token. Registration skips media packs (a `cortiq serve` entry for a diffusion model would only fail) in both Register and the wizard's Finish. 36 new UI strings translated across all 7 languages.
This commit is contained in:
Vendored
+38
@@ -468,4 +468,42 @@ export default {
|
||||
"onboarding.deleteFile": ".cmf dosyasını diskten sil",
|
||||
"onboarding.confirmDelete": "“{id}” silinsin mi? .cmf dosyası diskten kaldırılacak.",
|
||||
"onboarding.unregistered": "Ayrıca kaydı kaldırıldı: {ids}",
|
||||
|
||||
// playground: media generation + streaming metrics
|
||||
"pg.tab.chat": "Sohbet",
|
||||
"pg.tab.image": "Görsel",
|
||||
"pg.tab.video": "Video",
|
||||
"pg.generate": "Oluştur",
|
||||
"pg.generating": "Oluşturuluyor…",
|
||||
"pg.genFailed": "Oluşturma başarısız — günlüğe bakın.",
|
||||
"pg.result": "Sonuç",
|
||||
"pg.genMetrics": "Oluşturma metrikleri",
|
||||
"pg.imagePromptPlaceholder": "gün batımında karda oturan kızıl tilki, fotogerçekçi, ayrıntılı tüyler",
|
||||
"pg.videoPromptPlaceholder": "aşçı şapkalı bir corgi krep çeviriyor, cızırtı sesleri ve neşeli bir havlama",
|
||||
"pg.imageEmpty": "Oluşturulan görsel burada görünecek.",
|
||||
"pg.videoEmpty": "Oluşturulan klip (sesiyle) burada görünecek.",
|
||||
"pg.width": "Genişlik",
|
||||
"pg.height": "Yükseklik",
|
||||
"pg.steps": "Adım",
|
||||
"pg.seed": "Seed",
|
||||
"pg.randomSeed": "Rastgele seed",
|
||||
"pg.cfgHint": "Guidance gücü; ≤ 1 CFG'yi kapatır ve işi yarıya indirir.",
|
||||
"pg.frames": "Kare",
|
||||
"pg.framesHint": "24 fps'te; modelin ızgarasına yuvarlanır.",
|
||||
"pg.quality": "JPEG kalitesi",
|
||||
"pg.videoSizeHint": "32'nin katları; eğitilen kısa kenar 768.",
|
||||
"pg.videoStepsHint": "Turbo LoRA 4 adım için eğitildi.",
|
||||
"pg.firstFrame": "İlk kare (isteğe bağlı)",
|
||||
"pg.lastFrame": "Son kare (isteğe bağlı)",
|
||||
"pg.keyframeHint": "Çalışmayı keyframe-to-video'ya çevirir.",
|
||||
"pg.resolution": "Çözünürlük",
|
||||
"pg.genTime": "Oluşturma süresi",
|
||||
"pg.timePerStep": "Adım başına",
|
||||
"pg.timePerFrame": "Kare başına",
|
||||
"pg.fileSize": "Dosya boyutu",
|
||||
"pg.duration": "Süre",
|
||||
"pg.play": "Oynat",
|
||||
"pg.noMediaModels": "Henüz yerel bir {kind} modeli yok. İçe aktarma sekmesinden bir tane indirin (ör. infosave koleksiyonundan):",
|
||||
"pg.tokSpeed": "Hız",
|
||||
"pg.ttft": "İlk token",
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user