docs+chat: smoke checklist Projects + Pydantic discriminator + untitled-thread fallback#278
Merged
Merged
Conversation
Three changes bundled per follow-up review notes: 1. examples/chat/smoke/CHECKLIST.md — adds 'Projects' and 'Move thread to project' sections covering PR #273 (Phase 4) end-to-end: inline create / rename / delete, filter behaviour, submenu wiring, idempotent moves, persistence across reload. 2. examples/chat/python/src/streaming/envelope_tool.py — Pydantic model_validator on A2uiEnvelope rejects envelopes with zero or multiple discriminators set. Catches LLM outputs that pass strict- mode validation but emit ambiguous shapes; two new tests cover the rejected cases. 3. examples/chat/angular/src/app/shell/threads.service.ts — fallback for threads without metadata.title changes from 'Thread 019e1e98...' (raw id slice) to a graceful 'Untitled'. Backend writes the title on the first user message; threads created via '+ New chat' and abandoned previously appeared with their raw id prefix in the sidenav.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Three small follow-ups bundled, all surfaced by the review work after sidenav-polish:
1. Smoke checklist — Projects + Move-to-project (covers PR #273)
Two new sections in `examples/chat/smoke/CHECKLIST.md` cover Phase 4's Projects feature end-to-end:
2. Pydantic envelope discriminator enforcement
`A2uiEnvelope` now has a `model_validator` requiring exactly one of `surfaceUpdate` / `beginRendering` / `dataModelUpdate`. Catches LLM outputs that pass strict-mode validation but emit ambiguous (multi-discriminator or empty) envelopes — flagged in the PR #259 review as a follow-up.
Two new tests cover the rejected cases.
3. Untitled-thread fallback
`ThreadsService.toThread` previously fell back to `Thread 019e1e98...` (raw id slice) when `metadata.title` was missing. The Python backend writes the title on the first user message, but threads created via "+ New chat" and abandoned never get a title — leaving ugly raw-id rows in the sidenav.
Fallback now reads "Untitled" — easier on the eye, consistent with how most chat apps surface drafts.
Test plan