> For the complete documentation index, see [llms.txt](https://docs.soda.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.soda.io/soda-documentation/soda-ai/unstructured-input.md).

# Unstructured input

Attach images, PDFs and text files to a Soda AI chat message so Soda AI can read them alongside your question.

Attach a file to a Soda AI chat message and Soda AI reads it together with your question. Use it for context that does not live in a dataset: a requirements document, a screenshot of a report, a CSV export or a SQL query.

For example, you can:

* Attach a PDF with data requirements and ask Soda AI to turn them into checks on a contract.
* Attach a screenshot of a failing report and ask what could explain the numbers.
* Attach a CSV sample or a SQL query and ask which checks would catch the problems in it.

## Attach a file

You can add files to a message in three ways:

* Click the **paperclip** button in the chat input and pick one or more files.
* Paste a file or an image into the chat input.
* Drag and drop files anywhere onto the Soda AI chat panel. Dropping files on the collapsed chat bar opens the panel and attaches them.

<figure><img src="https://1123167021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FA2PmHkO5cBgeRPdiPPOG%2Fuploads%2FHXh3D4WpGzoB4v1HFGds%2Fimage.png?alt=media&#x26;token=b8b41733-0e3f-4c04-a842-05e3159dde09" alt="The Soda AI chat bar at the bottom of the page, with the paperclip button next to the send button"><figcaption><p>The paperclip button in the chat input</p></figcaption></figure>

Attached files appear as tiles above the input. Remove a file with the **x** on its tile. You can send a message with files and no text: Soda AI uses the first file name as the conversation title.

<figure><img src="https://1123167021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FA2PmHkO5cBgeRPdiPPOG%2Fuploads%2FN6SQsNKLegRZzw5azuWr%2Fsoda-ai-attach-composer.png?alt=media" alt="A CSV file attached in the chat input, shown as a tile with its name and size above the typed question"><figcaption><p>An attached file, ready to send with the question</p></figcaption></figure>

After you send the message, the file tile stays above your question in the conversation.

<figure><img src="https://1123167021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FA2PmHkO5cBgeRPdiPPOG%2Fuploads%2FU09Mj3XRuLSk0QlrN22e%2Fsoda-ai-attach-sent.png?alt=media" alt="A sent chat message with the attached CSV file tile above the question"><figcaption><p>The attached file in the conversation</p></figcaption></figure>

Soda AI answers from the file content. For example, attach a CSV sample and ask for a data contract: Soda AI points out the problems it finds in the rows and proposes contract YAML with a check for each one, ready to copy or publish directly from Soda AI.

<figure><img src="https://1123167021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FA2PmHkO5cBgeRPdiPPOG%2Fuploads%2F5FNjlrFuce90HppZPbaL%2Fimage.png?alt=media&#x26;token=39e47c65-8f87-4858-9d01-6a79c11dffe4" alt="Soda AI answering a question about an attached CSV file with a proposed data contract in YAML"><figcaption><p>A proposed contract for the attached CSV</p></figcaption></figure>

### Supported files

| Kind      | Formats                                                     |
| --------- | ----------------------------------------------------------- |
| Images    | PNG, JPEG, GIF, WebP                                        |
| Documents | PDF                                                         |
| Text      | TXT, LOG, CSV, TSV, Markdown, YAML, JSON, NDJSON/JSONL, SQL |

Soda checks the content of each file, not only its extension. A file whose content does not match its type, for example a renamed executable, is refused.

## Size limits

| Limit                                | Value  |
| ------------------------------------ | ------ |
| Files per message                    | 3      |
| Size of one file                     | 5 MB   |
| Total size of a message's files      | 8 MB   |
| Size of one text file                | 512 KB |
| Total size of a message's text files | 512 KB |

Before sending, Soda resizes large images: an image wider or taller than 2000 pixels, or larger than 2 MB, is converted to a JPEG that fits within 2000 pixels. GIFs are sent as a still image.

When a file breaks a limit or its type is not supported, Soda AI does not attach it and tells you which file was refused and why.

## File handling and privacy

* The file content is sent to the model provider together with your message, so the model can read it. Soda AI can refer back to an attached file in follow-up questions in the same conversation.
* Soda Cloud does not store your files. Your browser keeps the file name and a small preview thumbnail in the conversation history, in local storage, like the rest of your [conversations](/soda-documentation/soda-ai.md#conversations-and-history).
* Soda AI reads only the files you attach. Attach only content you are allowed to share with Soda AI.

{% hint style="warning" %}
Do not attach files that contain personal data, credentials or other sensitive information unless your organization allows sharing them with the model provider.
{% endhint %}

> Learn more about [Soda AI security & privacy measures](/soda-documentation/soda-ai.md#soda-ai-security-and-privacy-measures).

<br>

***

{% hint style="info" %}
You are **not logged in to Soda** and are viewing the default public documentation. Learn more about [Licensing & documentation access](/soda-documentation/reference/documentation-access-and-licensing.md).
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.soda.io/soda-documentation/soda-ai/unstructured-input.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
