Fix : No Tool Output Found with Responses API + Vector Store + Function Calls

TL;DR — If you enable the OpenAI Responses API together with a vector store in AI Engine, two‑step questions crash with No tool output found…. A quick fix is to disable the Responses API; the sections below explain why the bug happens and how raw‑API users can avoid it too.

AI Engine

Turning on the Responses API + Vector Store option lets the assistant use file_search to pull passages from your PDFs or Markdown and every WordPress helper you expose, such as wp_create_post or wp_upload_media.

All good—until someone asks a two‑part question that needs both tools. GPT‑4o sends one function call, waits for your reply, then sends the second. Because the Responses API expects all calls and outputs in a single response, AI Engine throws:

No tool output found for function call…

Single‑tool prompts are fine; multi‑tool + vector store is what breaks.

Quick Fix

In AI Engine → Settings → DevTools, switch off “Use Responses API,” or phrase questions so that only one tool fires per turn.

AI Engine Roadmap

Stateful collector — intercept the assistant’s first reply, keep asking “continue” until every function_call arrives, then run them together.

Smart gating — when a prompt clearly contains “and” or “also,” temporarily disable file_search so the model stays in normal multi‑function mode.

Wait for OpenAI — once the platform fixes parallel calls with vector stores, you can re‑enable the Responses API and enjoy true one‑shot automation.

All these approaches are work‑arounds; a real fix must come from OpenAI.

Direct Use of the OpenAI API

The same bug appears in custom apps that combine file_search (or any vector tool) with two or more custom functions.

What breaks

Desired flow — the assistant replies once with [function_call A, function_call B]. You execute both and return both outputs.

Actual flow with file_search on — the assistant sends only function_call A. After you answer, it sends function_call B. The Responses API complains because B should have been in the first response.

Reasoning‑mode models (GPT‑4o, o4‑mini) prefer to chain tools turn‑by‑turn, but the API spec demands they come together. Hence the clash.

Cleaner approaches

Collector loop — keep calling POST /responses with previous_response_id until the assistant stops emitting new function_calls, then execute everything at once.

Selective tool set — answer the vector‑store part first, then send a second prompt for the remaining tools.

Hang tight — OpenAI has acknowledged the bug; once fixed, multi‑call orchestration should “just work.”

// pseudo‑collector
let messages = [];
let pending = [];

let res = await openai.responses.create({ model, tools, messages });

while (res.choices[0].message.tool_calls) {
  pending.push(...res.choices[0].message.tool_calls);

  res = await openai.responses.create({
    model,
    tools,
    previous_response_id: res.id,
    messages
  });
}

// run pending ➜ send outputs

For now: keep it single‑tool or single‑turn

If you see No tool output found… in your logs, ask yourself: “Am I calling two tools and file_search in the same turn?” If so, split the steps or use the collector loop above until the next model update.

That should keep your chats humming—whether you run WordPress with AI Engine or wire straight into the OpenAI API. Happy building!