@akanjs/cli 3.0.0-beta.17 → 3.0.0-beta.19

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 (149) hide show
  1. package/.build-stamp +1 -1
  2. package/{CodeAgent-gjqnc2mg.js → CodeAgent-6cm97kay.js} +2 -2
  3. package/{CodeAgentRpcHost-qvwfv0n9.js → CodeAgentRpcHost-p7h6n2hp.js} +1 -1
  4. package/CodeAgentRpcListener-7p7z5dd7.js +97 -0
  5. package/{CodeTui-nd9hqvrw.js → CodeTui-za4jsm41.js} +205 -34
  6. package/{TunnelShare-r5tc2qk5.js → TunnelShare-2j6s511d.js} +2 -2
  7. package/{agent.command-n664dtcv.js → agent.command-e0wpbbyg.js} +6 -6
  8. package/akanCode.js +7 -5
  9. package/{application.command-t5542jte.js → application.command-8wyxqc8q.js} +28 -15
  10. package/{applicationBuildRunner-x4gbfn7y.js → applicationBuildRunner-n9gzaxd0.js} +35 -10
  11. package/{applicationReleasePackager-z61ep017.js → applicationReleasePackager-vpggfqgq.js} +1 -1
  12. package/buildBatch.proc.js +3 -3
  13. package/{capacitorApp-shv3ajh5.js → capacitorApp-q3z0qht0.js} +2 -2
  14. package/{cloud.command-dk5tj39k.js → cloud.command-4zwa5dsx.js} +34 -12
  15. package/cloud.script-fwx3vb34.js +20 -0
  16. package/{code.command-88sebgnn.js → code.command-468c9d7s.js} +41 -19
  17. package/commandManifest.json +1 -1
  18. package/{context.command-pqsm5jrk.js → context.command-dsnw0jby.js} +14 -14
  19. package/context.runner-rs4rj15d.js +22 -0
  20. package/{dependencyScanner-shs82ynp.js → dependencyScanner-0z2h2tks.js} +1 -1
  21. package/{devTui-gy6mendg.js → devTui-ffjsarqa.js} +3 -3
  22. package/{devTuiView-y1548wy6.js → devTuiView-1q1mdgrv.js} +1 -1
  23. package/{guideline.command-rpc2emw8.js → guideline.command-vhw13pqr.js} +8 -13
  24. package/guidelines/agentRule/agentRule.instruction.md +27 -10
  25. package/guidelines/conventions/conventions.instruction.md +53 -26
  26. package/guidelines/queryRule/queryRule.instruction.md +17 -7
  27. package/guidelines/runtimeRule/runtimeRule.instruction.md +74 -0
  28. package/guidelines/ssrRule/ssrRule.instruction.md +4 -2
  29. package/guidelines/transportRule/transportRule.instruction.md +10 -8
  30. package/guidelines/workspaceRecipes/workspaceRecipes.instruction.md +4 -3
  31. package/incrementalBuilder.proc.js +3 -2
  32. package/{index-4n4821gp.js → index-10dkrrww.js} +4 -4
  33. package/{index-bzakk0c2.js → index-14zrtgfa.js} +5 -3
  34. package/{index-v17gj504.js → index-18zybgkc.js} +2 -2
  35. package/{index-qh7brn20.js → index-22xtgmhn.js} +6 -2
  36. package/{index-qhtj9y6j.js → index-2446k7b4.js} +74 -21
  37. package/{index-g9zghs4h.js → index-3jrp517k.js} +12 -12
  38. package/{index-vpx68e4x.js → index-4m929vvn.js} +2 -2
  39. package/{index-4cvpzkq6.js → index-53176s7j.js} +3 -3
  40. package/{index-jwrpsrg3.js → index-667w0yah.js} +1 -1
  41. package/{index-3mg4h788.js → index-7ep8qtvp.js} +2 -2
  42. package/{index-w8kmx1b6.js → index-89hy31kf.js} +30 -7
  43. package/index-9d6nvkz2.js +656 -0
  44. package/index-9dp031by.js +12 -0
  45. package/{index-zn8qgeqx.js → index-a1w6934z.js} +3 -3
  46. package/{index-p0tew3fq.js → index-ab0c38ea.js} +10 -5
  47. package/index-bc88j1ry.js +1166 -0
  48. package/{index-ns128c4q.js → index-bftkz6cp.js} +280 -73
  49. package/{index-kcxmv48c.js → index-bhtmj233.js} +4 -1
  50. package/{index-kvzjda3v.js → index-bwf965h6.js} +5 -5
  51. package/{index-p4p9t45x.js → index-crmeqnmf.js} +56 -44
  52. package/{index-8k16atqy.js → index-d2242ksy.js} +23 -6
  53. package/{index-2sq06vv0.js → index-e4v6vhxq.js} +417 -105
  54. package/{index-xjc7gg65.js → index-esk82rvk.js} +23 -33
  55. package/{index-sn7dnzq4.js → index-kwaq3n9n.js} +1 -1
  56. package/{index-gm76f0qb.js → index-n3cv0tm4.js} +1 -1
  57. package/{index-6na0sd2b.js → index-qdgzsnhg.js} +5 -2
  58. package/{index-twq9p2sp.js → index-s5rhm04y.js} +0 -6
  59. package/{index-n8kt2wh6.js → index-sq2dzkzm.js} +35 -10
  60. package/{index-myj01w9r.js → index-srmay5jw.js} +15 -2
  61. package/{index-2pm1j01n.js → index-txr7dj2g.js} +4 -4
  62. package/{index-3cymrzsb.js → index-vqx8bdxz.js} +17 -3
  63. package/{index-te0y1c0m.js → index-zqgj2rt2.js} +12 -7
  64. package/index.js +21 -21
  65. package/{library.command-m8p2r1dh.js → library.command-cqr175dy.js} +3 -3
  66. package/{localRegistry.command-yppdqrxv.js → localRegistry.command-49z55qqz.js} +9 -9
  67. package/{module.command-mfzvqt0n.js → module.command-9p8mm3b0.js} +5 -5
  68. package/{package.command-cgp2p2v5.js → package.command-wxyz909t.js} +5 -5
  69. package/package.json +2 -2
  70. package/{page.command-taenb02b.js → page.command-gsrsfqqs.js} +3 -3
  71. package/{primitive.command-7kpncmkk.js → primitive.command-ns1mptje.js} +6 -6
  72. package/{prompter-9mn3kp36.js → prompter-1f8d9pcc.js} +1 -1
  73. package/{quality.command-1ar94hrw.js → quality.command-e76k2q9k.js} +18 -17
  74. package/{repair.command-n08t6j8p.js → repair.command-pkrsm3cw.js} +5 -5
  75. package/{routeSourceValidator-apyqw7wk.js → routeSourceValidator-7ycnfz0e.js} +0 -6
  76. package/{scalar.command-mq8qfp4t.js → scalar.command-0cpt3fc8.js} +4 -4
  77. package/skills/akan-code/SKILL.md +122 -0
  78. package/skills/akan-module/SKILL.md +2 -2
  79. package/skills/akan-store/SKILL.md +6 -2
  80. package/{subspace.command-jqv5n79w.js → subspace.command-fktpwp0g.js} +20 -10
  81. package/templates/__scalar/__model__/__model__.abstract.md.template +8 -0
  82. package/templates/appSample/lib/__scalar/workHistory/workHistory.abstract.ts +8 -39
  83. package/templates/appSample/lib/_noti/noti.abstract.ts +6 -29
  84. package/templates/appSample/lib/task/task.abstract.ts +12 -32
  85. package/templates/appSample/lib/task/task.signal.spec.ts +15 -18
  86. package/templates/appSample/lib/task/task.signal.test.ts +15 -1
  87. package/templates/appSample/lib/task/task.signal.ts +1 -1
  88. package/templates/appSample/srvkit/AuthGuard.ts +4 -1
  89. package/templates/appSample/srvkit/SessionInternalArg.ts +3 -1
  90. package/templates/crudPages/[__model__Id]/edit/page.tsx +2 -1
  91. package/templates/crudPages/[__model__Id]/page.tsx +2 -1
  92. package/templates/crudPages/new/page.tsx +2 -1
  93. package/templates/crudPages/page.tsx +2 -1
  94. package/templates/crudSinglePage/page.tsx +2 -1
  95. package/templates/localDev/docker-compose.yaml.template +3 -14
  96. package/templates/module/__model__.signal.ts +12 -4
  97. package/templates/pkgRoot/tsconfig.json.template +2 -7
  98. package/templates/service/__model__.abstract.md.template +8 -0
  99. package/{tunnel.command-ht2es78c.js → tunnel.command-d5jy9gk8.js} +4 -4
  100. package/{workflow.command-tvz4nm9n.js → workflow.command-6tkcysmx.js} +9 -9
  101. package/{workspace.command-txv1yv5e.js → workspace.command-gv84eh1p.js} +25 -24
  102. package/cloud.script-ch3xrw3s.js +0 -20
  103. package/context.runner-bys6ykcp.js +0 -22
  104. package/guidelines/agentRule/agentRule.generate.json +0 -31
  105. package/guidelines/componentRule/componentRule.generate.json +0 -31
  106. package/guidelines/conventions/conventions.generate.json +0 -25
  107. package/guidelines/cssRule/cssRule.generate.json +0 -31
  108. package/guidelines/docPageRule/docPageRule.generate.json +0 -31
  109. package/guidelines/docPageRule/docPageRule.instruction.md +0 -25
  110. package/guidelines/docSyncRule/docSyncRule.generate.json +0 -31
  111. package/guidelines/docSyncRule/docSyncRule.instruction.md +0 -25
  112. package/guidelines/enumConstant/enumConstant.generate.json +0 -31
  113. package/guidelines/enumConstant/enumConstant.instruction.md +0 -28
  114. package/guidelines/fieldRule/fieldRule.generate.json +0 -31
  115. package/guidelines/framework/framework.generate.json +0 -32
  116. package/guidelines/mcpRule/mcpRule.generate.json +0 -35
  117. package/guidelines/modelConstant/modelConstant.generate.json +0 -32
  118. package/guidelines/modelDictionary/modelDictionary.generate.json +0 -32
  119. package/guidelines/modelDocument/modelDocument.generate.json +0 -31
  120. package/guidelines/modelService/modelService.generate.json +0 -31
  121. package/guidelines/modelSignal/modelSignal.generate.json +0 -31
  122. package/guidelines/modelStore/modelStore.generate.json +0 -31
  123. package/guidelines/modelTemplate/modelTemplate.generate.json +0 -31
  124. package/guidelines/modelUnit/modelUnit.generate.json +0 -31
  125. package/guidelines/modelUtil/modelUtil.generate.json +0 -31
  126. package/guidelines/modelView/modelView.generate.json +0 -31
  127. package/guidelines/modelZone/modelZone.generate.json +0 -31
  128. package/guidelines/moduleCodegen/moduleCodegen.generate.json +0 -31
  129. package/guidelines/moduleCodegen/moduleCodegen.instruction.md +0 -28
  130. package/guidelines/moduleOverview/moduleOverview.generate.json +0 -31
  131. package/guidelines/queryRule/queryRule.generate.json +0 -31
  132. package/guidelines/recipeRule/recipeRule.generate.json +0 -31
  133. package/guidelines/runtimeRule/runtimeRule.generate.json +0 -25
  134. package/guidelines/scalarConstant/scalarConstant.generate.json +0 -32
  135. package/guidelines/scalarDictionary/scalarDictionary.generate.json +0 -32
  136. package/guidelines/scalarModule/scalarModule.generate.json +0 -31
  137. package/guidelines/sharedUiUsage/sharedUiUsage.generate.json +0 -31
  138. package/guidelines/sharedUiUsage/sharedUiUsage.instruction.md +0 -25
  139. package/guidelines/ssrRule/ssrRule.generate.json +0 -31
  140. package/guidelines/transportRule/transportRule.generate.json +0 -31
  141. package/guidelines/utilUiUsage/utilUiUsage.generate.json +0 -31
  142. package/guidelines/utilUiUsage/utilUiUsage.instruction.md +0 -25
  143. package/guidelines/workspaceOnboarding/workspaceOnboarding.generate.json +0 -24
  144. package/guidelines/workspaceRecipes/workspaceRecipes.generate.json +0 -34
  145. package/index-57p9p179.js +0 -461
  146. package/index-qt8dqgnf.js +0 -250
  147. package/templates/__scalar/__model__/__model__.abstract.md +0 -28
  148. package/templates/module/__model__.abstract.md +0 -28
  149. package/templates/service/__model__.abstract.md +0 -28
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  AppExecutor,
4
4
  LibExecutor
5
- } from "./index-p4p9t45x.js";
5
+ } from "./index-crmeqnmf.js";
6
6
 
7
7
  // pkgs/@akanjs/devkit/workflow/utils.ts
8
8
  var jsonText = (value, { trailingNewline = true } = {}) => `${JSON.stringify(value, null, 2)}${trailingNewline ? `
@@ -416,6 +416,7 @@ var renderPrimitiveWriteReport = (report) => [
416
416
  `);
417
417
  var renderPrimitiveReport = (report, format = "markdown") => format === "json" ? jsonText(report) : renderPrimitiveWriteReport(report);
418
418
  // pkgs/@akanjs/devkit/workflow/executor.ts
419
+ import { capitalize } from "akanjs/common";
419
420
  import ts3 from "typescript";
420
421
 
421
422
  // pkgs/@akanjs/devkit/workflow/moduleIndex.ts
@@ -531,20 +532,24 @@ var normalizeFieldType = (typeName) => {
531
532
  };
532
533
  return normalizedTypes[typeName.toLowerCase()] ?? typeName;
533
534
  };
534
- var ensureBaseTypeImport = (content, typeName) => {
535
- if (typeName !== "Int" && typeName !== "Float")
536
- return content;
537
- const source = sourceFileFor("constant.ts", content);
538
- const baseImport = findNamedImport(source, "akanjs/base");
539
- if (baseImport) {
540
- if (baseImport.names.includes(typeName))
535
+ var ensureNamedImport = (content, moduleSpecifier, name) => {
536
+ const source = sourceFileFor("source.ts", content);
537
+ const namedImport = findNamedImport(source, moduleSpecifier);
538
+ if (namedImport) {
539
+ if (namedImport.names.includes(name))
541
540
  return content;
542
- const nextNames = [...baseImport.names, typeName].sort();
543
- return spliceText(content, baseImport.namedBindingsStart, baseImport.namedBindingsEnd, `{ ${nextNames.join(", ")} }`);
541
+ const nextNames = [...namedImport.names, name].sort();
542
+ return spliceText(content, namedImport.namedBindingsStart, namedImport.namedBindingsEnd, `{ ${nextNames.join(", ")} }`);
544
543
  }
545
- return `import { ${typeName} } from "akanjs/base";
544
+ return `import { ${name} } from "${moduleSpecifier}";
546
545
  ${content}`;
547
546
  };
547
+ var ensureBaseImport = (content, name) => ensureNamedImport(content, "akanjs/base", name);
548
+ var ensureBaseTypeImport = (content, typeName) => {
549
+ if (typeName !== "Int" && typeName !== "Float")
550
+ return content;
551
+ return ensureBaseImport(content, typeName);
552
+ };
548
553
  var numericDefault = (typeName, rawDefault) => {
549
554
  if (typeof rawDefault === "number") {
550
555
  if (!Number.isFinite(rawDefault))
@@ -572,16 +577,16 @@ var booleanDefault = (rawDefault) => {
572
577
  };
573
578
  var dateDefault = (rawDefault) => {
574
579
  if (typeof rawDefault === "number" && Number.isFinite(rawDefault))
575
- return `new Date(${rawDefault})`;
580
+ return `() => dayjs(${rawDefault})`;
576
581
  if (typeof rawDefault !== "string")
577
582
  return null;
578
583
  const trimmed = rawDefault.trim();
579
584
  if (!trimmed)
580
585
  return null;
581
586
  if (trimmed === "now")
582
- return "new Date()";
587
+ return "() => dayjs()";
583
588
  if (!Number.isNaN(Date.parse(trimmed)))
584
- return `new Date(${JSON.stringify(trimmed)})`;
589
+ return `() => dayjs(${JSON.stringify(trimmed)})`;
585
590
  return null;
586
591
  };
587
592
  var coerceFieldDefault = (typeName, defaultValue, options = {}) => {
@@ -1941,6 +1946,52 @@ var addFieldUiSurfaceInspection = (plan) => {
1941
1946
  ]
1942
1947
  };
1943
1948
  };
1949
+ var addMutationActionSurfaceInspection = (plan) => {
1950
+ const module = workflowStringInput(plan.inputs.module) ?? "<module>";
1951
+ const mutation = workflowStringInput(plan.inputs.mutation) ?? "<mutation>";
1952
+ const moduleClassName = moduleComponentName(module);
1953
+ return {
1954
+ recommendations: [
1955
+ {
1956
+ code: "add-mutation-action-surface-review",
1957
+ kind: "manual-action",
1958
+ target: `*/${moduleSourcePaths(module).store}`,
1959
+ action: `Name the endpoint's guards and add its dictionary .endpoint() entry with a .desc(). After sync, fetch.${mutation} exists; write a store action only for a toast, an optimistic update, or a multi-field write, and put the control that calls it in ${moduleClassName}.Util.tsx.`,
1960
+ confidence: "medium",
1961
+ message: `Workflow apply does not write store or UI code for ${module}.${mutation}; review whether a screen should call it.`
1962
+ }
1963
+ ],
1964
+ nextActions: [
1965
+ {
1966
+ command: `akan workflow explain ${plan.workflow}`,
1967
+ reason: "Review action surface guidance before manually editing store or UI files."
1968
+ }
1969
+ ]
1970
+ };
1971
+ };
1972
+ var addSliceViewSurfaceInspection = (plan) => {
1973
+ const module = workflowStringInput(plan.inputs.module) ?? "<module>";
1974
+ const slice = workflowStringInput(plan.inputs.slice) ?? "<slice>";
1975
+ const moduleClassName = moduleComponentName(module);
1976
+ return {
1977
+ recommendations: [
1978
+ {
1979
+ code: "add-slice-view-surface-review",
1980
+ kind: "manual-action",
1981
+ target: `*/${moduleSourcePaths(module).zone}`,
1982
+ action: `Fill in the service query stub and add the dictionary .slice() entry. After sync, load fetch.init${moduleClassName}${capitalize(slice)}() in the page and pass the result to a ${moduleClassName}.Zone as an init prop.`,
1983
+ confidence: "medium",
1984
+ message: `Workflow apply does not write page or Zone code for ${module}.${slice}; review where the list should render.`
1985
+ }
1986
+ ],
1987
+ nextActions: [
1988
+ {
1989
+ command: `akan workflow explain ${plan.workflow}`,
1990
+ reason: "Review view surface guidance before manually editing Zone or page files."
1991
+ }
1992
+ ]
1993
+ };
1994
+ };
1944
1995
  var createWorkflowStepRegistry = ({
1945
1996
  workspace,
1946
1997
  createModule,
@@ -2032,12 +2083,14 @@ var createWorkflowStepRegistry = ({
2032
2083
  mutation: workflowStringInput(plan.inputs.mutation)
2033
2084
  })),
2034
2085
  [workflowStepKey("add-mutation", "update-signal")]: inspect,
2086
+ [workflowStepKey("add-mutation", "update-action-surfaces")]: async (_step, plan) => addMutationActionSurfaceInspection(plan),
2035
2087
  [workflowStepKey("add-slice", "update-service-query")]: async (_step, plan) => primitiveReportToWorkflowStepResult(await addSlice({
2036
2088
  app: workflowStringInput(plan.inputs.app),
2037
2089
  module: workflowStringInput(plan.inputs.module),
2038
2090
  slice: workflowStringInput(plan.inputs.slice)
2039
2091
  })),
2040
- [workflowStepKey("add-slice", "update-signal-slice")]: inspect
2092
+ [workflowStepKey("add-slice", "update-signal-slice")]: inspect,
2093
+ [workflowStepKey("add-slice", "connect-view-surfaces")]: async (_step, plan) => addSliceViewSurfaceInspection(plan)
2041
2094
  };
2042
2095
  };
2043
2096
  class WorkflowExecutor {
@@ -2126,7 +2179,7 @@ class WorkflowExecutor {
2126
2179
  }
2127
2180
  }
2128
2181
  // pkgs/@akanjs/devkit/workflow/plan.ts
2129
- import { capitalize } from "akanjs/common";
2182
+ import { capitalize as capitalize2 } from "akanjs/common";
2130
2183
  var surfaceModes = new Set(["infer", "include", "skip"]);
2131
2184
  var parseStringList = (value) => {
2132
2185
  if (Array.isArray(value)) {
@@ -2269,7 +2322,7 @@ var createAddFieldRecommendations = (inputs) => {
2269
2322
  kind: "placement",
2270
2323
  target: paths.constant,
2271
2324
  confidence: "high",
2272
- message: `Insert ${field}: field(${normalizedType}) in ${capitalize(module)}Input.`
2325
+ message: `Insert ${field}: field(${normalizedType}) in ${capitalize2(module)}Input.`
2273
2326
  },
2274
2327
  {
2275
2328
  code: "add-field-placement-dictionary",
@@ -2301,7 +2354,7 @@ var createAddFieldRecommendations = (inputs) => {
2301
2354
  code: "add-field-light-projection-choice",
2302
2355
  kind: "manual-action",
2303
2356
  target: paths.constant,
2304
- action: `Pass includeInLight=true when users should see ${field} in list/card data. Without it, the field can exist on ${capitalize(module)}Input but stay absent from Light${capitalize(module)} projections.`,
2357
+ action: `Pass includeInLight=true when users should see ${field} in list/card data. Without it, the field can exist on ${capitalize2(module)}Input but stay absent from Light${capitalize2(module)} projections.`,
2305
2358
  confidence: "medium",
2306
2359
  message: `${module}.${field} is not selected for list/card projection data.`
2307
2360
  }
@@ -2312,7 +2365,7 @@ var createAddFieldRecommendations = (inputs) => {
2312
2365
  kind: "placement",
2313
2366
  target: paths.constant,
2314
2367
  confidence: "high",
2315
- message: `Add ${field} to Light${capitalize(module)} projection fields.`
2368
+ message: `Add ${field} to Light${capitalize2(module)} projection fields.`
2316
2369
  }
2317
2370
  ] : [],
2318
2371
  ...surfaces && !templateRequested ? [
@@ -2329,7 +2382,7 @@ var createAddFieldRecommendations = (inputs) => {
2329
2382
  code: "add-field-ui-manual-review",
2330
2383
  kind: "manual-action",
2331
2384
  target: paths.template,
2332
- action: `After apply, verify what users can see: Template form auto-edit only runs when a generated ${module}Form hook and Layout.Template field list are present. Unit/View cards are not auto-edited, so ${field} may be stored on ${capitalize(module)} but not shown in list/card UI until you place it in the local card layout.`,
2385
+ action: `After apply, verify what users can see: Template form auto-edit only runs when a generated ${module}Form hook and Layout.Template field list are present. Unit/View cards are not auto-edited, so ${field} may be stored on ${capitalize2(module)} but not shown in list/card UI until you place it in the local card layout.`,
2333
2386
  confidence: "medium",
2334
2387
  message: `${app}:${module}.${field} may need UI review for user-visible Template, Unit, and View behavior.`
2335
2388
  },
@@ -2774,4 +2827,4 @@ for (const candidate of toolingRolloutCandidates) {
2774
2827
  if (isRestrictedCandidate(candidate))
2775
2828
  restrictedCandidates.set(candidate.packageName, candidate);
2776
2829
  }
2777
- export { jsonText, compactDiagnostics, workflowPlanApproval, createWorkflowApplyReport, workflowCommandsForPlan, workflowRunArtifactPath, writeWorkflowRunArtifact, workflowSyncDir, generatedFilePathsForTarget, writeGeneratedSyncState, readWorkflowRunArtifact, createWorkflowBaselineSummary, createWorkflowValidationRunReport, createDryRunWorkflowApplyReport, createRepairReport, createPrimitiveWriteReport, renderPrimitiveReport, sourceFile, moduleComponentName, moduleSourcePaths, generatedFilesForSync, validationCommandsForTarget, nextActionsForTarget, createPassedPrimitiveReport, scalarChangedFiles, lowerlize, bilingualLabelForField, bilingualDescriptionForField, normalizeFieldType, ensureBaseTypeImport, coerceFieldDefault, fieldExpression, viaBuilderParameterName, insertIntoObject, insertLightProjectionField, insertTemplateField, ensureEnumImport, insertEnumClass, insertDictionaryModelField, hasConstantInputField, hasDictionaryModelField, ensureConstantTypeImport, insertDictionaryEnum, parseValues, hasSourceParseErrors, hasClassMethod, insertClassMethod, hasSignalFactoryEntry, insertSignalFactoryEntry, buildAkanModuleContextIndex, addFieldUiPolicyForType, createWorkflowStepRegistry, WorkflowExecutor, listWorkflowSpecs, getWorkflowSpec, compactWorkflowInputs, createWorkflowPlan, renderWorkflowList, renderWorkflowExplain, renderWorkflowPlan, renderWorkflowApply, renderWorkflowValidation, renderRepairReport, renderWorkflowRunArtifact, toolingRolloutGate };
2830
+ export { jsonText, compactDiagnostics, workflowPlanApproval, createWorkflowApplyReport, workflowCommandsForPlan, workflowRunArtifactPath, writeWorkflowRunArtifact, workflowSyncDir, generatedFilePathsForTarget, writeGeneratedSyncState, readWorkflowRunArtifact, createWorkflowBaselineSummary, createWorkflowValidationRunReport, createDryRunWorkflowApplyReport, createRepairReport, createPrimitiveWriteReport, renderPrimitiveReport, sourceFile, moduleComponentName, moduleSourcePaths, generatedFilesForSync, validationCommandsForTarget, nextActionsForTarget, createPassedPrimitiveReport, scalarChangedFiles, lowerlize, bilingualLabelForField, bilingualDescriptionForField, normalizeFieldType, ensureNamedImport, ensureBaseImport, ensureBaseTypeImport, coerceFieldDefault, fieldExpression, viaBuilderParameterName, insertIntoObject, insertLightProjectionField, insertTemplateField, ensureEnumImport, insertEnumClass, insertDictionaryModelField, hasConstantInputField, hasDictionaryModelField, ensureConstantTypeImport, insertDictionaryEnum, parseValues, hasSourceParseErrors, hasClassMethod, insertClassMethod, hasSignalFactoryEntry, insertSignalFactoryEntry, buildAkanModuleContextIndex, addFieldUiPolicyForType, createWorkflowStepRegistry, WorkflowExecutor, listWorkflowSpecs, getWorkflowSpec, compactWorkflowInputs, createWorkflowPlan, renderWorkflowList, renderWorkflowExplain, renderWorkflowPlan, renderWorkflowApply, renderWorkflowValidation, renderRepairReport, renderWorkflowRunArtifact, toolingRolloutGate };
@@ -1,14 +1,14 @@
1
1
  // @bun
2
2
  import {
3
3
  AppExecutor
4
- } from "./index-p4p9t45x.js";
4
+ } from "./index-crmeqnmf.js";
5
5
  import {
6
6
  jsonText,
7
7
  createWorkflowBaselineSummary,
8
8
  buildAkanModuleContextIndex,
9
9
  createWorkflowStepRegistry,
10
10
  toolingRolloutGate
11
- } from "./index-qhtj9y6j.js";
11
+ } from "./index-2446k7b4.js";
12
12
  import {
13
13
  buildResourceList,
14
14
  codexMcpConfigPath,
@@ -18,32 +18,32 @@ import {
18
18
  upsertCodexMcpServerBlock,
19
19
  renderDoctorText,
20
20
  AkanContextAnalyzer
21
- } from "./index-v17gj504.js";
21
+ } from "./index-18zybgkc.js";
22
22
  import {
23
23
  isPlaceholderAppId2
24
- } from "./index-3cymrzsb.js";
24
+ } from "./index-vqx8bdxz.js";
25
25
  import {
26
26
  CommandContainer,
27
27
  runner
28
- } from "./index-6na0sd2b.js";
28
+ } from "./index-qdgzsnhg.js";
29
29
  import {
30
30
  Prompter2
31
- } from "./index-twq9p2sp.js";
31
+ } from "./index-s5rhm04y.js";
32
32
  import {
33
33
  RepairRunner
34
- } from "./index-4cvpzkq6.js";
34
+ } from "./index-53176s7j.js";
35
35
  import {
36
36
  WorkflowRunner
37
- } from "./index-2pm1j01n.js";
37
+ } from "./index-txr7dj2g.js";
38
38
  import {
39
39
  ModuleScript
40
- } from "./index-xjc7gg65.js";
40
+ } from "./index-esk82rvk.js";
41
41
  import {
42
42
  PrimitiveScript
43
- } from "./index-te0y1c0m.js";
43
+ } from "./index-zqgj2rt2.js";
44
44
  import {
45
45
  ScalarScript
46
- } from "./index-vpx68e4x.js";
46
+ } from "./index-4m929vvn.js";
47
47
  import {
48
48
  getMobileTargets
49
49
  } from "./index-47pj3aee.js";
@@ -1021,7 +1021,7 @@ ${payload}`);
1021
1021
  test: "`akan test <app-or-lib-or-pkg>` prepares the target and runs its tests.",
1022
1022
  build: "`akan build <app-name>` creates a production build after preparing generated files.",
1023
1023
  doctor: "`akan doctor --strict --format json` reports agent-readable workspace convention diagnostics and validation hints.",
1024
- "guideline show": "`akan guideline show <name>` prints an Akan codegen guideline instruction.",
1024
+ "guideline show": "`akan guideline show <name>` prints an Akan guideline instruction.",
1025
1025
  workflow: "`akan workflow list|explain|plan|apply|validate|report` lists, plans, applies, validates, and reports agent-readable Akan workflows.",
1026
1026
  "workflow list": "`akan workflow list` lists parseable read-only workflow specs.",
1027
1027
  "workflow explain": "`akan workflow explain <workflow>` explains inputs, optional surfaces, steps, and validation.",
@@ -2,12 +2,12 @@
2
2
  import {
3
3
  runner,
4
4
  script
5
- } from "./index-6na0sd2b.js";
5
+ } from "./index-qdgzsnhg.js";
6
6
  import {
7
7
  generatedFilesForSync,
8
8
  createPassedPrimitiveReport,
9
9
  scalarChangedFiles
10
- } from "./index-qhtj9y6j.js";
10
+ } from "./index-2446k7b4.js";
11
11
  import {
12
12
  pluralizeName
13
13
  } from "./index-nz8prx9g.js";
@@ -5,13 +5,13 @@ import {
5
5
  writeGeneratedSyncState,
6
6
  createRepairReport,
7
7
  renderRepairReport
8
- } from "./index-qhtj9y6j.js";
8
+ } from "./index-2446k7b4.js";
9
9
  import {
10
10
  AkanContextAnalyzer
11
- } from "./index-v17gj504.js";
11
+ } from "./index-18zybgkc.js";
12
12
  import {
13
13
  runner
14
- } from "./index-6na0sd2b.js";
14
+ } from "./index-qdgzsnhg.js";
15
15
 
16
16
  // pkgs/@akanjs/cli/repair/repair.runner.ts
17
17
  var commandForShell = (command) => command.startsWith("akan ") ? `bun run ${command}` : command;
@@ -1,6 +1,6 @@
1
1
  // @bun
2
2
  // pkgs/@akanjs/devkit/codeAgent/agent/akanCodeModel.ts
3
- var akanCodeDefaultModel2 = { provider: "deepseek", id: "deepseek-v4-flash" };
3
+ var akanCodeDefaultModel2 = { provider: "deepseek", id: "deepseek-flash" };
4
4
  var catalogueMissesImages = new Set(["deepseek/deepseek-v4-flash"]);
5
5
  var correctInputs = (model) => {
6
6
  if (!model || model.input.includes("image"))
@@ -2,10 +2,10 @@
2
2
  import {
3
3
  runner,
4
4
  script
5
- } from "./index-6na0sd2b.js";
5
+ } from "./index-qdgzsnhg.js";
6
6
  import {
7
7
  LibExecutor
8
- } from "./index-p4p9t45x.js";
8
+ } from "./index-crmeqnmf.js";
9
9
  import {
10
10
  LibSource,
11
11
  formatLibStatuses
@@ -1147,6 +1147,7 @@ var SSR_CLIENT_ALIAS_EXTERNALS = [
1147
1147
  class RouteClientBuilder {
1148
1148
  #app;
1149
1149
  #seeds;
1150
+ #graphSeeds;
1150
1151
  #knownEntries;
1151
1152
  #command;
1152
1153
  #discovery;
@@ -1154,20 +1155,22 @@ class RouteClientBuilder {
1154
1155
  constructor(options) {
1155
1156
  this.#app = options.app;
1156
1157
  this.#seeds = options.seeds;
1158
+ this.#graphSeeds = options.graphSeeds;
1157
1159
  this.#knownEntries = options.knownEntries ?? new Set;
1158
1160
  this.#command = options.command ?? "start";
1159
1161
  this.#discovery = options.discovery;
1160
1162
  this.#entries = options.entries;
1161
1163
  }
1162
1164
  async build() {
1163
- const discovered = this.#entries ?? await (this.#discovery ?? await GraphClientEntryDiscovery.create(this.#app)).discover(this.#seeds);
1164
- const entries = discovered.filter((e) => !this.#knownEntries.has(e));
1165
- if (entries.length === 0)
1165
+ const discovered = this.#entries ?? await (await this.#getDiscovery()).discover(this.#seeds);
1166
+ if (discovered.every((e) => this.#knownEntries.has(e)))
1166
1167
  return this.#emptyResult(discovered);
1168
+ const entries = this.#graphSeeds ? [...new Set([...discovered, ...await (await this.#getDiscovery()).discover(this.#graphSeeds)])].sort() : discovered.filter((e) => !this.#knownEntries.has(e));
1167
1169
  const bootstrapEntries = await this.#createBootstrapEntries(entries);
1168
1170
  const browserBundle = await this.#buildBrowserBundle(bootstrapEntries);
1169
1171
  const ssrBundle = await this.#buildSsrBundle(bootstrapEntries);
1170
1172
  const acceptedEntries = new Set(entries);
1173
+ const routeEntries = new Set(discovered);
1171
1174
  const manifestDelta = {};
1172
1175
  const ssrModuleMap = {};
1173
1176
  const clientDeps = new Set;
@@ -1195,18 +1198,23 @@ class RouteClientBuilder {
1195
1198
  deps.add(path6.resolve(dep));
1196
1199
  const sortedDeps = [...deps].sort();
1197
1200
  clientDepsByEntry[originalEntry] = sortedDeps;
1198
- for (const dep of sortedDeps)
1199
- clientDeps.add(dep);
1201
+ if (routeEntries.has(originalEntry))
1202
+ for (const dep of sortedDeps)
1203
+ clientDeps.add(dep);
1200
1204
  }
1201
1205
  return {
1202
1206
  manifestDelta,
1203
1207
  ssrManifestDelta: { moduleLoading: null, moduleMap: ssrModuleMap },
1204
- newEntries: entries,
1208
+ newEntries: entries.filter((e) => !this.#knownEntries.has(e)),
1205
1209
  discoveredEntries: discovered,
1206
1210
  clientDeps: [...clientDeps].sort(),
1207
1211
  clientDepsByEntry
1208
1212
  };
1209
1213
  }
1214
+ async#getDiscovery() {
1215
+ this.#discovery ??= await GraphClientEntryDiscovery.create(this.#app);
1216
+ return this.#discovery;
1217
+ }
1210
1218
  #emptyResult(discoveredEntries = []) {
1211
1219
  return {
1212
1220
  manifestDelta: {},
@@ -1440,6 +1448,7 @@ var LIB_BARRELS = {
1440
1448
  cnst: { barrel: "cnst", kind: "namespace" },
1441
1449
  srv: { barrel: "srv", kind: "namespace" }
1442
1450
  };
1451
+ var GLOBAL_NAMES = new Set(["fetch"]);
1443
1452
  var DOMAIN_DENYLIST = new Set([
1444
1453
  "Map",
1445
1454
  "Set",
@@ -1642,10 +1651,11 @@ var transformSource = (source, fileName, ctx, resolveExtra) => {
1642
1651
  const sf = ts2.createSourceFile(fileName, source, ts2.ScriptTarget.Latest, true, scriptKindFor(fileName));
1643
1652
  const bound = collectBoundNames(sf);
1644
1653
  const used = collectUsedReferences(sf);
1654
+ const bareGlobals = collectBareGlobalReferences(sf);
1645
1655
  const namedBySpecifier = new Map;
1646
1656
  const namespaceImports = [];
1647
1657
  for (const name of used) {
1648
- if (bound.has(name))
1658
+ if (bound.has(name) || bareGlobals.has(name))
1649
1659
  continue;
1650
1660
  const target = targetFor(name, ctx) ?? resolveExtra?.(name) ?? null;
1651
1661
  if (!target)
@@ -1743,6 +1753,19 @@ var collectUsedReferences = (sf) => {
1743
1753
  ts2.forEachChild(sf, visit);
1744
1754
  return used;
1745
1755
  };
1756
+ var collectBareGlobalReferences = (sf) => {
1757
+ const bare = new Set;
1758
+ const visit = (node) => {
1759
+ if (ts2.isIdentifier(node) && GLOBAL_NAMES.has(node.text) && isReferencePosition(node)) {
1760
+ const parent = node.parent;
1761
+ if (!(parent && ts2.isPropertyAccessExpression(parent) && parent.expression === node))
1762
+ bare.add(node.text);
1763
+ }
1764
+ ts2.forEachChild(node, visit);
1765
+ };
1766
+ ts2.forEachChild(sf, visit);
1767
+ return bare;
1768
+ };
1746
1769
  var isReferencePosition = (node) => {
1747
1770
  const parent = node.parent;
1748
1771
  if (!parent)