Skip to content

Conversation

@qandrew
Copy link
Owner

@qandrew qandrew commented Nov 14, 2025

Purpose

  • add browser tool, container tool

Test Plan

VLLM_GPT_OSS_SYSTEM_TOOL_MCP_LABELS=web_search_preview,container,code_interpreter VLLM_USE_EXPERIMENTAL_PARSER_CONTEXT=1 vllm serve MiniMaxAI/MiniMax-M2   --tensor-parallel-size 4   --tool-call-parser minimax_m2   --reasoning-parser minimax_m2    --enable-auto-tool-choice --trust-remote-code  --tool-server=localhost:8081/container,localhost:8081/browser,localhost:8081/python
curl -X POST "http://localhost:8000/v1/responses"   -H "Content-Type: application/json"   -H "Authorization: Bearer dummy-api-key"   -d '{
        "model": "MiniMaxAI/MiniMax-M2",
        "input": "Whats the latest news in New York City?",
        "tools": [
          {
            "type": "mcp",
            "server_label": "web_search_preview",
            "headers": {"test": "test"},
            "server_url": "IGNORED"
          }
        ]
      }'
{
    "id": "resp_a0ab2dc5053d4a48afb5c3d911cd09c0",
    "created_at": 1763163144,
    "incomplete_details": null,
    "instructions": null,
    "metadata": null,
    "model": "MiniMaxAI/MiniMax-M2",
    "object": "response",
    "output": [
        {
            "id": "rs_b7de25e4622c4e529dccd332a8ff75a9",
            "summary": [],
            "type": "reasoning",
            "content": [
                {
                    "text": "Okay, the user is asking for the latest news in New York City. This is a straightforward request for current information that I'll need to search for online.\n\nFirst, I need to consider how to approach this. Since the user is asking for \"latest news,\" they're looking for current, up-to-date information about events happening in New York City right now. This is exactly the type of query that would benefit from a web search rather than relying on my training data, which has a knowledge cutoff date.\n\nLooking at the tools available to me, I see I have access to a \"web_search_preview\" tool. This seems perfect for this request since I need to fetch current information about news in New York City. The tool requires parameters to work properly.\n\nFor the search query, I need to formulate something that will return relevant and recent news about New York City. The most direct approach is to search for \"news New York City\" which should return current news articles and stories about the city.\n\nI notice the tool requires approval before use according to the system message (\"require_approval\": null in the tool description). However, since this is a straightforward information request that the user is explicitly asking for, and the web search is directly relevant to fulfilling their request, I should proceed with using the tool.\n\nI'll need to format my tool call correctly with the appropriate XML tags and include the search query as a parameter. The format needs to include:\n1. The tool name: \"web_search_preview\"\n2. The arguments: a JSON object with the search query parameter\n\nSo I'll call the web_search_preview tool with \"news New York City\" as the search query to get the most recent news stories from the area. This should return a variety of news sources and stories that I can then present to the user.\n",
                    "type": "reasoning_text"
                }
            ],
            "encrypted_content": null,
            "status": "completed"
        },
        {
            "id": "msg_7475f128a26742c999a110b3cd590c5d",
            "content": [
                {
                    "annotations": [],
                    "text": "\n\n\n",
                    "type": "output_text",
                    "logprobs": null
                }
            ],
            "role": "assistant",
            "status": "completed",
            "type": "message"
        },
        {
            "arguments": "{\"query\": \"news New York City\"}",
            "call_id": "call_4c38ce68e7fd495fb8c3fcaa0e858600",
            "name": "web_search_preview",
            "type": "function_call",
            "id": "fc_5e6d1c1ae06b430fbb0c23f82e93e132",
            "status": "completed"
        },
        {
            "id": "rs_c534692966f44828813068ab13f73ef1",
            "summary": [],
            "type": "reasoning",
            "content": [
                {
                    "text": "Hmm, I see that the web search didn't return the specific news content I was hoping for. The search tool only returned a very brief result showing \"news New York City\" followed by a link to Google News for New York. This isn't particularly helpful since I don't have access to the actual news articles.\n\nLet me analyze what happened here. I tried to search for \"news New York City\" using the web_search_preview tool, but the response only gave me a pointer to Google News rather than actual news articles. This suggests that either:\n1. The search tool requires a more specific query format\n2. The tool might not be returning the full content of news articles\n3. There might be some technical limitation with how the search results are being displayed\n\nLooking at the result again, I can see \"viewing lines [0 - 3] of 3\" which suggests there are only 3 lines of results returned. This is quite limited and doesn't give me the actual news content the user is looking for.\n\nI need to try a different approach. Since I couldn't get specific news stories through the search, I should try to narrow down my search to get more relevant results. Instead of just \"news New York City,\" I should try to get more specific types of news or use a more targeted search query.\n\nOne approach is to search for \"breaking news New York City\" which might return more urgent or current news stories. Breaking news is typically what people are looking for when they ask for the \"latest news.\"\n\nAlternatively, I could search for \"New York City local news\" to get more locally-focused stories.\n\nLet me try the \"breaking news New York City\" query first, as this is most likely to return the current, urgent news that the user is probably interested in when asking about the \"latest news\" in NYC. This might give me access to more specific articles rather than just a general link to Google News.\n\nI'll make another web search with this more specific query and hope to get better results that I can actually use to provide the user with current New York City news.\n",
                    "type": "reasoning_text"
                }
            ],
            "encrypted_content": null,
            "status": "completed"
        },
        {
            "id": "msg_d4666ba7e2794e6e9abe05e5334d455d",
            "content": [
                {
                    "annotations": [],
                    "text": "\n\n\n",
                    "type": "output_text",
                    "logprobs": null
                }
            ],
            "role": "assistant",
            "status": "completed",
            "type": "message"
        },
        {
            "arguments": "{\"query\": \"breaking news New York City\"}",
            "call_id": "call_30af911ca0e3446186a99ececa22d746",
            "name": "web_search_preview",
            "type": "function_call",
            "id": "fc_0d43b0eccd774d4d8e082c141d8af59a",
            "status": "completed"
        },
        {
            "id": "rs_d7554918b74f44d6a6c1ca82e952af2e",
            "summary": [],
            "type": "reasoning",
            "content": [
                {
                    "text": "I see that I've attempted to search for news in New York City twice now, and both attempts have returned the same limited results. This is quite frustrating. Let me analyze what's happening here.\n\nIn my first search, I used the query \"news New York City\" and got back a very brief result showing:\n- \"# Search Results\"\n- A pointer to \"Google News - New York - Latest\" with a note to read full articles\n\nThen I tried a more specific search with \"breaking news New York City\" thinking it might return more urgent or current news stories, but I received essentially the same result.\n\nLooking at the tool response format, I notice it shows \"viewing lines [0 - 3] of 3\" which indicates there are only 3 lines of results being returned, and they don't contain actual news articles - just a link to Google News. This suggests there might be a technical limitation with how the web_search_preview tool is working in this context.\n\nHmm, I have a few options at this point:\n\n1. I could try another search with a different query, perhaps something more specific like \"today's news New York City\" or \"New York local news\"\n\n2. I could try searching for specific news categories like \"NYC politics news\" or \"NYC weather news\"\n\n3. I could explain to the user that I'm having technical difficulties retrieving the latest news\n\nGiven that my first two attempts with different queries returned the same result, I'm concerned that no matter what specific query I use, I might continue to get this same limited response. The web_search_preview tool doesn't seem to be returning the actual news content I need to fulfill the user's request.\n\nAt this point, I think the most straightforward approach is to acknowledge the limitation, provide what information I do have (the Google News link), and suggest that the user can check that link directly for the latest news in New York City. This is honest about the constraints I'm facing while still trying to be helpful by providing a relevant resource.\n\nI'll craft a simple, straightforward response that acknowledges I couldn't retrieve specific news articles but can point them to the Google News page for New York, where they can find the latest local news themselves.\n",
                    "type": "reasoning_text"
                }
            ],
            "encrypted_content": null,
            "status": "completed"
        },
        {
            "id": "msg_37bbc1da9bef4676b63f107b9dd66dc6",
            "content": [
                {
                    "annotations": [],
                    "text": "\n\nIt seems I couldn't retrieve the latest news articles directly. However, I recommend checking the \"Google News - New York - Latest\" page for the most recent news in New York City. You can visit the page to read full articles and browse through thousands of titles related to New York.",
                    "type": "output_text",
                    "logprobs": null
                }
            ],
            "role": "assistant",
            "status": "completed",
            "type": "message"
        }
    ],
    "parallel_tool_calls": true,
    "temperature": 1.0,
    "tool_choice": "auto",
    "tools": [
        {
            "server_label": "web_search_preview",
            "type": "mcp",
            "allowed_tools": null,
            "authorization": null,
            "connector_id": null,
            "headers": {
                "test": "test"
            },
            "require_approval": null,
            "server_description": null,
            "server_url": "IGNORED"
        }
    ],
    "top_p": 0.95,
    "background": false,
    "max_output_tokens": 195346,
    "max_tool_calls": null,
    "previous_response_id": null,
    "prompt": null,
    "reasoning": null,
    "service_tier": "auto",
    "status": "completed",
    "text": null,
    "top_logprobs": null,
    "truncation": "disabled",
    "usage": {
        "input_tokens": 1262,
        "input_tokens_details": {
            "cached_tokens": 1120,
            "input_tokens_per_turn": [],
            "cached_tokens_per_turn": []
        },
        "output_tokens": 1344,
        "output_tokens_details": {
            "reasoning_tokens": 0,
            "tool_output_tokens": 0,
            "output_tokens_per_turn": [],
            "tool_output_tokens_per_turn": []
        },
        "total_tokens": 2606
    },
    "user": null,
    "input_messages": null,
    "output_messages": null
}

@qandrew qandrew force-pushed the parser-sentence-mcp branch from a02b1be to c225a90 Compare November 16, 2025 00:54
@qandrew qandrew force-pushed the parser-browser-tool branch from bd366b8 to 5b7359a Compare November 16, 2025 00:59
Sign up for free to 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.

2 participants