Skip to content

fix(ml): rubato 1.0.1 API upgrade and StreamChunk wrapping (#1858)#2044

Merged
bug-ops merged 2 commits intomainfrom
fix-1858
Mar 20, 2026
Merged

fix(ml): rubato 1.0.1 API upgrade and StreamChunk wrapping (#1858)#2044
bug-ops merged 2 commits intomainfrom
fix-1858

Conversation

@bug-ops
Copy link
Owner

@bug-ops bug-ops commented Mar 20, 2026

Summary

Fixes two compile errors when running cargo check --features ml:

  1. rubato 1.0.1 API migration in candle_whisper.rs
  2. StreamChunk type wrapping in candle_provider.rs

Changes

  • candle_whisper.rs: Updated resample() for rubato 1.0.1 API (SincFixedIn → Async::new_sinc)
  • candle_provider.rs: Wrapped string chunks in StreamChunk::Content() enum
  • Cargo.toml: Added audioadapter-buffers 2.0 (required by rubato 1.0.1, gated on candle feature)
  • CHANGELOG.md: Documented under [Unreleased] → Fixed

Testing

  • cargo check --features ml passes
  • ✅ All pre-commit checks pass (fmt, clippy, tests)
  • ✅ 6014 tests pass, 15 skipped, 0 failures
  • ✅ Code review approved by rust-code-reviewer

Type

Bug fix (P0 blocking)

Fixes #1858

… provider

Fixes two compile errors when building with --features ml:
- Updated candle_whisper.rs resample() for rubato 1.0.1 API: SincFixedIn removed,
  replaced with Async::new_sinc() with FixedAsync::Input. Output extraction via
  InterleavedOwned::take_data() for type compatibility.
- Wrapped ChatStream output in StreamChunk::Content pattern in candle_provider
  to match type requirements (String -> StreamChunk enum).
- Added audioadapter-buffers 2.0 dependency (gated on candle feature) required
  by rubato 1.0.1 for buffer I/O via Adapter trait.

All checks pass: cargo check --features ml, fmt, clippy, 6014 tests.
@github-actions github-actions bot added bug Something isn't working size/S Small PR (11-50 lines) documentation Improvements or additions to documentation llm zeph-llm crate (Ollama, Claude) rust Rust code changes dependencies Dependency updates and removed size/S Small PR (11-50 lines) labels Mar 20, 2026
@bug-ops bug-ops enabled auto-merge (squash) March 20, 2026 14:08
@github-actions github-actions bot added the size/S Small PR (11-50 lines) label Mar 20, 2026
@bug-ops bug-ops merged commit bd4cefe into main Mar 20, 2026
25 checks passed
@bug-ops bug-ops deleted the fix-1858 branch March 20, 2026 14:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working dependencies Dependency updates documentation Improvements or additions to documentation llm zeph-llm crate (Ollama, Claude) rust Rust code changes size/S Small PR (11-50 lines)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(ml): candle/rubato compile errors with --features ml (pre-existing)

1 participant