-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Labels
samplesIssues that are directly related to samples.Issues that are directly related to samples.
Description
I can't seem to find basic information other than this reference on how to decode the data.
I see the response that I am getting as this:
{\n \"Candidates\": [\n {\n \"Index\": 0,\n \"Content\": {\n \"Role\": \"model\",\n \"Parts\": [\n \"I am doing well, thank you for asking! As a large language model, I don't experience emotions like humans do, but I am functioning optimally and ready to assist you. How can I help you today?\\n\"\n ]\n },\n \"FinishReason\": 1,\n \"SafetyRatings\": null,\n \"FinishMessage\": \"\",\n \"CitationMetadata\": null\n }\n ],\n \"PromptFeedback\": null,\n \"UsageMetadata\": {\n \"PromptTokenCount\": 5,\n \"CandidatesTokenCount\": 45,\n \"TotalTokenCount\": 50\n }\n}
Why does the element in Content.Parts[0]
have a string instead of an object? How can one decode this reliably? Why is there no documentation on this (or clear example for this)?
This makes me think the SDK is not idiomatic for golang.
Metadata
Metadata
Assignees
Labels
samplesIssues that are directly related to samples.Issues that are directly related to samples.