This runs the collection without an AI agent: it opens each provider in
Playwright's own Chromium, using a dedicated profile (default ~/.polyhelper-chrome — a
separate profile you log into once by hand, not your everyday Chrome; the login persists
there, and your normal browser, cookies and extensions are never touched),
pastes the question, tries to enable the deep mode, submits, waits, grabs the answer, and
saves each to a file.
This is an early skeleton, not the product. It does the collection
step only; it does not do the fan-out pipeline or the synthesis (anchor-and-enrich /
FINAL document). It also works through the providers one at a time, in order — the
parallel fan-out you see in the diagrams describes the AI-agent path, not this script.
With many providers enabled and a long --wait, a run can therefore take hours; start with
two or three providers via --providers. After it saves the NN-*.md files, you hand them to an AI agent to merge
(see ../AGENT-PROMPT.md, manual-import mode). Site layouts also change weekly, and the
deep-mode toggles and answer containers are best-effort selectors in providers.yaml; when a
site changes, that provider fails and you update its entry. The robust path is the AI-agent
method in the parent README.md — an agent adapts to UI changes; this script does not.
Run these from this script/ folder (cd script first — the files live here, not in the repo root):
python3 -m pip install -r requirements.txt
python3 -m playwright install chromium
python3 orchestrate.py "your question" --set western # ChatGPT, Claude, Gemini, Grok, Copilot
python3 orchestrate.py "your question" --set chinese # DeepSeek, Qwen, Kimi, GLM, Ernie
python3 orchestrate.py "your question" --set free # the ones with usable free tiers
python3 orchestrate.py "your question" --providers chatgpt,claude,deepseek
The sets are plain lists at the top of providers.yaml — edit them or add your own.
Start with two or three; going through many providers one at a time takes a long time.
python3 orchestrate.py "Your question here" --mode fast --lang en
or read the question from a file:
python3 orchestrate.py --file my_question.txt
Options:
--mode fast|deep— fast = normal chat (quick, cheap); deep = each AI's deepest mode (slow, heavy on quotas)--lang en|zh|es|hi|ar|pt|fr|ja|de|ru— terminal language (default: auto from your system)--providers chatgpt,claude,gemini— only these (default: all enabled in providers.yaml)--profile "/path/to/chrome/profile"— use a specific Chrome user-data dir (so logins persist)--wait 1800— max seconds to wait per provider (default 1800 = 30 min)--out ~/Desktop/My-folder— output folder (default:~/Desktop/PolyHelper/<your question>-<day>, e.g.~/Desktop/PolyHelper/Photo-backup-31-Aug)
- Uses a persistent browser context (your logins stay). It does NOT store or type passwords.
- It does NOT solve CAPTCHAs. If a provider shows one, that provider is skipped with a note.
- It only pastes the question and reads the answer. Nothing irreversible.
- It saves
00-question.md,01-log.md, and oneNN-provider.mdper answer, numbered from 02 — the same shape the agent path produces, so a merge sees the answers and not the log. Synthesis is NOT done by this script — hand the saved files to an AI agent (../AGENT-PROMPT.md, manual-import mode) or merge them yourself following../docs/how-it-works.md. (There is no--synthesizeoption; earlier drafts mentioned one — it was never implemented.)
All per-site knowledge lives in providers.yaml: the input box, the deep-mode toggles to
click before sending, the send action, and the answer container. Update these when a site
changes. This is the maintenance treadmill every model in the report warned about — which is
exactly why the agent-driven method is recommended for regular use.