@backthread/extractor 0.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.
Files changed (379) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +83 -0
  3. package/dist/cluster/domain-grouping.d.ts +113 -0
  4. package/dist/cluster/domain-grouping.d.ts.map +1 -0
  5. package/dist/cluster/domain-grouping.js +277 -0
  6. package/dist/cluster/domain-grouping.js.map +1 -0
  7. package/dist/cluster/grouping-gate.d.ts +54 -0
  8. package/dist/cluster/grouping-gate.d.ts.map +1 -0
  9. package/dist/cluster/grouping-gate.js +0 -0
  10. package/dist/cluster/grouping-gate.js.map +1 -0
  11. package/dist/cluster/louvain.d.ts +88 -0
  12. package/dist/cluster/louvain.d.ts.map +1 -0
  13. package/dist/cluster/louvain.js +674 -0
  14. package/dist/cluster/louvain.js.map +1 -0
  15. package/dist/cluster/overrides.d.ts +19 -0
  16. package/dist/cluster/overrides.d.ts.map +1 -0
  17. package/dist/cluster/overrides.js +32 -0
  18. package/dist/cluster/overrides.js.map +1 -0
  19. package/dist/cluster/subsystem.d.ts +45 -0
  20. package/dist/cluster/subsystem.d.ts.map +1 -0
  21. package/dist/cluster/subsystem.js +299 -0
  22. package/dist/cluster/subsystem.js.map +1 -0
  23. package/dist/cluster/workspaces.d.ts +64 -0
  24. package/dist/cluster/workspaces.d.ts.map +1 -0
  25. package/dist/cluster/workspaces.js +739 -0
  26. package/dist/cluster/workspaces.js.map +1 -0
  27. package/dist/extract.d.ts +52 -0
  28. package/dist/extract.d.ts.map +1 -0
  29. package/dist/extract.js +48 -0
  30. package/dist/extract.js.map +1 -0
  31. package/dist/framework/celery/celery.d.ts +17 -0
  32. package/dist/framework/celery/celery.d.ts.map +1 -0
  33. package/dist/framework/celery/celery.js +524 -0
  34. package/dist/framework/celery/celery.js.map +1 -0
  35. package/dist/framework/contribute-step.d.ts +38 -0
  36. package/dist/framework/contribute-step.d.ts.map +1 -0
  37. package/dist/framework/contribute-step.js +403 -0
  38. package/dist/framework/contribute-step.js.map +1 -0
  39. package/dist/framework/detect-step.d.ts +8 -0
  40. package/dist/framework/detect-step.d.ts.map +1 -0
  41. package/dist/framework/detect-step.js +54 -0
  42. package/dist/framework/detect-step.js.map +1 -0
  43. package/dist/framework/detect-util.d.ts +24 -0
  44. package/dist/framework/detect-util.d.ts.map +1 -0
  45. package/dist/framework/detect-util.js +59 -0
  46. package/dist/framework/detect-util.js.map +1 -0
  47. package/dist/framework/django/django.d.ts +22 -0
  48. package/dist/framework/django/django.d.ts.map +1 -0
  49. package/dist/framework/django/django.js +940 -0
  50. package/dist/framework/django/django.js.map +1 -0
  51. package/dist/framework/fastapi/fastapi.d.ts +27 -0
  52. package/dist/framework/fastapi/fastapi.d.ts.map +1 -0
  53. package/dist/framework/fastapi/fastapi.js +477 -0
  54. package/dist/framework/fastapi/fastapi.js.map +1 -0
  55. package/dist/framework/faststream/faststream.d.ts +19 -0
  56. package/dist/framework/faststream/faststream.d.ts.map +1 -0
  57. package/dist/framework/faststream/faststream.js +765 -0
  58. package/dist/framework/faststream/faststream.js.map +1 -0
  59. package/dist/framework/flask/flask.d.ts +17 -0
  60. package/dist/framework/flask/flask.d.ts.map +1 -0
  61. package/dist/framework/flask/flask.js +507 -0
  62. package/dist/framework/flask/flask.js.map +1 -0
  63. package/dist/framework/graphql/graphql.d.ts +17 -0
  64. package/dist/framework/graphql/graphql.d.ts.map +1 -0
  65. package/dist/framework/graphql/graphql.js +708 -0
  66. package/dist/framework/graphql/graphql.js.map +1 -0
  67. package/dist/framework/grpc/grpc.d.ts +22 -0
  68. package/dist/framework/grpc/grpc.d.ts.map +1 -0
  69. package/dist/framework/grpc/grpc.js +618 -0
  70. package/dist/framework/grpc/grpc.js.map +1 -0
  71. package/dist/framework/litestar/litestar.d.ts +17 -0
  72. package/dist/framework/litestar/litestar.d.ts.map +1 -0
  73. package/dist/framework/litestar/litestar.js +536 -0
  74. package/dist/framework/litestar/litestar.js.map +1 -0
  75. package/dist/framework/nest/nest.d.ts +19 -0
  76. package/dist/framework/nest/nest.d.ts.map +1 -0
  77. package/dist/framework/nest/nest.js +613 -0
  78. package/dist/framework/nest/nest.js.map +1 -0
  79. package/dist/framework/next/next.d.ts +22 -0
  80. package/dist/framework/next/next.d.ts.map +1 -0
  81. package/dist/framework/next/next.js +449 -0
  82. package/dist/framework/next/next.js.map +1 -0
  83. package/dist/framework/node/node.d.ts +24 -0
  84. package/dist/framework/node/node.d.ts.map +1 -0
  85. package/dist/framework/node/node.js +1009 -0
  86. package/dist/framework/node/node.js.map +1 -0
  87. package/dist/framework/orchestrator/orchestrator.d.ts +34 -0
  88. package/dist/framework/orchestrator/orchestrator.d.ts.map +1 -0
  89. package/dist/framework/orchestrator/orchestrator.js +691 -0
  90. package/dist/framework/orchestrator/orchestrator.js.map +1 -0
  91. package/dist/framework/orm/orm.d.ts +61 -0
  92. package/dist/framework/orm/orm.d.ts.map +1 -0
  93. package/dist/framework/orm/orm.js +620 -0
  94. package/dist/framework/orm/orm.js.map +1 -0
  95. package/dist/framework/python/analyze.d.ts +38 -0
  96. package/dist/framework/python/analyze.d.ts.map +1 -0
  97. package/dist/framework/python/analyze.js +98 -0
  98. package/dist/framework/python/analyze.js.map +1 -0
  99. package/dist/framework/python/py-ast.d.ts +130 -0
  100. package/dist/framework/python/py-ast.d.ts.map +1 -0
  101. package/dist/framework/python/py-ast.js +344 -0
  102. package/dist/framework/python/py-ast.js.map +1 -0
  103. package/dist/framework/python-orm/python-orm.d.ts +19 -0
  104. package/dist/framework/python-orm/python-orm.d.ts.map +1 -0
  105. package/dist/framework/python-orm/python-orm.js +516 -0
  106. package/dist/framework/python-orm/python-orm.js.map +1 -0
  107. package/dist/framework/react-native/react-native.d.ts +35 -0
  108. package/dist/framework/react-native/react-native.d.ts.map +1 -0
  109. package/dist/framework/react-native/react-native.js +1181 -0
  110. package/dist/framework/react-native/react-native.js.map +1 -0
  111. package/dist/framework/register.d.ts +2 -0
  112. package/dist/framework/register.d.ts.map +1 -0
  113. package/dist/framework/register.js +59 -0
  114. package/dist/framework/register.js.map +1 -0
  115. package/dist/framework/registry.d.ts +31 -0
  116. package/dist/framework/registry.d.ts.map +1 -0
  117. package/dist/framework/registry.js +70 -0
  118. package/dist/framework/registry.js.map +1 -0
  119. package/dist/framework/routing/expo-router.d.ts +31 -0
  120. package/dist/framework/routing/expo-router.d.ts.map +1 -0
  121. package/dist/framework/routing/expo-router.js +356 -0
  122. package/dist/framework/routing/expo-router.js.map +1 -0
  123. package/dist/framework/routing/index.d.ts +4 -0
  124. package/dist/framework/routing/index.d.ts.map +1 -0
  125. package/dist/framework/routing/index.js +16 -0
  126. package/dist/framework/routing/index.js.map +1 -0
  127. package/dist/framework/routing/next-router.d.ts +45 -0
  128. package/dist/framework/routing/next-router.d.ts.map +1 -0
  129. package/dist/framework/routing/next-router.js +378 -0
  130. package/dist/framework/routing/next-router.js.map +1 -0
  131. package/dist/framework/routing/route-tree.d.ts +73 -0
  132. package/dist/framework/routing/route-tree.d.ts.map +1 -0
  133. package/dist/framework/routing/route-tree.js +120 -0
  134. package/dist/framework/routing/route-tree.js.map +1 -0
  135. package/dist/framework/types.d.ts +230 -0
  136. package/dist/framework/types.d.ts.map +1 -0
  137. package/dist/framework/types.js +25 -0
  138. package/dist/framework/types.js.map +1 -0
  139. package/dist/graph/cross-language.d.ts +11 -0
  140. package/dist/graph/cross-language.d.ts.map +1 -0
  141. package/dist/graph/cross-language.js +123 -0
  142. package/dist/graph/cross-language.js.map +1 -0
  143. package/dist/graph/extract.d.ts +13 -0
  144. package/dist/graph/extract.d.ts.map +1 -0
  145. package/dist/graph/extract.js +79 -0
  146. package/dist/graph/extract.js.map +1 -0
  147. package/dist/graph/file-graph.d.ts +186 -0
  148. package/dist/graph/file-graph.d.ts.map +1 -0
  149. package/dist/graph/file-graph.js +427 -0
  150. package/dist/graph/file-graph.js.map +1 -0
  151. package/dist/graph/http-callsites.d.ts +14 -0
  152. package/dist/graph/http-callsites.d.ts.map +1 -0
  153. package/dist/graph/http-callsites.js +107 -0
  154. package/dist/graph/http-callsites.js.map +1 -0
  155. package/dist/graph/incremental.d.ts +122 -0
  156. package/dist/graph/incremental.d.ts.map +1 -0
  157. package/dist/graph/incremental.js +448 -0
  158. package/dist/graph/incremental.js.map +1 -0
  159. package/dist/graph/language.d.ts +31 -0
  160. package/dist/graph/language.d.ts.map +1 -0
  161. package/dist/graph/language.js +146 -0
  162. package/dist/graph/language.js.map +1 -0
  163. package/dist/graph/noise-filter.d.ts +46 -0
  164. package/dist/graph/noise-filter.d.ts.map +1 -0
  165. package/dist/graph/noise-filter.js +199 -0
  166. package/dist/graph/noise-filter.js.map +1 -0
  167. package/dist/graph/python-adapter.d.ts +36 -0
  168. package/dist/graph/python-adapter.d.ts.map +1 -0
  169. package/dist/graph/python-adapter.js +402 -0
  170. package/dist/graph/python-adapter.js.map +1 -0
  171. package/dist/graph/python-manifest.d.ts +22 -0
  172. package/dist/graph/python-manifest.d.ts.map +1 -0
  173. package/dist/graph/python-manifest.js +137 -0
  174. package/dist/graph/python-manifest.js.map +1 -0
  175. package/dist/graph/python-stdlib.d.ts +2 -0
  176. package/dist/graph/python-stdlib.d.ts.map +1 -0
  177. package/dist/graph/python-stdlib.js +53 -0
  178. package/dist/graph/python-stdlib.js.map +1 -0
  179. package/dist/graph/ts-morph-adapter.d.ts +65 -0
  180. package/dist/graph/ts-morph-adapter.d.ts.map +1 -0
  181. package/dist/graph/ts-morph-adapter.js +265 -0
  182. package/dist/graph/ts-morph-adapter.js.map +1 -0
  183. package/dist/graph/types.d.ts +37 -0
  184. package/dist/graph/types.d.ts.map +1 -0
  185. package/dist/graph/types.js +50 -0
  186. package/dist/graph/types.js.map +1 -0
  187. package/dist/index.d.ts +45 -0
  188. package/dist/index.d.ts.map +1 -0
  189. package/dist/index.js +51 -0
  190. package/dist/index.js.map +1 -0
  191. package/dist/infra/aws/aws-parse.d.ts +39 -0
  192. package/dist/infra/aws/aws-parse.d.ts.map +1 -0
  193. package/dist/infra/aws/aws-parse.js +149 -0
  194. package/dist/infra/aws/aws-parse.js.map +1 -0
  195. package/dist/infra/aws/aws.d.ts +6 -0
  196. package/dist/infra/aws/aws.d.ts.map +1 -0
  197. package/dist/infra/aws/aws.js +425 -0
  198. package/dist/infra/aws/aws.js.map +1 -0
  199. package/dist/infra/azure/azure-parse.d.ts +73 -0
  200. package/dist/infra/azure/azure-parse.d.ts.map +1 -0
  201. package/dist/infra/azure/azure-parse.js +178 -0
  202. package/dist/infra/azure/azure-parse.js.map +1 -0
  203. package/dist/infra/azure/azure.d.ts +12 -0
  204. package/dist/infra/azure/azure.d.ts.map +1 -0
  205. package/dist/infra/azure/azure.js +673 -0
  206. package/dist/infra/azure/azure.js.map +1 -0
  207. package/dist/infra/cloudflare/cloudflare.d.ts +50 -0
  208. package/dist/infra/cloudflare/cloudflare.d.ts.map +1 -0
  209. package/dist/infra/cloudflare/cloudflare.js +382 -0
  210. package/dist/infra/cloudflare/cloudflare.js.map +1 -0
  211. package/dist/infra/cloudflare/wrangler-parse.d.ts +6 -0
  212. package/dist/infra/cloudflare/wrangler-parse.d.ts.map +1 -0
  213. package/dist/infra/cloudflare/wrangler-parse.js +278 -0
  214. package/dist/infra/cloudflare/wrangler-parse.js.map +1 -0
  215. package/dist/infra/compose/compose-parse.d.ts +24 -0
  216. package/dist/infra/compose/compose-parse.d.ts.map +1 -0
  217. package/dist/infra/compose/compose-parse.js +77 -0
  218. package/dist/infra/compose/compose-parse.js.map +1 -0
  219. package/dist/infra/compose/compose.d.ts +12 -0
  220. package/dist/infra/compose/compose.d.ts.map +1 -0
  221. package/dist/infra/compose/compose.js +201 -0
  222. package/dist/infra/compose/compose.js.map +1 -0
  223. package/dist/infra/convex/convex-parse.d.ts +28 -0
  224. package/dist/infra/convex/convex-parse.d.ts.map +1 -0
  225. package/dist/infra/convex/convex-parse.js +74 -0
  226. package/dist/infra/convex/convex-parse.js.map +1 -0
  227. package/dist/infra/convex/convex.d.ts +18 -0
  228. package/dist/infra/convex/convex.d.ts.map +1 -0
  229. package/dist/infra/convex/convex.js +199 -0
  230. package/dist/infra/convex/convex.js.map +1 -0
  231. package/dist/infra/digitalocean/digitalocean.d.ts +33 -0
  232. package/dist/infra/digitalocean/digitalocean.d.ts.map +1 -0
  233. package/dist/infra/digitalocean/digitalocean.js +204 -0
  234. package/dist/infra/digitalocean/digitalocean.js.map +1 -0
  235. package/dist/infra/firebase/firebase.d.ts +43 -0
  236. package/dist/infra/firebase/firebase.d.ts.map +1 -0
  237. package/dist/infra/firebase/firebase.js +271 -0
  238. package/dist/infra/firebase/firebase.js.map +1 -0
  239. package/dist/infra/fly/fly-parse.d.ts +52 -0
  240. package/dist/infra/fly/fly-parse.d.ts.map +1 -0
  241. package/dist/infra/fly/fly-parse.js +114 -0
  242. package/dist/infra/fly/fly-parse.js.map +1 -0
  243. package/dist/infra/fly/fly.d.ts +15 -0
  244. package/dist/infra/fly/fly.d.ts.map +1 -0
  245. package/dist/infra/fly/fly.js +265 -0
  246. package/dist/infra/fly/fly.js.map +1 -0
  247. package/dist/infra/gcp/gcp-parse.d.ts +24 -0
  248. package/dist/infra/gcp/gcp-parse.d.ts.map +1 -0
  249. package/dist/infra/gcp/gcp-parse.js +123 -0
  250. package/dist/infra/gcp/gcp-parse.js.map +1 -0
  251. package/dist/infra/gcp/gcp.d.ts +10 -0
  252. package/dist/infra/gcp/gcp.d.ts.map +1 -0
  253. package/dist/infra/gcp/gcp.js +502 -0
  254. package/dist/infra/gcp/gcp.js.map +1 -0
  255. package/dist/infra/heroku/heroku-parse.d.ts +33 -0
  256. package/dist/infra/heroku/heroku-parse.d.ts.map +1 -0
  257. package/dist/infra/heroku/heroku-parse.js +63 -0
  258. package/dist/infra/heroku/heroku-parse.js.map +1 -0
  259. package/dist/infra/heroku/heroku.d.ts +24 -0
  260. package/dist/infra/heroku/heroku.d.ts.map +1 -0
  261. package/dist/infra/heroku/heroku.js +253 -0
  262. package/dist/infra/heroku/heroku.js.map +1 -0
  263. package/dist/infra/image-resolve.d.ts +56 -0
  264. package/dist/infra/image-resolve.d.ts.map +1 -0
  265. package/dist/infra/image-resolve.js +229 -0
  266. package/dist/infra/image-resolve.js.map +1 -0
  267. package/dist/infra/infra-step.d.ts +39 -0
  268. package/dist/infra/infra-step.d.ts.map +1 -0
  269. package/dist/infra/infra-step.js +57 -0
  270. package/dist/infra/infra-step.js.map +1 -0
  271. package/dist/infra/k8s/index.d.ts +78 -0
  272. package/dist/infra/k8s/index.d.ts.map +1 -0
  273. package/dist/infra/k8s/index.js +251 -0
  274. package/dist/infra/k8s/index.js.map +1 -0
  275. package/dist/infra/kamal/kamal-parse.d.ts +23 -0
  276. package/dist/infra/kamal/kamal-parse.d.ts.map +1 -0
  277. package/dist/infra/kamal/kamal-parse.js +66 -0
  278. package/dist/infra/kamal/kamal-parse.js.map +1 -0
  279. package/dist/infra/kamal/kamal.d.ts +17 -0
  280. package/dist/infra/kamal/kamal.d.ts.map +1 -0
  281. package/dist/infra/kamal/kamal.js +162 -0
  282. package/dist/infra/kamal/kamal.js.map +1 -0
  283. package/dist/infra/netlify/netlify.d.ts +33 -0
  284. package/dist/infra/netlify/netlify.d.ts.map +1 -0
  285. package/dist/infra/netlify/netlify.js +247 -0
  286. package/dist/infra/netlify/netlify.js.map +1 -0
  287. package/dist/infra/opentofu/opentofu.d.ts +3 -0
  288. package/dist/infra/opentofu/opentofu.d.ts.map +1 -0
  289. package/dist/infra/opentofu/opentofu.js +157 -0
  290. package/dist/infra/opentofu/opentofu.js.map +1 -0
  291. package/dist/infra/pulumi/pulumi-parse.d.ts +60 -0
  292. package/dist/infra/pulumi/pulumi-parse.d.ts.map +1 -0
  293. package/dist/infra/pulumi/pulumi-parse.js +155 -0
  294. package/dist/infra/pulumi/pulumi-parse.js.map +1 -0
  295. package/dist/infra/pulumi/pulumi.d.ts +23 -0
  296. package/dist/infra/pulumi/pulumi.d.ts.map +1 -0
  297. package/dist/infra/pulumi/pulumi.js +260 -0
  298. package/dist/infra/pulumi/pulumi.js.map +1 -0
  299. package/dist/infra/railway/railway-parse.d.ts +54 -0
  300. package/dist/infra/railway/railway-parse.d.ts.map +1 -0
  301. package/dist/infra/railway/railway-parse.js +200 -0
  302. package/dist/infra/railway/railway-parse.js.map +1 -0
  303. package/dist/infra/railway/railway.d.ts +19 -0
  304. package/dist/infra/railway/railway.d.ts.map +1 -0
  305. package/dist/infra/railway/railway.js +397 -0
  306. package/dist/infra/railway/railway.js.map +1 -0
  307. package/dist/infra/register.d.ts +2 -0
  308. package/dist/infra/register.d.ts.map +1 -0
  309. package/dist/infra/register.js +81 -0
  310. package/dist/infra/register.js.map +1 -0
  311. package/dist/infra/registry.d.ts +64 -0
  312. package/dist/infra/registry.d.ts.map +1 -0
  313. package/dist/infra/registry.js +205 -0
  314. package/dist/infra/registry.js.map +1 -0
  315. package/dist/infra/relevance.d.ts +16 -0
  316. package/dist/infra/relevance.d.ts.map +1 -0
  317. package/dist/infra/relevance.js +132 -0
  318. package/dist/infra/relevance.js.map +1 -0
  319. package/dist/infra/render/render-parse.d.ts +76 -0
  320. package/dist/infra/render/render-parse.d.ts.map +1 -0
  321. package/dist/infra/render/render-parse.js +155 -0
  322. package/dist/infra/render/render-parse.js.map +1 -0
  323. package/dist/infra/render/render.d.ts +11 -0
  324. package/dist/infra/render/render.d.ts.map +1 -0
  325. package/dist/infra/render/render.js +303 -0
  326. package/dist/infra/render/render.js.map +1 -0
  327. package/dist/infra/sst/sst-parse.d.ts +25 -0
  328. package/dist/infra/sst/sst-parse.d.ts.map +1 -0
  329. package/dist/infra/sst/sst-parse.js +45 -0
  330. package/dist/infra/sst/sst-parse.js.map +1 -0
  331. package/dist/infra/sst/sst.d.ts +19 -0
  332. package/dist/infra/sst/sst.d.ts.map +1 -0
  333. package/dist/infra/sst/sst.js +236 -0
  334. package/dist/infra/sst/sst.js.map +1 -0
  335. package/dist/infra/supabase/supabase-parse.d.ts +34 -0
  336. package/dist/infra/supabase/supabase-parse.d.ts.map +1 -0
  337. package/dist/infra/supabase/supabase-parse.js +113 -0
  338. package/dist/infra/supabase/supabase-parse.js.map +1 -0
  339. package/dist/infra/supabase/supabase.d.ts +15 -0
  340. package/dist/infra/supabase/supabase.d.ts.map +1 -0
  341. package/dist/infra/supabase/supabase.js +198 -0
  342. package/dist/infra/supabase/supabase.js.map +1 -0
  343. package/dist/infra/terraform/hcl-parse.d.ts +34 -0
  344. package/dist/infra/terraform/hcl-parse.d.ts.map +1 -0
  345. package/dist/infra/terraform/hcl-parse.js +203 -0
  346. package/dist/infra/terraform/hcl-parse.js.map +1 -0
  347. package/dist/infra/terraform/terraform.d.ts +14 -0
  348. package/dist/infra/terraform/terraform.d.ts.map +1 -0
  349. package/dist/infra/terraform/terraform.js +264 -0
  350. package/dist/infra/terraform/terraform.js.map +1 -0
  351. package/dist/infra/types.d.ts +151 -0
  352. package/dist/infra/types.d.ts.map +1 -0
  353. package/dist/infra/types.js +14 -0
  354. package/dist/infra/types.js.map +1 -0
  355. package/dist/infra/vercel/vercel-parse.d.ts +70 -0
  356. package/dist/infra/vercel/vercel-parse.d.ts.map +1 -0
  357. package/dist/infra/vercel/vercel-parse.js +194 -0
  358. package/dist/infra/vercel/vercel-parse.js.map +1 -0
  359. package/dist/infra/vercel/vercel.d.ts +30 -0
  360. package/dist/infra/vercel/vercel.d.ts.map +1 -0
  361. package/dist/infra/vercel/vercel.js +523 -0
  362. package/dist/infra/vercel/vercel.js.map +1 -0
  363. package/dist/infra/walk.d.ts +36 -0
  364. package/dist/infra/walk.d.ts.map +1 -0
  365. package/dist/infra/walk.js +85 -0
  366. package/dist/infra/walk.js.map +1 -0
  367. package/dist/safety.d.ts +13 -0
  368. package/dist/safety.d.ts.map +1 -0
  369. package/dist/safety.js +67 -0
  370. package/dist/safety.js.map +1 -0
  371. package/dist/types.d.ts +47 -0
  372. package/dist/types.d.ts.map +1 -0
  373. package/dist/types.js +111 -0
  374. package/dist/types.js.map +1 -0
  375. package/dist/version.d.ts +2 -0
  376. package/dist/version.d.ts.map +1 -0
  377. package/dist/version.js +35 -0
  378. package/dist/version.js.map +1 -0
  379. package/package.json +65 -0
@@ -0,0 +1,613 @@
1
+ // (Slice 2) — the NestJS FrameworkAdapter. DETECTION.
2
+ // the @Module grouping prior + DI graph + role tags.
3
+ //
4
+ // DETECTION: decides "is this a NestJS app?" from package.json deps +
5
+ // config-file existence — never source content (never-store-source).
6
+ //
7
+ // CONTRIBUTION: NestJS is the cleanest adapter — it DECLARES its
8
+ // architecture. Every `@Module({...})` is an authoritative subsystem boundary
9
+ // (controllers + providers + exports), constructor parameters ARE the dependency
10
+ // graph, and the stereotype decorators (@Controller / @Injectable / @Resolver,
11
+ // CanActivate / NestInterceptor / PipeTransform) ARE the roles. We read this
12
+ // STATICALLY via ts-morph (install-free; never-store-source — read server-side,
13
+ // persist only the derived groups/edges/roles) and contribute in the graph
14
+ // FILE-ID space; the generic contribute-step resolves to MODULE ids.
15
+ //
16
+ // * groupingPrior — one FrameworkGroup per @Module (its controller/provider/
17
+ // export files). The contribute-step makes each its own
18
+ // subsystem, AUTHORITATIVE over directory + workspace-package
19
+ // grouping (the headline value: @Module == subsystem).
20
+ // * syntheticEdges — the DI graph (kind 'calls' only): constructor-injected
21
+ // provider ← consumer, and @Module `imports` wiring.
22
+ // * roleTags — Controller/Resolver → gateway; Service/Guard/Interceptor/
23
+ // Pipe/Module → service. METADATA, never a new Module-kind.
24
+ //
25
+ // Unresolved custom providers / injection tokens (useFactory / useValue / string
26
+ // @Inject tokens) DEGRADE + LOG — no silent caps.
27
+ //
28
+ // Detection signals (manifest + config existence only):
29
+ // * dep: `@nestjs/core` — the authoritative signal
30
+ // * config: nest-cli.json — Nest CLI, Nest-specific
31
+ //
32
+ // scoreNest is PURE; the adapter gathers the fs signals and calls it.
33
+ import { SyntaxKind, } from 'ts-morph';
34
+ import { addAllSourceFiles, buildExtractionProject, toId, } from '../../graph/ts-morph-adapter.js';
35
+ import { SOURCE_EXTENSIONS } from '../../graph/file-graph.js';
36
+ import { clampConfidence, existsAny, readDeps, resolveBase } from '../detect-util.js';
37
+ /** Gather the signal set for a single root dir (fs only). */
38
+ export function gatherNestSignals(baseDir) {
39
+ const deps = readDeps(baseDir);
40
+ return {
41
+ hasNestCoreDep: '@nestjs/core' in deps,
42
+ hasNestCliJson: existsAny(baseDir, ['nest-cli.json']),
43
+ };
44
+ }
45
+ /**
46
+ * Decide NestJS from the signal set. Returns a DetectMatch, or null when no
47
+ * signal fires (generic-TS fallthrough intact).
48
+ *
49
+ * Both signals are SUFFICIENT on their own (each is Nest-specific): the
50
+ * `@nestjs/core` dep, or a nest-cli.json file.
51
+ */
52
+ export function scoreNest(s, rootPath = '') {
53
+ if (!s.hasNestCoreDep && !s.hasNestCliJson)
54
+ return null;
55
+ let confidence = 0;
56
+ if (s.hasNestCoreDep)
57
+ confidence += 0.6;
58
+ if (s.hasNestCliJson)
59
+ confidence += 0.4;
60
+ return {
61
+ adapter: 'nest',
62
+ confidence: clampConfidence(confidence),
63
+ rootPath,
64
+ metadata: {
65
+ signals: {
66
+ nestCoreDep: s.hasNestCoreDep,
67
+ nestCliJson: s.hasNestCliJson,
68
+ },
69
+ },
70
+ };
71
+ }
72
+ // Collapse priority when one FILE carries several role signals (rare — Nest is
73
+ // one-class-per-file) AND, downstream, when several files of different roles land
74
+ // in ONE module after clustering (the contribute-step keeps the highest). Request
75
+ // entries outrank cross-cutting providers outrank plain services outrank wiring.
76
+ const ROLE_PRIORITY = {
77
+ controller: 7,
78
+ resolver: 6,
79
+ guard: 5,
80
+ interceptor: 4,
81
+ pipe: 3,
82
+ service: 2,
83
+ module: 1,
84
+ };
85
+ const ROLE_KIND = {
86
+ controller: 'gateway',
87
+ resolver: 'gateway',
88
+ guard: 'service',
89
+ interceptor: 'service',
90
+ pipe: 'service',
91
+ service: 'service',
92
+ module: 'service',
93
+ };
94
+ // The Nest stereotype decorators whose class participates in DI (its constructor
95
+ // is the dependency graph). @Catch (exception filters) also injects.
96
+ const NEST_STEREOTYPES = new Set(['Controller', 'Injectable', 'Resolver', 'Catch']);
97
+ // Implemented-interface → cross-cutting role (the way Nest distinguishes a guard /
98
+ // interceptor / pipe from a plain @Injectable service — they're all @Injectable).
99
+ const INTERFACE_ROLE = {
100
+ CanActivate: 'guard',
101
+ NestInterceptor: 'interceptor',
102
+ PipeTransform: 'pipe',
103
+ };
104
+ const SOURCE_EXT_SET = new Set(SOURCE_EXTENSIONS);
105
+ // Memoized on the FrameworkContext OBJECT (not repoDir) so groupingPrior +
106
+ // syntheticEdges + roleTags share ONE parse, while the merge walk's per-checkpoint
107
+ // ctx (same clone.dir, different tree) gets a fresh analysis — no cross-tree
108
+ // staleness. Mirrors the RN / node adapters.
109
+ const ANALYSIS_CACHE = new WeakMap();
110
+ // ---------------------------------------------------------------------------
111
+ // Static resolution helpers (install-free, deterministic).
112
+ // localImportedName → resolved repo-relative file id, for one source file. Only
113
+ // INTERNAL imports resolve (getModuleSpecifierSourceFile is null for a bare
114
+ // external specifier install-free).
115
+ function buildImportNameMap(sf, repoDir) {
116
+ const map = new Map();
117
+ for (const decl of sf.getImportDeclarations()) {
118
+ const resolved = decl.getModuleSpecifierSourceFile();
119
+ if (!resolved)
120
+ continue;
121
+ const fileId = toId(repoDir, resolved.getFilePath());
122
+ const def = decl.getDefaultImport();
123
+ if (def)
124
+ map.set(def.getText(), fileId);
125
+ const ns = decl.getNamespaceImport();
126
+ if (ns)
127
+ map.set(ns.getText(), fileId);
128
+ for (const ni of decl.getNamedImports()) {
129
+ map.set((ni.getAliasNode() ?? ni.getNameNode()).getText(), fileId);
130
+ }
131
+ }
132
+ return map;
133
+ }
134
+ // ts-morph exposes getExpression() on many concrete node types but not the base
135
+ // Node; we reach it only after a getKind() gate, so a guarded optional-call is
136
+ // both safe and avoids a forest of per-kind casts.
137
+ function innerExpression(node) {
138
+ return node.getExpression?.();
139
+ }
140
+ // The leftmost identifier of a property-access / qualified-name chain (`a.b.c` →
141
+ // `a`). Undefined when the chain doesn't root in a plain identifier.
142
+ function rootIdentifier(node, depth = 0) {
143
+ if (depth > 16)
144
+ return undefined;
145
+ const k = node.getKind();
146
+ if (k === SyntaxKind.Identifier)
147
+ return node.getText();
148
+ if (k === SyntaxKind.PropertyAccessExpression || k === SyntaxKind.QualifiedName) {
149
+ const left = node;
150
+ const next = left.getExpression?.() ?? left.getLeft?.();
151
+ return next ? rootIdentifier(next, depth + 1) : undefined;
152
+ }
153
+ return undefined;
154
+ }
155
+ // A decorator's name (`@Module(...)` → 'Module'); '' if it can't be read.
156
+ function decoratorName(d) {
157
+ try {
158
+ return d.getName();
159
+ }
160
+ catch {
161
+ return '';
162
+ }
163
+ }
164
+ // Resolve a class REFERENCE expression (in a @Module array, or a useClass) to its
165
+ // declaring file id, or null when it can't be statically resolved.
166
+ // * Identifier → imported file; a locally-declared class → self
167
+ // * PropertyAccess → root identifier's file (`Ns.Foo`)
168
+ // * CallExpression → the callee's class (`XModule.forRoot()`)
169
+ // * as/paren/non-null → unwrap
170
+ function resolveClassRef(expr, imports, selfFileId, localClasses, depth = 0) {
171
+ if (depth > 8)
172
+ return null;
173
+ switch (expr.getKind()) {
174
+ case SyntaxKind.ParenthesizedExpression:
175
+ case SyntaxKind.AsExpression:
176
+ case SyntaxKind.SatisfiesExpression:
177
+ case SyntaxKind.NonNullExpression:
178
+ case SyntaxKind.TypeAssertionExpression: {
179
+ const inner = innerExpression(expr);
180
+ return inner ? resolveClassRef(inner, imports, selfFileId, localClasses, depth + 1) : null;
181
+ }
182
+ case SyntaxKind.Identifier: {
183
+ const t = expr.getText();
184
+ return imports.get(t) ?? (localClasses.has(t) ? selfFileId : null);
185
+ }
186
+ case SyntaxKind.PropertyAccessExpression: {
187
+ const root = rootIdentifier(expr);
188
+ return root ? (imports.get(root) ?? (localClasses.has(root) ? selfFileId : null)) : null;
189
+ }
190
+ case SyntaxKind.CallExpression:
191
+ return resolveClassRef(expr.getExpression(), imports, selfFileId, localClasses, depth + 1);
192
+ default:
193
+ return null;
194
+ }
195
+ }
196
+ // Resolve a single `providers: [...]` element to a file id, or null.
197
+ // * a bare class reference → resolveClassRef
198
+ // * `{ provide, useClass: Foo }` → resolve `useClass`
199
+ // * `{ provide, useFactory|useValue|useExisting}`→ DEGRADE (no class file) + log
200
+ // * spread / anything else → DEGRADE + log
201
+ function resolveProviderEntry(el, imports, selfFileId, localClasses, diag) {
202
+ let node = el;
203
+ // Unwrap as/paren/non-null so `Foo as Provider` still resolves.
204
+ for (let i = 0; i < 8; i++) {
205
+ const k = node.getKind();
206
+ if (k === SyntaxKind.ParenthesizedExpression ||
207
+ k === SyntaxKind.AsExpression ||
208
+ k === SyntaxKind.SatisfiesExpression ||
209
+ k === SyntaxKind.NonNullExpression ||
210
+ k === SyntaxKind.TypeAssertionExpression) {
211
+ const inner = innerExpression(node);
212
+ if (!inner)
213
+ break;
214
+ node = inner;
215
+ }
216
+ else {
217
+ break;
218
+ }
219
+ }
220
+ if (node.getKind() === SyntaxKind.ObjectLiteralExpression) {
221
+ const obj = node;
222
+ const useClass = obj.getProperty('useClass');
223
+ if (useClass && useClass.getKind() === SyntaxKind.PropertyAssignment) {
224
+ const init = useClass.getInitializer();
225
+ const file = init ? resolveClassRef(init, imports, selfFileId, localClasses) : null;
226
+ if (file)
227
+ return file;
228
+ }
229
+ // useFactory / useValue / useExisting / unresolved useClass: a custom
230
+ // provider with no statically-knowable class file. Degrade + log the token.
231
+ diag.dynamicProviders++;
232
+ const provide = obj.getProperty('provide');
233
+ if (provide && provide.getKind() === SyntaxKind.PropertyAssignment) {
234
+ const v = provide.getInitializer();
235
+ if (v)
236
+ diag.unresolvedProviders.add(v.getText().slice(0, 60));
237
+ }
238
+ return null;
239
+ }
240
+ if (node.getKind() === SyntaxKind.SpreadElement) {
241
+ diag.dynamicProviders++;
242
+ return null;
243
+ }
244
+ const file = resolveClassRef(node, imports, selfFileId, localClasses);
245
+ if (!file)
246
+ diag.unresolvedProviders.add(node.getText().slice(0, 60));
247
+ return file;
248
+ }
249
+ // Read an array-literal @Module property (`controllers` / `providers` / `imports`
250
+ // / `exports`) → resolved file ids. `mode` selects the per-element resolver.
251
+ function readArrayProp(obj, key, mode, imports, selfFileId, localClasses, diag) {
252
+ const prop = obj.getProperty(key);
253
+ if (!prop || prop.getKind() !== SyntaxKind.PropertyAssignment)
254
+ return [];
255
+ const init = prop.getInitializer();
256
+ if (!init || init.getKind() !== SyntaxKind.ArrayLiteralExpression)
257
+ return [];
258
+ const out = [];
259
+ for (const el of init.getElements()) {
260
+ if (mode === 'provider') {
261
+ const f = resolveProviderEntry(el, imports, selfFileId, localClasses, diag);
262
+ if (f)
263
+ out.push(f);
264
+ continue;
265
+ }
266
+ const f = resolveClassRef(el, imports, selfFileId, localClasses);
267
+ if (f)
268
+ out.push(f);
269
+ else if (mode === 'import')
270
+ diag.unresolvedImports.add(el.getText().slice(0, 60));
271
+ // `exports` re-export providers/tokens; an unresolved one is benign (it's a
272
+ // token, already covered by `providers`) — resolve silently, no diag.
273
+ }
274
+ return out;
275
+ }
276
+ // The role a class declares, from its decorators + implemented interfaces.
277
+ function roleOfClass(cls, decoNames) {
278
+ if (decoNames.includes('Controller'))
279
+ return 'controller';
280
+ if (decoNames.includes('Resolver'))
281
+ return 'resolver';
282
+ if (decoNames.includes('Module'))
283
+ return 'module';
284
+ if (decoNames.includes('Injectable') || decoNames.includes('Catch')) {
285
+ for (const impl of cls.getImplements()) {
286
+ const name = rootIdentifier(impl.getExpression());
287
+ if (name && INTERFACE_ROLE[name])
288
+ return INTERFACE_ROLE[name];
289
+ }
290
+ return 'service';
291
+ }
292
+ return undefined;
293
+ }
294
+ // The root identifier of a constructor parameter's TYPE (`private u: UsersService`
295
+ // → 'UsersService'; `r: Repository<User>` → 'Repository'). Undefined for a
296
+ // primitive / inline / union type with no leading type reference.
297
+ function paramTypeName(param) {
298
+ const tn = param.getTypeNode();
299
+ if (!tn || tn.getKind() !== SyntaxKind.TypeReference)
300
+ return undefined;
301
+ return rootIdentifier(tn.getTypeName());
302
+ }
303
+ // Keep the highest-priority candidate role per file (deterministic, lexical
304
+ // tiebreak) — mirrors the RN/node addRole + the contribute-step's module collapse.
305
+ function addRole(map, fileId, role) {
306
+ const cur = map.get(fileId);
307
+ if (cur === undefined ||
308
+ ROLE_PRIORITY[role] > ROLE_PRIORITY[cur] ||
309
+ (ROLE_PRIORITY[role] === ROLE_PRIORITY[cur] && role < cur)) {
310
+ map.set(fileId, role);
311
+ }
312
+ }
313
+ function addEdge(edges, from, to, relation) {
314
+ if (from === to)
315
+ return; // intra-file DI collapses; the step drops self-edges too
316
+ const key = `${from}→${to}`;
317
+ if (!edges.has(key)) {
318
+ edges.set(key, { source: from, target: to, kind: 'calls', metadata: { framework: 'nest', relation } });
319
+ }
320
+ }
321
+ function inScope(fileId, rootPath) {
322
+ if (rootPath === '')
323
+ return true;
324
+ return fileId === rootPath || fileId.startsWith(`${rootPath}/`);
325
+ }
326
+ // Deterministic slug for a group id (camelCase → kebab, drop non-alnum).
327
+ function slugify(s) {
328
+ return s
329
+ .replace(/([a-z0-9])([A-Z])/g, '$1-$2')
330
+ .toLowerCase()
331
+ .replace(/[^a-z0-9]+/g, '-')
332
+ .replace(/^-+|-+$/g, '');
333
+ }
334
+ // Humanize a @Module class name into a subsystem label: drop the trailing
335
+ // `Module`, split camelCase, title-case (`UsersModule` → 'Users', 'AppModule' →
336
+ // 'App'). Falls back to the class name when stripping leaves nothing.
337
+ function humanizeModuleName(className) {
338
+ const base = className.replace(/Module$/, '') || className;
339
+ const words = base
340
+ .replace(/([a-z0-9])([A-Z])/g, '$1 $2')
341
+ .replace(/[_\-.]+/g, ' ')
342
+ .trim()
343
+ .split(/\s+/)
344
+ .filter(Boolean);
345
+ if (words.length === 0)
346
+ return className;
347
+ return words.map((w) => w.charAt(0).toUpperCase() + w.slice(1)).join(' ');
348
+ }
349
+ // The first directory segment of a file id (for group-id collision disambiguation).
350
+ function dirSegment(fileId) {
351
+ const slash = fileId.indexOf('/');
352
+ return slash > 0 ? slugify(fileId.slice(0, slash)) : 'root';
353
+ }
354
+ function uniqueSorted(ids) {
355
+ return [...new Set(ids)].sort();
356
+ }
357
+ // ---------------------------------------------------------------------------
358
+ // The full analysis.
359
+ function analyzeNest(ctx) {
360
+ const { repoDir, rootPath } = ctx;
361
+ const project = buildExtractionProject(repoDir);
362
+ addAllSourceFiles(project, repoDir);
363
+ const fileById = new Map();
364
+ for (const sf of project.getSourceFiles())
365
+ fileById.set(toId(repoDir, sf.getFilePath()), sf);
366
+ // Pre-pass: per-file import maps + locally-declared class names (so a class
367
+ // referenced without an import — co-located — still resolves to its file).
368
+ const importMaps = new Map();
369
+ const localClasses = new Map();
370
+ for (const [fileId, sf] of fileById) {
371
+ if (!inScope(fileId, rootPath))
372
+ continue;
373
+ importMaps.set(fileId, buildImportNameMap(sf, repoDir));
374
+ const names = new Set();
375
+ for (const c of sf.getClasses()) {
376
+ const n = c.getName();
377
+ if (n)
378
+ names.add(n);
379
+ }
380
+ localClasses.set(fileId, names);
381
+ }
382
+ const roleByFile = new Map();
383
+ const edges = new Map();
384
+ const moduleDecls = [];
385
+ const diag = {
386
+ unresolvedProviders: new Set(),
387
+ dynamicProviders: 0,
388
+ unresolvedImports: new Set(),
389
+ unresolvedInjections: new Set(),
390
+ };
391
+ for (const [fileId, sf] of fileById) {
392
+ if (!inScope(fileId, rootPath))
393
+ continue;
394
+ const imports = importMaps.get(fileId);
395
+ const locals = localClasses.get(fileId);
396
+ for (const cls of sf.getClasses()) {
397
+ const decoNames = cls.getDecorators().map(decoratorName);
398
+ // Role from the class's own decorators/interfaces.
399
+ const role = roleOfClass(cls, decoNames);
400
+ if (role)
401
+ addRole(roleByFile, fileId, role);
402
+ // @Module → a grouping prior + authoritative roles + import edges.
403
+ if (decoNames.includes('Module')) {
404
+ const decl = parseModule(cls, fileId, imports, locals, diag);
405
+ if (decl) {
406
+ moduleDecls.push(decl);
407
+ // The @Module declaration is AUTHORITATIVE about controller vs provider,
408
+ // even for plain (un-decorated) classes — tag them by membership. A
409
+ // stronger decorator-derived role (guard/interceptor/pipe) still wins
410
+ // by priority via addRole.
411
+ for (const f of decl.controllerFiles)
412
+ addRole(roleByFile, f, 'controller');
413
+ for (const f of decl.providerFiles)
414
+ addRole(roleByFile, f, 'service');
415
+ // Module-import wiring → calls edges (this module file → imported module).
416
+ for (const imp of decl.importFiles)
417
+ addEdge(edges, fileId, imp, 'module-import');
418
+ }
419
+ }
420
+ // DI graph: a Nest-managed class's constructor params are its dependencies.
421
+ if (decoNames.some((d) => NEST_STEREOTYPES.has(d))) {
422
+ collectConstructorEdges(cls, fileId, imports, locals, edges, diag);
423
+ }
424
+ }
425
+ }
426
+ // Assign final, collision-free group ids ORDER-INDEPENDENTLY: two
427
+ // @Module classes can share a name across files, and the dedup must not depend
428
+ // on ts-morph's getSourceFiles() iteration order (it would yield a different id
429
+ // set run-to-run, breaking the grouping-stability invariant). Done as a separate
430
+ // pass over the decls sorted by fileId.
431
+ assignGroupIds(moduleDecls);
432
+ // Build the grouping prior. fileIds = the @Module file + its controllers,
433
+ // providers, exports (NOT its imports — those belong to the imported modules'
434
+ // own groups). Sorted for snapshot stability.
435
+ const groups = moduleDecls
436
+ .map((m) => ({
437
+ id: m.id,
438
+ label: m.label,
439
+ fileIds: uniqueSorted([m.fileId, ...m.controllerFiles, ...m.providerFiles, ...m.exportFiles]),
440
+ }))
441
+ .sort((a, b) => (a.id < b.id ? -1 : a.id > b.id ? 1 : 0));
442
+ const roles = new Map();
443
+ for (const [fileId, role] of roleByFile) {
444
+ roles.set(fileId, {
445
+ role,
446
+ kind: ROLE_KIND[role],
447
+ priority: ROLE_PRIORITY[role],
448
+ metadata: { framework: 'nest' },
449
+ });
450
+ }
451
+ const sortedEdges = [...edges.values()].sort((a, b) => a.source < b.source ? -1 : a.source > b.source ? 1 : a.target < b.target ? -1 : a.target > b.target ? 1 : 0);
452
+ // Positive signal for validation.
453
+ if (groups.length > 0 || roleByFile.size > 0) {
454
+ console.log(` [nest] ${moduleDecls.length} @Module(s) → ${groups.length} group(s) · ${roleByFile.size} role(s) · ${sortedEdges.length} DI edge(s)`);
455
+ }
456
+ // No silent caps (locked): log everything that degraded.
457
+ if (diag.unresolvedProviders.size > 0 ||
458
+ diag.dynamicProviders > 0 ||
459
+ diag.unresolvedImports.size > 0 ||
460
+ diag.unresolvedInjections.size > 0) {
461
+ const parts = [];
462
+ if (diag.dynamicProviders > 0)
463
+ parts.push(`${diag.dynamicProviders} custom provider(s) (useFactory/useValue/useExisting)`);
464
+ if (diag.unresolvedProviders.size > 0) {
465
+ parts.push(`${diag.unresolvedProviders.size} unresolvable provider/token(s): ${[...diag.unresolvedProviders].sort().join(', ')}`);
466
+ }
467
+ if (diag.unresolvedInjections.size > 0) {
468
+ parts.push(`${diag.unresolvedInjections.size} unresolvable @Inject token(s): ${[...diag.unresolvedInjections].sort().join(', ')}`);
469
+ }
470
+ if (diag.unresolvedImports.size > 0) {
471
+ parts.push(`${diag.unresolvedImports.size} unresolvable/external module import(s): ${[...diag.unresolvedImports].sort().join(', ')}`);
472
+ }
473
+ console.log(` [nest] degraded: ${parts.join(' · ')} (logged, not silently dropped)`);
474
+ }
475
+ return { groups, edges: sortedEdges, roles };
476
+ }
477
+ // Parse a `@Module({...})` class into its grouping declaration.
478
+ function parseModule(cls, fileId, imports, localClasses, diag) {
479
+ const className = cls.getName() ?? '';
480
+ const deco = cls.getDecorators().find((d) => decoratorName(d) === 'Module');
481
+ if (!deco)
482
+ return null;
483
+ const arg = deco.getArguments()[0];
484
+ let controllerFiles = [];
485
+ let providerFiles = [];
486
+ let exportFiles = [];
487
+ let importFiles = [];
488
+ if (arg && arg.getKind() === SyntaxKind.ObjectLiteralExpression) {
489
+ const obj = arg;
490
+ controllerFiles = readArrayProp(obj, 'controllers', 'class', imports, fileId, localClasses, diag);
491
+ providerFiles = readArrayProp(obj, 'providers', 'provider', imports, fileId, localClasses, diag);
492
+ exportFiles = readArrayProp(obj, 'exports', 'class', imports, fileId, localClasses, diag);
493
+ importFiles = readArrayProp(obj, 'imports', 'import', imports, fileId, localClasses, diag);
494
+ }
495
+ // The bare id slug from the class name (or the file basename if anonymous).
496
+ // The final, de-collided id is assigned later by assignGroupIds (order-
497
+ // independent) — NEVER an index here, so it is stable across snapshots.
498
+ const base = className || (fileId.split('/').pop() ?? 'module').replace(/\.[^.]+$/, '');
499
+ const baseSlug = slugify(base) || 'module';
500
+ return {
501
+ fileId,
502
+ baseSlug,
503
+ id: baseSlug, // provisional; finalized by assignGroupIds
504
+ label: className ? humanizeModuleName(className) : humanizeModuleName(base),
505
+ controllerFiles,
506
+ providerFiles,
507
+ exportFiles,
508
+ importFiles,
509
+ };
510
+ }
511
+ // Assign each @Module its final, collision-free group id ORDER-INDEPENDENTLY
512
+ //. Duplicate @Module class names (→ same `baseSlug`) are disambiguated
513
+ // deterministically: process the decls by ascending fileId so the SMALLEST fileId
514
+ // wins the bare slug, and later collisions take a `-<dirSegment>` then `-<n>`
515
+ // suffix. Because the order is the (stable) fileId order — not ts-morph's
516
+ // getSourceFiles() iteration order — the id set is identical run-to-run.
517
+ function assignGroupIds(decls) {
518
+ const taken = new Set();
519
+ const byFileId = [...decls].sort((a, b) => (a.fileId < b.fileId ? -1 : a.fileId > b.fileId ? 1 : 0));
520
+ for (const decl of byFileId) {
521
+ let id = decl.baseSlug;
522
+ if (taken.has(id))
523
+ id = `${decl.baseSlug}-${dirSegment(decl.fileId)}`;
524
+ let n = 2;
525
+ while (taken.has(id))
526
+ id = `${decl.baseSlug}-${n++}`;
527
+ taken.add(id);
528
+ decl.id = id;
529
+ }
530
+ }
531
+ // Emit DI edges from a Nest-managed class's constructor: consumer file → each
532
+ // injected provider's file (kind 'calls'). Resolves the param TYPE (the usual
533
+ // `constructor(private x: FooService)`), and an `@Inject(Token)` decorator —
534
+ // falling back to the param type so `@Inject(forwardRef(() => X)) x: X` still
535
+ // resolves. A token that resolves to nothing (string token / useFactory-only
536
+ // provider) DEGRADES + logs.
537
+ function collectConstructorEdges(cls, fileId, imports, localClasses, edges, diag) {
538
+ const ctor = cls.getConstructors()[0];
539
+ if (!ctor)
540
+ return;
541
+ for (const param of ctor.getParameters()) {
542
+ const inject = param.getDecorators().find((d) => decoratorName(d) === 'Inject');
543
+ if (inject) {
544
+ let file = null;
545
+ const tokenArg = inject.getArguments()[0];
546
+ if (tokenArg && tokenArg.getKind() === SyntaxKind.Identifier) {
547
+ file = resolveClassRef(tokenArg, imports, fileId, localClasses);
548
+ }
549
+ if (!file) {
550
+ const typeName = paramTypeName(param);
551
+ if (typeName)
552
+ file = imports.get(typeName) ?? (localClasses.has(typeName) ? fileId : null);
553
+ }
554
+ if (file)
555
+ addEdge(edges, fileId, file, 'di');
556
+ else
557
+ diag.unresolvedInjections.add((tokenArg?.getText() ?? '<inject>').slice(0, 60));
558
+ continue;
559
+ }
560
+ const typeName = paramTypeName(param);
561
+ if (!typeName)
562
+ continue;
563
+ // A plain type injection: only emit when the type resolves to an INTERNAL
564
+ // class file. An external (`ConfigService`) / primitive type stays off-graph
565
+ // — that's correct, not a dropped capability, so no diag here.
566
+ const file = imports.get(typeName) ?? (localClasses.has(typeName) ? fileId : null);
567
+ if (file)
568
+ addEdge(edges, fileId, file, 'di');
569
+ }
570
+ }
571
+ function getAnalysis(ctx) {
572
+ let a = ANALYSIS_CACHE.get(ctx);
573
+ if (!a) {
574
+ a = analyzeNest(ctx);
575
+ ANALYSIS_CACHE.set(ctx, a);
576
+ }
577
+ return a;
578
+ }
579
+ // ---------------------------------------------------------------------------
580
+ // The adapter.
581
+ export const nestAdapter = {
582
+ name: 'nest',
583
+ async detect(ctx) {
584
+ const { base, rootPath } = resolveBase(ctx);
585
+ return scoreNest(gatherNestSignals(base), rootPath);
586
+ },
587
+ // one grouping prior per @Module (controllers + providers + exports).
588
+ // The contribute-step makes each its own subsystem, AUTHORITATIVE over directory
589
+ // + workspace-package grouping. No classificationsNeeded: unresolved providers /
590
+ // tokens degrade + log inside the analysis (they're not LLM-classifiable into a
591
+ // class file), so the deferred-classification channel stays empty.
592
+ async groupingPrior(ctx) {
593
+ return { groups: getAnalysis(ctx).groups };
594
+ },
595
+ // the DI graph (file-id space; the step resolves to modules, drops
596
+ // self-edges, dedupes, 8-verb-validates). kind 'calls' only.
597
+ async syntheticEdges(ctx) {
598
+ return getAnalysis(ctx).edges;
599
+ },
600
+ // Controller/Resolver → gateway; Service/Guard/Interceptor/Pipe/
601
+ // Module → service. METADATA; the module's `kind` is unchanged.
602
+ async roleTags(ctx) {
603
+ return getAnalysis(ctx).roles;
604
+ },
605
+ // The hooks READ SOURCE (decorators, constructors), so declare the source paths
606
+ // the diff-driven hosted walk must treat as framework-relevant. Never-store-
607
+ // source holds: read server-side, persist only the derived groups/edges/roles.
608
+ scansSourcePath(path) {
609
+ const ext = path.split('.').pop();
610
+ return ext !== undefined && SOURCE_EXT_SET.has(ext);
611
+ },
612
+ };
613
+ //# sourceMappingURL=nest.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nest.js","sourceRoot":"","sources":["../../../src/framework/nest/nest.ts"],"names":[],"mappings":"AAAA,sDAAsD;AACtD,qDAAqD;AACrD,EAAE;AACF,sEAAsE;AACtE,qEAAqE;AACrE,EAAE;AACF,iEAAiE;AACjE,8EAA8E;AAC9E,iFAAiF;AACjF,+EAA+E;AAC/E,6EAA6E;AAC7E,gFAAgF;AAChF,2EAA2E;AAC3E,qEAAqE;AACrE,EAAE;AACF,gFAAgF;AAChF,6EAA6E;AAC7E,mFAAmF;AACnF,4EAA4E;AAC5E,8EAA8E;AAC9E,0EAA0E;AAC1E,iFAAiF;AACjF,iFAAiF;AACjF,EAAE;AACF,iFAAiF;AACjF,kDAAkD;AAClD,EAAE;AACF,wDAAwD;AACxD,+DAA+D;AAC/D,8DAA8D;AAC9D,EAAE;AACF,sEAAsE;AAEtE,OAAO,EACL,UAAU,GAWX,MAAM,UAAU,CAAC;AAClB,OAAO,EACL,iBAAiB,EACjB,sBAAsB,EACtB,IAAI,GACL,MAAM,iCAAiC,C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