fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls - #733

Merged
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727
Jan 8, 2026
Merged

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls#733
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727

Conversation

@pranaygp

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Gemini thinking models (e.g., gemini-3-pro-preview) that require thoughtSignature to be preserved across multi-turn tool calls
  • Maps providerMetadata from tool call responses to providerOptions in the conversation prompt, following the AI SDK convention

Problem

When using Gemini thinking models with tool calls, multi-turn conversations fail with:

function call is missing a thought_signature

This happens because providerMetadata (which contains thoughtSignature) from the tool call was not being passed back to the provider when reconstructing the conversation prompt.

Solution

In stream-text-iterator.ts, when adding tool calls to the conversation history, we now map providerMetadataproviderOptions:

conversationPrompt.push({role: 'assistant',content: toolCalls.map((toolCall)=>({type: 'tool-call',toolCallId: toolCall.toolCallId,toolName: toolCall.toolName,input: JSON.parse(toolCall.input),
...(toolCall.providerMetadata!=null
? {providerOptions: toolCall.providerMetadata}
: {}),})),});

This follows the same pattern used in the AI SDK's to-response-messages.ts.

Testing

Added comprehensive tests in stream-text-iterator.test.ts:

  • Preserving providerMetadata as providerOptions in tool-call messages
  • Not adding providerOptions when providerMetadata is undefined
  • Preserving providerMetadata for multiple parallel tool calls
  • Handling mixed tool calls with and without providerMetadata

Fixes#727

CopilotAI review requested due to automatic review settings January 7, 2026 06:18
@changeset-bot

changeset-botBot commented Jan 7, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7da7897

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@workflow/aiPatch
@workflow/docs-typecheckPatch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

Summary

PassedFailedSkippedTotal
✅ ▲ Vercel Production363011374
❌ 💻 Local Development299338340
✅ 📦 Local Production33208340
✅ 🐘 Local Postgres33208340
✅ 🪟 Windows340034
❌ 🌍 Community Worlds131170148
Total149150351576

❌ Failed Tests

💻 Local Development (33 failed)

nitro-stable (33 failed):

  • addTenWorkflow
  • addTenWorkflow
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • readableStreamWorkflow
  • hookWorkflow
  • webhookWorkflow
  • webhook route with invalid token
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • outputStreamWorkflow
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • stepDirectCallWorkflow - calling step functions directly outside workflow context
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check endpoint - workflow and step endpoints respond to __health query parameter
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
🌍 Community Worlds (17 failed)

mongodb (1 failed):

  • webhookWorkflow

redis (1 failed):

  • webhookWorkflow

starter (14 failed):

  • addTenWorkflow
  • addTenWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly

turso (1 failed):

  • webhookWorkflow

Details by Category

✅ ▲ Vercel Production
AppPassedFailedSkipped
✅ astro3301
✅ example3301
✅ express3301
✅ fastify3301
✅ hono3301
✅ nextjs-turbopack3301
✅ nextjs-webpack3301
✅ nitro3301
✅ nuxt3301
✅ sveltekit3301
✅ vite3301
❌ 💻 Local Development
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
❌ nitro-stable0331
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 📦 Local Production
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🐘 Local Postgres
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🪟 Windows
AppPassedFailedSkipped
✅ nextjs-turbopack3400
❌ 🌍 Community Worlds
AppPassedFailedSkipped
✅ mongodb-dev300
❌ mongodb3310
✅ redis-dev300
❌ redis3310
✅ starter-dev300
❌ starter20140
✅ turso-dev300
❌ turso3310

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: success
  • Local Dev: failure
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)0.037s (-1.1%)1.014s (~)0.977s101.00x
💻 LocalNext.js (Turbopack)0.038s (+10.7% 🔺)1.014s (~)0.975s101.03x
🌐 RedisNext.js (Turbopack)0.041s (-1.7%)1.017s (~)0.976s101.11x
💻 LocalNitro0.044s (-10.2% 🟢)1.006s (-0.8%)0.962s101.18x
💻 LocalExpress0.046s (+5.2% 🔺)1.008s (~)0.961s101.25x
🌐 MongoDBNext.js (Turbopack)0.083s (-30.1% 🟢)1.016s (~)0.934s102.23x
🌐 TursoNext.js (Turbopack)0.106s (+26.5% 🔺)1.014s (~)0.907s102.86x
🐘 PostgresExpress0.221s (-35.6% 🟢)1.014s (~)0.793s105.95x
🐘 PostgresNext.js (Turbopack)0.252s (+65.9% 🔺)1.029s (+1.0%)0.777s106.78x
🐘 PostgresNitro0.299s (+0.9%)1.012s (~)0.714s108.03x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro0.575s (-15.6% 🟢)1.423s (-15.2% 🟢)0.848s101.00x
▲ VercelExpress0.609s (-6.4% 🟢)1.435s (-15.6% 🟢)0.826s101.06x
▲ VercelNext.js (Turbopack)0.709s (-5.5% 🟢)1.532s (-9.8% 🟢)0.823s101.23x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.086s (+0.5%)2.011s (~)0.925s101.00x
💻 LocalNext.js (Turbopack)1.098s (+1.5%)2.012s (~)0.914s101.01x
🌐 RedisNext.js (Turbopack)1.106s (~)2.012s (~)0.906s101.02x
💻 LocalNitro1.113s (~)2.006s (~)0.893s101.02x
💻 LocalExpress1.118s (~)2.008s (~)0.890s101.03x
🌐 MongoDBNext.js (Turbopack)1.275s (-1.5%)2.017s (~)0.742s101.17x
🌐 TursoNext.js (Turbopack)1.308s (+1.3%)2.012s (~)0.704s101.20x
🐘 PostgresNext.js (Turbopack)1.660s (-11.0% 🟢)2.015s (~)0.355s101.53x
🐘 PostgresNitro2.158s (~)3.013s (~)0.855s101.99x
🐘 PostgresExpress2.254s (+2.6%)3.014s (~)0.761s102.08x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro2.637s (-11.0% 🟢)3.575s (-4.2%)0.938s101.00x
▲ VercelExpress2.650s (-16.4% 🟢)3.658s (-12.3% 🟢)1.007s101.01x
▲ VercelNext.js (Turbopack)2.712s (-11.7% 🟢)3.530s (-10.1% 🟢)0.817s101.03x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)10.606s (~)11.012s (~)0.406s51.00x
💻 LocalNext.js (Turbopack)10.653s (+1.4%)11.018s (~)0.365s51.00x
🌐 RedisNext.js (Turbopack)10.666s (~)11.016s (~)0.349s51.01x
💻 LocalNitro10.794s (~)11.012s (~)0.218s51.02x
💻 LocalExpress10.819s (~)11.016s (~)0.197s51.02x
🌐 MongoDBNext.js (Turbopack)12.068s (-1.2%)12.628s (-3.1%)0.560s51.14x
🌐 TursoNext.js (Turbopack)12.182s (~)13.023s (~)0.840s51.15x
🐘 PostgresNext.js (Turbopack)13.714s (-9.9% 🟢)14.235s (-11.2% 🟢)0.521s51.29x
🐘 PostgresExpress20.395s (~)21.036s (~)0.641s51.92x
🐘 PostgresNitro20.505s (~)21.029s (~)0.525s51.93x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro22.177s (+1.2%)22.860s (+1.0%)0.683s51.00x
▲ VercelNext.js (Turbopack)22.274s (~)22.897s (-0.9%)0.623s51.00x
▲ VercelExpress22.821s (+1.9%)23.459s (~)0.638s51.03x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Redis🥇 Next.js (Turbopack)1.348s (-1.1%)2.010s (~)0.662s151.00x
🌐 StarterNext.js (Turbopack)1.361s (+1.4%)2.008s (~)0.646s151.01x
💻 LocalNext.js (Turbopack)1.383s (+3.5%)2.012s (~)0.629s151.03x
💻 LocalNitro1.415s (~)2.005s (~)0.590s151.05x
💻 LocalExpress1.429s (+1.7%)2.007s (~)0.579s151.06x
🐘 PostgresNext.js (Turbopack)1.953s (+1.5%)2.160s (~)0.207s141.45x
🌐 MongoDBNext.js (Turbopack)2.144s (+1.2%)3.015s (~)0.871s101.59x
🌐 TursoNext.js (Turbopack)2.203s (-0.9%)3.013s (~)0.810s101.63x
🐘 PostgresNitro2.449s (+3.3%)3.010s (~)0.562s101.82x
🐘 PostgresExpress2.510s (+2.9%)3.015s (~)0.505s101.86x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.821s (~)3.588s (-9.5% 🟢)0.767s91.00x
▲ VercelNitro3.075s (-9.4% 🟢)4.000s (-7.9% 🟢)0.925s81.09x
▲ VercelNext.js (Turbopack)3.140s (-11.6% 🟢)3.954s (-9.1% 🟢)0.814s81.11x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.105s (+5.5% 🔺)3.022s (+39.8% 🔺)0.917s101.00x
💻 LocalExpress2.209s (-0.6%)3.159s (~)0.951s101.05x
💻 LocalNitro2.217s (+1.5%)3.177s (+1.5%)0.960s101.05x
🌐 StarterNext.js (Turbopack)2.477s (+0.8%)3.011s (~)0.534s101.18x
🌐 RedisNext.js (Turbopack)2.528s (+1.4%)3.034s (+0.7%)0.506s101.20x
🐘 PostgresNext.js (Turbopack)2.630s (+4.2%)3.013s (~)0.383s101.25x
🐘 PostgresNitro2.854s (+2.3%)3.012s (-0.7%)0.158s101.36x
🐘 PostgresExpress3.060s (+5.6% 🔺)3.362s (+8.0% 🔺)0.302s91.45x
🌐 MongoDBNext.js (Turbopack)4.718s (+1.9%)5.184s (~)0.466s62.24x
🌐 TursoNext.js (Turbopack)4.744s (+0.5%)5.184s (~)0.440s62.25x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro3.351s (+12.7% 🔺)3.810s (+6.0% 🔺)0.459s91.00x
▲ VercelExpress3.432s (+4.2%)3.969s (-1.9%)0.538s81.02x
▲ VercelNext.js (Turbopack)3.495s (+2.3%)3.962s (-3.3%)0.467s81.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

Promise.race with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.342s (-1.0%)2.007s (~)0.665s151.00x
🌐 RedisNext.js (Turbopack)1.376s (+1.5%)2.010s (~)0.635s151.02x
💻 LocalNext.js (Turbopack)1.395s (+2.8%)2.014s (~)0.619s151.04x
💻 LocalExpress1.420s (-0.7%)2.006s (~)0.585s151.06x
💻 LocalNitro1.422s (+0.7%)2.006s (~)0.585s151.06x
🐘 PostgresNext.js (Turbopack)1.663s (-6.6% 🟢)2.012s (~)0.349s151.24x
🐘 PostgresExpress1.784s (-21.3% 🟢)2.155s (-28.7% 🟢)0.372s141.33x
🐘 PostgresNitro1.975s (+8.0% 🔺)2.323s (+15.7% 🔺)0.348s131.47x
🌐 MongoDBNext.js (Turbopack)2.128s (-0.8%)3.014s (~)0.886s101.59x
🌐 TursoNext.js (Turbopack)2.225s (~)3.012s (~)0.787s101.66x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.745s (-3.5%)3.644s (-5.3% 🟢)0.900s91.00x
▲ VercelNitro2.886s (+4.4%)3.659s (+2.1%)0.773s91.05x
▲ VercelNext.js (Turbopack)2.890s (+3.8%)3.646s (-1.6%)0.756s91.05x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.210s (+7.3% 🔺)3.166s (+19.7% 🔺)0.956s101.00x
💻 LocalNitro2.237s (+0.9%)3.197s (+1.0%)0.960s101.01x
💻 LocalExpress2.265s (-0.6%)3.203s (~)0.938s101.02x
🌐 StarterNext.js (Turbopack)2.452s (-0.6%)3.010s (~)0.557s101.11x
🌐 RedisNext.js (Turbopack)2.507s (+1.2%)3.012s (~)0.505s101.13x
🐘 PostgresNext.js (Turbopack)2.664s (+9.7% 🔺)3.020s (~)0.356s101.21x
🐘 PostgresExpress2.879s (~)3.133s (+3.9%)0.253s101.30x
🐘 PostgresNitro2.966s (+18.7% 🔺)3.113s (+3.2%)0.147s101.34x
🌐 TursoNext.js (Turbopack)4.704s (-1.2%)5.183s (~)0.479s62.13x
🌐 MongoDBNext.js (Turbopack)4.705s (+0.6%)5.188s (~)0.483s62.13x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express3.355s (+4.6%)4.055s (+5.8% 🔺)0.700s81.00x
▲ VercelNitro3.438s (+7.9% 🔺)4.112s (+11.9% 🔺)0.674s81.02x
▲ VercelNext.js (Turbopack)3.828s (+18.1% 🔺)4.480s (+16.5% 🔺)0.652s71.14x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Stream Benchmarks(includes TTFB metrics)
workflow with stream

💻 Local Development

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)0.136s (+34.8% 🔺)1.003s (~)0.016s (-2.4%)1.027s (~)0.891s101.00x
🌐 StarterNext.js (Turbopack)0.139s (+7.9% 🔺)1.005s (~)0.000s (NaN%)1.011s (~)0.873s101.02x
🌐 RedisNext.js (Turbopack)0.151s (+5.0%)1.005s (~)0.000s (NaN%)1.014s (~)0.863s101.11x
💻 LocalNitro0.177s (+1.4%)0.993s (~)0.020s (+28.9% 🔺)1.026s (~)0.849s101.30x
💻 LocalExpress0.186s (+6.0% 🔺)0.993s (~)0.015s (-10.2% 🟢)1.023s (~)0.837s101.37x
🌐 TursoNext.js (Turbopack)0.478s (-5.6% 🟢)0.973s (+2.9%)0.000s (+Infinity% 🔺)1.014s (~)0.536s103.51x
🌐 MongoDBNext.js (Turbopack)0.496s (+5.9% 🔺)0.952s (-2.9%)0.000s (+Infinity% 🔺)1.015s (~)0.519s103.64x
🐘 PostgresNext.js (Turbopack)0.784s (-33.9% 🟢)0.883s (-52.6% 🟢)0.000s (+Infinity% 🔺)1.015s (-49.7% 🟢)0.231s105.75x
🐘 PostgresExpress2.183s (-7.3% 🟢)2.859s (+6.5% 🔺)0.000s (+Infinity% 🔺)3.015s (~)0.832s1016.02x
🐘 PostgresNitro2.334s (+1.1%)2.706s (-1.0%)0.000s (NaN%)3.012s (~)0.678s1017.12x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.840s (+1.7%)3.169s (-3.9%)0.680s (+110.8% 🔺)4.326s (+4.8%)1.486s101.00x
▲ VercelNext.js (Turbopack)2.848s (+1.5%)3.248s (+2.6%)0.502s (-23.1% 🟢)4.162s (-2.8%)1.314s101.00x
▲ VercelNitro2.880s (-8.2% 🟢)3.203s (-13.0% 🟢)0.631s (-28.5% 🟢)4.273s (-13.7% 🟢)1.393s101.01x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World🥇 Fastest FrameworkWins
💻 LocalNext.js (Turbopack)8/8
🐘 PostgresNext.js (Turbopack)7/8
▲ VercelNitro4/8
Fastest World by Framework

Winner determined by most benchmark wins

Framework🥇 Fastest WorldWins
Express💻 Local8/8
Next.js (Turbopack)🌐 Starter4/8
Nitro💻 Local8/8
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Starter: Community world (local development)
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

…ool calls
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a critical bug in Gemini thinking models (e.g., gemini-3-pro-preview) where multi-turn tool calls were failing with "function call is missing a thought_signature" error. The fix ensures that providerMetadata from tool calls is correctly mapped to providerOptions when reconstructing the conversation prompt for subsequent turns.

Key Changes:

  • Map providerMetadata to providerOptions when adding tool calls to conversation history
  • Add comprehensive test coverage for the providerMetadata preservation logic
  • Document the fix in a changeset for release notes

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

FileDescription
packages/ai/src/agent/stream-text-iterator.tsAdded logic to map providerMetadata from tool calls to providerOptions in the conversation prompt, with detailed inline comments explaining the critical nature of this mapping for Gemini thinking models
packages/ai/src/agent/stream-text-iterator.test.tsAdded comprehensive test suite with 4 test cases covering: single tool call with metadata, tool call without metadata, multiple parallel tool calls, and mixed scenarios with and without metadata
.changeset/fix-provider-metadata-tool-calls.mdAdded changeset describing the bug fix for release documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

];

// Second iteration - should trigger second doStreamStep call
const secondResult = await iterator.next(toolResults);

CopilotAIJan 7, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused variable secondResult.

Suggested change
constsecondResult=awaititerator.next(toolResults);
awaititerator.next(toolResults);

Copilot uses AI. Check for mistakes.

@VaguelySeriousVaguelySerious left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test looks not too useful, but no harm in merging IMO

@VaguelySerious
VaguelySerious merged commit 4b43186 into mainJan 8, 2026
89 of 91 checks passed
@VaguelySerious
VaguelySerious deleted the pranaygp/fix-727 branch January 8, 2026 09:56
TooTallNate added a commit that referenced this pull request Jan 12, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
VaguelySerious added a commit that referenced this pull request Jan 16, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto 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.

Gemini tool-calls fail after first step because thought_signature is dropped

3 participants

@pranaygp@VaguelySerious
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Add copy buttons to all
 blocks\n(function() {\n function addCopyButtons() {\n document.querySelectorAll('pre code').forEach(function(codeBlock) {\n if (codeBlock.parentElement.hasAttribute('data-copy-added')) return;\n codeBlock.parentElement.setAttribute('data-copy-added', 'true');\n \n var btn = document.createElement('button');\n btn.textContent = 'Copy';\n btn.style.cssText = 'position:absolute;top:4px;right:4px;padding:2px 8px;font-size:11px;background:#4ecdc4;border:none;border-radius:4px;color:#1a1a2e;cursor:pointer;opacity:0.7;transition:opacity 0.2s;';\n btn.onmouseover = function() { this.style.opacity = '1'; };\n btn.onmouseout = function() { this.style.opacity = '0.7'; };\n btn.onclick = function() {\n navigator.clipboard.writeText(codeBlock.textContent).then(function() {\n btn.textContent = 'Copied!';\n setTimeout(function() { btn.textContent = 'Copy'; }, 1500);\n });\n };\n codeBlock.parentElement.style.position = 'relative';\n codeBlock.parentElement.appendChild(btn);\n });\n }\n \n addCopyButtons();\n \n // Re-run on dynamic content\n var observer = new MutationObserver(addCopyButtons);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Add Copy Buttons to Code Blocks");
}
} catch(__e) { console.warn('[Userscript:Add Copy Buttons to Code Blocks]', __e); }
})();
(function(){
try {
var __m = "github.com";
var __re = new RegExp('^' + "github\\.com" + '
Skip to content

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls - #733

Merged
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727
Jan 8, 2026
Merged

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls#733
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727

Conversation

@pranaygp

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Gemini thinking models (e.g., gemini-3-pro-preview) that require thoughtSignature to be preserved across multi-turn tool calls
  • Maps providerMetadata from tool call responses to providerOptions in the conversation prompt, following the AI SDK convention

Problem

When using Gemini thinking models with tool calls, multi-turn conversations fail with:

function call is missing a thought_signature

This happens because providerMetadata (which contains thoughtSignature) from the tool call was not being passed back to the provider when reconstructing the conversation prompt.

Solution

In stream-text-iterator.ts, when adding tool calls to the conversation history, we now map providerMetadataproviderOptions:

conversationPrompt.push({role: 'assistant',content: toolCalls.map((toolCall)=>({type: 'tool-call',toolCallId: toolCall.toolCallId,toolName: toolCall.toolName,input: JSON.parse(toolCall.input),
...(toolCall.providerMetadata!=null
? {providerOptions: toolCall.providerMetadata}
: {}),})),});

This follows the same pattern used in the AI SDK's to-response-messages.ts.

Testing

Added comprehensive tests in stream-text-iterator.test.ts:

  • Preserving providerMetadata as providerOptions in tool-call messages
  • Not adding providerOptions when providerMetadata is undefined
  • Preserving providerMetadata for multiple parallel tool calls
  • Handling mixed tool calls with and without providerMetadata

Fixes#727

CopilotAI review requested due to automatic review settings January 7, 2026 06:18
@changeset-bot

changeset-botBot commented Jan 7, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7da7897

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@workflow/aiPatch
@workflow/docs-typecheckPatch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

Summary

PassedFailedSkippedTotal
✅ ▲ Vercel Production363011374
❌ 💻 Local Development299338340
✅ 📦 Local Production33208340
✅ 🐘 Local Postgres33208340
✅ 🪟 Windows340034
❌ 🌍 Community Worlds131170148
Total149150351576

❌ Failed Tests

💻 Local Development (33 failed)

nitro-stable (33 failed):

  • addTenWorkflow
  • addTenWorkflow
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • readableStreamWorkflow
  • hookWorkflow
  • webhookWorkflow
  • webhook route with invalid token
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • outputStreamWorkflow
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • stepDirectCallWorkflow - calling step functions directly outside workflow context
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check endpoint - workflow and step endpoints respond to __health query parameter
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
🌍 Community Worlds (17 failed)

mongodb (1 failed):

  • webhookWorkflow

redis (1 failed):

  • webhookWorkflow

starter (14 failed):

  • addTenWorkflow
  • addTenWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly

turso (1 failed):

  • webhookWorkflow

Details by Category

✅ ▲ Vercel Production
AppPassedFailedSkipped
✅ astro3301
✅ example3301
✅ express3301
✅ fastify3301
✅ hono3301
✅ nextjs-turbopack3301
✅ nextjs-webpack3301
✅ nitro3301
✅ nuxt3301
✅ sveltekit3301
✅ vite3301
❌ 💻 Local Development
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
❌ nitro-stable0331
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 📦 Local Production
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🐘 Local Postgres
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🪟 Windows
AppPassedFailedSkipped
✅ nextjs-turbopack3400
❌ 🌍 Community Worlds
AppPassedFailedSkipped
✅ mongodb-dev300
❌ mongodb3310
✅ redis-dev300
❌ redis3310
✅ starter-dev300
❌ starter20140
✅ turso-dev300
❌ turso3310

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: success
  • Local Dev: failure
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)0.037s (-1.1%)1.014s (~)0.977s101.00x
💻 LocalNext.js (Turbopack)0.038s (+10.7% 🔺)1.014s (~)0.975s101.03x
🌐 RedisNext.js (Turbopack)0.041s (-1.7%)1.017s (~)0.976s101.11x
💻 LocalNitro0.044s (-10.2% 🟢)1.006s (-0.8%)0.962s101.18x
💻 LocalExpress0.046s (+5.2% 🔺)1.008s (~)0.961s101.25x
🌐 MongoDBNext.js (Turbopack)0.083s (-30.1% 🟢)1.016s (~)0.934s102.23x
🌐 TursoNext.js (Turbopack)0.106s (+26.5% 🔺)1.014s (~)0.907s102.86x
🐘 PostgresExpress0.221s (-35.6% 🟢)1.014s (~)0.793s105.95x
🐘 PostgresNext.js (Turbopack)0.252s (+65.9% 🔺)1.029s (+1.0%)0.777s106.78x
🐘 PostgresNitro0.299s (+0.9%)1.012s (~)0.714s108.03x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro0.575s (-15.6% 🟢)1.423s (-15.2% 🟢)0.848s101.00x
▲ VercelExpress0.609s (-6.4% 🟢)1.435s (-15.6% 🟢)0.826s101.06x
▲ VercelNext.js (Turbopack)0.709s (-5.5% 🟢)1.532s (-9.8% 🟢)0.823s101.23x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.086s (+0.5%)2.011s (~)0.925s101.00x
💻 LocalNext.js (Turbopack)1.098s (+1.5%)2.012s (~)0.914s101.01x
🌐 RedisNext.js (Turbopack)1.106s (~)2.012s (~)0.906s101.02x
💻 LocalNitro1.113s (~)2.006s (~)0.893s101.02x
💻 LocalExpress1.118s (~)2.008s (~)0.890s101.03x
🌐 MongoDBNext.js (Turbopack)1.275s (-1.5%)2.017s (~)0.742s101.17x
🌐 TursoNext.js (Turbopack)1.308s (+1.3%)2.012s (~)0.704s101.20x
🐘 PostgresNext.js (Turbopack)1.660s (-11.0% 🟢)2.015s (~)0.355s101.53x
🐘 PostgresNitro2.158s (~)3.013s (~)0.855s101.99x
🐘 PostgresExpress2.254s (+2.6%)3.014s (~)0.761s102.08x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro2.637s (-11.0% 🟢)3.575s (-4.2%)0.938s101.00x
▲ VercelExpress2.650s (-16.4% 🟢)3.658s (-12.3% 🟢)1.007s101.01x
▲ VercelNext.js (Turbopack)2.712s (-11.7% 🟢)3.530s (-10.1% 🟢)0.817s101.03x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)10.606s (~)11.012s (~)0.406s51.00x
💻 LocalNext.js (Turbopack)10.653s (+1.4%)11.018s (~)0.365s51.00x
🌐 RedisNext.js (Turbopack)10.666s (~)11.016s (~)0.349s51.01x
💻 LocalNitro10.794s (~)11.012s (~)0.218s51.02x
💻 LocalExpress10.819s (~)11.016s (~)0.197s51.02x
🌐 MongoDBNext.js (Turbopack)12.068s (-1.2%)12.628s (-3.1%)0.560s51.14x
🌐 TursoNext.js (Turbopack)12.182s (~)13.023s (~)0.840s51.15x
🐘 PostgresNext.js (Turbopack)13.714s (-9.9% 🟢)14.235s (-11.2% 🟢)0.521s51.29x
🐘 PostgresExpress20.395s (~)21.036s (~)0.641s51.92x
🐘 PostgresNitro20.505s (~)21.029s (~)0.525s51.93x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro22.177s (+1.2%)22.860s (+1.0%)0.683s51.00x
▲ VercelNext.js (Turbopack)22.274s (~)22.897s (-0.9%)0.623s51.00x
▲ VercelExpress22.821s (+1.9%)23.459s (~)0.638s51.03x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Redis🥇 Next.js (Turbopack)1.348s (-1.1%)2.010s (~)0.662s151.00x
🌐 StarterNext.js (Turbopack)1.361s (+1.4%)2.008s (~)0.646s151.01x
💻 LocalNext.js (Turbopack)1.383s (+3.5%)2.012s (~)0.629s151.03x
💻 LocalNitro1.415s (~)2.005s (~)0.590s151.05x
💻 LocalExpress1.429s (+1.7%)2.007s (~)0.579s151.06x
🐘 PostgresNext.js (Turbopack)1.953s (+1.5%)2.160s (~)0.207s141.45x
🌐 MongoDBNext.js (Turbopack)2.144s (+1.2%)3.015s (~)0.871s101.59x
🌐 TursoNext.js (Turbopack)2.203s (-0.9%)3.013s (~)0.810s101.63x
🐘 PostgresNitro2.449s (+3.3%)3.010s (~)0.562s101.82x
🐘 PostgresExpress2.510s (+2.9%)3.015s (~)0.505s101.86x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.821s (~)3.588s (-9.5% 🟢)0.767s91.00x
▲ VercelNitro3.075s (-9.4% 🟢)4.000s (-7.9% 🟢)0.925s81.09x
▲ VercelNext.js (Turbopack)3.140s (-11.6% 🟢)3.954s (-9.1% 🟢)0.814s81.11x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.105s (+5.5% 🔺)3.022s (+39.8% 🔺)0.917s101.00x
💻 LocalExpress2.209s (-0.6%)3.159s (~)0.951s101.05x
💻 LocalNitro2.217s (+1.5%)3.177s (+1.5%)0.960s101.05x
🌐 StarterNext.js (Turbopack)2.477s (+0.8%)3.011s (~)0.534s101.18x
🌐 RedisNext.js (Turbopack)2.528s (+1.4%)3.034s (+0.7%)0.506s101.20x
🐘 PostgresNext.js (Turbopack)2.630s (+4.2%)3.013s (~)0.383s101.25x
🐘 PostgresNitro2.854s (+2.3%)3.012s (-0.7%)0.158s101.36x
🐘 PostgresExpress3.060s (+5.6% 🔺)3.362s (+8.0% 🔺)0.302s91.45x
🌐 MongoDBNext.js (Turbopack)4.718s (+1.9%)5.184s (~)0.466s62.24x
🌐 TursoNext.js (Turbopack)4.744s (+0.5%)5.184s (~)0.440s62.25x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro3.351s (+12.7% 🔺)3.810s (+6.0% 🔺)0.459s91.00x
▲ VercelExpress3.432s (+4.2%)3.969s (-1.9%)0.538s81.02x
▲ VercelNext.js (Turbopack)3.495s (+2.3%)3.962s (-3.3%)0.467s81.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

Promise.race with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.342s (-1.0%)2.007s (~)0.665s151.00x
🌐 RedisNext.js (Turbopack)1.376s (+1.5%)2.010s (~)0.635s151.02x
💻 LocalNext.js (Turbopack)1.395s (+2.8%)2.014s (~)0.619s151.04x
💻 LocalExpress1.420s (-0.7%)2.006s (~)0.585s151.06x
💻 LocalNitro1.422s (+0.7%)2.006s (~)0.585s151.06x
🐘 PostgresNext.js (Turbopack)1.663s (-6.6% 🟢)2.012s (~)0.349s151.24x
🐘 PostgresExpress1.784s (-21.3% 🟢)2.155s (-28.7% 🟢)0.372s141.33x
🐘 PostgresNitro1.975s (+8.0% 🔺)2.323s (+15.7% 🔺)0.348s131.47x
🌐 MongoDBNext.js (Turbopack)2.128s (-0.8%)3.014s (~)0.886s101.59x
🌐 TursoNext.js (Turbopack)2.225s (~)3.012s (~)0.787s101.66x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.745s (-3.5%)3.644s (-5.3% 🟢)0.900s91.00x
▲ VercelNitro2.886s (+4.4%)3.659s (+2.1%)0.773s91.05x
▲ VercelNext.js (Turbopack)2.890s (+3.8%)3.646s (-1.6%)0.756s91.05x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.210s (+7.3% 🔺)3.166s (+19.7% 🔺)0.956s101.00x
💻 LocalNitro2.237s (+0.9%)3.197s (+1.0%)0.960s101.01x
💻 LocalExpress2.265s (-0.6%)3.203s (~)0.938s101.02x
🌐 StarterNext.js (Turbopack)2.452s (-0.6%)3.010s (~)0.557s101.11x
🌐 RedisNext.js (Turbopack)2.507s (+1.2%)3.012s (~)0.505s101.13x
🐘 PostgresNext.js (Turbopack)2.664s (+9.7% 🔺)3.020s (~)0.356s101.21x
🐘 PostgresExpress2.879s (~)3.133s (+3.9%)0.253s101.30x
🐘 PostgresNitro2.966s (+18.7% 🔺)3.113s (+3.2%)0.147s101.34x
🌐 TursoNext.js (Turbopack)4.704s (-1.2%)5.183s (~)0.479s62.13x
🌐 MongoDBNext.js (Turbopack)4.705s (+0.6%)5.188s (~)0.483s62.13x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express3.355s (+4.6%)4.055s (+5.8% 🔺)0.700s81.00x
▲ VercelNitro3.438s (+7.9% 🔺)4.112s (+11.9% 🔺)0.674s81.02x
▲ VercelNext.js (Turbopack)3.828s (+18.1% 🔺)4.480s (+16.5% 🔺)0.652s71.14x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Stream Benchmarks(includes TTFB metrics)
workflow with stream

💻 Local Development

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)0.136s (+34.8% 🔺)1.003s (~)0.016s (-2.4%)1.027s (~)0.891s101.00x
🌐 StarterNext.js (Turbopack)0.139s (+7.9% 🔺)1.005s (~)0.000s (NaN%)1.011s (~)0.873s101.02x
🌐 RedisNext.js (Turbopack)0.151s (+5.0%)1.005s (~)0.000s (NaN%)1.014s (~)0.863s101.11x
💻 LocalNitro0.177s (+1.4%)0.993s (~)0.020s (+28.9% 🔺)1.026s (~)0.849s101.30x
💻 LocalExpress0.186s (+6.0% 🔺)0.993s (~)0.015s (-10.2% 🟢)1.023s (~)0.837s101.37x
🌐 TursoNext.js (Turbopack)0.478s (-5.6% 🟢)0.973s (+2.9%)0.000s (+Infinity% 🔺)1.014s (~)0.536s103.51x
🌐 MongoDBNext.js (Turbopack)0.496s (+5.9% 🔺)0.952s (-2.9%)0.000s (+Infinity% 🔺)1.015s (~)0.519s103.64x
🐘 PostgresNext.js (Turbopack)0.784s (-33.9% 🟢)0.883s (-52.6% 🟢)0.000s (+Infinity% 🔺)1.015s (-49.7% 🟢)0.231s105.75x
🐘 PostgresExpress2.183s (-7.3% 🟢)2.859s (+6.5% 🔺)0.000s (+Infinity% 🔺)3.015s (~)0.832s1016.02x
🐘 PostgresNitro2.334s (+1.1%)2.706s (-1.0%)0.000s (NaN%)3.012s (~)0.678s1017.12x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.840s (+1.7%)3.169s (-3.9%)0.680s (+110.8% 🔺)4.326s (+4.8%)1.486s101.00x
▲ VercelNext.js (Turbopack)2.848s (+1.5%)3.248s (+2.6%)0.502s (-23.1% 🟢)4.162s (-2.8%)1.314s101.00x
▲ VercelNitro2.880s (-8.2% 🟢)3.203s (-13.0% 🟢)0.631s (-28.5% 🟢)4.273s (-13.7% 🟢)1.393s101.01x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World🥇 Fastest FrameworkWins
💻 LocalNext.js (Turbopack)8/8
🐘 PostgresNext.js (Turbopack)7/8
▲ VercelNitro4/8
Fastest World by Framework

Winner determined by most benchmark wins

Framework🥇 Fastest WorldWins
Express💻 Local8/8
Next.js (Turbopack)🌐 Starter4/8
Nitro💻 Local8/8
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Starter: Community world (local development)
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

…ool calls
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a critical bug in Gemini thinking models (e.g., gemini-3-pro-preview) where multi-turn tool calls were failing with "function call is missing a thought_signature" error. The fix ensures that providerMetadata from tool calls is correctly mapped to providerOptions when reconstructing the conversation prompt for subsequent turns.

Key Changes:

  • Map providerMetadata to providerOptions when adding tool calls to conversation history
  • Add comprehensive test coverage for the providerMetadata preservation logic
  • Document the fix in a changeset for release notes

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

FileDescription
packages/ai/src/agent/stream-text-iterator.tsAdded logic to map providerMetadata from tool calls to providerOptions in the conversation prompt, with detailed inline comments explaining the critical nature of this mapping for Gemini thinking models
packages/ai/src/agent/stream-text-iterator.test.tsAdded comprehensive test suite with 4 test cases covering: single tool call with metadata, tool call without metadata, multiple parallel tool calls, and mixed scenarios with and without metadata
.changeset/fix-provider-metadata-tool-calls.mdAdded changeset describing the bug fix for release documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

];

// Second iteration - should trigger second doStreamStep call
const secondResult = await iterator.next(toolResults);

CopilotAIJan 7, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused variable secondResult.

Suggested change
constsecondResult=awaititerator.next(toolResults);
awaititerator.next(toolResults);

Copilot uses AI. Check for mistakes.

@VaguelySeriousVaguelySerious left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test looks not too useful, but no harm in merging IMO

@VaguelySerious
VaguelySerious merged commit 4b43186 into mainJan 8, 2026
89 of 91 checks passed
@VaguelySerious
VaguelySerious deleted the pranaygp/fix-727 branch January 8, 2026 09:56
TooTallNate added a commit that referenced this pull request Jan 12, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
VaguelySerious added a commit that referenced this pull request Jan 16, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto 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.

Gemini tool-calls fail after first step because thought_signature is dropped

3 participants

@pranaygp@VaguelySerious
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Force GitHub README to respect dark mode\n(function() {\n var style = document.createElement('style');\n style.textContent = '\n .markdown-body {\n color-scheme: dark light;\n }\n .markdown-body pre { background: #161b22 !important; }\n .markdown-body code { background: rgba(110, 118, 129, 0.4) !important; }\n .markdown-body table th, .markdown-body table td { border-color: #30363d !important; }\n .markdown-body img { background: #0d1117; }\n .markdown-body blockquote { border-left-color: #8b949e; }\n .markdown-body hr { border-color: #30363d; }\n ';\n document.head.appendChild(style);\n})();", "GitHub Dark Mode README Fix"); } } catch(__e) { console.warn('[Userscript:GitHub Dark Mode README Fix]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls - #733

Merged
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727
Jan 8, 2026
Merged

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls#733
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727

Conversation

@pranaygp

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Gemini thinking models (e.g., gemini-3-pro-preview) that require thoughtSignature to be preserved across multi-turn tool calls
  • Maps providerMetadata from tool call responses to providerOptions in the conversation prompt, following the AI SDK convention

Problem

When using Gemini thinking models with tool calls, multi-turn conversations fail with:

function call is missing a thought_signature

This happens because providerMetadata (which contains thoughtSignature) from the tool call was not being passed back to the provider when reconstructing the conversation prompt.

Solution

In stream-text-iterator.ts, when adding tool calls to the conversation history, we now map providerMetadataproviderOptions:

conversationPrompt.push({role: 'assistant',content: toolCalls.map((toolCall)=>({type: 'tool-call',toolCallId: toolCall.toolCallId,toolName: toolCall.toolName,input: JSON.parse(toolCall.input),
...(toolCall.providerMetadata!=null
? {providerOptions: toolCall.providerMetadata}
: {}),})),});

This follows the same pattern used in the AI SDK's to-response-messages.ts.

Testing

Added comprehensive tests in stream-text-iterator.test.ts:

  • Preserving providerMetadata as providerOptions in tool-call messages
  • Not adding providerOptions when providerMetadata is undefined
  • Preserving providerMetadata for multiple parallel tool calls
  • Handling mixed tool calls with and without providerMetadata

Fixes#727

CopilotAI review requested due to automatic review settings January 7, 2026 06:18
@changeset-bot

changeset-botBot commented Jan 7, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7da7897

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@workflow/aiPatch
@workflow/docs-typecheckPatch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

Summary

PassedFailedSkippedTotal
✅ ▲ Vercel Production363011374
❌ 💻 Local Development299338340
✅ 📦 Local Production33208340
✅ 🐘 Local Postgres33208340
✅ 🪟 Windows340034
❌ 🌍 Community Worlds131170148
Total149150351576

❌ Failed Tests

💻 Local Development (33 failed)

nitro-stable (33 failed):

  • addTenWorkflow
  • addTenWorkflow
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • readableStreamWorkflow
  • hookWorkflow
  • webhookWorkflow
  • webhook route with invalid token
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • outputStreamWorkflow
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • stepDirectCallWorkflow - calling step functions directly outside workflow context
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check endpoint - workflow and step endpoints respond to __health query parameter
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
🌍 Community Worlds (17 failed)

mongodb (1 failed):

  • webhookWorkflow

redis (1 failed):

  • webhookWorkflow

starter (14 failed):

  • addTenWorkflow
  • addTenWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly

turso (1 failed):

  • webhookWorkflow

Details by Category

✅ ▲ Vercel Production
AppPassedFailedSkipped
✅ astro3301
✅ example3301
✅ express3301
✅ fastify3301
✅ hono3301
✅ nextjs-turbopack3301
✅ nextjs-webpack3301
✅ nitro3301
✅ nuxt3301
✅ sveltekit3301
✅ vite3301
❌ 💻 Local Development
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
❌ nitro-stable0331
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 📦 Local Production
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🐘 Local Postgres
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🪟 Windows
AppPassedFailedSkipped
✅ nextjs-turbopack3400
❌ 🌍 Community Worlds
AppPassedFailedSkipped
✅ mongodb-dev300
❌ mongodb3310
✅ redis-dev300
❌ redis3310
✅ starter-dev300
❌ starter20140
✅ turso-dev300
❌ turso3310

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: success
  • Local Dev: failure
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)0.037s (-1.1%)1.014s (~)0.977s101.00x
💻 LocalNext.js (Turbopack)0.038s (+10.7% 🔺)1.014s (~)0.975s101.03x
🌐 RedisNext.js (Turbopack)0.041s (-1.7%)1.017s (~)0.976s101.11x
💻 LocalNitro0.044s (-10.2% 🟢)1.006s (-0.8%)0.962s101.18x
💻 LocalExpress0.046s (+5.2% 🔺)1.008s (~)0.961s101.25x
🌐 MongoDBNext.js (Turbopack)0.083s (-30.1% 🟢)1.016s (~)0.934s102.23x
🌐 TursoNext.js (Turbopack)0.106s (+26.5% 🔺)1.014s (~)0.907s102.86x
🐘 PostgresExpress0.221s (-35.6% 🟢)1.014s (~)0.793s105.95x
🐘 PostgresNext.js (Turbopack)0.252s (+65.9% 🔺)1.029s (+1.0%)0.777s106.78x
🐘 PostgresNitro0.299s (+0.9%)1.012s (~)0.714s108.03x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro0.575s (-15.6% 🟢)1.423s (-15.2% 🟢)0.848s101.00x
▲ VercelExpress0.609s (-6.4% 🟢)1.435s (-15.6% 🟢)0.826s101.06x
▲ VercelNext.js (Turbopack)0.709s (-5.5% 🟢)1.532s (-9.8% 🟢)0.823s101.23x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.086s (+0.5%)2.011s (~)0.925s101.00x
💻 LocalNext.js (Turbopack)1.098s (+1.5%)2.012s (~)0.914s101.01x
🌐 RedisNext.js (Turbopack)1.106s (~)2.012s (~)0.906s101.02x
💻 LocalNitro1.113s (~)2.006s (~)0.893s101.02x
💻 LocalExpress1.118s (~)2.008s (~)0.890s101.03x
🌐 MongoDBNext.js (Turbopack)1.275s (-1.5%)2.017s (~)0.742s101.17x
🌐 TursoNext.js (Turbopack)1.308s (+1.3%)2.012s (~)0.704s101.20x
🐘 PostgresNext.js (Turbopack)1.660s (-11.0% 🟢)2.015s (~)0.355s101.53x
🐘 PostgresNitro2.158s (~)3.013s (~)0.855s101.99x
🐘 PostgresExpress2.254s (+2.6%)3.014s (~)0.761s102.08x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro2.637s (-11.0% 🟢)3.575s (-4.2%)0.938s101.00x
▲ VercelExpress2.650s (-16.4% 🟢)3.658s (-12.3% 🟢)1.007s101.01x
▲ VercelNext.js (Turbopack)2.712s (-11.7% 🟢)3.530s (-10.1% 🟢)0.817s101.03x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)10.606s (~)11.012s (~)0.406s51.00x
💻 LocalNext.js (Turbopack)10.653s (+1.4%)11.018s (~)0.365s51.00x
🌐 RedisNext.js (Turbopack)10.666s (~)11.016s (~)0.349s51.01x
💻 LocalNitro10.794s (~)11.012s (~)0.218s51.02x
💻 LocalExpress10.819s (~)11.016s (~)0.197s51.02x
🌐 MongoDBNext.js (Turbopack)12.068s (-1.2%)12.628s (-3.1%)0.560s51.14x
🌐 TursoNext.js (Turbopack)12.182s (~)13.023s (~)0.840s51.15x
🐘 PostgresNext.js (Turbopack)13.714s (-9.9% 🟢)14.235s (-11.2% 🟢)0.521s51.29x
🐘 PostgresExpress20.395s (~)21.036s (~)0.641s51.92x
🐘 PostgresNitro20.505s (~)21.029s (~)0.525s51.93x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro22.177s (+1.2%)22.860s (+1.0%)0.683s51.00x
▲ VercelNext.js (Turbopack)22.274s (~)22.897s (-0.9%)0.623s51.00x
▲ VercelExpress22.821s (+1.9%)23.459s (~)0.638s51.03x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Redis🥇 Next.js (Turbopack)1.348s (-1.1%)2.010s (~)0.662s151.00x
🌐 StarterNext.js (Turbopack)1.361s (+1.4%)2.008s (~)0.646s151.01x
💻 LocalNext.js (Turbopack)1.383s (+3.5%)2.012s (~)0.629s151.03x
💻 LocalNitro1.415s (~)2.005s (~)0.590s151.05x
💻 LocalExpress1.429s (+1.7%)2.007s (~)0.579s151.06x
🐘 PostgresNext.js (Turbopack)1.953s (+1.5%)2.160s (~)0.207s141.45x
🌐 MongoDBNext.js (Turbopack)2.144s (+1.2%)3.015s (~)0.871s101.59x
🌐 TursoNext.js (Turbopack)2.203s (-0.9%)3.013s (~)0.810s101.63x
🐘 PostgresNitro2.449s (+3.3%)3.010s (~)0.562s101.82x
🐘 PostgresExpress2.510s (+2.9%)3.015s (~)0.505s101.86x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.821s (~)3.588s (-9.5% 🟢)0.767s91.00x
▲ VercelNitro3.075s (-9.4% 🟢)4.000s (-7.9% 🟢)0.925s81.09x
▲ VercelNext.js (Turbopack)3.140s (-11.6% 🟢)3.954s (-9.1% 🟢)0.814s81.11x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.105s (+5.5% 🔺)3.022s (+39.8% 🔺)0.917s101.00x
💻 LocalExpress2.209s (-0.6%)3.159s (~)0.951s101.05x
💻 LocalNitro2.217s (+1.5%)3.177s (+1.5%)0.960s101.05x
🌐 StarterNext.js (Turbopack)2.477s (+0.8%)3.011s (~)0.534s101.18x
🌐 RedisNext.js (Turbopack)2.528s (+1.4%)3.034s (+0.7%)0.506s101.20x
🐘 PostgresNext.js (Turbopack)2.630s (+4.2%)3.013s (~)0.383s101.25x
🐘 PostgresNitro2.854s (+2.3%)3.012s (-0.7%)0.158s101.36x
🐘 PostgresExpress3.060s (+5.6% 🔺)3.362s (+8.0% 🔺)0.302s91.45x
🌐 MongoDBNext.js (Turbopack)4.718s (+1.9%)5.184s (~)0.466s62.24x
🌐 TursoNext.js (Turbopack)4.744s (+0.5%)5.184s (~)0.440s62.25x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro3.351s (+12.7% 🔺)3.810s (+6.0% 🔺)0.459s91.00x
▲ VercelExpress3.432s (+4.2%)3.969s (-1.9%)0.538s81.02x
▲ VercelNext.js (Turbopack)3.495s (+2.3%)3.962s (-3.3%)0.467s81.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

Promise.race with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.342s (-1.0%)2.007s (~)0.665s151.00x
🌐 RedisNext.js (Turbopack)1.376s (+1.5%)2.010s (~)0.635s151.02x
💻 LocalNext.js (Turbopack)1.395s (+2.8%)2.014s (~)0.619s151.04x
💻 LocalExpress1.420s (-0.7%)2.006s (~)0.585s151.06x
💻 LocalNitro1.422s (+0.7%)2.006s (~)0.585s151.06x
🐘 PostgresNext.js (Turbopack)1.663s (-6.6% 🟢)2.012s (~)0.349s151.24x
🐘 PostgresExpress1.784s (-21.3% 🟢)2.155s (-28.7% 🟢)0.372s141.33x
🐘 PostgresNitro1.975s (+8.0% 🔺)2.323s (+15.7% 🔺)0.348s131.47x
🌐 MongoDBNext.js (Turbopack)2.128s (-0.8%)3.014s (~)0.886s101.59x
🌐 TursoNext.js (Turbopack)2.225s (~)3.012s (~)0.787s101.66x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.745s (-3.5%)3.644s (-5.3% 🟢)0.900s91.00x
▲ VercelNitro2.886s (+4.4%)3.659s (+2.1%)0.773s91.05x
▲ VercelNext.js (Turbopack)2.890s (+3.8%)3.646s (-1.6%)0.756s91.05x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.210s (+7.3% 🔺)3.166s (+19.7% 🔺)0.956s101.00x
💻 LocalNitro2.237s (+0.9%)3.197s (+1.0%)0.960s101.01x
💻 LocalExpress2.265s (-0.6%)3.203s (~)0.938s101.02x
🌐 StarterNext.js (Turbopack)2.452s (-0.6%)3.010s (~)0.557s101.11x
🌐 RedisNext.js (Turbopack)2.507s (+1.2%)3.012s (~)0.505s101.13x
🐘 PostgresNext.js (Turbopack)2.664s (+9.7% 🔺)3.020s (~)0.356s101.21x
🐘 PostgresExpress2.879s (~)3.133s (+3.9%)0.253s101.30x
🐘 PostgresNitro2.966s (+18.7% 🔺)3.113s (+3.2%)0.147s101.34x
🌐 TursoNext.js (Turbopack)4.704s (-1.2%)5.183s (~)0.479s62.13x
🌐 MongoDBNext.js (Turbopack)4.705s (+0.6%)5.188s (~)0.483s62.13x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express3.355s (+4.6%)4.055s (+5.8% 🔺)0.700s81.00x
▲ VercelNitro3.438s (+7.9% 🔺)4.112s (+11.9% 🔺)0.674s81.02x
▲ VercelNext.js (Turbopack)3.828s (+18.1% 🔺)4.480s (+16.5% 🔺)0.652s71.14x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Stream Benchmarks(includes TTFB metrics)
workflow with stream

💻 Local Development

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)0.136s (+34.8% 🔺)1.003s (~)0.016s (-2.4%)1.027s (~)0.891s101.00x
🌐 StarterNext.js (Turbopack)0.139s (+7.9% 🔺)1.005s (~)0.000s (NaN%)1.011s (~)0.873s101.02x
🌐 RedisNext.js (Turbopack)0.151s (+5.0%)1.005s (~)0.000s (NaN%)1.014s (~)0.863s101.11x
💻 LocalNitro0.177s (+1.4%)0.993s (~)0.020s (+28.9% 🔺)1.026s (~)0.849s101.30x
💻 LocalExpress0.186s (+6.0% 🔺)0.993s (~)0.015s (-10.2% 🟢)1.023s (~)0.837s101.37x
🌐 TursoNext.js (Turbopack)0.478s (-5.6% 🟢)0.973s (+2.9%)0.000s (+Infinity% 🔺)1.014s (~)0.536s103.51x
🌐 MongoDBNext.js (Turbopack)0.496s (+5.9% 🔺)0.952s (-2.9%)0.000s (+Infinity% 🔺)1.015s (~)0.519s103.64x
🐘 PostgresNext.js (Turbopack)0.784s (-33.9% 🟢)0.883s (-52.6% 🟢)0.000s (+Infinity% 🔺)1.015s (-49.7% 🟢)0.231s105.75x
🐘 PostgresExpress2.183s (-7.3% 🟢)2.859s (+6.5% 🔺)0.000s (+Infinity% 🔺)3.015s (~)0.832s1016.02x
🐘 PostgresNitro2.334s (+1.1%)2.706s (-1.0%)0.000s (NaN%)3.012s (~)0.678s1017.12x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.840s (+1.7%)3.169s (-3.9%)0.680s (+110.8% 🔺)4.326s (+4.8%)1.486s101.00x
▲ VercelNext.js (Turbopack)2.848s (+1.5%)3.248s (+2.6%)0.502s (-23.1% 🟢)4.162s (-2.8%)1.314s101.00x
▲ VercelNitro2.880s (-8.2% 🟢)3.203s (-13.0% 🟢)0.631s (-28.5% 🟢)4.273s (-13.7% 🟢)1.393s101.01x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World🥇 Fastest FrameworkWins
💻 LocalNext.js (Turbopack)8/8
🐘 PostgresNext.js (Turbopack)7/8
▲ VercelNitro4/8
Fastest World by Framework

Winner determined by most benchmark wins

Framework🥇 Fastest WorldWins
Express💻 Local8/8
Next.js (Turbopack)🌐 Starter4/8
Nitro💻 Local8/8
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Starter: Community world (local development)
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

…ool calls
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a critical bug in Gemini thinking models (e.g., gemini-3-pro-preview) where multi-turn tool calls were failing with "function call is missing a thought_signature" error. The fix ensures that providerMetadata from tool calls is correctly mapped to providerOptions when reconstructing the conversation prompt for subsequent turns.

Key Changes:

  • Map providerMetadata to providerOptions when adding tool calls to conversation history
  • Add comprehensive test coverage for the providerMetadata preservation logic
  • Document the fix in a changeset for release notes

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

FileDescription
packages/ai/src/agent/stream-text-iterator.tsAdded logic to map providerMetadata from tool calls to providerOptions in the conversation prompt, with detailed inline comments explaining the critical nature of this mapping for Gemini thinking models
packages/ai/src/agent/stream-text-iterator.test.tsAdded comprehensive test suite with 4 test cases covering: single tool call with metadata, tool call without metadata, multiple parallel tool calls, and mixed scenarios with and without metadata
.changeset/fix-provider-metadata-tool-calls.mdAdded changeset describing the bug fix for release documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

];

// Second iteration - should trigger second doStreamStep call
const secondResult = await iterator.next(toolResults);

CopilotAIJan 7, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused variable secondResult.

Suggested change
constsecondResult=awaititerator.next(toolResults);
awaititerator.next(toolResults);

Copilot uses AI. Check for mistakes.

@VaguelySeriousVaguelySerious left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test looks not too useful, but no harm in merging IMO

@VaguelySerious
VaguelySerious merged commit 4b43186 into mainJan 8, 2026
89 of 91 checks passed
@VaguelySerious
VaguelySerious deleted the pranaygp/fix-727 branch January 8, 2026 09:56
TooTallNate added a commit that referenced this pull request Jan 12, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
VaguelySerious added a commit that referenced this pull request Jan 16, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto 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.

Gemini tool-calls fail after first step because thought_signature is dropped

3 participants

@pranaygp@VaguelySerious
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Highlight search terms from Google/DuckDuckGo/Bing referrer\n(function() {\n var ref = document.referrer;\n var terms = [];\n \n if (ref.includes('google.com') || ref.includes('duckduckgo.com') || ref.includes('bing.com')) {\n var url = new URL(ref);\n var q = url.searchParams.get('q') || url.searchParams.get('p');\n if (q) {\n terms = q.split(/\\s+/).filter(function(t) { return t.length > 2; });\n }\n }\n \n if (terms.length === 0) return;\n \n var style = document.createElement('style');\n style.textContent = '.userscript-highlight { background: #fbbf24; color: #1a1a2e; padding: 1px 3px; border-radius: 2px; }';\n document.head.appendChild(style);\n \n function highlight(node) {\n if (node.nodeType === 3) { // text node\n var text = node.textContent;\n var found = false;\n terms.forEach(function(term) {\n var regex = new RegExp('(' + term.replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\') + ')', 'gi');\n if (regex.test(text)) {\n found = true;\n var frag = document.createDocumentFragment();\n var parts = text.split(regex);\n parts.forEach(function(part, i) {\n if (i % 2 === 0) {\n frag.appendChild(document.createTextNode(part));\n } else {\n var span = document.createElement('span');\n span.className = 'userscript-highlight';\n span.textContent = part;\n frag.appendChild(span);\n }\n });\n node.parentNode.replaceChild(frag, node);\n }\n });\n } else if (node.nodeType === 1 && node.childNodes) { // element\n var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT'];\n if (!skipTags.includes(node.tagName)) {\n Array.from(node.childNodes).forEach(highlight);\n }\n }\n }\n \n highlight(document.body);\n \n // Re-highlight on dynamic content\n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1 || node.nodeType === 3) highlight(node);\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Highlight Search Terms"); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls - #733

Merged
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727
Jan 8, 2026
Merged

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls#733
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727

Conversation

@pranaygp

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Gemini thinking models (e.g., gemini-3-pro-preview) that require thoughtSignature to be preserved across multi-turn tool calls
  • Maps providerMetadata from tool call responses to providerOptions in the conversation prompt, following the AI SDK convention

Problem

When using Gemini thinking models with tool calls, multi-turn conversations fail with:

function call is missing a thought_signature

This happens because providerMetadata (which contains thoughtSignature) from the tool call was not being passed back to the provider when reconstructing the conversation prompt.

Solution

In stream-text-iterator.ts, when adding tool calls to the conversation history, we now map providerMetadataproviderOptions:

conversationPrompt.push({role: 'assistant',content: toolCalls.map((toolCall)=>({type: 'tool-call',toolCallId: toolCall.toolCallId,toolName: toolCall.toolName,input: JSON.parse(toolCall.input),
...(toolCall.providerMetadata!=null
? {providerOptions: toolCall.providerMetadata}
: {}),})),});

This follows the same pattern used in the AI SDK's to-response-messages.ts.

Testing

Added comprehensive tests in stream-text-iterator.test.ts:

  • Preserving providerMetadata as providerOptions in tool-call messages
  • Not adding providerOptions when providerMetadata is undefined
  • Preserving providerMetadata for multiple parallel tool calls
  • Handling mixed tool calls with and without providerMetadata

Fixes#727

CopilotAI review requested due to automatic review settings January 7, 2026 06:18
@changeset-bot

changeset-botBot commented Jan 7, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7da7897

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@workflow/aiPatch
@workflow/docs-typecheckPatch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

Summary

PassedFailedSkippedTotal
✅ ▲ Vercel Production363011374
❌ 💻 Local Development299338340
✅ 📦 Local Production33208340
✅ 🐘 Local Postgres33208340
✅ 🪟 Windows340034
❌ 🌍 Community Worlds131170148
Total149150351576

❌ Failed Tests

💻 Local Development (33 failed)

nitro-stable (33 failed):

  • addTenWorkflow
  • addTenWorkflow
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • readableStreamWorkflow
  • hookWorkflow
  • webhookWorkflow
  • webhook route with invalid token
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • outputStreamWorkflow
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • stepDirectCallWorkflow - calling step functions directly outside workflow context
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check endpoint - workflow and step endpoints respond to __health query parameter
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
🌍 Community Worlds (17 failed)

mongodb (1 failed):

  • webhookWorkflow

redis (1 failed):

  • webhookWorkflow

starter (14 failed):

  • addTenWorkflow
  • addTenWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly

turso (1 failed):

  • webhookWorkflow

Details by Category

✅ ▲ Vercel Production
AppPassedFailedSkipped
✅ astro3301
✅ example3301
✅ express3301
✅ fastify3301
✅ hono3301
✅ nextjs-turbopack3301
✅ nextjs-webpack3301
✅ nitro3301
✅ nuxt3301
✅ sveltekit3301
✅ vite3301
❌ 💻 Local Development
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
❌ nitro-stable0331
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 📦 Local Production
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🐘 Local Postgres
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🪟 Windows
AppPassedFailedSkipped
✅ nextjs-turbopack3400
❌ 🌍 Community Worlds
AppPassedFailedSkipped
✅ mongodb-dev300
❌ mongodb3310
✅ redis-dev300
❌ redis3310
✅ starter-dev300
❌ starter20140
✅ turso-dev300
❌ turso3310

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: success
  • Local Dev: failure
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)0.037s (-1.1%)1.014s (~)0.977s101.00x
💻 LocalNext.js (Turbopack)0.038s (+10.7% 🔺)1.014s (~)0.975s101.03x
🌐 RedisNext.js (Turbopack)0.041s (-1.7%)1.017s (~)0.976s101.11x
💻 LocalNitro0.044s (-10.2% 🟢)1.006s (-0.8%)0.962s101.18x
💻 LocalExpress0.046s (+5.2% 🔺)1.008s (~)0.961s101.25x
🌐 MongoDBNext.js (Turbopack)0.083s (-30.1% 🟢)1.016s (~)0.934s102.23x
🌐 TursoNext.js (Turbopack)0.106s (+26.5% 🔺)1.014s (~)0.907s102.86x
🐘 PostgresExpress0.221s (-35.6% 🟢)1.014s (~)0.793s105.95x
🐘 PostgresNext.js (Turbopack)0.252s (+65.9% 🔺)1.029s (+1.0%)0.777s106.78x
🐘 PostgresNitro0.299s (+0.9%)1.012s (~)0.714s108.03x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro0.575s (-15.6% 🟢)1.423s (-15.2% 🟢)0.848s101.00x
▲ VercelExpress0.609s (-6.4% 🟢)1.435s (-15.6% 🟢)0.826s101.06x
▲ VercelNext.js (Turbopack)0.709s (-5.5% 🟢)1.532s (-9.8% 🟢)0.823s101.23x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.086s (+0.5%)2.011s (~)0.925s101.00x
💻 LocalNext.js (Turbopack)1.098s (+1.5%)2.012s (~)0.914s101.01x
🌐 RedisNext.js (Turbopack)1.106s (~)2.012s (~)0.906s101.02x
💻 LocalNitro1.113s (~)2.006s (~)0.893s101.02x
💻 LocalExpress1.118s (~)2.008s (~)0.890s101.03x
🌐 MongoDBNext.js (Turbopack)1.275s (-1.5%)2.017s (~)0.742s101.17x
🌐 TursoNext.js (Turbopack)1.308s (+1.3%)2.012s (~)0.704s101.20x
🐘 PostgresNext.js (Turbopack)1.660s (-11.0% 🟢)2.015s (~)0.355s101.53x
🐘 PostgresNitro2.158s (~)3.013s (~)0.855s101.99x
🐘 PostgresExpress2.254s (+2.6%)3.014s (~)0.761s102.08x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro2.637s (-11.0% 🟢)3.575s (-4.2%)0.938s101.00x
▲ VercelExpress2.650s (-16.4% 🟢)3.658s (-12.3% 🟢)1.007s101.01x
▲ VercelNext.js (Turbopack)2.712s (-11.7% 🟢)3.530s (-10.1% 🟢)0.817s101.03x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)10.606s (~)11.012s (~)0.406s51.00x
💻 LocalNext.js (Turbopack)10.653s (+1.4%)11.018s (~)0.365s51.00x
🌐 RedisNext.js (Turbopack)10.666s (~)11.016s (~)0.349s51.01x
💻 LocalNitro10.794s (~)11.012s (~)0.218s51.02x
💻 LocalExpress10.819s (~)11.016s (~)0.197s51.02x
🌐 MongoDBNext.js (Turbopack)12.068s (-1.2%)12.628s (-3.1%)0.560s51.14x
🌐 TursoNext.js (Turbopack)12.182s (~)13.023s (~)0.840s51.15x
🐘 PostgresNext.js (Turbopack)13.714s (-9.9% 🟢)14.235s (-11.2% 🟢)0.521s51.29x
🐘 PostgresExpress20.395s (~)21.036s (~)0.641s51.92x
🐘 PostgresNitro20.505s (~)21.029s (~)0.525s51.93x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro22.177s (+1.2%)22.860s (+1.0%)0.683s51.00x
▲ VercelNext.js (Turbopack)22.274s (~)22.897s (-0.9%)0.623s51.00x
▲ VercelExpress22.821s (+1.9%)23.459s (~)0.638s51.03x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Redis🥇 Next.js (Turbopack)1.348s (-1.1%)2.010s (~)0.662s151.00x
🌐 StarterNext.js (Turbopack)1.361s (+1.4%)2.008s (~)0.646s151.01x
💻 LocalNext.js (Turbopack)1.383s (+3.5%)2.012s (~)0.629s151.03x
💻 LocalNitro1.415s (~)2.005s (~)0.590s151.05x
💻 LocalExpress1.429s (+1.7%)2.007s (~)0.579s151.06x
🐘 PostgresNext.js (Turbopack)1.953s (+1.5%)2.160s (~)0.207s141.45x
🌐 MongoDBNext.js (Turbopack)2.144s (+1.2%)3.015s (~)0.871s101.59x
🌐 TursoNext.js (Turbopack)2.203s (-0.9%)3.013s (~)0.810s101.63x
🐘 PostgresNitro2.449s (+3.3%)3.010s (~)0.562s101.82x
🐘 PostgresExpress2.510s (+2.9%)3.015s (~)0.505s101.86x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.821s (~)3.588s (-9.5% 🟢)0.767s91.00x
▲ VercelNitro3.075s (-9.4% 🟢)4.000s (-7.9% 🟢)0.925s81.09x
▲ VercelNext.js (Turbopack)3.140s (-11.6% 🟢)3.954s (-9.1% 🟢)0.814s81.11x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.105s (+5.5% 🔺)3.022s (+39.8% 🔺)0.917s101.00x
💻 LocalExpress2.209s (-0.6%)3.159s (~)0.951s101.05x
💻 LocalNitro2.217s (+1.5%)3.177s (+1.5%)0.960s101.05x
🌐 StarterNext.js (Turbopack)2.477s (+0.8%)3.011s (~)0.534s101.18x
🌐 RedisNext.js (Turbopack)2.528s (+1.4%)3.034s (+0.7%)0.506s101.20x
🐘 PostgresNext.js (Turbopack)2.630s (+4.2%)3.013s (~)0.383s101.25x
🐘 PostgresNitro2.854s (+2.3%)3.012s (-0.7%)0.158s101.36x
🐘 PostgresExpress3.060s (+5.6% 🔺)3.362s (+8.0% 🔺)0.302s91.45x
🌐 MongoDBNext.js (Turbopack)4.718s (+1.9%)5.184s (~)0.466s62.24x
🌐 TursoNext.js (Turbopack)4.744s (+0.5%)5.184s (~)0.440s62.25x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro3.351s (+12.7% 🔺)3.810s (+6.0% 🔺)0.459s91.00x
▲ VercelExpress3.432s (+4.2%)3.969s (-1.9%)0.538s81.02x
▲ VercelNext.js (Turbopack)3.495s (+2.3%)3.962s (-3.3%)0.467s81.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

Promise.race with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.342s (-1.0%)2.007s (~)0.665s151.00x
🌐 RedisNext.js (Turbopack)1.376s (+1.5%)2.010s (~)0.635s151.02x
💻 LocalNext.js (Turbopack)1.395s (+2.8%)2.014s (~)0.619s151.04x
💻 LocalExpress1.420s (-0.7%)2.006s (~)0.585s151.06x
💻 LocalNitro1.422s (+0.7%)2.006s (~)0.585s151.06x
🐘 PostgresNext.js (Turbopack)1.663s (-6.6% 🟢)2.012s (~)0.349s151.24x
🐘 PostgresExpress1.784s (-21.3% 🟢)2.155s (-28.7% 🟢)0.372s141.33x
🐘 PostgresNitro1.975s (+8.0% 🔺)2.323s (+15.7% 🔺)0.348s131.47x
🌐 MongoDBNext.js (Turbopack)2.128s (-0.8%)3.014s (~)0.886s101.59x
🌐 TursoNext.js (Turbopack)2.225s (~)3.012s (~)0.787s101.66x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.745s (-3.5%)3.644s (-5.3% 🟢)0.900s91.00x
▲ VercelNitro2.886s (+4.4%)3.659s (+2.1%)0.773s91.05x
▲ VercelNext.js (Turbopack)2.890s (+3.8%)3.646s (-1.6%)0.756s91.05x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.210s (+7.3% 🔺)3.166s (+19.7% 🔺)0.956s101.00x
💻 LocalNitro2.237s (+0.9%)3.197s (+1.0%)0.960s101.01x
💻 LocalExpress2.265s (-0.6%)3.203s (~)0.938s101.02x
🌐 StarterNext.js (Turbopack)2.452s (-0.6%)3.010s (~)0.557s101.11x
🌐 RedisNext.js (Turbopack)2.507s (+1.2%)3.012s (~)0.505s101.13x
🐘 PostgresNext.js (Turbopack)2.664s (+9.7% 🔺)3.020s (~)0.356s101.21x
🐘 PostgresExpress2.879s (~)3.133s (+3.9%)0.253s101.30x
🐘 PostgresNitro2.966s (+18.7% 🔺)3.113s (+3.2%)0.147s101.34x
🌐 TursoNext.js (Turbopack)4.704s (-1.2%)5.183s (~)0.479s62.13x
🌐 MongoDBNext.js (Turbopack)4.705s (+0.6%)5.188s (~)0.483s62.13x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express3.355s (+4.6%)4.055s (+5.8% 🔺)0.700s81.00x
▲ VercelNitro3.438s (+7.9% 🔺)4.112s (+11.9% 🔺)0.674s81.02x
▲ VercelNext.js (Turbopack)3.828s (+18.1% 🔺)4.480s (+16.5% 🔺)0.652s71.14x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Stream Benchmarks(includes TTFB metrics)
workflow with stream

💻 Local Development

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)0.136s (+34.8% 🔺)1.003s (~)0.016s (-2.4%)1.027s (~)0.891s101.00x
🌐 StarterNext.js (Turbopack)0.139s (+7.9% 🔺)1.005s (~)0.000s (NaN%)1.011s (~)0.873s101.02x
🌐 RedisNext.js (Turbopack)0.151s (+5.0%)1.005s (~)0.000s (NaN%)1.014s (~)0.863s101.11x
💻 LocalNitro0.177s (+1.4%)0.993s (~)0.020s (+28.9% 🔺)1.026s (~)0.849s101.30x
💻 LocalExpress0.186s (+6.0% 🔺)0.993s (~)0.015s (-10.2% 🟢)1.023s (~)0.837s101.37x
🌐 TursoNext.js (Turbopack)0.478s (-5.6% 🟢)0.973s (+2.9%)0.000s (+Infinity% 🔺)1.014s (~)0.536s103.51x
🌐 MongoDBNext.js (Turbopack)0.496s (+5.9% 🔺)0.952s (-2.9%)0.000s (+Infinity% 🔺)1.015s (~)0.519s103.64x
🐘 PostgresNext.js (Turbopack)0.784s (-33.9% 🟢)0.883s (-52.6% 🟢)0.000s (+Infinity% 🔺)1.015s (-49.7% 🟢)0.231s105.75x
🐘 PostgresExpress2.183s (-7.3% 🟢)2.859s (+6.5% 🔺)0.000s (+Infinity% 🔺)3.015s (~)0.832s1016.02x
🐘 PostgresNitro2.334s (+1.1%)2.706s (-1.0%)0.000s (NaN%)3.012s (~)0.678s1017.12x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.840s (+1.7%)3.169s (-3.9%)0.680s (+110.8% 🔺)4.326s (+4.8%)1.486s101.00x
▲ VercelNext.js (Turbopack)2.848s (+1.5%)3.248s (+2.6%)0.502s (-23.1% 🟢)4.162s (-2.8%)1.314s101.00x
▲ VercelNitro2.880s (-8.2% 🟢)3.203s (-13.0% 🟢)0.631s (-28.5% 🟢)4.273s (-13.7% 🟢)1.393s101.01x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World🥇 Fastest FrameworkWins
💻 LocalNext.js (Turbopack)8/8
🐘 PostgresNext.js (Turbopack)7/8
▲ VercelNitro4/8
Fastest World by Framework

Winner determined by most benchmark wins

Framework🥇 Fastest WorldWins
Express💻 Local8/8
Next.js (Turbopack)🌐 Starter4/8
Nitro💻 Local8/8
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Starter: Community world (local development)
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

…ool calls
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a critical bug in Gemini thinking models (e.g., gemini-3-pro-preview) where multi-turn tool calls were failing with "function call is missing a thought_signature" error. The fix ensures that providerMetadata from tool calls is correctly mapped to providerOptions when reconstructing the conversation prompt for subsequent turns.

Key Changes:

  • Map providerMetadata to providerOptions when adding tool calls to conversation history
  • Add comprehensive test coverage for the providerMetadata preservation logic
  • Document the fix in a changeset for release notes

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

FileDescription
packages/ai/src/agent/stream-text-iterator.tsAdded logic to map providerMetadata from tool calls to providerOptions in the conversation prompt, with detailed inline comments explaining the critical nature of this mapping for Gemini thinking models
packages/ai/src/agent/stream-text-iterator.test.tsAdded comprehensive test suite with 4 test cases covering: single tool call with metadata, tool call without metadata, multiple parallel tool calls, and mixed scenarios with and without metadata
.changeset/fix-provider-metadata-tool-calls.mdAdded changeset describing the bug fix for release documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

];

// Second iteration - should trigger second doStreamStep call
const secondResult = await iterator.next(toolResults);

CopilotAIJan 7, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused variable secondResult.

Suggested change
constsecondResult=awaititerator.next(toolResults);
awaititerator.next(toolResults);

Copilot uses AI. Check for mistakes.

@VaguelySeriousVaguelySerious left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test looks not too useful, but no harm in merging IMO

@VaguelySerious
VaguelySerious merged commit 4b43186 into mainJan 8, 2026
89 of 91 checks passed
@VaguelySerious
VaguelySerious deleted the pranaygp/fix-727 branch January 8, 2026 09:56
TooTallNate added a commit that referenced this pull request Jan 12, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
VaguelySerious added a commit that referenced this pull request Jan 16, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto 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.

Gemini tool-calls fail after first step because thought_signature is dropped

3 participants

@pranaygp@VaguelySerious
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Strip utm_, fbclid, gclid, etc. from all links on page\n(function() {\n var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content',\n 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid',\n 'ref', 'ref_src', 'source', 'medium', 'campaign'];\n \n function cleanUrl(url) {\n try {\n var u = new URL(url, window.location.origin);\n var changed = false;\n trackingParams.forEach(function(p) {\n if (u.searchParams.has(p)) {\n u.searchParams.delete(p);\n changed = true;\n }\n });\n return changed ? u.toString() : url;\n } catch (e) {\n return url;\n }\n }\n \n function cleanLinks() {\n document.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n \n cleanLinks();\n \n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1) {\n if (node.tagName === 'A') cleanLinks();\n node.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Remove Tracking Parameters from Links"); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + '
Skip to content

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls - #733

Merged
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727
Jan 8, 2026
Merged

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls#733
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727

Conversation

@pranaygp

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Gemini thinking models (e.g., gemini-3-pro-preview) that require thoughtSignature to be preserved across multi-turn tool calls
  • Maps providerMetadata from tool call responses to providerOptions in the conversation prompt, following the AI SDK convention

Problem

When using Gemini thinking models with tool calls, multi-turn conversations fail with:

function call is missing a thought_signature

This happens because providerMetadata (which contains thoughtSignature) from the tool call was not being passed back to the provider when reconstructing the conversation prompt.

Solution

In stream-text-iterator.ts, when adding tool calls to the conversation history, we now map providerMetadataproviderOptions:

conversationPrompt.push({role: 'assistant',content: toolCalls.map((toolCall)=>({type: 'tool-call',toolCallId: toolCall.toolCallId,toolName: toolCall.toolName,input: JSON.parse(toolCall.input),
...(toolCall.providerMetadata!=null
? {providerOptions: toolCall.providerMetadata}
: {}),})),});

This follows the same pattern used in the AI SDK's to-response-messages.ts.

Testing

Added comprehensive tests in stream-text-iterator.test.ts:

  • Preserving providerMetadata as providerOptions in tool-call messages
  • Not adding providerOptions when providerMetadata is undefined
  • Preserving providerMetadata for multiple parallel tool calls
  • Handling mixed tool calls with and without providerMetadata

Fixes#727

CopilotAI review requested due to automatic review settings January 7, 2026 06:18
@changeset-bot

changeset-botBot commented Jan 7, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7da7897

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@workflow/aiPatch
@workflow/docs-typecheckPatch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

Summary

PassedFailedSkippedTotal
✅ ▲ Vercel Production363011374
❌ 💻 Local Development299338340
✅ 📦 Local Production33208340
✅ 🐘 Local Postgres33208340
✅ 🪟 Windows340034
❌ 🌍 Community Worlds131170148
Total149150351576

❌ Failed Tests

💻 Local Development (33 failed)

nitro-stable (33 failed):

  • addTenWorkflow
  • addTenWorkflow
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • readableStreamWorkflow
  • hookWorkflow
  • webhookWorkflow
  • webhook route with invalid token
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • outputStreamWorkflow
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • stepDirectCallWorkflow - calling step functions directly outside workflow context
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check endpoint - workflow and step endpoints respond to __health query parameter
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
🌍 Community Worlds (17 failed)

mongodb (1 failed):

  • webhookWorkflow

redis (1 failed):

  • webhookWorkflow

starter (14 failed):

  • addTenWorkflow
  • addTenWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly

turso (1 failed):

  • webhookWorkflow

Details by Category

✅ ▲ Vercel Production
AppPassedFailedSkipped
✅ astro3301
✅ example3301
✅ express3301
✅ fastify3301
✅ hono3301
✅ nextjs-turbopack3301
✅ nextjs-webpack3301
✅ nitro3301
✅ nuxt3301
✅ sveltekit3301
✅ vite3301
❌ 💻 Local Development
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
❌ nitro-stable0331
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 📦 Local Production
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🐘 Local Postgres
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🪟 Windows
AppPassedFailedSkipped
✅ nextjs-turbopack3400
❌ 🌍 Community Worlds
AppPassedFailedSkipped
✅ mongodb-dev300
❌ mongodb3310
✅ redis-dev300
❌ redis3310
✅ starter-dev300
❌ starter20140
✅ turso-dev300
❌ turso3310

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: success
  • Local Dev: failure
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)0.037s (-1.1%)1.014s (~)0.977s101.00x
💻 LocalNext.js (Turbopack)0.038s (+10.7% 🔺)1.014s (~)0.975s101.03x
🌐 RedisNext.js (Turbopack)0.041s (-1.7%)1.017s (~)0.976s101.11x
💻 LocalNitro0.044s (-10.2% 🟢)1.006s (-0.8%)0.962s101.18x
💻 LocalExpress0.046s (+5.2% 🔺)1.008s (~)0.961s101.25x
🌐 MongoDBNext.js (Turbopack)0.083s (-30.1% 🟢)1.016s (~)0.934s102.23x
🌐 TursoNext.js (Turbopack)0.106s (+26.5% 🔺)1.014s (~)0.907s102.86x
🐘 PostgresExpress0.221s (-35.6% 🟢)1.014s (~)0.793s105.95x
🐘 PostgresNext.js (Turbopack)0.252s (+65.9% 🔺)1.029s (+1.0%)0.777s106.78x
🐘 PostgresNitro0.299s (+0.9%)1.012s (~)0.714s108.03x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro0.575s (-15.6% 🟢)1.423s (-15.2% 🟢)0.848s101.00x
▲ VercelExpress0.609s (-6.4% 🟢)1.435s (-15.6% 🟢)0.826s101.06x
▲ VercelNext.js (Turbopack)0.709s (-5.5% 🟢)1.532s (-9.8% 🟢)0.823s101.23x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.086s (+0.5%)2.011s (~)0.925s101.00x
💻 LocalNext.js (Turbopack)1.098s (+1.5%)2.012s (~)0.914s101.01x
🌐 RedisNext.js (Turbopack)1.106s (~)2.012s (~)0.906s101.02x
💻 LocalNitro1.113s (~)2.006s (~)0.893s101.02x
💻 LocalExpress1.118s (~)2.008s (~)0.890s101.03x
🌐 MongoDBNext.js (Turbopack)1.275s (-1.5%)2.017s (~)0.742s101.17x
🌐 TursoNext.js (Turbopack)1.308s (+1.3%)2.012s (~)0.704s101.20x
🐘 PostgresNext.js (Turbopack)1.660s (-11.0% 🟢)2.015s (~)0.355s101.53x
🐘 PostgresNitro2.158s (~)3.013s (~)0.855s101.99x
🐘 PostgresExpress2.254s (+2.6%)3.014s (~)0.761s102.08x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro2.637s (-11.0% 🟢)3.575s (-4.2%)0.938s101.00x
▲ VercelExpress2.650s (-16.4% 🟢)3.658s (-12.3% 🟢)1.007s101.01x
▲ VercelNext.js (Turbopack)2.712s (-11.7% 🟢)3.530s (-10.1% 🟢)0.817s101.03x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)10.606s (~)11.012s (~)0.406s51.00x
💻 LocalNext.js (Turbopack)10.653s (+1.4%)11.018s (~)0.365s51.00x
🌐 RedisNext.js (Turbopack)10.666s (~)11.016s (~)0.349s51.01x
💻 LocalNitro10.794s (~)11.012s (~)0.218s51.02x
💻 LocalExpress10.819s (~)11.016s (~)0.197s51.02x
🌐 MongoDBNext.js (Turbopack)12.068s (-1.2%)12.628s (-3.1%)0.560s51.14x
🌐 TursoNext.js (Turbopack)12.182s (~)13.023s (~)0.840s51.15x
🐘 PostgresNext.js (Turbopack)13.714s (-9.9% 🟢)14.235s (-11.2% 🟢)0.521s51.29x
🐘 PostgresExpress20.395s (~)21.036s (~)0.641s51.92x
🐘 PostgresNitro20.505s (~)21.029s (~)0.525s51.93x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro22.177s (+1.2%)22.860s (+1.0%)0.683s51.00x
▲ VercelNext.js (Turbopack)22.274s (~)22.897s (-0.9%)0.623s51.00x
▲ VercelExpress22.821s (+1.9%)23.459s (~)0.638s51.03x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Redis🥇 Next.js (Turbopack)1.348s (-1.1%)2.010s (~)0.662s151.00x
🌐 StarterNext.js (Turbopack)1.361s (+1.4%)2.008s (~)0.646s151.01x
💻 LocalNext.js (Turbopack)1.383s (+3.5%)2.012s (~)0.629s151.03x
💻 LocalNitro1.415s (~)2.005s (~)0.590s151.05x
💻 LocalExpress1.429s (+1.7%)2.007s (~)0.579s151.06x
🐘 PostgresNext.js (Turbopack)1.953s (+1.5%)2.160s (~)0.207s141.45x
🌐 MongoDBNext.js (Turbopack)2.144s (+1.2%)3.015s (~)0.871s101.59x
🌐 TursoNext.js (Turbopack)2.203s (-0.9%)3.013s (~)0.810s101.63x
🐘 PostgresNitro2.449s (+3.3%)3.010s (~)0.562s101.82x
🐘 PostgresExpress2.510s (+2.9%)3.015s (~)0.505s101.86x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.821s (~)3.588s (-9.5% 🟢)0.767s91.00x
▲ VercelNitro3.075s (-9.4% 🟢)4.000s (-7.9% 🟢)0.925s81.09x
▲ VercelNext.js (Turbopack)3.140s (-11.6% 🟢)3.954s (-9.1% 🟢)0.814s81.11x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.105s (+5.5% 🔺)3.022s (+39.8% 🔺)0.917s101.00x
💻 LocalExpress2.209s (-0.6%)3.159s (~)0.951s101.05x
💻 LocalNitro2.217s (+1.5%)3.177s (+1.5%)0.960s101.05x
🌐 StarterNext.js (Turbopack)2.477s (+0.8%)3.011s (~)0.534s101.18x
🌐 RedisNext.js (Turbopack)2.528s (+1.4%)3.034s (+0.7%)0.506s101.20x
🐘 PostgresNext.js (Turbopack)2.630s (+4.2%)3.013s (~)0.383s101.25x
🐘 PostgresNitro2.854s (+2.3%)3.012s (-0.7%)0.158s101.36x
🐘 PostgresExpress3.060s (+5.6% 🔺)3.362s (+8.0% 🔺)0.302s91.45x
🌐 MongoDBNext.js (Turbopack)4.718s (+1.9%)5.184s (~)0.466s62.24x
🌐 TursoNext.js (Turbopack)4.744s (+0.5%)5.184s (~)0.440s62.25x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro3.351s (+12.7% 🔺)3.810s (+6.0% 🔺)0.459s91.00x
▲ VercelExpress3.432s (+4.2%)3.969s (-1.9%)0.538s81.02x
▲ VercelNext.js (Turbopack)3.495s (+2.3%)3.962s (-3.3%)0.467s81.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

Promise.race with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.342s (-1.0%)2.007s (~)0.665s151.00x
🌐 RedisNext.js (Turbopack)1.376s (+1.5%)2.010s (~)0.635s151.02x
💻 LocalNext.js (Turbopack)1.395s (+2.8%)2.014s (~)0.619s151.04x
💻 LocalExpress1.420s (-0.7%)2.006s (~)0.585s151.06x
💻 LocalNitro1.422s (+0.7%)2.006s (~)0.585s151.06x
🐘 PostgresNext.js (Turbopack)1.663s (-6.6% 🟢)2.012s (~)0.349s151.24x
🐘 PostgresExpress1.784s (-21.3% 🟢)2.155s (-28.7% 🟢)0.372s141.33x
🐘 PostgresNitro1.975s (+8.0% 🔺)2.323s (+15.7% 🔺)0.348s131.47x
🌐 MongoDBNext.js (Turbopack)2.128s (-0.8%)3.014s (~)0.886s101.59x
🌐 TursoNext.js (Turbopack)2.225s (~)3.012s (~)0.787s101.66x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.745s (-3.5%)3.644s (-5.3% 🟢)0.900s91.00x
▲ VercelNitro2.886s (+4.4%)3.659s (+2.1%)0.773s91.05x
▲ VercelNext.js (Turbopack)2.890s (+3.8%)3.646s (-1.6%)0.756s91.05x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.210s (+7.3% 🔺)3.166s (+19.7% 🔺)0.956s101.00x
💻 LocalNitro2.237s (+0.9%)3.197s (+1.0%)0.960s101.01x
💻 LocalExpress2.265s (-0.6%)3.203s (~)0.938s101.02x
🌐 StarterNext.js (Turbopack)2.452s (-0.6%)3.010s (~)0.557s101.11x
🌐 RedisNext.js (Turbopack)2.507s (+1.2%)3.012s (~)0.505s101.13x
🐘 PostgresNext.js (Turbopack)2.664s (+9.7% 🔺)3.020s (~)0.356s101.21x
🐘 PostgresExpress2.879s (~)3.133s (+3.9%)0.253s101.30x
🐘 PostgresNitro2.966s (+18.7% 🔺)3.113s (+3.2%)0.147s101.34x
🌐 TursoNext.js (Turbopack)4.704s (-1.2%)5.183s (~)0.479s62.13x
🌐 MongoDBNext.js (Turbopack)4.705s (+0.6%)5.188s (~)0.483s62.13x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express3.355s (+4.6%)4.055s (+5.8% 🔺)0.700s81.00x
▲ VercelNitro3.438s (+7.9% 🔺)4.112s (+11.9% 🔺)0.674s81.02x
▲ VercelNext.js (Turbopack)3.828s (+18.1% 🔺)4.480s (+16.5% 🔺)0.652s71.14x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Stream Benchmarks(includes TTFB metrics)
workflow with stream

💻 Local Development

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)0.136s (+34.8% 🔺)1.003s (~)0.016s (-2.4%)1.027s (~)0.891s101.00x
🌐 StarterNext.js (Turbopack)0.139s (+7.9% 🔺)1.005s (~)0.000s (NaN%)1.011s (~)0.873s101.02x
🌐 RedisNext.js (Turbopack)0.151s (+5.0%)1.005s (~)0.000s (NaN%)1.014s (~)0.863s101.11x
💻 LocalNitro0.177s (+1.4%)0.993s (~)0.020s (+28.9% 🔺)1.026s (~)0.849s101.30x
💻 LocalExpress0.186s (+6.0% 🔺)0.993s (~)0.015s (-10.2% 🟢)1.023s (~)0.837s101.37x
🌐 TursoNext.js (Turbopack)0.478s (-5.6% 🟢)0.973s (+2.9%)0.000s (+Infinity% 🔺)1.014s (~)0.536s103.51x
🌐 MongoDBNext.js (Turbopack)0.496s (+5.9% 🔺)0.952s (-2.9%)0.000s (+Infinity% 🔺)1.015s (~)0.519s103.64x
🐘 PostgresNext.js (Turbopack)0.784s (-33.9% 🟢)0.883s (-52.6% 🟢)0.000s (+Infinity% 🔺)1.015s (-49.7% 🟢)0.231s105.75x
🐘 PostgresExpress2.183s (-7.3% 🟢)2.859s (+6.5% 🔺)0.000s (+Infinity% 🔺)3.015s (~)0.832s1016.02x
🐘 PostgresNitro2.334s (+1.1%)2.706s (-1.0%)0.000s (NaN%)3.012s (~)0.678s1017.12x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.840s (+1.7%)3.169s (-3.9%)0.680s (+110.8% 🔺)4.326s (+4.8%)1.486s101.00x
▲ VercelNext.js (Turbopack)2.848s (+1.5%)3.248s (+2.6%)0.502s (-23.1% 🟢)4.162s (-2.8%)1.314s101.00x
▲ VercelNitro2.880s (-8.2% 🟢)3.203s (-13.0% 🟢)0.631s (-28.5% 🟢)4.273s (-13.7% 🟢)1.393s101.01x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World🥇 Fastest FrameworkWins
💻 LocalNext.js (Turbopack)8/8
🐘 PostgresNext.js (Turbopack)7/8
▲ VercelNitro4/8
Fastest World by Framework

Winner determined by most benchmark wins

Framework🥇 Fastest WorldWins
Express💻 Local8/8
Next.js (Turbopack)🌐 Starter4/8
Nitro💻 Local8/8
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Starter: Community world (local development)
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

…ool calls
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a critical bug in Gemini thinking models (e.g., gemini-3-pro-preview) where multi-turn tool calls were failing with "function call is missing a thought_signature" error. The fix ensures that providerMetadata from tool calls is correctly mapped to providerOptions when reconstructing the conversation prompt for subsequent turns.

Key Changes:

  • Map providerMetadata to providerOptions when adding tool calls to conversation history
  • Add comprehensive test coverage for the providerMetadata preservation logic
  • Document the fix in a changeset for release notes

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

FileDescription
packages/ai/src/agent/stream-text-iterator.tsAdded logic to map providerMetadata from tool calls to providerOptions in the conversation prompt, with detailed inline comments explaining the critical nature of this mapping for Gemini thinking models
packages/ai/src/agent/stream-text-iterator.test.tsAdded comprehensive test suite with 4 test cases covering: single tool call with metadata, tool call without metadata, multiple parallel tool calls, and mixed scenarios with and without metadata
.changeset/fix-provider-metadata-tool-calls.mdAdded changeset describing the bug fix for release documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

];

// Second iteration - should trigger second doStreamStep call
const secondResult = await iterator.next(toolResults);

CopilotAIJan 7, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused variable secondResult.

Suggested change
constsecondResult=awaititerator.next(toolResults);
awaititerator.next(toolResults);

Copilot uses AI. Check for mistakes.

@VaguelySeriousVaguelySerious left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test looks not too useful, but no harm in merging IMO

@VaguelySerious
VaguelySerious merged commit 4b43186 into mainJan 8, 2026
89 of 91 checks passed
@VaguelySerious
VaguelySerious deleted the pranaygp/fix-727 branch January 8, 2026 09:56
TooTallNate added a commit that referenced this pull request Jan 12, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
VaguelySerious added a commit that referenced this pull request Jan 16, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto 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.

Gemini tool-calls fail after first step because thought_signature is dropped

3 participants

@pranaygp@VaguelySerious
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Auto-enable theater mode on YouTube\n(function() {\n function tryTheater() {\n var btn = document.querySelector('button[aria-label=\"Theater mode\"], ytd-player #player button[title=\"Theater mode\"]');\n if (btn && !btn.classList.contains('activated')) {\n btn.click();\n }\n }\n \n // Try immediately\n tryTheater();\n \n // Try after navigation (SPA)\n var lastUrl = location.href;\n setInterval(function() {\n if (location.href !== lastUrl) {\n lastUrl = location.href;\n setTimeout(tryTheater, 500);\n }\n }, 1000);\n \n // Also try on player load\n var observer = new MutationObserver(tryTheater);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "YouTube Theater Mode Default"); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls - #733

Merged
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727
Jan 8, 2026
Merged

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls#733
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727

Conversation

@pranaygp

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Gemini thinking models (e.g., gemini-3-pro-preview) that require thoughtSignature to be preserved across multi-turn tool calls
  • Maps providerMetadata from tool call responses to providerOptions in the conversation prompt, following the AI SDK convention

Problem

When using Gemini thinking models with tool calls, multi-turn conversations fail with:

function call is missing a thought_signature

This happens because providerMetadata (which contains thoughtSignature) from the tool call was not being passed back to the provider when reconstructing the conversation prompt.

Solution

In stream-text-iterator.ts, when adding tool calls to the conversation history, we now map providerMetadataproviderOptions:

conversationPrompt.push({role: 'assistant',content: toolCalls.map((toolCall)=>({type: 'tool-call',toolCallId: toolCall.toolCallId,toolName: toolCall.toolName,input: JSON.parse(toolCall.input),
...(toolCall.providerMetadata!=null
? {providerOptions: toolCall.providerMetadata}
: {}),})),});

This follows the same pattern used in the AI SDK's to-response-messages.ts.

Testing

Added comprehensive tests in stream-text-iterator.test.ts:

  • Preserving providerMetadata as providerOptions in tool-call messages
  • Not adding providerOptions when providerMetadata is undefined
  • Preserving providerMetadata for multiple parallel tool calls
  • Handling mixed tool calls with and without providerMetadata

Fixes#727

CopilotAI review requested due to automatic review settings January 7, 2026 06:18
@changeset-bot

changeset-botBot commented Jan 7, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7da7897

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@workflow/aiPatch
@workflow/docs-typecheckPatch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

Summary

PassedFailedSkippedTotal
✅ ▲ Vercel Production363011374
❌ 💻 Local Development299338340
✅ 📦 Local Production33208340
✅ 🐘 Local Postgres33208340
✅ 🪟 Windows340034
❌ 🌍 Community Worlds131170148
Total149150351576

❌ Failed Tests

💻 Local Development (33 failed)

nitro-stable (33 failed):

  • addTenWorkflow
  • addTenWorkflow
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • readableStreamWorkflow
  • hookWorkflow
  • webhookWorkflow
  • webhook route with invalid token
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • outputStreamWorkflow
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • stepDirectCallWorkflow - calling step functions directly outside workflow context
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check endpoint - workflow and step endpoints respond to __health query parameter
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
🌍 Community Worlds (17 failed)

mongodb (1 failed):

  • webhookWorkflow

redis (1 failed):

  • webhookWorkflow

starter (14 failed):

  • addTenWorkflow
  • addTenWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly

turso (1 failed):

  • webhookWorkflow

Details by Category

✅ ▲ Vercel Production
AppPassedFailedSkipped
✅ astro3301
✅ example3301
✅ express3301
✅ fastify3301
✅ hono3301
✅ nextjs-turbopack3301
✅ nextjs-webpack3301
✅ nitro3301
✅ nuxt3301
✅ sveltekit3301
✅ vite3301
❌ 💻 Local Development
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
❌ nitro-stable0331
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 📦 Local Production
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🐘 Local Postgres
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🪟 Windows
AppPassedFailedSkipped
✅ nextjs-turbopack3400
❌ 🌍 Community Worlds
AppPassedFailedSkipped
✅ mongodb-dev300
❌ mongodb3310
✅ redis-dev300
❌ redis3310
✅ starter-dev300
❌ starter20140
✅ turso-dev300
❌ turso3310

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: success
  • Local Dev: failure
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)0.037s (-1.1%)1.014s (~)0.977s101.00x
💻 LocalNext.js (Turbopack)0.038s (+10.7% 🔺)1.014s (~)0.975s101.03x
🌐 RedisNext.js (Turbopack)0.041s (-1.7%)1.017s (~)0.976s101.11x
💻 LocalNitro0.044s (-10.2% 🟢)1.006s (-0.8%)0.962s101.18x
💻 LocalExpress0.046s (+5.2% 🔺)1.008s (~)0.961s101.25x
🌐 MongoDBNext.js (Turbopack)0.083s (-30.1% 🟢)1.016s (~)0.934s102.23x
🌐 TursoNext.js (Turbopack)0.106s (+26.5% 🔺)1.014s (~)0.907s102.86x
🐘 PostgresExpress0.221s (-35.6% 🟢)1.014s (~)0.793s105.95x
🐘 PostgresNext.js (Turbopack)0.252s (+65.9% 🔺)1.029s (+1.0%)0.777s106.78x
🐘 PostgresNitro0.299s (+0.9%)1.012s (~)0.714s108.03x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro0.575s (-15.6% 🟢)1.423s (-15.2% 🟢)0.848s101.00x
▲ VercelExpress0.609s (-6.4% 🟢)1.435s (-15.6% 🟢)0.826s101.06x
▲ VercelNext.js (Turbopack)0.709s (-5.5% 🟢)1.532s (-9.8% 🟢)0.823s101.23x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.086s (+0.5%)2.011s (~)0.925s101.00x
💻 LocalNext.js (Turbopack)1.098s (+1.5%)2.012s (~)0.914s101.01x
🌐 RedisNext.js (Turbopack)1.106s (~)2.012s (~)0.906s101.02x
💻 LocalNitro1.113s (~)2.006s (~)0.893s101.02x
💻 LocalExpress1.118s (~)2.008s (~)0.890s101.03x
🌐 MongoDBNext.js (Turbopack)1.275s (-1.5%)2.017s (~)0.742s101.17x
🌐 TursoNext.js (Turbopack)1.308s (+1.3%)2.012s (~)0.704s101.20x
🐘 PostgresNext.js (Turbopack)1.660s (-11.0% 🟢)2.015s (~)0.355s101.53x
🐘 PostgresNitro2.158s (~)3.013s (~)0.855s101.99x
🐘 PostgresExpress2.254s (+2.6%)3.014s (~)0.761s102.08x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro2.637s (-11.0% 🟢)3.575s (-4.2%)0.938s101.00x
▲ VercelExpress2.650s (-16.4% 🟢)3.658s (-12.3% 🟢)1.007s101.01x
▲ VercelNext.js (Turbopack)2.712s (-11.7% 🟢)3.530s (-10.1% 🟢)0.817s101.03x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)10.606s (~)11.012s (~)0.406s51.00x
💻 LocalNext.js (Turbopack)10.653s (+1.4%)11.018s (~)0.365s51.00x
🌐 RedisNext.js (Turbopack)10.666s (~)11.016s (~)0.349s51.01x
💻 LocalNitro10.794s (~)11.012s (~)0.218s51.02x
💻 LocalExpress10.819s (~)11.016s (~)0.197s51.02x
🌐 MongoDBNext.js (Turbopack)12.068s (-1.2%)12.628s (-3.1%)0.560s51.14x
🌐 TursoNext.js (Turbopack)12.182s (~)13.023s (~)0.840s51.15x
🐘 PostgresNext.js (Turbopack)13.714s (-9.9% 🟢)14.235s (-11.2% 🟢)0.521s51.29x
🐘 PostgresExpress20.395s (~)21.036s (~)0.641s51.92x
🐘 PostgresNitro20.505s (~)21.029s (~)0.525s51.93x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro22.177s (+1.2%)22.860s (+1.0%)0.683s51.00x
▲ VercelNext.js (Turbopack)22.274s (~)22.897s (-0.9%)0.623s51.00x
▲ VercelExpress22.821s (+1.9%)23.459s (~)0.638s51.03x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Redis🥇 Next.js (Turbopack)1.348s (-1.1%)2.010s (~)0.662s151.00x
🌐 StarterNext.js (Turbopack)1.361s (+1.4%)2.008s (~)0.646s151.01x
💻 LocalNext.js (Turbopack)1.383s (+3.5%)2.012s (~)0.629s151.03x
💻 LocalNitro1.415s (~)2.005s (~)0.590s151.05x
💻 LocalExpress1.429s (+1.7%)2.007s (~)0.579s151.06x
🐘 PostgresNext.js (Turbopack)1.953s (+1.5%)2.160s (~)0.207s141.45x
🌐 MongoDBNext.js (Turbopack)2.144s (+1.2%)3.015s (~)0.871s101.59x
🌐 TursoNext.js (Turbopack)2.203s (-0.9%)3.013s (~)0.810s101.63x
🐘 PostgresNitro2.449s (+3.3%)3.010s (~)0.562s101.82x
🐘 PostgresExpress2.510s (+2.9%)3.015s (~)0.505s101.86x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.821s (~)3.588s (-9.5% 🟢)0.767s91.00x
▲ VercelNitro3.075s (-9.4% 🟢)4.000s (-7.9% 🟢)0.925s81.09x
▲ VercelNext.js (Turbopack)3.140s (-11.6% 🟢)3.954s (-9.1% 🟢)0.814s81.11x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.105s (+5.5% 🔺)3.022s (+39.8% 🔺)0.917s101.00x
💻 LocalExpress2.209s (-0.6%)3.159s (~)0.951s101.05x
💻 LocalNitro2.217s (+1.5%)3.177s (+1.5%)0.960s101.05x
🌐 StarterNext.js (Turbopack)2.477s (+0.8%)3.011s (~)0.534s101.18x
🌐 RedisNext.js (Turbopack)2.528s (+1.4%)3.034s (+0.7%)0.506s101.20x
🐘 PostgresNext.js (Turbopack)2.630s (+4.2%)3.013s (~)0.383s101.25x
🐘 PostgresNitro2.854s (+2.3%)3.012s (-0.7%)0.158s101.36x
🐘 PostgresExpress3.060s (+5.6% 🔺)3.362s (+8.0% 🔺)0.302s91.45x
🌐 MongoDBNext.js (Turbopack)4.718s (+1.9%)5.184s (~)0.466s62.24x
🌐 TursoNext.js (Turbopack)4.744s (+0.5%)5.184s (~)0.440s62.25x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro3.351s (+12.7% 🔺)3.810s (+6.0% 🔺)0.459s91.00x
▲ VercelExpress3.432s (+4.2%)3.969s (-1.9%)0.538s81.02x
▲ VercelNext.js (Turbopack)3.495s (+2.3%)3.962s (-3.3%)0.467s81.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

Promise.race with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.342s (-1.0%)2.007s (~)0.665s151.00x
🌐 RedisNext.js (Turbopack)1.376s (+1.5%)2.010s (~)0.635s151.02x
💻 LocalNext.js (Turbopack)1.395s (+2.8%)2.014s (~)0.619s151.04x
💻 LocalExpress1.420s (-0.7%)2.006s (~)0.585s151.06x
💻 LocalNitro1.422s (+0.7%)2.006s (~)0.585s151.06x
🐘 PostgresNext.js (Turbopack)1.663s (-6.6% 🟢)2.012s (~)0.349s151.24x
🐘 PostgresExpress1.784s (-21.3% 🟢)2.155s (-28.7% 🟢)0.372s141.33x
🐘 PostgresNitro1.975s (+8.0% 🔺)2.323s (+15.7% 🔺)0.348s131.47x
🌐 MongoDBNext.js (Turbopack)2.128s (-0.8%)3.014s (~)0.886s101.59x
🌐 TursoNext.js (Turbopack)2.225s (~)3.012s (~)0.787s101.66x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.745s (-3.5%)3.644s (-5.3% 🟢)0.900s91.00x
▲ VercelNitro2.886s (+4.4%)3.659s (+2.1%)0.773s91.05x
▲ VercelNext.js (Turbopack)2.890s (+3.8%)3.646s (-1.6%)0.756s91.05x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.210s (+7.3% 🔺)3.166s (+19.7% 🔺)0.956s101.00x
💻 LocalNitro2.237s (+0.9%)3.197s (+1.0%)0.960s101.01x
💻 LocalExpress2.265s (-0.6%)3.203s (~)0.938s101.02x
🌐 StarterNext.js (Turbopack)2.452s (-0.6%)3.010s (~)0.557s101.11x
🌐 RedisNext.js (Turbopack)2.507s (+1.2%)3.012s (~)0.505s101.13x
🐘 PostgresNext.js (Turbopack)2.664s (+9.7% 🔺)3.020s (~)0.356s101.21x
🐘 PostgresExpress2.879s (~)3.133s (+3.9%)0.253s101.30x
🐘 PostgresNitro2.966s (+18.7% 🔺)3.113s (+3.2%)0.147s101.34x
🌐 TursoNext.js (Turbopack)4.704s (-1.2%)5.183s (~)0.479s62.13x
🌐 MongoDBNext.js (Turbopack)4.705s (+0.6%)5.188s (~)0.483s62.13x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express3.355s (+4.6%)4.055s (+5.8% 🔺)0.700s81.00x
▲ VercelNitro3.438s (+7.9% 🔺)4.112s (+11.9% 🔺)0.674s81.02x
▲ VercelNext.js (Turbopack)3.828s (+18.1% 🔺)4.480s (+16.5% 🔺)0.652s71.14x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Stream Benchmarks(includes TTFB metrics)
workflow with stream

💻 Local Development

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)0.136s (+34.8% 🔺)1.003s (~)0.016s (-2.4%)1.027s (~)0.891s101.00x
🌐 StarterNext.js (Turbopack)0.139s (+7.9% 🔺)1.005s (~)0.000s (NaN%)1.011s (~)0.873s101.02x
🌐 RedisNext.js (Turbopack)0.151s (+5.0%)1.005s (~)0.000s (NaN%)1.014s (~)0.863s101.11x
💻 LocalNitro0.177s (+1.4%)0.993s (~)0.020s (+28.9% 🔺)1.026s (~)0.849s101.30x
💻 LocalExpress0.186s (+6.0% 🔺)0.993s (~)0.015s (-10.2% 🟢)1.023s (~)0.837s101.37x
🌐 TursoNext.js (Turbopack)0.478s (-5.6% 🟢)0.973s (+2.9%)0.000s (+Infinity% 🔺)1.014s (~)0.536s103.51x
🌐 MongoDBNext.js (Turbopack)0.496s (+5.9% 🔺)0.952s (-2.9%)0.000s (+Infinity% 🔺)1.015s (~)0.519s103.64x
🐘 PostgresNext.js (Turbopack)0.784s (-33.9% 🟢)0.883s (-52.6% 🟢)0.000s (+Infinity% 🔺)1.015s (-49.7% 🟢)0.231s105.75x
🐘 PostgresExpress2.183s (-7.3% 🟢)2.859s (+6.5% 🔺)0.000s (+Infinity% 🔺)3.015s (~)0.832s1016.02x
🐘 PostgresNitro2.334s (+1.1%)2.706s (-1.0%)0.000s (NaN%)3.012s (~)0.678s1017.12x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.840s (+1.7%)3.169s (-3.9%)0.680s (+110.8% 🔺)4.326s (+4.8%)1.486s101.00x
▲ VercelNext.js (Turbopack)2.848s (+1.5%)3.248s (+2.6%)0.502s (-23.1% 🟢)4.162s (-2.8%)1.314s101.00x
▲ VercelNitro2.880s (-8.2% 🟢)3.203s (-13.0% 🟢)0.631s (-28.5% 🟢)4.273s (-13.7% 🟢)1.393s101.01x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World🥇 Fastest FrameworkWins
💻 LocalNext.js (Turbopack)8/8
🐘 PostgresNext.js (Turbopack)7/8
▲ VercelNitro4/8
Fastest World by Framework

Winner determined by most benchmark wins

Framework🥇 Fastest WorldWins
Express💻 Local8/8
Next.js (Turbopack)🌐 Starter4/8
Nitro💻 Local8/8
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Starter: Community world (local development)
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

…ool calls
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a critical bug in Gemini thinking models (e.g., gemini-3-pro-preview) where multi-turn tool calls were failing with "function call is missing a thought_signature" error. The fix ensures that providerMetadata from tool calls is correctly mapped to providerOptions when reconstructing the conversation prompt for subsequent turns.

Key Changes:

  • Map providerMetadata to providerOptions when adding tool calls to conversation history
  • Add comprehensive test coverage for the providerMetadata preservation logic
  • Document the fix in a changeset for release notes

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

FileDescription
packages/ai/src/agent/stream-text-iterator.tsAdded logic to map providerMetadata from tool calls to providerOptions in the conversation prompt, with detailed inline comments explaining the critical nature of this mapping for Gemini thinking models
packages/ai/src/agent/stream-text-iterator.test.tsAdded comprehensive test suite with 4 test cases covering: single tool call with metadata, tool call without metadata, multiple parallel tool calls, and mixed scenarios with and without metadata
.changeset/fix-provider-metadata-tool-calls.mdAdded changeset describing the bug fix for release documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

];

// Second iteration - should trigger second doStreamStep call
const secondResult = await iterator.next(toolResults);

CopilotAIJan 7, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused variable secondResult.

Suggested change
constsecondResult=awaititerator.next(toolResults);
awaititerator.next(toolResults);

Copilot uses AI. Check for mistakes.

@VaguelySeriousVaguelySerious left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test looks not too useful, but no harm in merging IMO

@VaguelySerious
VaguelySerious merged commit 4b43186 into mainJan 8, 2026
89 of 91 checks passed
@VaguelySerious
VaguelySerious deleted the pranaygp/fix-727 branch January 8, 2026 09:56
TooTallNate added a commit that referenced this pull request Jan 12, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
VaguelySerious added a commit that referenced this pull request Jan 16, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto 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.

Gemini tool-calls fail after first step because thought_signature is dropped

3 participants

@pranaygp@VaguelySerious
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Remove or un-stick sticky/fixed headers that block content\n(function() {\n function unstick() {\n document.querySelectorAll('header, nav, [role=\"banner\"], .header, .navbar, .sticky, .fixed-top, [style*=\"position: fixed\"], [style*=\"position:sticky\"]').forEach(function(el) {\n if (el.style.position === 'fixed' || el.style.position === 'sticky' || \n getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') {\n el.style.position = 'static';\n el.style.top = 'auto';\n el.style.zIndex = 'auto';\n }\n });\n }\n \n unstick();\n \n var observer = new MutationObserver(unstick);\n observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] });\n})();", "Kill Sticky Headers"); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls - #733

Merged
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727
Jan 8, 2026
Merged

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls#733
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727

Conversation

@pranaygp

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Gemini thinking models (e.g., gemini-3-pro-preview) that require thoughtSignature to be preserved across multi-turn tool calls
  • Maps providerMetadata from tool call responses to providerOptions in the conversation prompt, following the AI SDK convention

Problem

When using Gemini thinking models with tool calls, multi-turn conversations fail with:

function call is missing a thought_signature

This happens because providerMetadata (which contains thoughtSignature) from the tool call was not being passed back to the provider when reconstructing the conversation prompt.

Solution

In stream-text-iterator.ts, when adding tool calls to the conversation history, we now map providerMetadataproviderOptions:

conversationPrompt.push({role: 'assistant',content: toolCalls.map((toolCall)=>({type: 'tool-call',toolCallId: toolCall.toolCallId,toolName: toolCall.toolName,input: JSON.parse(toolCall.input),
...(toolCall.providerMetadata!=null
? {providerOptions: toolCall.providerMetadata}
: {}),})),});

This follows the same pattern used in the AI SDK's to-response-messages.ts.

Testing

Added comprehensive tests in stream-text-iterator.test.ts:

  • Preserving providerMetadata as providerOptions in tool-call messages
  • Not adding providerOptions when providerMetadata is undefined
  • Preserving providerMetadata for multiple parallel tool calls
  • Handling mixed tool calls with and without providerMetadata

Fixes#727

CopilotAI review requested due to automatic review settings January 7, 2026 06:18
@changeset-bot

changeset-botBot commented Jan 7, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7da7897

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@workflow/aiPatch
@workflow/docs-typecheckPatch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

Summary

PassedFailedSkippedTotal
✅ ▲ Vercel Production363011374
❌ 💻 Local Development299338340
✅ 📦 Local Production33208340
✅ 🐘 Local Postgres33208340
✅ 🪟 Windows340034
❌ 🌍 Community Worlds131170148
Total149150351576

❌ Failed Tests

💻 Local Development (33 failed)

nitro-stable (33 failed):

  • addTenWorkflow
  • addTenWorkflow
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • readableStreamWorkflow
  • hookWorkflow
  • webhookWorkflow
  • webhook route with invalid token
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • outputStreamWorkflow
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • stepDirectCallWorkflow - calling step functions directly outside workflow context
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check endpoint - workflow and step endpoints respond to __health query parameter
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
🌍 Community Worlds (17 failed)

mongodb (1 failed):

  • webhookWorkflow

redis (1 failed):

  • webhookWorkflow

starter (14 failed):

  • addTenWorkflow
  • addTenWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly

turso (1 failed):

  • webhookWorkflow

Details by Category

✅ ▲ Vercel Production
AppPassedFailedSkipped
✅ astro3301
✅ example3301
✅ express3301
✅ fastify3301
✅ hono3301
✅ nextjs-turbopack3301
✅ nextjs-webpack3301
✅ nitro3301
✅ nuxt3301
✅ sveltekit3301
✅ vite3301
❌ 💻 Local Development
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
❌ nitro-stable0331
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 📦 Local Production
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🐘 Local Postgres
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🪟 Windows
AppPassedFailedSkipped
✅ nextjs-turbopack3400
❌ 🌍 Community Worlds
AppPassedFailedSkipped
✅ mongodb-dev300
❌ mongodb3310
✅ redis-dev300
❌ redis3310
✅ starter-dev300
❌ starter20140
✅ turso-dev300
❌ turso3310

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: success
  • Local Dev: failure
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)0.037s (-1.1%)1.014s (~)0.977s101.00x
💻 LocalNext.js (Turbopack)0.038s (+10.7% 🔺)1.014s (~)0.975s101.03x
🌐 RedisNext.js (Turbopack)0.041s (-1.7%)1.017s (~)0.976s101.11x
💻 LocalNitro0.044s (-10.2% 🟢)1.006s (-0.8%)0.962s101.18x
💻 LocalExpress0.046s (+5.2% 🔺)1.008s (~)0.961s101.25x
🌐 MongoDBNext.js (Turbopack)0.083s (-30.1% 🟢)1.016s (~)0.934s102.23x
🌐 TursoNext.js (Turbopack)0.106s (+26.5% 🔺)1.014s (~)0.907s102.86x
🐘 PostgresExpress0.221s (-35.6% 🟢)1.014s (~)0.793s105.95x
🐘 PostgresNext.js (Turbopack)0.252s (+65.9% 🔺)1.029s (+1.0%)0.777s106.78x
🐘 PostgresNitro0.299s (+0.9%)1.012s (~)0.714s108.03x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro0.575s (-15.6% 🟢)1.423s (-15.2% 🟢)0.848s101.00x
▲ VercelExpress0.609s (-6.4% 🟢)1.435s (-15.6% 🟢)0.826s101.06x
▲ VercelNext.js (Turbopack)0.709s (-5.5% 🟢)1.532s (-9.8% 🟢)0.823s101.23x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.086s (+0.5%)2.011s (~)0.925s101.00x
💻 LocalNext.js (Turbopack)1.098s (+1.5%)2.012s (~)0.914s101.01x
🌐 RedisNext.js (Turbopack)1.106s (~)2.012s (~)0.906s101.02x
💻 LocalNitro1.113s (~)2.006s (~)0.893s101.02x
💻 LocalExpress1.118s (~)2.008s (~)0.890s101.03x
🌐 MongoDBNext.js (Turbopack)1.275s (-1.5%)2.017s (~)0.742s101.17x
🌐 TursoNext.js (Turbopack)1.308s (+1.3%)2.012s (~)0.704s101.20x
🐘 PostgresNext.js (Turbopack)1.660s (-11.0% 🟢)2.015s (~)0.355s101.53x
🐘 PostgresNitro2.158s (~)3.013s (~)0.855s101.99x
🐘 PostgresExpress2.254s (+2.6%)3.014s (~)0.761s102.08x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro2.637s (-11.0% 🟢)3.575s (-4.2%)0.938s101.00x
▲ VercelExpress2.650s (-16.4% 🟢)3.658s (-12.3% 🟢)1.007s101.01x
▲ VercelNext.js (Turbopack)2.712s (-11.7% 🟢)3.530s (-10.1% 🟢)0.817s101.03x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)10.606s (~)11.012s (~)0.406s51.00x
💻 LocalNext.js (Turbopack)10.653s (+1.4%)11.018s (~)0.365s51.00x
🌐 RedisNext.js (Turbopack)10.666s (~)11.016s (~)0.349s51.01x
💻 LocalNitro10.794s (~)11.012s (~)0.218s51.02x
💻 LocalExpress10.819s (~)11.016s (~)0.197s51.02x
🌐 MongoDBNext.js (Turbopack)12.068s (-1.2%)12.628s (-3.1%)0.560s51.14x
🌐 TursoNext.js (Turbopack)12.182s (~)13.023s (~)0.840s51.15x
🐘 PostgresNext.js (Turbopack)13.714s (-9.9% 🟢)14.235s (-11.2% 🟢)0.521s51.29x
🐘 PostgresExpress20.395s (~)21.036s (~)0.641s51.92x
🐘 PostgresNitro20.505s (~)21.029s (~)0.525s51.93x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro22.177s (+1.2%)22.860s (+1.0%)0.683s51.00x
▲ VercelNext.js (Turbopack)22.274s (~)22.897s (-0.9%)0.623s51.00x
▲ VercelExpress22.821s (+1.9%)23.459s (~)0.638s51.03x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Redis🥇 Next.js (Turbopack)1.348s (-1.1%)2.010s (~)0.662s151.00x
🌐 StarterNext.js (Turbopack)1.361s (+1.4%)2.008s (~)0.646s151.01x
💻 LocalNext.js (Turbopack)1.383s (+3.5%)2.012s (~)0.629s151.03x
💻 LocalNitro1.415s (~)2.005s (~)0.590s151.05x
💻 LocalExpress1.429s (+1.7%)2.007s (~)0.579s151.06x
🐘 PostgresNext.js (Turbopack)1.953s (+1.5%)2.160s (~)0.207s141.45x
🌐 MongoDBNext.js (Turbopack)2.144s (+1.2%)3.015s (~)0.871s101.59x
🌐 TursoNext.js (Turbopack)2.203s (-0.9%)3.013s (~)0.810s101.63x
🐘 PostgresNitro2.449s (+3.3%)3.010s (~)0.562s101.82x
🐘 PostgresExpress2.510s (+2.9%)3.015s (~)0.505s101.86x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.821s (~)3.588s (-9.5% 🟢)0.767s91.00x
▲ VercelNitro3.075s (-9.4% 🟢)4.000s (-7.9% 🟢)0.925s81.09x
▲ VercelNext.js (Turbopack)3.140s (-11.6% 🟢)3.954s (-9.1% 🟢)0.814s81.11x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.105s (+5.5% 🔺)3.022s (+39.8% 🔺)0.917s101.00x
💻 LocalExpress2.209s (-0.6%)3.159s (~)0.951s101.05x
💻 LocalNitro2.217s (+1.5%)3.177s (+1.5%)0.960s101.05x
🌐 StarterNext.js (Turbopack)2.477s (+0.8%)3.011s (~)0.534s101.18x
🌐 RedisNext.js (Turbopack)2.528s (+1.4%)3.034s (+0.7%)0.506s101.20x
🐘 PostgresNext.js (Turbopack)2.630s (+4.2%)3.013s (~)0.383s101.25x
🐘 PostgresNitro2.854s (+2.3%)3.012s (-0.7%)0.158s101.36x
🐘 PostgresExpress3.060s (+5.6% 🔺)3.362s (+8.0% 🔺)0.302s91.45x
🌐 MongoDBNext.js (Turbopack)4.718s (+1.9%)5.184s (~)0.466s62.24x
🌐 TursoNext.js (Turbopack)4.744s (+0.5%)5.184s (~)0.440s62.25x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro3.351s (+12.7% 🔺)3.810s (+6.0% 🔺)0.459s91.00x
▲ VercelExpress3.432s (+4.2%)3.969s (-1.9%)0.538s81.02x
▲ VercelNext.js (Turbopack)3.495s (+2.3%)3.962s (-3.3%)0.467s81.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

Promise.race with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.342s (-1.0%)2.007s (~)0.665s151.00x
🌐 RedisNext.js (Turbopack)1.376s (+1.5%)2.010s (~)0.635s151.02x
💻 LocalNext.js (Turbopack)1.395s (+2.8%)2.014s (~)0.619s151.04x
💻 LocalExpress1.420s (-0.7%)2.006s (~)0.585s151.06x
💻 LocalNitro1.422s (+0.7%)2.006s (~)0.585s151.06x
🐘 PostgresNext.js (Turbopack)1.663s (-6.6% 🟢)2.012s (~)0.349s151.24x
🐘 PostgresExpress1.784s (-21.3% 🟢)2.155s (-28.7% 🟢)0.372s141.33x
🐘 PostgresNitro1.975s (+8.0% 🔺)2.323s (+15.7% 🔺)0.348s131.47x
🌐 MongoDBNext.js (Turbopack)2.128s (-0.8%)3.014s (~)0.886s101.59x
🌐 TursoNext.js (Turbopack)2.225s (~)3.012s (~)0.787s101.66x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.745s (-3.5%)3.644s (-5.3% 🟢)0.900s91.00x
▲ VercelNitro2.886s (+4.4%)3.659s (+2.1%)0.773s91.05x
▲ VercelNext.js (Turbopack)2.890s (+3.8%)3.646s (-1.6%)0.756s91.05x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.210s (+7.3% 🔺)3.166s (+19.7% 🔺)0.956s101.00x
💻 LocalNitro2.237s (+0.9%)3.197s (+1.0%)0.960s101.01x
💻 LocalExpress2.265s (-0.6%)3.203s (~)0.938s101.02x
🌐 StarterNext.js (Turbopack)2.452s (-0.6%)3.010s (~)0.557s101.11x
🌐 RedisNext.js (Turbopack)2.507s (+1.2%)3.012s (~)0.505s101.13x
🐘 PostgresNext.js (Turbopack)2.664s (+9.7% 🔺)3.020s (~)0.356s101.21x
🐘 PostgresExpress2.879s (~)3.133s (+3.9%)0.253s101.30x
🐘 PostgresNitro2.966s (+18.7% 🔺)3.113s (+3.2%)0.147s101.34x
🌐 TursoNext.js (Turbopack)4.704s (-1.2%)5.183s (~)0.479s62.13x
🌐 MongoDBNext.js (Turbopack)4.705s (+0.6%)5.188s (~)0.483s62.13x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express3.355s (+4.6%)4.055s (+5.8% 🔺)0.700s81.00x
▲ VercelNitro3.438s (+7.9% 🔺)4.112s (+11.9% 🔺)0.674s81.02x
▲ VercelNext.js (Turbopack)3.828s (+18.1% 🔺)4.480s (+16.5% 🔺)0.652s71.14x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Stream Benchmarks(includes TTFB metrics)
workflow with stream

💻 Local Development

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)0.136s (+34.8% 🔺)1.003s (~)0.016s (-2.4%)1.027s (~)0.891s101.00x
🌐 StarterNext.js (Turbopack)0.139s (+7.9% 🔺)1.005s (~)0.000s (NaN%)1.011s (~)0.873s101.02x
🌐 RedisNext.js (Turbopack)0.151s (+5.0%)1.005s (~)0.000s (NaN%)1.014s (~)0.863s101.11x
💻 LocalNitro0.177s (+1.4%)0.993s (~)0.020s (+28.9% 🔺)1.026s (~)0.849s101.30x
💻 LocalExpress0.186s (+6.0% 🔺)0.993s (~)0.015s (-10.2% 🟢)1.023s (~)0.837s101.37x
🌐 TursoNext.js (Turbopack)0.478s (-5.6% 🟢)0.973s (+2.9%)0.000s (+Infinity% 🔺)1.014s (~)0.536s103.51x
🌐 MongoDBNext.js (Turbopack)0.496s (+5.9% 🔺)0.952s (-2.9%)0.000s (+Infinity% 🔺)1.015s (~)0.519s103.64x
🐘 PostgresNext.js (Turbopack)0.784s (-33.9% 🟢)0.883s (-52.6% 🟢)0.000s (+Infinity% 🔺)1.015s (-49.7% 🟢)0.231s105.75x
🐘 PostgresExpress2.183s (-7.3% 🟢)2.859s (+6.5% 🔺)0.000s (+Infinity% 🔺)3.015s (~)0.832s1016.02x
🐘 PostgresNitro2.334s (+1.1%)2.706s (-1.0%)0.000s (NaN%)3.012s (~)0.678s1017.12x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.840s (+1.7%)3.169s (-3.9%)0.680s (+110.8% 🔺)4.326s (+4.8%)1.486s101.00x
▲ VercelNext.js (Turbopack)2.848s (+1.5%)3.248s (+2.6%)0.502s (-23.1% 🟢)4.162s (-2.8%)1.314s101.00x
▲ VercelNitro2.880s (-8.2% 🟢)3.203s (-13.0% 🟢)0.631s (-28.5% 🟢)4.273s (-13.7% 🟢)1.393s101.01x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World🥇 Fastest FrameworkWins
💻 LocalNext.js (Turbopack)8/8
🐘 PostgresNext.js (Turbopack)7/8
▲ VercelNitro4/8
Fastest World by Framework

Winner determined by most benchmark wins

Framework🥇 Fastest WorldWins
Express💻 Local8/8
Next.js (Turbopack)🌐 Starter4/8
Nitro💻 Local8/8
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Starter: Community world (local development)
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

…ool calls
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a critical bug in Gemini thinking models (e.g., gemini-3-pro-preview) where multi-turn tool calls were failing with "function call is missing a thought_signature" error. The fix ensures that providerMetadata from tool calls is correctly mapped to providerOptions when reconstructing the conversation prompt for subsequent turns.

Key Changes:

  • Map providerMetadata to providerOptions when adding tool calls to conversation history
  • Add comprehensive test coverage for the providerMetadata preservation logic
  • Document the fix in a changeset for release notes

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

FileDescription
packages/ai/src/agent/stream-text-iterator.tsAdded logic to map providerMetadata from tool calls to providerOptions in the conversation prompt, with detailed inline comments explaining the critical nature of this mapping for Gemini thinking models
packages/ai/src/agent/stream-text-iterator.test.tsAdded comprehensive test suite with 4 test cases covering: single tool call with metadata, tool call without metadata, multiple parallel tool calls, and mixed scenarios with and without metadata
.changeset/fix-provider-metadata-tool-calls.mdAdded changeset describing the bug fix for release documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

];

// Second iteration - should trigger second doStreamStep call
const secondResult = await iterator.next(toolResults);

CopilotAIJan 7, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused variable secondResult.

Suggested change
constsecondResult=awaititerator.next(toolResults);
awaititerator.next(toolResults);

Copilot uses AI. Check for mistakes.

@VaguelySeriousVaguelySerious left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test looks not too useful, but no harm in merging IMO

@VaguelySerious
VaguelySerious merged commit 4b43186 into mainJan 8, 2026
89 of 91 checks passed
@VaguelySerious
VaguelySerious deleted the pranaygp/fix-727 branch January 8, 2026 09:56
TooTallNate added a commit that referenced this pull request Jan 12, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
VaguelySerious added a commit that referenced this pull request Jan 16, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto 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.

Gemini tool-calls fail after first step because thought_signature is dropped

3 participants

@pranaygp@VaguelySerious
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Universal Dark Mode - works on any site\n(function() {\n var enabled = true;\n \n function applyDarkMode() {\n if (!enabled) return;\n \n // Create style element if it doesn't exist\n var style = document.getElementById('universal-dark-mode-style');\n if (!style) {\n style = document.createElement('style');\n style.id = 'universal-dark-mode-style';\n document.head.appendChild(style);\n }\n \n // Dark mode CSS - inverts colors but preserves images/video\n style.textContent = '\n /* Invert everything except media */\n html {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #1a1a2e !important;\n }\n \n /* Restore images, videos, iframes, canvas */\n img, video, iframe, canvas, svg, picture, [style*=\"background-image\"] {\n filter: invert(1) hue-rotate(180deg) !important;\n }\n \n /* Preserve specific elements that should not be inverted */\n .no-dark-mode, .no-dark-mode *,\n [data-theme=\"light\"], [data-theme=\"light\"],\n .ace_editor, .ace_editor *,\n .CodeMirror, .CodeMirror *,\n .monaco-editor, .monaco-editor *,\n .markdown-body pre, .markdown-body pre *,\n .highlight, .highlight *,\n pre code, pre code * {\n filter: none !important;\n }\n \n /* Fix common UI elements */\n .modal, .popup, .dropdown-menu, .tooltip, .popover {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #2d2d44 !important;\n border-color: #444 !important;\n }\n \n /* Scrollbars */\n ::-webkit-scrollbar { background: #1a1a2e !important; }\n ::-webkit-scrollbar-thumb { background: #444 !important; }\n ::-webkit-scrollbar-thumb:hover { background: #555 !important; }\n \n /* Selection */\n ::selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ::-moz-selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ';\n }\n \n function removeDarkMode() {\n var style = document.getElementById('universal-dark-mode-style');\n if (style) style.remove();\n }\n \n // Toggle with Alt+Shift+D\n document.addEventListener('keydown', function(e) {\n if (e.altKey && e.shiftKey && e.key === 'D') {\n e.preventDefault();\n enabled = !enabled;\n if (enabled) {\n applyDarkMode();\n console.log('[Universal Dark Mode] Enabled');\n } else {\n removeDarkMode();\n console.log('[Universal Dark Mode] Disabled');\n }\n }\n });\n \n // Apply on load\n applyDarkMode();\n \n // Re-apply on dynamic content\n var observer = new MutationObserver(function(mutations) {\n if (enabled && !document.getElementById('universal-dark-mode-style')) {\n applyDarkMode();\n }\n });\n observer.observe(document.head, { childList: true });\n \n console.log('[Universal Dark Mode] Loaded - Press Alt+Shift+D to toggle');\n})();", "Universal Dark Mode"); } } catch(__e) { console.warn('[Userscript:Universal Dark Mode]', __e); } })(); })();
Skip to content

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls - #733

Merged
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727
Jan 8, 2026
Merged

fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls#733
VaguelySerious merged 1 commit into
mainfrom
pranaygp/fix-727

Conversation

@pranaygp

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Gemini thinking models (e.g., gemini-3-pro-preview) that require thoughtSignature to be preserved across multi-turn tool calls
  • Maps providerMetadata from tool call responses to providerOptions in the conversation prompt, following the AI SDK convention

Problem

When using Gemini thinking models with tool calls, multi-turn conversations fail with:

function call is missing a thought_signature

This happens because providerMetadata (which contains thoughtSignature) from the tool call was not being passed back to the provider when reconstructing the conversation prompt.

Solution

In stream-text-iterator.ts, when adding tool calls to the conversation history, we now map providerMetadataproviderOptions:

conversationPrompt.push({role: 'assistant',content: toolCalls.map((toolCall)=>({type: 'tool-call',toolCallId: toolCall.toolCallId,toolName: toolCall.toolName,input: JSON.parse(toolCall.input),
...(toolCall.providerMetadata!=null
? {providerOptions: toolCall.providerMetadata}
: {}),})),});

This follows the same pattern used in the AI SDK's to-response-messages.ts.

Testing

Added comprehensive tests in stream-text-iterator.test.ts:

  • Preserving providerMetadata as providerOptions in tool-call messages
  • Not adding providerOptions when providerMetadata is undefined
  • Preserving providerMetadata for multiple parallel tool calls
  • Handling mixed tool calls with and without providerMetadata

Fixes#727

CopilotAI review requested due to automatic review settings January 7, 2026 06:18
@changeset-bot

changeset-botBot commented Jan 7, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7da7897

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@workflow/aiPatch
@workflow/docs-typecheckPatch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

Summary

PassedFailedSkippedTotal
✅ ▲ Vercel Production363011374
❌ 💻 Local Development299338340
✅ 📦 Local Production33208340
✅ 🐘 Local Postgres33208340
✅ 🪟 Windows340034
❌ 🌍 Community Worlds131170148
Total149150351576

❌ Failed Tests

💻 Local Development (33 failed)

nitro-stable (33 failed):

  • addTenWorkflow
  • addTenWorkflow
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • readableStreamWorkflow
  • hookWorkflow
  • webhookWorkflow
  • webhook route with invalid token
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • outputStreamWorkflow
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • stepDirectCallWorkflow - calling step functions directly outside workflow context
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check endpoint - workflow and step endpoints respond to __health query parameter
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
🌍 Community Worlds (17 failed)

mongodb (1 failed):

  • webhookWorkflow

redis (1 failed):

  • webhookWorkflow

starter (14 failed):

  • addTenWorkflow
  • addTenWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly

turso (1 failed):

  • webhookWorkflow

Details by Category

✅ ▲ Vercel Production
AppPassedFailedSkipped
✅ astro3301
✅ example3301
✅ express3301
✅ fastify3301
✅ hono3301
✅ nextjs-turbopack3301
✅ nextjs-webpack3301
✅ nitro3301
✅ nuxt3301
✅ sveltekit3301
✅ vite3301
❌ 💻 Local Development
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
❌ nitro-stable0331
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 📦 Local Production
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🐘 Local Postgres
AppPassedFailedSkipped
✅ astro-stable3301
✅ express-stable3301
✅ fastify-stable3301
✅ hono-stable3301
✅ nextjs-turbopack-stable3400
✅ nextjs-webpack-stable3400
✅ nitro-stable3301
✅ nuxt-stable3301
✅ sveltekit-stable3301
✅ vite-stable3301
✅ 🪟 Windows
AppPassedFailedSkipped
✅ nextjs-turbopack3400
❌ 🌍 Community Worlds
AppPassedFailedSkipped
✅ mongodb-dev300
❌ mongodb3310
✅ redis-dev300
❌ redis3310
✅ starter-dev300
❌ starter20140
✅ turso-dev300
❌ turso3310

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: success
  • Local Dev: failure
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions

github-actionsBot commented Jan 7, 2026

Copy link
Copy Markdown
Contributor

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)0.037s (-1.1%)1.014s (~)0.977s101.00x
💻 LocalNext.js (Turbopack)0.038s (+10.7% 🔺)1.014s (~)0.975s101.03x
🌐 RedisNext.js (Turbopack)0.041s (-1.7%)1.017s (~)0.976s101.11x
💻 LocalNitro0.044s (-10.2% 🟢)1.006s (-0.8%)0.962s101.18x
💻 LocalExpress0.046s (+5.2% 🔺)1.008s (~)0.961s101.25x
🌐 MongoDBNext.js (Turbopack)0.083s (-30.1% 🟢)1.016s (~)0.934s102.23x
🌐 TursoNext.js (Turbopack)0.106s (+26.5% 🔺)1.014s (~)0.907s102.86x
🐘 PostgresExpress0.221s (-35.6% 🟢)1.014s (~)0.793s105.95x
🐘 PostgresNext.js (Turbopack)0.252s (+65.9% 🔺)1.029s (+1.0%)0.777s106.78x
🐘 PostgresNitro0.299s (+0.9%)1.012s (~)0.714s108.03x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro0.575s (-15.6% 🟢)1.423s (-15.2% 🟢)0.848s101.00x
▲ VercelExpress0.609s (-6.4% 🟢)1.435s (-15.6% 🟢)0.826s101.06x
▲ VercelNext.js (Turbopack)0.709s (-5.5% 🟢)1.532s (-9.8% 🟢)0.823s101.23x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.086s (+0.5%)2.011s (~)0.925s101.00x
💻 LocalNext.js (Turbopack)1.098s (+1.5%)2.012s (~)0.914s101.01x
🌐 RedisNext.js (Turbopack)1.106s (~)2.012s (~)0.906s101.02x
💻 LocalNitro1.113s (~)2.006s (~)0.893s101.02x
💻 LocalExpress1.118s (~)2.008s (~)0.890s101.03x
🌐 MongoDBNext.js (Turbopack)1.275s (-1.5%)2.017s (~)0.742s101.17x
🌐 TursoNext.js (Turbopack)1.308s (+1.3%)2.012s (~)0.704s101.20x
🐘 PostgresNext.js (Turbopack)1.660s (-11.0% 🟢)2.015s (~)0.355s101.53x
🐘 PostgresNitro2.158s (~)3.013s (~)0.855s101.99x
🐘 PostgresExpress2.254s (+2.6%)3.014s (~)0.761s102.08x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro2.637s (-11.0% 🟢)3.575s (-4.2%)0.938s101.00x
▲ VercelExpress2.650s (-16.4% 🟢)3.658s (-12.3% 🟢)1.007s101.01x
▲ VercelNext.js (Turbopack)2.712s (-11.7% 🟢)3.530s (-10.1% 🟢)0.817s101.03x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)10.606s (~)11.012s (~)0.406s51.00x
💻 LocalNext.js (Turbopack)10.653s (+1.4%)11.018s (~)0.365s51.00x
🌐 RedisNext.js (Turbopack)10.666s (~)11.016s (~)0.349s51.01x
💻 LocalNitro10.794s (~)11.012s (~)0.218s51.02x
💻 LocalExpress10.819s (~)11.016s (~)0.197s51.02x
🌐 MongoDBNext.js (Turbopack)12.068s (-1.2%)12.628s (-3.1%)0.560s51.14x
🌐 TursoNext.js (Turbopack)12.182s (~)13.023s (~)0.840s51.15x
🐘 PostgresNext.js (Turbopack)13.714s (-9.9% 🟢)14.235s (-11.2% 🟢)0.521s51.29x
🐘 PostgresExpress20.395s (~)21.036s (~)0.641s51.92x
🐘 PostgresNitro20.505s (~)21.029s (~)0.525s51.93x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro22.177s (+1.2%)22.860s (+1.0%)0.683s51.00x
▲ VercelNext.js (Turbopack)22.274s (~)22.897s (-0.9%)0.623s51.00x
▲ VercelExpress22.821s (+1.9%)23.459s (~)0.638s51.03x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Redis🥇 Next.js (Turbopack)1.348s (-1.1%)2.010s (~)0.662s151.00x
🌐 StarterNext.js (Turbopack)1.361s (+1.4%)2.008s (~)0.646s151.01x
💻 LocalNext.js (Turbopack)1.383s (+3.5%)2.012s (~)0.629s151.03x
💻 LocalNitro1.415s (~)2.005s (~)0.590s151.05x
💻 LocalExpress1.429s (+1.7%)2.007s (~)0.579s151.06x
🐘 PostgresNext.js (Turbopack)1.953s (+1.5%)2.160s (~)0.207s141.45x
🌐 MongoDBNext.js (Turbopack)2.144s (+1.2%)3.015s (~)0.871s101.59x
🌐 TursoNext.js (Turbopack)2.203s (-0.9%)3.013s (~)0.810s101.63x
🐘 PostgresNitro2.449s (+3.3%)3.010s (~)0.562s101.82x
🐘 PostgresExpress2.510s (+2.9%)3.015s (~)0.505s101.86x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.821s (~)3.588s (-9.5% 🟢)0.767s91.00x
▲ VercelNitro3.075s (-9.4% 🟢)4.000s (-7.9% 🟢)0.925s81.09x
▲ VercelNext.js (Turbopack)3.140s (-11.6% 🟢)3.954s (-9.1% 🟢)0.814s81.11x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.105s (+5.5% 🔺)3.022s (+39.8% 🔺)0.917s101.00x
💻 LocalExpress2.209s (-0.6%)3.159s (~)0.951s101.05x
💻 LocalNitro2.217s (+1.5%)3.177s (+1.5%)0.960s101.05x
🌐 StarterNext.js (Turbopack)2.477s (+0.8%)3.011s (~)0.534s101.18x
🌐 RedisNext.js (Turbopack)2.528s (+1.4%)3.034s (+0.7%)0.506s101.20x
🐘 PostgresNext.js (Turbopack)2.630s (+4.2%)3.013s (~)0.383s101.25x
🐘 PostgresNitro2.854s (+2.3%)3.012s (-0.7%)0.158s101.36x
🐘 PostgresExpress3.060s (+5.6% 🔺)3.362s (+8.0% 🔺)0.302s91.45x
🌐 MongoDBNext.js (Turbopack)4.718s (+1.9%)5.184s (~)0.466s62.24x
🌐 TursoNext.js (Turbopack)4.744s (+0.5%)5.184s (~)0.440s62.25x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Nitro3.351s (+12.7% 🔺)3.810s (+6.0% 🔺)0.459s91.00x
▲ VercelExpress3.432s (+4.2%)3.969s (-1.9%)0.538s81.02x
▲ VercelNext.js (Turbopack)3.495s (+2.3%)3.962s (-3.3%)0.467s81.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

Promise.race with 10 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
🌐 Starter🥇 Next.js (Turbopack)1.342s (-1.0%)2.007s (~)0.665s151.00x
🌐 RedisNext.js (Turbopack)1.376s (+1.5%)2.010s (~)0.635s151.02x
💻 LocalNext.js (Turbopack)1.395s (+2.8%)2.014s (~)0.619s151.04x
💻 LocalExpress1.420s (-0.7%)2.006s (~)0.585s151.06x
💻 LocalNitro1.422s (+0.7%)2.006s (~)0.585s151.06x
🐘 PostgresNext.js (Turbopack)1.663s (-6.6% 🟢)2.012s (~)0.349s151.24x
🐘 PostgresExpress1.784s (-21.3% 🟢)2.155s (-28.7% 🟢)0.372s141.33x
🐘 PostgresNitro1.975s (+8.0% 🔺)2.323s (+15.7% 🔺)0.348s131.47x
🌐 MongoDBNext.js (Turbopack)2.128s (-0.8%)3.014s (~)0.886s101.59x
🌐 TursoNext.js (Turbopack)2.225s (~)3.012s (~)0.787s101.66x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.745s (-3.5%)3.644s (-5.3% 🟢)0.900s91.00x
▲ VercelNitro2.886s (+4.4%)3.659s (+2.1%)0.773s91.05x
▲ VercelNext.js (Turbopack)2.890s (+3.8%)3.646s (-1.6%)0.756s91.05x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)2.210s (+7.3% 🔺)3.166s (+19.7% 🔺)0.956s101.00x
💻 LocalNitro2.237s (+0.9%)3.197s (+1.0%)0.960s101.01x
💻 LocalExpress2.265s (-0.6%)3.203s (~)0.938s101.02x
🌐 StarterNext.js (Turbopack)2.452s (-0.6%)3.010s (~)0.557s101.11x
🌐 RedisNext.js (Turbopack)2.507s (+1.2%)3.012s (~)0.505s101.13x
🐘 PostgresNext.js (Turbopack)2.664s (+9.7% 🔺)3.020s (~)0.356s101.21x
🐘 PostgresExpress2.879s (~)3.133s (+3.9%)0.253s101.30x
🐘 PostgresNitro2.966s (+18.7% 🔺)3.113s (+3.2%)0.147s101.34x
🌐 TursoNext.js (Turbopack)4.704s (-1.2%)5.183s (~)0.479s62.13x
🌐 MongoDBNext.js (Turbopack)4.705s (+0.6%)5.188s (~)0.483s62.13x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express3.355s (+4.6%)4.055s (+5.8% 🔺)0.700s81.00x
▲ VercelNitro3.438s (+7.9% 🔺)4.112s (+11.9% 🔺)0.674s81.02x
▲ VercelNext.js (Turbopack)3.828s (+18.1% 🔺)4.480s (+16.5% 🔺)0.652s71.14x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Stream Benchmarks(includes TTFB metrics)
workflow with stream

💻 Local Development

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
💻 Local🥇 Next.js (Turbopack)0.136s (+34.8% 🔺)1.003s (~)0.016s (-2.4%)1.027s (~)0.891s101.00x
🌐 StarterNext.js (Turbopack)0.139s (+7.9% 🔺)1.005s (~)0.000s (NaN%)1.011s (~)0.873s101.02x
🌐 RedisNext.js (Turbopack)0.151s (+5.0%)1.005s (~)0.000s (NaN%)1.014s (~)0.863s101.11x
💻 LocalNitro0.177s (+1.4%)0.993s (~)0.020s (+28.9% 🔺)1.026s (~)0.849s101.30x
💻 LocalExpress0.186s (+6.0% 🔺)0.993s (~)0.015s (-10.2% 🟢)1.023s (~)0.837s101.37x
🌐 TursoNext.js (Turbopack)0.478s (-5.6% 🟢)0.973s (+2.9%)0.000s (+Infinity% 🔺)1.014s (~)0.536s103.51x
🌐 MongoDBNext.js (Turbopack)0.496s (+5.9% 🔺)0.952s (-2.9%)0.000s (+Infinity% 🔺)1.015s (~)0.519s103.64x
🐘 PostgresNext.js (Turbopack)0.784s (-33.9% 🟢)0.883s (-52.6% 🟢)0.000s (+Infinity% 🔺)1.015s (-49.7% 🟢)0.231s105.75x
🐘 PostgresExpress2.183s (-7.3% 🟢)2.859s (+6.5% 🔺)0.000s (+Infinity% 🔺)3.015s (~)0.832s1016.02x
🐘 PostgresNitro2.334s (+1.1%)2.706s (-1.0%)0.000s (NaN%)3.012s (~)0.678s1017.12x

▲ Production (Vercel)

WorldFrameworkWorkflow TimeTTFBSlurpWall TimeOverheadSamplesvs Fastest
▲ Vercel🥇 Express2.840s (+1.7%)3.169s (-3.9%)0.680s (+110.8% 🔺)4.326s (+4.8%)1.486s101.00x
▲ VercelNext.js (Turbopack)2.848s (+1.5%)3.248s (+2.6%)0.502s (-23.1% 🟢)4.162s (-2.8%)1.314s101.00x
▲ VercelNitro2.880s (-8.2% 🟢)3.203s (-13.0% 🟢)0.631s (-28.5% 🟢)4.273s (-13.7% 🟢)1.393s101.01x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World🥇 Fastest FrameworkWins
💻 LocalNext.js (Turbopack)8/8
🐘 PostgresNext.js (Turbopack)7/8
▲ VercelNitro4/8
Fastest World by Framework

Winner determined by most benchmark wins

Framework🥇 Fastest WorldWins
Express💻 Local8/8
Next.js (Turbopack)🌐 Starter4/8
Nitro💻 Local8/8
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Starter: Community world (local development)
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

…ool calls
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a critical bug in Gemini thinking models (e.g., gemini-3-pro-preview) where multi-turn tool calls were failing with "function call is missing a thought_signature" error. The fix ensures that providerMetadata from tool calls is correctly mapped to providerOptions when reconstructing the conversation prompt for subsequent turns.

Key Changes:

  • Map providerMetadata to providerOptions when adding tool calls to conversation history
  • Add comprehensive test coverage for the providerMetadata preservation logic
  • Document the fix in a changeset for release notes

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

FileDescription
packages/ai/src/agent/stream-text-iterator.tsAdded logic to map providerMetadata from tool calls to providerOptions in the conversation prompt, with detailed inline comments explaining the critical nature of this mapping for Gemini thinking models
packages/ai/src/agent/stream-text-iterator.test.tsAdded comprehensive test suite with 4 test cases covering: single tool call with metadata, tool call without metadata, multiple parallel tool calls, and mixed scenarios with and without metadata
.changeset/fix-provider-metadata-tool-calls.mdAdded changeset describing the bug fix for release documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

];

// Second iteration - should trigger second doStreamStep call
const secondResult = await iterator.next(toolResults);

CopilotAIJan 7, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused variable secondResult.

Suggested change
constsecondResult=awaititerator.next(toolResults);
awaititerator.next(toolResults);

Copilot uses AI. Check for mistakes.

@VaguelySeriousVaguelySerious left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, test looks not too useful, but no harm in merging IMO

@VaguelySerious
VaguelySerious merged commit 4b43186 into mainJan 8, 2026
89 of 91 checks passed
@VaguelySerious
VaguelySerious deleted the pranaygp/fix-727 branch January 8, 2026 09:56
TooTallNate added a commit that referenced this pull request Jan 12, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
VaguelySerious added a commit that referenced this pull request Jan 16, 2026
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* fix(ai): preserve providerMetadata as providerOptions in multi-turn tool calls (#733)
When tool calls are added to the conversation history, map providerMetadata
to providerOptions following the AI SDK convention. This fixes Gemini thinking
models that require thoughtSignature to be preserved across multi-turn tool calls,
preventing the error 'function call is missing a thought_signature'.
Fixes#727
* Local ui cli flag (#744)
* [web] Increase contrast on attribute items in sidebar (#736)
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [world] Remove pause and resume events, actions and states (#751)
* Version Packages (beta) (#735)
* .
* .
* Update turbo inputs to include shared config (#752)
* Update turbo inputs to include shared config
* Apply suggestions from code review
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
---------
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
* feat(web): add self-hosted mode for world configuration (#747)
* feat(web): add self-hosted mode for world configuration
When WORKFLOW_TARGET_WORLD env var is set, the web UI operates in
self-hosted mode where the world configuration is locked to server-side
environment variables and cannot be changed via query params or UI.
- Add getHardcodedConfig server action to detect self-hosted mode
- Modify getWorldFromEnv to use server env vars in hardcoded mode
- Create WorldConfigContext to provide config state app-wide
- Update settings sidebar to show locked state with disabled inputs
- Update connection status to show PostgreSQL backend info
- Mask sensitive values (postgres URL) in hardcoded mode UI
* fix: address PR review feedback
- Remove unused ConfigMode type export
- Fix postgres substring to undefined (tooltip has details)
- Extract buildEnvMapFromProcessEnv helper to reduce duplication
- Remove unused EnvMap import from layout-client
- Import HardcodedConfig from web-shared/server instead of re-defining
* Fix: PostgreSQL URL parameter missing from configParsers, causing loss of postgres URL configuration on page reload in dynamic mode
* fix(cli): clear WORKFLOW_TARGET_WORLD when spawning web server
The CLI sets WORKFLOW_TARGET_WORLD as an env var, which the spawned
Next.js server inherits. This caused the web UI to enter self-hosted
mode even when launched via CLI.
Now we explicitly clear WORKFLOW_TARGET_WORLD from the server's
environment so it starts in dynamic mode where config comes from
query params as intended.
* refactor(web): use server-side env vars for world config
BREAKING CHANGE: The web UI no longer supports configuring the world
backend via URL query parameters. Configuration is now read exclusively
from server-side environment variables.
Changes:
- Remove query param parsing from @workflow/web config.ts
- Add ServerConfig interface with non-sensitive display info
- Update all components to use useServerConfig() hook
- Settings sidebar is now read-only
- CLI passes env vars to spawned web server instead of query params
- Server actions use process.env directly (envMap param reserved for future use)
This simplifies the architecture and improves security by never sending
sensitive data (connection strings, auth tokens) to the client.
* fix(web): fix settings sidebar overflow and shorten data dir path
- Add truncate/overflow handling to settings sidebar config values
- Add shortenPath() helper to abbreviate long file paths:
- Replaces home directory with ~
- Shows .../last-two-segments if still too long
- Add title attributes for full path on hover
* Update changeest
---------
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
* Version Packages (beta) (#755)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* [web] Tidy wake-up and re-enqueue buttons (#737)
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
* [cli] Use dotenv to resolve .env and .env.local files on startup (#765)
* Use temporary workflow-server deployment URL
* feat: add queue-based health check to bypass Deployment Protection
- Add HealthCheckPayloadSchema and HEALTH_CHECK_STREAM_PREFIX to @workflow/world
- Add healthCheck() method to Queue interface
- Update workflow and step handlers to detect and respond to health check messages
- Implement healthCheck() in world-local, world-vercel, and world-postgres
The queue-based health check sends a message through the queue pipeline,
which bypasses Vercel's Deployment Protection. The handler writes a response
to a stream that the caller reads to confirm health.
This complements the existing HTTP-based ?__health approach which still works
for local development and when bypass headers are available.
* refactor: move healthCheck to core package as utility function
Instead of adding healthCheck to the World interface (which duplicated
the same implementation across all worlds), this is now a utility function
in @workflow/core that takes the World as a parameter.
Usage:
import { healthCheck } from '@workflow/core';
const result = await healthCheck(world, 'workflow');
This is cleaner because:
- Single implementation instead of 3 identical ones
- World implementations remain simple
- No changes needed to the World interface
* .
* refactor: move health check types from world to core
Health check types (HealthCheckPayloadSchema, HealthCheckResult, etc.)
are now defined in @workflow/core since that's where they're used.
The HealthCheckPayloadSchema is still part of QueuePayloadSchema in
world (so the queue accepts health check messages), but it's not
exported from the public API.
* .
* Refactor health check implementation based on code review feedback (#746)
* Initial plan
* Address PR review comments: export types, fix race condition, improve error handling
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Add queue-based health check test and document security considerations
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Replace 'any' type with proper type guards for health check response
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* Extract health check queue names as constants and improve type guards
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
* .
* Fix e2e test
* .
* .
* .
* .
* .
* Update packages/world/src/queue.ts
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
* Use temporary workflow-server deployment URL
* .
* .
---------
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TooTallNate <71256+TooTallNate@users.noreply.github.com>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Vercel Release Bot <88769842+vercel-release-bot@users.noreply.github.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto 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.

Gemini tool-calls fail after first step because thought_signature is dropped

3 participants

@pranaygp@VaguelySerious