Repository navigation
Conversation
A description like "Snack sign up" says what people sign up for but gives nothing to make a real slot from, so Magic Compose drafted three "TBD:" rows. Rule 4 now has the model ask about when instead, and QuestionsSchema takes a reply without "what" as long as it asks "when", with one to four things read from the description. The questions screen shows those as already-picked chips under "What people sign up for", to remove or add to; they go back in what.picked as before. Example D flips from placeholder rows to that reply, the golden prompt is regenerated, ev_034 and ev_035 now expect questions, and ev_040 and ev_041 are new. Telemetry docs, the help line, the evals README and the CHANGELOG follow. Fixes #687. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016YZ9SWPHnLzQ4cTAJqUu28
Tophat: passedRan 2fdbaa7 locally with
For the owner (UX): when a description says what people sign up for but nothing a real slot could be made from ("Snack sign up"), Magic Compose should now ask When is it? (and how many) instead of making three "TBD" rows. On that screen, the "what" part changes from a question to a statement, What people sign up for, with the items read from the description already picked as removable chips, and "From your description. Remove any that don't fit, or add your own." Descriptions that don't say what still get the old question with option pills. How often a real model takes the new path is still open: please run the model-panel eval the PR asks for. See Screenshots are in https://claude.ai/code/session_016YZ9SVx3UwtY8voe3mmB3S. Generated by Claude Code |
richshaw
left a comment
There was a problem hiding this comment.
Review: changes needed (round 1)
This PR lets Magic Compose ask "when" without asking "what" when a description names the thing but would only make "TBD:" rows. It covers rule 4, the QUESTIONS section, Example D, QuestionsSchema (still .strict() at both levels), the questions screen's pre-picked chips, the evals, the help line, telemetry docs and CHANGELOG. The schema and the screen are done well and well tested. The route, schema, rule, component and unit tests cover each "Done when" item except the model-panel eval, which the PR rightly leaves to the owner. Two leftovers keep it from passing: one line of the prompt still sends the new case to "draft", and one line of the telemetry doc still describes the old payload.
Blocking (2):
src/lib/magic-compose/prompt.ts:208: the "asking what" bullet still says "If the options would be the prompt's own items or roles, it already says what: draft instead". That sends "Snack sign up" back to TBD rows and contradicts the new rule 4. Also__golden__/system-prompt.txt:22.docs/telemetry.md:106: it saysanswered/skippedcover only the topics asked, butansweredPayloadalways recordswhat, including in awhen-only round. The PR body says the doc covers this, but it doesn't.
Optional (5):
Questions.tsx:176(Back):appendAnswersgets the pre-picked items even when nothing was touched. Back straight away turns "Snack sign up" into "Snack sign up\nWhat: Bring snacks (no limit)", text the organizer never chose. When it matchesstartingAnswers(questions), you could pass the description unchanged.Questions.tsx:137(Draft with placeholders): with the chips untouched,hasAnswersis true. So the button drafts from the read items, with each count sent as "no limit", rather than sendingplaceholders: true, andmagic_compose.answeredlogsplaceholders: false. That's consistent with "empty count = no limit", but it may not be what the button's name suggests. Worth a look when you try the screen.src/lib/signup-rules.ts:55: "A prompt that lists items or roles drafts, with or without dates" sits beside Example D andev_041. Both name a single role and are now expected to ask. The line reads fine as "lists" (plural), but the eval run will show whether models agree.route.questions.db.test.ts:88: the old JSDoc (""what" was already known, so it's left out") was left aboveCANT_ASK's new one.- The issue's "Done when" says a five-option reply is rejected. The PR cuts it to four, matching what already happens when "what" is asked. That's a reasonable choice, and the description states it.
Earlier threads: none. Copilot couldn't review (quota).
Checks: CI green on 2fdbaa7 (lint-type-test, e2e, CodeQL). The tophat passed on 2fdbaa7, and no runtime code has changed since. Locally I read the diff and ran the built-in code review at high effort; I verified each finding above against the code.
Gate: owner (UX). The questions screen, the prompt and when Magic Compose asks all change. After the fix, look at the tophat's 696-after-desktop-questions / 696-after-phone-questions screenshots, and run the model-panel eval the PR's "Before merging" asks for (ev_040, ev_034, ev_035, ev_041, and the item-list ask rate).
Session: https://claude.ai/code/session_016YZ9SRngohvtRKSKMaRVum
Generated by Claude Code
…when "what" wasn't asked - The QUESTIONS bullet for asking "what" no longer says "draft instead" when the options would be the prompt's own items: it sends that case to rule 4 (ask "when" if every slot would be a TBD row, otherwise draft). Golden prompt regenerated; only that line changes. - docs/telemetry.md: `what` is always in answered or skipped, including a round where it wasn't asked. - Drop a stale JSDoc line above CANT_ASK in the route test. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016YZ9SUZQgfhZ8BGWLKdLLG
|
Addressed review round 1 in The optional points:
The prompt wording changed, so the PR goes back to tophat. Generated by Claude Code |
Tophat: passedI ran fc72b8c locally with
For the owner (UX): a description that names the job but gives nothing to build slots from ("Snack sign up") used to go straight to a draft of "TBD" rows. With this PR the model is told to ask when instead, and the questions screen can show that. The heading reads "What people sign up for", with the description's things already picked as removable chips, followed by the usual When and How many questions. Descriptions that don't say what still get the old pick-from-options screen. Two things to know:
See Screenshots are in https://claude.ai/code/session_016YZ9SUnN3jrznFjkUTJvNf. Generated by Claude Code |
richshaw
left a comment
There was a problem hiding this comment.
Review: passed (round 2)
Round 1's two blocking findings are fixed in fc72b8c, and nothing new came in with the fix. The "asking what" bullet in prompt.ts no longer says "draft instead". It now sends the case where the options would be the prompt's own items to rule 4: ask "when" if every slot would be a "TBD:" placeholder, otherwise draft. The golden prompt changes on that one line only. docs/telemetry.md now says what is always in answered or skipped, even in a round where it wasn't asked, and that matches answeredPayload (telemetry.ts: what goes in answered when any item went back, and when only when a when answer exists). The stale JSDoc above CANT_ASK is gone. The rest of the PR is the same code round 1 reviewed. I went through the repo checklist again: no services, schema, MCP tools, instructions.ts or RULES_IN_BOTH change, and the assistant's half of rule 4 is untouched.
Blocking (0)
Optional (0) new. Round 1's optional points (Back appends the pre-picked items, Draft with placeholders with untouched chips, the "lists items or roles" wording) were answered and left for the owner's call. They're repeated below.
Earlier threads: all resolved (2).
Checks: CI is green on fc72b8c (lint-type-test, e2e, CodeQL). The tophat passed on fc72b8c (17:29Z), on the same head. Locally I read the fix commit and checked the telemetry doc against answeredPayload. Copilot couldn't review (quota).
Gate: owner (UX). This changes when Magic Compose asks questions, the drafter prompt, and the questions screen: "What people sign up for" now shows pre-picked chips taken from the description. Please:
- look at the tophat's
696-after-desktop-questions,696-after-phone-questionsand696-after-desktop-removed-readdedscreenshots; - run the model-panel eval the PR's "Before merging" asks for (
ev_040,ev_034,ev_035,ev_041should askwhenwithoutwhat, the item-list ask rate shouldn't rise, andev_036/ev_037should still draft); - decide on two behaviours round 1 left to you. Pressing Back right away appends the pre-picked items to the description. Draft with placeholders with the chips untouched drafts from the items, with "no limit" counts.
Session: https://claude.ai/code/session_016YZ9SV6f7zJ31MfLwmVv2j
Generated by Claude Code
Fixes #687.
The problem
Since #577, Magic Compose asks questions only when a description doesn't say what people sign up for. A description that says what but nothing else, like "Snack sign up", went straight to a draft: rule 4 told the model to make 1–3 "TBD:" rows, so the organizer landed in the builder with three "TBD: Event" rows and nothing usable.
QuestionsSchemaalso requiredwhatand 2–4 options, so a model that tried to ask about when only (several did in #577's evals) got "AI draft did not match expected shape".The fix
NEVER_INVENT_MIDDLE.drafterinsrc/lib/signup-rules.ts): when the prompt says what but its slots need dates or times it doesn't give and nothing in it could make a real slot, so every slot would be a "TBD:" placeholder, ask about "when", not "what". A prompt that lists items or roles drafts, with or without dates. Placeholder rows are now only for answers that leave the dates out ("Not decided", Draft with placeholders). The old "named items … already say what: draft, don't ask" now reads "…: don't ask about it", since a named task like snack duty can now lead to asking when. The assistant's half of the rule andRULES_IN_BOTHare unchanged, so the MCP instructions are unchanged.topicsincludes "what" when the prompt doesn't say it. Otherwise it leaves "what" out and includes "when". A new line says that without "what",whatOptionsholds 1–4 things read from the prompt.{"questions":{"topics":["when"],"whatOptions":["Usher at the play"]}}. The golden prompt is regenerated, and its diff is only these changes.QuestionsSchema:topicsmust includewhatorwhen.whatOptionsneeds 2 or more whenwhatis asked and 1 or more when it isn't. Both levels stay.strict(). Unknown topics, blanks, duplicates and over-long options are dropped as before, and a list over four is cut to four, as it already is whenwhatis asked. A reply that asks neither what nor when still gets the route's one firmer retry.Questions.tsx,answers.ts): whenwhatwasn't asked, the screen starts with the model's items picked (startingAnswers). They're shown as removable chips under What people sign up for, with "From your description. Remove any that don't fit, or add your own." There are no option pills. Typing a removed item back picks it again, through the existingaddPending.removeAddedbecameremoveItem, which takes an item off either list. Focus moves to the next chip's ×, as before. "How many" rows and the follow-up are unchanged: the chips go inwhat.picked.evals/magic-compose/dev-evals.json):ev_034(snack duty, no dates) andev_035(conferences, no times) now expect questions withwhenand withoutwhat, and options that mention the prompt's own thing.ev_040("Snack sign up": asks when and how many, options mention snacks) andev_041(drivers for away concerts).ev_038/ev_039that Give one-day Magic Compose drafts a Date column, so their reminders go out #693 adds.ev_001,ev_016,ev_024,ev_032) are unchanged and still expect a draft.docs/telemetry.md:magic_compose.askedcan listwhenwithoutwhat, andoptionsthen counts the items read.Choices I made that the issue didn't
mainisn't Prettier-clean and a whole-file format would bury the change.magic_compose.answeredpayload code is unchanged. Withwhatnot asked,answered/skippedstill says whether any item went back, andpickedcounts the description's items the organizer kept. The telemetry doc says so.Tests
route.questions.db.test.ts): a stubbed["when","how_many"]reply with one item gives200 { questions }, makes one call, charges one quota and creates no signup. The "can't ask" fixture is now a reply with neither what nor when, and its retry tests still pass.prompt.test.ts):whatand nowhen; nowhatwith no items, only a blank one, or nowhatOptionskey; an extra key; mixed draft keys with awhen-only questions object.signup-rules.test.ts): rule 4 asks when for the all-placeholder case, keeps item lists drafting, and keeps placeholders for answers that leave dates out.Questions.test.tsx):what, the item shows as a picked chip with the new heading and no option pill, and gets a "How many" row.what.picked.answers.test.ts):startingAnswers,removeItem, andbuildFollowUpwithoutwhat.pnpm lint && pnpm typecheck && pnpm knip && pnpm test(2008 tests),pnpm test:db(629), andpnpm build && pnpm budgets(/app/signups/newat 115.3 of 116 kB).Before merging
#687's "Done when" asks for a model-panel eval run, PR vs
main, and this session has no LLM endpoint. Please run, on this branch and onmain(3 runs each, on the OpenRouter panel):Check that:
ev_040) andev_034/ev_035/ev_041now ask withwhenand withoutwhat;ev_001–ev_027,ev_032,ev_033) doesn't rise;ev_036/ev_037still draft from answers.Generated by Claude Code