fine-grained-tool-streaming

Patch Claude Code cli.js to enable fine-grained tool streaming for input_json_delta events.

2|Updated Jan 30, 2026
One-click install
npx skills add https://github.com/tankygranny05/agent-box --skill fine-grained-tool-streaming
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: fine-grained-tool-streaming
Source: https://github.com/tankygranny05/agent-box/tree/main/agent-box/seed/codex-skills/fine-grained-tool-streaming
Command: npx skills add https://github.com/tankygranny05/agent-box --skill fine-grained-tool-streaming

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires re, sys, shutil, pathlib, and includes scripts (resource) components.

What problem does it solve?

This Skill addresses an issue where tool call arguments in Claude Code cli.js are not streamed incrementally, leading to a less efficient and potentially broken tool usage experience.

Core Features & Use Cases

  • Enables Incremental Streaming: Patches cli.js to activate the fine-grained-tool-streaming-2025-05-14 beta.
  • Fixes Partial JSON: Resolves cases where tool arguments arrive as a single burst instead of streaming character-by-character.
  • Use Case: When Claude Code's tool usage appears sluggish or arguments are not processed as they are generated, this patch ensures a smoother, more responsive interaction.

Quick Start

Run the patch script to modify your local cli.js file.

Frequently Asked Questions about fine-grained-tool-streaming

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
Why are tool call arguments not streaming incrementally in Claude Code?

Tool call arguments are not streaming incrementally in Claude Code because the local cli.js lacks the fine-grained-tool-streaming beta flag, causing arguments to arrive as a single burst instead of character-by-character.

How do I enable fine-grained tool streaming for input_json_delta events?

To enable fine-grained tool streaming for input_json_delta events, you run a Python patching script that inserts the specific beta flag into your local Claude Code cli.js file to activate incremental streaming.

What do I need to patch cli.js for incremental tool argument streaming?

Patching cli.js for incremental tool argument streaming requires a Python environment with the re, sys, shutil, and pathlib modules available to execute the script that modifies the local Claude Code installation.

Does patching Claude Code cli.js fix partial JSON tool arguments?

Patching Claude Code cli.js fixes partial JSON tool arguments by activating the fine-grained-tool-streaming-2025-05-14 beta, ensuring tool arguments are processed smoothly as they are generated rather than sluggishly.

What happens if the Python patching script fails to modify cli.js?

If the Python patching script fails to modify cli.js, fine-grained tool streaming remains disabled and tool arguments will continue arriving as a single burst, resulting in sluggish and potentially broken tool usage.