antigravity-usage 0.1.1 → 0.2.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 +86 -5
- package/dist/index.js +1501 -40
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,8 +1,28 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
<div align="center">
|
|
2
|
+
<img src="images/icon.png" alt="antigravity-usage logo" width="150" height="150">
|
|
3
|
+
<h1>antigravity-usage</h1>
|
|
4
|
+
</div>
|
|
5
|
+
|
|
6
|
+
<p align="center">
|
|
7
|
+
<a href="https://npmjs.com/package/antigravity-usage"><img src="https://img.shields.io/npm/v/antigravity-usage?color=yellow" alt="npm version" /></a>
|
|
8
|
+
<a href="https://packagephobia.com/result?p=antigravity-usage"><img src="https://packagephobia.com/badge?p=antigravity-usage" alt="install size" /></a>
|
|
9
|
+
<a href="https://www.npmjs.com/package/antigravity-usage"><img src="https://img.shields.io/npm/dt/antigravity-usage" alt="NPM Downloads" /></a>
|
|
10
|
+
<a href="LICENSE"><img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License: MIT" /></a>
|
|
11
|
+
<a href="https://nodejs.org"><img src="https://img.shields.io/badge/node-%3E%3D20-brightgreen.svg" alt="Node.js Version" /></a>
|
|
12
|
+
</p>
|
|
13
|
+
|
|
14
|
+
<p align="center">
|
|
3
15
|
A fast, lightweight, and powerful CLI tool to track your Antigravity model quota and usage. Works offline with your IDE or online with multiple Google accounts.
|
|
16
|
+
</p>
|
|
17
|
+
|
|
18
|
+
<p align="center">
|
|
19
|
+
<em>Inspired by <a href="https://github.com/ryoppippi/ccusage">ccusage</a></em>
|
|
20
|
+
</p>
|
|
21
|
+
|
|
22
|
+
<div align="center">
|
|
23
|
+
<img src="images/banner.png" alt="Antigravity Usage Screenshot">
|
|
24
|
+
</div>
|
|
4
25
|
|
|
5
|
-
Inspired by [ccusage](https://github.com/ryoppippi/ccusage).
|
|
6
26
|
|
|
7
27
|
## Quick Start (No Login Required) 🚀
|
|
8
28
|
|
|
@@ -39,8 +59,6 @@ antigravity-usage accounts add
|
|
|
39
59
|
antigravity-usage quota --all
|
|
40
60
|
```
|
|
41
61
|
|
|
42
|
-

|
|
43
|
-
|
|
44
62
|
---
|
|
45
63
|
|
|
46
64
|
## How It Works 🛠️
|
|
@@ -92,6 +110,7 @@ Alias for `quota`. Fetches and displays usage data.
|
|
|
92
110
|
antigravity-usage # Auto-detect (Local -> Cloud)
|
|
93
111
|
antigravity-usage --all # Fetch ALL accounts
|
|
94
112
|
antigravity-usage --method local # Force local IDE connection
|
|
113
|
+
antigravity-usage --method google # Force google IDE connection
|
|
95
114
|
antigravity-usage --json # Output JSON for scripts
|
|
96
115
|
```
|
|
97
116
|
|
|
@@ -111,6 +130,68 @@ Troubleshoot issues with your setup. Checks env vars, auth status, and local ser
|
|
|
111
130
|
### `antigravity-usage status`
|
|
112
131
|
Quickly check if your auth tokens are valid or expired.
|
|
113
132
|
|
|
133
|
+
### `antigravity-usage wakeup` 🚀
|
|
134
|
+
**Never waste quota again.** Automatically wake up your AI models at strategic times to maximize your daily limits.
|
|
135
|
+
|
|
136
|
+
```bash
|
|
137
|
+
antigravity-usage wakeup config # Interactive setup (takes 30 seconds)
|
|
138
|
+
antigravity-usage wakeup install # Install to native system cron
|
|
139
|
+
antigravity-usage wakeup status # Check configuration & next run
|
|
140
|
+
antigravity-usage wakeup test # Test trigger manually
|
|
141
|
+
antigravity-usage wakeup history # View trigger history
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
**Why This Matters:**
|
|
145
|
+
Your Antigravity quota resets every ~5 hours, but if you don't use it, you lose it. The wakeup feature ensures you **automatically trigger** both Claude and Gemini models to keep your quota flowing.
|
|
146
|
+
|
|
147
|
+
#### 🎯 Intelligent Model Selection
|
|
148
|
+
Zero configuration needed. Automatically wakes up:
|
|
149
|
+
- **`claude-sonnet-4-5`** → Triggers the entire Claude family
|
|
150
|
+
- **`gemini-3-flash`** → Triggers the entire Gemini family
|
|
151
|
+
|
|
152
|
+
Both models combined ensure comprehensive coverage and optimal quota utilization across all available AI models.
|
|
153
|
+
|
|
154
|
+
#### ⚡️ Two Powerful Trigger Modes
|
|
155
|
+
|
|
156
|
+
**1. Schedule-Based** (Native Cron Integration)
|
|
157
|
+
Runs locally on your machine with zero dependencies:
|
|
158
|
+
- **Interval Mode**: Every N hours (e.g., every 6 hours)
|
|
159
|
+
- **Daily Mode**: At specific times (e.g., 9 AM, 5 PM)
|
|
160
|
+
- **Custom Mode**: Advanced cron expressions for power users
|
|
161
|
+
|
|
162
|
+
```bash
|
|
163
|
+
antigravity-usage wakeup install
|
|
164
|
+
# ✅ Installs to your system's native crontab
|
|
165
|
+
# ✅ Runs even when terminal/antigravity is closed
|
|
166
|
+
# ✅ Persists across reboots
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
**2. Smart Quota-Reset Detection** (Zero-Waste Mode)
|
|
170
|
+
The most intelligent trigger mode. Automatically detects when:
|
|
171
|
+
- Quota is at **100%** (unused)
|
|
172
|
+
- Reset time is **~5 hours away** (just reset)
|
|
173
|
+
- No cooldown conflicts
|
|
174
|
+
|
|
175
|
+
When triggered, it wakes up **ALL** your accounts simultaneously, ensuring none of your quota goes to waste.
|
|
176
|
+
|
|
177
|
+
#### 🛡️ Built-in Safety Features
|
|
178
|
+
- **Cooldown Protection**: Prevents duplicate triggers (1-hour default)
|
|
179
|
+
- **Multi-Account Support**: Trigger for specific accounts or all at once
|
|
180
|
+
- **Detailed History**: Track every trigger with timestamps and results
|
|
181
|
+
- **Graceful Failures**: Automatic retry logic with exponential backoff
|
|
182
|
+
- **Token Efficiency**: Minimal output tokens (just 1 token per request)
|
|
183
|
+
|
|
184
|
+
#### 📊 Real-Time Monitoring
|
|
185
|
+
```bash
|
|
186
|
+
antigravity-usage wakeup status
|
|
187
|
+
```
|
|
188
|
+
Shows:
|
|
189
|
+
- ✅ Enabled/disabled status
|
|
190
|
+
- 📅 Next scheduled run time
|
|
191
|
+
- 🎯 Selected models and accounts
|
|
192
|
+
- 📝 Last trigger result
|
|
193
|
+
- ⚙️ Cron installation status
|
|
194
|
+
|
|
114
195
|
## Configuration
|
|
115
196
|
Data is stored in your system's standard config location:
|
|
116
197
|
- **macOS**: `~/Library/Application Support/antigravity-usage/`
|