Skip to content

OTel: document and stabilise gen_ai.tool.call.arguments schema per built-in tool #5661

Backlog

Description

@k4otix

Describe the feature or problem you'd like to solve

gen_ai.tool.call.arguments is the standard place for tool inputs, but the format of each built-in tool isn't documented and differs by tool:

  • bash → JSON {"command": …, "description": …}
  • view → JSON {"path": …}
  • web_fetch → JSON {"url": …}
  • apply_patch → raw patch text, not JSON (*** Begin Patch\n*** Add File: …)

Which file-writing tool appears (apply_patch vs create/edit) depends on the model, and vendor attributes (github.copilot.tool.parameters.command, …file_path) exist only for some tools. Anyone parsing these attributes (detection rules, dashboards, cost tooling) breaks silently when a tool or its argument names change.

Proposed solution

  1. Document the argument schema for each built-in tool (bash, powershell, view, create, edit, apply_patch, web_fetch, grep, glob, task/sub-agents) in the monitoring docs.
  2. Always emit gen_ai.tool.call.arguments as JSON. For apply_patch, wrap it as {"patch": "…", "files": [{"path": …, "op": …}]}.
  3. Expose github.copilot.tool.parameters.* consistently for every tool (command, file_path, url, pattern), or drop it in favour of (2).
  4. Call out changes to tool names or argument schemas in the release notes under a telemetry heading.

Example prompts or workflows

  • One detection rule that covers file writes whichever model is selected (apply_patch vs create/edit).
  • Upgrade the CLI without silently breaking SIEM parsers.
  • Validate exported telemetry against a published schema in CI.

Additional context

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions