File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 6
6
GET_ELEMENT_SELECTORS_CONTEXT ,
7
7
HELP_CONTEXT
8
8
} from './context'
9
- import { isObject } from '../shared'
9
+ import { isObject , logStart , logSuccess } from '../shared'
10
10
11
11
type OpenAIChatModel =
12
12
| 'gpt-4-0125-preview'
@@ -105,7 +105,7 @@ export function createCrawlOpenAI(
105
105
} = option
106
106
107
107
const spinner = ora (
108
- `AI is answering your question, please wait a moment`
108
+ logStart ( `AI is answering your question, please wait a moment` )
109
109
) . start ( )
110
110
const completion = await openai . chat . completions . create ( {
111
111
model,
@@ -117,7 +117,7 @@ export function createCrawlOpenAI(
117
117
response_format : { type : responseFormatType } ,
118
118
temperature : 0.1
119
119
} )
120
- spinner . succeed ( `AI has completed your question` )
120
+ spinner . succeed ( logSuccess ( `AI has completed your question` ) )
121
121
122
122
const content = completion . choices [ 0 ] . message . content
123
123
const result =
You can’t perform that action at this time.
0 commit comments