Ask
68
@mature_student_j ·

first month with an agent — is 40 tool calls for a one-file edit normal context-window

Been using an agent in the editor for about four weeks. Asked it to add a field to a form and wire it to the API. It read 14 files, ran the test suite twice, grepped for four different things and made six edits — roughly 40 tool calls, about three minutes.

The result was correct. But I could have done it in 90 seconds because I know where the two files are.

Is that ratio just what this is? Am I supposed to be pointing it at files? I don't know what good looks like yet and everyone on my team just says "yeah, it does that".

10 answers Share
Report

Answering anonymously — a moderator will review it first.

  • @wonder_why_wren · 9mo ago · 3 replies

    Yes, you're supposed to point it at the files. 40 tool calls means it spent most of that time doing the part you had already done — working out where things live.

    For a task where you already know the answer: name the files, name the pattern to copy, say what done looks like. "Add a vatNumber field to CustomerForm.tsx following how taxId is done, update the zod schema in schemas/customer.ts and the handler in api/customers.ts." That's about eight tool calls and 40 seconds.

    Exploration mode is for when you don't know where things are — unfamiliar repo, a bug you can't localise. Then 40 tool calls is cheap and worth it. The mistake is using exploration mode on a task you could have specified in a sentence.

    94
    Share
    Reply

    Answering anonymously — a moderator will review it first.

    Report
    • @mature_student_j · 9mo ago

      So the skill is knowing which mode I'm in. That's a much more useful frame than 'write better prompts'.

      26
      Share
      Reply

      Answering anonymously — a moderator will review it first.

      Report
    • @coworking_cass · 9mo ago

      And be honest about it — half the time I think I know where the code is and I'm wrong. Letting it look is fine, just don't do it out of habit on something you could specify.

      17
      Share
      Reply

      Answering anonymously — a moderator will review it first.

      Report
  • @heirloom_hank · 9mo ago

    Worth checking a slightly different question: was it 90 seconds for you, or 90 seconds plus the twenty minutes you'd have spent getting back into the thing you were doing before? The comparison people make is usually "me at my sharpest and focused" against "the agent, measured honestly".

    That said, for a task this small, typing it yourself is usually right and you shouldn't feel like you're doing it wrong. The wins are in the twenty-minute-to-two-hour band, not the 90-second band.

    52
    Share
    Reply

    Answering anonymously — a moderator will review it first.

    Report
  • @negativesplitz · 9mo ago · 2 replies

    Normal, and it'll bother you less once you stop watching it. I got a lot more value when I started giving it tasks I could walk away from for five minutes rather than tasks I supervise keystroke by keystroke. Watching a three-minute agent run is like watching a compiler — technically informative, mostly a waste of your attention.

    19
    Share
    Reply

    Answering anonymously — a moderator will review it first.

    Report
    • @iris_tanaka · 9mo ago

      Depends on the task. I supervise anything writing to files I care about. But for 'find everywhere this config is set across the monorepo', absolutely walk away.

      11
      Share
      Reply

      Answering anonymously — a moderator will review it first.

      Report
  • @drainfield_dez · 9mo ago · 2 replies

    Normal in the sense that everyone sees it, not in the sense that it's optimal. Things that reduce it a lot:

    • a project instructions file that says where things are. Directory layout, where schemas live, which commands to run. Saves the same six exploratory calls every single session
    • tell it not to run the full suite unless asked. Test runs are usually the most expensive calls and it'll do them reflexively
    • be specific about done: "add the field, don't run the suite, just typecheck"
    31
    Share
    Reply

    Answering anonymously — a moderator will review it first.

    Report
    • @mature_student_j · 9mo ago

      The full-suite-by-default thing is a big chunk of my three minutes now that I look. Ours takes 50 seconds and it ran it twice.

      14
      Share
      Reply

      Answering anonymously — a moderator will review it first.

      Report
  • @rubberduck_rae · 9mo ago

    One nuance on the token side: those 14 file reads stay in context for the rest of the session. So the 40 tool calls aren't only three minutes, they're also 30-40k tokens of material you didn't need, which makes the next three tasks in that session worse. That's the real cost, not the wall clock.

    13
    Share
    Reply

    Answering anonymously — a moderator will review it first.

    Report
  • @thesis_wrangler · 9mo ago

    four weeks in and you're already measuring tool calls. you're doing fine, most people never look

    7
    Share
    Reply

    Answering anonymously — a moderator will review it first.

    Report