GraphConfig and a prompt, receive an updated GraphConfig.
Methods
generateGraph
Processes the request and returns the final result. Internally handles streaming and collects the response.generateGraphStream
Returns an async iterator that yields events as they arrive.Parameters
Metadata
Response
The response is validated with Zod. Invalid responses throw an error.
Invocation effort and chart narrative
metadata.effort selects how heavy the invocation is: it is stored on the request, forwarded into agent invocations (including tools that run nested agents), and drives defaults when you do not send storytellingEffort.
For chart generation, the chart agent still consumes a storytelling level (none / low / medium / high). The server sets that level as follows:
- If you send only
effort, the chart storytelling level is derived fromeffort(defaulteffortismedium, which matches the narrative band you previously got from omitting metadata or using the old default). - If you send only
storytellingEffort(deprecated), the chart uses that value directly and the server inferseffortfor the rest of the stack. - If you send both,
storytellingEffortwins for the chart so existing explicit chart settings keep working;effortstill applies everywhere else.
none value on effort; to drop narrative fields in the client, use storytellingOptions on GenerateGraphParams (see StorytellingOptions).
Basic Usage
With Progress Callback
Use theonProgress callback to show real-time progress without full streaming:

