Jarvis-Brain 0.1.7.5__tar.gz → 0.1.7.6__tar.gz

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: Jarvis_Brain
3
- Version: 0.1.7.5
3
+ Version: 0.1.7.6
4
4
  Summary: Jarvis brain mcp
5
5
  Requires-Python: >=3.10
6
6
  Requires-Dist: beautifulsoup4
@@ -105,6 +105,8 @@ def register_check_selector(mcp: FastMCP, browser_manager, client_manager: DPPro
105
105
  attr_output = "\n".join(ele_text_list)
106
106
  else:
107
107
  attr_output = json.dumps([i.attr(attr_name) for i in target_eles])
108
+ # 对attr_output逐个截断,截断的长度为:一轮最大token除以元素个数+6个点
109
+ attr_output = [attr_str[:one_turn_max_token // (len(attr_str) + 6)] + "......" for attr_str in attr_output]
108
110
  return dp_mcp_message_pack(
109
111
  f"已完成tab页:【{tab_id}】对:【{css_selector}】的检查",
110
112
  tab_id=tab_id,
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "Jarvis_Brain" # 别人下载时用的名字,必须在 PyPI 上唯一
3
- version = "0.1.7.5"
3
+ version = "0.1.7.6"
4
4
  description = "Jarvis brain mcp"
5
5
  dependencies = [
6
6
  "fastmcp",
File without changes
File without changes