Rename client and refactors dialog

This commit is contained in:
2024-02-07 20:19:11 +00:00
parent 4f49ec8478
commit 5ab9f353bc
5 changed files with 38 additions and 35 deletions

View File

@@ -11,7 +11,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
let project_id = std::env::var("PROJECT_ID")?;
let location_id = std::env::var("LOCATION_ID")?;
let vertex_client = VertexClient::new(
let gemini = GeminiClient::new(
authentication_manager,
api_endpoint,
project_id,
@@ -19,7 +19,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
);
let prompt = "What is the airspeed of an unladen swallow?";
let result = vertex_client.prompt_text(prompt, None).await?;
let result = gemini.prompt_text(prompt, None).await?;
println!("Response: {}", result);
Ok(())