> ## Documentation Index
> Fetch the complete documentation index at: https://docs.baserun.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Variables

You can store pairs of input variables and output datasets in Baserun Datasets, which can be utilized for fine-tuning and evaluation in the future.

```python theme={null}
completion.variable(key: str, value: str, metadata: Optional[Dict] = None) -> Tag:
```

### Arguments

{" "}

<ParamField path="key" type="string" required />

<ParamField path="value" type="string" required />

<ParamField path="metadata" type="object" />

### Instructions

```python theme={null}
from baserun import OpenAI

def example():
    client = OpenAI()
    city = input()
    completion = client.chat.completions.create(
        model="gpt-4o",
        temperature=0.7,
        messages=[
            {
                "role": "user",
                "content": f"What are three activities to do in {city}?"
            }
        ],
    )
    completion.variable("city", city)
```
