Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 20 additions & 4 deletions CAPABILITIES.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,18 @@ monorepo and installable from source.
(`compose`, `process`, released), and one program can switch surfaces, tabs
and popups mid-run ([#1197](https://github.com/OpenAdaptAI/OpenAdapt/pull/1197)).
5. **Confirms the right record before every write and reads it back after.**
The record check reads the system of record (API, database, FHIR with SMART
Backend Services, or a separate signed-in session), never just the screen.
A run is `VERIFIED` only when a read outside the acting session confirms the
save: the system of record (API, database, FHIR with SMART Backend Services,
a log or an export) or a separate session (a fresh sign-in on the web; on
desktop, a fresh session or a relaunch of the app, as the deployment
declares). A read on the acting screen gets its own level and never
verifies a run. The run report names the level for each save with a
declared read-back. Where the app's own screens are the only independent
read, the check covers at most the target record, plus the same actor's
changes in the app's activity log within a stated window where the app
shows one and the program is set up to read it; other records, later
server-side jobs and outbound messages are not covered. The wire check is
evidence of what was sent, not a check level.
`record --verify` proposes those checks from what the demonstration changed.
Released.
6. **Stops instead of improvising, and never retries an uncertain save.** A run
Expand Down Expand Up @@ -538,7 +548,11 @@ A test fails when a command has no file or this list is out of date.
- **Fault test.** We injected 8 kinds of bad save, 9 runs each, alongside
clean runs: 72 runs left a wrong record behind. A check that trusts the screen's "Saved" banner reported 54 of those
as success; reading the record back over the app's REST API missed 9; the
complete database read path caught all 72. The fault set and method are in
complete database read path caught all 72. The test app's database is
SQLite with two record tables, so "every table" there is two tables.
Separately, 9 of the 18 correct saves stopped in every arm: the server
committed the save but its answer timed out, so the write step halted before
any read-back ran. The count is of end-to-end run outcomes. The fault set and method are in
[EFFECT_E2E.md](packages/flow/benchmark/effect_e2e/EFFECT_E2E.md).
- **OpenEMR referral: agent, screen program and API step.** Median wall time
per referral, from a fresh browser through sign-in, the entry and the read-back:
Expand All @@ -563,7 +577,9 @@ A test fails when a command has no file or this list is out of date.
- **openIMIS claims.** On a test copy of openIMIS, the open-source insurance
and claims system that runs Nepal's national health insurance scheme, the
compiled program entered 149 synthetic claims with no model calls: 148 read
back correct and none were saved wrong:
back correct and none were saved wrong. Each saved claim was read back by
SQL through a read-only database role on the test copy; the 149th stopped
before saving:
[SCOREBOARD.md](packages/flow/benchmark/scoreboard/SCOREBOARD.md#openimis).

The systems each result ran on are listed in
Expand Down
21 changes: 16 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ every run. OpenAdapt lets your agent, or a person, do a task once in a web,
Windows, macOS, Linux or remote-desktop app. It compiles that run into a program,
and your agent calls the program as one tool. The program runs with no model
calls and sends no screenshots anywhere. It confirms the right record before
each save, reads the save back from the system of record after it, and returns
a plain outcome. When anything doesn't match, it stops and tells your agent
each save, checks the save after it, and returns a plain outcome that says
how the save was checked. When anything doesn't match, it stops and tells your agent
instead of guessing.

## Measured on OpenEMR and openIMIS
Expand All @@ -45,7 +45,8 @@ has every run.
On a test copy of openIMIS, the open-source insurance and claims system that
runs Nepal's national health insurance scheme, the compiled program entered
149 synthetic claims with no model calls: 148 read back correct and none were
saved wrong
saved wrong. Each saved claim was read back by SQL through a read-only
database role on the test copy; the 149th stopped before saving
([SCOREBOARD.md](https://github.com/OpenAdaptAI/OpenAdapt/blob/main/packages/flow/benchmark/scoreboard/SCOREBOARD.md#openimis)).

A screen can't show a save that went wrong behind it. On a test copy of
Expand Down Expand Up @@ -78,6 +79,16 @@ Each check below was asked whether those 72 bad saves had succeeded:
| A read of the record over the app's REST API | 9 of 72 (all writes to a table it didn't read) |
| A read of every table in the database | 0 of 72 |

The test app's database is SQLite with two record tables, so "every table"
there is two tables; a real system has many more. Separately, 9 of the 18
correct saves stopped in every arm: the server committed the save but its
answer timed out, so the write step halted before any read-back ran. Most
deployments give no database access at all. Where the app's own screens are
the only independent read, the check covers at most the target record, read
in a separate session, and the same user's changes in the app's activity log
within a stated window, where the app shows one and the program is set up to
read it.

[EFFECT_E2E.md](https://github.com/OpenAdaptAI/OpenAdapt/blob/main/packages/flow/benchmark/effect_e2e/EFFECT_E2E.md)
has the fault set, the method and the raw results.

Expand Down Expand Up @@ -328,7 +339,7 @@ the right record is on screen, makes the entry, and reads the record back.
| Model calls per run | At least one per step | None on a hit; the agent's calls on a miss | None | None with default settings |
| When the screen changes | The model tries to adapt | The agent improvises live | A selector stops matching, or matches the wrong control | The run stops before saving; a fix is proposed and a person approves it |
| Right record? | The model judges from the screen | Usually only that the screen looks as recorded | Whatever the developer scripted | Checked before every save |
| Did the save land? | The model judges from the screen | The screen | Whatever the developer scripted | Read back from the system of record |
| Did the save land? | The model judges from the screen | The screen | Whatever the developer scripted | Reported verified only when a read outside the acting session confirms it; weaker checks are named as such |
| Strongest for | New or changing tasks | Repeated tasks where a wrong save is cheap | Stable processes with a team to maintain the scripts | The same entry many times, where a wrong save is costly |

## What it can do
Expand All @@ -337,7 +348,7 @@ the right record is on screen, makes the entry, and reads the record back.
- **Uses the most reliable layer the app allows**: page structure (DOM, UI Automation, Accessibility), direct API calls where one is bound, and pixels only for remote desktops.
- **Builds branching programs** from several demonstrations, repeated halts and background runs, and routes each item to the right verified variant.
- **Works across surfaces**: web, Windows, macOS, Linux and RDP backends, chained in one workflow.
- **Confirms the right record before every write and reads the saved record back** from the system of record, never just the screen.
- **Confirms the right record before every write and checks the saved record after it**. A run is reported verified only when a read outside the acting session confirms the save: the system of record where one can be read, or a separate session. Weaker checks are reported at their own level.
- **Stops instead of guessing**, never retries an uncertain save, and says what changed before a stop.
- **Binds each approval to exactly what will be saved**, with one-tap answers on a paired phone.
- **Repairs itself when the app changes**, probing a fix up to the save and asking a person to approve it (qualified on browser runs and end to end on native macOS).
Expand Down
87 changes: 87 additions & 0 deletions docs/proposed-web-copy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
# Proposed website copy: check scope without database access

Status: draft for approval. Nothing here is applied to the website.

These changes bring the insurance and dental pages in line with the repository
docs ([LIMITS.md](../packages/flow/docs/LIMITS.md#what-the-guarantee-covers-without-database-access),
[THREAT_MODEL.md](../packages/flow/docs/THREAT_MODEL.md#what-layer-1-covers)).
When a portal's own screens are the only independent read (no database, API,
log or export), the strongest check is a separately signed-in session. It
covers the target record as shown at the time of the read, and only where the
portal allows a second session and that read loads the record fresh from the
server.

File: `data/site/pages/industries.mjs` in `OpenAdaptAI/openadapt-web`, at
commit `53f05758`. Line numbers refer to that commit.

## Line 145: insurance, who it's for (make conditional)

Current:

> It's also for brokers and agencies that key claims or submissions into
> carrier portals. There, the check opens the saved claim again in a fresh
> browser session and compares it field by field with what was entered. That
> check is set up along with the workflow.

Proposed:

> It's also for brokers and agencies that key claims or submissions into
> carrier portals. Where the portal allows a second signed-in session, the
> check opens the saved claim there and compares it field by field with what
> was entered. That shows the claim as the portal displayed it at the time of
> the check, not what the carrier does with it later. Where the portal allows
> no second session, a person reviews each save. The check is set up along
> with the workflow.

The link that follows ("How to stop re-keying claims") stays.

## Line 160: insurance, carrier-portal card (make conditional)

Current:

> Staff key a submission into several carrier portals, and each save is
> checked by opening it again in a fresh browser session.

Proposed:

> Staff key a submission into several carrier portals. Where a portal allows
> a second signed-in session, each save is checked by opening it again there.

## Line 176: insurance, record-check table (make conditional)

Current row:

| Your setup | Second read | Result OpenAdapt can give |
| --- | --- | --- |
| Broker entering into a carrier portal | The saved claim, opened again in a fresh browser session | Checked on screen, at the time of the run |

Proposed row:

| Your setup | Second read | Result OpenAdapt can give |
| --- | --- | --- |
| Broker entering into a carrier portal | The saved claim, opened again in a separate signed-in session, where the portal allows one and the second read loads the record fresh from the server | Checked in a separate session, as of the time of the check. With no second session, a person reviews |

## Line 218: dental page description (remove)

Current:

> After a demonstration, OpenAdapt looks up coverage in a payer portal and
> carries the answer into your practice system. We measured the look-up on
> openIMIS, an open-source insurance system, with synthetic members.

The openIMIS result behind this sentence was checked by SQL on a test copy
with database access. A payer portal gives no such access, so the measured
check does not carry over to the setup the sentence describes.

Proposed: remove this text. The site's registry test
(`tests/siteRegistry.test.js:86`) requires every page to have a description of
240 characters or fewer, so removing it means either replacing it or removing
the page. If the page stays, a replacement that makes no check claim:

> After a demonstration, OpenAdapt looks up coverage in a payer portal and
> carries the answer into your practice system after a person approves it. We
> qualify the workflow on your own portal first.

The same claim appears in the page's answer (line 221), workflow steps (line
231) and test section (line 239). If the description goes, those lines need
the same decision.
Loading