Skip to content

fix(eve): preserve authored tool and channel type precision - #1722

Draft
vercel-gh-bot-4[bot] wants to merge 1 commit into
mainfrom
e0/f84d82f8-aca6-4ffd-9e6a-bcaa1da13cc7
Draft

fix(eve): preserve authored tool and channel type precision#1722
vercel-gh-bot-4[bot] wants to merge 1 commit into
mainfrom
e0/f84d82f8-aca6-4ffd-9e6a-bcaa1da13cc7

Conversation

@vercel-gh-bot-4

Copy link
Copy Markdown

Fixes #1717.

defineTool(...) widened concrete executor returns to the full runtime union, and cross-channel selection rejected valid closed receive-target interfaces such as Slack's. Both failures appeared during TypeScript compilation even though runtime behavior already supported the authored definitions.

The hypothesis is that preserving the executor function in overload inference, while keeping ToolDefinition<TInput, TOutput> broad, restores precise authored returns without breaking explicit generic consumers. Constraining cross-channel selection with ChannelReference<unknown> lets TypeScript infer the channel's exact receive target.

This change adds compile-time coverage for async, async-generator, mixed streaming, projection-order, explicit-generic, and Slack target cases. It also retains tool extension epoch 7 while recording epoch 8.

Validation:

  • pnpm --filter eve typecheck
  • focused unit tests: 13 passed
  • pnpm guard:invariants
  • targeted oxfmt and oxlint
  • full unit suite: 6,015 passed; 10 unrelated sandbox failures remain. Three timeout failures pass when rerun alone. Seven run-vercel assertions detect the sandbox's /tmp/node_modules/.bin/vercel instead of the expected missing local binary.

@vercel

vercel Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
eve-docs Ready Ready Preview Aug 6, 2026 4:18pm
eve-docs-4759 Ready Ready Preview, v0 Aug 6, 2026 4:18pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Preserve authored tool and channel type precision

0 participants