← 返回
未分类

Qwen Web Agent

Browser automation for 通义千问 (Qwen) web interface at qianwen.com. Use when the agent needs to ask questions to Qwen AI and get back responses via browser auto...
在 qianwen.com 上对通义千问(Qwen)网页界面进行浏览器自动化。当需要向 Qwen AI 提问并通过浏览器获取回复时使用。
dereksongyang dereksongyang 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 289
下载
💾 0
安装
1
版本
#latest

概述

Qwen Web Agent

Browser automation for 通义千问 (qianwen.com) using Playwright. Login session persists at ~/.qwen_session/.

Quick Start

Single-turn

python scripts/qwen_agent.py "你的问题"
echo "你的问题" | python scripts/qwen_agent.py

Multi-turn

printf "问题1\n问题2\n关闭" | python scripts/qwen_multi_agent.py

First Run (Manual Login Required)

The first launch opens a Chromium window — complete login in the browser, then the script continues automatically. Subsequent runs reuse the saved session.

Scripts

scripts/qwen_agent.py

Single-turn Q&A. Sends one query, waits for the streaming response to stabilize, saves to last_output.md, then cleans up the conversation.

Parameters:

  • --timeout N: Override timeout in seconds (default 120)

scripts/qwen_multi_agent.py

Multi-turn conversation. Reads queries from stdin line by line, maintains conversation context, writes all turns to qwen_session_history.md.

Exit commands: 关闭, exit, quit, or EOF

Environment Requirements

  • Python 3.x
  • pip install playwright python-dotenv
  • playwright install chromium
  • Display server (X11/Wayland) or Xvfb for headed mode

Architecture

Both scripts use Playwright async API with a persistent browser context. The response capture logic polls DOM selectors (#qk-markdown-react, .chat-answers-card-wrap, etc.) until the text stabilizes (streaming detection). Multi-turn additionally tracks response element count to distinguish new responses from cached ones.

References

See references/使用说明.md for detailed usage documentation.

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-11 04:55 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-agent

Self-Improving + Proactive Agent

ivangdavila
自我反思+自我批评+自我学习+自组织记忆。智能体评估自身工作、发现错误并持续改进。
★ 1,441 📥 328,052
ai-agent

Find Skills

root
帮助用户发现和安装智能体技能,当用户询问如「如何做X」、「找X的技能」、「有能做...的吗」等问题时
★ 1,516 📥 571,861
ai-agent

self-improving agent

pskoett
记录自身发现以实现自我改进的技能
★ 4,161 📥 932,186