' +
'" +
'
' + escapeHtml(argsStr) + "
" +
@@ -1689,6 +1691,23 @@ export class AgentChat extends Model {
});
}
+ private objectLabel(args: Record
): string {
+ return (args.name || args.title || args.path || args.id || "") as string;
+ }
+
+ private toolActionLabel(action: string): string {
+ const L = window.siyuan.languages;
+ const labels: Record = {
+ "append": L.agentActionAppend || "add content",
+ "update": L.agentActionUpdate || "modify",
+ "delete": L.agentActionDelete || "delete",
+ "create": L.agentActionCreate || "create",
+ "move": L.agentActionMove || "move",
+ "rename": L.agentActionRename || "rename",
+ };
+ return labels[action] || action;
+ }
+
private formatMessageTime(ts: number): string {
const d = dayjs(ts);
if (d.format("YYYY-MM-DD") === dayjs().format("YYYY-MM-DD")) {