You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: boxed_future.rs
    path of file: ./repos/async-openai/async-openai/tests
    
    the code of the file until where you have to start completion: use futures::future::{BoxFuture, FutureExt};
use futures::StreamExt;

use async_openai::types::{CompletionResponseStream, CreateCompletionRequestArgs};
use async_openai::Client;

#[tokio::test]
async fn boxed_future_test() {
    fn interpret_bool(token_stream: &mut CompletionResponseStream) -> BoxFuture<'_, bool> {
        async move {
            while let Some(response) = token_stream.next().await {
  
    
async fn boxed_future_test() {
    fn interpret_bool(token_stream: &mut CompletionResponseStream) -> BoxFuture<'_, bool> {
        async move {
            while let Some(response) = token_stream.next().await {
                match response {
                    Ok(response) => {
                        let token_str = &response.choices[0].text.trim();
                        if !token_str.is_empty() {
                            return token_str.contains("yes") || token_str.contains("Yes");
                        }
                    }
                    Err(e) => eprintln!("Error: {e}"),
                }
            }
            false
        }
        .boxed()
    }

    let client = Client::new();

    let request = CreateCompletionRequestArgs::default()
        .model("text-babbage-001")
        .n(1)
        .prompt("does 2 and 2 add to four? (yes/no):\n")
        .stream(true)
        .logprobs(3)
        .max_tokens(64_u16)
        .build()
        .unwrap();

    let mut stream = client.completions().create_stream(request).await.unwrap();

    let result = interpret_bool(&mut stream).await;
    assert!(result);
}