jasper-context-compactor 0.3.2 → 0.3.3

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.
Files changed (2) hide show
  1. package/cli.js +7 -2
  2. package/package.json +1 -1
package/cli.js CHANGED
@@ -204,6 +204,11 @@ async function setup() {
204
204
  if (checkConfig.toLowerCase() === 'y' || checkConfig.toLowerCase() === 'yes') {
205
205
  detectedInfo = await detectModelContextWindow(config);
206
206
 
207
+ // Debug: show what we found
208
+ if (process.env.DEBUG) {
209
+ console.log(' [DEBUG] detectedInfo:', JSON.stringify(detectedInfo, null, 2));
210
+ }
211
+
207
212
  if (detectedInfo && detectedInfo.tokens) {
208
213
  console.log('');
209
214
  console.log(` ✓ Detected model: ${detectedInfo.model}`);
@@ -235,8 +240,8 @@ async function setup() {
235
240
  }
236
241
  }
237
242
 
238
- // Manual entry if no context window was detected or user declined
239
- if (!detectedInfo?.tokens || maxTokens === 16000) {
243
+ // Manual entry only if we couldn't detect context window at all
244
+ if (!detectedInfo?.tokens) {
240
245
  console.log('');
241
246
  console.log(' Could not auto-detect context window from your config.');
242
247
  console.log('');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jasper-context-compactor",
3
- "version": "0.3.2",
3
+ "version": "0.3.3",
4
4
  "description": "Context compaction plugin for OpenClaw - works with local models (MLX, llama.cpp) that don't report token limits",
5
5
  "main": "index.ts",
6
6
  "bin": {