File tree Expand file tree Collapse file tree
packages/core/src/tracing/vercel-ai Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -111,15 +111,15 @@ export function convertAvailableToolsToJsonString(tools: unknown[]): string {
111111 */
112112function filterMessagesArray ( input : unknown [ ] ) : { role : string ; content : string } [ ] {
113113 return input . filter (
114- ( m : unknown ) : m is { role : string ; content : string } => ! ! m && typeof m === 'object' && 'role' in m && 'content' in m ,
114+ ( m : unknown ) : m is { role : string ; content : string } =>
115+ ! ! m && typeof m === 'object' && 'role' in m && 'content' in m ,
115116 ) ;
116117}
117118
118119/**
119120 * Normalize the user input (stringified object with prompt, system, messages) to messages array
120121 */
121122export function convertUserInputToMessagesFormat ( userInput : string ) : { role : string ; content : string } [ ] {
122- console . log ( 'convertUserInputStringToMessagesFormat' , userInput ) ;
123123 try {
124124 const p = JSON . parse ( userInput ) ;
125125 if ( ! ! p && typeof p === 'object' ) {
@@ -172,7 +172,6 @@ export function convertUserInputToMessagesFormat(userInput: string): { role: str
172172 * invoke_agent op
173173 */
174174export function requestMessagesFromPrompt ( span : Span , attributes : SpanAttributes ) : void {
175- console . log ( 'attributes' , attributes ) ;
176175 if (
177176 typeof attributes [ AI_PROMPT_ATTRIBUTE ] === 'string' &&
178177 ! attributes [ GEN_AI_INPUT_MESSAGES_ATTRIBUTE ] &&
You can’t perform that action at this time.
0 commit comments