fix: 将所有emoji/Unicode特殊字符替换为ASCII安全字符
Windows cmd/PowerShell默认codepage下emoji显示为?号。 全局替换: 👋->移除, 💭->[Thinking], ⚙->*, ✓->[OK], ✗->[FAIL], ◆->>, ⚠->[!], ✅->[OK], •->|/-, →->>>, ✏️->[Edit]等。 ❯保留(windows-vtp终端下正常显示)。 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -87,7 +87,7 @@ public class FileEditTool implements Tool {
|
||||
long oldLines = oldString.lines().count();
|
||||
long newLines = newString.lines().count();
|
||||
|
||||
return "✅ Edited " + path + " (replaced " + oldLines + " lines with " + newLines + " lines)";
|
||||
return "[OK] Edited " + path + " (replaced " + oldLines + " lines with " + newLines + " lines)";
|
||||
|
||||
} catch (IOException e) {
|
||||
return "Error editing file: " + e.getMessage();
|
||||
@@ -96,6 +96,6 @@ public class FileEditTool implements Tool {
|
||||
|
||||
@Override
|
||||
public String activityDescription(Map<String, Object> input) {
|
||||
return "✏️ Editing " + input.getOrDefault("file_path", "file");
|
||||
return "[Edit] " + input.getOrDefault("file_path", "file");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user