accept model

This commit is contained in:
bel
2026-03-22 20:34:23 -06:00
parent 00f22caf59
commit ee273ff215

View File

@@ -27,6 +27,8 @@ func main() {
func run(ctx context.Context) error {
fs := flag.NewFlagSet(os.Args[0], flag.ContinueOnError)
n := fs.Int("n", 1, "loops")
model := fs.String("m", "gemini-2.5-flash", "model to use")
if err := fs.Parse(os.Args[1:]); err != nil {
return err
}
@@ -105,7 +107,7 @@ For the city {{.City}}, answer the following descriptors '1' for true or '0' for
for i := 0; i < *n; i++ {
result, err := client.Models.GenerateContent(
ctx,
"gemini-2.5-flash",
*model,
genai.Text(w.String()),
nil,
)