Asks a natural language question using one or more knowledge graphs and puts the result into a state variable.
Name | Type | Control | Default | Description | Options | Validation |
---|---|---|---|---|---|---|
Question | Text | - | - | The natural language question to ask. | - | - |
Use streaming | Text | - | yes | - |
| Allowed values: yes, no |
State Element | Text | - | - | State variable to store or stream the response into. Reference the state element directly, i.e. use “my_var” instead of ”@”. | - | - |
Graph Ids | Graph Ids | - | [] | IDs of the graphs to query. | - | - |
Use subqueries | Text | - | no | Enables LLM to ask follow-up questions to the knowledge graph. This improves answers, but may be slower. |
| Allowed values: yes, no |
Below are the possible end states of the block call.
Name | Field | Type | Description |
---|---|---|---|
Success | - | success | Successfully streamed the answer. |
Error | - | error | If the function raises an Exception. |
The Ask graph question block stores the answer to the question in a state variable that you set in the State Element
field.
Access the output of an Ask graph question block by referencing the state variable you defined. You can also access the output of an Ask graph question block using the @{result}
variable in the block that follows it in a blueprint.