reflex-agent 0.2.1 → 0.2.3

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 (179) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/app-build-manifest.json +101 -101
  3. package/.next/app-path-routes-manifest.json +11 -11
  4. package/.next/build-manifest.json +5 -5
  5. package/.next/prerender-manifest.json +3 -51
  6. package/.next/react-loadable-manifest.json +1 -1
  7. package/.next/server/app/_not-found/page.js +1 -1
  8. package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  9. package/.next/server/app/_not-found.html +1 -1
  10. package/.next/server/app/_not-found.rsc +3 -3
  11. package/.next/server/app/agents/[agentId]/page.js +1 -1
  12. package/.next/server/app/agents/[agentId]/page_client-reference-manifest.js +1 -1
  13. package/.next/server/app/api/agents/[agentId]/respond/route.js +1 -1
  14. package/.next/server/app/api/agents/[agentId]/respond/route_client-reference-manifest.js +1 -1
  15. package/.next/server/app/api/images/[rootId]/[file]/route.js +1 -1
  16. package/.next/server/app/api/images/[rootId]/[file]/route_client-reference-manifest.js +1 -1
  17. package/.next/server/app/api/oauth/callback/route.js +2 -2
  18. package/.next/server/app/api/oauth/callback/route_client-reference-manifest.js +1 -1
  19. package/.next/server/app/api/oauth/start/route.js +1 -1
  20. package/.next/server/app/api/oauth/start/route_client-reference-manifest.js +1 -1
  21. package/.next/server/app/api/roots/[id]/attachments/route.js +0 -0
  22. package/.next/server/app/api/roots/[id]/attachments/route_client-reference-manifest.js +1 -1
  23. package/.next/server/app/api/roots/[id]/chat/[topicId]/send/route.js +1 -1
  24. package/.next/server/app/api/roots/[id]/chat/[topicId]/send/route_client-reference-manifest.js +1 -1
  25. package/.next/server/app/api/roots/[id]/chat/[topicId]/stop/route.js +1 -1
  26. package/.next/server/app/api/roots/[id]/chat/[topicId]/stop/route_client-reference-manifest.js +1 -1
  27. package/.next/server/app/api/roots/[id]/chat/[topicId]/stream/route.js +2 -2
  28. package/.next/server/app/api/roots/[id]/chat/[topicId]/stream/route_client-reference-manifest.js +1 -1
  29. package/.next/server/app/api/roots/[id]/dashboard/route.js +1 -1
  30. package/.next/server/app/api/roots/[id]/dashboard/route.js.nft.json +1 -1
  31. package/.next/server/app/api/roots/[id]/dashboard/route_client-reference-manifest.js +1 -1
  32. package/.next/server/app/api/roots/[id]/suggestions/route.js +1 -1
  33. package/.next/server/app/api/roots/[id]/suggestions/route_client-reference-manifest.js +1 -1
  34. package/.next/server/app/api/utilities/[scope]/[id]/bundle.js/route_client-reference-manifest.js +1 -1
  35. package/.next/server/app/api/utilities/[scope]/[id]/host/route.js +1 -1
  36. package/.next/server/app/api/utilities/[scope]/[id]/host/route_client-reference-manifest.js +1 -1
  37. package/.next/server/app/api/utilities/[scope]/[id]/host-api.mjs/route_client-reference-manifest.js +1 -1
  38. package/.next/server/app/api/utilities/[scope]/[id]/host-ui.mjs/route_client-reference-manifest.js +1 -1
  39. package/.next/server/app/api/utilities/[scope]/[id]/iframe/route_client-reference-manifest.js +1 -1
  40. package/.next/server/app/api/utilities/[scope]/[id]/style.css/route_client-reference-manifest.js +1 -1
  41. package/.next/server/app/audit/page.js +2 -2
  42. package/.next/server/app/audit/page.js.nft.json +1 -1
  43. package/.next/server/app/audit/page_client-reference-manifest.js +1 -1
  44. package/.next/server/app/index.html +1 -1
  45. package/.next/server/app/index.rsc +3 -3
  46. package/.next/server/app/onboarding/page.js +3 -3
  47. package/.next/server/app/onboarding/page_client-reference-manifest.js +1 -1
  48. package/.next/server/app/page.js +2 -2
  49. package/.next/server/app/page.js.nft.json +1 -1
  50. package/.next/server/app/page_client-reference-manifest.js +1 -1
  51. package/.next/server/app/roots/[id]/chat/[topicId]/page.js +3 -3
  52. package/.next/server/app/roots/[id]/chat/[topicId]/page.js.nft.json +1 -1
  53. package/.next/server/app/roots/[id]/chat/[topicId]/page_client-reference-manifest.js +1 -1
  54. package/.next/server/app/roots/[id]/kb/[...slug]/page.js +3 -3
  55. package/.next/server/app/roots/[id]/kb/[...slug]/page.js.nft.json +1 -1
  56. package/.next/server/app/roots/[id]/kb/[...slug]/page_client-reference-manifest.js +1 -1
  57. package/.next/server/app/roots/[id]/page.js +3 -3
  58. package/.next/server/app/roots/[id]/page.js.nft.json +1 -1
  59. package/.next/server/app/roots/[id]/page_client-reference-manifest.js +1 -1
  60. package/.next/server/app/roots/[id]/workflows/[wfId]/page.js +2 -2
  61. package/.next/server/app/roots/[id]/workflows/[wfId]/page_client-reference-manifest.js +1 -1
  62. package/.next/server/app/roots/[id]/workflows/page.js +1 -1
  63. package/.next/server/app/roots/[id]/workflows/page.js.nft.json +1 -1
  64. package/.next/server/app/roots/[id]/workflows/page_client-reference-manifest.js +1 -1
  65. package/.next/server/app/roots/new/page.js +2 -2
  66. package/.next/server/app/roots/new/page_client-reference-manifest.js +1 -1
  67. package/.next/server/app/settings/page.js +5 -5
  68. package/.next/server/app/settings/page.js.nft.json +1 -1
  69. package/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  70. package/.next/server/app/share/[id]/file/page.js +2 -2
  71. package/.next/server/app/share/[id]/file/page_client-reference-manifest.js +1 -1
  72. package/.next/server/app/share/[id]/page.js +2 -2
  73. package/.next/server/app/share/[id]/page.js.nft.json +1 -1
  74. package/.next/server/app/share/[id]/page_client-reference-manifest.js +1 -1
  75. package/.next/server/app/utilities/[scope]/[id]/page.js +2 -2
  76. package/.next/server/app/utilities/[scope]/[id]/page.js.nft.json +1 -1
  77. package/.next/server/app/utilities/[scope]/[id]/page_client-reference-manifest.js +1 -1
  78. package/.next/server/app/utilities/page.js +4 -4
  79. package/.next/server/app/utilities/page_client-reference-manifest.js +1 -1
  80. package/.next/server/app-paths-manifest.json +11 -11
  81. package/.next/server/chunks/1105.js +1 -1
  82. package/.next/server/chunks/1223.js +1 -1
  83. package/.next/server/chunks/133.js +7 -7
  84. package/.next/server/chunks/1888.js +1 -1
  85. package/.next/server/chunks/1960.js +1 -1
  86. package/.next/server/chunks/1986.js +1 -1
  87. package/.next/server/chunks/2433.js +1 -1
  88. package/.next/server/chunks/2485.js +1 -1
  89. package/.next/server/chunks/2503.js +1 -1
  90. package/.next/server/chunks/2528.js +4 -0
  91. package/.next/server/chunks/3332.js +1 -1
  92. package/.next/server/chunks/4031.js +1 -1
  93. package/.next/server/chunks/4065.js +1 -0
  94. package/.next/server/chunks/4925.js +1 -1
  95. package/.next/server/chunks/5243.js +1 -1
  96. package/.next/server/chunks/6730.js +1 -1
  97. package/.next/server/chunks/6909.js +5 -5
  98. package/.next/server/chunks/6981.js +1 -0
  99. package/.next/server/chunks/7017.js +3 -0
  100. package/.next/server/chunks/{5401.js → 7800.js} +1 -1
  101. package/.next/server/chunks/8494.js +1 -0
  102. package/.next/server/chunks/8514.js +1 -1
  103. package/.next/server/chunks/9098.js +1 -1
  104. package/.next/server/chunks/9293.js +1 -1
  105. package/.next/server/chunks/9328.js +2 -2
  106. package/.next/server/chunks/9423.js +3 -0
  107. package/.next/server/chunks/9455.js +1 -0
  108. package/.next/server/chunks/9579.js +1 -1
  109. package/.next/server/functions-config-manifest.json +2 -2
  110. package/.next/server/middleware-build-manifest.js +1 -1
  111. package/.next/server/middleware-manifest.json +5 -5
  112. package/.next/server/middleware-react-loadable-manifest.js +1 -1
  113. package/.next/server/pages/404.html +1 -1
  114. package/.next/server/pages/500.html +1 -1
  115. package/.next/server/pages/_error.js +2 -2
  116. package/.next/server/server-reference-manifest.js +1 -1
  117. package/.next/server/server-reference-manifest.json +1 -1
  118. package/.next/static/chunks/1384-d28fb6c6c058876f.js +1 -0
  119. package/.next/static/chunks/2718-78fee2c0de782178.js +1 -0
  120. package/.next/static/chunks/4108.1ef6b5e7679b56ac.js +1 -0
  121. package/.next/static/chunks/7238-11701befb3ca3e41.js +1 -0
  122. package/.next/static/chunks/7951-590bf2004d7935b5.js +1 -0
  123. package/.next/static/chunks/8423-ffded33a21b27360.js +1 -0
  124. package/.next/static/chunks/app/{layout-c7a35075cfbfa3e3.js → layout-4fbf9f91ad45e221.js} +1 -1
  125. package/.next/static/chunks/app/onboarding/page-532b193d1c4b0dee.js +1 -0
  126. package/.next/static/chunks/app/page-e3ec0990b78ce7c7.js +1 -0
  127. package/.next/static/chunks/app/roots/[id]/chat/[topicId]/{page-1b55f68984817d29.js → page-11aad9a40def2e0d.js} +1 -1
  128. package/.next/static/chunks/app/roots/[id]/kb/[...slug]/page-d8757a85e873dfa1.js +1 -0
  129. package/.next/static/chunks/app/roots/[id]/page-76216026efb90ae0.js +1 -0
  130. package/.next/static/chunks/app/roots/[id]/workflows/[wfId]/{page-738e8e4128baa722.js → page-c4b6e3825f8626f5.js} +1 -1
  131. package/.next/static/chunks/app/roots/new/page-53ea8d2787e79425.js +1 -0
  132. package/.next/static/chunks/app/settings/page-7ebaf2b62f256538.js +1 -0
  133. package/.next/static/chunks/app/share/[id]/{page-5bbc8503cb9a9eeb.js → page-d5bbbb7e454d1375.js} +1 -1
  134. package/.next/static/chunks/app/utilities/[scope]/[id]/page-e2f928a37483d113.js +1 -0
  135. package/.next/static/chunks/app/utilities/page-839262ff726a52a2.js +1 -0
  136. package/.next/static/chunks/{webpack-2e8cca5826414cc6.js → webpack-87b4bb79fdc48563.js} +1 -1
  137. package/.next/trace +46 -46
  138. package/README.md +12 -1
  139. package/dist/bin/cli.js +1 -0
  140. package/dist/bin/cli.js.map +1 -1
  141. package/dist/bin/preload.js +22 -0
  142. package/dist/bin/preload.js.map +1 -0
  143. package/dist/lib/reflex/commands/start.js +35 -0
  144. package/dist/lib/reflex/commands/start.js.map +1 -1
  145. package/dist/lib/reflex/home.js +18 -0
  146. package/dist/lib/reflex/home.js.map +1 -0
  147. package/dist/lib/reflex/prompts/store.js +2 -2
  148. package/dist/lib/reflex/prompts/store.js.map +1 -1
  149. package/lib/server/utilities/worker-bootstrap.js +87 -0
  150. package/package.json +2 -1
  151. package/.next/server/app/roots/new.html +0 -1
  152. package/.next/server/app/roots/new.meta +0 -7
  153. package/.next/server/app/roots/new.rsc +0 -21
  154. package/.next/server/app/settings.html +0 -1
  155. package/.next/server/app/settings.meta +0 -7
  156. package/.next/server/app/settings.rsc +0 -22
  157. package/.next/server/chunks/5152.js +0 -1
  158. package/.next/server/chunks/5373.js +0 -1
  159. package/.next/server/chunks/5436.js +0 -1
  160. package/.next/server/chunks/5986.js +0 -3
  161. package/.next/server/chunks/613.js +0 -1
  162. package/.next/server/chunks/6536.js +0 -3
  163. package/.next/server/chunks/6602.js +0 -4
  164. package/.next/static/chunks/4108.d6ed46bc2fcab462.js +0 -1
  165. package/.next/static/chunks/4895-712004156efeccf2.js +0 -1
  166. package/.next/static/chunks/6489-ecde2d94e57eb8a9.js +0 -1
  167. package/.next/static/chunks/6727-d38536774bdb32d5.js +0 -1
  168. package/.next/static/chunks/6734-9d524ec49e4ba49c.js +0 -1
  169. package/.next/static/chunks/6744-dbfe3cc4ce461613.js +0 -1
  170. package/.next/static/chunks/app/onboarding/page-cde5b92b13b03c63.js +0 -1
  171. package/.next/static/chunks/app/page-ddaeffdc9a15f597.js +0 -1
  172. package/.next/static/chunks/app/roots/[id]/kb/[...slug]/page-d4358cb6042740c4.js +0 -1
  173. package/.next/static/chunks/app/roots/[id]/page-703d96bf8208af2f.js +0 -1
  174. package/.next/static/chunks/app/roots/new/page-534769dce46d0d29.js +0 -1
  175. package/.next/static/chunks/app/settings/page-86ee3d07ea1acbc7.js +0 -1
  176. package/.next/static/chunks/app/utilities/[scope]/[id]/page-72546d245b840091.js +0 -1
  177. package/.next/static/chunks/app/utilities/page-9f949d831421d314.js +0 -1
  178. /package/.next/static/{p8t15rbWhT5Rrs5fOXWZ6 → vTfQfQnAWV_hFVZjWEYvZ}/_buildManifest.js +0 -0
  179. /package/.next/static/{p8t15rbWhT5Rrs5fOXWZ6 → vTfQfQnAWV_hFVZjWEYvZ}/_ssgManifest.js +0 -0
package/README.md CHANGED
@@ -43,9 +43,20 @@ reflex chat <dir> # open a chat scoped to dir's KB
43
43
  ```sh
44
44
  pnpm install
45
45
  pnpm dev # http://localhost:3210 (Next dev server with HMR)
46
- pnpm build # produce dist/ + .next/standalone for `reflex start`
46
+ pnpm build # produce dist/ + .next/ for `reflex start`
47
47
  ```
48
48
 
49
+ ## Data directory
50
+
51
+ Reflex stores its global state (registered roots, settings, MCP config,
52
+ API keys, skills, …) in a single directory:
53
+
54
+ - **Dev (`pnpm dev`)** → `~/.reflex`
55
+ - **Prod (`reflex start` via npm-installed CLI)** → `~/.reflex-agent`
56
+
57
+ Override either by setting `REFLEX_HOME=/your/path` before launching. The
58
+ two defaults keep prod and dev experiments isolated.
59
+
49
60
  ## Layout produced
50
61
 
51
62
  ```
package/dist/bin/cli.js CHANGED
@@ -1,4 +1,5 @@
1
1
  #!/usr/bin/env node
2
+ import "./preload.js";
2
3
  import { Command } from "commander";
3
4
  import { runInit } from "../lib/reflex/commands/init.js";
4
5
  import { runWatch } from "../lib/reflex/commands/watch.js";
@@ -1 +1 @@
1
- {"version":3,"file":"cli.js","sourceRoot":"","sources":["../../bin/cli.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,MAAM,gCAAgC,CAAC;AACzD,OAAO,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAC;AAC3D,OAAO,EAAE,OAAO,EAAE,MAAM,gCAAgC,CAAC;AACzD,OAAO,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAC;AAC3D,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,OAAO,GAAG,IAAI,CAAC,OAAO,CAC1B,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAC5C,IAAI,EACJ,IAAI,EACJ,cAAc,CACf,CAAC;AACF,MAAM,GAAG,GAAG,IAAI,CAAC,KA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,CAAC,KAAK,IAAI,IAAI,SAAS,IAAI,CAAC,EAAE,CAAC;wBAC1D,OAAO,MAAM,CAAE,CAA0B,CAAC,OAAO,CAAC,CAAC;oBACrD,CAAC;oBACD,OAAO,MAAM,CAAC,CAAC,CAAC,CAAC;gBACnB,CAAC,CAAC;qBACD,IAAI,CAAC,IAAI,CAAC,CAAC;YAChB,CAAC;QACH,CAAC;QAAC,MAAM,CAAC;YACP,0BAA0B;QAC5B,CAAC;QACD,OAAO,GAAG,CAAC,OAAO,CAAC;IACrB,CAAC;IACD,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;AACrB,CAAC"}
@@ -0,0 +1,22 @@
1
+ // Sets env vars the prod CLI needs before any module reads them.
2
+ //
3
+ // ESM evaluates imports in DFS post-order, so importing this file first
4
+ // from `bin/cli.ts` guarantees these are set before sibling imports
5
+ // (registry, settings, worker-pool, etc.) read them at module-load time.
6
+ //
7
+ // Dev (`pnpm dev` → Next directly) doesn't go through bin/, so it keeps
8
+ // the `~/.reflex` default and process.cwd()-based fallbacks.
9
+ import os from "node:os";
10
+ import path from "node:path";
11
+ import { fileURLToPath } from "node:url";
12
+ if (!process.env.REFLEX_HOME) {
13
+ process.env.REFLEX_HOME = path.join(os.homedir(), ".reflex-agent");
14
+ }
15
+ // Package install root. dist/bin/preload.js → repo root is 2 levels up.
16
+ // Used by worker-pool to locate `lib/server/utilities/worker-bootstrap.js`
17
+ // without depending on `process.cwd()` (which is the user's current dir,
18
+ // not the package install location).
19
+ if (!process.env.REFLEX_PKG_ROOT) {
20
+ process.env.REFLEX_PKG_ROOT = path.resolve(path.dirname(fileURLToPath(import.meta.url)), "..", "..");
21
+ }
22
+ //# sourceMappingURL=preload.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"preload.js","sourceRoot":"","sources":["../../bin/preload.ts"],"names":[],"mappings":"AAAA,iEAAiE;AACjE,EAAE;AACF,wEAAwE;AACxE,oEAAoE;AACpE,yEAAyE;AACzE,EAAE;AACF,wEAAwE;AACxE,6DAA6D;AAC7D,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,WAAW,EAAE,CAAC;IAC7B,OAAO,CAAC,GAAG,CAAC,WAAW,GAAG,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,OAAO,EAAE,EAAE,eAAe,CAAC,CAAC;AACrE,CAAC;AAED,wEAAwE;AACxE,2EAA2E;AAC3E,yEAAyE;AACzE,qCAAqC;AACrC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC;IACjC,OAAO,CAAC,GAAG,CAAC,eAAe,GAAG,IAAI,CAAC,OAAO,CACxC,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAC5C,IAAI,EACJ,IAAI,CACL,CAAC;AACJ,CAAC"}
@@ -3,9 +3,11 @@ import { createServer } from "node:http";
3
3
  import path from "node:path";
4
4
  import { fileURLToPath } from "node:url";
5
5
  import { spawn } from "node:child_process";
6
+ import { reflexHome } from "../home.js";
6
7
  export async function runStart(opts) {
7
8
  const pkgRoot = await findPackageRoot();
8
9
  await assertBuilt(pkgRoot);
10
+ await rewriteBuildPaths(pkgRoot);
9
11
  // Lazy-import to avoid pulling Next into CLI-only commands.
10
12
  const nextMod = (await import("next"));
11
13
  const app = nextMod.default({ dev: false, dir: pkgRoot });
@@ -19,6 +21,7 @@ export async function runStart(opts) {
19
21
  server.listen(opts.port, opts.host, () => {
20
22
  const url = `http://${displayHost(opts.host)}:${opts.port}`;
21
23
  process.stdout.write(`Reflex running at ${url}\n`);
24
+ process.stdout.write(`Data dir: ${reflexHome()}\n`);
22
25
  if (opts.open)
23
26
  openBrowser(url);
24
27
  });
@@ -45,6 +48,38 @@ async function assertBuilt(pkgRoot) {
45
48
  throw new Error(`Reflex web bundle not found at ${pkgRoot}/.next. If running from source, run \`pnpm run build\` first.`);
46
49
  }
47
50
  }
51
+ /**
52
+ * Next bakes the build-time project path into `required-server-files.json`
53
+ * (`appDir`, `outputFileTracingRoot`). When the package is built in CI and
54
+ * installed on a user's machine those paths point at `/home/runner/...`
55
+ * which doesn't exist — rewrite them to the actual install location.
56
+ *
57
+ * Idempotent: if the values already match `pkgRoot`, skip the write.
58
+ */
59
+ async function rewriteBuildPaths(pkgRoot) {
60
+ const file = path.join(pkgRoot, ".next", "required-server-files.json");
61
+ let raw;
62
+ try {
63
+ raw = await fs.readFile(file, "utf8");
64
+ }
65
+ catch {
66
+ return;
67
+ }
68
+ const data = JSON.parse(raw);
69
+ let changed = false;
70
+ if (data.appDir && data.appDir !== pkgRoot) {
71
+ data.appDir = pkgRoot;
72
+ changed = true;
73
+ }
74
+ if (data.config?.outputFileTracingRoot &&
75
+ data.config.outputFileTracingRoot !== pkgRoot) {
76
+ data.config.outputFileTracingRoot = pkgRoot;
77
+ changed = true;
78
+ }
79
+ if (changed) {
80
+ await fs.writeFile(file, JSON.stringify(data, null, 2));
81
+ }
82
+ }
48
83
  function displayHost(host) {
49
84
  if (host === "0.0.0.0" || host === "::")
50
85
  return "localhost";
@@ -1 +1 @@
1
- {"version":3,"file":"start.js","sourceRoot":"","sources":["../../../../lib/reflex/commands/start.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,IAAI,EAAE,EAAE,MAAM,SAAS,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AACzC,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAQ3C,MAAM,CAAC,KAAK,UAAU,QAAQ,CAAC,IAAkB;IAC/C,MAAM,OAAO,GAAG,MAAM,eAAe,EAAE,CAAC;IACxC,MAAM,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qBAAqB,GAAG,OAAO,CAAC;QAC5C,OAAO,GAAG,IAAI,CAAC;IACjB,CAAC;IACD,IAAI,OAAO,EAAE,CAAC;QACZ,MAAM,EAAE,CAAC,SAAS,CAAC,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;IAC1D,CAAC;AACH,CAAC;AAED,SAAS,WAAW,CAAC,IAAY;IAC/B,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,IAAI;QAAE,OAAO,WAAW,CAAC;IAC5D,OAAO,IAAI,CAAC;AACd,CAAC;AAED,SAAS,WAAW,CAAC,GAAW;IAC9B,MAAM,QAAQ,GAAG,OAAO,CAAC,QAAQ,CAAC;IAClC,MAAM,GAAG,GACP,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,QAAQ,KAAK,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,UAAU,CAAC;IAC7E,MAAM,IAAI,GAAG,QAAQ,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACrE,IAAI,CAAC;QACH,KAAK,CAAC,GAAG,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC;IAChE,CAAC;IAAC,MAAM,CAAC;QACP,iCAAiC;IACnC,CAAC;AACH,CAAC"}
@@ -0,0 +1,18 @@
1
+ import os from "node:os";
2
+ import path from "node:path";
3
+ /**
4
+ * Resolve the directory where Reflex stores global state (registry, settings,
5
+ * MCP config, API keys, skills, etc.). Honors `$REFLEX_HOME` so prod and dev
6
+ * installs can be isolated.
7
+ *
8
+ * Defaults:
9
+ * - `pnpm dev` (source build) → `~/.reflex`
10
+ * - `reflex start` (npm-installed CLI) → `~/.reflex-agent` (set by bin/cli.ts)
11
+ */
12
+ export function reflexHome() {
13
+ const fromEnv = process.env.REFLEX_HOME;
14
+ if (fromEnv && fromEnv.length > 0)
15
+ return fromEnv;
16
+ return path.join(os.homedir(), ".reflex");
17
+ }
18
+ //# sourceMappingURL=home.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"home.js","sourceRoot":"","sources":["../../../lib/reflex/home.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B;;;;;;;;GAQG;AACH,MAAM,UAAU,UAAU;IACxB,MAAM,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC,WAAW,CAAC;IACxC,IAAI,OAAO,IAAI,OAAO,CAAC,MAAM,GAAG,CAAC;QAAE,OAAO,OAAO,CAAC;IAClD,OAAO,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,OAAO,EAAE,EAAE,SAAS,CAAC,CAAC;AAC5C,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import { promises as fs } from "node:fs";
2
2
  import path from "node:path";
3
- import os from "node:os";
3
+ import { reflexHome } from "../home.js";
4
4
  import { DEFAULT_TEMPLATES, TEMPLATE_NAMES, } from "./defaults.js";
5
- const PROMPTS_DIR = path.join(os.homedir(), ".reflex", "prompts");
5
+ const PROMPTS_DIR = path.join(reflexHome(), "prompts");
6
6
  function pathFor(name) {
7
7
  return path.join(PROMPTS_DIR, `${name}.md`);
8
8
  }
@@ -1 +1 @@
1
- {"version":3,"file":"store.js","sourceRoot":"","sources":["../../../../lib/reflex/prompts/store.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,IAAI,EAAE,EAAE,MAAM,SAAS,CAAC;AACzC,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,EACL,iBAAiB,EACjB,cAAc,GAEf,MAAM,eAAe,CAAC;AA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,CAAC,CAAC;IAC5C,CAAC;IACD,OAAO,CAAC,CAAC;AACX,CAAC;AAED,SAAS,UAAU,CAAC,GAAY;IAC9B,OAAO,CACL,OAAO,GAAG,KAAK,QAAQ;QACvB,GAAG,KAAK,IAAI;QACZ,MAAM,IAAI,GAAG;QACZ,GAAwB,CAAC,IAAI,KAAK,QAAQ,CAC5C,CAAC;AACJ,CAAC"}
@@ -0,0 +1,87 @@
1
+ // Static entry for every utility server-action Worker. We hand-roll plain JS
2
+ // (no TS) so we don't need a build step for this file. It:
3
+ // 1. Sets up a `reflex` host stub that RPC-calls the parent thread.
4
+ // 2. Dynamically imports the action bundle.
5
+ // 3. Awaits the named export with the args + host, returns the result.
6
+ // 4. Times out and exits cleanly.
7
+ //
8
+ // The action bundle is built by lib/server/utilities/build.ts with
9
+ // `external: ["@host/api"]`, so the bundle has `import { reflex } from
10
+ // "@host/api"`. We intercept that via Node's loader hook (worker_threads
11
+ // resolveAliases) — but since we can't easily inject one, we expose the
12
+ // host via globalThis and rewrite the bundle's import at build time?
13
+ //
14
+ // Practical solution: the build step injects a small shim file at the top
15
+ // that aliases `@host/api` to `globalThis.__reflexHost`. See build.ts.
16
+ // This bootstrap just sets up that global.
17
+
18
+ // Node treats this file as ESM (package.json has "type": "module"), so we
19
+ // use top-level `import` instead of `require`.
20
+ import { parentPort, workerData } from "node:worker_threads";
21
+
22
+ if (!parentPort) {
23
+ throw new Error("worker-bootstrap.js must be loaded as a worker_threads child");
24
+ }
25
+
26
+ const pending = new Map();
27
+ let nextRpcId = 1;
28
+
29
+ const reflex = new Proxy(
30
+ {},
31
+ {
32
+ get(_target, namespace) {
33
+ if (typeof namespace !== "string") return undefined;
34
+ return new Proxy(
35
+ {},
36
+ {
37
+ get(_t, method) {
38
+ if (typeof method !== "string") return undefined;
39
+ return (args) =>
40
+ new Promise((resolve, reject) => {
41
+ const id = nextRpcId++;
42
+ pending.set(id, { resolve, reject });
43
+ parentPort.postMessage({
44
+ type: "host-rpc",
45
+ id,
46
+ method: `${namespace}.${method}`,
47
+ args,
48
+ });
49
+ });
50
+ },
51
+ },
52
+ );
53
+ },
54
+ },
55
+ );
56
+
57
+ globalThis.__reflexHost = reflex;
58
+
59
+ parentPort.on("message", async (msg) => {
60
+ if (msg && msg.type === "host-rpc-result") {
61
+ const slot = pending.get(msg.id);
62
+ if (!slot) return;
63
+ pending.delete(msg.id);
64
+ if (msg.ok) slot.resolve(msg.result);
65
+ else slot.reject(new Error(msg.error || "rpc failed"));
66
+ return;
67
+ }
68
+ if (msg && msg.type === "invoke") {
69
+ try {
70
+ const mod = await import(workerData.bundleUrl);
71
+ const fn = mod[workerData.actionName] ?? mod.default;
72
+ if (typeof fn !== "function") {
73
+ throw new Error(
74
+ `action "${workerData.actionName}" must export a function (named export or default)`,
75
+ );
76
+ }
77
+ const result = await fn(msg.args, reflex);
78
+ parentPort.postMessage({ type: "invoke-result", ok: true, result });
79
+ } catch (err) {
80
+ parentPort.postMessage({
81
+ type: "invoke-result",
82
+ ok: false,
83
+ error: err && err.message ? err.message : String(err),
84
+ });
85
+ }
86
+ }
87
+ });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "reflex-agent",
3
- "version": "0.2.1",
3
+ "version": "0.2.3",
4
4
  "private": false,
5
5
  "description": "Local-first knowledge base built by an agent over a chosen directory.",
6
6
  "license": "MIT",
@@ -21,6 +21,7 @@
21
21
  "dist",
22
22
  ".next",
23
23
  "next.config.ts",
24
+ "lib/server/utilities/worker-bootstrap.js",
24
25
  "packages/utilities",
25
26
  "README.md",
26
27
  "LICENSE"
@@ -1 +0,0 @@
1
- <!DOCTYPE html><!--p8t15rbWhT5Rrs5fOXWZ6--><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/css/87e01f779d555d04.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/webpack-2e8cca5826414cc6.js"/><script src="/_next/static/chunks/6fe292aa-7126ff9d6732e864.js" async=""></script><script src="/_next/static/chunks/146-ccee3b26755b68c8.js" async=""></script><script src="/_next/static/chunks/main-app-ebe67847147d19aa.js" async=""></script><script src="/_next/static/chunks/4400-cdb1f7913ae34e09.js" async=""></script><script src="/_next/static/chunks/1217-407174d9b164a499.js" async=""></script><script src="/_next/static/chunks/3335-5647a38ab2cfa88d.js" async=""></script><script src="/_next/static/chunks/5097-f07f6aeee3f60a33.js" async=""></script><script src="/_next/static/chunks/app/roots/new/page-534769dce46d0d29.js" async=""></script><script src="/_next/static/chunks/9045-731ff0865352dd95.js" async=""></script><script src="/_next/static/chunks/app/layout-c7a35075cfbfa3e3.js" async=""></script><title>Reflex</title><meta name="description" content="Local-first knowledge base built by an agent."/><script src="/_next/static/chunks/polyfills-42372ed130431b0a.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><div class="h-screen flex"><aside class="w-72 shrink-0 border-r bg-muted/30 flex flex-col"><div class="px-4 py-4 flex items-center gap-2 border-b"><span class="reflex-gradient inline-flex h-7 w-7 items-center justify-center rounded-lg text-white shadow-sm"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-sparkles h-4 w-4"><path d="M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z"></path><path d="M20 3v4"></path><path d="M22 5h-4"></path><path d="M4 17v2"></path><path d="M5 18H3"></path></svg></span><div class="leading-tight"><a class="text-sm font-semibold tracking-tight hover:underline" href="/">Reflex</a><div class="text-[10px] uppercase tracking-wider text-muted-foreground">knowledge base</div></div></div><div dir="ltr" data-slot="scroll-area" class="relative flex-1" style="position:relative;--radix-scroll-area-corner-width:0px;--radix-scroll-area-corner-height:0px"><style>[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}</style><div data-radix-scroll-area-viewport="" data-slot="scroll-area-viewport" class="size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1" style="overflow-x:hidden;overflow-y:hidden"><div style="min-width:100%;display:table"><nav class="px-2 pt-3 pb-6"><div class="px-2 mb-1 text-[10px] uppercase tracking-wider text-muted-foreground">Пространства</div><div class="px-2 py-3 text-xs text-muted-foreground">Пока пусто.</div><div class="mt-2 px-2"><a data-slot="button" data-variant="ghost" data-size="sm" class="inline-flex shrink-0 items-center font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 gap-1.5 rounded-md px-3 has-[&gt;svg]:px-2.5 h-7 w-full justify-start text-xs" href="/roots/new"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-plus mr-1 h-3.5 w-3.5"><path d="M12 10v6"></path><path d="M9 13h6"></path><path d="M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z"></path></svg> Добавить пространство</a></div></nav></div></div></div><div data-orientation="horizontal" role="none" data-slot="separator" class="shrink-0 bg-border data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px"></div><div class="px-2 py-2 space-y-0.5"><a data-slot="button" data-variant="ghost" data-size="sm" class="inline-flex shrink-0 items-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 h-8 gap-1.5 rounded-md px-3 has-[&gt;svg]:px-2.5 w-full justify-start" href="/utilities"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-boxes mr-2 h-4 w-4"><path d="M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z"></path><path d="m7 16.5-4.74-2.85"></path><path d="m7 16.5 5-3"></path><path d="M7 16.5v5.17"></path><path d="M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z"></path><path d="m17 16.5-5-3"></path><path d="m17 16.5 4.74-2.85"></path><path d="M17 16.5v5.17"></path><path d="M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z"></path><path d="M12 8 7.26 5.15"></path><path d="m12 8 4.74-2.85"></path><path d="M12 13.5V8"></path></svg> Мини-приложения</a><a data-slot="button" data-variant="ghost" data-size="sm" class="inline-flex shrink-0 items-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 h-8 gap-1.5 rounded-md px-3 has-[&gt;svg]:px-2.5 w-full justify-start" href="/audit"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-file-search mr-2 h-4 w-4"><path d="M14 2v4a2 2 0 0 0 2 2h4"></path><path d="M4.268 21a2 2 0 0 0 1.727 1H18a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v3"></path><path d="m9 18-1.5-1.5"></path><circle cx="5" cy="14" r="3"></circle></svg> Аудит</a><a data-slot="button" data-variant="ghost" data-size="sm" class="inline-flex shrink-0 items-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 h-8 gap-1.5 rounded-md px-3 has-[&gt;svg]:px-2.5 w-full justify-start" href="/settings"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-settings mr-2 h-4 w-4"><path d="M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z"></path><circle cx="12" cy="12" r="3"></circle></svg> Settings</a></div></aside><main class="flex-1 min-w-0 flex flex-col"><main class="mx-auto w-full max-w-4xl flex-1 px-6 py-10"><header class="mb-8"><a data-slot="button" data-variant="ghost" data-size="sm" class="inline-flex shrink-0 items-center justify-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 h-8 gap-1.5 rounded-md px-3 has-[&gt;svg]:px-2.5 mb-2 -ml-3" href="/"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-left mr-1 h-4 w-4"><path d="m12 19-7-7 7-7"></path><path d="M19 12H5"></path></svg> Back</a><h1 class="text-3xl font-semibold tracking-tight">Add a directory</h1><p class="text-muted-foreground mt-1">Pick the directory you want Reflex to index. After it&#x27;s registered, you can run the initial analysis from the directory page.</p></header><div data-slot="card" class="flex flex-col gap-6 rounded-xl border bg-card py-6 text-card-foreground shadow-sm"><div data-slot="card-header" class="@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6"><div data-slot="card-title" class="leading-none font-semibold flex items-center justify-between gap-4"><span>Browse</span><button data-slot="button" data-variant="ghost" data-size="sm" class="inline-flex shrink-0 items-center justify-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 h-8 gap-1.5 rounded-md px-3 has-[&gt;svg]:px-2.5"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-house mr-1 h-4 w-4"><path d="M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8"></path><path d="M3 10a2 2 0 0 1 .709-1.528l7-5.999a2 2 0 0 1 2.582 0l7 5.999A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z"></path></svg> Home</button></div><form class="flex gap-2 mt-2"><input data-slot="input" class="h-9 w-full min-w-0 rounded-md border border-input bg-transparent px-3 py-1 shadow-xs transition-[color,box-shadow] outline-none selection:bg-primary selection:text-primary-foreground file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:bg-input/30 focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 font-mono text-xs" placeholder="/absolute/path" value="/home/runner"/><button data-slot="button" data-variant="secondary" data-size="default" class="inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 bg-secondary text-secondary-foreground hover:bg-secondary/80 h-9 px-4 py-2 has-[&gt;svg]:px-3" type="submit"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-refresh-cw h-4 w-4"><path d="M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8"></path><path d="M21 3v5h-5"></path><path d="M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16"></path><path d="M8 16H3v5"></path></svg></button></form></div><div data-orientation="horizontal" role="none" data-slot="separator" class="shrink-0 bg-border data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px"></div><div data-slot="card-content" class="px-2 py-2"><div dir="ltr" data-slot="scroll-area" class="relative h-[460px]" style="position:relative;--radix-scroll-area-corner-width:0px;--radix-scroll-area-corner-height:0px"><style>[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}</style><div data-radix-scroll-area-viewport="" data-slot="scroll-area-viewport" class="size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1" style="overflow-x:hidden;overflow-y:hidden"><div style="min-width:100%;display:table"><div class="px-2 py-1 flex items-center gap-2"><button data-slot="button" data-variant="ghost" data-size="sm" class="inline-flex shrink-0 items-center justify-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 gap-1.5 rounded-md px-3 has-[&gt;svg]:px-2.5 h-8" disabled=""><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevron-up mr-1 h-4 w-4"><path d="m18 15-6-6-6 6"></path></svg> Up</button><button type="button" class="flex-1 flex items-center gap-2 px-2 py-1 text-sm rounded-md hover:bg-accent bg-accent" title="/home/runner"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-open h-4 w-4 text-muted-foreground shrink-0"><path d="m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"></path></svg><span class="truncate font-mono text-xs">.</span><span class="text-muted-foreground text-[11px] truncate">(<!-- -->runner<!-- -->)</span></button><button data-slot="button" data-variant="ghost" data-size="sm" class="inline-flex shrink-0 items-center justify-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 gap-1.5 rounded-md px-3 has-[&gt;svg]:px-2.5 h-8" title="Создать папку в runner"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-folder-plus mr-1 h-4 w-4"><path d="M12 10v6"></path><path d="M9 13h6"></path><path d="M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z"></path></svg> Создать</button><label class="flex items-center gap-1 text-xs text-muted-foreground select-none"><input type="checkbox"/>hidden</label></div><div data-orientation="horizontal" role="none" data-slot="separator" class="shrink-0 bg-border data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px my-1"></div><div class="px-4 py-10 text-center text-sm text-muted-foreground">No subdirectories.</div></div></div></div></div><div data-orientation="horizontal" role="none" data-slot="separator" class="shrink-0 bg-border data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px"></div><div data-slot="card-footer" class="px-6 [.border-t]:pt-6 flex items-center justify-between gap-4"><div class="text-xs text-muted-foreground font-mono truncate">Selected: <!-- -->/home/runner</div><button data-slot="button" data-variant="default" data-size="default" class="inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&amp;_svg]:pointer-events-none [&amp;_svg]:shrink-0 [&amp;_svg:not([class*=&#x27;size-&#x27;])]:size-4 bg-primary text-primary-foreground hover:bg-primary/90 h-9 px-4 py-2 has-[&gt;svg]:px-3">Add this directory</button></div></div></main><!--$--><!--/$--></main></div><section aria-label="Notifications alt+T" tabindex="-1" aria-live="polite" aria-relevant="additions text" aria-atomic="false"></section><script src="/_next/static/chunks/webpack-2e8cca5826414cc6.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n3:I[26957,[],\"\"]\n4:I[97369,[],\"\"]\n6:I[21968,[],\"OutletBoundary\"]\n8:I[33705,[],\"AsyncMetadataOutlet\"]\na:I[21968,[],\"ViewportBoundary\"]\nc:I[21968,[],\"MetadataBoundary\"]\nd:\"$Sreact.suspense\"\nf:I[6287,[],\"\"]\n:HL[\"/_next/static/css/87e01f779d555d04.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"p8t15rbWhT5Rrs5fOXWZ6\",\"p\":\"\",\"c\":[\"\",\"roots\",\"new\"],\"i\":false,\"f\":[[[\"\",{\"children\":[\"roots\",{\"children\":[\"new\",{\"children\":[\"__PAGE__\",{}]}]}]},\"$undefined\",\"$undefined\",true],[\"\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/87e01f779d555d04.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]],\"$L2\"]}],{\"children\":[\"roots\",[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[\"new\",[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[\"__PAGE__\",[\"$\",\"$1\",\"c\",{\"children\":[\"$L5\",null,[\"$\",\"$L6\",null,{\"children\":[\"$L7\",[\"$\",\"$L8\",null,{\"promise\":\"$@9\"}]]}]]}],{},null,false]},null,false]},null,false]},null,false],[\"$\",\"$1\",\"h\",{\"children\":[null,[[\"$\",\"$La\",null,{\"children\":\"$Lb\"}],null],[\"$\",\"$Lc\",null,{\"children\":[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$d\",null,{\"fallback\":null,\"children\":\"$Le\"}]}]}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$f\",[]],\"s\":false,\"S\":true}\n"])</script><script>self.__next_f.push([1,"10:I[54400,[\"4400\",\"static/chunks/4400-cdb1f7913ae34e09.js\",\"1217\",\"static/chunks/1217-407174d9b164a499.js\",\"3335\",\"static/chunks/3335-5647a38ab2cfa88d.js\",\"5097\",\"static/chunks/5097-f07f6aeee3f60a33.js\",\"9429\",\"static/chunks/app/roots/new/page-534769dce46d0d29.js\"],\"\"]\n11:I[41372,[\"4400\",\"static/chunks/4400-cdb1f7913ae34e09.js\",\"1217\",\"static/chunks/1217-407174d9b164a499.js\",\"3335\",\"static/chunks/3335-5647a38ab2cfa88d.js\",\"5097\",\"static/chunks/5097-f07f6aeee3f60a33.js\",\"9429\",\"static/chunks/app/roots/new/page-534769dce46d0d29.js\"],\"DirectoryPicker\"]\n"])</script><script>self.__next_f.push([1,"5:[\"$\",\"main\",null,{\"className\":\"mx-auto w-full max-w-4xl flex-1 px-6 py-10\",\"children\":[[\"$\",\"header\",null,{\"className\":\"mb-8\",\"children\":[[\"$\",\"$L10\",null,{\"href\":\"/\",\"children\":[[\"$\",\"svg\",null,{\"ref\":\"$undefined\",\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":24,\"height\":24,\"viewBox\":\"0 0 24 24\",\"fill\":\"none\",\"stroke\":\"currentColor\",\"strokeWidth\":2,\"strokeLinecap\":\"round\",\"strokeLinejoin\":\"round\",\"className\":\"lucide lucide-arrow-left mr-1 h-4 w-4\",\"children\":[[\"$\",\"path\",\"1l729n\",{\"d\":\"m12 19-7-7 7-7\"}],[\"$\",\"path\",\"x3x0zl\",{\"d\":\"M19 12H5\"}],\"$undefined\"]}],\" Back\"],\"data-slot\":\"button\",\"data-variant\":\"ghost\",\"data-size\":\"sm\",\"className\":\"inline-flex shrink-0 items-center justify-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [\u0026_svg]:pointer-events-none [\u0026_svg]:shrink-0 [\u0026_svg:not([class*='size-'])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 h-8 gap-1.5 rounded-md px-3 has-[\u003esvg]:px-2.5 mb-2 -ml-3\",\"ref\":null}],[\"$\",\"h1\",null,{\"className\":\"text-3xl font-semibold tracking-tight\",\"children\":\"Add a directory\"}],[\"$\",\"p\",null,{\"className\":\"text-muted-foreground mt-1\",\"children\":\"Pick the directory you want Reflex to index. After it's registered, you can run the initial analysis from the directory page.\"}]]}],[\"$\",\"$L11\",null,{\"initialPath\":\"/home/runner\"}]]}]\n"])</script><script>self.__next_f.push([1,"b:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n7:null\n"])</script><script>self.__next_f.push([1,"9:{\"metadata\":[[\"$\",\"title\",\"0\",{\"children\":\"Reflex\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Local-first knowledge base built by an agent.\"}]],\"error\":null,\"digest\":\"$undefined\"}\n"])</script><script>self.__next_f.push([1,"e:\"$9:metadata\"\n"])</script><script>self.__next_f.push([1,"12:I[41287,[\"4400\",\"static/chunks/4400-cdb1f7913ae34e09.js\",\"1217\",\"static/chunks/1217-407174d9b164a499.js\",\"5097\",\"static/chunks/5097-f07f6aeee3f60a33.js\",\"9045\",\"static/chunks/9045-731ff0865352dd95.js\",\"7177\",\"static/chunks/app/layout-c7a35075cfbfa3e3.js\"],\"AppSidebar\"]\n13:I[43450,[\"4400\",\"static/chunks/4400-cdb1f7913ae34e09.js\",\"1217\",\"static/chunks/1217-407174d9b164a499.js\",\"5097\",\"static/chunks/5097-f07f6aeee3f60a33.js\",\"9045\",\"static/chunks/9045-731ff0865352dd95.js\",\"7177\",\"static/chunks/app/layout-c7a35075cfbfa3e3.js\"],\"Toaster\"]\n"])</script><script>self.__next_f.push([1,"2:[\"$\",\"html\",null,{\"lang\":\"en\",\"suppressHydrationWarning\":true,\"children\":[\"$\",\"body\",null,{\"children\":[[\"$\",\"div\",null,{\"className\":\"h-screen flex\",\"children\":[[\"$\",\"$L12\",null,{\"initialRoots\":[]}],[\"$\",\"main\",null,{\"className\":\"flex-1 min-w-0 flex flex-col\",\"children\":[\"$\",\"$L3\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L4\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}]]}],[\"$\",\"$L13\",null,{\"richColors\":true,\"closeButton\":true}]]}]}]\n"])</script></body></html>
@@ -1,7 +0,0 @@
1
- {
2
- "headers": {
3
- "x-nextjs-stale-time": "300",
4
- "x-nextjs-prerender": "1",
5
- "x-next-cache-tags": "_N_T_/layout,_N_T_/roots/layout,_N_T_/roots/new/layout,_N_T_/roots/new/page,_N_T_/roots/new"
6
- }
7
- }
@@ -1,21 +0,0 @@
1
- 1:"$Sreact.fragment"
2
- 3:I[26957,[],""]
3
- 4:I[97369,[],""]
4
- 6:I[21968,[],"OutletBoundary"]
5
- 8:I[33705,[],"AsyncMetadataOutlet"]
6
- a:I[21968,[],"ViewportBoundary"]
7
- c:I[21968,[],"MetadataBoundary"]
8
- d:"$Sreact.suspense"
9
- f:I[6287,[],""]
10
- :HL["/_next/static/css/87e01f779d555d04.css","style"]
11
- 0:{"P":null,"b":"p8t15rbWhT5Rrs5fOXWZ6","p":"","c":["","roots","new"],"i":false,"f":[[["",{"children":["roots",{"children":["new",{"children":["__PAGE__",{}]}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/87e01f779d555d04.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],"$L2"]}],{"children":["roots",["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["new",["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":["$L5",null,["$","$L6",null,{"children":["$L7",["$","$L8",null,{"promise":"$@9"}]]}]]}],{},null,false]},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,[["$","$La",null,{"children":"$Lb"}],null],["$","$Lc",null,{"children":["$","div",null,{"hidden":true,"children":["$","$d",null,{"fallback":null,"children":"$Le"}]}]}]]}],false]],"m":"$undefined","G":["$f",[]],"s":false,"S":true}
12
- 10:I[54400,["4400","static/chunks/4400-cdb1f7913ae34e09.js","1217","static/chunks/1217-407174d9b164a499.js","3335","static/chunks/3335-5647a38ab2cfa88d.js","5097","static/chunks/5097-f07f6aeee3f60a33.js","9429","static/chunks/app/roots/new/page-534769dce46d0d29.js"],""]
13
- 11:I[41372,["4400","static/chunks/4400-cdb1f7913ae34e09.js","1217","static/chunks/1217-407174d9b164a499.js","3335","static/chunks/3335-5647a38ab2cfa88d.js","5097","static/chunks/5097-f07f6aeee3f60a33.js","9429","static/chunks/app/roots/new/page-534769dce46d0d29.js"],"DirectoryPicker"]
14
- 5:["$","main",null,{"className":"mx-auto w-full max-w-4xl flex-1 px-6 py-10","children":[["$","header",null,{"className":"mb-8","children":[["$","$L10",null,{"href":"/","children":[["$","svg",null,{"ref":"$undefined","xmlns":"http://www.w3.org/2000/svg","width":24,"height":24,"viewBox":"0 0 24 24","fill":"none","stroke":"currentColor","strokeWidth":2,"strokeLinecap":"round","strokeLinejoin":"round","className":"lucide lucide-arrow-left mr-1 h-4 w-4","children":[["$","path","1l729n",{"d":"m12 19-7-7 7-7"}],["$","path","x3x0zl",{"d":"M19 12H5"}],"$undefined"]}]," Back"],"data-slot":"button","data-variant":"ghost","data-size":"sm","className":"inline-flex shrink-0 items-center justify-center text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50 h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5 mb-2 -ml-3","ref":null}],["$","h1",null,{"className":"text-3xl font-semibold tracking-tight","children":"Add a directory"}],["$","p",null,{"className":"text-muted-foreground mt-1","children":"Pick the directory you want Reflex to index. After it's registered, you can run the initial analysis from the directory page."}]]}],["$","$L11",null,{"initialPath":"/home/runner"}]]}]
15
- b:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]
16
- 7:null
17
- 9:{"metadata":[["$","title","0",{"children":"Reflex"}],["$","meta","1",{"name":"description","content":"Local-first knowledge base built by an agent."}]],"error":null,"digest":"$undefined"}
18
- e:"$9:metadata"
19
- 12:I[41287,["4400","static/chunks/4400-cdb1f7913ae34e09.js","1217","static/chunks/1217-407174d9b164a499.js","5097","static/chunks/5097-f07f6aeee3f60a33.js","9045","static/chunks/9045-731ff0865352dd95.js","7177","static/chunks/app/layout-c7a35075cfbfa3e3.js"],"AppSidebar"]
20
- 13:I[43450,["4400","static/chunks/4400-cdb1f7913ae34e09.js","1217","static/chunks/1217-407174d9b164a499.js","5097","static/chunks/5097-f07f6aeee3f60a33.js","9045","static/chunks/9045-731ff0865352dd95.js","7177","static/chunks/app/layout-c7a35075cfbfa3e3.js"],"Toaster"]
21
- 2:["$","html",null,{"lang":"en","suppressHydrationWarning":true,"children":["$","body",null,{"children":[["$","div",null,{"className":"h-screen flex","children":[["$","$L12",null,{"initialRoots":[]}],["$","main",null,{"className":"flex-1 min-w-0 flex flex-col","children":["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]]}],["$","$L13",null,{"richColors":true,"closeButton":true}]]}]}]