diff options
Diffstat (limited to 'data/zh_cn/paillmtrace/2024-03-11/api-docs.php')
| -rw-r--r-- | data/zh_cn/paillmtrace/2024-03-11/api-docs.php | 2754 |
1 files changed, 936 insertions, 1818 deletions
diff --git a/data/zh_cn/paillmtrace/2024-03-11/api-docs.php b/data/zh_cn/paillmtrace/2024-03-11/api-docs.php index fdee6ea..8128026 100644 --- a/data/zh_cn/paillmtrace/2024-03-11/api-docs.php +++ b/data/zh_cn/paillmtrace/2024-03-11/api-docs.php @@ -1,52 +1,30 @@ <?php return [ 'version' => '1.0', - 'info' => [ - 'style' => 'ROA', - 'product' => 'PaiLLMTrace', - 'version' => '2024-03-11', - ], + 'info' => ['style' => 'ROA', 'product' => 'PaiLLMTrace', 'version' => '2024-03-11'], 'directories' => [ [ - 'id' => 208975, - 'title' => '评估单条链路数据', + 'children' => ['EvaluateTrace'], 'type' => 'directory', - 'children' => [ - 'EvaluateTrace', - ], + 'title' => '评估单条链路数据', + 'id' => 128815, ], [ - 'id' => 204454, - 'title' => '链路评估任务', + 'children' => ['DeleteOnlineEvalTask', 'GetEvaluationTemplates', 'GetOnlineEvalTask', 'ListOnlineEvalTaskResults', 'ListOnlineEvalTasks', 'StopOnlineEvalTask', 'UpdateOnlineEvalTask', 'CreateOnlineEvalTask'], 'type' => 'directory', - 'children' => [ - 'DeleteOnlineEvalTask', - 'GetEvaluationTemplates', - 'GetOnlineEvalTask', - 'ListOnlineEvalTaskResults', - 'ListOnlineEvalTasks', - 'StopOnlineEvalTask', - 'UpdateOnlineEvalTask', - 'CreateOnlineEvalTask', - ], + 'title' => '链路评估任务', + 'id' => 128817, ], [ - 'id' => 204463, - 'title' => '链路追踪', + 'children' => ['ListTracesDatas'], 'type' => 'directory', - 'children' => [ - 'ListTracesDatas', - ], + 'title' => '链路追踪', + 'id' => 128826, ], [ - 'id' => 205090, - 'title' => '其他', + 'children' => ['GetXtraceToken', 'CreateServiceIdentityRole', 'GetServiceIdentityRole', 'ListEvalResults'], 'type' => 'directory', - 'children' => [ - 'CreateServiceIdentityRole', - 'GetServiceIdentityRole', - 'GetXtraceToken', - 'ListEvalResults', - ], + 'title' => '其他', + 'id' => 128828, ], ], 'components' => [ @@ -59,245 +37,130 @@ 'description' => '大模型回答问题时参考的上下文节点信息。', 'type' => 'object', 'properties' => [ - 'JsonPathInSpan' => [ - 'description' => '链路log里存放Context的json path。', - 'type' => 'string', - 'example' => 'attributes.retrieval.documents[*].document.content', - 'minLength' => 1, - ], - 'SpanName' => [ - 'description' => '链路log的span名称。', - 'type' => 'string', - 'example' => 'retrieve', - 'minLength' => 1, - ], - 'JsonPathInSpanValue' => [ - 'description' => '如果json path处取到的值本身仍然是json string,那么需要进一步定义这个json里的json path以获取实际的值。', - 'type' => 'string', - 'example' => 'message/value', - ], + 'JsonPathInSpan' => ['description' => '链路log里存放Context的json path。', 'type' => 'string', 'example' => 'attributes.retrieval.documents[*].document.content', 'minLength' => 1], + 'SpanName' => ['description' => '链路log的span名称。', 'type' => 'string', 'example' => 'retrieve', 'minLength' => 1], + 'JsonPathInSpanValue' => ['description' => '如果json path处取到的值本身仍然是json string,那么需要进一步定义这个json里的json path以获取实际的值。', 'type' => 'string', 'example' => 'message/value'], ], ], 'Answer' => [ 'description' => '基于大语言模型的应用针对用户问题的回答。', 'type' => 'object', 'properties' => [ - 'JsonPathInSpan' => [ - 'description' => '链路log里存放Answer的json path。', - 'type' => 'string', - 'example' => 'attributes.output.value', - 'minLength' => 1, - ], - 'SpanName' => [ - 'description' => '链路log的span名称。', - 'type' => 'string', - 'example' => 'query', - 'minLength' => 1, - ], - 'JsonPathInSpanValue' => [ - 'description' => '如果json path处取到的值本身仍然是json string,那么需要进一步定义这个json里的json path以获取实际的值。', - 'type' => 'string', - 'example' => 'message/value', - ], + 'JsonPathInSpan' => ['description' => '链路log里存放Answer的json path。', 'type' => 'string', 'example' => 'attributes.output.value', 'minLength' => 1], + 'SpanName' => ['description' => '链路log的span名称。', 'type' => 'string', 'example' => 'query', 'minLength' => 1], + 'JsonPathInSpanValue' => ['description' => '如果json path处取到的值本身仍然是json string,那么需要进一步定义这个json里的json path以获取实际的值。', 'type' => 'string', 'example' => 'message/value'], ], ], 'Query' => [ 'description' => '用户向基于大语言模型的应用提出的问题。', 'type' => 'object', 'properties' => [ - 'JsonPathInSpan' => [ - 'description' => '链路log里存放Query的json path。', - 'type' => 'string', - 'example' => 'attributes.input.value', - 'minLength' => 1, - ], - 'SpanName' => [ - 'description' => '链路log的span名称。', - 'type' => 'string', - 'example' => 'query', - 'minLength' => 1, - ], - 'JsonPathInSpanValue' => [ - 'description' => '如果json path处取到的值本身仍然是json string,那么需要进一步定义这个json里的json path以获取实际的值。', - 'type' => 'string', - 'example' => 'message/value', - ], + 'JsonPathInSpan' => ['description' => '链路log里存放Query的json path。', 'type' => 'string', 'example' => 'attributes.input.value', 'minLength' => 1], + 'SpanName' => ['description' => '链路log的span名称。', 'type' => 'string', 'example' => 'query', 'minLength' => 1], + 'JsonPathInSpanValue' => ['description' => '如果json path处取到的值本身仍然是json string,那么需要进一步定义这个json里的json path以获取实际的值。', 'type' => 'string', 'example' => 'message/value'], ], ], ], ], 'ModelConfig' => [ 'description' => '评估任务内部使用的大模型的访问配置结构体。', + 'visibility' => 'Public', 'type' => 'object', 'properties' => [ - 'Temperature' => [ - 'description' => '控制大模型输出随机性的温度参数。最大可设置到0.2。', - 'type' => 'number', - 'format' => 'float', - 'example' => '0.1', - ], - 'ApiKey' => [ - 'description' => '评估任务需要以用户名义调用用户有使用权的大模型时,需要填充的认证key。', - 'type' => 'string', - 'example' => 'lRQ6ny2BP1g73fsgf9O+Hr4DEedezQ', - ], - 'Endpoint' => [ - 'description' => '评估任务需要以用户名义调用用户有使用权的大模型时,需要填充的模型服务地址。', - 'type' => 'string', - 'example' => 'https://aiservice.cn-hangzhou.aliyuncs.com/v1', - ], - 'UseFunctionCall' => [ - 'description' => '评估任务需要以用户名义调用用户有使用权的大模型时,是否允许大模型调用外部工具。', - 'type' => 'boolean', - 'example' => 'True', - ], - 'TopP' => [ - 'description' => '控制大模型输出随机性的top p参数。', - 'type' => 'number', - 'format' => 'float', - 'example' => '0.9', - ], - 'Name' => [ - 'description' => '大模型的名称。', - 'type' => 'string', - 'example' => 'pai-judge'."\n" - .'themis'."\n" - .'qwen'."\n" - .'gpt', - ], - 'IsSelfHost' => [ - 'description' => '用户的大模型服务是自己提供的(True)、还是阿里云PAI提供的(False)。', - 'type' => 'boolean', - 'example' => 'False', - ], - ], - ], - 'QuestionAnswer' => [ - 'type' => 'object', - 'properties' => [ - 'Answer' => [ - 'type' => 'object', - 'properties' => [ - 'Text' => [ - 'type' => 'string', - ], - 'Contexts' => [ - 'type' => 'array', - 'items' => [ - 'type' => 'string', - ], - ], - ], - ], - 'Question' => [ - 'type' => 'string', - ], - 'GroundTruth' => [ - 'type' => 'object', - 'properties' => [ - 'Text' => [ - 'type' => 'string', - ], - 'Contexts' => [ - 'type' => 'array', - 'items' => [ - 'type' => 'string', - ], - ], - ], - ], + 'Temperature' => ['description' => '控制大模型输出随机性的温度参数。最大可设置到0.2。', 'visibility' => 'Public', 'type' => 'number', 'format' => 'float', 'example' => '0.1', 'backendName' => 'temperature'], + 'ApiKey' => ['description' => '评估任务需要以用户名义调用用户有使用权的大模型时,需要填充的认证key。', 'visibility' => 'Public', 'type' => 'string', 'example' => 'lRQ6ny2BP1g73fsgf9O+Hr4DEedezQ', 'backendName' => 'apiKey'], + 'Endpoint' => ['description' => '评估任务需要以用户名义调用用户有使用权的大模型时,需要填充的模型服务地址。', 'visibility' => 'Public', 'type' => 'string', 'example' => 'https://aiservice.cn-hangzhou.aliyuncs.com/v1', 'backendName' => 'endpoint'], + 'UseFunctionCall' => ['description' => '评估任务需要以用户名义调用用户有使用权的大模型时,是否允许大模型调用外部工具。', 'visibility' => 'Public', 'type' => 'boolean', 'example' => 'True', 'backendName' => 'useFunctionCall'], + 'TopP' => ['description' => '控制大模型输出随机性的top p参数。', 'visibility' => 'Public', 'type' => 'number', 'format' => 'float', 'example' => '0.9', 'backendName' => 'topP'], + 'Name' => ['description' => '大模型的名称。', 'visibility' => 'Public', 'type' => 'string', 'example' => 'pai-judge'."\n" + .'themis'."\n" + .'qwen'."\n" + .'gpt', 'backendName' => 'name'], + 'IsSelfHost' => ['description' => '用户的大模型服务是自己提供的(True)、还是阿里云PAI提供的(False)。', 'visibility' => 'Public', 'type' => 'boolean', 'example' => 'False', 'backendName' => 'isSelfHost'], ], ], ], ], 'apis' => [ - 'EvaluateTrace' => [ - 'summary' => '评估一条指定的trace数据。', - 'path' => '/api/v1/PAILLMTrace/eval/trace/{TraceId}', - 'methods' => [ - 'put', - ], - 'schemes' => [ - 'https', - ], + 'CreateOnlineEvalTask' => [ + 'summary' => '创建一个链路评估任务。系统会根据任务配置,从用户的链路数据里采样部分数据,用大模型对这些链路的执行效果做评估,并记录评估结果。', + 'path' => '/api/v1/PAILLMTrace/onlineevaltasks', + 'methods' => ['post'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ - 'operationType' => 'none', + 'operationType' => 'create', 'riskType' => 'none', 'chargeType' => 'free', - 'abilityTreeCode' => '246343', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], + 'abilityTreeCode' => '241117', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], 'tenantRelevance' => 'publicInformation', ], 'parameters' => [ [ - 'name' => 'TraceId', - 'in' => 'path', - 'schema' => [ - 'description' => '链路id', - 'type' => 'string', - 'required' => true, - 'example' => 'c43793673a384d39daa0a351b1000000', - ], - ], - [ 'name' => 'body', - 'in' => 'body', + 'in' => 'query', 'style' => 'json', 'schema' => [ - 'description' => '请求结构。', + 'description' => '请求Body。', 'type' => 'object', 'properties' => [ - 'AppName' => [ - 'description' => '链路数据所在的应用名称', - 'type' => 'string', - 'required' => false, - 'example' => 'my-llm-app', - ], - 'MinTime' => [ - 'description' => '搜索时间范围的UTC开始时间。', - 'type' => 'string', - 'required' => false, - 'example' => '2025-04-05 13:24:25'."\n" - .'2025-04-05', - ], - 'MaxTime' => [ - 'description' => '搜索时间范围的UTC结束时间。', - 'type' => 'string', - 'required' => false, - 'example' => '2025-04-05 13:24:25'."\n" - .'2025-04-05', - ], - 'EvaluationConfig' => [ - 'description' => '如果json path处取到的值本身仍然是json string,那么需要进一步定义这个json里的json path以获取实际的值。', - 'required' => true, - '$ref' => '#/components/schemas/EvaluationConfig', - ], - 'ModelConfig' => [ - 'description' => '评估链路功能内部使用的大模型的访问配置结构体。', - 'required' => false, - '$ref' => '#/components/schemas/ModelConfig', - ], - 'EvaluationId' => [ - 'description' => '评估任务的id。如果不指定,则系统会随机产生一个id返回给用户。用户可以凭借这个返回的任务id快速搜索评估结果。', - 'type' => 'string', + 'TaskName' => ['description' => '任务名称。', 'type' => 'string', 'required' => false, 'example' => 'my-llm-app-eval-task-1'], + 'AppName' => ['description' => '用户应用在链路数据里记录的名称', 'type' => 'string', 'required' => false, 'example' => 'my-best-llm-app'], + 'StartTime' => ['description' => '链路数据的UTC开始时间', 'type' => 'string', 'required' => false, 'example' => '2025-04-05 14:00:01'."\n" + .'2025-04-05'], + 'EndTime' => ['description' => '链路数据的UTC结束时间', 'type' => 'string', 'required' => false, 'example' => '2025-06-05 14:00:01'."\n" + .'2025-06-05'], + 'SamplingFrequencyMinutes' => ['description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义任务每次搜索输入数据的时间窗口的宽度。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '9'], + 'Description' => ['description' => '任务描述信息', 'type' => 'string', 'required' => false, 'example' => '4月到6月数据评估'], + 'Filters' => [ + 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义搜索筛选条件的列表。', + 'type' => 'array', + 'items' => [ + 'description' => '过滤条件对象。', + 'type' => 'object', + 'properties' => [ + 'Key' => [ + 'description' => '过滤条件的key', + 'type' => 'string', + 'required' => false, + 'enumValueTitles' => ['Status' => 'Status', 'SpanName' => 'SpanName', 'Input' => 'Input', 'TraceType' => 'TraceType', 'SpanType' => 'SpanType', 'ServiceName' => 'ServiceName', 'Output' => 'Output', 'TraceName' => 'TraceName', 'ServiceId' => 'ServiceId'], + 'example' => 'ServiceId'."\n" + .'ServiceName'."\n" + .'Input'."\n" + .'Output'."\n" + .'Status'."\n" + .'TraceType'."\n" + .'SpanType'."\n" + .'TraceName'."\n" + .'SpanName', + ], + 'Operator' => [ + 'description' => '过滤条件匹配操作符', + 'type' => 'string', + 'required' => false, + 'enumValueTitles' => ['Contains' => 'Contains', '=' => '=', 'StartsWith' => 'StartsWith'], + 'example' => '='."\n" + .'StartsWith'."\n" + .'Contains'."\n", + ], + 'Value' => ['description' => '过滤条件的值', 'type' => 'string', 'required' => false, 'example' => 'foo'], + ], + 'required' => false, + ], 'required' => false, - 'example' => '44aea0ee00000000be5be24b2abb8f98', ], + 'SamplingRatio' => ['description' => '评估任务在一个时间窗口里搜索到的数据,真正作为评估输入数据的百分比。比如100表示搜索到的所有数据都作为评估输入。又比如20表示从搜索到的数据里随机取20%作为评估输入。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '50'], + 'EvaluationConfig' => ['description' => '从json格式的链路数据里要一些提取特定路径上的值,作为评估操作的输入。在这个EvaluationConfig结构体里定义这些json路径。', 'required' => false, '$ref' => '#/components/schemas/EvaluationConfig'], + 'ModelConfig' => ['description' => '评估任务内部使用的大模型的访问配置结构体。', 'required' => false, '$ref' => '#/components/schemas/ModelConfig'], ], 'required' => false, ], @@ -310,57 +173,77 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => 'F1AB295E-0D1F-5ECE-9FFA-98ABB4CB5DF5', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'eval_request missing dataset id or times', - ], - 'EvaluationId' => [ - 'description' => '链路数据所属的评估任务的任务id。', - 'type' => 'string', - 'example' => '6000043e103011f0922edec44617e03c', - ], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'TaskId' => ['description' => '新创建的链路评估任务的id。', 'type' => 'string', 'example' => '711ef9112343286810abbfce04e161ee'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'EvaluationConfig.Answer.SpanName is required.'], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', + 'staticInfo' => ['returnType' => 'synchronous'], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"TaskId\\": \\"711ef9112343286810abbfce04e161ee\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"EvaluationConfig.Answer.SpanName is required.\\"\\n}","type":"json"}]', + 'title' => '创建一个链路评估任务。', + ], + 'CreateServiceIdentityRole' => [ + 'summary' => '创建PaiLLMTrace服务需要使用的服务关联角色。', + 'path' => '/api/v1/PAILLMTrace/ServiceIdentityRole', + 'methods' => ['post'], + 'schemes' => ['https'], + 'security' => [ + [ + 'AK' => [], + ], ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"F1AB295E-0D1F-5ECE-9FFA-98ABB4CB5DF5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"eval_request missing dataset id or times\\",\\n \\"EvaluationId\\": \\"6000043e103011f0922edec44617e03c\\"\\n}","type":"json"}]', - 'title' => '评估一条指定的链路数据。', + 'consumes' => ['application/json'], + 'produces' => ['application/json'], + 'operationType' => 'write', + 'deprecated' => false, + 'systemTags' => [ + 'operationType' => 'none', + 'riskType' => 'none', + 'chargeType' => 'free', + 'abilityTreeCode' => '226578', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], + 'tenantRelevance' => 'publicInformation', + ], + 'parameters' => [], + 'responses' => [ + 200 => [ + 'schema' => [ + 'title' => 'Schema of Response', + 'description' => 'Schema of Response', + 'type' => 'object', + 'properties' => [ + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'Code' => ['title' => '调用失败后的错误码。', 'description' => '调用失败后的错误码。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['title' => '调用失败后的错误信息。', 'description' => '调用失败后的错误信息。', 'type' => 'string', 'example' => 'User don\'t have permission to create SLR.'], + 'RoleName' => ['description' => '操作服务关联角色名称,默认值:AliyunServiceRoleForPaiLLMTrace。', 'type' => 'string', 'example' => 'AliyunServiceRoleForPaiLLMTrace'], + 'RoleDetails' => ['description' => '角色详细信息。', 'type' => 'string', 'example' => 'AliyunServiceRoleForPaiLLMTrace'], + ], + ], + ], + ], + 'staticInfo' => ['returnType' => 'synchronous'], + 'eventInfo' => [ + 'enable' => false, + 'eventNames' => [], + ], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"User don\'t have permission to create SLR.\\",\\n \\"RoleName\\": \\"AliyunServiceRoleForPaiLLMTrace\\",\\n \\"RoleDetails\\": \\"AliyunServiceRoleForPaiLLMTrace\\"\\n}","type":"json"}]', + 'title' => '创建服务关联角色。', ], 'DeleteOnlineEvalTask' => [ 'summary' => '删除一个链路评估任务。', 'path' => '/api/v1/PAILLMTrace/onlineevaltasks/{TaskId}', - 'methods' => [ - 'delete', - ], - 'schemes' => [ - 'https', - ], + 'methods' => ['delete'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ @@ -368,20 +251,13 @@ 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeCode' => '241122', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], ], 'parameters' => [ [ 'name' => 'TaskId', 'in' => 'path', - 'schema' => [ - 'description' => '链路评估任务的id。', - 'type' => 'string', - 'required' => true, - 'example' => '1d3f2shp3cfjum4l74odz5gkkh', - ], + 'schema' => ['description' => '链路评估任务的id。', 'type' => 'string', 'required' => true, 'example' => '1d3f2shp3cfjum4l74odz5gkkh'], ], ], 'responses' => [ @@ -391,61 +267,104 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'task id is empty', - ], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'task id is empty'], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], + 'staticInfo' => ['returnType' => 'synchronous'], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"task id is empty\\"\\n}","type":"json"}]', 'title' => '删除一个链路评估任务。', ], + 'EvaluateTrace' => [ + 'summary' => '评估一条指定的trace数据。', + 'path' => '/api/v1/PAILLMTrace/eval/trace/{TraceId}', + 'methods' => ['put'], + 'schemes' => ['https'], + 'security' => [ + [ + 'AK' => [], + ], + ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], + 'operationType' => 'write', + 'deprecated' => false, + 'systemTags' => [ + 'operationType' => 'none', + 'riskType' => 'none', + 'chargeType' => 'free', + 'abilityTreeCode' => '246343', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], + 'tenantRelevance' => 'publicInformation', + ], + 'parameters' => [ + [ + 'name' => 'TraceId', + 'in' => 'path', + 'schema' => ['description' => '链路id', 'type' => 'string', 'required' => true, 'example' => 'c43793673a384d39daa0a351b1000000'], + ], + [ + 'name' => 'body', + 'in' => 'body', + 'style' => 'json', + 'schema' => [ + 'description' => '请求结构。', + 'type' => 'object', + 'properties' => [ + 'AppName' => ['description' => '链路数据所在的应用名称', 'type' => 'string', 'required' => false, 'example' => 'my-llm-app'], + 'MinTime' => ['description' => '搜索时间范围的UTC开始时间。', 'type' => 'string', 'required' => false, 'example' => '2025-04-05 13:24:25'."\n" + .'2025-04-05'], + 'MaxTime' => ['description' => '搜索时间范围的UTC结束时间。', 'type' => 'string', 'required' => false, 'example' => '2025-04-05 13:24:25'."\n" + .'2025-04-05'], + 'EvaluationConfig' => ['description' => '如果json path处取到的值本身仍然是json string,那么需要进一步定义这个json里的json path以获取实际的值。', 'required' => true, '$ref' => '#/components/schemas/EvaluationConfig'], + 'ModelConfig' => ['description' => '评估链路功能内部使用的大模型的访问配置结构体。', 'required' => false, '$ref' => '#/components/schemas/ModelConfig'], + 'EvaluationId' => ['description' => '评估任务的id。如果不指定,则系统会随机产生一个id返回给用户。用户可以凭借这个返回的任务id快速搜索评估结果。', 'type' => 'string', 'required' => false, 'example' => '44aea0ee00000000be5be24b2abb8f98'], + ], + 'required' => false, + ], + ], + ], + 'responses' => [ + 200 => [ + 'schema' => [ + 'title' => 'Schema of Response', + 'description' => 'Schema of Response', + 'type' => 'object', + 'properties' => [ + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => 'F1AB295E-0D1F-5ECE-9FFA-98ABB4CB5DF5'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'eval_request missing dataset id or times'], + 'EvaluationId' => ['description' => '链路数据所属的评估任务的任务id。', 'type' => 'string', 'example' => '6000043e103011f0922edec44617e03c'], + ], + ], + ], + ], + 'staticInfo' => ['returnType' => 'synchronous'], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"F1AB295E-0D1F-5ECE-9FFA-98ABB4CB5DF5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"eval_request missing dataset id or times\\",\\n \\"EvaluationId\\": \\"6000043e103011f0922edec44617e03c\\"\\n}","type":"json"}]', + 'title' => '评估一条指定的链路数据。', + ], 'GetEvaluationTemplates' => [ 'summary' => '链路评估系统通过和大模型交互、来生成对用户应用的评估结果。评估系统和大模型交互时,需要构造特定的提问提交给大模型。这些问题会基于评估系统内部定义的一些模板构造。这个API返回这些评估系统内部预设模板,供调用者参考和理解。', 'path' => '/api/v1/PAILLMTrace/eval/templates', - 'methods' => [ - 'get', - ], - 'schemes' => [ - 'https', - ], + 'methods' => ['get'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], 'operationType' => 'read', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'get', 'riskType' => 'none', 'chargeType' => 'free', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], 'tenantRelevance' => 'publicInformation', ], 'parameters' => [], @@ -456,77 +375,52 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'ExecutionFailure', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'cannot get data back.', - ], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'ExecutionFailure'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'cannot get data back.'], 'EvaluationTemplates' => [ 'description' => '评估系统内部使用的构造llm交互信息的一系列模板。', 'type' => 'array', - 'items' => [ - 'description' => '一个模板。', - 'type' => 'any', - 'example' => ' {'."\n" - .' \'eval_app_type\': constants.EvalAppType.RAG,'."\n" - .' \'templates\': ['."\n" - .' {'."\n" - .' \'metric\': "relevance",'."\n" - .' \'template\': \'...\''."\n" - .' },'."\n" - .' {'."\n" - .' \'metric\': "faithfulness",'."\n" - .' \'template\': \'...\''."\n" - .' },'."\n" - .' {'."\n" - .' \'metric\': \'correctness\','."\n" - .' \'template\': \'...\''."\n" - .' }'."\n" - .' ]'."\n" - .' }', - ], + 'items' => ['description' => '一个模板。', 'type' => 'any', 'example' => ' {'."\n" + .' \'eval_app_type\': constants.EvalAppType.RAG,'."\n" + .' \'templates\': ['."\n" + .' {'."\n" + .' \'metric\': "relevance",'."\n" + .' \'template\': \'...\''."\n" + .' },'."\n" + .' {'."\n" + .' \'metric\': "faithfulness",'."\n" + .' \'template\': \'...\''."\n" + .' },'."\n" + .' {'."\n" + .' \'metric\': \'correctness\','."\n" + .' \'template\': \'...\''."\n" + .' }'."\n" + .' ]'."\n" + .' }'], ], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], + 'staticInfo' => ['returnType' => 'synchronous'], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"ExecutionFailure\\",\\n \\"Message\\": \\"cannot get data back.\\",\\n \\"EvaluationTemplates\\": [\\n \\" {\\\\n \'eval_app_type\': constants.EvalAppType.RAG,\\\\n \'templates\': [\\\\n {\\\\n \'metric\': \\\\\\"relevance\\\\\\",\\\\n \'template\': \'...\'\\\\n },\\\\n {\\\\n \'metric\': \\\\\\"faithfulness\\\\\\",\\\\n \'template\': \'...\'\\\\n },\\\\n {\\\\n \'metric\': \'correctness\',\\\\n \'template\': \'...\'\\\\n }\\\\n ]\\\\n }\\"\\n ]\\n}","type":"json"}]', 'title' => '获取链路评估系统内部使用的模版', + 'changeSet' => [], + 'ramActions' => [], ], 'GetOnlineEvalTask' => [ 'summary' => '获取指定链路评估任务的详细信息,包括名称、评估模型配置,起止时间等信息。', 'path' => '/api/v1/PAILLMTrace/onlineevaltasks/{TaskId}', - 'methods' => [ - 'get', - ], - 'schemes' => [ - 'https', - ], + 'methods' => ['get'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], 'operationType' => 'read', 'deprecated' => false, 'systemTags' => [ @@ -534,20 +428,13 @@ 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeCode' => '241119', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], ], 'parameters' => [ [ 'name' => 'TaskId', 'in' => 'path', - 'schema' => [ - 'description' => '任务ID。', - 'type' => 'string', - 'required' => true, - 'example' => 'e111d41dd22ca6cf4bc1e3fcad7a142af93', - ], + 'schema' => ['description' => '任务ID。', 'type' => 'string', 'required' => true, 'example' => 'e111d41dd22ca6cf4bc1e3fcad7a142af93'], ], ], 'responses' => [ @@ -557,51 +444,18 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'POP request id', - 'type' => 'string', - 'example' => '6F352A02-9C0D-54A7-B57C-663CF71D5714', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'task id is empty', - ], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'POP request id', 'type' => 'string', 'example' => '6F352A02-9C0D-54A7-B57C-663CF71D5714'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'task id is empty'], 'Task' => [ 'description' => '任务信息', 'type' => 'object', 'properties' => [ - 'Id' => [ - 'description' => '任务id', - 'type' => 'string', - 'example' => '0839a02d-aa24-4174-90bb-7a773885934d', - ], - 'Name' => [ - 'description' => '任务名称。', - 'type' => 'string', - 'example' => 'my-eval-task-1', - ], - 'AliyunUid' => [ - 'description' => '任务创建者的阿里云账号(主账号)。', - 'type' => 'string', - 'example' => '1195531608511111', - ], - 'UserId' => [ - 'description' => '任务创建者的阿里云子账号。', - 'type' => 'string', - 'example' => '222222222222222222', - ], - 'AppName' => [ - 'description' => '该任务针对的用户应用的名称。', - 'type' => 'string', - 'example' => 'my-llm-app', - ], + 'Id' => ['description' => '任务id', 'type' => 'string', 'example' => '0839a02d-aa24-4174-90bb-7a773885934d'], + 'Name' => ['description' => '任务名称。', 'type' => 'string', 'example' => 'my-eval-task-1'], + 'AliyunUid' => ['description' => '任务创建者的阿里云账号(主账号)。', 'type' => 'string', 'example' => '1195531608511111'], + 'UserId' => ['description' => '任务创建者的阿里云子账号。', 'type' => 'string', 'example' => '222222222222222222'], + 'AppName' => ['description' => '该任务针对的用户应用的名称。', 'type' => 'string', 'example' => 'my-llm-app'], 'Filters' => [ 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义搜索筛选条件的列表。', 'type' => 'array', @@ -609,204 +463,315 @@ 'description' => '过滤条件对象。', 'type' => 'object', 'properties' => [ - 'Key' => [ - 'description' => '过滤条件的key。', - 'type' => 'string', - 'example' => 'ServiceId'."\n" - .'ServiceName'."\n" - .'Input'."\n" - .'Output'."\n" - .'Status'."\n" - .'TraceType'."\n" - .'SpanType'."\n" - .'TraceName'."\n" - .'SpanName', - ], - 'Operator' => [ - 'description' => '过滤条件匹配操作符。', - 'type' => 'string', - 'example' => '='."\n" - .'StartsWith'."\n" - .'Contains', - ], - 'Value' => [ - 'description' => '过滤条件的值。', - 'type' => 'string', - 'example' => 'foo', - ], + 'Key' => ['description' => '过滤条件的key。', 'type' => 'string', 'example' => 'ServiceId'."\n" + .'ServiceName'."\n" + .'Input'."\n" + .'Output'."\n" + .'Status'."\n" + .'TraceType'."\n" + .'SpanType'."\n" + .'TraceName'."\n" + .'SpanName'], + 'Operator' => ['description' => '过滤条件匹配操作符。', 'type' => 'string', 'example' => '='."\n" + .'StartsWith'."\n" + .'Contains'], + 'Value' => ['description' => '过滤条件的值。', 'type' => 'string', 'example' => 'foo'], ], ], ], - 'GmtCreateTime' => [ - 'description' => '任务UTC创建时间。', - 'type' => 'string', - 'example' => '2024-07-31 08:30:00', - ], - 'GmtStartTime' => [ - 'description' => '链路数据的UTC开始时间。', - 'type' => 'string', - 'example' => '2024-08-02', - ], - 'GmtEndTime' => [ - 'description' => '链路数据的UTC结束时间。', - 'type' => 'string', - 'example' => '2024-08-10 13:20:00', - ], - 'GmtLastSamplingWindowStartTime' => [ - 'description' => '最后一次采样窗口的UTC开始时间。', - 'type' => 'string', - 'example' => '2024-08-10 13:11:00', - ], - 'GmtLastSamplingWindowEndTime' => [ - 'description' => '最后一次采样窗口的UTC结束时间', - 'type' => 'string', - 'example' => '2024-08-10 13:14:00', - ], - 'SamplingFrequencyMinutes' => [ - 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义任务每次搜索输入数据的时间窗口的宽度。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '3', - ], - 'SamplingRatio' => [ - 'description' => '评估任务在一个时间窗口里搜索到的数据,真正作为评估输入数据的百分比。比如100表示搜索到的所有数据都作为评估输入。又比如20表示从搜索到的数据里随机取20%作为评估输入。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '70', - ], - 'Description' => [ - 'description' => '任务描述信息', - 'type' => 'string', - 'example' => '这个任务做了这些事。', - ], - 'Status' => [ - 'description' => '任务状态', - 'type' => 'string', - 'example' => 'CREATED'."\n" - .'RUNNING'."\n" - .'FINISHED'."\n" - .'USER_CANCELED', - ], - 'RecordCount' => [ - 'description' => '评估记录数量', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '999', - ], - 'EvalResults' => [ - 'description' => '从该任务所有的评估结果,通过聚合计算得到的聚合评估结果。', - 'type' => 'string', - 'example' => '[{"task_id": "11111", "result_type": "HasValidEvalResult", "record_count": 8, "faithfulness": 0.5, "correctness": 0.5, "ndcg": null, "mrr": null, "hit_rate": null, "precision": null}, {"task_id": "11111", "result_type": "FailedToExtractQCA", "record_count": 3, "faithfulness": 0.0, "correctness": 0.0, "ndcg": null, "mrr": null, "hit_rate": null, "precision": null}]', - ], - 'EvaluationConfig' => [ - 'description' => '从json格式的链路数据里要一些提取特定路径上的值,作为评估操作的输入。在这个EvaluationConfig结构体里定义这些json路径。', - '$ref' => '#/components/schemas/EvaluationConfig', - ], - 'ModelConfig' => [ - 'description' => '评估任务内部使用的大模型的访问配置结构体。', - '$ref' => '#/components/schemas/ModelConfig', - ], + 'GmtCreateTime' => ['description' => '任务UTC创建时间。', 'type' => 'string', 'example' => '2024-07-31 08:30:00'], + 'GmtStartTime' => ['description' => '链路数据的UTC开始时间。', 'type' => 'string', 'example' => '2024-08-02'], + 'GmtEndTime' => ['description' => '链路数据的UTC结束时间。', 'type' => 'string', 'example' => '2024-08-10 13:20:00'], + 'GmtLastSamplingWindowStartTime' => ['description' => '最后一次采样窗口的UTC开始时间。', 'type' => 'string', 'example' => '2024-08-10 13:11:00'], + 'GmtLastSamplingWindowEndTime' => ['description' => '最后一次采样窗口的UTC结束时间', 'type' => 'string', 'example' => '2024-08-10 13:14:00'], + 'SamplingFrequencyMinutes' => ['description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义任务每次搜索输入数据的时间窗口的宽度。', 'type' => 'integer', 'format' => 'int32', 'example' => '3'], + 'SamplingRatio' => ['description' => '评估任务在一个时间窗口里搜索到的数据,真正作为评估输入数据的百分比。比如100表示搜索到的所有数据都作为评估输入。又比如20表示从搜索到的数据里随机取20%作为评估输入。', 'type' => 'integer', 'format' => 'int32', 'example' => '70'], + 'Description' => ['description' => '任务描述信息', 'type' => 'string', 'example' => '这个任务做了这些事。'], + 'Status' => ['description' => '任务状态', 'type' => 'string', 'example' => 'CREATED'."\n" + .'RUNNING'."\n" + .'FINISHED'."\n" + .'USER_CANCELED'], + 'RecordCount' => ['description' => '评估记录数量', 'type' => 'integer', 'format' => 'int32', 'example' => '999'], + 'EvalResults' => ['description' => '从该任务所有的评估结果,通过聚合计算得到的聚合评估结果。', 'type' => 'string', 'example' => '[{"task_id": "11111", "result_type": "HasValidEvalResult", "record_count": 8, "faithfulness": 0.5, "correctness": 0.5, "ndcg": null, "mrr": null, "hit_rate": null, "precision": null}, {"task_id": "11111", "result_type": "FailedToExtractQCA", "record_count": 3, "faithfulness": 0.0, "correctness": 0.0, "ndcg": null, "mrr": null, "hit_rate": null, "precision": null}]'], + 'EvaluationConfig' => ['description' => '从json格式的链路数据里要一些提取特定路径上的值,作为评估操作的输入。在这个EvaluationConfig结构体里定义这些json路径。', '$ref' => '#/components/schemas/EvaluationConfig'], + 'ModelConfig' => ['description' => '评估任务内部使用的大模型的访问配置结构体。', '$ref' => '#/components/schemas/ModelConfig'], ], ], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6F352A02-9C0D-54A7-B57C-663CF71D5714\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"task id is empty\\",\\n \\"Task\\": {\\n \\"Id\\": \\"0839a02d-aa24-4174-90bb-7a773885934d\\",\\n \\"Name\\": \\"my-eval-task-1\\",\\n \\"AliyunUid\\": \\"1195531608511111\\",\\n \\"UserId\\": \\"222222222222222222\\",\\n \\"AppName\\": \\"my-llm-app\\",\\n \\"Filters\\": [\\n {\\n \\"Key\\": \\"ServiceId\\\\nServiceName\\\\nInput\\\\nOutput\\\\nStatus\\\\nTraceType\\\\nSpanType\\\\nTraceName\\\\nSpanName\\",\\n \\"Operator\\": \\"=\\\\nStartsWith\\\\nContains\\",\\n \\"Value\\": \\"foo\\"\\n }\\n ],\\n \\"GmtCreateTime\\": \\"2024-07-31 08:30:00\\",\\n \\"GmtStartTime\\": \\"2024-08-02\\",\\n \\"GmtEndTime\\": \\"2024-08-10 13:20:00\\",\\n \\"GmtLastSamplingWindowStartTime\\": \\"2024-08-10 13:11:00\\",\\n \\"GmtLastSamplingWindowEndTime\\": \\"2024-08-10 13:14:00\\",\\n \\"SamplingFrequencyMinutes\\": 3,\\n \\"SamplingRatio\\": 70,\\n \\"Description\\": \\"这个任务做了这些事。\\",\\n \\"Status\\": \\"CREATED\\\\nRUNNING\\\\nFINISHED\\\\nUSER_CANCELED\\",\\n \\"RecordCount\\": 999,\\n \\"EvalResults\\": \\"[{\\\\\\"task_id\\\\\\": \\\\\\"11111\\\\\\", \\\\\\"result_type\\\\\\": \\\\\\"HasValidEvalResult\\\\\\", \\\\\\"record_count\\\\\\": 8, \\\\\\"faithfulness\\\\\\": 0.5, \\\\\\"correctness\\\\\\": 0.5, \\\\\\"ndcg\\\\\\": null, \\\\\\"mrr\\\\\\": null, \\\\\\"hit_rate\\\\\\": null, \\\\\\"precision\\\\\\": null}, {\\\\\\"task_id\\\\\\": \\\\\\"11111\\\\\\", \\\\\\"result_type\\\\\\": \\\\\\"FailedToExtractQCA\\\\\\", \\\\\\"record_count\\\\\\": 3, \\\\\\"faithfulness\\\\\\": 0.0, \\\\\\"correctness\\\\\\": 0.0, \\\\\\"ndcg\\\\\\": null, \\\\\\"mrr\\\\\\": null, \\\\\\"hit_rate\\\\\\": null, \\\\\\"precision\\\\\\": null}]\\",\\n \\"EvaluationConfig\\": {\\n \\"Context\\": {\\n \\"JsonPathInSpan\\": \\"\\",\\n \\"SpanName\\": \\"\\",\\n \\"JsonPathInSpanValue\\": \\"\\"\\n },\\n \\"Answer\\": {\\n \\"JsonPathInSpan\\": \\"\\",\\n \\"SpanName\\": \\"\\",\\n \\"JsonPathInSpanValue\\": \\"\\"\\n },\\n \\"Query\\": {\\n \\"JsonPathInSpan\\": \\"\\",\\n \\"SpanName\\": \\"\\",\\n \\"JsonPathInSpanValue\\": \\"\\"\\n }\\n },\\n \\"ModelConfig\\": {\\n \\"Temperature\\": 0,\\n \\"ApiKey\\": \\"\\",\\n \\"Endpoint\\": \\"\\",\\n \\"UseFunctionCall\\": true,\\n \\"TopP\\": 0,\\n \\"Name\\": \\"\\",\\n \\"IsSelfHost\\": true\\n }\\n }\\n}","type":"json"}]', + 'staticInfo' => ['returnType' => 'synchronous'], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6F352A02-9C0D-54A7-B57C-663CF71D5714\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"task id is empty\\",\\n \\"Task\\": {\\n \\"Id\\": \\"0839a02d-aa24-4174-90bb-7a773885934d\\",\\n \\"Name\\": \\"my-eval-task-1\\",\\n \\"AliyunUid\\": \\"1195531608511111\\",\\n \\"UserId\\": \\"222222222222222222\\",\\n \\"AppName\\": \\"my-llm-app\\",\\n \\"Filters\\": [\\n {\\n \\"Key\\": \\"ServiceId\\\\nServiceName\\\\nInput\\\\nOutput\\\\nStatus\\\\nTraceType\\\\nSpanType\\\\nTraceName\\\\nSpanName\\",\\n \\"Operator\\": \\"=\\\\nStartsWith\\\\nContains\\",\\n \\"Value\\": \\"foo\\"\\n }\\n ],\\n \\"GmtCreateTime\\": \\"2024-07-31 08:30:00\\",\\n \\"GmtStartTime\\": \\"2024-08-02\\",\\n \\"GmtEndTime\\": \\"2024-08-10 13:20:00\\",\\n \\"GmtLastSamplingWindowStartTime\\": \\"2024-08-10 13:11:00\\",\\n \\"GmtLastSamplingWindowEndTime\\": \\"2024-08-10 13:14:00\\",\\n \\"SamplingFrequencyMinutes\\": 3,\\n \\"SamplingRatio\\": 70,\\n \\"Description\\": \\"这个任务做了这些事。\\",\\n \\"Status\\": \\"CREATED\\\\nRUNNING\\\\nFINISHED\\\\nUSER_CANCELED\\",\\n \\"RecordCount\\": 999,\\n \\"EvalResults\\": \\"[{\\\\\\"task_id\\\\\\": \\\\\\"11111\\\\\\", \\\\\\"result_type\\\\\\": \\\\\\"HasValidEvalResult\\\\\\", \\\\\\"record_count\\\\\\": 8, \\\\\\"faithfulness\\\\\\": 0.5, \\\\\\"correctness\\\\\\": 0.5, \\\\\\"ndcg\\\\\\": null, \\\\\\"mrr\\\\\\": null, \\\\\\"hit_rate\\\\\\": null, \\\\\\"precision\\\\\\": null}, {\\\\\\"task_id\\\\\\": \\\\\\"11111\\\\\\", \\\\\\"result_type\\\\\\": \\\\\\"FailedToExtractQCA\\\\\\", \\\\\\"record_count\\\\\\": 3, \\\\\\"faithfulness\\\\\\": 0.0, \\\\\\"correctness\\\\\\": 0.0, \\\\\\"ndcg\\\\\\": null, \\\\\\"mrr\\\\\\": null, \\\\\\"hit_rate\\\\\\": null, \\\\\\"precision\\\\\\": null}]\\",\\n \\"EvaluationConfig\\": {\\n \\"Context\\": {\\n \\"JsonPathInSpan\\": \\"attributes.retrieval.documents[*].document.content\\",\\n \\"SpanName\\": \\"retrieve\\",\\n \\"JsonPathInSpanValue\\": \\"message/value\\"\\n },\\n \\"Answer\\": {\\n \\"JsonPathInSpan\\": \\"attributes.output.value\\",\\n \\"SpanName\\": \\"query\\",\\n \\"JsonPathInSpanValue\\": \\"message/value\\"\\n },\\n \\"Query\\": {\\n \\"JsonPathInSpan\\": \\"attributes.input.value\\",\\n \\"SpanName\\": \\"query\\",\\n \\"JsonPathInSpanValue\\": \\"message/value\\"\\n }\\n },\\n \\"ModelConfig\\": {\\n \\"Temperature\\": 0.1,\\n \\"ApiKey\\": \\"lRQ6ny2BP1g73fsgf9O+Hr4DEedezQ\\",\\n \\"Endpoint\\": \\"https://aiservice.cn-hangzhou.aliyuncs.com/v1\\",\\n \\"UseFunctionCall\\": true,\\n \\"TopP\\": 0.9,\\n \\"Name\\": \\"pai-judge\\\\nthemis\\\\nqwen\\\\ngpt\\",\\n \\"IsSelfHost\\": true\\n }\\n }\\n}","type":"json"}]', 'title' => '获取一个链路评估任务的详细信息。', + 'changeSet' => [], + 'ramActions' => [ + [ + 'operationType' => 'get', + 'ramAction' => [ + 'action' => 'paillmtrace:GetOnlineEvalTask', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/{#OnlineEvaluationId}'], + ], + ], + ], + ], ], - 'ListOnlineEvalTaskResults' => [ - 'summary' => '获取链路评估任务的结果列表。', - 'path' => '/api/v1/PAILLMTrace/onlineevaltaskresults', - 'methods' => [ - 'get', + 'GetServiceIdentityRole' => [ + 'summary' => '获取服务关联角色相关信息。', + 'path' => '/api/v1/PAILLMTrace/ServiceIdentityRole', + 'methods' => ['get'], + 'schemes' => ['https'], + 'security' => [ + [ + 'AK' => [], + ], + ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], + 'operationType' => 'read', + 'deprecated' => false, + 'systemTags' => [ + 'operationType' => 'none', + 'riskType' => 'none', + 'chargeType' => 'free', + 'abilityTreeCode' => '229846', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], + 'tenantRelevance' => 'publicInformation', + ], + 'parameters' => [], + 'responses' => [ + 200 => [ + 'schema' => [ + 'title' => 'Schema of Response', + 'description' => 'Schema of Response', + 'type' => 'object', + 'properties' => [ + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'EntityNotExist'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'Serivce role does not exit.'], + 'RoleDetail' => ['description' => '角色详细信息。', 'type' => 'string', 'example' => 'AliyunServiceRoleForPaiLLMTrace'], + 'RoleName' => ['description' => '操作服务关联角色名称,默认值:AliyunServiceRoleForPaiLLMTrace。', 'type' => 'string', 'example' => 'AliyunServiceRoleForPaiLLMTrace'], + ], + ], + ], ], - 'schemes' => [ - 'https', + 'staticInfo' => ['returnType' => 'synchronous'], + 'eventInfo' => [ + 'enable' => false, + 'eventNames' => [], ], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"EntityNotExist\\",\\n \\"Message\\": \\"Serivce role does not exit.\\",\\n \\"RoleDetail\\": \\"AliyunServiceRoleForPaiLLMTrace\\",\\n \\"RoleName\\": \\"AliyunServiceRoleForPaiLLMTrace\\"\\n}","type":"json"}]', + 'title' => '获取服务关联角色。', + ], + 'GetXtraceToken' => [ + 'summary' => '获取Xtrace服务中所使用的token,以及上传trace数据所需要的endpoint。', + 'path' => '/api/v1/PAILLMTrace/XtraceToken', + 'methods' => ['get'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', + 'consumes' => ['application/json'], + 'produces' => ['application/json'], + 'operationType' => 'read', + 'deprecated' => false, + 'systemTags' => [ + 'operationType' => 'none', + 'riskType' => 'none', + 'chargeType' => 'free', + 'abilityTreeCode' => '230427', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], + 'tenantRelevance' => 'publicInformation', ], - 'produces' => [ - 'application/json', + 'parameters' => [], + 'responses' => [ + 200 => [ + 'schema' => [ + 'title' => 'Schema of Response', + 'description' => 'Schema of Response', + 'type' => 'object', + 'properties' => [ + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'get_xtrace_token: failed, ERROR: NoPermission'], + 'Token' => ['description' => 'arms链路上传使用的token', 'type' => 'string', 'example' => 'h1abcw7@5abcb_h1abcw7@5abc01'], + 'HttpEndpoint' => ['description' => 'arms链路上传使用的endpoint.', 'type' => 'string', 'example' => 'http://tracing-analysis-dc-hz.aliyuncs.com/aaa@bbb@ccc/api/otlp/traces'], + 'HttpInternalEndpoint' => ['description' => '阿里云内部使用的arms链路上传的endpoint', 'type' => 'string', 'example' => 'http://tracing-analysis-dc-hz-internal.aliyuncs.com/aaa@bbb@ccc/api/otlp/traces'], + 'GrpcEndpoint' => ['description' => 'arms链路上传使用的grpc endpoint', 'type' => 'string', 'example' => 'http://tracing-analysis-dc-hz.aliyuncs.com:8090'], + 'GrpcInternalEndpoint' => ['description' => '阿里云内部使用的arms链路上传的grpc endpoint', 'type' => 'string', 'example' => 'http://tracing-analysis-dc-hz-internal.aliyuncs.com:8090'], + ], + ], + ], ], + 'staticInfo' => ['returnType' => 'synchronous'], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"get_xtrace_token: failed, ERROR: NoPermission\\",\\n \\"Token\\": \\"h1abcw7@5abcb_h1abcw7@5abc01\\",\\n \\"HttpEndpoint\\": \\"http://tracing-analysis-dc-hz.aliyuncs.com/aaa@bbb@ccc/api/otlp/traces\\",\\n \\"HttpInternalEndpoint\\": \\"http://tracing-analysis-dc-hz-internal.aliyuncs.com/aaa@bbb@ccc/api/otlp/traces\\",\\n \\"GrpcEndpoint\\": \\"http://tracing-analysis-dc-hz.aliyuncs.com:8090\\",\\n \\"GrpcInternalEndpoint\\": \\"http://tracing-analysis-dc-hz-internal.aliyuncs.com:8090\\"\\n}","type":"json"}]', + 'title' => '获取Xtrace服务的Token。', + ], + 'ListEvalResults' => [ + 'summary' => '获取链路数据评估结果列表。和EvaluateTrace API搭配使用。EvaluateTrace触发评估操作。ListEvalResults获取评估结果。', + 'path' => '/api/v1/PAILLMTrace/eval/results', + 'methods' => ['get'], + 'schemes' => ['https'], + 'security' => [ + [ + 'AK' => [], + ], + ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], 'operationType' => 'read', 'deprecated' => false, 'systemTags' => [ - 'operationType' => 'get', + 'operationType' => 'list', 'riskType' => 'none', 'chargeType' => 'free', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], + 'abilityTreeCode' => '237145', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], ], 'parameters' => [ [ - 'name' => 'TraceIds', + 'name' => 'RecordIds', 'in' => 'query', 'style' => 'simple', 'schema' => [ - 'description' => '指定一组链路id,只返回这些链路的评估结果。链路id和任务Id至少要设置其中一个。', + 'description' => '链路数据id列表。', 'type' => 'array', - 'items' => [ - 'description' => '链路id', - 'type' => 'string', - 'required' => false, - 'example' => '3fbb8d864ac0004b7e41b6f4512c80ae', - ], + 'items' => ['description' => '链路数据id', 'type' => 'string', 'required' => false, 'example' => '7423034a494ca17c16443ffd16336981'], 'required' => false, ], ], [ 'name' => 'PageNumber', 'in' => 'query', - 'schema' => [ - 'description' => '当前页数。取值范围:大于0的整数。默认值:1。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '2', - ], + 'schema' => ['description' => '分页查询时设置的页码。 起始值:1。默认值:1。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '1'], ], [ 'name' => 'PageSize', 'in' => 'query', - 'schema' => [ - 'description' => '分页大小,默认为10,最大为50。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '50', - ], + 'schema' => ['description' => '分页大小,默认值10,最大值50。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '10'], ], [ 'name' => 'EvaluationId', 'in' => 'query', + 'schema' => ['description' => '链路数据所属的评估任务的任务id。', 'type' => 'string', 'required' => false, 'example' => '0bb05ae2a2dc11ef9757faaa2a1ec0c6'], + ], + [ + 'name' => 'Keyword', + 'in' => 'query', + 'schema' => ['description' => '查询关键字,在评估输入数据里查询。', 'type' => 'string', 'required' => false, 'example' => 'foo'], + ], + ], + 'responses' => [ + 200 => [ 'schema' => [ - 'description' => '评估任务的id。链路id和任务Id至少要设置其中一个。', - 'type' => 'string', - 'required' => false, - 'example' => '0bb05ae8888c11ef9757faaa2a1ec0c6', + 'title' => 'Schema of Response', + 'description' => 'Schema of Response', + 'type' => 'object', + 'properties' => [ + 'RequestId' => ['title' => 'Id of the request', 'description' => 'POP请求id', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'ExecutionFailure'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'cannot get data back.'], + 'TotalCount' => ['description' => '符合条件的评估结果的总数。', 'type' => 'integer', 'format' => 'int32', 'example' => '22'], + 'EvaluationResults' => [ + 'description' => '资源评估结果列表。', + 'type' => 'array', + 'items' => ['description' => '一条链路记录的评估结果。', 'type' => 'string', 'example' => '[{'."\n" + .' "result": {'."\n" + .' "correctness": {'."\n" + .' "label": "正确",'."\n" + .' "score": 1,'."\n" + .' "reason": " \\n - 回顾问题:询问了26岁理工宅男的礼物建议。\\n - 回顾答案:提供了多种礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\n - 回答内容详细且具体,提供了多种选择。\\n - 回答内容与问题相关,提供了多种礼物建议。\\n</think>\\n<answer>{\\"label\\":\\"正确\\", \\"reason\\":\\"提供了多种礼物建议,与问题相关,内容详细且具体。\\"}</answer></answer>",'."\n" + .' "name": "正确性"'."\n" + .' },'."\n" + .' "faithfulness": {'."\n" + .' "label": "事实",'."\n" + .' "score": 1,'."\n" + .' "reason": " \\n - 回顾查询内容,用户询问了适合26岁理工宅男的礼物建议。\\n - 回答内容提供了多个具体的礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\n - 回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\n - 回答内容没有提供虚构的信息,因此可以认为是基于事实的。\\n</think>\\n<answer>{\\"label\\":\\"事实\\", \\"reason\\":\\"回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\"}</answer></answer>",'."\n" + .' "name": "真实性"'."\n" + .' }'."\n" + .' },'."\n" + .' "eval_app_type": "qa"'."\n" + .'}]'], + ], + ], ], ], + ], + 'staticInfo' => ['returnType' => 'synchronous'], + 'title' => '获取链路数据评估结果', + 'changeSet' => [], + 'ramActions' => [ [ - 'name' => 'MostRecentResultsOnly', + 'operationType' => 'list', + 'ramAction' => [ + 'action' => 'paillmtrace:ListEvalResults', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'Eval', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:eval/{#EvalId}'], + ], + ], + ], + ], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"ExecutionFailure\\",\\n \\"Message\\": \\"cannot get data back.\\",\\n \\"TotalCount\\": 22,\\n \\"EvaluationResults\\": [\\n \\"[{\\\\n \\\\\\"result\\\\\\": {\\\\n \\\\\\"correctness\\\\\\": {\\\\n \\\\\\"label\\\\\\": \\\\\\"正确\\\\\\",\\\\n \\\\\\"score\\\\\\": 1,\\\\n \\\\\\"reason\\\\\\": \\\\\\" \\\\\\\\n - 回顾问题:询问了26岁理工宅男的礼物建议。\\\\\\\\n - 回顾答案:提供了多种礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\\\\\\\n - 回答内容详细且具体,提供了多种选择。\\\\\\\\n - 回答内容与问题相关,提供了多种礼物建议。\\\\\\\\n</think>\\\\\\\\n<answer>{\\\\\\\\\\\\\\"label\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"正确\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"reason\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"提供了多种礼物建议,与问题相关,内容详细且具体。\\\\\\\\\\\\\\"}</answer></answer>\\\\\\",\\\\n \\\\\\"name\\\\\\": \\\\\\"正确性\\\\\\"\\\\n },\\\\n \\\\\\"faithfulness\\\\\\": {\\\\n \\\\\\"label\\\\\\": \\\\\\"事实\\\\\\",\\\\n \\\\\\"score\\\\\\": 1,\\\\n \\\\\\"reason\\\\\\": \\\\\\" \\\\\\\\n - 回顾查询内容,用户询问了适合26岁理工宅男的礼物建议。\\\\\\\\n - 回答内容提供了多个具体的礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\\\\\\\n - 回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\\\\\\\n - 回答内容没有提供虚构的信息,因此可以认为是基于事实的。\\\\\\\\n</think>\\\\\\\\n<answer>{\\\\\\\\\\\\\\"label\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"事实\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"reason\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\\\\\\\\\\\\\"}</answer></answer>\\\\\\",\\\\n \\\\\\"name\\\\\\": \\\\\\"真实性\\\\\\"\\\\n }\\\\n },\\\\n \\\\\\"eval_app_type\\\\\\": \\\\\\"qa\\\\\\"\\\\n}]\\"\\n ]\\n}","type":"json"}]', + ], + 'ListOnlineEvalTaskResults' => [ + 'summary' => '获取链路评估任务的结果列表。', + 'path' => '/api/v1/PAILLMTrace/onlineevaltaskresults', + 'methods' => ['get'], + 'schemes' => ['https'], + 'security' => [ + [ + 'AK' => [], + ], + ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], + 'operationType' => 'read', + 'deprecated' => false, + 'systemTags' => [ + 'operationType' => 'get', + 'riskType' => 'none', + 'chargeType' => 'free', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], + ], + 'parameters' => [ + [ + 'name' => 'TraceIds', 'in' => 'query', + 'style' => 'simple', 'schema' => [ - 'description' => '同一条链路数据可能会被不同的任务都评估过。如果不指定任务id,且同一个链路id有多条评估结果,那么这个参数指定是否只返回最新的一条评估结果。默认为True,只返回最新的一条结果。', - 'type' => 'boolean', + 'description' => '指定一组链路id,只返回这些链路的评估结果。链路id和任务Id至少要设置其中一个。', + 'type' => 'array', + 'items' => ['description' => '链路id', 'type' => 'string', 'required' => false, 'example' => '3fbb8d864ac0004b7e41b6f4512c80ae'], 'required' => false, - 'example' => 'True', ], ], + [ + 'name' => 'PageNumber', + 'in' => 'query', + 'schema' => ['description' => '当前页数。取值范围:大于0的整数。默认值:1。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '2'], + ], + [ + 'name' => 'PageSize', + 'in' => 'query', + 'schema' => ['description' => '分页大小,默认为10,最大为50。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '50'], + ], + [ + 'name' => 'EvaluationId', + 'in' => 'query', + 'schema' => ['description' => '评估任务的id。链路id和任务Id至少要设置其中一个。', 'type' => 'string', 'required' => false, 'example' => '0bb05ae8888c11ef9757faaa2a1ec0c6'], + ], + [ + 'name' => 'MostRecentResultsOnly', + 'in' => 'query', + 'schema' => ['description' => '同一条链路数据可能会被不同的任务都评估过。如果不指定任务id,且同一个链路id有多条评估结果,那么这个参数指定是否只返回最新的一条评估结果。默认为True,只返回最新的一条结果。', 'type' => 'boolean', 'required' => false, 'example' => 'True'], + ], ], 'responses' => [ 200 => [ @@ -815,83 +780,65 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => '22BA9A5A-E3D8-5B4C-90FC-F33F6E5853F8', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'must provide trace_id(s) or eval_id', - ], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => '22BA9A5A-E3D8-5B4C-90FC-F33F6E5853F8'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'must provide trace_id(s) or eval_id'], 'EvaluationResults' => [ 'description' => '评估结果列表。', 'type' => 'array', - 'items' => [ - 'description' => '一条链路记录的评估结果。', - 'type' => 'string', - 'example' => '{'."\n" - .' "result": {'."\n" - .' "correctness": {'."\n" - .' "label": "正确",'."\n" - .' "score": 1,'."\n" - .' "reason": " \\n - 回顾问题:询问了26岁理工宅男的礼物建议。\\n - 回顾答案:提供了多种礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\n - 回答内容详细且具体,提供了多种选择。\\n - 回答内容与问题相关,提供了多种礼物建议。\\n</think>\\n<answer>{\\"label\\":\\"正确\\", \\"reason\\":\\"提供了多种礼物建议,与问题相关,内容详细且具体。\\"}</answer></answer>",'."\n" - .' "name": "正确性"'."\n" - .' },'."\n" - .' "faithfulness": {'."\n" - .' "label": "事实",'."\n" - .' "score": 1,'."\n" - .' "reason": " \\n - 回顾查询内容,用户询问了适合26岁理工宅男的礼物建议。\\n - 回答内容提供了多个具体的礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\n - 回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\n - 回答内容没有提供虚构的信息,因此可以认为是基于事实的。\\n</think>\\n<answer>{\\"label\\":\\"事实\\", \\"reason\\":\\"回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\"}</answer></answer>",'."\n" - .' "name": "真实性"'."\n" - .' }'."\n" - .' },'."\n" - .' "eval_app_type": "qa"'."\n" - .'}', - ], - ], - 'TotalCount' => [ - 'description' => '符合条件的评估结果的总数。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '123', - ], + 'items' => ['description' => '一条链路记录的评估结果。', 'type' => 'string', 'example' => '{'."\n" + .' "result": {'."\n" + .' "correctness": {'."\n" + .' "label": "正确",'."\n" + .' "score": 1,'."\n" + .' "reason": " \\n - 回顾问题:询问了26岁理工宅男的礼物建议。\\n - 回顾答案:提供了多种礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\n - 回答内容详细且具体,提供了多种选择。\\n - 回答内容与问题相关,提供了多种礼物建议。\\n</think>\\n<answer>{\\"label\\":\\"正确\\", \\"reason\\":\\"提供了多种礼物建议,与问题相关,内容详细且具体。\\"}</answer></answer>",'."\n" + .' "name": "正确性"'."\n" + .' },'."\n" + .' "faithfulness": {'."\n" + .' "label": "事实",'."\n" + .' "score": 1,'."\n" + .' "reason": " \\n - 回顾查询内容,用户询问了适合26岁理工宅男的礼物建议。\\n - 回答内容提供了多个具体的礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\n - 回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\n - 回答内容没有提供虚构的信息,因此可以认为是基于事实的。\\n</think>\\n<answer>{\\"label\\":\\"事实\\", \\"reason\\":\\"回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\"}</answer></answer>",'."\n" + .' "name": "真实性"'."\n" + .' }'."\n" + .' },'."\n" + .' "eval_app_type": "qa"'."\n" + .'}'], + ], + 'TotalCount' => ['description' => '符合条件的评估结果的总数。', 'type' => 'integer', 'format' => 'int32', 'example' => '123'], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], + 'staticInfo' => ['returnType' => 'synchronous'], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"22BA9A5A-E3D8-5B4C-90FC-F33F6E5853F8\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"must provide trace_id(s) or eval_id\\",\\n \\"EvaluationResults\\": [\\n \\"{\\\\n \\\\\\"result\\\\\\": {\\\\n \\\\\\"correctness\\\\\\": {\\\\n \\\\\\"label\\\\\\": \\\\\\"正确\\\\\\",\\\\n \\\\\\"score\\\\\\": 1,\\\\n \\\\\\"reason\\\\\\": \\\\\\" \\\\\\\\n - 回顾问题:询问了26岁理工宅男的礼物建议。\\\\\\\\n - 回顾答案:提供了多种礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\\\\\\\n - 回答内容详细且具体,提供了多种选择。\\\\\\\\n - 回答内容与问题相关,提供了多种礼物建议。\\\\\\\\n</think>\\\\\\\\n<answer>{\\\\\\\\\\\\\\"label\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"正确\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"reason\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"提供了多种礼物建议,与问题相关,内容详细且具体。\\\\\\\\\\\\\\"}</answer></answer>\\\\\\",\\\\n \\\\\\"name\\\\\\": \\\\\\"正确性\\\\\\"\\\\n },\\\\n \\\\\\"faithfulness\\\\\\": {\\\\n \\\\\\"label\\\\\\": \\\\\\"事实\\\\\\",\\\\n \\\\\\"score\\\\\\": 1,\\\\n \\\\\\"reason\\\\\\": \\\\\\" \\\\\\\\n - 回顾查询内容,用户询问了适合26岁理工宅男的礼物建议。\\\\\\\\n - 回答内容提供了多个具体的礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\\\\\\\n - 回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\\\\\\\n - 回答内容没有提供虚构的信息,因此可以认为是基于事实的。\\\\\\\\n</think>\\\\\\\\n<answer>{\\\\\\\\\\\\\\"label\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"事实\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"reason\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\\\\\\\\\\\\\"}</answer></answer>\\\\\\",\\\\n \\\\\\"name\\\\\\": \\\\\\"真实性\\\\\\"\\\\n }\\\\n },\\\\n \\\\\\"eval_app_type\\\\\\": \\\\\\"qa\\\\\\"\\\\n}\\"\\n ],\\n \\"TotalCount\\": 123\\n}","type":"json"}]', 'title' => '获取一个链路评估任务的结果列表', + 'changeSet' => [], + 'ramActions' => [ + [ + 'operationType' => 'get', + 'ramAction' => [ + 'action' => 'paillmtrace:ListOnlineEvalTaskResults', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/{#OnlineEvaluationId}'], + ], + ], + ], + ], ], 'ListOnlineEvalTasks' => [ 'summary' => '查找符合条件的链路评估任务。', 'path' => '/api/v1/PAILLMTrace/onlineevaltasks', - 'methods' => [ - 'get', - ], - 'schemes' => [ - 'https', - ], + 'methods' => ['get'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], 'operationType' => 'read', 'deprecated' => false, 'systemTags' => [ @@ -899,122 +846,68 @@ 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeCode' => '241118', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], ], 'parameters' => [ [ 'name' => 'MinTime', 'in' => 'query', - 'schema' => [ - 'description' => '搜索时间范围的UTC开始时间', - 'type' => 'string', - 'required' => false, - 'example' => '2025-04-05 13:24:25'."\n" - .'2025-04-05', - ], + 'schema' => ['description' => '搜索时间范围的UTC开始时间', 'type' => 'string', 'required' => false, 'example' => '2025-04-05 13:24:25'."\n" + .'2025-04-05'], ], [ 'name' => 'MaxTime', 'in' => 'query', - 'schema' => [ - 'description' => '搜索时间范围的UTC截止时间', - 'type' => 'string', - 'required' => false, - 'example' => '2025-04-07 13:24:25'."\n" - .'2025-04-07', - ], + 'schema' => ['description' => '搜索时间范围的UTC截止时间', 'type' => 'string', 'required' => false, 'example' => '2025-04-07 13:24:25'."\n" + .'2025-04-07'], ], [ 'name' => 'PageNumber', 'in' => 'query', - 'schema' => [ - 'description' => '当前页数。取值范围:大于0的整数。默认值:1。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '1', - ], + 'schema' => ['description' => '当前页数。取值范围:大于0的整数。默认值:1。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '1'], ], [ 'name' => 'PageSize', 'in' => 'query', - 'schema' => [ - 'description' => '分页大小,默认为10,最大为50。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '50', - ], + 'schema' => ['description' => '分页大小,默认为10,最大为50。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '50'], ], [ 'name' => 'AppName', 'in' => 'query', - 'schema' => [ - 'description' => '用户应用在链路数据里记录的名称。完全匹配。', - 'type' => 'string', - 'required' => false, - 'example' => 'my-foo-llm-app-1.0', - ], + 'schema' => ['description' => '用户应用在链路数据里记录的名称。完全匹配。', 'type' => 'string', 'required' => false, 'example' => 'my-foo-llm-app-1.0'], ], [ 'name' => 'Status', 'in' => 'query', - 'schema' => [ - 'description' => '任务状态。完全匹配。', - 'type' => 'string', - 'required' => false, - 'example' => 'CREATED'."\n" - .'RUNNING'."\n" - .'FINISHED'."\n" - .'USER_CANCELED', - ], + 'schema' => ['description' => '任务状态。完全匹配。', 'type' => 'string', 'required' => false, 'example' => 'CREATED'."\n" + .'RUNNING'."\n" + .'FINISHED'."\n" + .'USER_CANCELED'], ], [ 'name' => 'Keyword', 'in' => 'query', - 'schema' => [ - 'description' => '搜索关键字。会在任务名称、任务id、任务描述这些字段上模糊匹配。', - 'type' => 'string', - 'required' => false, - 'example' => 'foo', - ], + 'schema' => ['description' => '搜索关键字。会在任务名称、任务id、任务描述这些字段上模糊匹配。', 'type' => 'string', 'required' => false, 'example' => 'foo'], ], [ 'name' => 'SamplingMethod', 'in' => 'query', - 'schema' => [ - 'description' => '任务数据采样方式。窗口或者概率。精确匹配。', - 'type' => 'string', - 'required' => false, - 'example' => 'Window'."\n" - .'Ratio', - ], + 'schema' => ['description' => '任务数据采样方式。窗口或者概率。精确匹配。', 'type' => 'string', 'required' => false, 'example' => 'Window'."\n" + .'Ratio'], ], [ 'name' => 'SortBy', 'in' => 'query', - 'schema' => [ - 'description' => '用于排序返回结果的字段,目前支持TaskId, CreateTime,TaskName,和Status。不填则默认用CreateTime', - 'type' => 'string', - 'required' => false, - 'example' => 'CreateTime'."\n" - .'Status'."\n" - .'TaskId'."\n" - .'TaskName', - ], + 'schema' => ['description' => '用于排序返回结果的字段,目前支持TaskId, CreateTime,TaskName,和Status。不填则默认用CreateTime', 'type' => 'string', 'required' => false, 'example' => 'CreateTime'."\n" + .'Status'."\n" + .'TaskId'."\n" + .'TaskName'], ], [ 'name' => 'SortOrder', 'in' => 'query', - 'schema' => [ - 'description' => '返回结果的排序方向。取值范围:ASC(升序)、DESC(降序)。不填则默认用DESC。', - 'type' => 'string', - 'required' => false, - 'example' => 'ASC'."\n" - .'DESC', - ], + 'schema' => ['description' => '返回结果的排序方向。取值范围:ASC(升序)、DESC(降序)。不填则默认用DESC。', 'type' => 'string', 'required' => false, 'example' => 'ASC'."\n" + .'DESC'], ], ], 'responses' => [ @@ -1024,28 +917,10 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => '6F352A02-9C0D-54A7-B57C-663CF71D5714', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'page number should be greater than 0', - ], - 'TotalCount' => [ - 'description' => '符合条件的任务的总数。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '22', - ], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the request', 'type' => 'string', 'example' => '6F352A02-9C0D-54A7-B57C-663CF71D5714'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'page number should be greater than 0'], + 'TotalCount' => ['description' => '符合条件的任务的总数。', 'type' => 'integer', 'format' => 'int32', 'example' => '22'], 'Tasks' => [ 'description' => '任务列表。', 'type' => 'array', @@ -1053,31 +928,11 @@ 'description' => '任务的详细信息。', 'type' => 'object', 'properties' => [ - 'Id' => [ - 'description' => '任务ID。', - 'type' => 'string', - 'example' => '9f50cd72efcf36535152ee811a911115', - ], - 'Name' => [ - 'description' => '任务名称。', - 'type' => 'string', - 'example' => 'my-foo-evaluation-task', - ], - 'AliyunUid' => [ - 'description' => '任务创建者的阿里云账号(主账号)。', - 'type' => 'string', - 'example' => '1512522691911111', - ], - 'UserId' => [ - 'description' => '任务创建者的阿里云子账号', - 'type' => 'string', - 'example' => '2222222222', - ], - 'AppName' => [ - 'description' => '该任务针对的用户应用的名称。', - 'type' => 'string', - 'example' => 'my-llm-app', - ], + 'Id' => ['description' => '任务ID。', 'type' => 'string', 'example' => '9f50cd72efcf36535152ee811a911115'], + 'Name' => ['description' => '任务名称。', 'type' => 'string', 'example' => 'my-foo-evaluation-task'], + 'AliyunUid' => ['description' => '任务创建者的阿里云账号(主账号)。', 'type' => 'string', 'example' => '1512522691911111'], + 'UserId' => ['description' => '任务创建者的阿里云子账号', 'type' => 'string', 'example' => '2222222222'], + 'AppName' => ['description' => '该任务针对的用户应用的名称。', 'type' => 'string', 'example' => 'my-llm-app'], 'Filters' => [ 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义搜索筛选条件的列表。', 'type' => 'array', @@ -1088,17 +943,7 @@ 'Key' => [ 'description' => '过滤条件的key。', 'type' => 'string', - 'enumValueTitles' => [ - 'Status' => 'Status', - 'SpanName' => 'SpanName', - 'Input' => 'Input', - 'TraceType' => 'TraceType', - 'SpanType' => 'SpanType', - 'ServiceName' => 'ServiceName', - 'Output' => 'Output', - 'TraceName' => 'TraceName', - 'ServiceId' => 'ServiceId', - ], + 'enumValueTitles' => ['Status' => 'Status', 'SpanName' => 'SpanName', 'Input' => 'Input', 'TraceType' => 'TraceType', 'SpanType' => 'SpanType', 'ServiceName' => 'ServiceName', 'Output' => 'Output', 'TraceName' => 'TraceName', 'ServiceId' => 'ServiceId'], 'example' => 'ServiceId'."\n" .'ServiceName'."\n" .'Input'."\n" @@ -1112,82 +957,29 @@ 'Operator' => [ 'description' => '过滤条件匹配操作符。', 'type' => 'string', - 'enumValueTitles' => [ - 'Contains' => 'Contains', - '=' => '=', - 'StartsWith' => 'StartsWith', - ], + 'enumValueTitles' => ['Contains' => 'Contains', '=' => '=', 'StartsWith' => 'StartsWith'], 'example' => '='."\n" .'StartsWith'."\n" .'Contains', ], - 'Value' => [ - 'description' => '过滤条件的值。', - 'type' => 'string', - 'example' => 'foo', - ], + 'Value' => ['description' => '过滤条件的值。', 'type' => 'string', 'example' => 'foo'], ], ], ], - 'GmtCreateTime' => [ - 'description' => '任务UTC创建时间。', - 'type' => 'string', - 'example' => '2025-04-07 13:24:35', - ], - 'GmtStartTime' => [ - 'description' => '任务UTC开始时间。', - 'type' => 'string', - 'example' => '2025-04-08 13:24:35', - ], - 'GmtEndTime' => [ - 'description' => '任务UTC结束时间。', - 'type' => 'string', - 'example' => '2025-04-09 13:24:35', - ], - 'SamplingFrequencyMinutes' => [ - 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义任务每次搜索输入数据的时间窗口的宽度。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '12', - ], - 'SamplingRatio' => [ - 'description' => '评估任务在一个时间窗口里搜索到的数据,真正作为评估输入数据的百分比。比如100表示搜索到的所有数据都作为评估输入。又比如20表示从搜索到的数据里随机取20%作为评估输入。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '50', - ], - 'Description' => [ - 'description' => '任务描述信息', - 'type' => 'string', - 'example' => '评估任务', - ], - 'Status' => [ - 'description' => '任务状态', - 'type' => 'string', - 'example' => 'CREATED'."\n" - .'RUNNING'."\n" - .'FINISHED'."\n" - .'USER_CANCELED', - ], - 'EvaluationConfig' => [ - 'description' => '从json格式的链路数据里要一些提取特定路径上的值,作为评估操作的输入。在这个EvaluationConfig结构体里定义这些json路径。', - '$ref' => '#/components/schemas/EvaluationConfig', - ], - 'ModelConfig' => [ - 'description' => '评估任务内部使用的大模型的访问配置结构体。', - '$ref' => '#/components/schemas/ModelConfig', - ], - 'RecordCount' => [ - 'description' => '评估记录数量。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '11', - ], - 'EvalResults' => [ - 'description' => '从该任务所有的评估结果,通过聚合计算得到的聚合评估结果。', - 'type' => 'string', - 'example' => '[{"task_id": "00000", "result_type": "HasValidEvalResult", "record_count": 8, "faithfulness": 0.5, "correctness": 0.5, "ndcg": null, "mrr": null, "hit_rate": null, "precision": null}, {"task_id": "00000", "result_type": "FailedToExtractQCA", "record_count": 3, "faithfulness": 0.0, "correctness": 0.0, "ndcg": null, "mrr": null, "hit_rate": null, "precision": null}]', - ], + 'GmtCreateTime' => ['description' => '任务UTC创建时间。', 'type' => 'string', 'example' => '2025-04-07 13:24:35'], + 'GmtStartTime' => ['description' => '任务UTC开始时间。', 'type' => 'string', 'example' => '2025-04-08 13:24:35'], + 'GmtEndTime' => ['description' => '任务UTC结束时间。', 'type' => 'string', 'example' => '2025-04-09 13:24:35'], + 'SamplingFrequencyMinutes' => ['description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义任务每次搜索输入数据的时间窗口的宽度。', 'type' => 'integer', 'format' => 'int32', 'example' => '12'], + 'SamplingRatio' => ['description' => '评估任务在一个时间窗口里搜索到的数据,真正作为评估输入数据的百分比。比如100表示搜索到的所有数据都作为评估输入。又比如20表示从搜索到的数据里随机取20%作为评估输入。', 'type' => 'integer', 'format' => 'int32', 'example' => '50'], + 'Description' => ['description' => '任务描述信息', 'type' => 'string', 'example' => '评估任务'], + 'Status' => ['description' => '任务状态', 'type' => 'string', 'example' => 'CREATED'."\n" + .'RUNNING'."\n" + .'FINISHED'."\n" + .'USER_CANCELED'], + 'EvaluationConfig' => ['description' => '从json格式的链路数据里要一些提取特定路径上的值,作为评估操作的输入。在这个EvaluationConfig结构体里定义这些json路径。', '$ref' => '#/components/schemas/EvaluationConfig'], + 'ModelConfig' => ['description' => '评估任务内部使用的大模型的访问配置结构体。', '$ref' => '#/components/schemas/ModelConfig'], + 'RecordCount' => ['description' => '评估记录数量。', 'type' => 'integer', 'format' => 'int32', 'example' => '11'], + 'EvalResults' => ['description' => '从该任务所有的评估结果,通过聚合计算得到的聚合评估结果。', 'type' => 'string', 'example' => '[{"task_id": "00000", "result_type": "HasValidEvalResult", "record_count": 8, "faithfulness": 0.5, "correctness": 0.5, "ndcg": null, "mrr": null, "hit_rate": null, "precision": null}, {"task_id": "00000", "result_type": "FailedToExtractQCA", "record_count": 3, "faithfulness": 0.0, "correctness": 0.0, "ndcg": null, "mrr": null, "hit_rate": null, "precision": null}]'], ], ], ], @@ -1195,502 +987,36 @@ ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6F352A02-9C0D-54A7-B57C-663CF71D5714\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"page number should be greater than 0\\",\\n \\"TotalCount\\": 22,\\n \\"Tasks\\": [\\n {\\n \\"Id\\": \\"9f50cd72efcf36535152ee811a911115\\",\\n \\"Name\\": \\"my-foo-evaluation-task\\",\\n \\"AliyunUid\\": \\"1512522691911111\\",\\n \\"UserId\\": \\"2222222222\\",\\n \\"AppName\\": \\"my-llm-app\\",\\n \\"Filters\\": [\\n {\\n \\"Key\\": \\"ServiceId\\\\nServiceName\\\\nInput\\\\nOutput\\\\nStatus\\\\nTraceType\\\\nSpanType\\\\nTraceName\\\\nSpanName\\",\\n \\"Operator\\": \\"=\\\\nStartsWith\\\\nContains\\",\\n \\"Value\\": \\"foo\\"\\n }\\n ],\\n \\"GmtCreateTime\\": \\"2025-04-07 13:24:35\\",\\n \\"GmtStartTime\\": \\"2025-04-08 13:24:35\\",\\n \\"GmtEndTime\\": \\"2025-04-09 13:24:35\\",\\n \\"SamplingFrequencyMinutes\\": 12,\\n \\"SamplingRatio\\": 50,\\n \\"Description\\": \\"评估任务\\",\\n \\"Status\\": \\"CREATED\\\\nRUNNING\\\\nFINISHED\\\\nUSER_CANCELED\\",\\n \\"EvaluationConfig\\": {\\n \\"Context\\": {\\n \\"JsonPathInSpan\\": \\"\\",\\n \\"SpanName\\": \\"\\",\\n \\"JsonPathInSpanValue\\": \\"\\"\\n },\\n \\"Answer\\": {\\n \\"JsonPathInSpan\\": \\"\\",\\n \\"SpanName\\": \\"\\",\\n \\"JsonPathInSpanValue\\": \\"\\"\\n },\\n \\"Query\\": {\\n \\"JsonPathInSpan\\": \\"\\",\\n \\"SpanName\\": \\"\\",\\n \\"JsonPathInSpanValue\\": \\"\\"\\n }\\n },\\n \\"ModelConfig\\": {\\n \\"Temperature\\": 0,\\n \\"ApiKey\\": \\"\\",\\n \\"Endpoint\\": \\"\\",\\n \\"UseFunctionCall\\": true,\\n \\"TopP\\": 0,\\n \\"Name\\": \\"\\",\\n \\"IsSelfHost\\": true\\n },\\n \\"RecordCount\\": 11,\\n \\"EvalResults\\": \\"[{\\\\\\"task_id\\\\\\": \\\\\\"00000\\\\\\", \\\\\\"result_type\\\\\\": \\\\\\"HasValidEvalResult\\\\\\", \\\\\\"record_count\\\\\\": 8, \\\\\\"faithfulness\\\\\\": 0.5, \\\\\\"correctness\\\\\\": 0.5, \\\\\\"ndcg\\\\\\": null, \\\\\\"mrr\\\\\\": null, \\\\\\"hit_rate\\\\\\": null, \\\\\\"precision\\\\\\": null}, {\\\\\\"task_id\\\\\\": \\\\\\"00000\\\\\\", \\\\\\"result_type\\\\\\": \\\\\\"FailedToExtractQCA\\\\\\", \\\\\\"record_count\\\\\\": 3, \\\\\\"faithfulness\\\\\\": 0.0, \\\\\\"correctness\\\\\\": 0.0, \\\\\\"ndcg\\\\\\": null, \\\\\\"mrr\\\\\\": null, \\\\\\"hit_rate\\\\\\": null, \\\\\\"precision\\\\\\": null}]\\"\\n }\\n ]\\n}","type":"json"}]', + 'staticInfo' => ['returnType' => 'synchronous'], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6F352A02-9C0D-54A7-B57C-663CF71D5714\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"page number should be greater than 0\\",\\n \\"TotalCount\\": 22,\\n \\"Tasks\\": [\\n {\\n \\"Id\\": \\"9f50cd72efcf36535152ee811a911115\\",\\n \\"Name\\": \\"my-foo-evaluation-task\\",\\n \\"AliyunUid\\": \\"1512522691911111\\",\\n \\"UserId\\": \\"2222222222\\",\\n \\"AppName\\": \\"my-llm-app\\",\\n \\"Filters\\": [\\n {\\n \\"Key\\": \\"ServiceId\\\\nServiceName\\\\nInput\\\\nOutput\\\\nStatus\\\\nTraceType\\\\nSpanType\\\\nTraceName\\\\nSpanName\\",\\n \\"Operator\\": \\"=\\\\nStartsWith\\\\nContains\\",\\n \\"Value\\": \\"foo\\"\\n }\\n ],\\n \\"GmtCreateTime\\": \\"2025-04-07 13:24:35\\",\\n \\"GmtStartTime\\": \\"2025-04-08 13:24:35\\",\\n \\"GmtEndTime\\": \\"2025-04-09 13:24:35\\",\\n \\"SamplingFrequencyMinutes\\": 12,\\n \\"SamplingRatio\\": 50,\\n \\"Description\\": \\"评估任务\\",\\n \\"Status\\": \\"CREATED\\\\nRUNNING\\\\nFINISHED\\\\nUSER_CANCELED\\",\\n \\"EvaluationConfig\\": {\\n \\"Context\\": {\\n \\"JsonPathInSpan\\": \\"attributes.retrieval.documents[*].document.content\\",\\n \\"SpanName\\": \\"retrieve\\",\\n \\"JsonPathInSpanValue\\": \\"message/value\\"\\n },\\n \\"Answer\\": {\\n \\"JsonPathInSpan\\": \\"attributes.output.value\\",\\n \\"SpanName\\": \\"query\\",\\n \\"JsonPathInSpanValue\\": \\"message/value\\"\\n },\\n \\"Query\\": {\\n \\"JsonPathInSpan\\": \\"attributes.input.value\\",\\n \\"SpanName\\": \\"query\\",\\n \\"JsonPathInSpanValue\\": \\"message/value\\"\\n }\\n },\\n \\"ModelConfig\\": {\\n \\"Temperature\\": 0.1,\\n \\"ApiKey\\": \\"lRQ6ny2BP1g73fsgf9O+Hr4DEedezQ\\",\\n \\"Endpoint\\": \\"https://aiservice.cn-hangzhou.aliyuncs.com/v1\\",\\n \\"UseFunctionCall\\": true,\\n \\"TopP\\": 0.9,\\n \\"Name\\": \\"pai-judge\\\\nthemis\\\\nqwen\\\\ngpt\\",\\n \\"IsSelfHost\\": true\\n },\\n \\"RecordCount\\": 11,\\n \\"EvalResults\\": \\"[{\\\\\\"task_id\\\\\\": \\\\\\"00000\\\\\\", \\\\\\"result_type\\\\\\": \\\\\\"HasValidEvalResult\\\\\\", \\\\\\"record_count\\\\\\": 8, \\\\\\"faithfulness\\\\\\": 0.5, \\\\\\"correctness\\\\\\": 0.5, \\\\\\"ndcg\\\\\\": null, \\\\\\"mrr\\\\\\": null, \\\\\\"hit_rate\\\\\\": null, \\\\\\"precision\\\\\\": null}, {\\\\\\"task_id\\\\\\": \\\\\\"00000\\\\\\", \\\\\\"result_type\\\\\\": \\\\\\"FailedToExtractQCA\\\\\\", \\\\\\"record_count\\\\\\": 3, \\\\\\"faithfulness\\\\\\": 0.0, \\\\\\"correctness\\\\\\": 0.0, \\\\\\"ndcg\\\\\\": null, \\\\\\"mrr\\\\\\": null, \\\\\\"hit_rate\\\\\\": null, \\\\\\"precision\\\\\\": null}]\\"\\n }\\n ]\\n}","type":"json"}]', 'title' => '获取链路评估任务列表。', - ], - 'StopOnlineEvalTask' => [ - 'summary' => '停止一个链路评估任务的执行。任务停止后,不能再做任何配置改动,任务也不会再生成任何新的评估结果。', - 'path' => '/api/v1/PAILLMTrace/onlineevaltasks/{TaskId}/stop', - 'methods' => [ - 'put', - ], - 'schemes' => [ - 'https', - ], - 'security' => [ + 'changeSet' => [], + 'ramActions' => [ [ - 'AK' => [], - ], - ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], - 'operationType' => 'write', - 'deprecated' => false, - 'systemTags' => [ - 'operationType' => 'update', - 'riskType' => 'none', - 'chargeType' => 'free', - 'abilityTreeCode' => '241121', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], - ], - 'parameters' => [ - [ - 'name' => 'TaskId', - 'in' => 'path', - 'schema' => [ - 'description' => '链路评估任务的id。', - 'type' => 'string', - 'required' => true, - 'example' => '518b1d2f3cfca4ad3836ace4db69ba59c', - ], - ], - ], - 'responses' => [ - 200 => [ - 'schema' => [ - 'title' => 'Schema of Response', - 'description' => 'Schema of Response', - 'type' => 'object', - 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the POP request', - 'type' => 'string', - 'example' => '31E5FBC2-792D-5B5C-A5EB-3019984ABFC8', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'task id is empty', - ], + 'operationType' => 'list', + 'ramAction' => [ + 'action' => 'paillmtrace:ListOnlineEvalTasks', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/*'], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"31E5FBC2-792D-5B5C-A5EB-3019984ABFC8\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"task id is empty\\"\\n}","type":"json"}]', - 'title' => '停止一个链路评估任务。', - ], - 'UpdateOnlineEvalTask' => [ - 'summary' => '更改一个链路评估任务的配置。', - 'path' => '/api/v1/PAILLMTrace/onlineevaltasks/{TaskId}', - 'methods' => [ - 'put', - ], - 'schemes' => [ - 'https', - ], - 'security' => [ - [ - 'AK' => [], - ], - ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], - 'operationType' => 'write', - 'deprecated' => false, - 'systemTags' => [ - 'operationType' => 'update', - 'riskType' => 'none', - 'chargeType' => 'free', - 'abilityTreeCode' => '241120', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], - ], - 'parameters' => [ - [ - 'name' => 'TaskId', - 'in' => 'path', - 'schema' => [ - 'description' => '链路评估任务的id。', - 'type' => 'string', - 'required' => true, - 'example' => '518bc0f833d9a4ad3836ace4db69ba59c', - ], - ], - [ - 'name' => 'body', - 'in' => 'body', - 'style' => 'json', - 'schema' => [ - 'description' => '请求体。', - 'type' => 'object', - 'properties' => [ - 'TaskName' => [ - 'description' => '任务名称', - 'type' => 'string', - 'required' => false, - 'example' => 'foo大模型应用效果评估', - ], - 'AppName' => [ - 'description' => '用户的基于大模型的应用的名称', - 'type' => 'string', - 'required' => false, - 'example' => 'my-llm-one', - ], - 'Filters' => [ - 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义搜索筛选条件的列表。', - 'type' => 'array', - 'items' => [ - 'description' => '自定义过滤条件对象。', - 'type' => 'object', - 'properties' => [ - 'Key' => [ - 'description' => '过滤条件的key', - 'type' => 'string', - 'required' => false, - 'enumValueTitles' => [ - 'Status' => 'Status', - 'SpanName' => 'SpanName', - 'Input' => 'Input', - 'TraceType' => 'TraceType', - 'SpanType' => 'SpanType', - 'ServiceName' => 'ServiceName', - 'Output' => 'Output', - 'TraceName' => 'TraceName', - 'ServiceId' => 'ServiceId', - ], - 'example' => 'ServiceId'."\n" - .'ServiceName'."\n" - .'Input'."\n" - .'Output'."\n" - .'Status'."\n" - .'TraceType'."\n" - .'SpanType'."\n" - .'TraceName'."\n" - .'SpanName', - ], - 'Operator' => [ - 'description' => '过滤条件匹配操作符', - 'type' => 'string', - 'required' => false, - 'enumValueTitles' => [ - 'Contains' => 'Contains', - '=' => '=', - 'StartsWith' => 'StartsWith', - ], - 'example' => '='."\n" - .'StartsWith'."\n" - .'Contains', - ], - 'Value' => [ - 'description' => '过滤条件的值', - 'type' => 'string', - 'required' => false, - 'example' => 'foo', - ], - ], - 'required' => false, - ], - 'required' => false, - ], - 'StartTime' => [ - 'description' => '链路数据的UTC开始时间', - 'type' => 'string', - 'required' => false, - 'example' => '2024-07-31 08:30:00', - ], - 'EndTime' => [ - 'description' => '链路数据的UTC结束时间', - 'type' => 'string', - 'required' => false, - 'example' => '2024-09-02 22:24:00', - ], - 'SamplingFrequencyMinutes' => [ - 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义任务每次搜索输入数据的时间窗口的宽度。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '10', - ], - 'SamplingRatio' => [ - 'description' => '评估任务在一个时间窗口里搜索到的数据,真正作为评估输入数据的百分比。比如100表示搜索到的所有数据都作为评估输入。又比如20表示从搜索到的数据里随机取20%作为评估输入。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '50', - ], - 'Description' => [ - 'description' => '任务描述信息', - 'type' => 'string', - 'required' => false, - 'example' => '这个任务做了这些事。', - ], - 'EvaluationConfig' => [ - 'description' => '从json格式的链路数据里要一些提取特定路径上的值,作为评估操作的输入。在这个EvaluationConfig结构体里定义这些json路径。', - 'required' => false, - '$ref' => '#/components/schemas/EvaluationConfig', - ], - 'ModelConfig' => [ - 'description' => '评估任务内部使用的大模型的访问配置结构体。', - 'required' => false, - '$ref' => '#/components/schemas/ModelConfig', - ], - ], - 'required' => false, - ], - ], - ], - 'responses' => [ - 200 => [ - 'schema' => [ - 'title' => 'Schema of Response', - 'description' => 'Schema of Response', - 'type' => 'object', - 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the POP request', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'cannot modify a stopped task', - ], - ], - ], - ], - ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"cannot modify a stopped task\\"\\n}","type":"json"}]', - 'title' => '更改一个链路评估任务的配置。', - ], - 'CreateOnlineEvalTask' => [ - 'summary' => '创建一个链路评估任务。系统会根据任务配置,从用户的链路数据里采样部分数据,用大模型对这些链路的执行效果做评估,并记录评估结果。', - 'path' => '/api/v1/PAILLMTrace/onlineevaltasks', - 'methods' => [ - 'post', - ], - 'schemes' => [ - 'https', - ], - 'security' => [ - [ - 'AK' => [], - ], - ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], - 'operationType' => 'write', - 'deprecated' => false, - 'systemTags' => [ - 'operationType' => 'create', - 'riskType' => 'none', - 'chargeType' => 'free', - 'abilityTreeCode' => '241117', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], - 'tenantRelevance' => 'publicInformation', - ], - 'parameters' => [ - [ - 'name' => 'body', - 'in' => 'query', - 'style' => 'json', - 'schema' => [ - 'description' => '请求Body。', - 'type' => 'object', - 'properties' => [ - 'TaskName' => [ - 'description' => '任务名称。', - 'type' => 'string', - 'required' => false, - 'example' => 'my-llm-app-eval-task-1', - ], - 'AppName' => [ - 'description' => '用户应用在链路数据里记录的名称', - 'type' => 'string', - 'required' => false, - 'example' => 'my-best-llm-app', - ], - 'StartTime' => [ - 'description' => '链路数据的UTC开始时间', - 'type' => 'string', - 'required' => false, - 'example' => '2025-04-05 14:00:01'."\n" - .'2025-04-05', - ], - 'EndTime' => [ - 'description' => '链路数据的UTC结束时间', - 'type' => 'string', - 'required' => false, - 'example' => '2025-06-05 14:00:01'."\n" - .'2025-06-05', - ], - 'SamplingFrequencyMinutes' => [ - 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义任务每次搜索输入数据的时间窗口的宽度。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '9', - ], - 'Description' => [ - 'description' => '任务描述信息', - 'type' => 'string', - 'required' => false, - 'example' => '4月到6月数据评估', - ], - 'Filters' => [ - 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义搜索筛选条件的列表。', - 'type' => 'array', - 'items' => [ - 'description' => '过滤条件对象。', - 'type' => 'object', - 'properties' => [ - 'Key' => [ - 'description' => '过滤条件的key', - 'type' => 'string', - 'required' => false, - 'enumValueTitles' => [ - 'Status' => 'Status', - 'SpanName' => 'SpanName', - 'Input' => 'Input', - 'TraceType' => 'TraceType', - 'SpanType' => 'SpanType', - 'ServiceName' => 'ServiceName', - 'Output' => 'Output', - 'TraceName' => 'TraceName', - 'ServiceId' => 'ServiceId', - ], - 'example' => 'ServiceId'."\n" - .'ServiceName'."\n" - .'Input'."\n" - .'Output'."\n" - .'Status'."\n" - .'TraceType'."\n" - .'SpanType'."\n" - .'TraceName'."\n" - .'SpanName', - ], - 'Operator' => [ - 'description' => '过滤条件匹配操作符', - 'type' => 'string', - 'required' => false, - 'enumValueTitles' => [ - 'Contains' => 'Contains', - '=' => '=', - 'StartsWith' => 'StartsWith', - ], - 'example' => '='."\n" - .'StartsWith'."\n" - .'Contains'."\n", - ], - 'Value' => [ - 'description' => '过滤条件的值', - 'type' => 'string', - 'required' => false, - 'example' => 'foo', - ], - ], - 'required' => false, - ], - 'required' => false, - ], - 'SamplingRatio' => [ - 'description' => '评估任务在一个时间窗口里搜索到的数据,真正作为评估输入数据的百分比。比如100表示搜索到的所有数据都作为评估输入。又比如20表示从搜索到的数据里随机取20%作为评估输入。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '50', - ], - 'EvaluationConfig' => [ - 'description' => '从json格式的链路数据里要一些提取特定路径上的值,作为评估操作的输入。在这个EvaluationConfig结构体里定义这些json路径。', - 'required' => false, - '$ref' => '#/components/schemas/EvaluationConfig', - ], - 'ModelConfig' => [ - 'description' => '评估任务内部使用的大模型的访问配置结构体。', - 'required' => false, - '$ref' => '#/components/schemas/ModelConfig', - ], - ], - 'required' => false, - ], - ], - ], - 'responses' => [ - 200 => [ - 'schema' => [ - 'title' => 'Schema of Response', - 'description' => 'Schema of Response', - 'type' => 'object', - 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'TaskId' => [ - 'description' => '新创建的链路评估任务的id。', - 'type' => 'string', - 'example' => '711ef9112343286810abbfce04e161ee', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'EvaluationConfig.Answer.SpanName is required.', - ], - ], - ], - ], - ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"TaskId\\": \\"711ef9112343286810abbfce04e161ee\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"EvaluationConfig.Answer.SpanName is required.\\"\\n}","type":"json"}]', - 'title' => '创建一个链路评估任务。', ], 'ListTracesDatas' => [ 'summary' => '每条链路数据记录,可以命名为trace。一个trace包含了一组span记录。这个API以trace为粒度执行搜索,按照指定条件获取trace数据列表。', 'path' => '/api/v1/PAILLMTrace/TracesDatas', - 'methods' => [ - 'get', - ], - 'schemes' => [ - 'https', - ], + 'methods' => ['get'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], 'operationType' => 'read', 'deprecated' => false, 'systemTags' => [ @@ -1698,9 +1024,7 @@ 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeCode' => '215404', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], 'tenantRelevance' => 'publicInformation', ], 'parameters' => [ @@ -1711,12 +1035,7 @@ 'schema' => [ 'description' => '链路id数组。', 'type' => 'array', - 'items' => [ - 'description' => '一个链路id', - 'type' => 'string', - 'required' => false, - 'example' => '4d097fb3d451bad0148feefb4ab95', - ], + 'items' => ['description' => '一个链路id', 'type' => 'string', 'required' => false, 'example' => '4d097fb3d451bad0148feefb4ab95'], 'required' => false, ], ], @@ -1727,163 +1046,81 @@ 'schema' => [ 'description' => 'span id数组。一条链路记录里包含一个或多个span。', 'type' => 'array', - 'items' => [ - 'title' => 'The ids to list', - 'description' => '一个span id', - 'type' => 'string', - 'required' => false, - 'example' => '17d4ef87a1fe8', - ], + 'items' => ['title' => 'The ids to list', 'description' => '一个span id', 'type' => 'string', 'required' => false, 'example' => '17d4ef87a1fe8'], 'required' => false, ], ], [ 'name' => 'SessionId', 'in' => 'query', - 'schema' => [ - 'description' => '链路记录里attributes.gen_ai.session.id字段的值。默认为空。', - 'type' => 'string', - 'required' => false, - 'example' => 'e5895063-9b29-4ce4-b0fd-a018bfa11111', - ], + 'schema' => ['description' => '链路记录里attributes.gen_ai.session.id字段的值。默认为空。', 'type' => 'string', 'required' => false, 'example' => 'e5895063-9b29-4ce4-b0fd-a018bfa11111'], ], [ 'name' => 'MinTime', 'in' => 'query', - 'schema' => [ - 'title' => '当总结果个数大于MaxResults时,用于翻页的token。', - 'description' => '搜索时间范围下限,UTC时间,YYYY-mm-dd或者YYYY-MM-DD HH:mm:ss格式。默认(当前时间 - 2天)', - 'type' => 'string', - 'required' => true, - 'example' => '2024-01-31'."\n" - .'2024-12-31 23:59:59', - ], + 'schema' => ['title' => '当总结果个数大于MaxResults时,用于翻页的token。', 'description' => '搜索时间范围下限,UTC时间,YYYY-mm-dd或者YYYY-MM-DD HH:mm:ss格式。默认(当前时间 - 2天)', 'type' => 'string', 'required' => true, 'example' => '2024-01-31'."\n" + .'2024-12-31 23:59:59'], ], [ 'name' => 'MaxTime', 'in' => 'query', - 'schema' => [ - 'description' => '搜索时间范围上限,UTC时间,YYYY-mm-dd或者YYYY-MM-DD HH:mm:ss格式。默认(当前时间 + 10分钟)', - 'type' => 'string', - 'required' => false, - 'example' => '2024-01-31'."\n" - .'2024-12-31 23:59:59', - ], + 'schema' => ['description' => '搜索时间范围上限,UTC时间,YYYY-mm-dd或者YYYY-MM-DD HH:mm:ss格式。默认(当前时间 + 10分钟)', 'type' => 'string', 'required' => false, 'example' => '2024-01-31'."\n" + .'2024-12-31 23:59:59'], ], [ 'name' => 'PageNumber', 'in' => 'query', - 'schema' => [ - 'description' => '分页查询时设置的页码。 起始值:1。默认值:1。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '1', - ], + 'schema' => ['description' => '分页查询时设置的页码。 起始值:1。默认值:1。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '1'], ], [ 'name' => 'PageSize', 'in' => 'query', - 'schema' => [ - 'description' => '分页大小,默认值10,最大值50。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '10', - ], + 'schema' => ['description' => '分页大小,默认值10,最大值50。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '10'], ], [ 'name' => 'SpanName', 'in' => 'query', - 'schema' => [ - 'description' => '查找Trace时使用的过滤条件,返回包含该span名称的Trace。', - 'type' => 'string', - 'required' => false, - 'example' => 'ChatFlow.astream_chat', - ], + 'schema' => ['description' => '查找Trace时使用的过滤条件,返回包含该span名称的Trace。', 'type' => 'string', 'required' => false, 'example' => 'ChatFlow.astream_chat'], ], [ 'name' => 'LlmAppName', 'in' => 'query', - 'schema' => [ - 'description' => '链路记录里,resources.service.app.name字段的值。允许a-zA-Z0-9 dot, hyphen, underscore这些字符。必须完全匹配。默认为空。', - 'type' => 'string', - 'required' => false, - 'example' => 'My.super_LLM-app2', - ], + 'schema' => ['description' => '链路记录里,resources.service.app.name字段的值。允许a-zA-Z0-9 dot, hyphen, underscore这些字符。必须完全匹配。默认为空。', 'type' => 'string', 'required' => false, 'example' => 'My.super_LLM-app2'], ], [ 'name' => 'MinDuration', 'in' => 'query', - 'schema' => [ - 'description' => '查找Trace时使用的过滤条件,Trace的最小持续时长。单位为秒(s)。', - 'type' => 'number', - 'format' => 'float', - 'required' => false, - 'example' => '2', - ], + 'schema' => ['description' => '查找Trace时使用的过滤条件,Trace的最小持续时长。单位为秒(s)。', 'type' => 'number', 'format' => 'float', 'required' => false, 'example' => '2'], ], [ 'name' => 'MaxDuration', 'in' => 'query', - 'schema' => [ - 'description' => '查找Trace时使用的过滤条件,Trace的最大持续时长。单位为秒(s)。', - 'type' => 'number', - 'format' => 'float', - 'required' => false, - 'example' => '5', - ], + 'schema' => ['description' => '查找Trace时使用的过滤条件,Trace的最大持续时长。单位为秒(s)。', 'type' => 'number', 'format' => 'float', 'required' => false, 'example' => '5'], ], [ 'name' => 'OpentelemetryCompatible', 'in' => 'query', - 'schema' => [ - 'description' => '返回的json格式数据是否可以直接转换成opentelemetry TracesData protobuf对象。默认为False。OpenTelemetry格式兼容的json数据,格式更复杂,除非为了生成OpenTelemetry的protobuf对象,一般不需要这种格式的数据。', - 'type' => 'boolean', - 'required' => false, - 'example' => 'False', - 'default' => 'False', - ], + 'schema' => ['description' => '返回的json格式数据是否可以直接转换成opentelemetry TracesData protobuf对象。默认为False。OpenTelemetry格式兼容的json数据,格式更复杂,除非为了生成OpenTelemetry的protobuf对象,一般不需要这种格式的数据。', 'type' => 'boolean', 'required' => false, 'example' => 'False', 'default' => 'False'], ], [ 'name' => 'HasStatusMessage', 'in' => 'query', - 'schema' => [ - 'description' => '是否只返回包含有statusMessage不为空的span的链路记录。比如1个链路里有3个span,如果该项为True,3个span任何1个有非空的statusMessage,那么这个链路就符合条件。默认为False,不用statusMessage状态做筛选。', - 'type' => 'boolean', - 'required' => false, - 'example' => 'False', - ], + 'schema' => ['description' => '是否只返回包含有statusMessage不为空的span的链路记录。比如1个链路里有3个span,如果该项为True,3个span任何1个有非空的statusMessage,那么这个链路就符合条件。默认为False,不用statusMessage状态做筛选。', 'type' => 'boolean', 'required' => false, 'example' => 'False'], ], [ 'name' => 'HasEvents', 'in' => 'query', - 'schema' => [ - 'description' => '是否只返回包含有events不为空的span的链路记录。比如1个链路里有3个span,如果该项为True,3个span任何1个有非空的events,那么这个链路记录就符合条件。默认为False,不用events状态做筛选。', - 'type' => 'boolean', - 'required' => false, - 'example' => 'False', - ], + 'schema' => ['description' => '是否只返回包含有events不为空的span的链路记录。比如1个链路里有3个span,如果该项为True,3个span任何1个有非空的events,那么这个链路记录就符合条件。默认为False,不用events状态做筛选。', 'type' => 'boolean', 'required' => false, 'example' => 'False'], ], [ 'name' => 'OwnerSubId', 'in' => 'query', - 'schema' => [ - 'description' => '链路记录里resources.service.owner.sub_id字段的值。允许a-zA-Z0-9 dot, hyphen, underscore这些字符。默认为空。', - 'type' => 'string', - 'required' => false, - 'example' => '123456789', - ], + 'schema' => ['description' => '链路记录里resources.service.owner.sub_id字段的值。允许a-zA-Z0-9 dot, hyphen, underscore这些字符。默认为空。', 'type' => 'string', 'required' => false, 'example' => '123456789'], ], [ 'name' => 'EndUserId', 'in' => 'query', - 'schema' => [ - 'description' => '链路记录里attributes.service.app.user_id字段的值。允许a-zA-Z0-9 dot, hyphen, underscore这些字符。默认为空。', - 'type' => 'string', - 'required' => false, - 'example' => 'end-user.12345', - ], + 'schema' => ['description' => '链路记录里attributes.service.app.user_id字段的值。允许a-zA-Z0-9 dot, hyphen, underscore这些字符。默认为空。', 'type' => 'string', 'required' => false, 'example' => 'end-user.12345'], ], [ 'name' => 'Filters', @@ -1921,36 +1158,17 @@ .'比如用户自定义key为 foo.bar,那么服务端会在attributes.foo.bar 这个位置执行筛选。比如用户自定义key为 gen_ai.FOO.BAR,那么服务端会在attributes.gen_ai.FOO.BAR 这个位置执行筛选。', 'type' => 'string', 'required' => false, - 'enumValueTitles' => [ - 'Status' => 'Status', - 'SpanName' => 'SpanName', - 'Input' => 'Input', - 'TraceType' => 'TraceType', - 'SpanType' => 'SpanType', - 'ServiceName' => 'ServiceName', - 'Output' => 'Output', - 'TraceName' => 'TraceName', - 'ServiceId' => 'ServiceId', - ], + 'enumValueTitles' => ['Status' => 'Status', 'SpanName' => 'SpanName', 'Input' => 'Input', 'TraceType' => 'TraceType', 'SpanType' => 'SpanType', 'ServiceName' => 'ServiceName', 'Output' => 'Output', 'TraceName' => 'TraceName', 'ServiceId' => 'ServiceId'], 'example' => 'output', ], 'Operator' => [ 'description' => '参数运算符。大小写不敏感。目前支持:‘=’,’contains‘,\'startswith\'。', 'type' => 'string', 'required' => false, - 'enumValueTitles' => [ - 'contains' => 'contains', - '=' => '=', - 'startsWith' => 'startsWith', - ], + 'enumValueTitles' => ['contains' => 'contains', '=' => '=', 'startsWith' => 'startsWith'], 'example' => 'contains', ], - 'Value' => [ - 'description' => '过滤参数取值。对于contains操作,大小写敏感。其它操作,大小写不敏感。', - 'type' => 'string', - 'required' => false, - 'example' => '智能填写', - ], + 'Value' => ['description' => '过滤参数取值。对于contains操作,大小写敏感。其它操作,大小写不敏感。', 'type' => 'string', 'required' => false, 'example' => '智能填写'], ], 'required' => false, ], @@ -1970,10 +1188,7 @@ .'不填写 - 则维持原有数据', 'type' => 'string', 'required' => false, - 'enumValueTitles' => [ - 'ROOT_ONLY' => 'ROOT_ONLY', - 'REMOVE_EMBEDDING' => 'REMOVE_EMBEDDING', - ], + 'enumValueTitles' => ['ROOT_ONLY' => 'ROOT_ONLY', 'REMOVE_EMBEDDING' => 'REMOVE_EMBEDDING'], 'example' => 'REMOVE_EMBEDDING'."\n" .'ROOT_ONLY', ], @@ -1985,10 +1200,7 @@ 'description' => '返回结果排序字段,目前支持trace开始时间、trace时长、trace总token数量、和trace id。', 'type' => 'string', 'required' => false, - 'enumValueTitles' => [ - 'StartTime' => 'StartTime', - 'Duration' => 'Duration', - ], + 'enumValueTitles' => ['StartTime' => 'StartTime', 'Duration' => 'Duration'], 'example' => 'StartTime'."\n" .'Duration'."\n" .'TotalTokens'."\n" @@ -2004,10 +1216,7 @@ .'- **DESC**(默认值):降序', 'type' => 'string', 'required' => false, - 'enumValueTitles' => [ - 'ASC' => 'ASC', - 'DESC' => 'DESC', - ], + 'enumValueTitles' => ['ASC' => 'ASC', 'DESC' => 'DESC'], 'example' => 'DESC'."\n" .'ASC', ], @@ -2020,88 +1229,72 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'TotalCount' => [ - 'title' => '总记录数。', - 'description' => '符合条件的trace的总数。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '22', - ], - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'POP request id', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'ExecutionFailure', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'failed to get trace data', - ], + 'TotalCount' => ['title' => '总记录数。', 'description' => '符合条件的trace的总数。', 'type' => 'integer', 'format' => 'int32', 'example' => '22'], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'POP request id', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'ExecutionFailure'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'failed to get trace data'], 'Traces' => [ 'description' => 'json array,每个element是一个trace的json string。array长度等于或者小于page size参数值。', 'type' => 'array', - 'items' => [ - 'description' => '代表一个trace的json string。', - 'type' => 'any', - 'example' => 'open telemetry compatible:'."\n" - .'{"resource_spans":[{"resource":{"attributes":[{"key":"telemetry.sdk.language","value":{"string_value":"python"}},{"key":"telemetry.sdk.name","value":{"string_value":"opentelemetry"}},{"key":"telemetry.sdk.version","value":{"string_value":"1.25.0"}},{"key":"service.name","value":{"string_value":"llm_trace_llamaindex_test_template"}},{"key":"service.version","value":{"string_value":"0.0.1"}},{"key":"deployment.environment","value":{"string_value":"cn-hangzhou"}},{"key":"service.app.name","value":{"string_value":"llm_trace_llamaindex_test"}},{"key":"service.owner.id","value":{"string_value":"177393915"}},{"key":"service.owner.sub_id","value":{"string_value":"230589443368"}}]},"scope_spans":[{"spans":[{"trace_id":"ae40025eae77fbab21687bd7e41c","span_id":"e09710fbd3c6","parent_span_id":"0","name":"query","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910212440262841","end_time_unix_nano":"1718910215403326721","attributes":[{"key":"input.value","value":{"string_value":"Question 1: what is pai-llm-trace."}},{"key":"openinference.span.kind","value":{"string_value":"CHAIN"}},{"key":"output.value","value":{"string_value":"The term \\"pai-llm-trace\\" refers to a component or module within the project or codebase being worked on."}},{"key":"pop.request.id","value":{"string_value":"1C714E-057D-1216-835A-06F722E4F3"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"444bae400277fbab21687bd7e41c","span_id":"5686fa7a6b85b","parent_span_id":"e0a5920fbd3c6","name":"retrieve","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910212440884059","end_time_unix_nano":"1718910213181800657","attributes":[{"key":"input.value","value":{"string_value":"Question 1: what is pai-llm-trace."}},{"key":"openinference.span.kind","value":{"string_value":"RETRIEVER"}},{"key":"pop.request.id","value":{"string_value":"E8A1F8D9-D35A-1F9F-B724-5DA12E6F612"}},{"key":"retrieval.documents","value":{"array_value":{"values":[{"kvlist_value":{"values":[{"key":"document.content","value":{"string_value":".PHONY: clean package test\\n\\nclean:\\n\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\n\\npackage: clean\\n\\tpip install build && python -m build\\n\\nrun:\\n\\tbash tools/run_test.sh"}},{"key":"document.id","value":{"string_value":"c3bd0f7e-2-42f7-964c-2fcc698657db"}},{"key":"document.metadata","value":{"string_value":"{\\"file_path\\": \\"/mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\", \\"file_name\\": \\"makefile\\", \\"file_size\\": 213, \\"creation_date\\": \\"2024-05-10\\", \\"last_modified_date\\": \\"2024-05-10\\"}"}},{"key":"document.score","value":{"double_value":0.592955599044689}},{"key":"vector_index","value":{"int_value":"0"}}]}}]}}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"444bae4e77fbab21687bd7e41c","span_id":"f2fc6f6acbc7","parent_span_id":"f08a7a6b85b","name":"embedding","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910212441468561","end_time_unix_nano":"1718910212617063167","attributes":[{"key":"embedding.embeddings","value":{"array_value":{"values":[{"kvlist_value":{"values":[{"key":"embedding.text","value":{"string_value":"Question 1: what is pai-llm-trace."}},{"key":"embedding.vector","value":{"string_value":"PAI LLM Trace system hid 1536 actual items"}},{"key":"vector_index","value":{"int_value":"0"}}]}}]}}},{"key":"embedding.model_name","value":{"string_value":"text-embedding-ada-002"}},{"key":"openinference.span.kind","value":{"string_value":"EMBEDDING"}},{"key":"pop.request.id","value":{"string_value":"56B9CCC3-CC84-0ED-53F60DC4A318"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"ae25eae77fbab21687bd7e41c","span_id":"f2ebc6f12b27","parent_span_id":"e0a710fbd3c6","name":"synthesize","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910213465461860","end_time_unix_nano":"1718910215131655555","attributes":[{"key":"input.value","value":{"string_value":"Question 1: what is pai-llm-trace."}},{"key":"openinference.span.kind","value":{"string_value":"CHAIN"}},{"key":"output.value","value":{"string_value":"The term \\"pai-llm-trace\\" refers to a component or module within the project or codebase being worked on."}},{"key":"pop.request.id","value":{"string_value":"67D34C0D-1CD5-11B7-BEE2-05649"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"21687bd7e41c","span_id":"d8f3fc7c","parent_span_id":"f2ebc12b27","name":"chunking","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910213467525240","end_time_unix_nano":"1718910213467894216","attributes":[{"key":"openinference.span.kind","value":{"string_value":"CHAIN"}},{"key":"pop.request.id","value":{"string_value":"8E1625-B8D1-EA177F9FC69D"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"5eae77fbab7bd7e41c","span_id":"0ab8a7c75","parent_span_id":"f2ebcf12b27","name":"chunking","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910213733013448","end_time_unix_nano":"1718910213733446902","attributes":[{"key":"openinference.span.kind","value":{"string_value":"CHAIN"}},{"key":"pop.request.id","value":{"string_value":"14D0D5-1675-BCA7-AF320E26C1A4"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"25eae77fbab87bd7e41c","span_id":"2cb6c51c5fb2","parent_span_id":"f2ebcf12b27","name":"llm","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910214008467118","end_time_unix_nano":"1718910214849631714","attributes":[{"key":"llm.completions","value":{"array_value":{"values":[{"kvlist_value":{"values":[{"key":"message.content","value":{"string_value":"The term \\"pai-llm-trace\\" refersto a component or module within the project or codebase being worked on."}},{"key":"message.role","value":{"string_value":"assistant"}},{"key":"vector_index","value":{"int_value":"0"}}]}}]}}},{"key":"llm.invocation_parameters","value":{"string_value":"{\\"temperature\\": 0.1, \\"model\\": \\"gpt-3.5-turbo\\"}"}},{"key":"llm.model_name","value":{"string_value":"gpt-3.5-turbo"}},{"key":"llm.prompt_template.template","value":{"string_value":"system: You are an expert Q&A system that is trusted around the world.\\nAlways answer the query using the provided context information, and not prior knowledge.\\nSome rules to follow:\\n1. Never directly reference thegiven context in your answer.\\n2. Avoid statements like \'Based on the context, ...\' or \'The context information ...\' or anything along those lines.\\nuser: Context information is below.\\n---------------------\\n{context_str}\\n---------------------\\nGiven the context information and not prior knowledge, answer the query.\\nQuery: {query_str}\\nAnswer: \\nassistant: "}},{"key":"llm.prompt_template.variables","value":{"string_value":"{\\"context_str\\": \\"file_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\n\\\\n.PHONY: clean package test\\\\n\\\\nclean:\\\\n\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\n\\\\npackage: clean\\\\n\\\\tpip install build && python -m build\\\\n\\\\nrun:\\\\n\\\\tbash tools/run_test.sh\\", \\"query_str\\": \\"Question 1: what is pai-llm-trace.\\"}"}},{"key":"llm.prompts","value":{"array_value":{"values":[{"kvlist_value":{"values":[{"key":"message.content","value":{"string_value":"You are an expert Q&A system that is trusted around the world.\\nAlways answer the query using the provided context information, and not prior knowledge.\\nSome rules to follow:\\n1. Never directly reference the given context in your answer.\\n2. Avoid statements like \'Based on the context, ...\' or \'The context information ...\' or anything along those lines."}},{"key":"message.role","value":{"string_value":"system"}},{"key":"vector_index","value":{"int_value":"0"}}]}},{"kvlist_value":{"values":[{"key":"message.content","value":{"string_value":"Context information is below.\\n---------------------\\nfile_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\n\\n.PHONY: clean package test\\n\\nclean:\\n\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\n\\npackage: clean\\n\\tpip install build && python -m build\\n\\nrun:\\n\\tbash tools/run_test.sh\\n---------------------\\nGiven the context information and not prior knowledge, answer the query.\\nQuery: Question 1:what is pai-llm-trace.\\nAnswer: "}},{"key":"message.role","value":{"string_value":"user"}},{"key":"vector_index","value":{"int_value":"1"}}]}}]}}},{"key":"llm.token_count.completion","value":{"string_value":"26"}},{"key":"llm.token_count.prompt","value":{"string_value":"210"}},{"key":"llm.token_count.total","value":{"string_value":"236"}},{"key":"openinference.span.kind","value":{"string_value":"LLM"}},{"key":"output.value","value":{"string_value":"The term \\"pai-llm-trace\\" refers to a component or module within the project or codebase being worked on."}},{"key":"pop.request.id","value":{"string_value":"AA68F16D-A8B7-1BB0-1BD1E47B5"}}],"status":{"code":"STATUS_CODE_OK"}}]}]}]}'."\n" - ."\n" - .'open telemetry incompatible:'."\n" - .'[{"aliyunUid": "1773939154", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "177393915", "sub_id": "2305894433"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "444bae77fbab7bd7e41c", "spanId": "e0a0fbd3c6", "parentSpanId": "0", "kind": "SPAN_KIND_INTERNAL", "spanName": "query", "links": [], "events": [], "traceState": "", "startTime": 1718910212440262841, "endTime": 1718910215403326721, "duration": 2963063880, "attributes": {"input": {"value": "Question 1: what is pai-llm-trace."}, "openinference": {"span": {"kind": "CHAIN"}},"output": {"value": "The term \\\\"pai-llm-trace\\\\" refers to a component or module within the project or codebase being worked on."}, "pop": {"request": {"id": "1C70E14E-06F7D4F3"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "773939154", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "1773939", "sub_id": "2305819539"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "baeeae77fbab21687bd7e41c", "spanId": "ff08a7a6b85b", "parentSpanId": "e0a0fbd3c6", "kind": "SPAN_KIND_INTERNAL", "spanName": "retrieve", "links": [], "events": [], "traceState": "","startTime": 1718910212440884059, "endTime": 1718910213181800657, "duration": 740916598, "attributes": {"input": {"value": "Question 1: what is pai-llm-trace."}, "openinference": {"span": {"kind": "RETRIEVER"}}, "pop": {"request": {"id": "E8A1F8D9-D35A-1F9F2E6F612"}}, "retrieval": {"documents": [{"document": {"content": ".PHONY: clean package test\\\\n\\\\nclean:\\\\n\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\n\\\\npackage: clean\\\\n\\\\tpip install build && python -m build\\\\n\\\\nrun:\\\\n\\\\tbash tools/run_test.sh", "id": "c3bd0f7e-7--2fcc8657db", "metadata": "{\\\\"file_path\\\\": \\\\"/mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\", \\\\"file_name\\\\": \\\\"makefile\\\\", \\\\"file_size\\\\": 213, \\\\"creation_date\\\\": \\\\"2024-05-10\\\\", \\\\"last_modified_date\\\\": \\\\"2024-05-10\\\\"}", "score": 0.592955599044689}}]}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939154062345", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "1793915", "sub_id": "58944336"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "444baebd7e41c", "spanId": "fc6f6acbc7", "parentSpanId": "f08a7a6b85b", "kind": "SPAN_KIND_INTERNAL", "spanName": "embedding", "links": [],"events": [], "traceState": "", "startTime": 1718910212441468561, "endTime": 1718910212617063167, "duration": 175594606, "attributes": {"embedding": {"embeddings": [{"embedding": {"text": "Question 1: what is pai-llm-trace.", "vector": "PAI LLM Trace system hid 1536 actual items"}}], "model_name": "text-embedding-ada-002"}, "openinference": {"span": {"kind": "EMBEDDING"}}, "pop": {"request": {"id": "56B9CCC3-CC84-80ED-53F60DC4A"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "17739391540", "sub_id": "23058944336"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "eae77fbab21687bd7e41c", "spanId": "f2ebcf12b27", "parentSpanId": "e0afbd3c6", "kind": "SPAN_KIND_INTERNAL", "spanName": "synthesize", "links": [], "events": [], "traceState": "", "startTime": 1718910213465461860, "endTime": 1718910215131655555, "duration": 1666193695, "attributes": {"input": {"value": "Question 1: what is pai-llm-trace."}, "openinference": {"span": {"kind": "CHAIN"}}, "output": {"value": "The term \\\\"pai-llm-trace\\\\" refers to a component or module within the project or codebase being worked on."}, "pop": {"request": {"id": "67D34C0D-1CD5-11B7-BEE2-0F90DCC"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "177393915", "sub_id": "23058944336"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "ae0ae77fbab87bd7e41c", "spanId": "d8f3fc6d47c", "parentSpanId": "f2ebcf12b27", "kind": "SPAN_KIND_INTERNAL", "spanName": "chunking", "links": [], "events": [], "traceState": "", "startTime": 1718910213467525240, "endTime": 1718910213467894216, "duration": 368976, "attributes": {"openinference": {"span": {"kind": "CHAIN"}}, "pop": {"request": {"id": "8EA31C-5-B8D1-EA177F9FC69D"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name":"llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "17739391", "sub_id": "23058944"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name":"opentelemetry", "version": "1.25.0"}}}, "traceId": "444babd7e41c", "spanId": "0aba7c75", "parentSpanId": "f2ebc6f12b27", "kind": "SPAN_KIND_INTERNAL", "spanName": "chunking", "links": [], "events": [], "traceState": "", "startTime": 1718910213733013448, "endTime": 1718910213733446902, "duration": 433454, "attributes": {"openinference": {"span": {"kind": "CHAIN"}}, "pop": {"request": {"id": "14D0D75-BCA7-AFE26C1A4"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "177393915", "sub_id": "2305894433"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "ae025eae77fbab7bd7e41c", "spanId": "2cb6c51c5fb2", "parentSpanId": "f2ebc6f12b27", "kind": "SPAN_KIND_INTERNAL", "spanName": "llm","links": [], "events": [], "traceState": "", "startTime": 1718910214008467118, "endTime": 1718910214849631714, "duration": 841164596, "attributes": {"llm": {"completions": [{"message": {"content": "The term \\\\"pai-llm-trace\\\\" refers to a component or module within the project or codebase being worked on.", "role": "assistant"}}], "invocation_parameters": "{\\\\"temperature\\\\": 0.1, \\\\"model\\\\": \\\\"gpt-3.5-turbo\\\\"}", "model_name": "gpt-3.5-turbo", "prompt_template": {"template": "system: You are an expert Q&A system that is trusted around the world.\\\\nAlways answer the query using the provided context information, and not prior knowledge.\\\\nSome rules to follow:\\\\n1. Never directly reference the given context in your answer.\\\\n2. Avoid statements like \\\'Based on the context, ...\\\' or \\\'The context information ...\\\' or anything along those lines.\\\\nuser: Contextinformation is below.\\\\n---------------------\\\\n{context_str}\\\\n---------------------\\\\nGiven the context information and not prior knowledge, answer the query.\\\\nQuery: {query_str}\\\\nAnswer: \\\\nassistant: ", "variables": "{\\\\"context_str\\\\": \\\\"file_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\\\\\n\\\\\\\\n.PHONY: clean package test\\\\\\\\n\\\\\\\\nclean:\\\\\\\\n\\\\\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__src/pai/llm_trace/__pycache__\\\\\\\\n\\\\\\\\npackage: clean\\\\\\\\n\\\\\\\\tpip install build && python -m build\\\\\\\\n\\\\\\\\nrun:\\\\\\\\n\\\\\\\\tbash tools/run_test.sh\\\\", \\\\"query_str\\\\": \\\\"Question 1: what is pai-llm-trace.\\\\"}"}, "prompts": [{"message": {"content": "You are an expert Q&A system that is trusted around the world.\\\\nAlways answer the query using the provided context information, and not prior knowledge.\\\\nSome rules to follow:\\\\n1. Never directly reference the given context in your answer.\\\\n2. Avoid statements like \\\'Based on the context, ...\\\' or \\\'The context information ...\\\' or anything along those lines.", "role": "system"}}, {"message": {"content": "Context information is below.\\\\n---------------------\\\\nfile_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\n\\\\n.PHONY: clean package test\\\\n\\\\nclean:\\\\n\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\n\\\\npackage: clean\\\\n\\\\tpip install build && python -m build\\\\n\\\\nrun:\\\\n\\\\tbash tools/run_test.sh\\\\n---------------------\\\\nGiven the context information and notprior knowledge, answer the query.\\\\nQuery: Question 1: what is pai-llm-trace.\\\\nAnswer: ", "role": "user"}}], "token_count": {"completion": "26", "prompt": "210", "total": "236"}}, "openinference": {"span": {"kind": "LLM"}}, "output": {"value": "The term \\\\"pai-llm-trace\\\\" refers to a component or module within the project or codebase being worked on."}, "pop": {"request": {"id": "AA68F16D-A8B7-1BB0-1BD1E47B5"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}]', - ], + 'items' => ['description' => '代表一个trace的json string。', 'type' => 'any', 'example' => 'open telemetry compatible:'."\n" + .'{"resource_spans":[{"resource":{"attributes":[{"key":"telemetry.sdk.language","value":{"string_value":"python"}},{"key":"telemetry.sdk.name","value":{"string_value":"opentelemetry"}},{"key":"telemetry.sdk.version","value":{"string_value":"1.25.0"}},{"key":"service.name","value":{"string_value":"llm_trace_llamaindex_test_template"}},{"key":"service.version","value":{"string_value":"0.0.1"}},{"key":"deployment.environment","value":{"string_value":"cn-hangzhou"}},{"key":"service.app.name","value":{"string_value":"llm_trace_llamaindex_test"}},{"key":"service.owner.id","value":{"string_value":"177393915"}},{"key":"service.owner.sub_id","value":{"string_value":"230589443368"}}]},"scope_spans":[{"spans":[{"trace_id":"ae40025eae77fbab21687bd7e41c","span_id":"e09710fbd3c6","parent_span_id":"0","name":"query","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910212440262841","end_time_unix_nano":"1718910215403326721","attributes":[{"key":"input.value","value":{"string_value":"Question 1: what is pai-llm-trace."}},{"key":"openinference.span.kind","value":{"string_value":"CHAIN"}},{"key":"output.value","value":{"string_value":"The term \\"pai-llm-trace\\" refers to a component or module within the project or codebase being worked on."}},{"key":"pop.request.id","value":{"string_value":"1C714E-057D-1216-835A-06F722E4F3"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"444bae400277fbab21687bd7e41c","span_id":"5686fa7a6b85b","parent_span_id":"e0a5920fbd3c6","name":"retrieve","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910212440884059","end_time_unix_nano":"1718910213181800657","attributes":[{"key":"input.value","value":{"string_value":"Question 1: what is pai-llm-trace."}},{"key":"openinference.span.kind","value":{"string_value":"RETRIEVER"}},{"key":"pop.request.id","value":{"string_value":"E8A1F8D9-D35A-1F9F-B724-5DA12E6F612"}},{"key":"retrieval.documents","value":{"array_value":{"values":[{"kvlist_value":{"values":[{"key":"document.content","value":{"string_value":".PHONY: clean package test\\n\\nclean:\\n\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\n\\npackage: clean\\n\\tpip install build && python -m build\\n\\nrun:\\n\\tbash tools/run_test.sh"}},{"key":"document.id","value":{"string_value":"c3bd0f7e-2-42f7-964c-2fcc698657db"}},{"key":"document.metadata","value":{"string_value":"{\\"file_path\\": \\"/mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\", \\"file_name\\": \\"makefile\\", \\"file_size\\": 213, \\"creation_date\\": \\"2024-05-10\\", \\"last_modified_date\\": \\"2024-05-10\\"}"}},{"key":"document.score","value":{"double_value":0.592955599044689}},{"key":"vector_index","value":{"int_value":"0"}}]}}]}}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"444bae4e77fbab21687bd7e41c","span_id":"f2fc6f6acbc7","parent_span_id":"f08a7a6b85b","name":"embedding","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910212441468561","end_time_unix_nano":"1718910212617063167","attributes":[{"key":"embedding.embeddings","value":{"array_value":{"values":[{"kvlist_value":{"values":[{"key":"embedding.text","value":{"string_value":"Question 1: what is pai-llm-trace."}},{"key":"embedding.vector","value":{"string_value":"PAI LLM Trace system hid 1536 actual items"}},{"key":"vector_index","value":{"int_value":"0"}}]}}]}}},{"key":"embedding.model_name","value":{"string_value":"text-embedding-ada-002"}},{"key":"openinference.span.kind","value":{"string_value":"EMBEDDING"}},{"key":"pop.request.id","value":{"string_value":"56B9CCC3-CC84-0ED-53F60DC4A318"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"ae25eae77fbab21687bd7e41c","span_id":"f2ebc6f12b27","parent_span_id":"e0a710fbd3c6","name":"synthesize","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910213465461860","end_time_unix_nano":"1718910215131655555","attributes":[{"key":"input.value","value":{"string_value":"Question 1: what is pai-llm-trace."}},{"key":"openinference.span.kind","value":{"string_value":"CHAIN"}},{"key":"output.value","value":{"string_value":"The term \\"pai-llm-trace\\" refers to a component or module within the project or codebase being worked on."}},{"key":"pop.request.id","value":{"string_value":"67D34C0D-1CD5-11B7-BEE2-05649"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"21687bd7e41c","span_id":"d8f3fc7c","parent_span_id":"f2ebc12b27","name":"chunking","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910213467525240","end_time_unix_nano":"1718910213467894216","attributes":[{"key":"openinference.span.kind","value":{"string_value":"CHAIN"}},{"key":"pop.request.id","value":{"string_value":"8E1625-B8D1-EA177F9FC69D"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"5eae77fbab7bd7e41c","span_id":"0ab8a7c75","parent_span_id":"f2ebcf12b27","name":"chunking","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910213733013448","end_time_unix_nano":"1718910213733446902","attributes":[{"key":"openinference.span.kind","value":{"string_value":"CHAIN"}},{"key":"pop.request.id","value":{"string_value":"14D0D5-1675-BCA7-AF320E26C1A4"}}],"status":{"code":"STATUS_CODE_OK"}},{"trace_id":"25eae77fbab87bd7e41c","span_id":"2cb6c51c5fb2","parent_span_id":"f2ebcf12b27","name":"llm","kind":"SPAN_KIND_INTERNAL","start_time_unix_nano":"1718910214008467118","end_time_unix_nano":"1718910214849631714","attributes":[{"key":"llm.completions","value":{"array_value":{"values":[{"kvlist_value":{"values":[{"key":"message.content","value":{"string_value":"The term \\"pai-llm-trace\\" refersto a component or module within the project or codebase being worked on."}},{"key":"message.role","value":{"string_value":"assistant"}},{"key":"vector_index","value":{"int_value":"0"}}]}}]}}},{"key":"llm.invocation_parameters","value":{"string_value":"{\\"temperature\\": 0.1, \\"model\\": \\"gpt-3.5-turbo\\"}"}},{"key":"llm.model_name","value":{"string_value":"gpt-3.5-turbo"}},{"key":"llm.prompt_template.template","value":{"string_value":"system: You are an expert Q&A system that is trusted around the world.\\nAlways answer the query using the provided context information, and not prior knowledge.\\nSome rules to follow:\\n1. Never directly reference thegiven context in your answer.\\n2. Avoid statements like \'Based on the context, ...\' or \'The context information ...\' or anything along those lines.\\nuser: Context information is below.\\n---------------------\\n{context_str}\\n---------------------\\nGiven the context information and not prior knowledge, answer the query.\\nQuery: {query_str}\\nAnswer: \\nassistant: "}},{"key":"llm.prompt_template.variables","value":{"string_value":"{\\"context_str\\": \\"file_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\n\\\\n.PHONY: clean package test\\\\n\\\\nclean:\\\\n\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\n\\\\npackage: clean\\\\n\\\\tpip install build && python -m build\\\\n\\\\nrun:\\\\n\\\\tbash tools/run_test.sh\\", \\"query_str\\": \\"Question 1: what is pai-llm-trace.\\"}"}},{"key":"llm.prompts","value":{"array_value":{"values":[{"kvlist_value":{"values":[{"key":"message.content","value":{"string_value":"You are an expert Q&A system that is trusted around the world.\\nAlways answer the query using the provided context information, and not prior knowledge.\\nSome rules to follow:\\n1. Never directly reference the given context in your answer.\\n2. Avoid statements like \'Based on the context, ...\' or \'The context information ...\' or anything along those lines."}},{"key":"message.role","value":{"string_value":"system"}},{"key":"vector_index","value":{"int_value":"0"}}]}},{"kvlist_value":{"values":[{"key":"message.content","value":{"string_value":"Context information is below.\\n---------------------\\nfile_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\n\\n.PHONY: clean package test\\n\\nclean:\\n\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\n\\npackage: clean\\n\\tpip install build && python -m build\\n\\nrun:\\n\\tbash tools/run_test.sh\\n---------------------\\nGiven the context information and not prior knowledge, answer the query.\\nQuery: Question 1:what is pai-llm-trace.\\nAnswer: "}},{"key":"message.role","value":{"string_value":"user"}},{"key":"vector_index","value":{"int_value":"1"}}]}}]}}},{"key":"llm.token_count.completion","value":{"string_value":"26"}},{"key":"llm.token_count.prompt","value":{"string_value":"210"}},{"key":"llm.token_count.total","value":{"string_value":"236"}},{"key":"openinference.span.kind","value":{"string_value":"LLM"}},{"key":"output.value","value":{"string_value":"The term \\"pai-llm-trace\\" refers to a component or module within the project or codebase being worked on."}},{"key":"pop.request.id","value":{"string_value":"AA68F16D-A8B7-1BB0-1BD1E47B5"}}],"status":{"code":"STATUS_CODE_OK"}}]}]}]}'."\n" + ."\n" + .'open telemetry incompatible:'."\n" + .'[{"aliyunUid": "1773939154", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "177393915", "sub_id": "2305894433"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "444bae77fbab7bd7e41c", "spanId": "e0a0fbd3c6", "parentSpanId": "0", "kind": "SPAN_KIND_INTERNAL", "spanName": "query", "links": [], "events": [], "traceState": "", "startTime": 1718910212440262841, "endTime": 1718910215403326721, "duration": 2963063880, "attributes": {"input": {"value": "Question 1: what is pai-llm-trace."}, "openinference": {"span": {"kind": "CHAIN"}},"output": {"value": "The term \\\\"pai-llm-trace\\\\" refers to a component or module within the project or codebase being worked on."}, "pop": {"request": {"id": "1C70E14E-06F7D4F3"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "773939154", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "1773939", "sub_id": "2305819539"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "baeeae77fbab21687bd7e41c", "spanId": "ff08a7a6b85b", "parentSpanId": "e0a0fbd3c6", "kind": "SPAN_KIND_INTERNAL", "spanName": "retrieve", "links": [], "events": [], "traceState": "","startTime": 1718910212440884059, "endTime": 1718910213181800657, "duration": 740916598, "attributes": {"input": {"value": "Question 1: what is pai-llm-trace."}, "openinference": {"span": {"kind": "RETRIEVER"}}, "pop": {"request": {"id": "E8A1F8D9-D35A-1F9F2E6F612"}}, "retrieval": {"documents": [{"document": {"content": ".PHONY: clean package test\\\\n\\\\nclean:\\\\n\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\n\\\\npackage: clean\\\\n\\\\tpip install build && python -m build\\\\n\\\\nrun:\\\\n\\\\tbash tools/run_test.sh", "id": "c3bd0f7e-7--2fcc8657db", "metadata": "{\\\\"file_path\\\\": \\\\"/mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\", \\\\"file_name\\\\": \\\\"makefile\\\\", \\\\"file_size\\\\": 213, \\\\"creation_date\\\\": \\\\"2024-05-10\\\\", \\\\"last_modified_date\\\\": \\\\"2024-05-10\\\\"}", "score": 0.592955599044689}}]}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939154062345", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "1793915", "sub_id": "58944336"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "444baebd7e41c", "spanId": "fc6f6acbc7", "parentSpanId": "f08a7a6b85b", "kind": "SPAN_KIND_INTERNAL", "spanName": "embedding", "links": [],"events": [], "traceState": "", "startTime": 1718910212441468561, "endTime": 1718910212617063167, "duration": 175594606, "attributes": {"embedding": {"embeddings": [{"embedding": {"text": "Question 1: what is pai-llm-trace.", "vector": "PAI LLM Trace system hid 1536 actual items"}}], "model_name": "text-embedding-ada-002"}, "openinference": {"span": {"kind": "EMBEDDING"}}, "pop": {"request": {"id": "56B9CCC3-CC84-80ED-53F60DC4A"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "17739391540", "sub_id": "23058944336"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "eae77fbab21687bd7e41c", "spanId": "f2ebcf12b27", "parentSpanId": "e0afbd3c6", "kind": "SPAN_KIND_INTERNAL", "spanName": "synthesize", "links": [], "events": [], "traceState": "", "startTime": 1718910213465461860, "endTime": 1718910215131655555, "duration": 1666193695, "attributes": {"input": {"value": "Question 1: what is pai-llm-trace."}, "openinference": {"span": {"kind": "CHAIN"}}, "output": {"value": "The term \\\\"pai-llm-trace\\\\" refers to a component or module within the project or codebase being worked on."}, "pop": {"request": {"id": "67D34C0D-1CD5-11B7-BEE2-0F90DCC"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "177393915", "sub_id": "23058944336"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "ae0ae77fbab87bd7e41c", "spanId": "d8f3fc6d47c", "parentSpanId": "f2ebcf12b27", "kind": "SPAN_KIND_INTERNAL", "spanName": "chunking", "links": [], "events": [], "traceState": "", "startTime": 1718910213467525240, "endTime": 1718910213467894216, "duration": 368976, "attributes": {"openinference": {"span": {"kind": "CHAIN"}}, "pop": {"request": {"id": "8EA31C-5-B8D1-EA177F9FC69D"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name":"llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "17739391", "sub_id": "23058944"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name":"opentelemetry", "version": "1.25.0"}}}, "traceId": "444babd7e41c", "spanId": "0aba7c75", "parentSpanId": "f2ebc6f12b27", "kind": "SPAN_KIND_INTERNAL", "spanName": "chunking", "links": [], "events": [], "traceState": "", "startTime": 1718910213733013448, "endTime": 1718910213733446902, "duration": 433454, "attributes": {"openinference": {"span": {"kind": "CHAIN"}}, "pop": {"request": {"id": "14D0D75-BCA7-AFE26C1A4"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}, {"aliyunUid": "1773939", "hostname": "qlc-ark2", "resources": {"deployment": {"environment": "cn-hangzhou"}, "service": {"app": {"name": "llm_trace_llamaindex_test"}, "name": "llm_trace_llamaindex_test_template", "owner": {"id": "177393915", "sub_id": "2305894433"}, "version": "0.0.1"}, "telemetry": {"sdk": {"language": "python", "name": "opentelemetry", "version": "1.25.0"}}}, "traceId": "ae025eae77fbab7bd7e41c", "spanId": "2cb6c51c5fb2", "parentSpanId": "f2ebc6f12b27", "kind": "SPAN_KIND_INTERNAL", "spanName": "llm","links": [], "events": [], "traceState": "", "startTime": 1718910214008467118, "endTime": 1718910214849631714, "duration": 841164596, "attributes": {"llm": {"completions": [{"message": {"content": "The term \\\\"pai-llm-trace\\\\" refers to a component or module within the project or codebase being worked on.", "role": "assistant"}}], "invocation_parameters": "{\\\\"temperature\\\\": 0.1, \\\\"model\\\\": \\\\"gpt-3.5-turbo\\\\"}", "model_name": "gpt-3.5-turbo", "prompt_template": {"template": "system: You are an expert Q&A system that is trusted around the world.\\\\nAlways answer the query using the provided context information, and not prior knowledge.\\\\nSome rules to follow:\\\\n1. Never directly reference the given context in your answer.\\\\n2. Avoid statements like \\\'Based on the context, ...\\\' or \\\'The context information ...\\\' or anything along those lines.\\\\nuser: Contextinformation is below.\\\\n---------------------\\\\n{context_str}\\\\n---------------------\\\\nGiven the context information and not prior knowledge, answer the query.\\\\nQuery: {query_str}\\\\nAnswer: \\\\nassistant: ", "variables": "{\\\\"context_str\\\\": \\\\"file_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\\\\\n\\\\\\\\n.PHONY: clean package test\\\\\\\\n\\\\\\\\nclean:\\\\\\\\n\\\\\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__src/pai/llm_trace/__pycache__\\\\\\\\n\\\\\\\\npackage: clean\\\\\\\\n\\\\\\\\tpip install build && python -m build\\\\\\\\n\\\\\\\\nrun:\\\\\\\\n\\\\\\\\tbash tools/run_test.sh\\\\", \\\\"query_str\\\\": \\\\"Question 1: what is pai-llm-trace.\\\\"}"}, "prompts": [{"message": {"content": "You are an expert Q&A system that is trusted around the world.\\\\nAlways answer the query using the provided context information, and not prior knowledge.\\\\nSome rules to follow:\\\\n1. Never directly reference the given context in your answer.\\\\n2. Avoid statements like \\\'Based on the context, ...\\\' or \\\'The context information ...\\\' or anything along those lines.", "role": "system"}}, {"message": {"content": "Context information is below.\\\\n---------------------\\\\nfile_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\n\\\\n.PHONY: clean package test\\\\n\\\\nclean:\\\\n\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\n\\\\npackage: clean\\\\n\\\\tpip install build && python -m build\\\\n\\\\nrun:\\\\n\\\\tbash tools/run_test.sh\\\\n---------------------\\\\nGiven the context information and notprior knowledge, answer the query.\\\\nQuery: Question 1: what is pai-llm-trace.\\\\nAnswer: ", "role": "user"}}], "token_count": {"completion": "26", "prompt": "210", "total": "236"}}, "openinference": {"span": {"kind": "LLM"}}, "output": {"value": "The term \\\\"pai-llm-trace\\\\" refers to a component or module within the project or codebase being worked on."}, "pop": {"request": {"id": "AA68F16D-A8B7-1BB0-1BD1E47B5"}}}, "statusCode": "STATUS_CODE_OK", "statusMessage": ""}]'], ], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], + 'staticInfo' => ['returnType' => 'synchronous'], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"TotalCount\\": 22,\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"ExecutionFailure\\",\\n \\"Message\\": \\"failed to get trace data\\",\\n \\"Traces\\": [\\n \\"open telemetry compatible:\\\\n{\\\\\\"resource_spans\\\\\\":[{\\\\\\"resource\\\\\\":{\\\\\\"attributes\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"telemetry.sdk.language\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"python\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"telemetry.sdk.name\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"opentelemetry\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"telemetry.sdk.version\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"1.25.0\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"service.name\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"llm_trace_llamaindex_test_template\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"service.version\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"0.0.1\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"deployment.environment\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"cn-hangzhou\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"service.app.name\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"llm_trace_llamaindex_test\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"service.owner.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"177393915\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"service.owner.sub_id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"230589443368\\\\\\"}}]},\\\\\\"scope_spans\\\\\\":[{\\\\\\"spans\\\\\\":[{\\\\\\"trace_id\\\\\\":\\\\\\"ae40025eae77fbab21687bd7e41c\\\\\\",\\\\\\"span_id\\\\\\":\\\\\\"e09710fbd3c6\\\\\\",\\\\\\"parent_span_id\\\\\\":\\\\\\"0\\\\\\",\\\\\\"name\\\\\\":\\\\\\"query\\\\\\",\\\\\\"kind\\\\\\":\\\\\\"SPAN_KIND_INTERNAL\\\\\\",\\\\\\"start_time_unix_nano\\\\\\":\\\\\\"1718910212440262841\\\\\\",\\\\\\"end_time_unix_nano\\\\\\":\\\\\\"1718910215403326721\\\\\\",\\\\\\"attributes\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"input.value\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"Question 1: what is pai-llm-trace.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"openinference.span.kind\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"CHAIN\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"output.value\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"The term \\\\\\\\\\\\\\"pai-llm-trace\\\\\\\\\\\\\\" refers to a component or module within the project or codebase being worked on.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"pop.request.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"1C714E-057D-1216-835A-06F722E4F3\\\\\\"}}],\\\\\\"status\\\\\\":{\\\\\\"code\\\\\\":\\\\\\"STATUS_CODE_OK\\\\\\"}},{\\\\\\"trace_id\\\\\\":\\\\\\"444bae400277fbab21687bd7e41c\\\\\\",\\\\\\"span_id\\\\\\":\\\\\\"5686fa7a6b85b\\\\\\",\\\\\\"parent_span_id\\\\\\":\\\\\\"e0a5920fbd3c6\\\\\\",\\\\\\"name\\\\\\":\\\\\\"retrieve\\\\\\",\\\\\\"kind\\\\\\":\\\\\\"SPAN_KIND_INTERNAL\\\\\\",\\\\\\"start_time_unix_nano\\\\\\":\\\\\\"1718910212440884059\\\\\\",\\\\\\"end_time_unix_nano\\\\\\":\\\\\\"1718910213181800657\\\\\\",\\\\\\"attributes\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"input.value\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"Question 1: what is pai-llm-trace.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"openinference.span.kind\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"RETRIEVER\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"pop.request.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"E8A1F8D9-D35A-1F9F-B724-5DA12E6F612\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"retrieval.documents\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"array_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"kvlist_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"document.content\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\".PHONY: clean package test\\\\\\\\n\\\\\\\\nclean:\\\\\\\\n\\\\\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\\\\\n\\\\\\\\npackage: clean\\\\\\\\n\\\\\\\\tpip install build && python -m build\\\\\\\\n\\\\\\\\nrun:\\\\\\\\n\\\\\\\\tbash tools/run_test.sh\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"document.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"c3bd0f7e-2-42f7-964c-2fcc698657db\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"document.metadata\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"{\\\\\\\\\\\\\\"file_path\\\\\\\\\\\\\\": \\\\\\\\\\\\\\"/mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"file_name\\\\\\\\\\\\\\": \\\\\\\\\\\\\\"makefile\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"file_size\\\\\\\\\\\\\\": 213, \\\\\\\\\\\\\\"creation_date\\\\\\\\\\\\\\": \\\\\\\\\\\\\\"2024-05-10\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"last_modified_date\\\\\\\\\\\\\\": \\\\\\\\\\\\\\"2024-05-10\\\\\\\\\\\\\\"}\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"document.score\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"double_value\\\\\\":0.592955599044689}},{\\\\\\"key\\\\\\":\\\\\\"vector_index\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"int_value\\\\\\":\\\\\\"0\\\\\\"}}]}}]}}}],\\\\\\"status\\\\\\":{\\\\\\"code\\\\\\":\\\\\\"STATUS_CODE_OK\\\\\\"}},{\\\\\\"trace_id\\\\\\":\\\\\\"444bae4e77fbab21687bd7e41c\\\\\\",\\\\\\"span_id\\\\\\":\\\\\\"f2fc6f6acbc7\\\\\\",\\\\\\"parent_span_id\\\\\\":\\\\\\"f08a7a6b85b\\\\\\",\\\\\\"name\\\\\\":\\\\\\"embedding\\\\\\",\\\\\\"kind\\\\\\":\\\\\\"SPAN_KIND_INTERNAL\\\\\\",\\\\\\"start_time_unix_nano\\\\\\":\\\\\\"1718910212441468561\\\\\\",\\\\\\"end_time_unix_nano\\\\\\":\\\\\\"1718910212617063167\\\\\\",\\\\\\"attributes\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"embedding.embeddings\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"array_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"kvlist_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"embedding.text\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"Question 1: what is pai-llm-trace.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"embedding.vector\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"PAI LLM Trace system hid 1536 actual items\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"vector_index\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"int_value\\\\\\":\\\\\\"0\\\\\\"}}]}}]}}},{\\\\\\"key\\\\\\":\\\\\\"embedding.model_name\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"text-embedding-ada-002\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"openinference.span.kind\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"EMBEDDING\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"pop.request.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"56B9CCC3-CC84-0ED-53F60DC4A318\\\\\\"}}],\\\\\\"status\\\\\\":{\\\\\\"code\\\\\\":\\\\\\"STATUS_CODE_OK\\\\\\"}},{\\\\\\"trace_id\\\\\\":\\\\\\"ae25eae77fbab21687bd7e41c\\\\\\",\\\\\\"span_id\\\\\\":\\\\\\"f2ebc6f12b27\\\\\\",\\\\\\"parent_span_id\\\\\\":\\\\\\"e0a710fbd3c6\\\\\\",\\\\\\"name\\\\\\":\\\\\\"synthesize\\\\\\",\\\\\\"kind\\\\\\":\\\\\\"SPAN_KIND_INTERNAL\\\\\\",\\\\\\"start_time_unix_nano\\\\\\":\\\\\\"1718910213465461860\\\\\\",\\\\\\"end_time_unix_nano\\\\\\":\\\\\\"1718910215131655555\\\\\\",\\\\\\"attributes\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"input.value\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"Question 1: what is pai-llm-trace.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"openinference.span.kind\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"CHAIN\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"output.value\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"The term \\\\\\\\\\\\\\"pai-llm-trace\\\\\\\\\\\\\\" refers to a component or module within the project or codebase being worked on.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"pop.request.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"67D34C0D-1CD5-11B7-BEE2-05649\\\\\\"}}],\\\\\\"status\\\\\\":{\\\\\\"code\\\\\\":\\\\\\"STATUS_CODE_OK\\\\\\"}},{\\\\\\"trace_id\\\\\\":\\\\\\"21687bd7e41c\\\\\\",\\\\\\"span_id\\\\\\":\\\\\\"d8f3fc7c\\\\\\",\\\\\\"parent_span_id\\\\\\":\\\\\\"f2ebc12b27\\\\\\",\\\\\\"name\\\\\\":\\\\\\"chunking\\\\\\",\\\\\\"kind\\\\\\":\\\\\\"SPAN_KIND_INTERNAL\\\\\\",\\\\\\"start_time_unix_nano\\\\\\":\\\\\\"1718910213467525240\\\\\\",\\\\\\"end_time_unix_nano\\\\\\":\\\\\\"1718910213467894216\\\\\\",\\\\\\"attributes\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"openinference.span.kind\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"CHAIN\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"pop.request.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"8E1625-B8D1-EA177F9FC69D\\\\\\"}}],\\\\\\"status\\\\\\":{\\\\\\"code\\\\\\":\\\\\\"STATUS_CODE_OK\\\\\\"}},{\\\\\\"trace_id\\\\\\":\\\\\\"5eae77fbab7bd7e41c\\\\\\",\\\\\\"span_id\\\\\\":\\\\\\"0ab8a7c75\\\\\\",\\\\\\"parent_span_id\\\\\\":\\\\\\"f2ebcf12b27\\\\\\",\\\\\\"name\\\\\\":\\\\\\"chunking\\\\\\",\\\\\\"kind\\\\\\":\\\\\\"SPAN_KIND_INTERNAL\\\\\\",\\\\\\"start_time_unix_nano\\\\\\":\\\\\\"1718910213733013448\\\\\\",\\\\\\"end_time_unix_nano\\\\\\":\\\\\\"1718910213733446902\\\\\\",\\\\\\"attributes\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"openinference.span.kind\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"CHAIN\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"pop.request.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"14D0D5-1675-BCA7-AF320E26C1A4\\\\\\"}}],\\\\\\"status\\\\\\":{\\\\\\"code\\\\\\":\\\\\\"STATUS_CODE_OK\\\\\\"}},{\\\\\\"trace_id\\\\\\":\\\\\\"25eae77fbab87bd7e41c\\\\\\",\\\\\\"span_id\\\\\\":\\\\\\"2cb6c51c5fb2\\\\\\",\\\\\\"parent_span_id\\\\\\":\\\\\\"f2ebcf12b27\\\\\\",\\\\\\"name\\\\\\":\\\\\\"llm\\\\\\",\\\\\\"kind\\\\\\":\\\\\\"SPAN_KIND_INTERNAL\\\\\\",\\\\\\"start_time_unix_nano\\\\\\":\\\\\\"1718910214008467118\\\\\\",\\\\\\"end_time_unix_nano\\\\\\":\\\\\\"1718910214849631714\\\\\\",\\\\\\"attributes\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"llm.completions\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"array_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"kvlist_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"message.content\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"The term \\\\\\\\\\\\\\"pai-llm-trace\\\\\\\\\\\\\\" refersto a component or module within the project or codebase being worked on.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"message.role\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"assistant\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"vector_index\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"int_value\\\\\\":\\\\\\"0\\\\\\"}}]}}]}}},{\\\\\\"key\\\\\\":\\\\\\"llm.invocation_parameters\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"{\\\\\\\\\\\\\\"temperature\\\\\\\\\\\\\\": 0.1, \\\\\\\\\\\\\\"model\\\\\\\\\\\\\\": \\\\\\\\\\\\\\"gpt-3.5-turbo\\\\\\\\\\\\\\"}\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"llm.model_name\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"gpt-3.5-turbo\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"llm.prompt_template.template\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"system: You are an expert Q&A system that is trusted around the world.\\\\\\\\nAlways answer the query using the provided context information, and not prior knowledge.\\\\\\\\nSome rules to follow:\\\\\\\\n1. Never directly reference thegiven context in your answer.\\\\\\\\n2. Avoid statements like \'Based on the context, ...\' or \'The context information ...\' or anything along those lines.\\\\\\\\nuser: Context information is below.\\\\\\\\n---------------------\\\\\\\\n{context_str}\\\\\\\\n---------------------\\\\\\\\nGiven the context information and not prior knowledge, answer the query.\\\\\\\\nQuery: {query_str}\\\\\\\\nAnswer: \\\\\\\\nassistant: \\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"llm.prompt_template.variables\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"{\\\\\\\\\\\\\\"context_str\\\\\\\\\\\\\\": \\\\\\\\\\\\\\"file_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\n.PHONY: clean package test\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\nclean:\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\npackage: clean\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\tpip install build && python -m build\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\nrun:\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\tbash tools/run_test.sh\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"query_str\\\\\\\\\\\\\\": \\\\\\\\\\\\\\"Question 1: what is pai-llm-trace.\\\\\\\\\\\\\\"}\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"llm.prompts\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"array_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"kvlist_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"message.content\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"You are an expert Q&A system that is trusted around the world.\\\\\\\\nAlways answer the query using the provided context information, and not prior knowledge.\\\\\\\\nSome rules to follow:\\\\\\\\n1. Never directly reference the given context in your answer.\\\\\\\\n2. Avoid statements like \'Based on the context, ...\' or \'The context information ...\' or anything along those lines.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"message.role\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"system\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"vector_index\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"int_value\\\\\\":\\\\\\"0\\\\\\"}}]}},{\\\\\\"kvlist_value\\\\\\":{\\\\\\"values\\\\\\":[{\\\\\\"key\\\\\\":\\\\\\"message.content\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"Context information is below.\\\\\\\\n---------------------\\\\\\\\nfile_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\\\\\n\\\\\\\\n.PHONY: clean package test\\\\\\\\n\\\\\\\\nclean:\\\\\\\\n\\\\\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\\\\\n\\\\\\\\npackage: clean\\\\\\\\n\\\\\\\\tpip install build && python -m build\\\\\\\\n\\\\\\\\nrun:\\\\\\\\n\\\\\\\\tbash tools/run_test.sh\\\\\\\\n---------------------\\\\\\\\nGiven the context information and not prior knowledge, answer the query.\\\\\\\\nQuery: Question 1:what is pai-llm-trace.\\\\\\\\nAnswer: \\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"message.role\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"user\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"vector_index\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"int_value\\\\\\":\\\\\\"1\\\\\\"}}]}}]}}},{\\\\\\"key\\\\\\":\\\\\\"llm.token_count.completion\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"26\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"llm.token_count.prompt\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"210\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"llm.token_count.total\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"236\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"openinference.span.kind\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"LLM\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"output.value\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"The term \\\\\\\\\\\\\\"pai-llm-trace\\\\\\\\\\\\\\" refers to a component or module within the project or codebase being worked on.\\\\\\"}},{\\\\\\"key\\\\\\":\\\\\\"pop.request.id\\\\\\",\\\\\\"value\\\\\\":{\\\\\\"string_value\\\\\\":\\\\\\"AA68F16D-A8B7-1BB0-1BD1E47B5\\\\\\"}}],\\\\\\"status\\\\\\":{\\\\\\"code\\\\\\":\\\\\\"STATUS_CODE_OK\\\\\\"}}]}]}]}\\\\n\\\\nopen telemetry incompatible:\\\\n[{\\\\\\"aliyunUid\\\\\\": \\\\\\"1773939154\\\\\\", \\\\\\"hostname\\\\\\": \\\\\\"qlc-ark2\\\\\\", \\\\\\"resources\\\\\\": {\\\\\\"deployment\\\\\\": {\\\\\\"environment\\\\\\": \\\\\\"cn-hangzhou\\\\\\"}, \\\\\\"service\\\\\\": {\\\\\\"app\\\\\\": {\\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test\\\\\\"}, \\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test_template\\\\\\", \\\\\\"owner\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"177393915\\\\\\", \\\\\\"sub_id\\\\\\": \\\\\\"2305894433\\\\\\"}, \\\\\\"version\\\\\\": \\\\\\"0.0.1\\\\\\"}, \\\\\\"telemetry\\\\\\": {\\\\\\"sdk\\\\\\": {\\\\\\"language\\\\\\": \\\\\\"python\\\\\\", \\\\\\"name\\\\\\": \\\\\\"opentelemetry\\\\\\", \\\\\\"version\\\\\\": \\\\\\"1.25.0\\\\\\"}}}, \\\\\\"traceId\\\\\\": \\\\\\"444bae77fbab7bd7e41c\\\\\\", \\\\\\"spanId\\\\\\": \\\\\\"e0a0fbd3c6\\\\\\", \\\\\\"parentSpanId\\\\\\": \\\\\\"0\\\\\\", \\\\\\"kind\\\\\\": \\\\\\"SPAN_KIND_INTERNAL\\\\\\", \\\\\\"spanName\\\\\\": \\\\\\"query\\\\\\", \\\\\\"links\\\\\\": [], \\\\\\"events\\\\\\": [], \\\\\\"traceState\\\\\\": \\\\\\"\\\\\\", \\\\\\"startTime\\\\\\": 1718910212440262841, \\\\\\"endTime\\\\\\": 1718910215403326721, \\\\\\"duration\\\\\\": 2963063880, \\\\\\"attributes\\\\\\": {\\\\\\"input\\\\\\": {\\\\\\"value\\\\\\": \\\\\\"Question 1: what is pai-llm-trace.\\\\\\"}, \\\\\\"openinference\\\\\\": {\\\\\\"span\\\\\\": {\\\\\\"kind\\\\\\": \\\\\\"CHAIN\\\\\\"}},\\\\\\"output\\\\\\": {\\\\\\"value\\\\\\": \\\\\\"The term \\\\\\\\\\\\\\\\\\\\\\"pai-llm-trace\\\\\\\\\\\\\\\\\\\\\\" refers to a component or module within the project or codebase being worked on.\\\\\\"}, \\\\\\"pop\\\\\\": {\\\\\\"request\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"1C70E14E-06F7D4F3\\\\\\"}}}, \\\\\\"statusCode\\\\\\": \\\\\\"STATUS_CODE_OK\\\\\\", \\\\\\"statusMessage\\\\\\": \\\\\\"\\\\\\"}, {\\\\\\"aliyunUid\\\\\\": \\\\\\"773939154\\\\\\", \\\\\\"hostname\\\\\\": \\\\\\"qlc-ark2\\\\\\", \\\\\\"resources\\\\\\": {\\\\\\"deployment\\\\\\": {\\\\\\"environment\\\\\\": \\\\\\"cn-hangzhou\\\\\\"}, \\\\\\"service\\\\\\": {\\\\\\"app\\\\\\": {\\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test\\\\\\"}, \\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test_template\\\\\\", \\\\\\"owner\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"1773939\\\\\\", \\\\\\"sub_id\\\\\\": \\\\\\"2305819539\\\\\\"}, \\\\\\"version\\\\\\": \\\\\\"0.0.1\\\\\\"}, \\\\\\"telemetry\\\\\\": {\\\\\\"sdk\\\\\\": {\\\\\\"language\\\\\\": \\\\\\"python\\\\\\", \\\\\\"name\\\\\\": \\\\\\"opentelemetry\\\\\\", \\\\\\"version\\\\\\": \\\\\\"1.25.0\\\\\\"}}}, \\\\\\"traceId\\\\\\": \\\\\\"baeeae77fbab21687bd7e41c\\\\\\", \\\\\\"spanId\\\\\\": \\\\\\"ff08a7a6b85b\\\\\\", \\\\\\"parentSpanId\\\\\\": \\\\\\"e0a0fbd3c6\\\\\\", \\\\\\"kind\\\\\\": \\\\\\"SPAN_KIND_INTERNAL\\\\\\", \\\\\\"spanName\\\\\\": \\\\\\"retrieve\\\\\\", \\\\\\"links\\\\\\": [], \\\\\\"events\\\\\\": [], \\\\\\"traceState\\\\\\": \\\\\\"\\\\\\",\\\\\\"startTime\\\\\\": 1718910212440884059, \\\\\\"endTime\\\\\\": 1718910213181800657, \\\\\\"duration\\\\\\": 740916598, \\\\\\"attributes\\\\\\": {\\\\\\"input\\\\\\": {\\\\\\"value\\\\\\": \\\\\\"Question 1: what is pai-llm-trace.\\\\\\"}, \\\\\\"openinference\\\\\\": {\\\\\\"span\\\\\\": {\\\\\\"kind\\\\\\": \\\\\\"RETRIEVER\\\\\\"}}, \\\\\\"pop\\\\\\": {\\\\\\"request\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"E8A1F8D9-D35A-1F9F2E6F612\\\\\\"}}, \\\\\\"retrieval\\\\\\": {\\\\\\"documents\\\\\\": [{\\\\\\"document\\\\\\": {\\\\\\"content\\\\\\": \\\\\\".PHONY: clean package test\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\nclean:\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\npackage: clean\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\tpip install build && python -m build\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\nrun:\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\tbash tools/run_test.sh\\\\\\", \\\\\\"id\\\\\\": \\\\\\"c3bd0f7e-7--2fcc8657db\\\\\\", \\\\\\"metadata\\\\\\": \\\\\\"{\\\\\\\\\\\\\\\\\\\\\\"file_path\\\\\\\\\\\\\\\\\\\\\\": \\\\\\\\\\\\\\\\\\\\\\"/mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\\\\\\\\\\\\\\\\\\\", \\\\\\\\\\\\\\\\\\\\\\"file_name\\\\\\\\\\\\\\\\\\\\\\": \\\\\\\\\\\\\\\\\\\\\\"makefile\\\\\\\\\\\\\\\\\\\\\\", \\\\\\\\\\\\\\\\\\\\\\"file_size\\\\\\\\\\\\\\\\\\\\\\": 213, \\\\\\\\\\\\\\\\\\\\\\"creation_date\\\\\\\\\\\\\\\\\\\\\\": \\\\\\\\\\\\\\\\\\\\\\"2024-05-10\\\\\\\\\\\\\\\\\\\\\\", \\\\\\\\\\\\\\\\\\\\\\"last_modified_date\\\\\\\\\\\\\\\\\\\\\\": \\\\\\\\\\\\\\\\\\\\\\"2024-05-10\\\\\\\\\\\\\\\\\\\\\\"}\\\\\\", \\\\\\"score\\\\\\": 0.592955599044689}}]}}, \\\\\\"statusCode\\\\\\": \\\\\\"STATUS_CODE_OK\\\\\\", \\\\\\"statusMessage\\\\\\": \\\\\\"\\\\\\"}, {\\\\\\"aliyunUid\\\\\\": \\\\\\"1773939154062345\\\\\\", \\\\\\"hostname\\\\\\": \\\\\\"qlc-ark2\\\\\\", \\\\\\"resources\\\\\\": {\\\\\\"deployment\\\\\\": {\\\\\\"environment\\\\\\": \\\\\\"cn-hangzhou\\\\\\"}, \\\\\\"service\\\\\\": {\\\\\\"app\\\\\\": {\\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test\\\\\\"}, \\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test_template\\\\\\", \\\\\\"owner\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"1793915\\\\\\", \\\\\\"sub_id\\\\\\": \\\\\\"58944336\\\\\\"}, \\\\\\"version\\\\\\": \\\\\\"0.0.1\\\\\\"}, \\\\\\"telemetry\\\\\\": {\\\\\\"sdk\\\\\\": {\\\\\\"language\\\\\\": \\\\\\"python\\\\\\", \\\\\\"name\\\\\\": \\\\\\"opentelemetry\\\\\\", \\\\\\"version\\\\\\": \\\\\\"1.25.0\\\\\\"}}}, \\\\\\"traceId\\\\\\": \\\\\\"444baebd7e41c\\\\\\", \\\\\\"spanId\\\\\\": \\\\\\"fc6f6acbc7\\\\\\", \\\\\\"parentSpanId\\\\\\": \\\\\\"f08a7a6b85b\\\\\\", \\\\\\"kind\\\\\\": \\\\\\"SPAN_KIND_INTERNAL\\\\\\", \\\\\\"spanName\\\\\\": \\\\\\"embedding\\\\\\", \\\\\\"links\\\\\\": [],\\\\\\"events\\\\\\": [], \\\\\\"traceState\\\\\\": \\\\\\"\\\\\\", \\\\\\"startTime\\\\\\": 1718910212441468561, \\\\\\"endTime\\\\\\": 1718910212617063167, \\\\\\"duration\\\\\\": 175594606, \\\\\\"attributes\\\\\\": {\\\\\\"embedding\\\\\\": {\\\\\\"embeddings\\\\\\": [{\\\\\\"embedding\\\\\\": {\\\\\\"text\\\\\\": \\\\\\"Question 1: what is pai-llm-trace.\\\\\\", \\\\\\"vector\\\\\\": \\\\\\"PAI LLM Trace system hid 1536 actual items\\\\\\"}}], \\\\\\"model_name\\\\\\": \\\\\\"text-embedding-ada-002\\\\\\"}, \\\\\\"openinference\\\\\\": {\\\\\\"span\\\\\\": {\\\\\\"kind\\\\\\": \\\\\\"EMBEDDING\\\\\\"}}, \\\\\\"pop\\\\\\": {\\\\\\"request\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"56B9CCC3-CC84-80ED-53F60DC4A\\\\\\"}}}, \\\\\\"statusCode\\\\\\": \\\\\\"STATUS_CODE_OK\\\\\\", \\\\\\"statusMessage\\\\\\": \\\\\\"\\\\\\"}, {\\\\\\"aliyunUid\\\\\\": \\\\\\"1773939\\\\\\", \\\\\\"hostname\\\\\\": \\\\\\"qlc-ark2\\\\\\", \\\\\\"resources\\\\\\": {\\\\\\"deployment\\\\\\": {\\\\\\"environment\\\\\\": \\\\\\"cn-hangzhou\\\\\\"}, \\\\\\"service\\\\\\": {\\\\\\"app\\\\\\": {\\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test\\\\\\"}, \\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test_template\\\\\\", \\\\\\"owner\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"17739391540\\\\\\", \\\\\\"sub_id\\\\\\": \\\\\\"23058944336\\\\\\"}, \\\\\\"version\\\\\\": \\\\\\"0.0.1\\\\\\"}, \\\\\\"telemetry\\\\\\": {\\\\\\"sdk\\\\\\": {\\\\\\"language\\\\\\": \\\\\\"python\\\\\\", \\\\\\"name\\\\\\": \\\\\\"opentelemetry\\\\\\", \\\\\\"version\\\\\\": \\\\\\"1.25.0\\\\\\"}}}, \\\\\\"traceId\\\\\\": \\\\\\"eae77fbab21687bd7e41c\\\\\\", \\\\\\"spanId\\\\\\": \\\\\\"f2ebcf12b27\\\\\\", \\\\\\"parentSpanId\\\\\\": \\\\\\"e0afbd3c6\\\\\\", \\\\\\"kind\\\\\\": \\\\\\"SPAN_KIND_INTERNAL\\\\\\", \\\\\\"spanName\\\\\\": \\\\\\"synthesize\\\\\\", \\\\\\"links\\\\\\": [], \\\\\\"events\\\\\\": [], \\\\\\"traceState\\\\\\": \\\\\\"\\\\\\", \\\\\\"startTime\\\\\\": 1718910213465461860, \\\\\\"endTime\\\\\\": 1718910215131655555, \\\\\\"duration\\\\\\": 1666193695, \\\\\\"attributes\\\\\\": {\\\\\\"input\\\\\\": {\\\\\\"value\\\\\\": \\\\\\"Question 1: what is pai-llm-trace.\\\\\\"}, \\\\\\"openinference\\\\\\": {\\\\\\"span\\\\\\": {\\\\\\"kind\\\\\\": \\\\\\"CHAIN\\\\\\"}}, \\\\\\"output\\\\\\": {\\\\\\"value\\\\\\": \\\\\\"The term \\\\\\\\\\\\\\\\\\\\\\"pai-llm-trace\\\\\\\\\\\\\\\\\\\\\\" refers to a component or module within the project or codebase being worked on.\\\\\\"}, \\\\\\"pop\\\\\\": {\\\\\\"request\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"67D34C0D-1CD5-11B7-BEE2-0F90DCC\\\\\\"}}}, \\\\\\"statusCode\\\\\\": \\\\\\"STATUS_CODE_OK\\\\\\", \\\\\\"statusMessage\\\\\\": \\\\\\"\\\\\\"}, {\\\\\\"aliyunUid\\\\\\": \\\\\\"1773939\\\\\\", \\\\\\"hostname\\\\\\": \\\\\\"qlc-ark2\\\\\\", \\\\\\"resources\\\\\\": {\\\\\\"deployment\\\\\\": {\\\\\\"environment\\\\\\": \\\\\\"cn-hangzhou\\\\\\"}, \\\\\\"service\\\\\\": {\\\\\\"app\\\\\\": {\\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test\\\\\\"}, \\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test_template\\\\\\", \\\\\\"owner\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"177393915\\\\\\", \\\\\\"sub_id\\\\\\": \\\\\\"23058944336\\\\\\"}, \\\\\\"version\\\\\\": \\\\\\"0.0.1\\\\\\"}, \\\\\\"telemetry\\\\\\": {\\\\\\"sdk\\\\\\": {\\\\\\"language\\\\\\": \\\\\\"python\\\\\\", \\\\\\"name\\\\\\": \\\\\\"opentelemetry\\\\\\", \\\\\\"version\\\\\\": \\\\\\"1.25.0\\\\\\"}}}, \\\\\\"traceId\\\\\\": \\\\\\"ae0ae77fbab87bd7e41c\\\\\\", \\\\\\"spanId\\\\\\": \\\\\\"d8f3fc6d47c\\\\\\", \\\\\\"parentSpanId\\\\\\": \\\\\\"f2ebcf12b27\\\\\\", \\\\\\"kind\\\\\\": \\\\\\"SPAN_KIND_INTERNAL\\\\\\", \\\\\\"spanName\\\\\\": \\\\\\"chunking\\\\\\", \\\\\\"links\\\\\\": [], \\\\\\"events\\\\\\": [], \\\\\\"traceState\\\\\\": \\\\\\"\\\\\\", \\\\\\"startTime\\\\\\": 1718910213467525240, \\\\\\"endTime\\\\\\": 1718910213467894216, \\\\\\"duration\\\\\\": 368976, \\\\\\"attributes\\\\\\": {\\\\\\"openinference\\\\\\": {\\\\\\"span\\\\\\": {\\\\\\"kind\\\\\\": \\\\\\"CHAIN\\\\\\"}}, \\\\\\"pop\\\\\\": {\\\\\\"request\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"8EA31C-5-B8D1-EA177F9FC69D\\\\\\"}}}, \\\\\\"statusCode\\\\\\": \\\\\\"STATUS_CODE_OK\\\\\\", \\\\\\"statusMessage\\\\\\": \\\\\\"\\\\\\"}, {\\\\\\"aliyunUid\\\\\\": \\\\\\"1773939\\\\\\", \\\\\\"hostname\\\\\\": \\\\\\"qlc-ark2\\\\\\", \\\\\\"resources\\\\\\": {\\\\\\"deployment\\\\\\": {\\\\\\"environment\\\\\\": \\\\\\"cn-hangzhou\\\\\\"}, \\\\\\"service\\\\\\": {\\\\\\"app\\\\\\": {\\\\\\"name\\\\\\":\\\\\\"llm_trace_llamaindex_test\\\\\\"}, \\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test_template\\\\\\", \\\\\\"owner\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"17739391\\\\\\", \\\\\\"sub_id\\\\\\": \\\\\\"23058944\\\\\\"}, \\\\\\"version\\\\\\": \\\\\\"0.0.1\\\\\\"}, \\\\\\"telemetry\\\\\\": {\\\\\\"sdk\\\\\\": {\\\\\\"language\\\\\\": \\\\\\"python\\\\\\", \\\\\\"name\\\\\\":\\\\\\"opentelemetry\\\\\\", \\\\\\"version\\\\\\": \\\\\\"1.25.0\\\\\\"}}}, \\\\\\"traceId\\\\\\": \\\\\\"444babd7e41c\\\\\\", \\\\\\"spanId\\\\\\": \\\\\\"0aba7c75\\\\\\", \\\\\\"parentSpanId\\\\\\": \\\\\\"f2ebc6f12b27\\\\\\", \\\\\\"kind\\\\\\": \\\\\\"SPAN_KIND_INTERNAL\\\\\\", \\\\\\"spanName\\\\\\": \\\\\\"chunking\\\\\\", \\\\\\"links\\\\\\": [], \\\\\\"events\\\\\\": [], \\\\\\"traceState\\\\\\": \\\\\\"\\\\\\", \\\\\\"startTime\\\\\\": 1718910213733013448, \\\\\\"endTime\\\\\\": 1718910213733446902, \\\\\\"duration\\\\\\": 433454, \\\\\\"attributes\\\\\\": {\\\\\\"openinference\\\\\\": {\\\\\\"span\\\\\\": {\\\\\\"kind\\\\\\": \\\\\\"CHAIN\\\\\\"}}, \\\\\\"pop\\\\\\": {\\\\\\"request\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"14D0D75-BCA7-AFE26C1A4\\\\\\"}}}, \\\\\\"statusCode\\\\\\": \\\\\\"STATUS_CODE_OK\\\\\\", \\\\\\"statusMessage\\\\\\": \\\\\\"\\\\\\"}, {\\\\\\"aliyunUid\\\\\\": \\\\\\"1773939\\\\\\", \\\\\\"hostname\\\\\\": \\\\\\"qlc-ark2\\\\\\", \\\\\\"resources\\\\\\": {\\\\\\"deployment\\\\\\": {\\\\\\"environment\\\\\\": \\\\\\"cn-hangzhou\\\\\\"}, \\\\\\"service\\\\\\": {\\\\\\"app\\\\\\": {\\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test\\\\\\"}, \\\\\\"name\\\\\\": \\\\\\"llm_trace_llamaindex_test_template\\\\\\", \\\\\\"owner\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"177393915\\\\\\", \\\\\\"sub_id\\\\\\": \\\\\\"2305894433\\\\\\"}, \\\\\\"version\\\\\\": \\\\\\"0.0.1\\\\\\"}, \\\\\\"telemetry\\\\\\": {\\\\\\"sdk\\\\\\": {\\\\\\"language\\\\\\": \\\\\\"python\\\\\\", \\\\\\"name\\\\\\": \\\\\\"opentelemetry\\\\\\", \\\\\\"version\\\\\\": \\\\\\"1.25.0\\\\\\"}}}, \\\\\\"traceId\\\\\\": \\\\\\"ae025eae77fbab7bd7e41c\\\\\\", \\\\\\"spanId\\\\\\": \\\\\\"2cb6c51c5fb2\\\\\\", \\\\\\"parentSpanId\\\\\\": \\\\\\"f2ebc6f12b27\\\\\\", \\\\\\"kind\\\\\\": \\\\\\"SPAN_KIND_INTERNAL\\\\\\", \\\\\\"spanName\\\\\\": \\\\\\"llm\\\\\\",\\\\\\"links\\\\\\": [], \\\\\\"events\\\\\\": [], \\\\\\"traceState\\\\\\": \\\\\\"\\\\\\", \\\\\\"startTime\\\\\\": 1718910214008467118, \\\\\\"endTime\\\\\\": 1718910214849631714, \\\\\\"duration\\\\\\": 841164596, \\\\\\"attributes\\\\\\": {\\\\\\"llm\\\\\\": {\\\\\\"completions\\\\\\": [{\\\\\\"message\\\\\\": {\\\\\\"content\\\\\\": \\\\\\"The term \\\\\\\\\\\\\\\\\\\\\\"pai-llm-trace\\\\\\\\\\\\\\\\\\\\\\" refers to a component or module within the project or codebase being worked on.\\\\\\", \\\\\\"role\\\\\\": \\\\\\"assistant\\\\\\"}}], \\\\\\"invocation_parameters\\\\\\": \\\\\\"{\\\\\\\\\\\\\\\\\\\\\\"temperature\\\\\\\\\\\\\\\\\\\\\\": 0.1, \\\\\\\\\\\\\\\\\\\\\\"model\\\\\\\\\\\\\\\\\\\\\\": \\\\\\\\\\\\\\\\\\\\\\"gpt-3.5-turbo\\\\\\\\\\\\\\\\\\\\\\"}\\\\\\", \\\\\\"model_name\\\\\\": \\\\\\"gpt-3.5-turbo\\\\\\", \\\\\\"prompt_template\\\\\\": {\\\\\\"template\\\\\\": \\\\\\"system: You are an expert Q&A system that is trusted around the world.\\\\\\\\\\\\\\\\nAlways answer the query using the provided context information, and not prior knowledge.\\\\\\\\\\\\\\\\nSome rules to follow:\\\\\\\\\\\\\\\\n1. Never directly reference the given context in your answer.\\\\\\\\\\\\\\\\n2. Avoid statements like \\\\\\\\\'Based on the context, ...\\\\\\\\\' or \\\\\\\\\'The context information ...\\\\\\\\\' or anything along those lines.\\\\\\\\\\\\\\\\nuser: Contextinformation is below.\\\\\\\\\\\\\\\\n---------------------\\\\\\\\\\\\\\\\n{context_str}\\\\\\\\\\\\\\\\n---------------------\\\\\\\\\\\\\\\\nGiven the context information and not prior knowledge, answer the query.\\\\\\\\\\\\\\\\nQuery: {query_str}\\\\\\\\\\\\\\\\nAnswer: \\\\\\\\\\\\\\\\nassistant: \\\\\\", \\\\\\"variables\\\\\\": \\\\\\"{\\\\\\\\\\\\\\\\\\\\\\"context_str\\\\\\\\\\\\\\\\\\\\\\": \\\\\\\\\\\\\\\\\\\\\\"file_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\n.PHONY: clean package test\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\nclean:\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__src/pai/llm_trace/__pycache__\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\npackage: clean\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\tpip install build && python -m build\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\nrun:\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\tbash tools/run_test.sh\\\\\\\\\\\\\\\\\\\\\\", \\\\\\\\\\\\\\\\\\\\\\"query_str\\\\\\\\\\\\\\\\\\\\\\": \\\\\\\\\\\\\\\\\\\\\\"Question 1: what is pai-llm-trace.\\\\\\\\\\\\\\\\\\\\\\"}\\\\\\"}, \\\\\\"prompts\\\\\\": [{\\\\\\"message\\\\\\": {\\\\\\"content\\\\\\": \\\\\\"You are an expert Q&A system that is trusted around the world.\\\\\\\\\\\\\\\\nAlways answer the query using the provided context information, and not prior knowledge.\\\\\\\\\\\\\\\\nSome rules to follow:\\\\\\\\\\\\\\\\n1. Never directly reference the given context in your answer.\\\\\\\\\\\\\\\\n2. Avoid statements like \\\\\\\\\'Based on the context, ...\\\\\\\\\' or \\\\\\\\\'The context information ...\\\\\\\\\' or anything along those lines.\\\\\\", \\\\\\"role\\\\\\": \\\\\\"system\\\\\\"}}, {\\\\\\"message\\\\\\": {\\\\\\"content\\\\\\": \\\\\\"Context information is below.\\\\\\\\\\\\\\\\n---------------------\\\\\\\\\\\\\\\\nfile_path: /mnt/disk1t/weidan.kong/work/llm_trace/client/makefile\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\n.PHONY: clean package test\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\nclean:\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\trm -rf build dist src/*.egg-info src/pai/llm_trace/__pycache__ src/pai/llm_trace/__pycache__\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\npackage: clean\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\tpip install build && python -m build\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\nrun:\\\\\\\\\\\\\\\\n\\\\\\\\\\\\\\\\tbash tools/run_test.sh\\\\\\\\\\\\\\\\n---------------------\\\\\\\\\\\\\\\\nGiven the context information and notprior knowledge, answer the query.\\\\\\\\\\\\\\\\nQuery: Question 1: what is pai-llm-trace.\\\\\\\\\\\\\\\\nAnswer: \\\\\\", \\\\\\"role\\\\\\": \\\\\\"user\\\\\\"}}], \\\\\\"token_count\\\\\\": {\\\\\\"completion\\\\\\": \\\\\\"26\\\\\\", \\\\\\"prompt\\\\\\": \\\\\\"210\\\\\\", \\\\\\"total\\\\\\": \\\\\\"236\\\\\\"}}, \\\\\\"openinference\\\\\\": {\\\\\\"span\\\\\\": {\\\\\\"kind\\\\\\": \\\\\\"LLM\\\\\\"}}, \\\\\\"output\\\\\\": {\\\\\\"value\\\\\\": \\\\\\"The term \\\\\\\\\\\\\\\\\\\\\\"pai-llm-trace\\\\\\\\\\\\\\\\\\\\\\" refers to a component or module within the project or codebase being worked on.\\\\\\"}, \\\\\\"pop\\\\\\": {\\\\\\"request\\\\\\": {\\\\\\"id\\\\\\": \\\\\\"AA68F16D-A8B7-1BB0-1BD1E47B5\\\\\\"}}}, \\\\\\"statusCode\\\\\\": \\\\\\"STATUS_CODE_OK\\\\\\", \\\\\\"statusMessage\\\\\\": \\\\\\"\\\\\\"}]\\"\\n ]\\n}","type":"json"}]', 'title' => '按照条件查找链路', 'requestParamsDescription' => '所有参数之间是AND的关系。spanIds的多个id之间是OR的关系。traceIds的多个id之间是OR的关系。一个trace里任何一个span如果符合搜索条件,那么这个trace就符合搜索条件。'."\n" ."\n" .'如果不需要支持opentelemetry格式的数据,建议把OpentelemetryCompatible参数设置成False,可以简化返回的json string的结构。', - ], - 'CreateServiceIdentityRole' => [ - 'summary' => '创建PaiLLMTrace服务需要使用的服务关联角色。', - 'path' => '/api/v1/PAILLMTrace/ServiceIdentityRole', - 'methods' => [ - 'post', - ], - 'schemes' => [ - 'https', + 'changeSet' => [], + 'ramActions' => [ + [ + 'operationType' => 'list', + 'ramAction' => [ + 'action' => 'paillmtrace:ListTracesDatas', + 'authLevel' => 'operate', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => '全部资源', 'arn' => '*'], + ], + ], + ], ], + ], + 'StopOnlineEvalTask' => [ + 'summary' => '停止一个链路评估任务的执行。任务停止后,不能再做任何配置改动,任务也不会再生成任何新的评估结果。', + 'path' => '/api/v1/PAILLMTrace/onlineevaltasks/{TaskId}/stop', + 'methods' => ['put'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], + 'consumes' => ['application/json'], + 'produces' => ['application/json'], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ - 'operationType' => 'none', + 'operationType' => 'update', 'riskType' => 'none', 'chargeType' => 'free', - 'abilityTreeCode' => '226578', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', + 'abilityTreeCode' => '241121', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], + ], + 'parameters' => [ + [ + 'name' => 'TaskId', + 'in' => 'path', + 'schema' => ['description' => '链路评估任务的id。', 'type' => 'string', 'required' => true, 'example' => '518b1d2f3cfca4ad3836ace4db69ba59c'], ], - 'tenantRelevance' => 'publicInformation', ], - 'parameters' => [], 'responses' => [ 200 => [ 'schema' => [ @@ -2109,161 +1302,103 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'Code' => [ - 'title' => '调用失败后的错误码。', - 'description' => '调用失败后的错误码。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'title' => '调用失败后的错误信息。', - 'description' => '调用失败后的错误信息。', - 'type' => 'string', - 'example' => 'User don\'t have permission to create SLR.', - ], - 'RoleName' => [ - 'description' => '操作服务关联角色名称,默认值:AliyunServiceRoleForPaiLLMTrace。', - 'type' => 'string', - 'example' => 'AliyunServiceRoleForPaiLLMTrace', - ], - 'RoleDetails' => [ - 'description' => '角色详细信息。', - 'type' => 'string', - 'example' => 'AliyunServiceRoleForPaiLLMTrace', - ], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the POP request', 'type' => 'string', 'example' => '31E5FBC2-792D-5B5C-A5EB-3019984ABFC8'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'task id is empty'], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], - 'eventInfo' => [ - 'enable' => false, - 'eventNames' => [], - ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"User don\'t have permission to create SLR.\\",\\n \\"RoleName\\": \\"AliyunServiceRoleForPaiLLMTrace\\",\\n \\"RoleDetails\\": \\"AliyunServiceRoleForPaiLLMTrace\\"\\n}","type":"json"}]', - 'title' => '创建服务关联角色。', + 'staticInfo' => ['returnType' => 'synchronous'], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"31E5FBC2-792D-5B5C-A5EB-3019984ABFC8\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"task id is empty\\"\\n}","type":"json"}]', + 'title' => '停止一个链路评估任务。', ], - 'GetServiceIdentityRole' => [ - 'summary' => '获取服务关联角色相关信息。', - 'path' => '/api/v1/PAILLMTrace/ServiceIdentityRole', - 'methods' => [ - 'get', - ], - 'schemes' => [ - 'https', - ], + 'UpdateOnlineEvalTask' => [ + 'summary' => '更改一个链路评估任务的配置。', + 'path' => '/api/v1/PAILLMTrace/onlineevaltasks/{TaskId}', + 'methods' => ['put'], + 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], - 'operationType' => 'read', + 'consumes' => ['application/json'], + 'produces' => ['application/json'], + 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ - 'operationType' => 'none', + 'operationType' => 'update', 'riskType' => 'none', 'chargeType' => 'free', - 'abilityTreeCode' => '229846', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], - 'tenantRelevance' => 'publicInformation', + 'abilityTreeCode' => '241120', + 'abilityTreeNodes' => ['FEATURElearn0UHCCK'], ], - 'parameters' => [], - 'responses' => [ - 200 => [ + 'parameters' => [ + [ + 'name' => 'TaskId', + 'in' => 'path', + 'schema' => ['description' => '链路评估任务的id。', 'type' => 'string', 'required' => true, 'example' => '518bc0f833d9a4ad3836ace4db69ba59c'], + ], + [ + 'name' => 'body', + 'in' => 'body', + 'style' => 'json', 'schema' => [ - 'title' => 'Schema of Response', - 'description' => 'Schema of Response', + 'description' => '请求体。', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'EntityNotExist', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'Serivce role does not exit.', - ], - 'RoleDetail' => [ - 'description' => '角色详细信息。', - 'type' => 'string', - 'example' => 'AliyunServiceRoleForPaiLLMTrace', - ], - 'RoleName' => [ - 'description' => '操作服务关联角色名称,默认值:AliyunServiceRoleForPaiLLMTrace。', - 'type' => 'string', - 'example' => 'AliyunServiceRoleForPaiLLMTrace', + 'TaskName' => ['description' => '任务名称', 'type' => 'string', 'required' => false, 'example' => 'foo大模型应用效果评估'], + 'AppName' => ['description' => '用户的基于大模型的应用的名称', 'type' => 'string', 'required' => false, 'example' => 'my-llm-one'], + 'Filters' => [ + 'description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义搜索筛选条件的列表。', + 'type' => 'array', + 'items' => [ + 'description' => '自定义过滤条件对象。', + 'type' => 'object', + 'properties' => [ + 'Key' => [ + 'description' => '过滤条件的key', + 'type' => 'string', + 'required' => false, + 'enumValueTitles' => ['Status' => 'Status', 'SpanName' => 'SpanName', 'Input' => 'Input', 'TraceType' => 'TraceType', 'SpanType' => 'SpanType', 'ServiceName' => 'ServiceName', 'Output' => 'Output', 'TraceName' => 'TraceName', 'ServiceId' => 'ServiceId'], + 'example' => 'ServiceId'."\n" + .'ServiceName'."\n" + .'Input'."\n" + .'Output'."\n" + .'Status'."\n" + .'TraceType'."\n" + .'SpanType'."\n" + .'TraceName'."\n" + .'SpanName', + ], + 'Operator' => [ + 'description' => '过滤条件匹配操作符', + 'type' => 'string', + 'required' => false, + 'enumValueTitles' => ['Contains' => 'Contains', '=' => '=', 'StartsWith' => 'StartsWith'], + 'example' => '='."\n" + .'StartsWith'."\n" + .'Contains', + ], + 'Value' => ['description' => '过滤条件的值', 'type' => 'string', 'required' => false, 'example' => 'foo'], + ], + 'required' => false, + ], + 'required' => false, ], + 'StartTime' => ['description' => '链路数据的UTC开始时间', 'type' => 'string', 'required' => false, 'example' => '2024-07-31 08:30:00'], + 'EndTime' => ['description' => '链路数据的UTC结束时间', 'type' => 'string', 'required' => false, 'example' => '2024-09-02 22:24:00'], + 'SamplingFrequencyMinutes' => ['description' => '评估任务要搜索一定量的用户应用产生的链路数据,作为评估操作的输入数据。这是定义任务每次搜索输入数据的时间窗口的宽度。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '10'], + 'SamplingRatio' => ['description' => '评估任务在一个时间窗口里搜索到的数据,真正作为评估输入数据的百分比。比如100表示搜索到的所有数据都作为评估输入。又比如20表示从搜索到的数据里随机取20%作为评估输入。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '50'], + 'Description' => ['description' => '任务描述信息', 'type' => 'string', 'required' => false, 'example' => '这个任务做了这些事。'], + 'EvaluationConfig' => ['description' => '从json格式的链路数据里要一些提取特定路径上的值,作为评估操作的输入。在这个EvaluationConfig结构体里定义这些json路径。', 'required' => false, '$ref' => '#/components/schemas/EvaluationConfig'], + 'ModelConfig' => ['description' => '评估任务内部使用的大模型的访问配置结构体。', 'required' => false, '$ref' => '#/components/schemas/ModelConfig'], ], + 'required' => false, ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', - ], - 'eventInfo' => [ - 'enable' => false, - 'eventNames' => [], - ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"EntityNotExist\\",\\n \\"Message\\": \\"Serivce role does not exit.\\",\\n \\"RoleDetail\\": \\"AliyunServiceRoleForPaiLLMTrace\\",\\n \\"RoleName\\": \\"AliyunServiceRoleForPaiLLMTrace\\"\\n}","type":"json"}]', - 'title' => '获取服务关联角色。', - ], - 'GetXtraceToken' => [ - 'summary' => '获取Xtrace服务中所使用的token,以及上传trace数据所需要的endpoint。', - 'path' => '/api/v1/PAILLMTrace/XtraceToken', - 'methods' => [ - 'get', - ], - 'schemes' => [ - 'https', - ], - 'security' => [ - [ - 'AK' => [], - ], - ], - 'consumes' => [ - 'application/json', - ], - 'produces' => [ - 'application/json', - ], - 'operationType' => 'read', - 'deprecated' => false, - 'systemTags' => [ - 'operationType' => 'none', - 'riskType' => 'none', - 'chargeType' => 'free', - 'abilityTreeCode' => '230427', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', - ], - 'tenantRelevance' => 'publicInformation', - ], - 'parameters' => [], 'responses' => [ 200 => [ 'schema' => [ @@ -2271,229 +1406,212 @@ 'description' => 'Schema of Response', 'type' => 'object', 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'Id of the request', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'InvalidInputParams', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'get_xtrace_token: failed, ERROR: NoPermission', - ], - 'Token' => [ - 'description' => 'arms链路上传使用的token', - 'type' => 'string', - 'example' => 'h1abcw7@5abcb_h1abcw7@5abc01', - ], - 'HttpEndpoint' => [ - 'description' => 'arms链路上传使用的endpoint.', - 'type' => 'string', - 'example' => 'http://tracing-analysis-dc-hz.aliyuncs.com/aaa@bbb@ccc/api/otlp/traces', - ], - 'HttpInternalEndpoint' => [ - 'description' => '阿里云内部使用的arms链路上传的endpoint', - 'type' => 'string', - 'example' => 'http://tracing-analysis-dc-hz-internal.aliyuncs.com/aaa@bbb@ccc/api/otlp/traces', - ], - 'GrpcEndpoint' => [ - 'description' => 'arms链路上传使用的grpc endpoint', - 'type' => 'string', - 'example' => 'http://tracing-analysis-dc-hz.aliyuncs.com:8090', - ], - 'GrpcInternalEndpoint' => [ - 'description' => '阿里云内部使用的arms链路上传的grpc endpoint', - 'type' => 'string', - 'example' => 'http://tracing-analysis-dc-hz-internal.aliyuncs.com:8090', - ], + 'RequestId' => ['title' => 'Id of the request', 'description' => 'Id of the POP request', 'type' => 'string', 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5'], + 'Code' => ['description' => '内部错误码。只在响应出错时被设置。', 'type' => 'string', 'example' => 'InvalidInputParams'], + 'Message' => ['description' => '响应错误信息。只在响应出错时被设置。', 'type' => 'string', 'example' => 'cannot modify a stopped task'], ], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', + 'staticInfo' => ['returnType' => 'synchronous'], + 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"cannot modify a stopped task\\"\\n}","type":"json"}]', + 'title' => '更改一个链路评估任务的配置。', + ], + ], + 'endpoints' => [ + ['regionId' => 'cn-shenzhen', 'regionName' => '华南1(深圳)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paillmtrace.cn-shenzhen.aliyuncs.com', 'endpoint' => 'paillmtrace.cn-shenzhen.aliyuncs.com', 'vpc' => 'paillmtrace-vpc.cn-shenzhen.aliyuncs.com'], + ['regionId' => 'cn-beijing', 'regionName' => '华北2(北京)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paillmtrace.cn-beijing.aliyuncs.com', 'endpoint' => 'paillmtrace.cn-beijing.aliyuncs.com', 'vpc' => 'paillmtrace-vpc.cn-beijing.aliyuncs.com'], + ['regionId' => 'cn-shanghai', 'regionName' => '华东2(上海)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paillmtrace.cn-shanghai.aliyuncs.com', 'endpoint' => 'paillmtrace.cn-shanghai.aliyuncs.com', 'vpc' => 'paillmtrace-vpc.cn-shanghai.aliyuncs.com'], + ['regionId' => 'cn-hangzhou', 'regionName' => '华东1(杭州)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paillmtrace.cn-hangzhou.aliyuncs.com', 'endpoint' => 'paillmtrace.cn-hangzhou.aliyuncs.com', 'vpc' => 'paillmtrace-vpc.cn-hangzhou.aliyuncs.com'], + ], + 'errorCodes' => [], + 'changeSet' => [], + 'ram' => [ + 'productCode' => 'PAILLMTrace', + 'productName' => '人工智能平台 PAI', + 'ramCodes' => ['paillmtrace'], + 'ramLevel' => '资源级', + 'ramConditions' => [ + [ + 'name' => 'paillmtrace:TestThis', + 'schema' => ['type' => 'String', 'description' => 'paillmtrace:TestThis'], ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"InvalidInputParams\\",\\n \\"Message\\": \\"get_xtrace_token: failed, ERROR: NoPermission\\",\\n \\"Token\\": \\"h1abcw7@5abcb_h1abcw7@5abc01\\",\\n \\"HttpEndpoint\\": \\"http://tracing-analysis-dc-hz.aliyuncs.com/aaa@bbb@ccc/api/otlp/traces\\",\\n \\"HttpInternalEndpoint\\": \\"http://tracing-analysis-dc-hz-internal.aliyuncs.com/aaa@bbb@ccc/api/otlp/traces\\",\\n \\"GrpcEndpoint\\": \\"http://tracing-analysis-dc-hz.aliyuncs.com:8090\\",\\n \\"GrpcInternalEndpoint\\": \\"http://tracing-analysis-dc-hz-internal.aliyuncs.com:8090\\"\\n}","type":"json"}]', - 'title' => '获取Xtrace服务的Token。', ], - 'ListEvalResults' => [ - 'summary' => '获取链路数据评估结果列表。和EvaluateTrace API搭配使用。EvaluateTrace触发评估操作。ListEvalResults获取评估结果。', - 'path' => '/api/v1/PAILLMTrace/eval/results', - 'methods' => [ - 'get', + 'ramActions' => [ + [ + 'apiName' => 'GetServiceIdentityRole', + 'description' => '获取服务关联角色。', + 'operationType' => 'none', + 'ramAction' => [ + 'action' => 'paillmtrace:GetServiceIdentityRole', + 'authLevel' => 'operate', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => '全部资源', 'arn' => '*'], + ], + ], ], - 'schemes' => [ - 'https', + [ + 'apiName' => 'CreateOnlineEvalTask', + 'description' => '创建一个链路评估任务。', + 'operationType' => 'create', + 'ramAction' => [ + 'action' => 'paillmtrace:CreateOnlineEvalTask', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/*'], + ], + ], ], - 'security' => [ - [ - 'AK' => [], + [ + 'apiName' => 'ListTracesDatas', + 'description' => '按照条件查找链路', + 'operationType' => 'list', + 'ramAction' => [ + 'action' => 'paillmtrace:ListTracesDatas', + 'authLevel' => 'operate', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => '全部资源', 'arn' => '*'], + ], ], ], - 'consumes' => [ - 'application/json', + [ + 'apiName' => 'GetOnlineEvalTask', + 'description' => '获取一个链路评估任务的详细信息。', + 'operationType' => 'get', + 'ramAction' => [ + 'action' => 'paillmtrace:GetOnlineEvalTask', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/{#OnlineEvaluationId}'], + ], + ], ], - 'produces' => [ - 'application/json', + [ + 'apiName' => 'GetXtraceToken', + 'description' => '获取Xtrace服务的Token。', + 'operationType' => 'none', + 'ramAction' => [ + 'action' => 'paillmtrace:GetXtraceToken', + 'authLevel' => 'operate', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => '全部资源', 'arn' => '*'], + ], + ], ], - 'operationType' => 'read', - 'deprecated' => false, - 'systemTags' => [ - 'operationType' => 'list', - 'riskType' => 'none', - 'chargeType' => 'free', - 'abilityTreeCode' => '237145', - 'abilityTreeNodes' => [ - 'FEATURElearn0UHCCK', + [ + 'apiName' => 'UpdateOnlineEvalTask', + 'description' => '更改一个链路评估任务的配置。', + 'operationType' => 'update', + 'ramAction' => [ + 'action' => 'paillmtrace:UpdateOnlineEvalTask', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/{#OnlineEvaluationId}'], + ], ], ], - 'parameters' => [ - [ - 'name' => 'RecordIds', - 'in' => 'query', - 'style' => 'simple', - 'schema' => [ - 'description' => '链路数据id列表。', - 'type' => 'array', - 'items' => [ - 'description' => '链路数据id', - 'type' => 'string', - 'required' => false, - 'example' => '7423034a494ca17c16443ffd16336981', - ], - 'required' => false, + [ + 'apiName' => 'StopOnlineEvalTask', + 'description' => '停止一个链路评估任务。', + 'operationType' => 'update', + 'ramAction' => [ + 'action' => 'paillmtrace:StopOnlineEvalTask', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/{#OnlineEvaluationId}'], ], ], - [ - 'name' => 'PageNumber', - 'in' => 'query', - 'schema' => [ - 'description' => '分页查询时设置的页码。 起始值:1。默认值:1。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '1', + ], + [ + 'apiName' => 'CreateServiceIdentityRole', + 'description' => '创建服务关联角色。', + 'operationType' => 'none', + 'ramAction' => [ + 'action' => 'paillmtrace:CreateServiceLinkedRole', + 'authLevel' => 'operate', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => '全部资源', 'arn' => '*'], ], ], - [ - 'name' => 'PageSize', - 'in' => 'query', - 'schema' => [ - 'description' => '分页大小,默认值10,最大值50。', - 'type' => 'integer', - 'format' => 'int32', - 'required' => false, - 'example' => '10', + ], + [ + 'apiName' => 'ListOnlineEvalTaskResults', + 'description' => '获取一个链路评估任务的结果列表', + 'operationType' => 'get', + 'ramAction' => [ + 'action' => 'paillmtrace:ListOnlineEvalTaskResults', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/{#OnlineEvaluationId}'], ], ], - [ - 'name' => 'EvaluationId', - 'in' => 'query', - 'schema' => [ - 'description' => '链路数据所属的评估任务的任务id。', - 'type' => 'string', - 'required' => false, - 'example' => '0bb05ae2a2dc11ef9757faaa2a1ec0c6', + ], + [ + 'apiName' => 'ListOnlineEvalTasks', + 'description' => '获取链路评估任务列表。', + 'operationType' => 'list', + 'ramAction' => [ + 'action' => 'paillmtrace:ListOnlineEvalTasks', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/*'], ], ], - [ - 'name' => 'Keyword', - 'in' => 'query', - 'schema' => [ - 'description' => '查询关键字,在评估输入数据里查询。', - 'type' => 'string', - 'required' => false, - 'example' => 'foo', + ], + [ + 'apiName' => 'EvaluateTrace', + 'description' => '评估一条指定的链路数据。', + 'operationType' => 'none', + 'ramAction' => [ + 'action' => 'paillmtrace:EvaluateTrace', + 'authLevel' => 'operate', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => '全部资源', 'arn' => '*'], ], ], ], - 'responses' => [ - 200 => [ - 'schema' => [ - 'title' => 'Schema of Response', - 'description' => 'Schema of Response', - 'type' => 'object', - 'properties' => [ - 'RequestId' => [ - 'title' => 'Id of the request', - 'description' => 'POP请求id', - 'type' => 'string', - 'example' => '6A87228C-969A-1381-98CF-AE07AE630FA5', - ], - 'Code' => [ - 'description' => '内部错误码。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'ExecutionFailure', - ], - 'Message' => [ - 'description' => '响应错误信息。只在响应出错时被设置。', - 'type' => 'string', - 'example' => 'cannot get data back.', - ], - 'TotalCount' => [ - 'description' => '符合条件的评估结果的总数。', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '22', - ], - 'EvaluationResults' => [ - 'description' => '资源评估结果列表。', - 'type' => 'array', - 'items' => [ - 'description' => '一条链路记录的评估结果。', - 'type' => 'string', - 'example' => '[{'."\n" - .' "result": {'."\n" - .' "correctness": {'."\n" - .' "label": "正确",'."\n" - .' "score": 1,'."\n" - .' "reason": " \\n - 回顾问题:询问了26岁理工宅男的礼物建议。\\n - 回顾答案:提供了多种礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\n - 回答内容详细且具体,提供了多种选择。\\n - 回答内容与问题相关,提供了多种礼物建议。\\n</think>\\n<answer>{\\"label\\":\\"正确\\", \\"reason\\":\\"提供了多种礼物建议,与问题相关,内容详细且具体。\\"}</answer></answer>",'."\n" - .' "name": "正确性"'."\n" - .' },'."\n" - .' "faithfulness": {'."\n" - .' "label": "事实",'."\n" - .' "score": 1,'."\n" - .' "reason": " \\n - 回顾查询内容,用户询问了适合26岁理工宅男的礼物建议。\\n - 回答内容提供了多个具体的礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\n - 回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\n - 回答内容没有提供虚构的信息,因此可以认为是基于事实的。\\n</think>\\n<answer>{\\"label\\":\\"事实\\", \\"reason\\":\\"回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\"}</answer></answer>",'."\n" - .' "name": "真实性"'."\n" - .' }'."\n" - .' },'."\n" - .' "eval_app_type": "qa"'."\n" - .'}]', - ], - ], - ], + [ + 'apiName' => 'DeleteOnlineEvalTask', + 'description' => '删除一个链路评估任务。', + 'operationType' => 'delete', + 'ramAction' => [ + 'action' => 'paillmtrace:DeleteOnlineEvalTask', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/{#OnlineEvaluationId}'], ], ], ], - 'staticInfo' => [ - 'returnType' => 'synchronous', + [ + 'apiName' => 'ListEvalResults', + 'description' => '获取链路数据评估结果', + 'operationType' => 'list', + 'ramAction' => [ + 'action' => 'paillmtrace:ListEvalResults', + 'authLevel' => 'resource', + 'actionConditions' => [], + 'resources' => [ + ['validationType' => 'always', 'product' => 'PAILLMTrace', 'resourceType' => 'Eval', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:eval/{#EvalId}'], + ], + ], ], - 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6A87228C-969A-1381-98CF-AE07AE630FA5\\",\\n \\"Code\\": \\"ExecutionFailure\\",\\n \\"Message\\": \\"cannot get data back.\\",\\n \\"TotalCount\\": 22,\\n \\"EvaluationResults\\": [\\n \\"[{\\\\n \\\\\\"result\\\\\\": {\\\\n \\\\\\"correctness\\\\\\": {\\\\n \\\\\\"label\\\\\\": \\\\\\"正确\\\\\\",\\\\n \\\\\\"score\\\\\\": 1,\\\\n \\\\\\"reason\\\\\\": \\\\\\" \\\\\\\\n - 回顾问题:询问了26岁理工宅男的礼物建议。\\\\\\\\n - 回顾答案:提供了多种礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\\\\\\\n - 回答内容详细且具体,提供了多种选择。\\\\\\\\n - 回答内容与问题相关,提供了多种礼物建议。\\\\\\\\n</think>\\\\\\\\n<answer>{\\\\\\\\\\\\\\"label\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"正确\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"reason\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"提供了多种礼物建议,与问题相关,内容详细且具体。\\\\\\\\\\\\\\"}</answer></answer>\\\\\\",\\\\n \\\\\\"name\\\\\\": \\\\\\"正确性\\\\\\"\\\\n },\\\\n \\\\\\"faithfulness\\\\\\": {\\\\n \\\\\\"label\\\\\\": \\\\\\"事实\\\\\\",\\\\n \\\\\\"score\\\\\\": 1,\\\\n \\\\\\"reason\\\\\\": \\\\\\" \\\\\\\\n - 回顾查询内容,用户询问了适合26岁理工宅男的礼物建议。\\\\\\\\n - 回答内容提供了多个具体的礼物建议,包括智能穿戴设备、最新款电子产品、编程相关书籍、DIY组装套件、桌游或拼图、科幻小说/漫画集、个性化定制礼品、体验式礼物。\\\\\\\\n - 回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\\\\\\\n - 回答内容没有提供虚构的信息,因此可以认为是基于事实的。\\\\\\\\n</think>\\\\\\\\n<answer>{\\\\\\\\\\\\\\"label\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"事实\\\\\\\\\\\\\\", \\\\\\\\\\\\\\"reason\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"回答内容提供了多种可能的礼物选项,这些选项在逻辑上是合理的,且与用户的需求相关。\\\\\\\\\\\\\\"}</answer></answer>\\\\\\",\\\\n \\\\\\"name\\\\\\": \\\\\\"真实性\\\\\\"\\\\n }\\\\n },\\\\n \\\\\\"eval_app_type\\\\\\": \\\\\\"qa\\\\\\"\\\\n}]\\"\\n ]\\n}","type":"json"}]', - 'title' => '获取链路数据评估结果', ], - ], - 'endpoints' => [ - [ - 'regionId' => 'cn-hangzhou', - 'endpoint' => 'paillmtrace.cn-hangzhou.aliyuncs.com', - ], - [ - 'regionId' => 'cn-beijing', - 'endpoint' => 'paillmtrace.cn-beijing.aliyuncs.com', - ], - [ - 'regionId' => 'cn-shanghai', - 'endpoint' => 'paillmtrace.cn-shanghai.aliyuncs.com', - ], - [ - 'regionId' => 'cn-shenzhen', - 'endpoint' => 'paillmtrace.cn-shenzhen.aliyuncs.com', + 'resourceTypes' => [ + ['validationType' => 'always', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/*'], + ['validationType' => 'always', 'resourceType' => 'OnlineEvaluation', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:onlineevaluation/{#OnlineEvaluationId}'], + ['validationType' => 'always', 'resourceType' => 'Eval', 'arn' => 'acs:paillmtrace:{#regionId}:{#accountId}:eval/{#EvalId}'], ], ], ]; |
