# Files

Files is a shared drive for a workspace. Every member can open it, upload to it and change what is in it. Sensei, Crons and chat session agents write to it too. Open it from the **Files** row under the workspace in the sidebar, beside **Crons**. The row is there for every workspace, also when the workspace has no files yet. It opens `/w/<slug>/files`.

What a chat session's agent or a Cron Run writes lands here too, in the **Sessions** and **Crons** folders. See [Files of a session](https://kosuke.ai/docs/sessions/files.md).

## Organize files

The page lists the open folder, folders first and then by name, with the columns Name, Size, Modified and Modified by. A breadcrumb above the list, such as Files › Designs, shows where you are. Press a crumb to go up.

An empty workspace shows an empty state with **Upload** and **New folder**.

| To | Do this |
| --- | --- |
| Make a folder | Press **New folder** and enter a name. |
| Add files | Press **Upload** and pick one or more files, or drop them onto the list. |
| Open | Press a folder to go into it, or a file to view it. |
| Download | In a row's **…** menu, choose **Download**. |
| Rename | In a row's **…** menu, choose **Rename**. |
| Move | In a row's **…** menu, choose **Move** and pick the folder, or the root. |
| Replace | In a row's **…** menu, choose **Replace** and pick the new file. It keeps the name and the place. |
| Delete | In a row's **…** menu, choose **Delete**, then confirm. A line under the list says it was deleted. |

A name is unique in its folder, ignoring case. A name holds 1 to 255 characters, cannot contain `/`, and cannot be `.` or `..`. A folder cannot move into itself or into one of its own subfolders.

## Sessions and Crons

Two folders hold what agents write. They sit among your other folders, sorted with them.

| Folder | What is inside |
| --- | --- |
| Sessions | One folder per repository, then one per chat session, holding the files that session's agent wrote. See [Files of a session](https://kosuke.ai/docs/sessions/files.md). |
| Crons | One folder per Cron, then one per run, named after when it started, such as "31 Oct 2026, 6:00 AM". See [Crons](https://kosuke.ai/docs/automate/crons.md). |

Sensei creates and keeps these folders, so their menu offers only **Open**. They cannot be renamed, moved or deleted, and nothing can be created, uploaded or moved into them. A session's own folder is the one exception: it takes uploads and files you move there, and it shows **Upload**.

The QA Report and a session's **QA evidence** folder are locked. They show a lock icon with the tooltip "Kept with the test run". Their menu offers only **Open** and **Download**, and Sensei alone changes them.

Every other file an agent wrote is yours to rename, move, replace or delete. The session or run keeps listing it wherever you move it.

- **Delete** removes the file from Files and takes its content with it. The session's or run's page keeps a row that says who deleted it and when.
- **Replace** stores your file as a new version. The session's or run's page says who replaced it. The version the agent wrote is not kept.

When a session, Cron, run or repository is deleted, its files and folders stay here as ordinary content, and members can manage them.

## Upload and replace

A file can be of any type, up to 25 MB. Sensei keeps the current version only. Each replace counts the file's version up, and the list and the viewer show who changed it last and when.

If an upload brings a name that is already in the folder, Sensei asks once, for every clash, whether to replace those files. Say no and they stay as they were. Files over 25 MB are left out, and one message names them. The other files in the same upload are stored.

## View a file

Press a file to open it on the page.

| File | What you see |
| --- | --- |
| Markdown | Formatted text |
| HTML | The page, in an isolated frame. It cannot read your Sensei login or call the platform. |
| PNG, JPEG, GIF, WebP | The picture |
| MP4, WebM | A player |
| PDF | **Open in new tab** and **Download** |
| Other text | Plain text |
| Anything else, and SVG | **Download** only |

An HTML file over 1 MB offers **Download** only. The viewer also shows the version and who changed the file last.

## Link to a file

The address bar holds `?folder=<id>` or `?file=<id>` for what is open. Copy it to link to that folder or file. The link uses the id, so it keeps working after a rename or a move. Whoever follows it needs to be a member of the workspace. A link that Sensei or an agent writes in a reply lands on the same page.

## Let agents use Files

Agents reach Files with `kosuke files`. Sensei, Crons and chat session agents can list, read, write, create folders and move. Their instructions tell them not to delete, and to replace only files they wrote in that work or that you asked them to change. These are instructions, not a limit: an agent's credential reaches the delete command too. Only the locks above refuse an agent, as they refuse everyone. A write to a name that exists replaces that file. A write by an agent that no member started, such as a cron whose creator left, shows "Agent" in **Modified by**.

An agent writes by path, and the folders on the path are created. For example, from a chat session:

```bash
kosuke files set <workspaceId> --path notes/plan.md --text "# Plan"
```

The command prints the item's `url`, which opens it in Files. See [Sensei CLI](https://kosuke.ai/docs/interfaces/cli.md#files) for every command.

### Prototypes

Sensei writes a prototype as an HTML file in the Files of the workspace the work is about. When it is unclear which workspace, Sensei asks. Variants are sibling files in a folder, such as `prototypes/board/a-columns.html` and `prototypes/board/b-rows.html`. Sensei's reply links each file as a file card, and the card opens the file here. See [Prototypes](https://kosuke.ai/docs/automate/sensei.md#prototypes).

To build from a file, put it on a Backlog ticket. The ticket points at the file instead of copying it, and its agent reads the current version when the session starts. See [Put a file on a ticket](https://kosuke.ai/docs/sessions/files.md#put-a-file-on-a-ticket).

## Personal Files

Your personal Files belong to you and to no workspace. Only you see them: no teammate, and no workspace's Files, ever lists them. Open them from the **Files** item under **Search** in the sidebar, at `/personal/files`. The page works like a workspace's Files, with the same folders, uploads, viewer, limits and `?folder=` and `?file=` links, and the same name may be used in a workspace and in your personal Files.

Sensei and your agents use them with `kosuke files`: Sensei, a chat session agent working on a message you sent, a Cron Run of a Cron you created, and the Slack agent answering you. They list, read, write, create folders and move, and are told not to delete, as in a workspace. An agent that no member stands behind cannot reach them, and neither can an AI app you connected over [MCP](https://kosuke.ai/docs/interfaces/mcp.md). Prototypes still go to a workspace's Files, where your teammates can open them. See [Sensei CLI](https://kosuke.ai/docs/interfaces/cli.md#user-files).

Deleting your account deletes your personal Files.

## Limits

- Every member of the workspace sees and changes every file of its Files. Keep what is yours alone in your personal Files.
- There is no in-app editor. To change a file, replace it.
- There is no trash. A deleted file or folder is gone, and only a file an agent wrote leaves a row on its session's or run's page.
- Sensei keeps no earlier versions, and Files has no search and no storage quota.
- A superadmin who is not a member of the workspace cannot open its Files.

## Next steps

- [Sensei](https://kosuke.ai/docs/automate/sensei.md)
- [Files of a session](https://kosuke.ai/docs/sessions/files.md)
- [Sensei CLI](https://kosuke.ai/docs/interfaces/cli.md)
