-
Notifications
You must be signed in to change notification settings - Fork 15
docs: use Luna xhigh in V4 examples #284
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -21,7 +21,8 @@ run = client.runs.create( | |
| ```typescript TypeScript | ||
| const run = await client.runs.create({ | ||
| task: "Download my latest invoice", | ||
| model: "grok-4.5", | ||
| model: "gpt-5.6-luna", | ||
| modelParams: { reasoning: { effort: "xhigh" } }, | ||
| browserSettings: { | ||
| profileId: "YOUR_PROFILE_ID", | ||
| proxyCountryCode: "us", | ||
|
|
@@ -43,7 +44,10 @@ the code. Then continue with the same session: | |
| first = client.runs.create( | ||
| "Open the login page and stop at the 2FA prompt", | ||
| ) | ||
| ready = client.runs.wait_for_event(first.id, "browser.ready") | ||
| client.runs.wait_for_completion(first.id) | ||
| print(ready.data["live_view_url"]) | ||
| input("Press Enter after entering the 2FA code...") | ||
|
|
||
| next_run = client.runs.create( | ||
| "Continue after login and download the invoice", | ||
|
|
@@ -53,13 +57,20 @@ next_run = client.runs.create( | |
| ```typescript TypeScript | ||
| const first = await client.runs.create({ | ||
| task: "Open the login page and stop at the 2FA prompt", | ||
| model: "grok-4.5", | ||
| model: "gpt-5.6-luna", | ||
| modelParams: { reasoning: { effort: "xhigh" } }, | ||
| }); | ||
| const ready = await client.runs.waitForEvent(first.id, "browser.ready"); | ||
| await client.runs.waitForCompletion(first.id); | ||
| console.log(ready.data.live_view_url); | ||
| await new Promise((resolve) => { | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P3: After the human presses Enter, this promise resolves but nothing pauses or closes Prompt for AI agents |
||
| process.stdin.once("data", resolve); | ||
| }); | ||
|
|
||
| const nextRun = await client.runs.create({ | ||
| task: "Continue after login and download the invoice", | ||
| model: "grok-4.5", | ||
| model: "gpt-5.6-luna", | ||
| modelParams: { reasoning: { effort: "xhigh" } }, | ||
| sessionId: first.sessionId, | ||
| }); | ||
| ``` | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.