rag_chunk_file/
rag_chunk_file.rs

1use llamaedge::Client;
2
3#[tokio::main]
4async fn main() {
5    const SERVER_BASE_URL: &str = "http://localhost:10086";
6
7    let client = Client::new(SERVER_BASE_URL).unwrap();
8
9    let file_path = "tests/assets/paris.txt";
10    match client.rag_chunk_file(file_path, 1024).await {
11        Ok(chunks_response) => println!("{:#?}", chunks_response),
12        Err(e) => println!("Error: {}", e),
13    }
14}