squeezr-ai 1.81.2 → 1.99.2

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 (69) hide show
  1. package/bin/squeezr.js +82 -1
  2. package/dist/__tests__/bench.test.d.ts +1 -0
  3. package/dist/__tests__/bench.test.js +55 -0
  4. package/dist/__tests__/cacheAligner.test.d.ts +1 -0
  5. package/dist/__tests__/cacheAligner.test.js +75 -0
  6. package/dist/__tests__/codeStructure.test.d.ts +1 -0
  7. package/dist/__tests__/codeStructure.test.js +74 -0
  8. package/dist/__tests__/compressor.test.js +5 -1
  9. package/dist/__tests__/contentRouter.test.d.ts +1 -0
  10. package/dist/__tests__/contentRouter.test.js +76 -0
  11. package/dist/__tests__/controlEndpointGuard.test.d.ts +1 -0
  12. package/dist/__tests__/controlEndpointGuard.test.js +61 -0
  13. package/dist/__tests__/deterministic.test.js +13 -0
  14. package/dist/__tests__/doctor.test.d.ts +1 -0
  15. package/dist/__tests__/doctor.test.js +86 -0
  16. package/dist/__tests__/jsonCrush.test.d.ts +1 -0
  17. package/dist/__tests__/jsonCrush.test.js +168 -0
  18. package/dist/__tests__/learn.test.d.ts +1 -0
  19. package/dist/__tests__/learn.test.js +159 -0
  20. package/dist/__tests__/outputSavings.test.d.ts +1 -0
  21. package/dist/__tests__/outputSavings.test.js +49 -0
  22. package/dist/__tests__/outputShaper.test.d.ts +1 -0
  23. package/dist/__tests__/outputShaper.test.js +216 -0
  24. package/dist/__tests__/relevance.test.d.ts +1 -0
  25. package/dist/__tests__/relevance.test.js +66 -0
  26. package/dist/__tests__/secureKeyFile.test.d.ts +1 -0
  27. package/dist/__tests__/secureKeyFile.test.js +27 -0
  28. package/dist/__tests__/serverBinding.test.d.ts +1 -0
  29. package/dist/__tests__/serverBinding.test.js +18 -0
  30. package/dist/__tests__/statsOutput.test.d.ts +1 -0
  31. package/dist/__tests__/statsOutput.test.js +46 -0
  32. package/dist/__tests__/textCrusher.test.d.ts +1 -0
  33. package/dist/__tests__/textCrusher.test.js +133 -0
  34. package/dist/bench.d.ts +45 -0
  35. package/dist/bench.js +114 -0
  36. package/dist/cacheAligner.d.ts +34 -0
  37. package/dist/cacheAligner.js +73 -0
  38. package/dist/codexMitm.d.ts +1 -0
  39. package/dist/codexMitm.js +26 -2
  40. package/dist/compressor.js +42 -4
  41. package/dist/config.d.ts +6 -0
  42. package/dist/config.js +25 -0
  43. package/dist/contentRouter.d.ts +30 -0
  44. package/dist/contentRouter.js +112 -0
  45. package/dist/dashboard.d.ts +1 -1
  46. package/dist/dashboard.js +26 -7
  47. package/dist/deterministic.d.ts +4 -1
  48. package/dist/deterministic.js +43 -10
  49. package/dist/doctor.d.ts +38 -0
  50. package/dist/doctor.js +113 -0
  51. package/dist/index.js +4 -1
  52. package/dist/jsonCrush.d.ts +34 -0
  53. package/dist/jsonCrush.js +177 -0
  54. package/dist/learn.d.ts +65 -0
  55. package/dist/learn.js +244 -0
  56. package/dist/outputSavings.d.ts +20 -0
  57. package/dist/outputSavings.js +52 -0
  58. package/dist/outputShaper.d.ts +71 -0
  59. package/dist/outputShaper.js +155 -0
  60. package/dist/relevance.d.ts +27 -0
  61. package/dist/relevance.js +78 -0
  62. package/dist/server.js +106 -11
  63. package/dist/stats.d.ts +17 -0
  64. package/dist/stats.js +55 -0
  65. package/dist/systemPrompt.js +3 -2
  66. package/dist/textCrusher.d.ts +35 -0
  67. package/dist/textCrusher.js +160 -0
  68. package/package.json +69 -69
  69. package/squeezr.toml +15 -1
package/squeezr.toml CHANGED
@@ -11,7 +11,12 @@ disabled = false
11
11
  # API key + backend = "gpt-mini" / "gemini-flash" / "local".
12
12
  ai_compression = false
13
13
  compress_system_prompt = true # only runs when ai_compression = true (it makes a Haiku call)
14
- compress_conversation = true # deterministic clean on old user/assistant messages + tool_use inputs (pure regex, no AI)
14
+ compress_conversation = true # deterministic clean on OLD user/assistant PROSE (pure regex, no AI)
15
+ # compress_tool_inputs = false # DEFAULT FALSE. Lossy-clean OLD Write/Edit/Bash tool INPUTS.
16
+ # OFF porque corrompía código en disco (v1.82.0): Write.content se
17
+ # escribe verbatim y Edit.old_string debe casar byte a byte. No lo
18
+ # enciendas salvo que aceptes ese riesgo; el bloat de turnos viejos
19
+ # ya lo recupera stale_turns de forma segura.
15
20
  keep_recent_assistant = 3 # leave last N assistant turns untouched
16
21
  assistant_threshold = 300 # min chars before applying prose cleanup
17
22
  stale_turns = true # collapse old assistant turns when conversation > threshold (default 40)
@@ -31,6 +36,15 @@ tool_desc_expand = true # store full spec in expand store — Claude ll
31
36
  # Per-command: add "# squeezr:skip" anywhere in a Bash command to skip that result:
32
37
  # git diff HEAD~3 # squeezr:skip
33
38
 
39
+ [output]
40
+ # Output-side token reduction — trims what the model WRITES BACK (output costs
41
+ # ~5x input on Opus). DEFAULT OFF (opt-in). Enable here or with SQUEEZR_OUTPUT_SHAPER=1.
42
+ enabled = false
43
+ verbosity_steering = true # append a byte-stable "be terse" block to the system tail (cache-safe)
44
+ level = 2 # 1 (light) .. 4 (caveman). 2 = no ceremony + don't restate context
45
+ effort_routing = true # on mechanical turns (clean tool_result) lower an EXISTING thinking budget
46
+ mechanical_thinking_floor = 1024 # clamp thinking.budget_tokens down to this on mechanical turns
47
+
34
48
  [cache]
35
49
  enabled = true
36
50
  max_entries = 1000 # LRU cap for cached compressions