cost-bubble 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -10,10 +10,10 @@ Cost Bubble sits as a lightweight native floating pill right beside your AI codi
10
10
 
11
11
  ## What It Shows
12
12
 
13
- - **Live session pulse** — Automatically follows your open chat (`▸`) in **Codex**, **Claude Code**, or **Antigravity Desktop**, plus up to two other chats with spend in the last 5 minutes.
14
- - **Context-window gauge** — Four cyan signal bars show how much of the model’s context window the latest request used. Purple dots underneath mark active subagents.
13
+ - **Live session pulse** — Automatically follows your open chat (`▸`) in **Codex**, **Claude Code**, or **Antigravity Desktop**, plus up to two other chats ranked by recent spend, weighted with a 150-second half-life.
14
+ - **Input token gauge** — Four bars show the latest request’s input size. Their color changes at 50k, 100k, 200k and 300k tokens. Purple dots underneath mark active subagents.
15
15
  - **Instant cost breakdown** — Hover or click any price for last-5-minute, hourly, daily, and lifetime spend, input/output and cache token splits, per-request rates, and subagent / auto-review totals.
16
- - **Recent sessions on hover** — Hover the pill to compare recent chats, switch between today and lifetime totals, sort by recency, cost, or activity, or click any title to switch chats.
16
+ - **Recent sessions on hover** — Hover the pill to compare recent chats, see today’s spend, sort by recent activity, daily cost or recency, or click any title to switch chats.
17
17
  - **Native & unobtrusive** — Built in Swift/AppKit. Drag or resize per app; hides automatically on home screens and ordinary non-Code Claude chats.
18
18
 
19
19
  ---
@@ -46,16 +46,16 @@ Cost Bubble uses macOS Accessibility to detect the active chat, align beside the
46
46
  | **Hover the signal bars** | Shows the latest request’s input tokens inline and its share of the model’s context window. **Click** to pin it open. |
47
47
  | **Hover a price** | Opens the full cost breakdown: 5-min / 1-hr / today / lifetime spend, token & cache splits, per-request rates, and subagent / auto-review totals. **Click** to pin it open. |
48
48
  | **Click a chat title** | Switches directly to that chat in the active desktop app. *(Antigravity leaves its picker open if multiple titles match.)* |
49
- | **Click the total** | Toggles row prices between **Today** and **Lifetime** estimates for the listed chats. |
50
- | **Click `⇅`** | Cycles row order between **Recent**, **Cost**, and **Activity** (last 5 minutes). |
51
- | **Drag, pinch, or `−` / `+`** | Moves or resizes the pill—each desktop app remembers its own position. Use **`≡`** for pin, auto-fit, 12-chat history, and reset options. |
49
+ | **Read the header total** | Shows today’s combined spend across this app’s chats. Lifetime estimates appear in each chat’s price breakdown. |
50
+ | **Click `⇅`** | Cycles row order between **Decay**, **Cost**, and **Recent**. |
51
+ | **Drag the left edge, pinch, or `−` / `+`** | Moves or resizes the pill—each desktop app remembers its own position. Use **`≡`** for pin, auto-fit, 12-chat history, and reset options. |
52
52
 
53
53
  ---
54
54
 
55
55
  ## How Estimates Work
56
56
 
57
- - **Direct local pricing:** Reads your local session logs directly and prices token usage against [LiteLLM](https://github.com/BerriAI/litellm)’s public pricing catalog (refreshed daily to a local cache, with a bundled offline fallback). A **`—`** means pricing is unavailable; a **`≥`** amount reflects the priced portion of a session with incomplete cost data. Estimates may differ from subscription invoices or API bills.
58
- - **Context-window bars:** Measures the latest request’s input tokens (including cached input) against the recorded context window (read from matching local generation records for Antigravity Desktop). Bars stay gray when the provider omits the limit; hover still shows the recorded token count.
57
+ - **Direct local pricing:** Reads your local session logs directly and prices token usage against [LiteLLM](https://github.com/BerriAI/litellm)’s public pricing catalog (refreshed daily to a local cache, with a bundled offline fallback). A **`—`** means pricing is unavailable; sessions with incomplete pricing show the sum of their priced requests. Estimates may differ from subscription invoices or API bills.
58
+ - **Input token bars:** Mint, cyan, yellow, orange and red mark progressively larger input sizes including cached input. Hover for the exact token count and the context-window share when recorded.
59
59
  - **Subagents & auto-reviewers:** Up to four purple dots underneath the signal bars indicate ordinary subagents. Automatic reviewers are separated into their own row in the cost breakdown and included in totals when priced.
60
60
  - **Per-request vs. per-turn rates:** Latest, average, and peak figures measure individual requests in Codex and Antigravity, or turns in Claude Code. If a refresh fails, the pill retains its last successful reading and continues aging spend out of the 5-minute window.
61
61
  - **Local-only readers:** All three apps share the same Swift UI, while lightweight Python readers normalize each app’s local storage with incremental file-identity caching. Custom `CODEX_HOME` and `CLAUDE_CONFIG_DIR` paths are preserved at install time.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cost-bubble",
3
- "version": "0.2.0",
3
+ "version": "0.3.0",
4
4
  "description": "A macOS cost HUD for Codex, Claude Code and Antigravity.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.2.0",
2
+ "version": "0.3.0",
3
3
  "teamID": "4YJ6CF8CRP",
4
- "sha256": "2630324e30a25fa5da2ba325aaa3e6ce9c13481924c9386f536ecda12c4bced8"
4
+ "sha256": "62cb0fa7352dfef1ac70cbfaae45fdfcc14ec1b60b929cbbaef86903092fa0e3"
5
5
  }