# Set/Get Variable

If you are running a Custom Function, or LLM Chain, you might want to reuse the result in other nodes without having to recompute/rerun the same thing again. You can save the output result as a variable, and reuse it for other nodes that is further down the flow path.

<figure><img src="/files/ptIKC783Uj4zuyhRcuGG" alt=""><figcaption></figcaption></figure>

### Set Variable

Taking inputs from any node that outputs `string, number, boolean, json, array,` we can assign a variable name to it.

<figure><img src="/files/yr9m6tFmP5k6s9ruF7EF" alt="" width="270"><figcaption></figcaption></figure>

### Get Variable

You can get the variable value from the variable name at a later stage:

<figure><img src="/files/655iRmgifCRn2WYgq8fk" alt="" width="563"><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.flowiseai.com/integrations/utilities/set-get-variable.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
