File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,6 @@ async function basic() {
2727const HackerNewsResponse = z . object ( {
2828 title : z . string ( ) ,
2929 url : z . string ( ) ,
30- score : z . number ( ) ,
3130} ) ;
3231
3332const TaskOutput = z . object ( {
@@ -39,7 +38,7 @@ async function structured() {
3938
4039 // Create Task
4140 const rsp = await browseruse . tasks . run ( {
42- task : 'Search for the top 10 Hacker News posts and return the title, url, and score ' ,
41+ task : 'Search for the top 10 Hacker News posts and return the title and url! ' ,
4342 schema : TaskOutput ,
4443 agentSettings : { llm : 'gpt-4.1' } ,
4544 } ) ;
@@ -53,7 +52,7 @@ async function structured() {
5352 console . log ( `Structured: Top Hacker News posts:` ) ;
5453
5554 for ( const post of posts ) {
56- console . log ( `${ post . title } ( ${ post . score } ) - ${ post . url } ` ) ;
55+ console . log ( ` - ${ post . title } - ${ post . url } ` ) ;
5756 }
5857
5958 console . log ( `\nStructured: DONE` ) ;
You can’t perform that action at this time.
0 commit comments