diff options
| author | Jeff Carr <[email protected]> | 2025-04-12 11:27:04 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-04-12 11:27:04 -0500 |
| commit | 605ebd6c8b46c6312c0cd0fdc337e42813f9b3ad (patch) | |
| tree | c4b3cabec1095976aeedc1d11c77cd7aa09d973b /genai/aistudio.go | |
| parent | 1b0344899fd4794bd9417454e2d03fe2bcc98c24 (diff) | |
ai code builds kindav0.0.53
Diffstat (limited to 'genai/aistudio.go')
| -rw-r--r-- | genai/aistudio.go | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/genai/aistudio.go b/genai/aistudio.go index ab6ccf2..3fda5ec 100644 --- a/genai/aistudio.go +++ b/genai/aistudio.go @@ -6,7 +6,8 @@ import ( "log" "os" - "github.com/google/generative-ai-go/genai" + // "github.com/google/generative-ai-go/genai" + "cloud.google.com/go/ai/vertexai/genai" "google.golang.org/api/option" ) @@ -33,15 +34,8 @@ func main() { }, } - // Create user content - userContent := &genai.Content{ - Parts: []genai.Part{ - genai.Text("what is the current version of forge on the webpage?"), - }, - } - // Stream content generation - iter := model.GenerateContentStream(ctx, []*genai.Content{userContent}...) + iter := model.GenerateContentStream(ctx, genai.Text("what is the current version of forge on the webpage?")) for { resp, err := iter.Next() if err != nil { |
