Skip to content

elcoosp/hindsight-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

hindsight-client

Rust HTTP client for the Hindsight agent memory system.

Usage

use hindsight_client::HindsightClient;

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let client = HindsightClient::new("http://localhost:8888")?;
    client.retain("my-bank", "Rust is awesome", None, None).await?;
    let memories = client.recall("my-bank", "Rust", Some(5)).await?;
    for mem in memories {
        println!("{} (score: {})", mem.content, mem.score);
    }
    Ok(())
}

License

MIT

About

Hindsight HTTP client

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages