1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
//! # Real-time API Module
//!
//! Provides real-time audio and video communication capabilities for the Zhipu AI API.
//! This module is designed for interactive applications that require low-latency
//! audio and video streaming.
//!
//! ## Features
//!
//! - **Audio Streaming** - Real-time audio input and output
//! - **Video Streaming** - Real-time video input and output
//! - **Low Latency** - Optimized for minimal communication delay
//! - **Interactive Communication** - Support for bidirectional audio/video calls
//!
//! ## Usage
//!
//! ```rust,ignore
//! use zai_rs::realTime::*;
//!
//! #[tokio::main]
//! async fn main() -> Result<(), Box<dyn std::error::Error>> {
//! let client = RealTimeClient::new(api_key);
//!
//! // Start an audio session
//! let session = client
//! .audio_session()
//! .model(RealTimeModel::Glm4Voice)
//! .build()
//! .await?;
//!
//! // Send audio data
//! session.send_audio(audio_bytes).await?;
//!
//! // Receive responses
//! while let Some(event) = session.next_event().await? {
//! match event {
//! RealTimeEvent::Audio(data) => {
//! // Handle audio response
//! },
//! RealTimeEvent::Text(text) => {
//! // Handle transcription
//! },
//! _ => {},
//! }
//! }
//!
//! Ok(())
//! }
//! ```
pub use *;
pub use *;
pub use *;
pub use *;