Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions crates/audio/src/async_ring.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ use std::time::{Duration, Instant};

pub(crate) struct PollNextSample {
pub(crate) poll: Poll<Option<f32>>,
#[allow(dead_code)]
pub(crate) did_pop_chunk: bool,
}

Expand Down Expand Up @@ -66,6 +67,7 @@ where
self
}

#[allow(dead_code)]
pub(crate) fn has_buffered_samples(&self) -> bool {
self.read_idx < self.read_len
}
Expand Down
2 changes: 2 additions & 0 deletions crates/audio/src/rt_ring.rs
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ where
}
}

#[allow(dead_code)]
pub(crate) fn convert_and_push_to_ringbuf<T, P>(
samples: &[T],
scratch: &mut [f32],
Expand Down Expand Up @@ -143,6 +144,7 @@ where
}
}

#[allow(dead_code)]
pub(crate) fn push_f32_to_ringbuf<P>(data: &[f32], producer: &mut P) -> PushStats
where
P: Producer<Item = f32>,
Expand Down
9 changes: 4 additions & 5 deletions crates/owhisper-client/src/adapter/cactus/batch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -302,14 +302,13 @@ impl<S> SseParserState<S> {
&mut self,
response: StreamResponse,
) -> Option<Result<StreamingBatchEvent, Error>> {
if let StreamResponse::TranscriptResponse { channel, .. } = &response {
if channel
if let StreamResponse::TranscriptResponse { channel, .. } = &response
&& channel
.alternatives
.first()
.is_some_and(|a| !a.words.is_empty())
{
self.saw_segment_words = true;
}
{
self.saw_segment_words = true;
}

let segment_end = match &response {
Expand Down
1 change: 1 addition & 0 deletions crates/transcribe-proxy/src/relay/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ impl<S> WebSocketProxyBuilder<S> {
}
}

#[allow(clippy::too_many_arguments)]
fn build_from(
request: ClientRequestBuilder,
control_message_types: HashSet<&'static str>,
Expand Down
3 changes: 3 additions & 0 deletions crates/transcribe-proxy/src/relay/handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ pub struct WebSocketProxy {
}

impl WebSocketProxy {
#[allow(clippy::too_many_arguments)]
pub(crate) fn new(
upstream_request: ClientRequestBuilder,
control_message_types: Option<ControlMessageTypes>,
Expand Down Expand Up @@ -117,6 +118,7 @@ impl WebSocketProxy {
.into_response()
}

#[allow(clippy::too_many_arguments)]
async fn run_proxy_loop(
client_socket: WebSocket,
upstream_stream: WebSocketStream<MaybeTlsStream<tokio::net::TcpStream>>,
Expand Down Expand Up @@ -209,6 +211,7 @@ impl WebSocketProxy {
false
}

#[allow(clippy::too_many_arguments)]
async fn run_client_to_upstream(
mut client_receiver: ClientReceiver,
mut upstream_sender: UpstreamSender,
Expand Down
Loading