billion-context 0.1.2 → 0.1.4
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 +31 -1
- package/dist/index.js +294 -148
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -99,6 +99,37 @@ Verbose mode logs every `processTurn` (tag counts, token usage), the nudge
|
|
|
99
99
|
decision (growth/usage/pendingT1/shouldInject), client headers, and SSE
|
|
100
100
|
rewrites.
|
|
101
101
|
|
|
102
|
+
### Log file
|
|
103
|
+
|
|
104
|
+
All logs are **tee'd to a file by default**: `~/.local/state/billion-context/bili.log`
|
|
105
|
+
(XDG state dir). They also still print to stderr so a foreground `bili start`
|
|
106
|
+
shows them in the terminal.
|
|
107
|
+
|
|
108
|
+
```bash
|
|
109
|
+
bili start # logs → ~/.local/state/billion-context/bili.log + terminal
|
|
110
|
+
bili update # (see below)
|
|
111
|
+
# Config: "logFile": "/custom/path.log"
|
|
112
|
+
# Env: ACP_LOG_FILE=/custom/path.log (or ACP_LOG_FILE=off to disable the file)
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
The file auto-rotates at 10 MB (renamed to `bili.log.old`). Cache-hit stats
|
|
116
|
+
per request are logged as `[acp-usage] round N input=X cached=Y (cache hit Z%)`
|
|
117
|
+
so you can measure prefix-cache health directly from the log.
|
|
118
|
+
|
|
119
|
+
### Self-update
|
|
120
|
+
|
|
121
|
+
The proxy checks npm for a newer version on startup and every 3 minutes. When a
|
|
122
|
+
newer version is found it installs it globally (`npm install -g`) and logs a
|
|
123
|
+
notice — **restart `bili` to pick up the new version**.
|
|
124
|
+
|
|
125
|
+
```bash
|
|
126
|
+
bili update # check & install now (manual, bypasses 3min throttle)
|
|
127
|
+
bili --no-auto-update # disable self-update for this run
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
Disable permanently via config (`"autoUpdate": false`) or env
|
|
131
|
+
(`ACP_AUTO_UPDATE=0`).
|
|
132
|
+
|
|
102
133
|
## Configuration
|
|
103
134
|
|
|
104
135
|
Configuration is read from a JSON file with env-var overrides. Priority:
|
|
@@ -143,7 +174,6 @@ The config file is a single JSON object. Example:
|
|
|
143
174
|
| `debug` | `false` | Verbose logging (same as `ACP_DEBUG=1`) |
|
|
144
175
|
| `passthrough` | `false` | Forward without compression (same as `ACP_PASSTHROUGH=1`) |
|
|
145
176
|
| `providers` | *(none)* | Provider routes — see below |
|
|
146
|
-
| `condense` | *(see defaults)* | Tool-result condensing: `{ enabled, keepRecentToolResults, minCharsToCondense, maxKeptChars }` |
|
|
147
177
|
| `compress` | *(see defaults)* | `{ injectTool, injectNudge }` |
|
|
148
178
|
|
|
149
179
|
### Providers (URL routing + per-model context)
|