hive collector runs only on hive hosts; review classifier pushes metrics through its forwarder
This commit is contained in:
parent
03796f1964
commit
0cbfa806d3
9 changed files with 191 additions and 98 deletions
|
|
@ -655,14 +655,15 @@ Add a filter such as `F_OUTCOME:="post-failed"` before the `|` to narrow it.
|
|||
The swarm UI shows no token counts, cache counts or cost, on any page. On the
|
||||
claude runtimes, every classifier run starts its `claude` process with
|
||||
`OTEL_RESOURCE_ATTRIBUTES` naming the repo and the PR, so the cost reads from
|
||||
the metrics store by repo and PR. The process exports to the hive-tier collector on
|
||||
the classifier's host, where that host runs one. On a subscription, cost is notional.
|
||||
the metrics store by repo and PR. The process exports to the OTLP receiver of the
|
||||
container's own forwarder on loopback, which pushes to the swarm collector as the
|
||||
classifier's OAuth2 client, on a host with a hive or without one. On a subscription, cost is notional.
|
||||
|
||||
On the ACP runtime, the service computes each classification's cost itself,
|
||||
from the settings' `acp.prices` and the token counts the agent reports for the
|
||||
prompt, and adds it to the counter `hyperhive.review_classifier.cost.usage`,
|
||||
labelled `repo`, `pr`, `model` (the provider's) and `currency` (`USD`). It
|
||||
exports to the same collector `claude` does. A classification stopped at its
|
||||
exports to the same receiver `claude` does. A classification stopped at its
|
||||
deadline, or whose agent reports no token counts, adds nothing. opencode
|
||||
reports no cost of its own for a provider without prices in its config, which
|
||||
is why the prices are a setting.
|
||||
|
|
|
|||
Loading…
Reference in a new issue