pediatric-ai-scribe-v3/docs
Daniel 03621752e8
Some checks failed
Forgejo Android APK / Root app tests (push) Successful in 55s
Forgejo Docker Build / Root app tests (push) Successful in 45s
Forgejo Android APK / Build signed APK (push) Successful in 2m5s
Forgejo Docker Build / Build Docker image (push) Successful in 19s
Forgejo Docker Build / Deploy to the host (push) Failing after 0s
feat: image fallback chains for every workflow, and a library worth looking at
**Fallbacks.** One image model meant a refusal, a rate limit or a model the
gateway had since dropped ended as a missing picture. Every workflow now tries
its model, then each fallback in order, stopping at the first that produces an
image. Primary plus two, capped: each hop is a paid request, and a chain long
enough to need a cap is long enough to surprise someone.

My Resources previously had no fallback at all — only the Clinical Assistant
did, and only one. That is backwards: a missing figure is most visible in a
deck, where it leaves a hole in a slide.

The retry rule is now a classifier that says *why*, rather than a boolean.
Transient faults, a 404 for a model the gateway does not have, and a content
refusal all move to the next model — a refusal because policy is a vendor
decision, not a fact about the request. 401/403 stop immediately (one gateway,
one set of credentials, the next model fails identically), as do 413 and any
other 4xx, which are malformed everywhere. Refusals are recognised from the
message: no provider sends a machine-readable reason and the status varies.

Each hop re-leases the job, so a chain cannot outlive its claim and let a second
worker repeat the same paid work, and the row records the model actually being
paid for so a picture made by the third model is not attributed to the first.

The old singular `fallback_image_model` is still read, so an existing
configuration keeps working without anyone re-entering it.

**Library.** Documents/Images tabs in My Resources, with a real grid: fixed
aspect tiles so the rows line up whatever shape the pictures are, a source badge
on the picture, two-line prompt, hover lift, shimmer skeletons while thumbnails
land, and a lightbox that closes on Escape or the backdrop and restores focus.
Actions are hidden on hover only behind `@media (hover:hover)` — hiding delete
behind :hover would put it out of reach on touch and keyboard.

Downloads go through privateImageBlob rather than a bare `<a download href>`: a
mobile client's session is a bearer token an anchor cannot send, and these
assets are served no-store on purpose.

The gallery lives in My Resources only. Assistant images appear in it, which was
the point; the assistant page does not grow a gallery of its own, and a test
asserts no assistant module lists the endpoint.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Dv6sqaY6Vq3ChZHMem3cnU
2026-09-12 14:53:04 +02:00
..
logic docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
ai-providers.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
api-reference.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
architecture.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
authentication.md docs: accounts in the README, and the sign-in code path is verified end to end 2026-09-11 22:02:25 +02:00
clinical-assistant.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
configuration.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
database.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
deployment.md docs: deploy.sh is the deploy path, and it was documented nowhere 2026-09-12 06:04:13 +02:00
developer-guide.md docs: deploy.sh is the deploy path, and it was documented nowhere 2026-09-12 06:04:13 +02:00
embeddings-setup.md simplify speech and embeddings through litellm 2026-05-09 05:09:02 +02:00
features-explained.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
global-prompt-administration.md fix: reviewer findings — mhchem macro wrapping, regenerate history dedupe, strict safe image allowlist, stale docs 2026-09-08 19:25:31 +02:00
improvements.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
learning-hub.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
migrations.md docs: rewrite architecture, authentication, configuration, deployment, ai-providers, speech, database, learning-hub, migrations, developer-guide for public audience 2026-04-15 00:26:38 +02:00
mobile-build.md ci: route Android APK through Forgejo releases 2026-05-11 04:21:15 +02:00
module-conventions.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
my-resources.md feat: image fallback chains for every workflow, and a library worth looking at 2026-09-12 14:53:04 +02:00
openid-setup.md feat: ED multi-stage UX, extensions polish, docs viewer + application-logic docs 2026-04-28 03:09:38 +02:00
ops-docs-ped-ai-and-milvus.md docs: Ops Docs page on how Ped-AI and the two Milvus servers work 2026-09-10 18:37:41 +02:00
retrieval-tuning.md docs: My Resources, sign-in codes, invitations, and what the image carries 2026-09-11 20:49:10 +02:00
scaling.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00
speech.md docs: merge the duplicate pairs and correct them against the running app 2026-09-12 04:57:35 +02:00