* Every ordered pair of files where one reaches into the other, once each. * * `contains` is excluded (a file "contains" its own symbols, which is not a * dependency), and so are same-file edges and low-confidence name matches.
(minConfidence: number)
| 3476 | * dependency), and so are same-file edges and low-confidence name matches. |
| 3477 | */ |
| 3478 | getCrossFileDependencyPairs(minConfidence: number): Array<{ source: string; target: string }> { |
| 3479 | return this.db |
| 3480 | .prepare( |
| 3481 | `SELECT DISTINCT sn.file_path AS source, tn.file_path AS target |
| 3482 | FROM edges e |
| 3483 | JOIN nodes sn ON sn.id = e.source |
| 3484 | JOIN nodes tn ON tn.id = e.target |
| 3485 | WHERE e.kind <> 'contains' |
| 3486 | AND sn.file_path <> tn.file_path |
| 3487 | AND COALESCE(json_extract(e.metadata, '$.confidence'), 1) >= ?` |
| 3488 | ) |
| 3489 | .all(minConfidence) as Array<{ source: string; target: string }>; |
| 3490 | } |
| 3491 | |
| 3492 | /** |
| 3493 | * Every ordered pair of files where one imports the other, once each: the |
no test coverage detected