Commit Graph
34 Commits
Author SHA1 Message Date
Pascal f9f4a0c820 cleanup: remove dead code and DRY pre_conv release via wctx_free 2026-05-14 23:27:09 +02:00
Pascal dda50c2225 codec: add chunked decode with rolling left context 2026-05-14 22:53:28 +02:00
Pascal d99eececc8 nits 2026-05-14 22:26:28 +02:00
Pascal b1339f7cae abi: drop QT_CODEC_SAMPLE_RATE macro, hardcode 24000 like omnivoice 2026-05-14 21:55:23 +02:00
Pascal 38bf6d762a abi, pipeline, cli: conform qwentts on omnivoice convention 2026-05-14 21:42:52 +02:00
Pascal 259e7059f6 align symbol naming on omnivoice convention 2026-05-14 18:09:07 +02:00
Pascal e55ba50b75 src: fuse 3 .cpp into header-only modules to match omnivoice 2026-05-14 17:14:30 +02:00
Pascal e8f1c2a053 nits 2026-05-14 16:47:45 +02:00
Pascal b1e864cb8d cli, facade: rename --ref-audio to --ref-wav, align with omnivoice convention 2026-05-14 15:46:46 +02:00
Pascal 6ad6a7db7a facade, abi: thin CLI on top of qwen_* public ABI, lock contract with C99 probe 2026-05-14 15:31:47 +02:00
Pascal 552aa93f98 refactor: ABI 2026-05-14 15:13:45 +02:00
Pascal eb48f33f09 utf8: portable Windows UTF-8 boundary for argv, fopen and CreateFile 2026-05-14 14:10:26 +02:00
Pascal 57d12ba4e5 ggml: sync from llama.cpp 2026-05-13 10:03:56 +02:00
Pascal d5f1e20c08 pipeline: zero-init qenc_host_ready, value-init PipelineTTS
The lazy-init flag started on stack garbage. When non-zero the encode
path skipped the codebook load and silently returned empty RVQ codes.
2026-05-11 18:27:06 +02:00
Pascal 7f532f1ed0 cli, pipeline: decode --ref-audio once at the CLI, pipeline takes a mono buffer
Clone mode used to read the same WAV twice (speaker encoder then codec
encoder), which failed silently on Windows where pipeline_codec_encode
returned empty on the second pass. PipelineTTSSynthesizeParams now takes
ref_audio_24k + ref_n_samples instead of a path. The CLI calls
audio_read_mono once, holds the buffer in a unique_ptr until synthesis
returns, and feeds the same pointer to both encoders.
2026-05-11 18:14:59 +02:00
Pascal d700ffea43 cli: --ref-text takes a file path instead of inline string content 2026-05-11 17:57:40 +02:00
Pascal eefb13043e tests logs 2026-05-11 16:27:12 +02:00
Pascal 32560ea597 talker, code-predictor: fused flash attention, fix Vulkan autoregressive decode 2026-05-11 15:29:24 +02:00
Pascal 42510fff59 tests logs 2026-05-11 13:38:21 +02:00
Pascal 530eed6ac5 loader, quantize: align GGUF on llama.cpp, conv kernels widened to F16 at load
GGUF norm matches llama.cpp policy: F32 master stays F32, BF16
variant keeps source BF16, K-quants fall back to F16 when kernel
rows do not align. No conv override in pick_type.

Conv kernels widen to F16 at load through gf_load_conv (12 sites).
qwen_load_ctw_f32 accepts BF16 source.

TODO upstream GGML: ggml_conv_1d and ggml_conv_1d_dw force F16 on
their im2col output, while conv_2d picks the kernel dtype. This
crashes F32 and BF16 kernels on CPU (im2col only handles F16) and
BF16 on Vulkan (mul_mat refuses BF16 on the operand the kernel
ends up on). Aligning conv_1d on conv_2d removes the workaround.
2026-05-11 12:42:54 +02:00
Pascal 59fda26827 tests logs 2026-05-11 07:23:36 +02:00
Pascal 0a7023bd0b talker, code predictor: persistent KV cache
Adds a per-layer K/V ring (kv-cache.h) backed by a dedicated backend
buffer, sized at init for max_seq_len positions. The talker holds a
4096 position cache (896 MB f32) for the LM context, the code
predictor a 16 position cache (~80 KB) reset every frame.

talker_forward splits into prefill (resets the cache and writes T
positions in one shot) and decode (appends one position, reads the
[0, cur_len+1) window). code_predictor_step does the same with a T=2
prefill plus 14 single token decodes.

Bit identical audio output, validated by sha256 against the pre KV
cache run on a 64 frame F32 reference seed=42. Walltime drops ~10%
on a single utterance ; the win scales with sequence length and
unlocks frame by frame streaming.
2026-05-11 06:44:39 +02:00
Pascal 05ecde271a convert: drop orphan encoder.sliding_window GGUF key 2026-05-11 05:48:47 +02:00
Pascal 9264b737a9 encoder: replicate pad on downsample, drop orphan sliding_window field 2026-05-11 05:43:06 +02:00
Pascal 7e01c71c58 clang-format 2026-05-10 22:20:47 +02:00
Pascal c3bd376338 encoder-transformer: pure causal mask, drop sliding window 2026-05-10 22:20:22 +02:00
Pascal 7b9435c886 clone: mode B fix, librosa to torchaudio resample, plus SEANet bisection tooling 2026-05-10 22:11:45 +02:00
Pascal 186ee91c70 ggml: sync from llama.cpp 2026-05-10 20:56:28 +02:00
Pascal 7e89929a70 fix speaker encoder ECAPA forward cossim 0.86 -> 0.996
mel-spk and mel-mag dumps in speaker-encoder-extract.h applied an extra
ggml_transpose plus cont before write. Raw ggml ne=(C, T) already
streams as numpy [T, C], so the transpose was inverting axes vs the
python upstream. Removed it.
MelMag 0.04 -> 0.999, MelSpk 0.92 -> 0.998

spk_conv1d_same passed ggml_im2col a kernel ne=(K, 1, IC, 1) and an
input ne=(T_pad, 1, IC, 1) with IC in ne[2]. But the im2col impl reads
IC = b->ne[1] when is_2D=false, so it saw IC=1, wrote OW*K floats into
a buffer declared for OW*IC*K floats, and mul_mat consumed 99% garbage.
Moved IC into ne[1] for both kernel and input, which makes the impl
read the real IC and writes a buffer coherent with the declared ne. The
permute and the retranspose after pad become unnecessary, dropped both.
SpkFrontend 0.74 -> 0.994, SpeakerEmb 0.86 -> 0.996

Adds ECAPA bisection infrastructure : 4 stage out params in
speaker_encoder_forward (frontend, block3, mfa, asp), codec encoder
intermediate dumps in pipeline-codec.cpp (seanet-out, enc-transformer
out, codec-pre-fsq), matching pytorch hooks in debug-clone-cossim.py.
2026-05-10 20:56:14 +02:00
Pascal acb75fca36 tests 2026-05-10 17:24:33 +02:00
Pascal 564b36ac90 example file for voice clone 2026-05-10 17:20:15 +02:00
Pascal 4feb286f04 tests 2026-05-10 16:43:58 +02:00
Pascal 8ca9622c70 add ggml submodule 2026-05-10 16:02:06 +02:00
Pascal add3f940a0 Initial release 2026-05-10 15:57:15 +02:00