File Writer
Write a value from memory to a file on disk.
What it does
Takes a value from memory and writes it to a file path you specify. Can overwrite the file or append to it. Useful for producing reports, exports, log files, or simple persistence between runs.
The file is written from the AI Kit server's perspective. For on-premise installations, that is your server's filesystem. For cloud installations, it is a workspace-scoped storage area.
What you configure
| Field | What it controls | Required | Notes |
|---|---|---|---|
| File path | Full path of the file to write. | required | Must be reachable from the AI Kit server. |
| Encoding | Character encoding for text files. | optional | Defaults to UTF-8. |
| Content (memory input) | The data to write. | required | Pull from memory. Strings, JSON, or binary all work. |
| Append | When on, content is added at the end of the file instead of overwriting it. | optional | Off by default. |
📷 SCREENSHOT: The File Writer step with the path field, encoding selector, and the append toggle.
Example scenario
Daily export. A cron-triggered workflow queries a database for yesterday's data, formats it as CSV with an LLM Prompt or a dedicated step, and writes the CSV to /exports/sales-{{ date }}.csv on the server. A separate process picks the files up.
Recommendations
- ✅ Choose a dedicated directory for AI Kit outputs. Keeps cleanup simple.
- ✅ Use append mode for log-style files where the workflow runs many times per day.
- ✅ Include the date or job ID in the filename if the workflow runs more than once a day. Otherwise each run overwrites the previous one (unless you use append).
- ⚠️ Append mode does not add newlines. If you want one line per run, include
\nat the start of your content or build the line in a prior step. - ❌ Do not write to system-critical paths. Stick to a directory the AI Kit owns.
- ❌ Do not write secrets to disk. Use secured-field references inside the workflow instead.
What to do next
- To react to incoming files: Filesystem Watcher.
- For tabular output: Spreadsheet Append.