@xiaofanzhao/dsh-plugin-knowledge-base 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +300 -2
- package/client.js +1809 -0
- package/cordis.patch.yml +20 -0
- package/docs/DESIGN.md +662 -0
- package/docs/DETAIL.md +60 -0
- package/docs/images/architecture.svg +111 -0
- package/docs/images/ui-bigscreen.svg +59 -0
- package/docs/images/ui-overview.svg +152 -0
- package/icon.svg +13 -0
- package/index.js +131 -0
- package/lib/chunker.mjs +121 -0
- package/lib/extract.mjs +434 -0
- package/lib/index.mjs +383 -0
- package/lib/pdf.mjs +88 -0
- package/lib/pipeline.mjs +116 -0
- package/lib/preview.mjs +217 -0
- package/lib/routes.mjs +546 -0
- package/lib/settings.mjs +107 -0
- package/lib/store.mjs +445 -0
- package/lib/tools.mjs +246 -0
- package/lib/util.mjs +129 -0
- package/locale/en.json +33 -0
- package/locale/zh.json +33 -0
- package/package.json +63 -4
package/cordis.patch.yml
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# 个人知识库插件在 profile 插件树里的加载行。
|
|
2
|
+
# id 是稳定标识(后续 patch 按 id 覆盖 config);name 是包名。
|
|
3
|
+
- insert:
|
|
4
|
+
- id: knowledge-base
|
|
5
|
+
name: '@xiaofanzhao/dsh-plugin-knowledge-base'
|
|
6
|
+
config:
|
|
7
|
+
# 库文件根目录;留空用默认值 $DSH_HOME/kb
|
|
8
|
+
# root: 'D:\\我的资料\\dsh-kb'
|
|
9
|
+
root: ''
|
|
10
|
+
# 单个文件大小上限(字节),默认 64 MiB
|
|
11
|
+
maxFileBytes: 67108864
|
|
12
|
+
# 解析队列并发(1-2 比较稳妥)
|
|
13
|
+
parseConcurrency: 1
|
|
14
|
+
# 向量检索:地址和模型给出厂默认(百炼),**密钥请填在界面上**,
|
|
15
|
+
# 它只写进 $DSH_HOME/kb/settings.json,永远不进这个文件、更不进仓库。
|
|
16
|
+
# enabled 保持 false:没填 Key 之前打开只会让索引白跑一遍。
|
|
17
|
+
embedding:
|
|
18
|
+
enabled: false
|
|
19
|
+
baseUrl: 'https://dashscope.aliyuncs.com/compatible-mode/v1'
|
|
20
|
+
model: 'text-embedding-v4'
|