WENBU · FIELD NOTES

When an agent call fails, read the status and conventions before retrying

A failed or partial agent call should be read in order: returned status, input fields, then the stated conventions, before deciding to retry, fix the input or stop. A triage table separates invalid fields, rate limits, broken streams, budget-limited turns and successful-but-empty results, and says what each does not prove.

Wenbu · AI-assisted editorialFigures · Worked example · Sources

Read the status first, then the input, then the conventions. For MCP, check isError before reading structured content. For the built-in agent command, check the status on the done event: complete means the turn finished, waiting means the user must add something, limited means the budget is used up, and error or a stream with no terminal event is not completion. REST errors carry a stable code and a readable message; 422 usually means an invalid field or time, and 429 means short-term rate limiting or insufficient AI quota. Keep what you already received, but let the user decide on a retry; an AI request that has started may be counted even if it fails, so do not retry automatically. An error says this call did not finish as agreed. It does not say the tool is broken, the cards were drawn wrongly, or the interpretation is inaccurate.

  • Check isError or the status on the done event before reading content; a stream with no terminal event is not completion.
  • For 422-style errors, check fields and times first; for 429-style errors, back off and read the message instead of resending immediately.
  • An AI request that has started may be counted even if it fails, so retries belong to the user, not an automatic loop.
  • A successful but empty result often points to input or scope, and does not show that the tool lacks a capability.

Reading order for a failed call

  1. Read the status

    For MCP, check isError; for the agent command, check whether the done event status is complete, waiting or limited. An error and a stream with no terminal event are not completion.

  2. Read the input

    Check fields, the date range, timezone and clock time. 422 usually points to an invalid field or time; an omitted timezone defaults to Asia/Shanghai and returns a warning.

  3. Read the conventions

    Confirm the convention in use, such as the day boundary, the solar-time approximation, or the tarot card count and reversal setting, so a convention difference is not mistaken for an error.

  4. Decide

    Fix the input, back off, keep the received content for the user, or stop. On 429, back off; an AI request that has started may be counted, so do not retry automatically.

A four-step flow from status to conventions to decision. It describes a reading order, not an automatic retry policy; each step rests on a status or convention the public documentation states.

Read the status: did this call actually finish?

The first step in judging an agent call is not whether the content looks like an answer, but what the protocol says about the outcome. MCP declares an outputSchema for successful results and returns structuredContent, and the documentation says to check isError first; if isError is true, the structured content that follows should not be treated as a usable result. The built-in agent command emits line-by-line JSON events, and you check the status on the done event: complete means the turn finished, waiting means the user must add something, and limited means the budget is used up. An error, or a stream with no terminal event, is not completion.

This step separates "I did not get the answer I wanted" from "the call did not finish." When a stream breaks, you may keep what you already received, but it is a partial artifact; treating it as a finished reading builds later follow-up questions on incomplete context. The documentation also says a retry is the user's decision rather than something the agent should loop on its own. Status is a fact; whether the content is sufficient is a judgment. Keep them apart.

Read the input: do fields, times and conventions line up?

When the status shows the call did not finish, the next thing to check is the input. REST endpoints use POST application/json, personal input must not go in the URL, and 422 usually means an invalid field or time. Check each item against the public conventions: bazi input is a Gregorian date from 1901 to 2099, the local clock time at the birthplace, and an IANA timezone name or an explicit UTC offset; an omitted timezone defaults to Asia/Shanghai and returns a warning; an unknown birth time omits the hour pillar. These are input problems you can correct, not tool defects.

Conventions also determine which results are expected to carry uncertainty. Solar-time correction is an approximation, and near a day or hour boundary the documentation suggests comparing settings; ziwei does not convert timezones or correct solar time automatically; tarot draws one or three cards from a 78-card deck with equal probability and no repeats within a single draw. If a result does not match expectations, confirm which convention you sent before deciding it is an error. Mistaking a convention difference for a failure invites unnecessary retries.

The triage table: what to check first for five outcomes

The table below groups common outcomes into five types, each with what to check first and what it does not prove. It relies only on statuses and conventions the public documentation actually states, and adds no error codes, retry counts or quota reset times that the documentation does not declare. When you meet a case the documentation does not describe, record the raw response and stop inferring rather than applying a rule of thumb.

Note that this table is a reading order, not an automatic retry policy. An invalid field means fix the input; a rate limit means back off and read the message; a broken stream means keep what arrived and return the decision to the user; an exhausted budget means stop and say so; a successful but empty result means check scope first. None of these supports the conclusion that the tool is unusable, because a single outcome cannot cover every tool and every input.

Retry boundaries: when to stop

The documented boundary is specific: on 429, back off; an AI request that has started may be counted even if it fails, so do not retry automatically. Together these mean a retry is not a free default action but a choice the user should make with the facts in hand. For calculation tools, the same input can be recomputed under the stated conventions; for random draws, a new draw produces a different result, and the public convention asks you to keep the returned cards rather than redraw without the user choosing to.

Stopping is therefore also a correct handling. When the status is limited, or a stream broke and the user has not decided, or the message points to quota rather than input, resending only spends more attempts without adding information. Handing the raw response, the content received and your judgment to the user is closer to reviewable work than an automatic retry. Passing software tests only shows that tested behavior matches the conventions; it does not validate predictions, and the same caution applies to reading an error.

Triage table for agent call outcomes
OutcomeCheck firstWhat it does not prove
Invalid field or time (e.g. 422)Check field names, whether the date is within 1901–2099, the timezone format and the clock time; read the readable error messageDoes not show the tool lacks that capability, and does not show the chart itself is wrong
Rate limit or insufficient quota (e.g. 429)Read the message to tell short-term rate limiting from insufficient AI quota; back off as documentedDoes not show the service is permanently unavailable, and you cannot assume when quota resets
Broken stream, no terminal eventConfirm whether a done event arrived; keep the content already receivedDoes not make a partial artifact a finished reading, and does not show the model reached a wrong conclusion
Budget-limited turn (limited)Confirm the status is limited and state that this turn's budget is used upDoes not show the input was wrong, and does not show later turns will be limited the same way
Successful but empty resultCheck search scope, locale and whether the input falls within the tool's coverageDoes not show the feature does not exist; a page not describing a capability is not evidence the vendor lacks it

Hypothetical case: a three-card reading request breaks mid-stream (fictional scenario)

The following is a fictional teaching scenario and corresponds to no real user or real chart. Suppose a reader asks an agent for a three-card reflection exercise, the host disconnects mid-stream, and the interface shows text for only the first two cards. The reader wants to know whether to resend the request immediately.

  1. Step one, read the status: check whether a done event arrived. In this case there is no terminal event, so by the documentation it is a broken stream, not completion; even if the first two cards look plausible, they cannot be treated as a complete result.
  2. Step two, keep what arrived: record the two displayed card names, orientations and keywords exactly. The public convention asks you to keep the returned cards rather than redraw without the user choosing to.
  3. Step three, read the input and conventions: confirm whether the request asked for one card or three, whether reversals were enabled, and whether locale was explicit. This request asked for three and returned two, which points to a transport interruption rather than a card-count setting.
  4. Step four, decide: give the reader the fact of the broken stream, the content received, and the choice of whether to draw again. If the reader chooses a new draw, it is an independent random procedure that may coincidentally repeat a card or differ entirely; do not promise to reproduce the original cards.
  5. Step five, record: note in the journal that this was a broken stream, what was kept, and what the reader chose. That record is more reliable than memory the next time something similar happens.

The specific lesson is that a broken stream and "bad cards" are different problems. A broken stream is an unfinished call, handled by keeping content and returning the decision; card meaning is interpretation, which the reader judges against their own situation. Confusing the two leads to redrawing over a transport problem, or resending requests over an interpretive one.

Questions you may have

An MCP call returned content but I am unsure it succeeded. Where do I look first?

Check isError first. The documentation says MCP declares an outputSchema for successful results and returns structuredContent, and asks you to check isError; if it is true, do not treat the content that follows as a usable result. Once success is confirmed, read the structured fields and compare the input and conventions with what you sent.

On a 429, can I just wait a bit and resend automatically?

The documentation says to back off on 429 and explains that 429 means short-term rate limiting or insufficient AI quota, so read the error message. It gives no universal retry interval or quota reset time, so do not assume one. If the message points to AI quota, automatic resending may keep spending attempts; the retry should be the user's decision.

A call succeeded but returned nothing. Does that mean the tool does not support what I wanted?

That does not follow. An empty result is more likely about input scope, locale or search range; for example, search_library searches Wenbu's original material and a curated source directory, not the whole web. A page not describing a capability is not evidence the vendor lacks it; check the capabilities list for tool coverage instead of concluding from one empty result.

If I draw tarot again, can I get the same cards as last time?

Not on demand. Tarot draws one or three cards from a 78-card deck with equal probability and no repeats within a single draw; a new draw is an independent random procedure that may coincidentally repeat a card or differ entirely. The public convention asks you to keep the returned cards rather than redraw without the user choosing to.

Terms in this guide

isError
The error flag on an MCP result. The documentation asks you to check it before reading structuredContent; when it is true, the content that follows should not be treated as a usable result.
done event
The terminal event in the built-in agent command's line-by-line JSON output, whose status can be complete, waiting or limited. An error or a stream with no terminal event is not completion.
422 and 429
Two REST error statuses. 422 usually means an invalid field or time; 429 means short-term rate limiting or insufficient AI quota, and you should read the message and back off.
Keep the returned cards
Part of the tarot convention: a single draw does not repeat cards, and a new draw is a new random procedure, so keep the returned cards for follow-up rather than redrawing by default.
See the claim and source notes
  • MCP successful results declare an outputSchema and return structuredContent, and callers should check isError first.

    先检查 isError
  • Completion of the built-in agent command is read from the status on the done event; an error or a stream with no terminal event is not completion.

    error 或没有终止事件的断流都不是完成
  • The public capabilities list describes calculations as deterministic conventions or explicit random draws, and interpretations as cultural reflection rather than established factual predictions.

    Cultural reflection, not established factual predictions

Sources and review scope

This AI-assisted Wenbu article passed automated structure checks and a separate editorial model pass. It is not independent expert review or a paid-account product test.

  1. Wenbu · agent integrations ↗Current first-party product documentation · 2026-11-02 · Fetched text
  2. Wenbu · versioned public capabilities ↗First-party current tool, convention and privacy contract; not external endorsement or predictive validation · 2026-11-02 · Fetched text
  3. Wenbu · calculation conventions ↗First-party implementation; not evidence of predictive accuracy · 2026-11-02 · Fetched text

Run CLI doctor to check the connection and version

Before chasing an error, use the documented CLI doctor to confirm the connection and version, then read the response in the order of status, input and conventions; this step checks the integration only and is not a reading.

Run CLI doctor to check the connection and version ↗

Explore this guide with Wenbu ↗

WENBU · A NOTE TO US

Help shape what comes next.