Three Requests in One Sentence: Intent Decomposition and Task Orchestration for Compound Logistics Needs
"Check why it's delayed, reschedule to tomorrow, and apply for a shipping-fee refund." The user sees one matter; the system sees three completely different actions: a read-only query, a medium-risk write, and a money approval. The classic bot failure is treating it as a single tool call—answer the delay reason and reply "all handled", never rescheduling, never filing the claim; when the user finds the package still on the old schedule the next day, trust is gone. Compound requests test not the model's generation ability, but decomposition, orchestration, and state management.
This post is part of the "AI Customer Service Product and Engineering Practices" experience-sharing series, drawn from a practice review of an AI customer service product at a leading logistics company. In this post I want to share the AI Agent's intent recognition, task decomposition, tool calling, and multi-step execution flow design for compound requests such as "check the logistics exception reason, modify the delivery time, and apply for shipping-fee compensation". This is the watershed between task-oriented agents and Q&A bots.

Five Key Design Points in Multi-Intent Orchestration
- Multi-intent recognition and slot extraction: splitting one sentence into multiple requests and completing key parameters such as tracking number, time, and address.
- Task decomposition and dependency orchestration: identifying ordering dependencies among subtasks and forming an executable task tree or DAG.
- Tool call design: parameter validation, idempotency, timeout retry, and outcome verification must be complete.
- Multi-step state management: how to handle interrupted resumption, partial success, and failure rollback.
- Interaction design: follow-up clarification, double confirmation, and structured feedback that respect user experience.
The Overall Design
In this effort, I would treat it as a multi-task orchestration problem, not a comprehension problem. The overall approach in one sentence: split intents and fill slots without guessing, build the task tree from business dependencies, validate each step with double confirmation, persist state for resumable execution, and report results item by item.
Step 1: Decompose intents, extract slots, and follow up on missing information
The sentence holds three things—check the exception reason, change the delivery time, apply for compensation. Split them into three independent intents and extract slots such as tracking number, expected time, address, and amount; when information is incomplete, follow up first and never guess—the cost of acting on a wrong guess far exceeds one extra question.
Step 2: Build the task tree from business dependencies
The three tasks have dependencies: you must first use the tracking number to query the trajectory and the exception node—confirming what stage the package is in and whether it is truly abnormal—before judging whether rescheduling is possible; and whether the reschedule succeeds in turn affects the compensation decision. So build a task tree, order execution by dependency, parallelize what can run in parallel and strictly serialize what cannot, rather than mechanically requiring "claim only after rescheduling".
Step 3: Validate every step; double-confirm medium and high risk
Each execution step passes validation: identity, order state, operation permission, and schema-validated parameters; medium-risk writes like changing the delivery time must show the user the change and its impact and obtain explicit confirmation before executing.
Step 4: Execute tool calls to engineering standards
Tool calls carry an idempotency key to prevent duplicate execution, retry on timeout per policy, and after success query the business system again to confirm it actually took effect—an HTTP 200 is not success. On an ambiguous timeout, first reconcile whether the write happened before deciding to retry.
Step 5: Persist state for resumable runs and partial success
Use a workflow engine to record the state of every subtask (pending, running, outcome unknown, successful, failed, under human review), so an interrupted run can resume from the breakpoint without redoing completed steps; when the user interrupts or the case goes to humans, preserve finished results and outstanding requests.
Step 6: Report structured results
Finally, give the user an honest itemized list: reschedule succeeded, claim in progress, expected payout time—each stated separately; unfinished parts go to humans with a summary of the dialogue and completed operations so the user never re-explains. A completed query, a successful reschedule, and a pending claim are three different outcomes—never compress them into "everything is handled".
Practice in Bytedesk
The open-source Bytedesk customer service system (GitHub, website https://www.weiyuai.cn ) provides the foundations for this approach: multi-turn conversation memory helps the Agent understand context and follow up across turns to fill slots; tool management configures external actions such as logistics queries and delivery changes for robots and agents, serving as the entry point for "getting things done"; the ticket module records requests that need further handling and their owners, fitting approval-flow tasks like compensation claims; transferring to humans carries the full conversation context so agents continue only the unfinished parts. The multi-goal task graph, per-step state persistence, and parameter versioning must be implemented in a dedicated business orchestration layer—conversation memory and ticket state do not replace tool idempotency and outcome verification.
Key Takeaways
- Split compound requests into independent intents and complete the slots first—follow up on missing information, never guess.
- Task dependencies come from business rules: querying the exception node usually precedes judging rescheduling, and the reschedule result feeds back into the compensation decision.
- Medium and high-risk writes require double confirmation; tool calls carry idempotency keys, and success requires a second query to confirm the effect.
- Persist the state of every subtask to support resumable runs and partial success, never redoing completed steps.
- Report honestly, item by item: state results for what is done, hand off what is not with a service summary—never bundle everything into "all handled".
