8 releases
0.1.7 | Jan 9, 2024 |
---|---|
0.1.6 | Aug 3, 2023 |
#555 in Machine learning
31 downloads per month
8KB
72 lines
gpt_text_wrapper
This is a encaplusate version of openai version called "fieri" . The basic function of this module is to reduce the excutation cycles such as nlp related tasks.
structure
gpt_text
|------------- src
|-------------lib.rs
|------------- cargo.toml
module
-> openai
code
use gpt_text::openai;
let mut openc : _ = openai::new("cat translate into japanese".to_string(), "".to_string(), "cat".len().try_into().unwrap());
let wrap_gpt : _ = openc.openai_text_wrapper(openai_apikey).await{
Ok(text) => text,
Err(err) => panic!("Error = {:?}", err),
};
println!("Response = {:?}", wrap_gpt);
install
cargo add gpt_text
documentation
cargo doc --open
Dependencies
~11–24MB
~337K SLoC