lens-engine 2.0.1 → 2.1.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.
@@ -4,7 +4,7 @@
4
4
  <meta charset="UTF-8" />
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
6
  <title>LENS Dashboard</title>
7
- <script type="module" crossorigin src="/assets/index-x1mtAEvB.js"></script>
7
+ <script type="module" crossorigin src="/assets/index-CzRbHqXG.js"></script>
8
8
  <link rel="stylesheet" crossorigin href="/assets/index-xIwKSMlF.css">
9
9
  </head>
10
10
  <body>
@@ -0,0 +1 @@
1
+ ALTER TABLE `file_metadata` ADD `namespaces` text DEFAULT '[]';
@@ -0,0 +1,586 @@
1
+ {
2
+ "version": "6",
3
+ "dialect": "sqlite",
4
+ "id": "5a197db2-43fd-496d-bd62-3e0fe61a793d",
5
+ "prevId": "36e4b5d2-4369-4c78-9f50-7be449407d05",
6
+ "tables": {
7
+ "chunks": {
8
+ "name": "chunks",
9
+ "columns": {
10
+ "id": {
11
+ "name": "id",
12
+ "type": "text",
13
+ "primaryKey": true,
14
+ "notNull": true,
15
+ "autoincrement": false
16
+ },
17
+ "repo_id": {
18
+ "name": "repo_id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true,
22
+ "autoincrement": false
23
+ },
24
+ "path": {
25
+ "name": "path",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true,
29
+ "autoincrement": false
30
+ },
31
+ "chunk_index": {
32
+ "name": "chunk_index",
33
+ "type": "integer",
34
+ "primaryKey": false,
35
+ "notNull": true,
36
+ "autoincrement": false
37
+ },
38
+ "start_line": {
39
+ "name": "start_line",
40
+ "type": "integer",
41
+ "primaryKey": false,
42
+ "notNull": true,
43
+ "autoincrement": false
44
+ },
45
+ "end_line": {
46
+ "name": "end_line",
47
+ "type": "integer",
48
+ "primaryKey": false,
49
+ "notNull": true,
50
+ "autoincrement": false
51
+ },
52
+ "content": {
53
+ "name": "content",
54
+ "type": "text",
55
+ "primaryKey": false,
56
+ "notNull": true,
57
+ "autoincrement": false
58
+ },
59
+ "chunk_hash": {
60
+ "name": "chunk_hash",
61
+ "type": "text",
62
+ "primaryKey": false,
63
+ "notNull": true,
64
+ "autoincrement": false
65
+ },
66
+ "last_seen_commit": {
67
+ "name": "last_seen_commit",
68
+ "type": "text",
69
+ "primaryKey": false,
70
+ "notNull": true,
71
+ "autoincrement": false
72
+ },
73
+ "language": {
74
+ "name": "language",
75
+ "type": "text",
76
+ "primaryKey": false,
77
+ "notNull": false,
78
+ "autoincrement": false
79
+ }
80
+ },
81
+ "indexes": {
82
+ "idx_chunks_unique": {
83
+ "name": "idx_chunks_unique",
84
+ "columns": [
85
+ "repo_id",
86
+ "path",
87
+ "chunk_index",
88
+ "chunk_hash"
89
+ ],
90
+ "isUnique": true
91
+ },
92
+ "idx_chunks_repo_path": {
93
+ "name": "idx_chunks_repo_path",
94
+ "columns": [
95
+ "repo_id",
96
+ "path"
97
+ ],
98
+ "isUnique": false
99
+ }
100
+ },
101
+ "foreignKeys": {
102
+ "chunks_repo_id_repos_id_fk": {
103
+ "name": "chunks_repo_id_repos_id_fk",
104
+ "tableFrom": "chunks",
105
+ "tableTo": "repos",
106
+ "columnsFrom": [
107
+ "repo_id"
108
+ ],
109
+ "columnsTo": [
110
+ "id"
111
+ ],
112
+ "onDelete": "cascade",
113
+ "onUpdate": "no action"
114
+ }
115
+ },
116
+ "compositePrimaryKeys": {},
117
+ "uniqueConstraints": {},
118
+ "checkConstraints": {}
119
+ },
120
+ "file_cochanges": {
121
+ "name": "file_cochanges",
122
+ "columns": {
123
+ "id": {
124
+ "name": "id",
125
+ "type": "text",
126
+ "primaryKey": true,
127
+ "notNull": true,
128
+ "autoincrement": false
129
+ },
130
+ "repo_id": {
131
+ "name": "repo_id",
132
+ "type": "text",
133
+ "primaryKey": false,
134
+ "notNull": true,
135
+ "autoincrement": false
136
+ },
137
+ "path_a": {
138
+ "name": "path_a",
139
+ "type": "text",
140
+ "primaryKey": false,
141
+ "notNull": true,
142
+ "autoincrement": false
143
+ },
144
+ "path_b": {
145
+ "name": "path_b",
146
+ "type": "text",
147
+ "primaryKey": false,
148
+ "notNull": true,
149
+ "autoincrement": false
150
+ },
151
+ "cochange_count": {
152
+ "name": "cochange_count",
153
+ "type": "integer",
154
+ "primaryKey": false,
155
+ "notNull": true,
156
+ "autoincrement": false,
157
+ "default": 1
158
+ }
159
+ },
160
+ "indexes": {
161
+ "idx_file_cochanges_unique": {
162
+ "name": "idx_file_cochanges_unique",
163
+ "columns": [
164
+ "repo_id",
165
+ "path_a",
166
+ "path_b"
167
+ ],
168
+ "isUnique": true
169
+ },
170
+ "idx_cochanges_lookup": {
171
+ "name": "idx_cochanges_lookup",
172
+ "columns": [
173
+ "repo_id",
174
+ "path_a"
175
+ ],
176
+ "isUnique": false
177
+ }
178
+ },
179
+ "foreignKeys": {
180
+ "file_cochanges_repo_id_repos_id_fk": {
181
+ "name": "file_cochanges_repo_id_repos_id_fk",
182
+ "tableFrom": "file_cochanges",
183
+ "tableTo": "repos",
184
+ "columnsFrom": [
185
+ "repo_id"
186
+ ],
187
+ "columnsTo": [
188
+ "id"
189
+ ],
190
+ "onDelete": "cascade",
191
+ "onUpdate": "no action"
192
+ }
193
+ },
194
+ "compositePrimaryKeys": {},
195
+ "uniqueConstraints": {},
196
+ "checkConstraints": {}
197
+ },
198
+ "file_imports": {
199
+ "name": "file_imports",
200
+ "columns": {
201
+ "id": {
202
+ "name": "id",
203
+ "type": "text",
204
+ "primaryKey": true,
205
+ "notNull": true,
206
+ "autoincrement": false
207
+ },
208
+ "repo_id": {
209
+ "name": "repo_id",
210
+ "type": "text",
211
+ "primaryKey": false,
212
+ "notNull": true,
213
+ "autoincrement": false
214
+ },
215
+ "source_path": {
216
+ "name": "source_path",
217
+ "type": "text",
218
+ "primaryKey": false,
219
+ "notNull": true,
220
+ "autoincrement": false
221
+ },
222
+ "target_path": {
223
+ "name": "target_path",
224
+ "type": "text",
225
+ "primaryKey": false,
226
+ "notNull": true,
227
+ "autoincrement": false
228
+ }
229
+ },
230
+ "indexes": {
231
+ "idx_file_imports_unique": {
232
+ "name": "idx_file_imports_unique",
233
+ "columns": [
234
+ "repo_id",
235
+ "source_path",
236
+ "target_path"
237
+ ],
238
+ "isUnique": true
239
+ },
240
+ "idx_file_imports_target": {
241
+ "name": "idx_file_imports_target",
242
+ "columns": [
243
+ "repo_id",
244
+ "target_path"
245
+ ],
246
+ "isUnique": false
247
+ },
248
+ "idx_file_imports_source": {
249
+ "name": "idx_file_imports_source",
250
+ "columns": [
251
+ "repo_id",
252
+ "source_path"
253
+ ],
254
+ "isUnique": false
255
+ }
256
+ },
257
+ "foreignKeys": {
258
+ "file_imports_repo_id_repos_id_fk": {
259
+ "name": "file_imports_repo_id_repos_id_fk",
260
+ "tableFrom": "file_imports",
261
+ "tableTo": "repos",
262
+ "columnsFrom": [
263
+ "repo_id"
264
+ ],
265
+ "columnsTo": [
266
+ "id"
267
+ ],
268
+ "onDelete": "cascade",
269
+ "onUpdate": "no action"
270
+ }
271
+ },
272
+ "compositePrimaryKeys": {},
273
+ "uniqueConstraints": {},
274
+ "checkConstraints": {}
275
+ },
276
+ "file_metadata": {
277
+ "name": "file_metadata",
278
+ "columns": {
279
+ "id": {
280
+ "name": "id",
281
+ "type": "text",
282
+ "primaryKey": true,
283
+ "notNull": true,
284
+ "autoincrement": false
285
+ },
286
+ "repo_id": {
287
+ "name": "repo_id",
288
+ "type": "text",
289
+ "primaryKey": false,
290
+ "notNull": true,
291
+ "autoincrement": false
292
+ },
293
+ "path": {
294
+ "name": "path",
295
+ "type": "text",
296
+ "primaryKey": false,
297
+ "notNull": true,
298
+ "autoincrement": false
299
+ },
300
+ "language": {
301
+ "name": "language",
302
+ "type": "text",
303
+ "primaryKey": false,
304
+ "notNull": false,
305
+ "autoincrement": false
306
+ },
307
+ "exports": {
308
+ "name": "exports",
309
+ "type": "text",
310
+ "primaryKey": false,
311
+ "notNull": false,
312
+ "autoincrement": false,
313
+ "default": "'[]'"
314
+ },
315
+ "imports": {
316
+ "name": "imports",
317
+ "type": "text",
318
+ "primaryKey": false,
319
+ "notNull": false,
320
+ "autoincrement": false,
321
+ "default": "'[]'"
322
+ },
323
+ "docstring": {
324
+ "name": "docstring",
325
+ "type": "text",
326
+ "primaryKey": false,
327
+ "notNull": false,
328
+ "autoincrement": false,
329
+ "default": "''"
330
+ },
331
+ "sections": {
332
+ "name": "sections",
333
+ "type": "text",
334
+ "primaryKey": false,
335
+ "notNull": false,
336
+ "autoincrement": false,
337
+ "default": "'[]'"
338
+ },
339
+ "internals": {
340
+ "name": "internals",
341
+ "type": "text",
342
+ "primaryKey": false,
343
+ "notNull": false,
344
+ "autoincrement": false,
345
+ "default": "'[]'"
346
+ },
347
+ "symbols": {
348
+ "name": "symbols",
349
+ "type": "text",
350
+ "primaryKey": false,
351
+ "notNull": false,
352
+ "autoincrement": false,
353
+ "default": "'[]'"
354
+ },
355
+ "namespaces": {
356
+ "name": "namespaces",
357
+ "type": "text",
358
+ "primaryKey": false,
359
+ "notNull": false,
360
+ "autoincrement": false,
361
+ "default": "'[]'"
362
+ }
363
+ },
364
+ "indexes": {
365
+ "idx_file_metadata_unique": {
366
+ "name": "idx_file_metadata_unique",
367
+ "columns": [
368
+ "repo_id",
369
+ "path"
370
+ ],
371
+ "isUnique": true
372
+ }
373
+ },
374
+ "foreignKeys": {
375
+ "file_metadata_repo_id_repos_id_fk": {
376
+ "name": "file_metadata_repo_id_repos_id_fk",
377
+ "tableFrom": "file_metadata",
378
+ "tableTo": "repos",
379
+ "columnsFrom": [
380
+ "repo_id"
381
+ ],
382
+ "columnsTo": [
383
+ "id"
384
+ ],
385
+ "onDelete": "cascade",
386
+ "onUpdate": "no action"
387
+ }
388
+ },
389
+ "compositePrimaryKeys": {},
390
+ "uniqueConstraints": {},
391
+ "checkConstraints": {}
392
+ },
393
+ "file_stats": {
394
+ "name": "file_stats",
395
+ "columns": {
396
+ "id": {
397
+ "name": "id",
398
+ "type": "text",
399
+ "primaryKey": true,
400
+ "notNull": true,
401
+ "autoincrement": false
402
+ },
403
+ "repo_id": {
404
+ "name": "repo_id",
405
+ "type": "text",
406
+ "primaryKey": false,
407
+ "notNull": true,
408
+ "autoincrement": false
409
+ },
410
+ "path": {
411
+ "name": "path",
412
+ "type": "text",
413
+ "primaryKey": false,
414
+ "notNull": true,
415
+ "autoincrement": false
416
+ },
417
+ "commit_count": {
418
+ "name": "commit_count",
419
+ "type": "integer",
420
+ "primaryKey": false,
421
+ "notNull": true,
422
+ "autoincrement": false,
423
+ "default": 0
424
+ },
425
+ "recent_count": {
426
+ "name": "recent_count",
427
+ "type": "integer",
428
+ "primaryKey": false,
429
+ "notNull": true,
430
+ "autoincrement": false,
431
+ "default": 0
432
+ },
433
+ "last_modified": {
434
+ "name": "last_modified",
435
+ "type": "text",
436
+ "primaryKey": false,
437
+ "notNull": false,
438
+ "autoincrement": false
439
+ }
440
+ },
441
+ "indexes": {
442
+ "idx_file_stats_unique": {
443
+ "name": "idx_file_stats_unique",
444
+ "columns": [
445
+ "repo_id",
446
+ "path"
447
+ ],
448
+ "isUnique": true
449
+ }
450
+ },
451
+ "foreignKeys": {
452
+ "file_stats_repo_id_repos_id_fk": {
453
+ "name": "file_stats_repo_id_repos_id_fk",
454
+ "tableFrom": "file_stats",
455
+ "tableTo": "repos",
456
+ "columnsFrom": [
457
+ "repo_id"
458
+ ],
459
+ "columnsTo": [
460
+ "id"
461
+ ],
462
+ "onDelete": "cascade",
463
+ "onUpdate": "no action"
464
+ }
465
+ },
466
+ "compositePrimaryKeys": {},
467
+ "uniqueConstraints": {},
468
+ "checkConstraints": {}
469
+ },
470
+ "repos": {
471
+ "name": "repos",
472
+ "columns": {
473
+ "id": {
474
+ "name": "id",
475
+ "type": "text",
476
+ "primaryKey": true,
477
+ "notNull": true,
478
+ "autoincrement": false
479
+ },
480
+ "identity_key": {
481
+ "name": "identity_key",
482
+ "type": "text",
483
+ "primaryKey": false,
484
+ "notNull": true,
485
+ "autoincrement": false
486
+ },
487
+ "name": {
488
+ "name": "name",
489
+ "type": "text",
490
+ "primaryKey": false,
491
+ "notNull": true,
492
+ "autoincrement": false
493
+ },
494
+ "root_path": {
495
+ "name": "root_path",
496
+ "type": "text",
497
+ "primaryKey": false,
498
+ "notNull": true,
499
+ "autoincrement": false
500
+ },
501
+ "remote_url": {
502
+ "name": "remote_url",
503
+ "type": "text",
504
+ "primaryKey": false,
505
+ "notNull": false,
506
+ "autoincrement": false
507
+ },
508
+ "last_indexed_commit": {
509
+ "name": "last_indexed_commit",
510
+ "type": "text",
511
+ "primaryKey": false,
512
+ "notNull": false,
513
+ "autoincrement": false
514
+ },
515
+ "index_status": {
516
+ "name": "index_status",
517
+ "type": "text",
518
+ "primaryKey": false,
519
+ "notNull": true,
520
+ "autoincrement": false,
521
+ "default": "'pending'"
522
+ },
523
+ "last_indexed_at": {
524
+ "name": "last_indexed_at",
525
+ "type": "text",
526
+ "primaryKey": false,
527
+ "notNull": false,
528
+ "autoincrement": false
529
+ },
530
+ "last_git_analysis_commit": {
531
+ "name": "last_git_analysis_commit",
532
+ "type": "text",
533
+ "primaryKey": false,
534
+ "notNull": false,
535
+ "autoincrement": false
536
+ },
537
+ "max_import_depth": {
538
+ "name": "max_import_depth",
539
+ "type": "integer",
540
+ "primaryKey": false,
541
+ "notNull": false,
542
+ "autoincrement": false,
543
+ "default": 0
544
+ },
545
+ "created_at": {
546
+ "name": "created_at",
547
+ "type": "text",
548
+ "primaryKey": false,
549
+ "notNull": true,
550
+ "autoincrement": false,
551
+ "default": "(datetime('now'))"
552
+ }
553
+ },
554
+ "indexes": {
555
+ "repos_identity_key_unique": {
556
+ "name": "repos_identity_key_unique",
557
+ "columns": [
558
+ "identity_key"
559
+ ],
560
+ "isUnique": true
561
+ },
562
+ "idx_repos_identity": {
563
+ "name": "idx_repos_identity",
564
+ "columns": [
565
+ "identity_key"
566
+ ],
567
+ "isUnique": false
568
+ }
569
+ },
570
+ "foreignKeys": {},
571
+ "compositePrimaryKeys": {},
572
+ "uniqueConstraints": {},
573
+ "checkConstraints": {}
574
+ }
575
+ },
576
+ "views": {},
577
+ "enums": {},
578
+ "_meta": {
579
+ "schemas": {},
580
+ "tables": {},
581
+ "columns": {}
582
+ },
583
+ "internal": {
584
+ "indexes": {}
585
+ }
586
+ }
@@ -15,6 +15,13 @@
15
15
  "when": 1771578032958,
16
16
  "tag": "0001_free_sphinx",
17
17
  "breakpoints": true
18
+ },
19
+ {
20
+ "idx": 2,
21
+ "version": "6",
22
+ "when": 1779103536804,
23
+ "tag": "0002_csharp_namespaces",
24
+ "breakpoints": true
18
25
  }
19
26
  ]
20
27
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lens-engine",
3
- "version": "2.0.1",
3
+ "version": "2.1.0",
4
4
  "description": "LENS — Structured code query engine for AI agents",
5
5
  "type": "module",
6
6
  "bin": {
@@ -9,7 +9,9 @@
9
9
  },
10
10
  "files": ["cli.js", "daemon.js", "dashboard", "drizzle-core", "drizzle-engine"],
11
11
  "dependencies": {
12
- "better-sqlite3": "^12.6.2"
12
+ "better-sqlite3": "^12.6.2",
13
+ "@ast-grep/napi": "^0.42.2",
14
+ "@ast-grep/lang-csharp": "^0.0.6"
13
15
  },
14
16
  "engines": {
15
17
  "node": ">=20"