Files
nanobot/tests/e2e/pages/login.html
T
95160a304d feat(tools): add model-agnostic computer use (computer_use + browser tools)
Adds two opt-in agent tools for controlling a computer:
- computer_use: pixel-based (screenshot + mouse/keyboard) via a desktop
  (pyautogui) or browser (playwright) backend.
- browser: DOM/accessibility-based web automation (act by element ref),
  reliable across ANY tool-calling model, not just vision/CU-trained ones.

Core enabler in the runner: a tool may return image content blocks, which
are split out and delivered to the model as a follow-up user message
(_split_tool_result_media), so screenshots reach any vision provider
(e.g. via OpenRouter/openai-compat) without provider-specific code.

Both tools are OFF by default (tools.computerUse.enable / tools.browser.enable),
are not exposed to subagents, and the browser tool supports an allowed_domains
allowlist. Heavy deps (pyautogui/pillow/playwright) are an optional [computer-use] extra.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-08-09 01:12:13 +09:00

25 lines
750 B
HTML

<!doctype html>
<html><head><meta charset="utf-8"><title>Login</title></head>
<body>
<h1>Sign in</h1>
<form onsubmit="return go(event)">
<p><input id="user" aria-label="Username" placeholder="Username"></p>
<p><input id="pass" type="password" aria-label="Password" placeholder="Password"></p>
<button type="submit">Log in</button>
</form>
<div id="err"></div>
<script>
function go(e){
e.preventDefault();
var u = document.getElementById('user').value;
var p = document.getElementById('pass').value;
if (u === 'admin' && p === 'secret') {
location.href = 'dashboard.html?user=' + encodeURIComponent(u);
} else {
document.getElementById('err').textContent = 'Invalid credentials';
}
return false;
}
</script>
</body></html>