Codex usage data provider for `mngr usage` (rollout token_count -> cost_snapshot writer + reader)
Project description
imbue-mngr-codex-usage
Codex data provider for mngr usage. Codex exposes no statusline or in-process
plugin, but mngr already tails its rollout JSONL into a raw transcript via
mngr_codex's background-tasks supervisor. This package adds:
- The writer (
codex_usage.sh): installed into the agent'scommands/dir, where mngr_codex'scodex_background_tasks.shlaunches it iff present. It reads the raw rollout stream and emits onecost_snapshotpertoken_countitem toevents/codex/usage/events.jsonl. - The reader: an
aggregate_usage_sourcehookimpl claiming thecodexsource, aggregated session-cumulatively (eachtoken_countcarries the session's cumulative total, so the freshest per session wins).
What gets captured
Codex reports cumulative token usage (info.total_token_usage) but no dollar
cost, so cost is left null and the reader estimates it from tokens via the
pricing table (provenance ESTIMATED). input_tokens includes cached, so the
writer emits input = input_tokens - cached_input_tokens and
cache_read = cached_input_tokens (OpenAI has no cache-write surcharge). The
model is openai/<model> from the rollout's turn_context.
In ChatGPT-plan (subscription) mode, token_count also carries 5h/7d rate-limit
windows, which the writer maps onto the window schema -- so Codex subscription
agents get Claude-style windows, and the session is classified SUBSCRIPTION
(imputed). Without rate limits it's API_KEY (real spend).
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file imbue_mngr_codex_usage-0.1.2.tar.gz.
File metadata
- Download URL: imbue_mngr_codex_usage-0.1.2.tar.gz
- Upload date:
- Size: 18.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
37f63443979dc1c4f7047788e40c5a3ac7911d3c23fd77c1783061381faaf73b
|
|
| MD5 |
d7d23f5c6eafb7007f1807649f0a6892
|
|
| BLAKE2b-256 |
0f8cb511849faca3c7f8c6cb18e44b0a6146377c8abc9bed7cb0abe12144c8f2
|
Provenance
The following attestation bundles were made for imbue_mngr_codex_usage-0.1.2.tar.gz:
Publisher:
publish.yml on imbue-ai/mngr
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
imbue_mngr_codex_usage-0.1.2.tar.gz -
Subject digest:
37f63443979dc1c4f7047788e40c5a3ac7911d3c23fd77c1783061381faaf73b - Sigstore transparency entry: 1858307696
- Sigstore integration time:
-
Permalink:
imbue-ai/mngr@ed465f3fc2a0b4ad935d473b03bcffb205fac223 -
Branch / Tag:
refs/tags/v0.2.17 - Owner: https://github.com/imbue-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@ed465f3fc2a0b4ad935d473b03bcffb205fac223 -
Trigger Event:
push
-
Statement type:
File details
Details for the file imbue_mngr_codex_usage-0.1.2-py3-none-any.whl.
File metadata
- Download URL: imbue_mngr_codex_usage-0.1.2-py3-none-any.whl
- Upload date:
- Size: 9.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
89e585d6218854dc587e16acbd487dc0ab0af3aafa3df50211210fd84b907e61
|
|
| MD5 |
f751c1c857a6b9dec4f8a8ba12ef41e8
|
|
| BLAKE2b-256 |
18bb1a59e7d65b7f06d463709bf079f68501b0a0f0749313da2c07230737e596
|
Provenance
The following attestation bundles were made for imbue_mngr_codex_usage-0.1.2-py3-none-any.whl:
Publisher:
publish.yml on imbue-ai/mngr
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
imbue_mngr_codex_usage-0.1.2-py3-none-any.whl -
Subject digest:
89e585d6218854dc587e16acbd487dc0ab0af3aafa3df50211210fd84b907e61 - Sigstore transparency entry: 1858308092
- Sigstore integration time:
-
Permalink:
imbue-ai/mngr@ed465f3fc2a0b4ad935d473b03bcffb205fac223 -
Branch / Tag:
refs/tags/v0.2.17 - Owner: https://github.com/imbue-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@ed465f3fc2a0b4ad935d473b03bcffb205fac223 -
Trigger Event:
push
-
Statement type: