# Qwen3 tool calls not parsed into AIMessage.tool_calls on OCI

## What was going on

Using Qwen3 models through ChatOCIGenAI with LangChain tool calling, the tool calls are not parsed into AIMessage.tool_calls. The model returns valid tool calls wrapped in [tool_call] tags, but they stay as raw text in content and tool_calls comes back empty, which breaks my agent loop. I retried the same request several times over an hour and got the same error each time. The model name and parameters match the docs.

## The fix that worked

The model was returning tool calls in Qwen-style [tool_call]...[/tool_call] or [tool_calling]...[/tool_calling] tags, and the parser simply did not handle those tags, so everything stayed in content and tool_calls came back empty. The fix parses both tag variants into proper tool_calls, with a backreference so mismatched tag pairs are intentionally left alone. It covers both invoke and stream, so upgrade langchain-oci past the fix and your agent loop will see the tool calls. Source: https://github.com/oracle/langchain-oracle/issues/207

## Where this came from

https://github.com/oracle/langchain-oracle/issues/207