Jennifer Nguyen

Bootwitch

Scientist building AI and research tools
10+ years in immunology research · Building with AI since 2024
Bootwitch / Interactive demo
Simulated session
Files
Terminal
Welcome to Bootwitch.
Projects / guided-portfolio-conversation-technical

Guided Portfolio Conversation — Technical

Technical walkthrough of bounded continuity, stream lifecycle, and safe exports.

guided-conversationtechnicalstreamingsecurity

README · ARCHITECTURE · TECHNICAL · source

Structured conversation, not terminal history

The terminal includes boot lines, commands, navigation, and status messages. Conversation state instead records only completed user and assistant turns. That keeps the model context focused and makes transcript export clean by construction.

Bounded continuity

The request contract caps the rolling summary, number and size of recent turns, and combined context size. The Worker rejects unsupported fields and invalid roles rather than quietly accepting an expanding client payload.

The summary is refreshed only after the answer completes. If that small second model call fails, the previous summary is preserved so a secondary feature cannot break the main answer path.

Evidence remains separate

The browser controls its request payload, so its history is untrusted. Retrieval runs separately over curated public documents and public-safe reference notes. Hidden reference notes are a presentation choice—not a confidentiality boundary—and only visible website documents can be cited to visitors.

Stream lifecycle

Incremental text is visible as it arrives. A completed event carries the final answer, mode, and next summary. Interrupted answers remain visibly marked but are excluded from conversation state. The site's abort signal is forwarded to the provider request, and clear adds an epoch guard so late work cannot rebuild a conversation the visitor erased.

Export safety

The transcript export never crosses the Worker because the browser already has the structured turns. Summary generation is different: it happens only when requested and sends a bounded set of turns to a protected, rate-limited route. The model is asked for plain text—not HTML—and its output is escaped into a static template with an inert content-security policy.

Apart from one explicitly contributed exchange, the application does not persist raw questions, answers, conversation summaries, recent turns, transcripts, or summary HTML. The contribute <1-5> command is the only path that writes verbatim visitor text, and it is gated on a signed one-hour receipt naming an eligible answer. Operational records contain categories and measurements instead: topic labels, prompt length, response mode, cited sources, export kind and size, and a session hash. Provider store: false, application non-retention, and HTTP Cache-Control: no-store cover different layers; none prevents the provider from processing a request while it is being answered.

Demo-grade boundaries

The signed passphrase session is a one-hour portfolio capability, not user authentication. KV-backed rate limiting is shared across Worker instances but uses a read-modify-write sequence, so it is useful abuse friction rather than a strict atomic quota.

See selected source excerpts