@tablestore/tablestore-agent-cli 0.2.10 → 0.2.11
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.
- package/dist/commands/memory.d.ts.map +1 -1
- package/dist/commands/memory.js +171 -95
- package/dist/commands/memory.js.map +1 -1
- package/dist/dashboard-runtime/dashboard/.next/BUILD_ID +1 -1
- package/dist/dashboard-runtime/dashboard/.next/app-path-routes-manifest.json +1 -3
- package/dist/dashboard-runtime/dashboard/.next/build-manifest.json +3 -3
- package/dist/dashboard-runtime/dashboard/.next/prerender-manifest.json +3 -3
- package/dist/dashboard-runtime/dashboard/.next/required-server-files.json +4 -4
- package/dist/dashboard-runtime/dashboard/.next/routes-manifest.json +5 -20
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/api-keys/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/api-keys/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/chat/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/chat/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/documents/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/documents/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/qa/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/qa/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/retrieval/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/retrieval/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/settings/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/[name]/settings/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/create/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/create/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/knowledge-base/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/llm-providers/[id]/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/llm-providers/[id]/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/llm-providers/new/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/llm-providers/new/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/llm-providers/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/llm-providers/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/dream/[dreamId]/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/dream/[dreamId]/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/dream/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/dream/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/messages/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/messages/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/requests/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/requests/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/search/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/search/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/settings/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/settings/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/tasks/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/tasks/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/units/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/[store]/units/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/create/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/create/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/memory/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/projects/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/(dashboard)/projects/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_global-error.html +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_global-error.rsc +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found.html +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found.rsc +16 -16
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found.segments/_full.segment.rsc +16 -16
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found.segments/_head.segment.rsc +3 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found.segments/_index.segment.rsc +11 -11
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +4 -4
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found.segments/_not-found.segment.rsc +3 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/[id]/custom-policy/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/[id]/custom-policy/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/[id]/effective-permissions/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/[id]/effective-permissions/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/[id]/policies/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/[id]/policies/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/[id]/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/[id]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/filter-by-permission/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/filter-by-permission/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/api-keys/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/auth/status/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/auth/status/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/auth/token/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/auth/token/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/instances/[name]/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/instances/[name]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/instances/[name]/token/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/instances/[name]/token/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/instances/[name]/use/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/instances/[name]/use/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/instances/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/instances/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/chunks/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/chunks/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/documents/[docId]/chunks/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/documents/[docId]/chunks/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/documents/[docId]/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/documents/[docId]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/documents/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/documents/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/documents/upload/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/documents/upload/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/retrieve/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/retrieve/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/route.js +4 -4
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/[name]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/knowledge-bases/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/chat/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/chat/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/providers/[id]/models/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/providers/[id]/models/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/providers/[id]/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/providers/[id]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/providers/[id]/test/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/providers/[id]/test/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/providers/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/llm/providers/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/logs/client/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/logs/client/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-kb-sync/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-kb-sync/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/[dreamId]/actions/apply/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/[dreamId]/actions/apply/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/[dreamId]/actions/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/[dreamId]/actions/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/[dreamId]/cancel/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/[dreamId]/cancel/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/[dreamId]/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/[dreamId]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/dream-tasks/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/[action]/route/app-paths-manifest.json +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/[action]/route.js +6 -0
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/{sync → [action]}/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/[action]/route_client-reference-manifest.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/messages/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/messages/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/requests/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/requests/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/scopes/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/scopes/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/search/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/search/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/tasks/[requestId]/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/tasks/[requestId]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/tasks/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/tasks/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/units/[memoryId]/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/units/[memoryId]/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/units/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/units/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/oss/list/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/oss/list/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/runtime/context/route.js +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/runtime/context/route.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/index.html +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/index.rsc +15 -15
- package/dist/dashboard-runtime/dashboard/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/index.segments/_full.segment.rsc +15 -15
- package/dist/dashboard-runtime/dashboard/.next/server/app/index.segments/_head.segment.rsc +3 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/index.segments/_index.segment.rsc +11 -11
- package/dist/dashboard-runtime/dashboard/.next/server/app/index.segments/_tree.segment.rsc +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding.html +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding.rsc +18 -18
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding.segments/_full.segment.rsc +18 -18
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding.segments/_head.segment.rsc +3 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding.segments/_index.segment.rsc +11 -11
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding.segments/_tree.segment.rsc +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding.segments/onboarding/__PAGE__.segment.rsc +4 -4
- package/dist/dashboard-runtime/dashboard/.next/server/app/onboarding.segments/onboarding.segment.rsc +4 -4
- package/dist/dashboard-runtime/dashboard/.next/server/app/page.js.nft.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/page_client-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app-paths-manifest.json +1 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/05a2_app_api_v1_memory_stores_[store]_file-memory_[action]_route_actions_0m70if_.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/0p91_next_dist_esm_build_templates_app-route_0n~ec7s.js +19 -12
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0--nu07._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0.gylau._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0.hvkwy._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0.qtdn4._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__02p1x3t._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__03og44p._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__04dd04u._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__04ujbw-._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__04zbudf._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/{[root-of-the-server]__0-3~.bv._.js → [root-of-the-server]__052epg.._.js} +3 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__05eryp~._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__06fva9g._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__08_2avk._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0acvvri._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0byveuc._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0cee_lo._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0cyd2qb._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0dzh4cj._.js +40 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0ecs-9r._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0ejcow5._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0es0s_~._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0fglxiw._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0g3yw6w._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0i1_p1s._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0is6qso._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0k7ex0r._.js +40 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0no9qm0._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0q8vcw8._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0q9fgt6._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0rx9hon._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0tc-.6s._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0u03tze._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0ua_nqs._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0uebf40._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0v0il3n._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/{[root-of-the-server]__089es3y._.js → [root-of-the-server]__0w56nne._.js} +10 -10
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0w_ig2a._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0y0w3mg._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0zmo~nd._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__10m-wmo._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__11s_zx6._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__11wq90l._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__126srko._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__12e1t6o._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__12ylr4n._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__13g_f9w._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__13q2wbt._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__13~-fxp._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/0b1r_app_(dashboard)_knowledge-base_[name]_documents_documents-client_tsx_0g2uxmt._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__0.ooo1s._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__01f7est._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__07fsbff._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__0b5cw4e._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__0cj2gsm._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0.pa1e6._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_01snuz~._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_05bw0~2._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_071hi50._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0_aw2vr._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0ep_q37._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0ez3yia._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0fttf6a._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0fz3kge._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0hx2079._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0hy21o9._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0oiggmj._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0p0sh02._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0uc_gmf._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0wce254._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0ww5s91._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0xrd8-1._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0y4mxf8._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0y7vx.d._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_12l8jkb._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_079nj-_._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_0_z9696._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_0bhjp9s._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_0grv2wq._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_app_(dashboard)_api-keys_page_tsx_0lb6fu7._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_app_(dashboard)_memory_[store]_dream_page_tsx_0uzzpvs._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_app_(dashboard)_memory_[store]_layout_tsx_0rbi41w._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_app_(dashboard)_memory_[store]_messages_page_tsx_0votz-n._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_app_(dashboard)_memory_[store]_tasks_page_tsx_0a_bgx4._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_app_(dashboard)_memory_[store]_units_page_tsx_0.6xnei._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_components_memory_memory-files-browser_tsx_0o2~94-._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_i18n_i18n-context_tsx_0c39ewr._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_providers_runtime-context-provider_tsx_0wmj66z._.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/node_modules__pnpm_0sr_ner._.js +3 -0
- package/dist/dashboard-runtime/dashboard/.next/server/functions-config-manifest.json +1 -3
- package/dist/dashboard-runtime/dashboard/.next/server/middleware-build-manifest.js +3 -3
- package/dist/dashboard-runtime/dashboard/.next/server/pages/404.html +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/pages/500.html +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/server-reference-manifest.js +1 -1
- package/dist/dashboard-runtime/dashboard/.next/server/server-reference-manifest.json +1 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0-~e5~2eoun8n.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0.hi0qmo.f-h4.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/01xcynczarvq~.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/01xuyqw7ivp3n.js +138 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/026lyw-ynx1og.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/029zyc1pxa~4m.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/05_iqjh-v2gej.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/05f4mjbi6x-tm.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/05vzt~ml0z7~9.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/07twdccs42b_-.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/{010bpq~3ntjcm.js → 08h7wustf~cl4.js} +1 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/08o2~c-80nbla.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/090n1_814n.n~.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0_osn.dm_85jw.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0aj~rx1m.91ur.js +5 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0dx_8pb_z_xy6.css +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0eafb9pun~54k.js +9 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0hnqmb1a7y7x1.js +138 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0jjiw-agnutux.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0k9guaejnlc0r.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/{0l~3_bvic.da3.js → 0ogrq_r43je48.js} +1 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0pxisu-1mnehf.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0r6utd8g~.cc1.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0u6c8q4k~6aiy.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0uu2cjfwvbn3y.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0vn5pp.3keyh5.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0wbozn0wq-4ls.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0yvc~t7p88wsf.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/{02u9ocsl0a12t.js → 0~naqbx3873~r.js} +1 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/12iur8ibdfi5_.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/13kxz9vygidrz.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/14.8mq880kjoc.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/145hqnc~4wc~n.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/14rpr3z1.lmgj.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/165fwg-5at5cq.js +1 -0
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/17b4md7atp39z.js +1 -0
- package/dist/dashboard-runtime/dashboard/server.js +1 -1
- package/dist/dashboard-runtime/dashboard/src/app/(dashboard)/chat/page.tsx +1 -0
- package/dist/dashboard-runtime/dashboard/src/app/(dashboard)/knowledge-base/[name]/qa/page.tsx +1 -0
- package/dist/dashboard-runtime/dashboard/src/app/(dashboard)/memory/[store]/layout.tsx +59 -8
- package/dist/dashboard-runtime/dashboard/src/app/(dashboard)/memory/[store]/messages/page.tsx +15 -0
- package/dist/dashboard-runtime/dashboard/src/app/(dashboard)/memory/[store]/tasks/page.tsx +9 -0
- package/dist/dashboard-runtime/dashboard/src/app/(dashboard)/memory/[store]/units/page.tsx +123 -24
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/llm/chat/file-memory-curator.ts +491 -0
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/llm/chat/file-memory-helpers.ts +12 -81
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/llm/chat/memory-helpers.ts +3 -3
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/llm/chat/route.ts +200 -39
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/memory/stores/[store]/file-memory/[action]/route.ts +92 -0
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/memory/stores/[store]/file-memory/_helpers.ts +26 -36
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/memory/stores/[store]/file-memory/_request.ts +49 -0
- package/dist/dashboard-runtime/dashboard/src/components/chat/chat-config-context.tsx +48 -9
- package/dist/dashboard-runtime/dashboard/src/components/chat/memory-bind-section.tsx +66 -18
- package/dist/dashboard-runtime/dashboard/src/components/chat/memory-files-dialog.tsx +1 -1
- package/dist/dashboard-runtime/dashboard/src/components/memory/file-details-panel.tsx +91 -0
- package/dist/dashboard-runtime/dashboard/src/components/memory/file-editor.tsx +139 -0
- package/dist/dashboard-runtime/dashboard/src/components/memory/file-mutation-dialogs.tsx +181 -0
- package/dist/dashboard-runtime/dashboard/src/components/memory/file-scope-onboarding.tsx +154 -0
- package/dist/dashboard-runtime/dashboard/src/components/memory/file-version-history.tsx +201 -0
- package/dist/dashboard-runtime/dashboard/src/components/memory/file-workspace-toolbar.tsx +101 -0
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-create-form.tsx +166 -75
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-dream-create-dialog.tsx +147 -20
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-files-browser.tsx +452 -168
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-scope-bar.tsx +27 -21
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-search-form.tsx +51 -14
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-search-results.tsx +5 -1
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-settings-form.tsx +54 -46
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-store-card.tsx +126 -69
- package/dist/dashboard-runtime/dashboard/src/components/memory/memory-unit-table.tsx +5 -1
- package/dist/dashboard-runtime/dashboard/src/components/qa/qa-message.tsx +232 -38
- package/dist/dashboard-runtime/dashboard/src/components/shared/error-state.tsx +3 -2
- package/dist/dashboard-runtime/dashboard/src/hooks/use-chat-history.ts +125 -47
- package/dist/dashboard-runtime/dashboard/src/hooks/use-file-memory.ts +184 -29
- package/dist/dashboard-runtime/dashboard/src/hooks/use-memory-store-scopes.ts +2 -1
- package/dist/dashboard-runtime/dashboard/src/hooks/use-qa-chat.ts +188 -23
- package/dist/dashboard-runtime/dashboard/src/i18n/locales/en.ts +123 -14
- package/dist/dashboard-runtime/dashboard/src/i18n/locales/zh.ts +115 -14
- package/dist/dashboard-runtime/dashboard/src/lib/api-error-toast.ts +9 -1
- package/dist/dashboard-runtime/dashboard/src/lib/browser-file-memory.ts +391 -0
- package/dist/dashboard-runtime/dashboard/src/lib/file-scope-history.ts +108 -0
- package/dist/dashboard-runtime/dashboard/src/lib/memory-storage-mode.ts +193 -31
- package/dist/dashboard-runtime/dashboard/src/lib/memory.ts +16 -4
- package/dist/dashboard-runtime/dashboard/src/lib/query-keys.ts +67 -0
- package/dist/dashboard-runtime/dashboard/src/schemas/llm-chat.ts +58 -13
- package/dist/dashboard-runtime/dashboard/src/services/file-memory.ts +88 -46
- package/dist/dashboard-runtime/dashboard/src/types/file-memory.ts +97 -0
- package/dist/dashboard-runtime/dashboard/src/types/llm-chat.ts +49 -13
- package/dist/dashboard-runtime/dashboard/src/types/memory.ts +9 -2
- package/dist/dashboard-runtime/dashboard/tsconfig.tsbuildinfo +1 -0
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/index.d.ts +0 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/index.d.ts.map +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/index.js +0 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/index.js.map +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/memory-client.d.ts +55 -8
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/memory-client.d.ts.map +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/memory-client.js +93 -11
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/memory-client.js.map +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/oss-uploader.d.ts +56 -0
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/oss-uploader.d.ts.map +1 -0
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/oss-uploader.js +120 -0
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/oss-uploader.js.map +1 -0
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/response.d.ts.map +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/response.js +1 -0
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/response.js.map +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-sdk/package.json +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-shared/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/dashboard-runtime/node_modules/@tablestore/tablestore-agent-shared/dist/types.d.ts.map +1 -1
- package/dist/dashboard-runtime/node_modules/semver/node_modules/.bin/semver +21 -0
- package/dist/main.js +0 -0
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/index.d.ts +0 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/index.d.ts.map +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/index.js +0 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/index.js.map +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/memory-client.d.ts +55 -8
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/memory-client.d.ts.map +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/memory-client.js +93 -11
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/memory-client.js.map +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/oss-uploader.d.ts +56 -0
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/oss-uploader.d.ts.map +1 -0
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/oss-uploader.js +120 -0
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/oss-uploader.js.map +1 -0
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/response.d.ts.map +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/response.js +1 -0
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/response.js.map +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-sdk/package.json +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-shared/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/node_modules/@tablestore/tablestore-agent-shared/dist/types.d.ts.map +1 -1
- package/package.json +2 -2
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/file/route/app-paths-manifest.json +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/file/route.js +0 -6
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/file/route.js.nft.json +0 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/file/route_client-reference-manifest.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/sync/route/app-paths-manifest.json +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/sync/route/build-manifest.json +0 -9
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/sync/route/server-reference-manifest.json +0 -4
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/sync/route.js +0 -6
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/sync/route.js.map +0 -5
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/sync/route_client-reference-manifest.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/tree/route/app-paths-manifest.json +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/tree/route/build-manifest.json +0 -9
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/tree/route/server-reference-manifest.json +0 -4
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/tree/route.js +0 -6
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/tree/route.js.map +0 -5
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/tree/route.js.nft.json +0 -1
- package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/tree/route_client-reference-manifest.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/0ndq_server_app_api_v1_memory_stores_[store]_file-memory_file_route_actions_06~k01v.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/0ndq_server_app_api_v1_memory_stores_[store]_file-memory_sync_route_actions_0rt6p8e.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/0ndq_server_app_api_v1_memory_stores_[store]_file-memory_tree_route_actions_0wl_n8b.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0-dt7~s._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0.-~ff4._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0.l706t._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0.nejw_._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__00_mrad._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__00i.7se._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__00r7uqs._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__02~yw7n._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__04kpzpa._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__04p1a88._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__05x0k4d._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__060s~oe._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__06fanvv._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__06tci88._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__08bzgzm._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__08d7wb.._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__08p_m_c._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__095xiwn._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__09h95i6._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0ai2k_o._.js +0 -40
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0alcygi._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0aspytx._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0cq-9s~._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0cyiuai._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0d4zrpj._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0d~m09k._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0f1lugp._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0g1cfb7._.js +0 -40
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0gpz.~y._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0i3u9x3._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0iromt6._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0j8.u0y._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0k-pfaj._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0kcbz7k._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0nrl-.g._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0o5mf4h._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0omyr40._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0ty8jgt._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0ug_2kc._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0v98i9~._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0wt0ksb._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0ya_8d2._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0zfg-ml._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0~9ru5n._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__0~f7ckz._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__109i6ps._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__10o5zq5._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/[root-of-the-server]__12ls5l8._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/0w-2_lucide-react_dist_esm_icons_0h-3_0x._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__0k0es2c._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__0ky8i.~._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__0ocsrt0._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__0ys4x_n._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/[root-of-the-server]__10rkv6z._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_002mc1c._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_04f2u4t._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_06ny.4k._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0b9pl2d._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0e.ehti._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0f8moq0._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0f8yv4v._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0fvg_xo._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0h9c.8m._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0ip4ncy._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0izjcsk._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0j.62sb._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0mdbcju._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0p_s55v._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0qiamjd._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0t.h859._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_0xp94lc._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/_13730cz._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_00.1.s_._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_04o7mfc._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/dashboard_src_0qlyj-q._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/node_modules__pnpm_00usyu3._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/server/chunks/ssr/node_modules__pnpm_0791f2k._.js +0 -3
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0--dupndun7xc.css +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0.uxk~hsm6yi8.js +0 -138
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/00eggrx~.4c55.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/00lvoeu_v3253.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/00o9vmhspv._3.js +0 -138
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/00x1.t633f041.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/02p7gke47s.2~.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/03dth-av1gl-h.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/07s0f6938um2v.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/09y30vyml4r.b.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0au0pbejtwahz.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0b-ei8-g7ceug.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0chiv044h3u58.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0fcdli-~wmvvx.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0fz_9~-rxluly.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0i55cqygnl-a9.js +0 -5
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0j8p7vk~awgs..js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0j_.hkhjix9hw.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0naliud7av3p1.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0pbfl~23ac79y.js +0 -9
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0u3qx.qasmdx9.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0vuh8jgeqqdy..js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0wbevjtr1_grz.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0y-gjpq3kxsbz.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/0z_pq4ttgotxw.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/10i~m4_8ainxw.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/12535rmhzbk63.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/13uk2uuzuop5e.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/13vd4hv~l95-c.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/16.2aecdwo6w_.js +0 -1
- package/dist/dashboard-runtime/dashboard/.next/static/chunks/16yu0g~7n~33c.js +0 -1
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/memory/stores/[store]/file-memory/file/route.ts +0 -69
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/memory/stores/[store]/file-memory/sync/route.ts +0 -69
- package/dist/dashboard-runtime/dashboard/src/app/api/v1/memory/stores/[store]/file-memory/tree/route.ts +0 -44
- /package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/{file → [action]}/route/build-manifest.json +0 -0
- /package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/{file → [action]}/route/server-reference-manifest.json +0 -0
- /package/dist/dashboard-runtime/dashboard/.next/server/app/api/v1/memory/stores/[store]/file-memory/{file → [action]}/route.js.map +0 -0
- /package/dist/dashboard-runtime/dashboard/.next/static/{5irIRCYtKcYh5T_Bewihp → AgybWIwFBY3-L1V2Copiq}/_buildManifest.js +0 -0
- /package/dist/dashboard-runtime/dashboard/.next/static/{5irIRCYtKcYh5T_Bewihp → AgybWIwFBY3-L1V2Copiq}/_clientMiddlewareManifest.js +0 -0
- /package/dist/dashboard-runtime/dashboard/.next/static/{5irIRCYtKcYh5T_Bewihp → AgybWIwFBY3-L1V2Copiq}/_ssgManifest.js +0 -0
|
@@ -209,6 +209,8 @@ export const messages = {
|
|
|
209
209
|
deleteConfirm: '确定要删除记忆库 "{name}" 吗?此操作不可撤销。',
|
|
210
210
|
},
|
|
211
211
|
card: {
|
|
212
|
+
inputType: "输入",
|
|
213
|
+
storageStructure: "存储",
|
|
212
214
|
longTerm: "长期",
|
|
213
215
|
shortTerm: "短期",
|
|
214
216
|
extract: "抽取",
|
|
@@ -235,6 +237,22 @@ export const messages = {
|
|
|
235
237
|
nameDesc: "仅支持字母、数字和下划线,最多 32 个字符。",
|
|
236
238
|
descriptionLabel: "描述",
|
|
237
239
|
descriptionPlaceholder: "描述这个记忆库的用途...",
|
|
240
|
+
inputTypeSection: "输入类型",
|
|
241
|
+
inputTypeSectionDesc: "选择记忆如何进入记忆库。输入类型仅支持单选。",
|
|
242
|
+
shortTermInputLabel: "短期记忆",
|
|
243
|
+
shortTermInputDescription:
|
|
244
|
+
"接收对话产生的短期记忆,并按照所选存储结构进行持久化。",
|
|
245
|
+
fileInputLabel: "记忆文件",
|
|
246
|
+
fileInputDescription:
|
|
247
|
+
"直接读写记忆文件;选择后,存储结构固定为记忆文件。",
|
|
248
|
+
storageStructureSection: "记忆存储结构",
|
|
249
|
+
storageStructureSectionDesc:
|
|
250
|
+
"结构化记忆为短期记忆输入的必选项,可同时启用记忆文件。",
|
|
251
|
+
structuredStorageLabel: "结构化记忆",
|
|
252
|
+
structuredStorageDescription:
|
|
253
|
+
"以结构化条目保存,支持语义检索、记忆抽取和整理。",
|
|
254
|
+
fileStorageLabel: "记忆文件",
|
|
255
|
+
fileStorageDescription: "以文件树形式保存,并通过文件工作区访问。",
|
|
238
256
|
storageModeSection: "存储模式",
|
|
239
257
|
storageModeSectionDesc: "选择记忆库的存储后端。创建后不可修改。",
|
|
240
258
|
extractSection: "记忆抽取指令",
|
|
@@ -249,15 +267,23 @@ export const messages = {
|
|
|
249
267
|
nameMaxLength: "名称不能超过 32 个字符",
|
|
250
268
|
namePattern: "只能包含字母、数字和下划线",
|
|
251
269
|
descriptionMaxLength: "描述不超过 256 字",
|
|
270
|
+
storageStructureRequired: "请至少选择一种记忆存储结构",
|
|
271
|
+
storageStructureInvalid: "输入类型与记忆存储结构的组合不受支持",
|
|
252
272
|
extractMaxLength: "抽取指令不超过 4096 字",
|
|
253
273
|
},
|
|
254
274
|
storageMode: {
|
|
255
275
|
apiOnlyLabel: "仅 API 记忆",
|
|
256
276
|
fileLabel: "支持文件记忆",
|
|
277
|
+
projectedFileLabel: "只读文件投影",
|
|
278
|
+
writableFileLabel: "可写文件记忆",
|
|
257
279
|
apiOnlyDescription:
|
|
258
280
|
"仅 Tablestore:通过 API 语义检索读写记忆,不生成文件投影。",
|
|
259
281
|
fileDescription:
|
|
260
282
|
"Tablestore + OSS 文件投影:记忆额外投影成 markdown 文件树,可在对话中以文件形式检索、在控制台与 CLI 浏览目录结构。",
|
|
283
|
+
projectedFileDescription:
|
|
284
|
+
"通过文件 API 浏览 file+ots 单向投影;服务端握手决定只读状态,不维护浏览器或服务端本地镜像。",
|
|
285
|
+
writableFileDescription:
|
|
286
|
+
"完整文件记忆:通过 JSON API 新建、编辑、重命名、删除并查看版本历史,可直接为对话提供文件上下文。",
|
|
261
287
|
},
|
|
262
288
|
settings: {
|
|
263
289
|
basicInfo: "基本信息",
|
|
@@ -291,6 +317,7 @@ export const messages = {
|
|
|
291
317
|
deleteStore: "删除记忆库",
|
|
292
318
|
backToList: "返回列表",
|
|
293
319
|
tabUnits: "长期记忆",
|
|
320
|
+
tabFiles: "文件工作区",
|
|
294
321
|
tabSearch: "记忆检索",
|
|
295
322
|
tabMessages: "短期记忆",
|
|
296
323
|
tabTasks: "记忆抽取",
|
|
@@ -346,7 +373,9 @@ export const messages = {
|
|
|
346
373
|
tableContent: "内容",
|
|
347
374
|
tableType: "类型",
|
|
348
375
|
tableVersion: "版本",
|
|
349
|
-
tableCreatedAt: "
|
|
376
|
+
tableCreatedAt: "事件时间",
|
|
377
|
+
tableCreatedAtHint:
|
|
378
|
+
"记忆单元所描述的来源消息的事件时间,而不是写入时间。若引用的来源消息没有时间戳,则依次回退到单元自身时间、memcell 时间和服务端写入时间;Dream 产出的单元始终为服务端任务时间。updated_at 才是写入时间。",
|
|
350
379
|
tableActions: "操作",
|
|
351
380
|
disabledTitle: "当前记忆单元缺少精确范围或 ID,无法操作",
|
|
352
381
|
view: "查看详情",
|
|
@@ -363,14 +392,61 @@ export const messages = {
|
|
|
363
392
|
detailMetadata: "元数据",
|
|
364
393
|
},
|
|
365
394
|
files: {
|
|
395
|
+
scopeOnboardingTitle: "设置文件范围",
|
|
396
|
+
scopeOnboardingDescription:
|
|
397
|
+
"可读写文件记忆按精确 scope 隔离。此模式不提供服务端 scope 列表,请填写应用、租户、智能体和会话后进入文件工作区。",
|
|
398
|
+
recentScopes: "本浏览器最近使用的文件范围(最多 10 条)",
|
|
399
|
+
recentScopesLocalHint:
|
|
400
|
+
"这些范围只保存在当前浏览器中,不代表服务端已存在对应文件。",
|
|
401
|
+
scopeAllRequired: "四个范围字段都必须填写具体值,不能使用通配符 *",
|
|
402
|
+
scopeIsolationHint: "每个精确范围拥有独立的文件目录和版本历史。",
|
|
403
|
+
setScopeAndEnter: "设置范围并进入文件工作区",
|
|
366
404
|
selectFile: "选择左侧文件查看内容",
|
|
367
405
|
readFailed: "读取失败:{error}",
|
|
368
406
|
fileCount: "共 {count} 个文件",
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
407
|
+
emptyHint: "当前范围暂无文件",
|
|
408
|
+
searchPlaceholder: "筛选文件路径…",
|
|
409
|
+
newFile: "新建文件",
|
|
410
|
+
rename: "重命名",
|
|
411
|
+
writableMode: "可读写",
|
|
412
|
+
readOnlyMode: "只读投影",
|
|
413
|
+
readOnlyGuidance:
|
|
414
|
+
"该记忆库返回了只读握手;你可以浏览和引用文件,但不能修改内容或查看版本历史。",
|
|
415
|
+
unsaved: "未保存",
|
|
416
|
+
byteCount: "{count} / {limit} 字节",
|
|
417
|
+
editorLabel: "文件内容编辑器",
|
|
418
|
+
editorPlaceholder: "在这里编辑 UTF-8 文本…",
|
|
419
|
+
shaConflict:
|
|
420
|
+
"文件已被其他会话更新。你的文本仍保留在编辑器中;请复制内容、刷新最新版本后再合并保存。",
|
|
421
|
+
discardChanges: "当前文件有未保存的修改,确定要放弃吗?",
|
|
422
|
+
saveSuccess: "文件已保存",
|
|
423
|
+
saveFailed: "保存文件失败",
|
|
424
|
+
createSuccess: "文件已创建",
|
|
425
|
+
renameSuccess: "文件已重命名",
|
|
426
|
+
deleteSuccess: "文件已删除",
|
|
427
|
+
createTitle: "新建记忆文件",
|
|
428
|
+
renameTitle: "重命名文件",
|
|
429
|
+
deleteTitle: "删除文件",
|
|
430
|
+
deleteDescription: "确定删除 {path}?历史版本将保留,但当前文件会消失。",
|
|
431
|
+
pathHelp: "路径使用 UTF-8 文本,最长 800 字节,并且不能包含 .. 段。",
|
|
432
|
+
pathLabel: "文件路径",
|
|
433
|
+
initialContent: "初始内容",
|
|
434
|
+
pathRequired: "请输入文件路径",
|
|
435
|
+
pathTraversal: "文件路径不能包含 .. 段",
|
|
436
|
+
pathTooLarge: "文件路径不能超过 800 个 UTF-8 字节",
|
|
437
|
+
contentTooLarge: "文件内容不能超过 100 KiB",
|
|
438
|
+
selectForDetails: "选择文件后查看元数据与版本历史",
|
|
439
|
+
details: "文件详情",
|
|
440
|
+
size: "内容大小",
|
|
441
|
+
latestVersion: "当前版本",
|
|
442
|
+
updatedAt: "更新时间",
|
|
443
|
+
versionHistory: "版本历史",
|
|
444
|
+
noVersions: "暂无历史版本",
|
|
445
|
+
loadMore: "加载更多",
|
|
446
|
+
contentUnavailable: "该版本没有可读取的内容",
|
|
447
|
+
restoreVersion: "恢复为此版本",
|
|
448
|
+
restoreSuccess: "历史版本已恢复为新版本",
|
|
449
|
+
restoreFailed: "恢复版本失败",
|
|
374
450
|
},
|
|
375
451
|
add: {
|
|
376
452
|
title: "添加记忆",
|
|
@@ -408,7 +484,7 @@ export const messages = {
|
|
|
408
484
|
scopeRequired: "请先在范围栏中设置「应用」和「租户」的具体值",
|
|
409
485
|
scopeRequiredHint: "请先在范围栏中设置「应用」和「租户」的具体值。",
|
|
410
486
|
queryRequired: "请输入检索内容",
|
|
411
|
-
topKRange: "Top K 必须在
|
|
487
|
+
topKRange: "Top K 必须在 1 到 50 之间",
|
|
412
488
|
similarityRange: "相似度阈值必须在 0 到 1 之间",
|
|
413
489
|
notSearchedTitle: "尚未搜索",
|
|
414
490
|
notSearchedDescription:
|
|
@@ -420,7 +496,9 @@ export const messages = {
|
|
|
420
496
|
relevance: "相关度 {value}",
|
|
421
497
|
resultId: "ID:{id}",
|
|
422
498
|
resultScope: "范围:{scope}",
|
|
423
|
-
resultCreatedAt: "
|
|
499
|
+
resultCreatedAt: "事件时间:{time}",
|
|
500
|
+
resultCreatedAtHint:
|
|
501
|
+
"记忆单元所描述的来源消息的事件时间,而不是写入时间。若引用的来源消息没有时间戳,则依次回退到单元自身时间、memcell 时间和服务端写入时间;Dream 产出的单元始终为服务端任务时间。updated_at 才是写入时间。",
|
|
424
502
|
resultVersion: "版本:{version}",
|
|
425
503
|
},
|
|
426
504
|
messages: {
|
|
@@ -429,6 +507,7 @@ export const messages = {
|
|
|
429
507
|
"请在上方范围栏中为所有字段设置具体值以查询短期记忆",
|
|
430
508
|
emptyRange: "该时间范围内暂无消息",
|
|
431
509
|
empty: "当前范围下暂无消息记录",
|
|
510
|
+
loadFailed: "加载会话消息失败",
|
|
432
511
|
loadEarlier: "加载更早的消息",
|
|
433
512
|
allLoaded: "— 已加载全部消息 —",
|
|
434
513
|
count: "共 {count} 条消息",
|
|
@@ -461,6 +540,7 @@ export const messages = {
|
|
|
461
540
|
description:
|
|
462
541
|
"每条 AddMemories 调用对应一个任务记录,展示从消息到记忆条目的处理状态",
|
|
463
542
|
emptyTitle: "暂无任务",
|
|
543
|
+
loadFailed: "加载抽取任务失败",
|
|
464
544
|
emptyAll:
|
|
465
545
|
"该 scope 下还没有 AddMemories 调用产生的入库任务。可以在长期记忆 / 检索 Tab 触发记忆写入,或调用 CLI memory add 后回到这里查看进度。",
|
|
466
546
|
emptyFiltered:
|
|
@@ -669,6 +749,14 @@ export const messages = {
|
|
|
669
749
|
appIdRequired: "appId 必填",
|
|
670
750
|
atLeastOneNonWildcard: "至少指定一个非通配符字段",
|
|
671
751
|
atLeastOneScope: "至少一个 scope",
|
|
752
|
+
scopesLimit: "scope 最多 20 个",
|
|
753
|
+
instructionsLimit: "指令不能超过 4000 字节(UTF-8)",
|
|
754
|
+
maxSessionsRange: "最大会话数必须是 1 到 100 之间的整数",
|
|
755
|
+
maxMessagesRange: "最大消息数必须是 1 到 20000 之间的整数",
|
|
756
|
+
maxMemoriesRange: "最大记忆数必须是 1 到 5000 之间的整数",
|
|
757
|
+
thresholdRange: "置信度阈值必须在 0 到 1 之间",
|
|
758
|
+
timestampInvalid: "时间格式不正确",
|
|
759
|
+
timestampOrder: "最晚时间不能早于最早时间",
|
|
672
760
|
actions: {
|
|
673
761
|
allStatus: "全部状态",
|
|
674
762
|
allTypes: "全部类型",
|
|
@@ -1152,10 +1240,11 @@ export const messages = {
|
|
|
1152
1240
|
modeSearchTitle: "语义检索",
|
|
1153
1241
|
modeSearchDesc: "每轮向量检索记忆库",
|
|
1154
1242
|
modeLocalTitle: "文件记忆",
|
|
1155
|
-
modeLocalDescEnabled: "
|
|
1243
|
+
modeLocalDescEnabled: "通过文件 API 缓存后本地检索",
|
|
1244
|
+
modeLocalDescWritable: "filemem 固定使用文件检索",
|
|
1156
1245
|
modeLocalDescDisabled: "仅「支持文件记忆」的记忆库可用",
|
|
1157
1246
|
localHint:
|
|
1158
|
-
"
|
|
1247
|
+
"每轮对话前,浏览器通过文件 API 分页列举并按 SHA 复用内容,在当前标签页做有界词法检索;不会启动 FUSE 或创建服务端本地镜像。",
|
|
1159
1248
|
viewFiles: "查看记忆文件",
|
|
1160
1249
|
viewFilesHint: "请先填写完整的应用 / 租户 / 智能体",
|
|
1161
1250
|
emptyNoStoresTitle: "还没有任何记忆库",
|
|
@@ -1181,6 +1270,8 @@ export const messages = {
|
|
|
1181
1270
|
agentField: "智能体 *",
|
|
1182
1271
|
autoSave: "对话后自动写入记忆",
|
|
1183
1272
|
autoSaveDesc: "自动归档:把本轮用户 / 助手消息写入当前范围",
|
|
1273
|
+
autoSaveFilememDesc:
|
|
1274
|
+
"智能提炼每轮对话中值得长期保存的内容,并追加到日期记忆文件",
|
|
1184
1275
|
runIdLabel: "会话 ID",
|
|
1185
1276
|
runIdTitle:
|
|
1186
1277
|
"会话 ID 由当前对话自动生成并在整个对话内复用,用于串联同一会话的记忆",
|
|
@@ -1191,7 +1282,7 @@ export const messages = {
|
|
|
1191
1282
|
},
|
|
1192
1283
|
filesDialog: {
|
|
1193
1284
|
title: "记忆文件",
|
|
1194
|
-
description: "
|
|
1285
|
+
description: "通过文件 API 管理该精确范围的虚拟文件与版本",
|
|
1195
1286
|
},
|
|
1196
1287
|
history: {
|
|
1197
1288
|
newChat: "新对话",
|
|
@@ -1248,6 +1339,11 @@ export const messages = {
|
|
|
1248
1339
|
edit: "编辑",
|
|
1249
1340
|
resend: "重新发送",
|
|
1250
1341
|
regenerate: "重新生成",
|
|
1342
|
+
saveToFile: "保存回复到文件记忆",
|
|
1343
|
+
savePathPrompt: "请输入要保存到 filemem 的文件路径",
|
|
1344
|
+
saveToFileInvalid: "路径无效,或回复内容超过 100 KiB",
|
|
1345
|
+
savedToFile: "回复已保存到 {path}",
|
|
1346
|
+
saveToFileFailed: "保存回复到文件记忆失败",
|
|
1251
1347
|
summarizeSkill: "总结技能到知识库",
|
|
1252
1348
|
extractProfile: "提取画像到知识库",
|
|
1253
1349
|
delete: "删除",
|
|
@@ -1274,6 +1370,10 @@ export const messages = {
|
|
|
1274
1370
|
generateFailed: "生成失败",
|
|
1275
1371
|
elapsedSeconds: "用时 {seconds} 秒",
|
|
1276
1372
|
elapsedMinutes: "用时 {minutes} 分 {seconds} 秒",
|
|
1373
|
+
memorySaving: "正在提炼文件记忆…",
|
|
1374
|
+
memorySaved: "已写入 {count} 条长期记忆",
|
|
1375
|
+
memoryUnchanged: "本轮无需记录长期记忆",
|
|
1376
|
+
memorySaveFailed: "文件记忆提炼失败:{error}",
|
|
1277
1377
|
},
|
|
1278
1378
|
chunks: {
|
|
1279
1379
|
viewCitations: "查看 {count} 个引用",
|
|
@@ -1291,9 +1391,10 @@ export const messages = {
|
|
|
1291
1391
|
referenceCount: "参考 {count} 条记忆",
|
|
1292
1392
|
unnamedMemory: "未命名记忆",
|
|
1293
1393
|
filesThisTurn: "本轮文件记忆 {count} 个文件",
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1394
|
+
cacheFailed: "文件 API 缓存失败:{error}",
|
|
1395
|
+
cacheSummary: "读取 {loaded} · SHA 复用 {reused} · 共 {total} 个",
|
|
1396
|
+
cacheTruncated: "已达到 300 文件 / 3 MiB 检索上限",
|
|
1397
|
+
emptyFiles: "该精确范围暂无可检索的记忆文件",
|
|
1297
1398
|
fileSize: "{size} B",
|
|
1298
1399
|
},
|
|
1299
1400
|
panel: {
|
|
@@ -38,7 +38,15 @@ export function showApiError(
|
|
|
38
38
|
}
|
|
39
39
|
const message =
|
|
40
40
|
error instanceof Error ? error.message : String(error ?? "未知错误");
|
|
41
|
-
|
|
41
|
+
if (options.fallbackTitle) {
|
|
42
|
+
if (message) {
|
|
43
|
+
toast.error(options.fallbackTitle, { description: message });
|
|
44
|
+
} else {
|
|
45
|
+
toast.error(options.fallbackTitle);
|
|
46
|
+
}
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
toast.error(message);
|
|
42
50
|
}
|
|
43
51
|
|
|
44
52
|
/**
|
|
@@ -0,0 +1,391 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import type { ChatMemoryWriteScope } from "@/components/chat/chat-config-context";
|
|
4
|
+
import {
|
|
5
|
+
listFileMemories as listFileMemoriesService,
|
|
6
|
+
readFileMemory as readFileMemoryService,
|
|
7
|
+
} from "@/services/file-memory";
|
|
8
|
+
import type { FileMemory, FileMemoryScope } from "@/types/file-memory";
|
|
9
|
+
|
|
10
|
+
export const BROWSER_FILE_MEMORY_LABEL =
|
|
11
|
+
"标签页内容缓存 · 通过文件 API 按 SHA 复用";
|
|
12
|
+
export const MAX_BROWSER_FILE_MEMORY_FILES = 300;
|
|
13
|
+
export const MAX_BROWSER_FILE_MEMORY_BYTES = 3 * 1024 * 1024;
|
|
14
|
+
export const MAX_BROWSER_FILE_MEMORY_SNAPSHOTS = 8;
|
|
15
|
+
|
|
16
|
+
const LIST_PAGE_SIZE = 100;
|
|
17
|
+
const READ_CONCURRENCY = 8;
|
|
18
|
+
const MAX_LIST_PAGES = 1_000;
|
|
19
|
+
const SNIPPET_LINES = 10;
|
|
20
|
+
|
|
21
|
+
export interface BrowserFileMemoryEntry {
|
|
22
|
+
rel: string;
|
|
23
|
+
size: number;
|
|
24
|
+
sha256: string;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export interface BrowserFileMemoryHit {
|
|
28
|
+
text: string;
|
|
29
|
+
source: string;
|
|
30
|
+
score: number;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export interface BrowserFileMemoryCacheSummary {
|
|
34
|
+
ok: boolean;
|
|
35
|
+
listed: number;
|
|
36
|
+
loaded: number;
|
|
37
|
+
reused: number;
|
|
38
|
+
totalBytes: number;
|
|
39
|
+
truncated: boolean;
|
|
40
|
+
error?: string;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
interface CachedFile extends BrowserFileMemoryEntry {
|
|
44
|
+
path: string;
|
|
45
|
+
memoryId: string;
|
|
46
|
+
text: string;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
interface BrowserFileMemorySnapshot {
|
|
50
|
+
files: Map<string, CachedFile>;
|
|
51
|
+
updatedAt: number;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
type ListFileMemories = typeof listFileMemoriesService;
|
|
55
|
+
type ReadFileMemory = typeof readFileMemoryService;
|
|
56
|
+
|
|
57
|
+
export interface LoadBrowserFileMemoryOptions {
|
|
58
|
+
dataScopeKey: string;
|
|
59
|
+
memoryStoreName: string;
|
|
60
|
+
scope: ChatMemoryWriteScope;
|
|
61
|
+
listFileMemories?: ListFileMemories;
|
|
62
|
+
readFileMemory?: ReadFileMemory;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export interface LoadBrowserFileMemoryResult {
|
|
66
|
+
key: string;
|
|
67
|
+
files: BrowserFileMemoryEntry[];
|
|
68
|
+
cache: BrowserFileMemoryCacheSummary;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
const snapshots = new Map<string, BrowserFileMemorySnapshot>();
|
|
72
|
+
const inflight = new Map<string, Promise<LoadBrowserFileMemoryResult>>();
|
|
73
|
+
|
|
74
|
+
function readSnapshot(key: string): BrowserFileMemorySnapshot | undefined {
|
|
75
|
+
const snapshot = snapshots.get(key);
|
|
76
|
+
if (snapshot) {
|
|
77
|
+
snapshots.delete(key);
|
|
78
|
+
snapshots.set(key, snapshot);
|
|
79
|
+
}
|
|
80
|
+
return snapshot;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
function storeSnapshot(key: string, snapshot: BrowserFileMemorySnapshot): void {
|
|
84
|
+
snapshots.delete(key);
|
|
85
|
+
snapshots.set(key, snapshot);
|
|
86
|
+
while (snapshots.size > MAX_BROWSER_FILE_MEMORY_SNAPSHOTS) {
|
|
87
|
+
const oldestKey = snapshots.keys().next().value;
|
|
88
|
+
if (oldestKey === undefined) break;
|
|
89
|
+
snapshots.delete(oldestKey);
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
function normalizeScope(scope: ChatMemoryWriteScope): FileMemoryScope {
|
|
94
|
+
const read = (value: string, field: string) => {
|
|
95
|
+
const normalized = value.trim();
|
|
96
|
+
if (!normalized || normalized === "*") {
|
|
97
|
+
throw new Error(`file memory requires an exact ${field}`);
|
|
98
|
+
}
|
|
99
|
+
return normalized;
|
|
100
|
+
};
|
|
101
|
+
return {
|
|
102
|
+
appId: read(scope.appId, "appId"),
|
|
103
|
+
tenantId: read(scope.tenantId, "tenantId"),
|
|
104
|
+
agentId: read(scope.agentId, "agentId"),
|
|
105
|
+
runId: read(scope.runId, "runId"),
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
export function browserFileMemoryKey(opts: {
|
|
110
|
+
dataScopeKey: string;
|
|
111
|
+
memoryStoreName: string;
|
|
112
|
+
scope: ChatMemoryWriteScope;
|
|
113
|
+
}): string {
|
|
114
|
+
const scope = normalizeScope(opts.scope);
|
|
115
|
+
return JSON.stringify([
|
|
116
|
+
opts.dataScopeKey,
|
|
117
|
+
opts.memoryStoreName,
|
|
118
|
+
scope.appId,
|
|
119
|
+
scope.tenantId,
|
|
120
|
+
scope.agentId,
|
|
121
|
+
scope.runId,
|
|
122
|
+
]);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
function normalizePath(path: string): { path: string; rel: string } {
|
|
126
|
+
const absolute = `/${path.trim().replace(/^\/+/, "")}`;
|
|
127
|
+
const parts = absolute.slice(1).split("/");
|
|
128
|
+
if (
|
|
129
|
+
absolute === "/" ||
|
|
130
|
+
absolute.includes("\\") ||
|
|
131
|
+
parts.some((part) => !part || part === "." || part === "..")
|
|
132
|
+
) {
|
|
133
|
+
throw new Error(`invalid file-memory path: ${path}`);
|
|
134
|
+
}
|
|
135
|
+
return { path: absolute, rel: parts.join("/") };
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
function validateMetadata(file: FileMemory): void {
|
|
139
|
+
normalizePath(file.path);
|
|
140
|
+
if (
|
|
141
|
+
!file.memoryId ||
|
|
142
|
+
!file.contentSha256 ||
|
|
143
|
+
!Number.isSafeInteger(file.contentSizeBytes) ||
|
|
144
|
+
file.contentSizeBytes < 0
|
|
145
|
+
) {
|
|
146
|
+
throw new Error(`invalid file-memory metadata: ${file.path}`);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
async function collectMetadata(
|
|
151
|
+
opts: LoadBrowserFileMemoryOptions,
|
|
152
|
+
scope: FileMemoryScope,
|
|
153
|
+
): Promise<{ files: FileMemory[]; truncated: boolean }> {
|
|
154
|
+
const list = opts.listFileMemories ?? listFileMemoriesService;
|
|
155
|
+
const files = new Map<string, FileMemory>();
|
|
156
|
+
const tokens = new Set<string>();
|
|
157
|
+
let nextToken: string | undefined;
|
|
158
|
+
let truncated = false;
|
|
159
|
+
|
|
160
|
+
for (let page = 0; page < MAX_LIST_PAGES; page += 1) {
|
|
161
|
+
const response = await list(opts.memoryStoreName, {
|
|
162
|
+
scope,
|
|
163
|
+
limit: LIST_PAGE_SIZE,
|
|
164
|
+
...(nextToken ? { nextToken } : {}),
|
|
165
|
+
});
|
|
166
|
+
for (const [index, file] of response.memories.entries()) {
|
|
167
|
+
validateMetadata(file);
|
|
168
|
+
const { path } = normalizePath(file.path);
|
|
169
|
+
if (!files.has(path)) files.set(path, { ...file, path });
|
|
170
|
+
if (files.size >= MAX_BROWSER_FILE_MEMORY_FILES) {
|
|
171
|
+
truncated =
|
|
172
|
+
index < response.memories.length - 1 || !!response.nextToken;
|
|
173
|
+
return { files: [...files.values()], truncated };
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
if (!response.nextToken) return { files: [...files.values()], truncated };
|
|
177
|
+
if (tokens.has(response.nextToken)) {
|
|
178
|
+
throw new Error("ListFileMemories repeated a pagination token");
|
|
179
|
+
}
|
|
180
|
+
tokens.add(response.nextToken);
|
|
181
|
+
nextToken = response.nextToken;
|
|
182
|
+
}
|
|
183
|
+
throw new Error("ListFileMemories exceeded the pagination limit");
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
async function mapConcurrent<T, TResult>(
|
|
187
|
+
items: T[],
|
|
188
|
+
concurrency: number,
|
|
189
|
+
worker: (item: T) => Promise<TResult>,
|
|
190
|
+
): Promise<TResult[]> {
|
|
191
|
+
const results = new Array<TResult>(items.length);
|
|
192
|
+
let cursor = 0;
|
|
193
|
+
await Promise.all(
|
|
194
|
+
Array.from({ length: Math.min(concurrency, items.length) }, async () => {
|
|
195
|
+
while (cursor < items.length) {
|
|
196
|
+
const index = cursor;
|
|
197
|
+
cursor += 1;
|
|
198
|
+
results[index] = await worker(items[index]);
|
|
199
|
+
}
|
|
200
|
+
}),
|
|
201
|
+
);
|
|
202
|
+
return results;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
function snapshotEntries(
|
|
206
|
+
snapshot: BrowserFileMemorySnapshot | undefined,
|
|
207
|
+
): BrowserFileMemoryEntry[] {
|
|
208
|
+
if (!snapshot) return [];
|
|
209
|
+
return [...snapshot.files.values()]
|
|
210
|
+
.map(({ rel, size, sha256 }) => ({ rel, size, sha256 }))
|
|
211
|
+
.sort((a, b) => a.rel.localeCompare(b.rel));
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
async function performLoad(
|
|
215
|
+
opts: LoadBrowserFileMemoryOptions,
|
|
216
|
+
key: string,
|
|
217
|
+
scope: FileMemoryScope,
|
|
218
|
+
): Promise<LoadBrowserFileMemoryResult> {
|
|
219
|
+
const previous = readSnapshot(key);
|
|
220
|
+
try {
|
|
221
|
+
const collected = await collectMetadata(opts, scope);
|
|
222
|
+
const selected: FileMemory[] = [];
|
|
223
|
+
let totalBytes = 0;
|
|
224
|
+
let truncated = collected.truncated;
|
|
225
|
+
for (const file of collected.files) {
|
|
226
|
+
if (totalBytes + file.contentSizeBytes > MAX_BROWSER_FILE_MEMORY_BYTES) {
|
|
227
|
+
truncated = true;
|
|
228
|
+
continue;
|
|
229
|
+
}
|
|
230
|
+
selected.push(file);
|
|
231
|
+
totalBytes += file.contentSizeBytes;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
const candidate = new Map<string, CachedFile>();
|
|
235
|
+
const toRead: FileMemory[] = [];
|
|
236
|
+
let reused = 0;
|
|
237
|
+
for (const file of selected) {
|
|
238
|
+
const { rel } = normalizePath(file.path);
|
|
239
|
+
const cached = previous?.files.get(rel);
|
|
240
|
+
if (cached?.sha256 === file.contentSha256) {
|
|
241
|
+
candidate.set(rel, {
|
|
242
|
+
...cached,
|
|
243
|
+
path: file.path,
|
|
244
|
+
memoryId: file.memoryId,
|
|
245
|
+
size: file.contentSizeBytes,
|
|
246
|
+
});
|
|
247
|
+
reused += 1;
|
|
248
|
+
} else {
|
|
249
|
+
toRead.push(file);
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
const read = opts.readFileMemory ?? readFileMemoryService;
|
|
254
|
+
const loaded = await mapConcurrent(
|
|
255
|
+
toRead,
|
|
256
|
+
READ_CONCURRENCY,
|
|
257
|
+
async (file) => {
|
|
258
|
+
const response = await read(opts.memoryStoreName, {
|
|
259
|
+
scope,
|
|
260
|
+
path: file.path,
|
|
261
|
+
});
|
|
262
|
+
if (response.content === undefined) {
|
|
263
|
+
throw new Error(`ReadFileMemory omitted content for ${file.path}`);
|
|
264
|
+
}
|
|
265
|
+
const { path, rel } = normalizePath(file.path);
|
|
266
|
+
return {
|
|
267
|
+
path,
|
|
268
|
+
rel,
|
|
269
|
+
memoryId: file.memoryId,
|
|
270
|
+
size: file.contentSizeBytes,
|
|
271
|
+
sha256: file.contentSha256,
|
|
272
|
+
text: response.content,
|
|
273
|
+
} satisfies CachedFile;
|
|
274
|
+
},
|
|
275
|
+
);
|
|
276
|
+
for (const file of loaded) candidate.set(file.rel, file);
|
|
277
|
+
|
|
278
|
+
const snapshot = { files: candidate, updatedAt: Date.now() };
|
|
279
|
+
storeSnapshot(key, snapshot);
|
|
280
|
+
return {
|
|
281
|
+
key,
|
|
282
|
+
files: snapshotEntries(snapshot),
|
|
283
|
+
cache: {
|
|
284
|
+
ok: true,
|
|
285
|
+
listed: collected.files.length,
|
|
286
|
+
loaded: loaded.length,
|
|
287
|
+
reused,
|
|
288
|
+
totalBytes,
|
|
289
|
+
truncated,
|
|
290
|
+
},
|
|
291
|
+
};
|
|
292
|
+
} catch (error) {
|
|
293
|
+
const files = snapshotEntries(previous);
|
|
294
|
+
return {
|
|
295
|
+
key,
|
|
296
|
+
files,
|
|
297
|
+
cache: {
|
|
298
|
+
ok: false,
|
|
299
|
+
listed: files.length,
|
|
300
|
+
loaded: 0,
|
|
301
|
+
reused: files.length,
|
|
302
|
+
totalBytes: files.reduce((sum, file) => sum + file.size, 0),
|
|
303
|
+
truncated: false,
|
|
304
|
+
error: error instanceof Error ? error.message : String(error),
|
|
305
|
+
},
|
|
306
|
+
};
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
export function loadBrowserFileMemory(
|
|
311
|
+
opts: LoadBrowserFileMemoryOptions,
|
|
312
|
+
): Promise<LoadBrowserFileMemoryResult> {
|
|
313
|
+
const scope = normalizeScope(opts.scope);
|
|
314
|
+
const key = browserFileMemoryKey({ ...opts, scope });
|
|
315
|
+
const existing = inflight.get(key);
|
|
316
|
+
if (existing) return existing;
|
|
317
|
+
const run = performLoad(opts, key, scope).finally(() => inflight.delete(key));
|
|
318
|
+
inflight.set(key, run);
|
|
319
|
+
return run;
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
export function readBrowserFileMemoryFile(key: string, rel: string): string {
|
|
323
|
+
const normalized = normalizePath(rel).rel;
|
|
324
|
+
const file = readSnapshot(key)?.files.get(normalized);
|
|
325
|
+
if (!file) throw new Error(`browser file-memory file not found: ${rel}`);
|
|
326
|
+
return file.text;
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
function tokenizeQuery(query: string): string[] {
|
|
330
|
+
const terms = new Set<string>();
|
|
331
|
+
for (const token of query.toLowerCase().match(/[a-z0-9]+/g) ?? []) {
|
|
332
|
+
if (token.length >= 2) terms.add(token);
|
|
333
|
+
}
|
|
334
|
+
for (const run of query.match(/[一-鿿㐀-䶿]+/g) ?? []) {
|
|
335
|
+
for (const char of run) terms.add(char);
|
|
336
|
+
for (let index = 0; index + 1 < run.length; index += 1) {
|
|
337
|
+
terms.add(run[index] + run[index + 1]);
|
|
338
|
+
}
|
|
339
|
+
}
|
|
340
|
+
return [...terms];
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
function scoreSnippet(
|
|
344
|
+
text: string,
|
|
345
|
+
terms: string[],
|
|
346
|
+
fullQuery: string,
|
|
347
|
+
): number {
|
|
348
|
+
const lower = text.toLowerCase();
|
|
349
|
+
const matched = terms.reduce(
|
|
350
|
+
(count, term) => count + (lower.includes(term) ? 1 : 0),
|
|
351
|
+
0,
|
|
352
|
+
);
|
|
353
|
+
if (!matched) return 0;
|
|
354
|
+
const bonus =
|
|
355
|
+
fullQuery.length > 4 && lower.includes(fullQuery.toLowerCase()) ? 0.1 : 0;
|
|
356
|
+
return Math.min(1, matched / Math.max(1, terms.length) + bonus);
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
export function searchBrowserFileMemory(opts: {
|
|
360
|
+
key: string;
|
|
361
|
+
query: string;
|
|
362
|
+
topK: number;
|
|
363
|
+
}): { results: BrowserFileMemoryHit[]; skipped?: boolean } {
|
|
364
|
+
const query = opts.query.trim();
|
|
365
|
+
const snapshot = readSnapshot(opts.key);
|
|
366
|
+
const terms = tokenizeQuery(query);
|
|
367
|
+
if (!query || !snapshot || terms.length === 0) {
|
|
368
|
+
return { results: [], skipped: true };
|
|
369
|
+
}
|
|
370
|
+
const hits: BrowserFileMemoryHit[] = [];
|
|
371
|
+
for (const file of snapshot.files.values()) {
|
|
372
|
+
const lines = file.text.split("\n");
|
|
373
|
+
for (let index = 0; index < lines.length; index += SNIPPET_LINES) {
|
|
374
|
+
const text = lines
|
|
375
|
+
.slice(index, index + SNIPPET_LINES)
|
|
376
|
+
.join("\n")
|
|
377
|
+
.trim();
|
|
378
|
+
if (!text) continue;
|
|
379
|
+
const score = scoreSnippet(text, terms, query);
|
|
380
|
+
if (score > 0) hits.push({ text, source: file.rel, score });
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
hits.sort((a, b) => b.score - a.score || a.source.localeCompare(b.source));
|
|
384
|
+
const topK = Math.max(1, Math.min(50, Math.trunc(opts.topK) || 1));
|
|
385
|
+
return { results: hits.slice(0, topK) };
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
export function clearBrowserFileMemoryForTests(): void {
|
|
389
|
+
snapshots.clear();
|
|
390
|
+
inflight.clear();
|
|
391
|
+
}
|