feat(tools): the assistant can read the files of records, where a host turns that on; an answer keeps no address the application did not give #116

Open
james.maes wants to merge 21 commits from feat/read-file-contents into develop
pull from: feat/read-file-contents
21 Commits
Author SHA1 Message Date
james.maesandClaude Fable 5.2 6e812014c3 Merge branch 'feat/compact-answers-and-output-ceiling' into feat/read-file-contents
build / maven (push) Blocked by required conditions
maven / build (push) In progress
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 16:09:21 -06:00
james.maesandClaude Fable 5.2 7da70de9ba fix(tools): file reading is off until a host turns it on; a file is read only with the record it is attached to; one deadline for an outside fetch
After a second independent review of reading files and of the link rule:

- Reading files is off by default. A host turns it on per table
  (withFileSource) or for every table (withFileReading); until then the
  tool is not offered and a call reads nothing.
- A file is read only when the record it is attached to may be read: where
  the host declared it (withAttachedTo, withAttachedToRecordOf), the
  assistant must be allowed that record's table and the person that record.
  An attachment-style table with no declaration is refused, and the refusal
  says what to declare.
- A file kept outside the application is fetched only from an allowed
  origin (scheme, host and port; https unless an http origin is listed),
  with one deadline for the whole fetch, body included. The client is shut
  down after each fetch. A refusal names neither the address nor its host.
- Taking the text out of a document is bounded: what a workbook inflates
  to, the rows and cells walked, and time.
- The link rule judges every way a path of the application can be written
  (angle brackets, an HTML anchor, relative forms), and a path that is only
  written in the content of a file or a record no longer counts as given.
  The design note says plainly that the panel is the control for addresses
  of other sites and for images.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 16:09:21 -06:00
james.maesandClaude Fable 5.2 97ee750c26 Merge branch 'feat/one-card-for-a-set' into feat/compact-answers-and-output-ceiling
maven / build (push) Successful in 8m57s
build / maven (push) Successful in 8m57s
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 16:02:39 -06:00
james.maesandClaude Fable 5.2 ce9a1323bb Merge remote-tracking branch 'origin/develop' into feat/one-card-for-a-set
maven / build (push) Successful in 10m2s
build / maven (push) Successful in 10m2s
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 15:53:05 -06:00
james.maesandClaude Fable 5.2 efe161a94d fix(process): a review's own inputs and values are held to what the card showed
A review was passed on its count and its lines alone. A review with an
option whose value the process had changed after the card was made, or with
a value to read, went on to store with what the card never showed (proved
by a second independent review).

A review is a screen too: before it is passed, and before it is answered
with "validate", what it has of its own is held to the record of what the
card displayed (screenDiffers), like any other screen. Such a run stops
with nothing stored, and the card to go on with shows the review's inputs
with the values the process holds now and its values to read. The values
the card gave for a review's own inputs are sent with its answer.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 15:53:05 -06:00
james.maesandClaude Fable 5.2 77f2b7595c feat(tools): the assistant reads the files of records, and an answer keeps no address the application did not give
maven / build (push) Successful in 12m36s
build / maven (push) Successful in 12m35s
A person asked what was in a file attached to a record. The assistant found
the row of the file, said it cannot read files, and wrote an address it had
composed as plain text.

read_file returns the content of a file a record holds, for a person who
may open it. Which fields are files is read from the metadata (a BLOB, a
field with a file-download adornment); no table of another QBit is named.
The record is read as the person, a BLOB is downloaded with the
application's own operation as the person (UiApiGateway.download), and a
file kept outside the application is fetched only from a host the code
allowed (withFileUrlHosts; no credentials, no redirect). Data access and
field exposure narrow it as for every read: a masked field is not read.
Text comes back as text, a PDF or a workbook as its text, bounded, and a
part says it is a part; an image and any other binary is described, never
dumped. The content is untrusted data inside the envelope, and the
tool-call log does not keep it.

A file is shown as a chip that opens the record it is attached to (when the
host said which, and the application lists that table for the person), or
its own record. An address of the application in an answer is kept only
when a tool result, the conversation or the page gave it (AnswerLinks): a
composed path is removed from the streamed and the stored text.

Design: docs/file-contents-and-links.md.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 15:15:51 -06:00
james.maes 8bf9a557ab Merge branch 'feat/one-card-for-a-set' into feat/compact-answers-and-output-ceiling
maven / build (push) Successful in 10m12s
build / maven (push) Successful in 10m12s
2026-11-17 13:52:55 -06:00
james.maesandClaude Fable 5.2 479be0408b fix(engine): the model row's output limit follows the same floor as the provider row's; the panel and INCOMPLETE in the upgrade notes
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 13:46:57 -06:00
james.maesandClaude Fable 5.2 a5b5f8cc4a test: the tool-set file follows the description of get_run_status
maven / build (push) Successful in 10m8s
build / maven (push) Successful in 10m8s
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 13:43:34 -06:00
james.maes c6ef837d0a Merge branch 'feat/one-card-for-a-set' into feat/compact-answers-and-output-ceiling 2026-11-17 13:43:11 -06:00
james.maes df24de71fe Merge branch 'fix/render-widget-follows-data-access' into feat/one-card-for-a-set
# Conflicts:
#	CHANGELOG.md
2026-11-17 13:41:14 -06:00
james.maesandClaude Fable 5.2 647a8eadfb fix(process): a screen is passed only against the record of its card; a review is judged before any step; an unread job is not described
Three cases an independent review proved against the first version, each
with a test that fails without its fix:

- a review with a warning and an error was answered with 'validate first'
  before its lines were read, and a process that is not core's streamed one
  went on to store. The lines are now judged first, for every process, and
  'validate first' is only answered for core's own streamed process; a
  review with no lines is not passed.
- a screen outside the process's list of steps (an optional step), with a
  defaulted option, was passed although the card never displayed it. The
  stored proposal now keeps a record of what the card displayed, and a screen
  is passed only against it; a screen the process changed while it ran and
  every screen of a state-machine process stop.
- a job the person may not read was reported as running. A job that was not
  read is reported as exactly that, and the action fails.

Also: a status check cancels nothing; a run still working is 'started and
has not finished'; the names on a card are in the application's order;
every input is on the card, also one left empty.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 13:40:24 -06:00
james.maes 4bf102cd4a Merge branch 'feat/one-card-for-a-set' into feat/compact-answers-and-output-ceiling
maven / build (push) Successful in 8m32s
build / maven (push) Successful in 8m32s
2026-11-15 05:42:34 -06:00
james.maesandClaude Fable 5.2 298b75c5ff test: a provider row's output cap is read with the floor in code
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-15 05:42:34 -06:00
james.maesandClaude Fable 5.2 18e893b835 fix(process): a card shows all a screen says; a screen that says more than a card shows is not passed
maven / build (push) Successful in 9m20s
build / maven (push) Successful in 9m20s
The first card showed the first 300 characters of a screen's text and then
passed the screen. It now shows the whole text (up to 2,000 characters), and
a screen whose text is longer is one the card did not show in full: the run
stops there.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-15 05:42:27 -06:00
james.maes 540ad0371d Merge branch 'feat/one-card-for-a-set' into feat/compact-answers-and-output-ceiling 2026-11-15 05:31:49 -06:00
james.maes d6bfe77c78 Merge branch 'fix/render-widget-follows-data-access' into feat/one-card-for-a-set
# Conflicts:
#	CHANGELOG.md
#	UPGRADE.md
2026-11-15 05:31:32 -06:00
james.maesandClaude Fable 5.2 15de0db565 feat(engine): compact answers; a reply cut off at the output ceiling drops no work and never ends COMPLETE
A reply that stopped at the output ceiling is read like any other: the tool
calls it had completely formed run, the one it was still writing (its last
part) and any whose input a provider could not read never do and get an
error result that says so. The answer goes on by itself at most
maxOutputContinuations times, each a model call under every limit of any
other; after that it ends INCOMPLETE, never COMPLETE, says what was done and
what was not, and stays in the conversation so that 'continue' goes on.

A provider row lowers the output ceiling of one reply only down to
minOutputTokensPerRequest; it never raises the ceiling the code configured.

An answer shows a record once and at most maxRecordCardsPerTurn record cards
and maxRecordChipsPerTurn record links; a confirmation card is never left
out. The system prompt asks for one proposal for a set and compact answers.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-15 05:29:56 -06:00
james.maesandClaude Fable 5.2 47d3e34f8c docs(process): the design of one confirmation for a set; the card's records and what they were, in the API
docs/one-card-for-a-set.md is the design and the safety argument for parts A
to D; README, UPGRADE, CHANGELOG and the agent notes follow it. UI API
extension assistant 1.11.0 (additive): AssistantActionV1.recordCount,
records and recordsBefore for a run over a set.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-15 05:28:55 -06:00
james.maesandClaude Fable 5.2 583f8f1f9d test: the existing security tests follow 'no card for what cannot happen'
A person the application refuses is refused before a card where the
application says so beforehand; the confirm-time refusal (a permission that
goes between the card and the confirmation) keeps its tests, with the UI's
own status and message. The tool-set file changes in one description
(run_process), replaced as text.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-15 05:23:13 -06:00
james.maesandClaude Fable 5.2 11fc143e6d feat(process): one confirmation runs a set to its end, within what its card showed; no card for a change the person may not make
A confirmed run_process goes through the process's own init and step
operations as the person and passes a screen for them only when it shows
nothing their card did not: its text and inputs were on the card with the
values the process has now, and a review counts exactly the records of the
card and, with every record validated first, has no warning and no error.
Anything else comes back to the person with a new card and nothing stored.

The set is frozen by primary key and by one digest over its records as the
person read them; a set that changed is not run. The card keeps what the
records were (how many, a sample of 20) and lists the whole set by name.

The assistant no longer creates a job: when the application itself hands the
work to a background job, the job is the person's, it is waited for, and its
outcome (rows done, failed and why) is the card's. A job the application
created waiting is cancelled and the run reported as not done.

A change to records of a table is proposed only to a person the application
lets make it (what it tells their own screens); otherwise they are told so
and there is no card.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-15 05:09:34 -06:00