@keyou007/agent-bot 0.1.13-alpha.3 → 0.1.13-alpha.4
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/CHANGELOG.md +5 -0
- package/dist/cli/DefaultAgentSelection.js +16 -2
- package/dist/cli/DefaultAgentSelection.js.map +1 -1
- package/dist/cli/InitializationWelcome.js +20 -42
- package/dist/cli/InitializationWelcome.js.map +1 -1
- package/dist/cli/Initializer.js +44 -0
- package/dist/cli/Initializer.js.map +1 -1
- package/dist/cli/help.js +2 -2
- package/dist/cli.js +80 -30
- package/dist/cli.js.map +1 -1
- package/dist/feishu/CardRenderer.js +15 -30
- package/dist/feishu/CardRenderer.js.map +1 -1
- package/docs/technical-reference.md +2 -2
- package/docs/technical-reference.zh.md +2 -2
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
- package/skills/agent-bot/SKILL.md +1 -1
- package/src/cli/DefaultAgentSelection.ts +19 -2
- package/src/cli/InitializationWelcome.ts +19 -44
- package/src/cli/Initializer.ts +67 -0
- package/src/cli/help.ts +2 -2
- package/src/cli.ts +112 -31
- package/src/feishu/CardRenderer.ts +15 -31
|
@@ -45,7 +45,6 @@ export interface InitializationWelcomeFeature {
|
|
|
45
45
|
|
|
46
46
|
export interface InitializationWelcomeView {
|
|
47
47
|
kind: InitializationWelcomeKind;
|
|
48
|
-
language: "en" | "zh";
|
|
49
48
|
version: string;
|
|
50
49
|
previousVersion?: string;
|
|
51
50
|
activationPending?: boolean;
|
|
@@ -701,33 +700,26 @@ export class CardRenderer {
|
|
|
701
700
|
}
|
|
702
701
|
|
|
703
702
|
renderInitializationWelcome(view: InitializationWelcomeView): Record<string, unknown> {
|
|
704
|
-
const chinese = view.language === "zh";
|
|
705
703
|
const title = view.kind === "first"
|
|
706
|
-
?
|
|
704
|
+
? "欢迎使用 Agent Bot"
|
|
707
705
|
: view.kind === "upgrade"
|
|
708
|
-
?
|
|
709
|
-
:
|
|
706
|
+
? "Agent Bot 已更新"
|
|
707
|
+
: "Agent Bot 已准备就绪";
|
|
710
708
|
const subtitle = view.activationPending
|
|
711
|
-
?
|
|
709
|
+
? "配置已完成,安全重启后生效"
|
|
712
710
|
: view.kind === "first"
|
|
713
|
-
?
|
|
711
|
+
? "本地 Agent 已接入飞书"
|
|
714
712
|
: view.kind === "upgrade"
|
|
715
|
-
?
|
|
716
|
-
:
|
|
713
|
+
? `新版本 ${view.version} 已生效`
|
|
714
|
+
: "初始化配置已刷新";
|
|
717
715
|
const activationNote = view.activationPending
|
|
718
|
-
?
|
|
716
|
+
? "当前任务完成并安全重启后生效。"
|
|
719
717
|
: undefined;
|
|
720
718
|
const intro = view.kind === "first"
|
|
721
|
-
?
|
|
722
|
-
? "**初始化完成**\n从现在起,你可以直接在飞书里把任务交给本机 Agent,并随时查看进度、切换任务或创建分支。"
|
|
723
|
-
: "**Setup complete**\nYou can now work with local Agents from Lark, follow progress, switch tasks, and branch conversations.")
|
|
719
|
+
? "**初始化完成**\n从现在起,你可以直接在飞书里把任务交给本机 Agent,并随时查看进度、切换任务或创建分支。"
|
|
724
720
|
: view.kind === "upgrade"
|
|
725
|
-
? (
|
|
726
|
-
|
|
727
|
-
: `**Upgrade complete**\n${view.previousVersion ? `${inlineCode(view.previousVersion)} → ` : ""}${inlineCode(view.version)} is ready. ${activationNote ?? "Here is what is new."}`)
|
|
728
|
-
: (chinese
|
|
729
|
-
? `**配置刷新完成**\n${inlineCode(view.version)} 已重新检查配置、Agent 和飞书连接。${activationNote ?? ""}`
|
|
730
|
-
: `**Configuration refreshed**\n${inlineCode(view.version)} rechecked your configuration, Agents, and Lark connection. ${activationNote ?? ""}`);
|
|
721
|
+
? `**升级完成**\n${view.previousVersion ? `${inlineCode(view.previousVersion)} → ` : ""}${inlineCode(view.version)} 已准备好。${activationNote ?? "下面是本版值得关注的能力。"}`
|
|
722
|
+
: `**配置刷新完成**\n${inlineCode(view.version)} 已重新检查配置、Agent 和飞书连接。${activationNote ?? ""}`;
|
|
731
723
|
const logo = {
|
|
732
724
|
...localCardImage(view.logoPath, "Agent Bot logo"),
|
|
733
725
|
preview: false,
|
|
@@ -797,24 +789,16 @@ export class CardRenderer {
|
|
|
797
789
|
],
|
|
798
790
|
},
|
|
799
791
|
{ tag: "hr" },
|
|
800
|
-
markdown(
|
|
801
|
-
? `**${view.kind === "upgrade" ? "本版亮点" : "你可以这样使用"}**`
|
|
802
|
-
: `**${view.kind === "upgrade" ? "What's new" : "What you can do"}**`),
|
|
792
|
+
markdown(`**${view.kind === "upgrade" ? "本版亮点" : "你可以这样使用"}**`),
|
|
803
793
|
...featureRows,
|
|
804
794
|
{ tag: "hr" },
|
|
805
|
-
markdown(
|
|
806
|
-
? "> 直接发送消息即可开始;发送 `/new` 创建新任务;发送 `/help` 查看全部命令。"
|
|
807
|
-
: "> Send a message to begin, `/new` for a new task, or `/help` for all commands."),
|
|
795
|
+
markdown("> 直接发送消息即可开始;发送 `/new` 创建新任务;发送 `/help` 查看全部命令。"),
|
|
808
796
|
{
|
|
809
|
-
...markdown(
|
|
810
|
-
? `**版本** ${inlineCode(view.version)} · **默认 Agent** ${inlineCode(view.defaultAgentTitle)} · **可用 Agent** ${availableAgents}`
|
|
811
|
-
: `**Version** ${inlineCode(view.version)} · **Default Agent** ${inlineCode(view.defaultAgentTitle)} · **Available** ${availableAgents}`),
|
|
797
|
+
...markdown(`**版本** ${inlineCode(view.version)} · **默认 Agent** ${inlineCode(view.defaultAgentTitle)} · **可用 Agent** ${availableAgents}`),
|
|
812
798
|
text_size: "notation",
|
|
813
799
|
},
|
|
814
800
|
{
|
|
815
|
-
...markdown(
|
|
816
|
-
? "📋 [查看更新日志](https://github.com/keyou/agent-bot/blob/master/CHANGELOG.md)"
|
|
817
|
-
: "📋 [View Changelog](https://github.com/keyou/agent-bot/blob/master/CHANGELOG.md)"),
|
|
801
|
+
...markdown("📋 [查看更新日志](https://github.com/keyou/agent-bot/blob/master/CHANGELOG.md)"),
|
|
818
802
|
text_size: "notation",
|
|
819
803
|
},
|
|
820
804
|
],
|