cogito-claude

Crates.iocogito-claude
lib.rscogito-claude
version0.1.0
created_at2025-12-02 23:18:01.572482+00
updated_at2025-12-02 23:18:01.572482+00
descriptionAnthropic Claude client implementation for Cogito
homepage
repositoryhttps://github.com/mdippery/cogito
max_upload_size
id1962837
size81,748
Michael Dippery (mdippery)

documentation

https://docs.rs/cogito-claude

README

cogito-claude

cogito-claude is a provider for Anthropic Claude that adheres to the Cogito specification.

Usage

use cogito::client::{AIClient, AIRequest, AIResponse};
use cogito_claude::ClaudeModel;
use cogito_claude::client::{ClaudeClient, ClaudeRequest};
use hypertyper::prelude::*;

let auth = Auth::from_env("CLAUDE_API_KEY")?;
let factory = HttpClientFactory::new(env!("CARGO_PKG_NAME"), env!("CARGO_PKG_VERSION"));
let client = ClaudeClient::new(auth, factory);
let request = ClaudeRequest::default().model(ClaudeModel::Sonnet45).input("Write me a haiku.");
let response = client.send(&request).await?.result();

See the Cogito docs and Hypertyper docs for more information.

License

Cogito is licensed under the terms of the Apache 2.0 license. Please see the LICENSE file accompanying this source code or visit apache.org for more information on licensing.

Commit count: 0

cargo fmt