@aiready/context-analyzer 0.21.17 → 0.21.22

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @aiready/context-analyzer@0.21.17 build /Users/pengcao/projects/aiready/packages/context-analyzer
2
+ > @aiready/context-analyzer@0.21.22 build /Users/pengcao/projects/aiready/packages/context-analyzer
3
3
  > tsup src/index.ts src/cli.ts --format cjs,esm --dts
4
4
 
5
5
  CLI Building entry: src/cli.ts, src/index.ts
@@ -8,17 +8,17 @@ CLI tsup v8.5.1
8
8
  CLI Target: es2020
9
9
  CJS Build start
10
10
  ESM Build start
11
- ESM dist/chunk-64U3PNO3.mjs 2.65 KB
11
+ CJS dist/cli.js 69.82 KB
12
+ CJS dist/index.js 83.72 KB
13
+ CJS ⚡️ Build success in 495ms
12
14
  ESM dist/index.mjs 12.40 KB
13
15
  ESM dist/python-context-3GZKN3LR.mjs 4.47 KB
14
- ESM dist/cli.mjs 4.38 KB
15
16
  ESM dist/chunk-CBWM3EK5.mjs 60.62 KB
16
- ESM ⚡️ Build success in 604ms
17
- CJS dist/cli.js 69.82 KB
18
- CJS dist/index.js 83.72 KB
19
- CJS ⚡️ Build success in 604ms
17
+ ESM dist/chunk-64U3PNO3.mjs 2.65 KB
18
+ ESM dist/cli.mjs 4.38 KB
19
+ ESM ⚡️ Build success in 504ms
20
20
  DTS Build start
21
- DTS ⚡️ Build success in 11190ms
21
+ DTS ⚡️ Build success in 13528ms
22
22
  DTS dist/cli.d.ts 20.00 B
23
23
  DTS dist/index.d.ts 25.70 KB
24
24
  DTS dist/cli.d.mts 20.00 B
@@ -1,41 +1,41 @@
1
1
 
2
- > @aiready/context-analyzer@0.21.16 test /Users/pengcao/projects/aiready/packages/context-analyzer
2
+ > @aiready/context-analyzer@0.21.18 test /Users/pengcao/projects/aiready/packages/context-analyzer
3
3
  > vitest run
4
4
 
5
5
 
6
6
   RUN  v4.0.18 /Users/pengcao/projects/aiready/packages/context-analyzer
7
7
 
8
- ✓ src/__tests__/scoring.test.ts (15 tests) 8ms
9
8
  Sourcemap for "/Users/pengcao/projects/aiready/packages/context-analyzer/dist/semantic-analysis.js" points to missing source files
10
- ✓ dist/__tests__/fragmentation-coupling.test.js (2 tests) 21ms
11
- ✓ src/__tests__/remediation.test.ts (6 tests) 2ms
12
- ✓ dist/__tests__/analyzer.test.js (14 tests) 33ms
13
- ✓ dist/__tests__/auto-detection.test.js (8 tests) 22ms
14
- ✓ dist/__tests__/file-classification.test.js (63 tests) 6ms
15
- ✓ dist/__tests__/contract.test.js (1 test) 103ms
16
- ✓ src/__tests__/contract.test.ts (1 test) 29ms
17
- ✓ src/__tests__/analyzer.test.ts (14 tests) 41ms
18
- ✓ src/__tests__/fragmentation-coupling.test.ts (2 tests) 25ms
19
- ✓ src/__tests__/file-classification.test.ts (63 tests) 23ms
20
- ✓ src/__tests__/auto-detection.test.ts (8 tests) 53ms
9
+ ✓ dist/__tests__/cluster-detector.test.js (3 tests) 5ms
10
+ ✓ dist/__tests__/contract.test.js (1 test) 146ms
11
+ ✓ dist/__tests__/fragmentation-coupling.test.js (2 tests) 25ms
12
+ ✓ dist/__tests__/auto-detection.test.js (8 tests) 139ms
13
+ ✓ dist/__tests__/analyzer.test.js (14 tests) 186ms
14
+ ✓ src/__tests__/structural-cohesion.test.ts (4 tests) 2ms
15
+ ✓ src/__tests__/fragmentation-log.test.ts (3 tests) 2ms
16
+ ✓ src/__tests__/fragmentation-coupling.test.ts (2 tests) 37ms
17
+ ✓ src/__tests__/contract.test.ts (1 test) 37ms
18
+ ✓ src/__tests__/auto-detection.test.ts (8 tests) 96ms
19
+ ✓ src/__tests__/analyzer.test.ts (14 tests) 162ms
20
+ ✓ dist/__tests__/file-classification.test.js (63 tests) 9ms
21
+ ✓ src/__tests__/scoring.test.ts (15 tests) 4ms
22
+ ✓ src/__tests__/file-classification.test.ts (63 tests) 7ms
23
+ ✓ dist/__tests__/provider.test.js (2 tests) 11ms
24
+ ✓ src/__tests__/provider.test.ts (2 tests) 5ms
21
25
  ✓ dist/__tests__/remediation.test.js (6 tests) 5ms
22
- ✓ src/__tests__/provider.test.ts (2 tests) 6ms
23
- ✓ dist/__tests__/scoring.test.js (15 tests) 4ms
24
26
  ✓ src/__tests__/cluster-detector.test.ts (3 tests) 3ms
25
- ✓ src/__tests__/enhanced-cohesion.test.ts (6 tests) 2ms
26
- ✓ dist/__tests__/provider.test.js (2 tests) 4ms
27
- ✓ src/__tests__/boilerplate-barrel.test.ts (7 tests) 51ms
27
+ ✓ dist/__tests__/scoring.test.js (15 tests) 4ms
28
28
  ✓ dist/__tests__/enhanced-cohesion.test.js (6 tests) 2ms
29
- ✓ dist/__tests__/cluster-detector.test.js (3 tests) 2ms
30
- ✓ src/__tests__/fragmentation-advanced.test.ts (3 tests) 4ms
31
- ✓ src/__tests__/structural-cohesion.test.ts (4 tests) 4ms
32
- ✓ dist/__tests__/structural-cohesion.test.js (4 tests) 2ms
33
- ✓ dist/__tests__/fragmentation-log.test.js (3 tests) 3ms
29
+ ✓ src/__tests__/remediation.test.ts (6 tests) 2ms
30
+ ✓ src/__tests__/fragmentation-advanced.test.ts (3 tests) 2ms
31
+ ✓ src/__tests__/enhanced-cohesion.test.ts (6 tests) 4ms
32
+ ✓ src/__tests__/boilerplate-barrel.test.ts (7 tests) 5ms
34
33
  ✓ dist/__tests__/fragmentation-advanced.test.js (3 tests) 2ms
35
- ✓ src/__tests__/fragmentation-log.test.ts (3 tests) 2ms
34
+ ✓ dist/__tests__/fragmentation-log.test.js (3 tests) 3ms
35
+ ✓ dist/__tests__/structural-cohesion.test.js (4 tests) 3ms
36
36
 
37
37
   Test Files  27 passed (27)
38
38
   Tests  267 passed (267)
39
-  Start at  10:44:36
40
-  Duration  4.33s (transform 6.06s, setup 0ms, import 31.48s, tests 463ms, environment 9ms)
39
+  Start at  12:24:37
40
+  Duration  7.87s (transform 17.15s, setup 0ms, import 59.83s, tests 906ms, environment 19ms)
41
41
 
package/dist/index.js CHANGED
@@ -2069,22 +2069,22 @@ async function getSmartDefaults(directory, userOptions) {
2069
2069
  let minCohesion;
2070
2070
  let maxFragmentation;
2071
2071
  if (estimatedBlocks < 100) {
2072
- maxDepth = 4;
2072
+ maxDepth = 5;
2073
2073
  maxContextBudget = 8e3;
2074
2074
  minCohesion = 0.5;
2075
2075
  maxFragmentation = 0.5;
2076
2076
  } else if (estimatedBlocks < 500) {
2077
- maxDepth = 5;
2077
+ maxDepth = 6;
2078
2078
  maxContextBudget = 15e3;
2079
2079
  minCohesion = 0.45;
2080
2080
  maxFragmentation = 0.6;
2081
2081
  } else if (estimatedBlocks < 2e3) {
2082
- maxDepth = 7;
2082
+ maxDepth = 8;
2083
2083
  maxContextBudget = 25e3;
2084
2084
  minCohesion = 0.4;
2085
2085
  maxFragmentation = 0.7;
2086
2086
  } else {
2087
- maxDepth = 10;
2087
+ maxDepth = 12;
2088
2088
  maxContextBudget = 4e4;
2089
2089
  minCohesion = 0.35;
2090
2090
  maxFragmentation = 0.8;
package/dist/index.mjs CHANGED
@@ -311,22 +311,22 @@ async function getSmartDefaults(directory, userOptions) {
311
311
  let minCohesion;
312
312
  let maxFragmentation;
313
313
  if (estimatedBlocks < 100) {
314
- maxDepth = 4;
314
+ maxDepth = 5;
315
315
  maxContextBudget = 8e3;
316
316
  minCohesion = 0.5;
317
317
  maxFragmentation = 0.5;
318
318
  } else if (estimatedBlocks < 500) {
319
- maxDepth = 5;
319
+ maxDepth = 6;
320
320
  maxContextBudget = 15e3;
321
321
  minCohesion = 0.45;
322
322
  maxFragmentation = 0.6;
323
323
  } else if (estimatedBlocks < 2e3) {
324
- maxDepth = 7;
324
+ maxDepth = 8;
325
325
  maxContextBudget = 25e3;
326
326
  minCohesion = 0.4;
327
327
  maxFragmentation = 0.7;
328
328
  } else {
329
- maxDepth = 10;
329
+ maxDepth = 12;
330
330
  maxContextBudget = 4e4;
331
331
  minCohesion = 0.35;
332
332
  maxFragmentation = 0.8;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aiready/context-analyzer",
3
- "version": "0.21.17",
3
+ "version": "0.21.22",
4
4
  "description": "AI context window cost analysis - detect fragmented code, deep import chains, and expensive context budgets",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -49,7 +49,7 @@
49
49
  "commander": "^14.0.0",
50
50
  "chalk": "^5.3.0",
51
51
  "prompts": "^2.4.2",
52
- "@aiready/core": "0.23.14"
52
+ "@aiready/core": "0.23.19"
53
53
  },
54
54
  "devDependencies": {
55
55
  "@types/node": "^24.0.0",
package/src/defaults.ts CHANGED
@@ -27,22 +27,22 @@ export async function getSmartDefaults(
27
27
  let maxFragmentation: number;
28
28
 
29
29
  if (estimatedBlocks < 100) {
30
- maxDepth = 4;
30
+ maxDepth = 5;
31
31
  maxContextBudget = 8000;
32
32
  minCohesion = 0.5;
33
33
  maxFragmentation = 0.5;
34
34
  } else if (estimatedBlocks < 500) {
35
- maxDepth = 5;
35
+ maxDepth = 6;
36
36
  maxContextBudget = 15000;
37
37
  minCohesion = 0.45;
38
38
  maxFragmentation = 0.6;
39
39
  } else if (estimatedBlocks < 2000) {
40
- maxDepth = 7;
40
+ maxDepth = 8;
41
41
  maxContextBudget = 25000;
42
42
  minCohesion = 0.4;
43
43
  maxFragmentation = 0.7;
44
44
  } else {
45
- maxDepth = 10;
45
+ maxDepth = 12;
46
46
  maxContextBudget = 40000;
47
47
  minCohesion = 0.35;
48
48
  maxFragmentation = 0.8;