Wire up Valyu Answer (search-grounded answers) with the Python SDK.
Basic usage
Common patterns
Structured output
Pass a JSON schema tostructured_output and response.contents comes back as a structured object (a dict) instead of a string. Detect it with isinstance(response.contents, dict):
Streaming
Setstreaming=True to receive the answer progressively. The method returns a generator yielding typed chunks:
Reference
Parameters
Parameters
query (str, required) - the question to answer.Response format
Response format

