Browse · Help archive
Getting Started
Account & Security
Billing & Plans
Organization & Roles
QA-QC
Project Matrix
File Management
Project Members
Access Requests
Project Setup
Attribute Extract
Attribute Import
Scheduled Jobs
Power BI Analytics
Foreman Assistant
Permissions Graph

Draft · This article is being updated. Content may change.

  1. Archive
  2. /
  3. Foreman Assistant
  4. /
  5. Uploading Files to the Foreman Assistant

Uploading Files to the Foreman Assistant

Learn how to attach and manage files in the Foreman Assistant, including upload methods, limits, supported formats, and how attachments link to your messages.

How to attach a file

Three ways, all in the composer:

  1. Click the paperclip icon at the left of the text area to open a native file picker.
  2. Drag-and-drop — drag files from your desktop or another app anywhere onto the chat pane. A dashed blue overlay appears while you hover ("Drop files to attach — PDF, Word, Excel, PowerPoint, text & code files"). Dropping unsupported types triggers a short red notice ("N files were ignored — unsupported type.") instead of a silent failure.
  3. Upload up to 10 files per message. Past that, the upload is rejected with a "too many attachments" error.

Uploaded files appear as chips above the text area. Each chip shows a thumbnail (for images), a file icon (for documents), the filename, size, and an × to remove it before sending.

Attachments are associated with the user message you send them with. Removing a chip before sending deletes the uploaded file from storage. Once sent, attachments are tied to the message permanently unless the message is deleted.

Supported file types

The Assistant reads attachments as text via type-specific parsers — Excel via ClosedXML / ExcelDataReader, Word and PowerPoint via OpenXml, PDFs via PdfPig with OCR fallback for scanned pages.

Category Extensions How the Assistant reads it
Images .jpg, .jpeg, .png, .webp, .gif Filename hint in the prompt; inline preview in the chat (vision content blocks coming in a future release).
PDFs .pdf First 20 pages of extracted text are inlined (capped at 256 KB). Tesseract OCR runs as a fallback for scanned pages. Password-protected PDFs are rejected with a password_protected error.
Excel .xlsx, .xls Sheet content read into a structured text block — sheet names, headers, and rows. Legacy .xls is parsed via ExcelDataReader; .xlsx via ClosedXML.
Word .docx Body paragraphs and table cells are extracted in document order.
PowerPoint .pptx Slide titles and body text are extracted in slide order — useful for deck reviews and briefing summaries.
Tabular text .csv, .tsv Inlined as plain text into the prompt.
Text & markup .txt, .md, .json, .xml, .yml, .yaml, .log, .html, .htm, .css, .ini, .toml, .conf Inlined as UTF-8 text. Great for configs, logs, schemas, and notes.
Code .cs, .ts, .tsx, .js, .jsx, .py, .go, .java, .rb, .sql, .sh, .ps1, .razor, .cshtml, .vue Inlined as UTF-8 text — paste a script or component and ask the Assistant to explain, refactor, or generate tests.

Unsupported file types are rejected at upload with an unsupported_type error. Anything that does parse but produces no extractable content returns an empty result with a warning, not a hard failure.

Tip. You don't need to upload files that already live in an APS project. Ask the Assistant directly — it has a read_file_content tool that fetches and extracts text for any supported file via its item ID, with the same 256 KB cap and paging params for large PDFs and spreadsheets.

Per-attachment size limits

Size caps are enforced server-side and vary by your tenant's plan:

Tier Max per attachment
Business 25 MB
Enterprise 100 MB
Legacy tiers 10 MB

If you hit the cap, the upload is rejected with file_too_large and the actual byte cap is returned so the UI can tell you what's allowed.

PDF text extraction

When you attach a PDF, Foreman runs it through the same text-extraction pipeline used by the QA/QC engine (PdfPig with Tesseract OCR fallback for scanned pages). The AI receives:

  • A header line like [Attachment: drawings.pdf (application/pdf)].
  • The extracted text from the first 20 pages, truncated at 256 KB of extracted content.
  • Each page prefixed by a --- Page N --- marker.

That's usually enough for title-block questions, review comments, or short reports. For very long PDFs, summarise or pre-split the document before attaching.

Office document parsing

  • Excel (.xlsx, .xls) — every sheet is iterated and serialised into a structured text block. The Assistant sees sheet names, header rows, and per-row cell values up to the size cap. Formulas are read as their evaluated value. Legacy .xls files use ExcelDataReader; modern .xlsx uses ClosedXML.
  • Word (.docx) — body paragraphs and table cells are extracted in document order. Headers, footers, and tracked changes are not yet inlined.
  • PowerPoint (.pptx) — slide titles and body text are extracted in slide order. Speaker notes are not yet inlined.
  • PDF (.pdf) — text-based pages extract directly; scanned pages fall back to Tesseract OCR (15 languages). Password-protected PDFs are rejected with password_protected.

CSV, text & code inlining

CSV, TSV, plain-text, markup (HTML/CSS/XML/JSON/YAML/TOML/INI/Conf), and code files are read as UTF-8 and inlined directly into the user message (up to 256 KB per file). Binary content is not decoded.

Storage quota

Attachment bytes roll into your tenant's shared storage quota alongside Attribute Extract exports, File Search exports, and stored QA check files. Check your current usage from the Storage page — the AI Chat breakdown shows total MB used by chat attachments across all users in your tenant.

Retention

By default, attachments are kept forever — they're tied to the message they were sent with, and deleting the message (or the whole conversation) cleans them up.

If you want a stricter auto-retention, set a per-user retention period via Account → Manage (coming via the AiChatAttachmentRetentionDays setting). Passing -1 means "never auto-delete"; any positive integer is the number of days a file is retained after its message is sent.

Deleting attachments

Three ways:

  1. Before sending — click the × on a chip in the composer. The file is removed from storage immediately.
  2. After sending — delete the entire user message (Trash icon in the message bubble on hover). All attachments on that message are cascaded.
  3. Delete the conversation — removes the session and every attachment linked to it.

Downloading an attachment

Attachments rendered on a past message have a download arrow icon next to the filename — click to get the original file back. Images in user messages render as inline thumbnails you can click to view full size.

Troubleshooting

  • storage_quota_exceeded — your tenant's storage pool is full. Clean up older Attribute Extracts, File Search exports, or chat attachments, or ask your org admin to upgrade the plan.
  • too_many_attachments — you've got 10 pending attachments on the current (unsent) draft. Remove one before adding another.
  • unsupported_file_type — the file extension isn't in the supported list above. Convert or rename, or paste the content directly into the chat.
  • password_protected — the PDF requires a password. Decrypt it locally first.
  • file_too_large — over the per-tenant size cap. The error includes the actual byte limit so the UI can show what's allowed.
  • parse_failed — the file matched a supported extension but the parser couldn't read it (corrupt file, unexpected encoding). Re-export from the source application and try again.
  • Extraction returned no text — PDF is likely scanned and OCR fell back. For best results, use a text-based (not scanned) PDF or run it through a dedicated OCR tool first.

See Also

You're offline — some actions may not work.

Connection lost

Attempting to reconnect to Foreman...

Connection lost

Retrying in --s Attempt - of -

Connection interrupted

Retrying in --s Attempt - of -