Documents
Code documents
Scripts and text files you and the agent edit together.
A code document is a plain-text file, such as a Python script, a SQL query or a Markdown file. You, your teammates and the agent edit it together. Changes show live and save as you type.
Create one
- On the Documents tab, choose Code from the ⊕. Type a filename like
reconcile.pyand press Enter. - Drop text or code files onto the Documents tab, such as
.py,.sql,.mdor.txt. - Ask the agent to write a script or a config file.
Each dropped file becomes its own code document. See Creating and uploading.
The name sets the language
The extension in the title picks the colouring. A .py file reads as Python and a .sql file as SQL. A name with no extension shows as plain text.
To change the language, click the title and rename the file.
Editing
Undo reverses your own typing only. The agent's edits and your teammates' edits stay put.
A code document holds up to 1 MB. A warning appears as you get close.
Saving a file doesn't run it. Ask the agent to run a script, and it runs a copy in its own workspace.
Version history
- Choose Version history from the ⋯ menu. A bar opens at the bottom of the file.
- Click Save version to keep the current state.
- To go back, pick an earlier version from the list in that bar.
- Click Restore this version.
The agent's changes are saved as versions too. A restore first saves the current text as a version, so you can go back. Click Cancel to leave without changing anything.
On an agent shared with you as a viewer, you can browse versions but not restore them.
Download
The ⋯ menu downloads the file under its own name. Copy contents puts the whole file on your clipboard.
Mention the document in chat, such as "tidy up @reconcile.py". The agent edits that file in place instead of making a new one.

