Repository navigation
Include Hermes Agent’s usage in the Usage tab, with per-model breakdowns #21034
Ouna-the-Dataweaver
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
I’d like T3 Code’s Usage tab to include token usage from a local Hermes Agent installation, including activity outside T3 - Telegram bot, CLI, scheduled jobs, and background tasks.
I use Hermes with some of the same subscriptions I use through T3, including ChatGPT and Grok. I’m interested in seeing which models consume the tokens and their estimated API-equivalent cost, consistent with the existing Usage page. This request is about reading Hermes’s usage history; it doesn’t require running Hermes through T3 (though it still needs connecting it as provider, since there's no separate "add usage source" path).
What data is available
I inspected my installed Hermes’s SQLite databases read-only. The
session_model_usagetable contains populated records with:The default Hermes home and individual profiles have separate databases. This looks sufficient for historical totals broken down by model, including auxiliary work.
The main design question: time ranges
In my installation, these records accumulate totals per session/model/task. They don’t preserve a timestamped entry for each API call. Some span several days; one spans roughly nine days. Individual message token counts were also empty.
That means we can report accumulated totals, but cannot accurately assign all historical usage to individual days or hours. A record crossing the boundary of “last 7 days” also can’t be split accurately. Assigning the whole total to its first or last timestamp would distort the chart.
Proposed implementation
Calculate total usage in session, then average it over affected days. For sessions fully fitting within time frame in usage tab, this gives exact usage. For long sessions breaking through boundaries, this gives reasonable average, since long sessions would have somewhat distributed compute over time, at least this is the case for my hermes usage.
Example and showcase
I did some testing and drafted this without ACP route, just direct Usage tab integration:
Scope
From my understanding, this does not require promoting Hermes into a fully supported provider. Existing support through ACP is sufficient, with, on T3code recognizing new provider as Hermes, it invoking the reading usage for hermes path. I'm not sure how exactly this should be done, but if the feature gets green light I can open PR with some experiments for this, since I already have the usage pulling working.
All reactions