]> git.giacomolli.uk - onechat/commit
Record the subagent name in the usage records
authorAnderson A. Giacomolli <redacted>
Sun, 8 Nov 2026 12:50:31 +0000 (09:50 -0300)
committerAnderson A. Giacomolli <redacted>
Sun, 8 Nov 2026 12:50:31 +0000 (09:50 -0300)
commit7594b9938b7343717e7a57aa7aede5d40d547483
treece8053c5a656b37673f07960add0880308298a92
parent9bd91a76e6277f7716e206ddb665dc5fe6f5b583
Record the subagent name in the usage records

A model request names the subagent that makes it, and the usage record
of the call holds that name in the agent field. A call of the agent
itself has no such field. The name goes only to the usage file, never to
the endpoint, so the usage records show the cost of each subagent in the
shared usage file of the agent.

Issue: b1ac698
model.go
model_test.go