From 0a4aef114df17ff14062435421bb4c8e287bc70c Mon Sep 17 00:00:00 2001 From: 2829798842 <2829798842@qq.com> Date: Wed, 28 May 2025 19:16:06 +0800 Subject: [PATCH] Update change_relationship.py --- src/tools/not_used/change_relationship.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/tools/not_used/change_relationship.py b/src/tools/not_used/change_relationship.py index b038a3e6..e543f3c5 100644 --- a/src/tools/not_used/change_relationship.py +++ b/src/tools/not_used/change_relationship.py @@ -8,13 +8,13 @@ logger = get_logger("relationship_tool") class RelationshipTool(BaseTool): name = "change_relationship" - description = "根据收到的文本和回复内容,修改与特定用户的关系值,当你回复了别人的消息,你可以使用这个工具" + description = "Modify relationship value with specific user based on received text and reply content, you can use this tool when you reply to someone's message" parameters = { "type": "object", "properties": { - "text": {"type": "string", "description": "收到的文本"}, - "changed_value": {"type": "number", "description": "变更值"}, - "reason": {"type": "string", "description": "变更原因"}, + "text": {"type": "string", "description": "Received text"}, + "changed_value": {"type": "number", "description": "Change value"}, + "reason": {"type": "string", "description": "Reason for change"}, }, "required": ["text", "changed_value", "reason"], } @@ -34,8 +34,8 @@ class RelationshipTool(BaseTool): changed_value = function_args.get("changed_value") reason = function_args.get("reason") - return {"content": f"因为你刚刚因为{reason},所以你和发[{text}]这条消息的人的关系值变化为{changed_value}"} + return {"content": f"Because you just {reason}, your relationship value with the person who sent [{text}] has changed by {changed_value}"} except Exception as e: - logger.error(f"修改关系值时发生错误: {str(e)}") - return {"content": f"修改关系值失败: {str(e)}"} + logger.error(f"Error occurred while modifying relationship value: {str(e)}") + return {"content": f"Failed to modify relationship value: {str(e)}"}