Context
I am using google gemini-api.
Using their Python SDK
Goal
I am trying to generate multiple possible responses for a single prompt according to the docs and API-reference
Expected result – multiple response for a single prompt
Actual result – single response
Code I have tried
# ... more code above
model = genai.GenerativeModel(model_name="gemini-1.5-pro-latest", system_instruction=system_instruction)
response = model.generate_content("What is the meaning of life?")
resps = response.candidates
resps
is alist
which should contain more than 1 response. But there is only 1 response inside it.- The prompt used here is a demo prompt. But the outcome is same for any input string.
If any more information is needed please ask in the comments.