Skip to content

Conversation

@krichprollsch
Copy link
Member

https://docs.stagehand.dev/

import "dotenv/config";
import { Stagehand } from "@browserbasehq/stagehand";
import { z } from "zod/v3";

async function main() {
 const stagehand = new Stagehand({
    env: "LOCAL",
	localBrowserLaunchOptions: {
		cdpUrl: "ws://127.0.0.1:9222"
	},
    model: "ollama/qwen3:1.7b",
  });

  await stagehand.init();
  const page = stagehand.context.pages()[0];

  await page.goto("https://demo-browser.lightpanda.io/");

  // Act on the page
  await stagehand.act("Click the Campfire link")
  const price = await stagehand.extract("product price", z.string())

    console.log(price);

  await stagehand.close();
}

main().catch((err) => {
  console.error(err);
  process.exit(1);
});

@krichprollsch
Copy link
Member Author

krichprollsch commented Nov 18, 2025

@karlseguin : this is a work in progress, but Stagehand relies on existing Chrome's default target.
So the STARTUP session hack doesn't work with it...

@krichprollsch
Copy link
Member Author

Next blocker Accessibility.getFullAXTree

> {"id":36,"method":"Accessibility.getFullAXTree","params":{"frameId":"TID-1"},"sessionId":"SID-1"}
< {"id":36,"error":{"code":-31998,"message":"UnknownMethod"},"sessionId":"SID-1"}

@spolu
Copy link

spolu commented Nov 27, 2025

Exciting \o/ One last bit :)

@kevbook
Copy link

kevbook commented Dec 10, 2025

In Stagehand, in agent mode, screenshots are sent to AI models to understand where to click, what to do next. How can we solve these?

See: https://docs.stagehand.dev/v3/configuration/models#agent-models-with-cua-support

@krichprollsch
Copy link
Member Author

krichprollsch commented Dec 10, 2025

Lightpanda can't provide screenshot, so we won't be compatible with computer use agents.

In the future, we think of adding kind of text rendering, something similar to lynx maybe, that could be helpful for this use cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants