Skip to content

Open-source AI browser agent for Chrome and Firefox (monorepo) 🧠

3.0 KB
Raw Blame
{
  "id": "032",
  "category": "truncation-cascade",
  "mode": "ask",
  "browser": "chrome",
  "tab": {
    "url": "https://en.wikipedia.org/wiki/Closure_(computer_programming)",
    "title": "Closure β€” Wikipedia"
  },
  "description": "After read_page truncated, agent re-fetched a different Wikipedia endpoint and that also truncated. Should now answer from what it has.",
  "seed": [
    {
      "role": "user",
      "content": "[Current page context β€” applies to this user message and supersedes older page context for phrases like \"this page\". URL: https://en.wikipedia.org/wiki/Closure_(computer_programming) β€” Title: Closure β€” Wikipedia]\n\nwhen did closures first appear in a programming language?"
    },
    {
      "role": "assistant",
      "content": "",
      "tool_calls": [
        {
          "id": "call_z_8cf059",
          "type": "function",
          "function": {
            "name": "read_page",
            "arguments": "{}"
          }
        }
      ]
    },
    {
      "role": "tool",
      "tool_call_id": "call_z_8cf059",
      "name": "read_page",
      "content": "{\"url\":\"https://en.wikipedia.org/wiki/Closure_(computer_programming)\",\"title\":\"Closure β€” Wikipedia\",\"text\":\"The concept of closures was developed in the 1960s for the mechanical evaluation of expressions in the Ξ»-calculus and was first fully implemented in 1970 as a language feature in the PAL programming language to support lexically scoped first-class functions. ...\",\"_truncated\":true,\"originalLength\":84000}"
    },
    {
      "role": "assistant",
      "content": "",
      "tool_calls": [
        {
          "id": "call_10_89f054",
          "type": "function",
          "function": {
            "name": "fetch_url",
            "arguments": "{\"url\":\"https://en.wikipedia.org/w/api.php?action=parse&page=Closure_(computer_programming)&prop=wikitext&format=json\"}"
          }
        }
      ]
    },
    {
      "role": "tool",
      "tool_call_id": "call_10_89f054",
      "name": "fetch_url",
      "content": "{\"success\":true,\"json\":\"{\\\"parse\\\":{\\\"wikitext\\\":{\\\"*\\\":\\\"... (large dump) ...\\\"}}}\",\"_truncated\":true,\"originalLength\":60000}"
    }
  ],
  "expected": {
    "idealNextToolCall": {
      "name": "done",
      "args": {
        "summary": "Closures originated in the 1960s in the context of evaluating Ξ»-calculus expressions, and were first fully implemented as a programming-language feature in 1970 in PAL."
      }
    },
    "antiPatterns": [
      {
        "match": "fetch_url({url:\"https://en.m.wikipedia.org/...\"})",
        "reason": "Third re-fetch of the same content with a different endpoint β€” xiaomi-mimo did exactly this."
      },
      {
        "match": "read_page({})",
        "reason": "Re-reading the same page."
      }
    ],
    "successRubric": "Both fetches returned the answer in their visible portion. Stop fetching, call done. Two truncated reads of the same content rarely improves the answer."
  }
}