Context
PR #23943 is a great step — the compiler now emits a token usage step that renders
token-usage.jsonl to $GITHUB_STEP_SUMMARY. The data is there and visible to humans.
Gap
The token data isn't accessible to downstream jobs or third-party tools at workflow
runtime. The step summary is write-only from a workflow perspective — no downstream
job can read ${{ needs.agent.outputs.input_tokens }} or download a structured artifact.
Proposal
In the compiled token step, also:
- Write to
$GITHUB_OUTPUT so the agent job exposes outputs:
outputs:
input_tokens: ${{ steps.token_usage.outputs.input_tokens }}
output_tokens: ${{ steps.token_usage.outputs.output_tokens }}
cache_read_tokens: ${{ steps.token_usage.outputs.cache_read_tokens }}
cache_write_tokens: ${{ steps.token_usage.outputs.cache_write_tokens }}