@lih-x-x/kmr 1.0.8 → 1.0.10
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/index.js +21 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -840,7 +840,7 @@ var SESSION_SKILL = `\u4F60\u662F KMR\uFF08Key Meetings Record\uFF09\u7684\u667A
|
|
|
840
840
|
- \u4F1A\u8BAE\u8BB0\u5F55\u5B58\u50A8\u5728 ~/.kmr/data/meetings/ \u76EE\u5F55\u4E0B\uFF0C\u6BCF\u4E2A\u4F1A\u8BAE\u662F\u4E00\u4E2A JSON \u6587\u4EF6
|
|
841
841
|
- \u4F60\u53EF\u4EE5\u76F4\u63A5\u7528 ls\u3001cat\u3001grep \u7B49\u547D\u4EE4\u8BFB\u53D6\u8FD9\u4E9B\u6587\u4EF6\u6765\u56DE\u7B54\u7528\u6237\u7684\u95EE\u9898
|
|
842
842
|
- \u6BCF\u4E2A JSON \u6587\u4EF6\u5305\u542B\uFF1Asummary\uFF08\u6807\u9898/\u65E5\u671F/\u53C2\u4E0E\u4EBA/\u8981\u70B9\uFF09\u3001todos\u3001risks\u3001commitments\u3001reusableInsights\u3001rawContent
|
|
843
|
-
- \u5F53\u7528\u6237\u95EE"\u6700\u8FD1\u7684\u4F1A\u8BAE"\u3001"\u4E0A\u6B21\u8BA8\u8BBA\u4E86\u4EC0\u4E48"\u7B49\u95EE\u9898\u65F6\uFF0C\u76F4\u63A5\u8BFB\u53D6\u6587\u4EF6\u56DE\u7B54
|
|
843
|
+
- \u5F53\u7528\u6237\u95EE"\u6700\u8FD1\u7684\u4F1A\u8BAE"\u3001"\u4E0A\u6B21\u8BA8\u8BBA\u4E86\u4EC0\u4E48"\u7B49\u4EFB\u4F55\u4F60\u9700\u8981\u901A\u8FC7\u6587\u4EF6\u5185\u5BB9\u56DE\u7B54\u7684\u95EE\u9898\u65F6\uFF0C\u76F4\u63A5\u8BFB\u53D6\u6587\u4EF6\u5E76\u52A0\u5DE5\u56DE\u7B54
|
|
844
844
|
- \u7528\u6237\u4E5F\u53EF\u4EE5\u4F7F\u7528\u4EE5\u4E0B\u547D\u4EE4\uFF1A/find \u641C\u7D22\u3001/listall \u5217\u51FA\u5168\u90E8\u3001/show <id> \u67E5\u770B\u8BE6\u60C5\u3001/del <id> \u5220\u9664
|
|
845
845
|
|
|
846
846
|
\u5BF9\u8BDD\u8981\u6C42\uFF1A
|
|
@@ -923,11 +923,27 @@ var SessionManager = class {
|
|
|
923
923
|
}
|
|
924
924
|
extractReply(output) {
|
|
925
925
|
const lines = output.split("\n");
|
|
926
|
-
const
|
|
926
|
+
const metaPrefixes = ["[client]", "[tool]", "[thinking]", "[done]", "[error]", "[warn]", "[info]"];
|
|
927
|
+
const blocks = [];
|
|
928
|
+
let current = [];
|
|
929
|
+
for (const line of lines) {
|
|
927
930
|
const t = line.trim();
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
+
if (metaPrefixes.some((p) => t.startsWith(p))) {
|
|
932
|
+
if (current.length > 0) {
|
|
933
|
+
blocks.push(current.join("\n").trim());
|
|
934
|
+
current = [];
|
|
935
|
+
}
|
|
936
|
+
} else {
|
|
937
|
+
current.push(line);
|
|
938
|
+
}
|
|
939
|
+
}
|
|
940
|
+
if (current.length > 0) {
|
|
941
|
+
blocks.push(current.join("\n").trim());
|
|
942
|
+
}
|
|
943
|
+
for (let i = blocks.length - 1; i >= 0; i--) {
|
|
944
|
+
if (blocks[i].length > 0) return blocks[i];
|
|
945
|
+
}
|
|
946
|
+
return output.trim();
|
|
931
947
|
}
|
|
932
948
|
async appendSummary(userId, userText, aiReply) {
|
|
933
949
|
const userDir = path5.join(this.sessionDir, userId);
|