Skip to content

File Cards & Artifact Panel

Files appear in the chat as a card instead of a block of text. Clicking it opens the artifact panel — a window on the right-hand edge that overlays the chat.


Appears automatically as soon as an agent reads or creates a file. Survives a page reload.

┌────────────────────────────────────────────┐
│ [Icon] filename.md [✎ Open] │
│ /path/to/filename.md · 5.4 KB │
└────────────────────────────────────────────┘
ElementMeaning
Icon (left)Document symbol for text files · different symbol for PDF
Action (right)Pencil = open for editing · Eye = open for viewing (PDF)
“partial” markerOnly an excerpt was loaded (very large file) — editing disabled

┌─ ⇔ ────────────────────────────────────────┐
│ filename.md [Edit|Preview] [×] │
│ /path/to/filename.md │
│ ┌─────────────────────────────────────────┐ │
│ │ │ │
│ │ Editor or Preview or PDF │ │
│ │ │ │
│ └─────────────────────────────────────────┘ │
│ sha256 a1b2c3d4e5f6… [Save] │
└─────────────────────────────────────────────┘
ElementDescription
Handle on the left edge (⇔)Drag to resize; the width is remembered. Full width on mobile, no handle.
Edit | PreviewMarkdown and Mermaid only. Preview is the default and always renders the current editor state.
×Close the panel. Unsaved changes are lost.
sha256 lineChecksum of the last read file state.
SaveEnabled only when there are unsaved changes.

The composer stays usable above the panel; the panel keeps its lower area clear for it.

File typeView
.md, .markdownPreview (rendered Markdown) ↔ editor
.mmd, .mermaidPreview (rendered diagram with zoom) ↔ editor
.pdfViewer: scrollable pages, zoom buttons, selectable and copyable text. No editing. Content readable on request (see below).
all other text filesEditor only, no toggle

Opening a file re-reads it from disk. On save, Ontheia checks whether it changed in the meantime:

CaseBehaviour
File unchangedWritten; the previous version is moved to .trash/
File changed externallyRed notice with a Reload button — no overwrite
Only a partial view loadedEditor locked, saving not possible

Every code block in an answer — including a rendered Mermaid diagram — carries a pencil icon in its header: “Edit in panel”.

Flow: click the pencil → the content opens as a draft in the panel (titled “Draft”) → edit → enter a path in the field at the bottom → Save as…

SituationBehaviour
SuccessThe file is created, a file card appears in the chat, and the panel switches to normal file mode
File already existsNotice to pick a different name — the existing file is not overwritten
Path outside the permitted directoriesNotice listing the allowed root directories
Panel closed without savingNothing is created; the code block in the message stays unchanged

The path field is prefilled with the directory used last.


  • Every request carries a compact list of this chat’s files (path, id, checksum) — not their content.
  • After you save in the panel, the changed text is passed to the agent verbatim, with the instruction not to rephrase it.
  • File content is loaded deliberately when needed.

Limitation: Changes made outside Ontheia, directly on the filesystem, are only noticed once the agent reads the file again. Ask it explicitly to do so in that case.

The agent never sees a PDF’s bytes — only its name, path, and size. When asked about the content, Ontheia converts the PDF to text and hands that over.

What the user asksWhat happens
”open/show the PDF”Card in the chat, viewer in the panel — no conversion
”what does the PDF say about…”Converted to text; the agent answers from it

Conversion runs only on the first content question and is cached afterwards, so follow-ups in the same chat are instant. Replacing the file triggers a fresh extraction.

Limitation: Extraction uses the text layer. Scanned or image-only PDFs have none — the agent will report it cannot read the content (OCR would be required). For multi-column pages, diagrams, and tables the layout is lost: the information is complete but arranged differently from the original.