Repository navigation
docs(predictions): push prediction events into Claude Code routines - #210
Merged
Merged
Conversation
Replaces the claim that a webhook cannot start a Claude turn. Adds the routine push recipe, delivery semantics, token rotation, limits, safety, and a scheduled-routine pull alternative. Describes behavior from the implementation brief for t-y-b-b/nextjs-ai-chatbot#2690 and is not proven in production yet.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Docs PreviewChanged docs pages: 3
Navigation updated: no Impacted nav groups:
|
Contributor
Author
|
Statements not verified (PR stays draft until #2690 proof):
Checks: fmt, docs:test, docs:check, venue-tools --check, lint, audit all pass locally; rejudge + compare.mjs: no regression. |
ericjuta
marked this pull request as ready for review
October 23, 2026 21:55
This branch was successfully deployed
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.
Tracks t-y-b-b/nextjs-ai-chatbot#2690
DRAFT. These docs match shipped D46 behavior from t-y-b-b/nextjs-ai-chatbot#2691 and #2693, production revision
1150273e4. The owner runs the live fire manually. No live fire was performed for this documentation correction.What changes
docs/connect/claude.mdx: corrects routine registration controls, optionalkind, test-fire cooldown and token replacement instructions.docs/predictions-mcp/events.mdx: corrects immediate rejection/oversize pauses, shared destination backoff, routine tests, receiver selection and token replacement. Replaces unnecessary hardcoded inventory/quota counts with schema/error fields and Anthropic's current limits documentation.tools/docs/venue-tools.jsonand generateddocs/predictions-mcp/tools.mdx: mention optional destinationkindin the registration description.Shipped behavior documented
events.mdx:239:200delivers.events.mdx:240:429is not a failure; honorRetry-After, never sooner than 150 seconds; persist the wait on the destination across its subscriptions.events.mdx:241,245:400,401,403,404immediately pause with onepausedhealth event androutine_rejected; fix the cause and resume withupdatePredictionEventSubscription,patch.enabled: true.events.mdx:242,245:413or an envelope too large to fit alone pauses withroutine_too_large.events.mdx:243: other statuses, including500/503, and network failures use normal failed-delivery backoff; retrying a500can duplicate a session.claude.mdx:106,events.mdx:125,222-224,tools.mdx:107: optionalkind, URL inference, rejection of other Anthropic URLs or contradictory kind, Receiver type choices, exact URL/token labels and Claude routine badge.claude.mdx:116,events.mdx:252-254: Replace token, Save token and resume after a rejection pause.claude.mdx:108,events.mdx:139,303: a short unsigned test message starts a real session, uses fire quota and occupies the destination's 150-second slot. During cooldown nothing is sent; MCP returnsWEBHOOK_ROUTINE_NOT_READYwithdetails.retryAfterSeconds, and settings tells the user to wait N seconds.events.mdx:228-229: one fire per destination every 150 seconds, oldest first, text under 65,536 characters, envelopes never split.Local checks
At head
56382687f23801ba92636ab2cde9c28e41918dc3:bun install --frozen-lockfile: passed.bunx vp fmt,bun run fmt:check: passed.bun run docs:test: 41 passed, 0 failed.bun run docs:check: passed; 73 pages and 27 images validated.node tools/docs/venue-tools.mjs --check: passed.bun run lint: exit 0, including package builds.git diff --check: passed.compare.mjsreported "No regression against the baseline", with 0 pages newly atdrift_risk >= 0.7. Final drift estimates: Claude 0.41, events 0.44, tools 0.29. Unchanged pages retain committed baseline verdicts; this was not a fresh whole-site sweep.bun audit: FAILED, 1 high-severity advisory in unchanged Zod dependencies (4.1.8,4.4.3): GHSA-mrhx-c7xc-m3w5. No dependency or lockfile changes were made.Fetched
origin/mainand rangit rebase origin/mainbefore editing; Git reported already up to date (0 behind, 2 ahead). Added one signed correction commit and pushed using the lease pinned tof7c8b7aff2c13a1778a3e582ee7cd31ab20da2b2.No merge, deployment, environment change or nextjs-ai-chatbot edits.