File tree Expand file tree Collapse file tree 1 file changed +10
-5
lines changed
examples/nodejs/workflows Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Original file line number Diff line number Diff line change 1- // Test script for the simplified proxy approach
21import 'dotenv/config' ;
3- import { Langbase } from 'langbase' ;
2+ import { Langbase , Workflow } from 'langbase' ;
43
54// Create Langbase instance
65const langbase = new Langbase ( {
@@ -10,9 +9,15 @@ const langbase = new Langbase({
109async function main ( ) {
1110 // Create a workflow with debug mode enabled
1211 const workflow = langbase . workflow ( {
13- name : 'simplified-proxy-test ' ,
14- debug : true , // Enable debug logging
12+ name : 'Test Agent Workflow ' ,
13+ debug : true ,
1514 } ) ;
15+ // OR
16+ // const workflow = new Workflow({
17+ // name: 'Test Agent Workflow',
18+ // debug: true,
19+ // langbase,
20+ // });
1621
1722 try {
1823 // STEP 1: Call langbase.agent.run but don't return its result directly
@@ -76,7 +81,7 @@ async function main() {
7681 } catch ( error ) {
7782 console . error ( '❌ Workflow error:' , error ) ;
7883 } finally {
79- // End the workflow to show trace report
84+ // End the workflow to send trace
8085 workflow . end ( ) ;
8186 }
8287}
You can’t perform that action at this time.
0 commit comments