Skip to content

Commit 8c64c29

Browse files
authored
bump to 0.5.0, add stealth to templates (#15)
* bump to 0.5.0 * stealthify
1 parent a975bba commit 8c64c29

File tree

11 files changed

+13
-10
lines changed

11 files changed

+13
-10
lines changed

templates/python/browser-use/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ async def bu_task(ctx: kernel.KernelContext, input_data: TaskInput):
2828
An object with final_result and errors properties
2929
"""
3030

31-
kernel_browser = client.browsers.create(invocation_id=ctx.invocation_id)
31+
kernel_browser = client.browsers.create(invocation_id=ctx.invocation_id, stealth=True)
3232
print("Kernel browser live view url: ", kernel_browser.browser_live_view_url)
3333
agent = Agent(
3434
#task="Compare the price of gpt-4o and DeepSeek-V3",

templates/python/browser-use/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ readme = "README.md"
66
requires-python = ">=3.11"
77
dependencies = [
88
"browser-use~=0.2.4",
9-
"kernel==0.4.0",
9+
"kernel>=0.5.0",
1010
"langchain-openai>=0.3.11",
1111
"pydantic>=2.10.6",
1212
]

templates/python/persistent-browser/main.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ async def get_page_title(ctx: kernel.KernelContext, input_data: PageTitleInput)
4646
# Create a browser instance using the context's invocation_id and a persistent id
4747
kernel_browser = client.browsers.create(
4848
invocation_id=ctx.invocation_id,
49-
persistence={"id": "my-awesome-persistent-browser-2"}
49+
persistence={"id": "my-awesome-persistent-browser-2"},
50+
stealth=True,
5051
)
5152
print("Kernel browser live view url: ", kernel_browser.browser_live_view_url)
5253

templates/python/persistent-browser/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ version = "0.1.0"
44
description = "Basic Kernel application that demonstrates the use of persistent browsers"
55
readme = "README.md"
66
requires-python = ">=3.11"
7-
dependencies = ["kernel==0.4.0", "playwright>=1.52.0"]
7+
dependencies = ["kernel>=0.5.0", "playwright>=1.52.0"]
88

99
[dependency-groups]
1010
dev = ["mypy>=1.15.0"]

templates/python/sample-app/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ version = "0.1.0"
44
description = "Kernel application template - Python"
55
readme = "README.md"
66
requires-python = ">=3.11"
7-
dependencies = ["kernel==0.4.0", "playwright>=1.52.0"]
7+
dependencies = ["kernel>=0.5.0", "playwright>=1.52.0"]
88

99
[dependency-groups]
1010
dev = ["mypy>=1.15.0"]

templates/typescript/computer-use/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"typescript": "^5"
88
},
99
"dependencies": {
10-
"@onkernel/sdk": "0.3.0",
10+
"@onkernel/sdk": ">=0.5.0",
1111
"playwright": "^1.52.0",
1212
"@anthropic-ai/sdk": "0.52.0",
1313
"luxon": "3.6.0"

templates/typescript/persistent-browser/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ app.action<PageTitleInput, PageTitleOutput>(
5151
persistence: {
5252
id: "ts-persistent-browser",
5353
},
54+
stealth: true,
5455
});
5556

5657
console.log(

templates/typescript/persistent-browser/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"typescript": "^5"
88
},
99
"dependencies": {
10-
"@onkernel/sdk": "0.4.0",
10+
"@onkernel/sdk": ">=0.5.0",
1111
"playwright": "^1.52.0"
1212
}
1313
}

templates/typescript/sample-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"typescript": "^5"
88
},
99
"dependencies": {
10-
"@onkernel/sdk": "0.4.0",
10+
"@onkernel/sdk": ">=0.5.0",
1111
"playwright": "^1.52.0"
1212
}
1313
}

templates/typescript/stagehand/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { Kernel, type KernelContext } from '@onkernel/sdk';
21
import { Stagehand } from "@browserbasehq/stagehand";
2+
import { Kernel, type KernelContext } from '@onkernel/sdk';
33
import { z } from 'zod';
44

55
const kernel = new Kernel();
@@ -40,6 +40,7 @@ app.action<SearchQueryInput, SearchQueryOutput>(
4040

4141
const kernelBrowser = await kernel.browsers.create({
4242
invocation_id: ctx.invocation_id,
43+
stealth: true,
4344
});
4445

4546
console.log("Kernel browser live view url: ", kernelBrowser.browser_live_view_url);

0 commit comments

Comments
 (0)