diff options
| author | Zhineng Li <im@zhineng.li> | 2026-07-12 17:11:17 +0800 |
|---|---|---|
| committer | Zhineng Li <im@zhineng.li> | 2026-07-12 17:11:17 +0800 |
| commit | 1c7f908ce09f98fdcbf79ed2a8ae21be60eaa634 (patch) | |
| tree | 5f0857666365b7e40cdaa3733ebe1f3ba9e13c67 /data/en_us/nlp-automl/2019-07-01/api-docs.php | |
| parent | 7347bac4ab7e136157fc94777e6cf87ef9e08599 (diff) | |
| download | afterglow-metadata-full-1c7f908ce09f98fdcbf79ed2a8ae21be60eaa634.tar.gz afterglow-metadata-full-1c7f908ce09f98fdcbf79ed2a8ae21be60eaa634.zip | |
update APIs 20260712
Diffstat (limited to 'data/en_us/nlp-automl/2019-07-01/api-docs.php')
| -rw-r--r-- | data/en_us/nlp-automl/2019-07-01/api-docs.php | 343 |
1 files changed, 158 insertions, 185 deletions
diff --git a/data/en_us/nlp-automl/2019-07-01/api-docs.php b/data/en_us/nlp-automl/2019-07-01/api-docs.php index 002b6c6..eeffd34 100644 --- a/data/en_us/nlp-automl/2019-07-01/api-docs.php +++ b/data/en_us/nlp-automl/2019-07-01/api-docs.php @@ -1,35 +1,14 @@ <?php return [ 'version' => '1.0', - 'info' => [ - 'style' => 'RPC', - 'product' => 'nlp-automl', - 'version' => '2019-07-01', - ], - 'directories' => [ - [ - 'id' => 0, - 'title' => '其它', - 'type' => 'directory', - 'children' => [ - 'AddMTInterveneWord', - 'GetPredictDoc', - 'PredictMTModelByDoc', - ], - ], - ], + 'info' => ['style' => 'RPC', 'product' => 'nlp-automl', 'version' => '2019-07-01'], + 'directories' => ['AddMTInterveneWord', 'GetPredictDoc', 'PredictMTModelByDoc'], 'components' => [ 'schemas' => [], ], 'apis' => [ 'AddMTInterveneWord' => [ - 'methods' => [ - 'post', - 'get', - ], - 'schemes' => [ - 'http', - 'https', - ], + 'methods' => ['post', 'get'], + 'schemes' => ['http', 'https'], 'security' => [ [ 'AK' => [], @@ -43,53 +22,27 @@ ], 'operationType' => 'write', 'deprecated' => false, - 'systemTags' => [ - 'operationType' => 'update', - ], + 'systemTags' => ['operationType' => 'update'], 'parameters' => [ [ 'name' => 'SourceText', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'string', - 'required' => true, - 'docRequired' => true, - 'example' => 'hello', - ], + 'schema' => ['description' => 'The source text.', 'type' => 'string', 'required' => true, 'docRequired' => true, 'example' => 'hello', 'title' => ''], ], [ 'name' => 'TargetText', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'string', - 'required' => false, - 'example' => '', - ], + 'schema' => ['description' => 'The target text.', 'type' => 'string', 'required' => false, 'example' => '你好', 'title' => ''], ], [ 'name' => 'ProjectId', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'string', - 'required' => true, - 'docRequired' => true, - 'example' => '1', - ], + 'schema' => ['description' => 'The project ID.', 'type' => 'string', 'required' => true, 'docRequired' => true, 'example' => '1', 'title' => ''], ], [ 'name' => 'PackageId', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'string', - 'required' => false, - 'docRequired' => true, - 'example' => '1', - 'default' => 'mt_automl', - ], + 'schema' => ['description' => 'The word package ID.', 'type' => 'string', 'required' => false, 'docRequired' => true, 'default' => 'mt_automl', 'example' => '1', 'title' => ''], ], ], 'responses' => [ @@ -97,44 +50,36 @@ 'schema' => [ 'type' => 'object', 'properties' => [ - 'Code' => [ - 'description' => '', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '200', - ], - 'Message' => [ - 'description' => '', - 'type' => 'string', - 'example' => 'parameterError', - ], - 'RequestId' => [ - 'description' => '', - 'type' => 'string', - 'example' => '46E6B40D-2B6C-571B-AC41-86207DE288A5', - ], - 'WordId' => [ - 'description' => '', - 'type' => 'integer', - 'format' => 'int64', - 'example' => '1', - ], + 'Code' => ['description' => 'The response code. Valid values:'."\n" + .'- 200: success.'."\n" + .'- Other values: error codes. For more information, see error codes.', 'type' => 'integer', 'format' => 'int32', 'example' => '200', 'title' => ''], + 'Message' => ['description' => 'The error message corresponding to the error code.', 'type' => 'string', 'example' => 'parameterError', 'title' => ''], + 'RequestId' => ['description' => 'The request ID.', 'type' => 'string', 'example' => '46E6B40D-2B6C-571B-AC41-86207DE288A5', 'title' => ''], + 'WordId' => ['description' => 'The ID of the successfully added word.', 'type' => 'integer', 'format' => 'int64', 'example' => '1', 'title' => ''], ], + 'description' => '', + 'title' => '', + 'example' => '', ], ], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"Code\\": 200,\\n \\"Message\\": \\"parameterError\\",\\n \\"RequestId\\": \\"46E6B40D-2B6C-571B-AC41-86207DE288A5\\",\\n \\"WordId\\": 1\\n}","type":"json"}]', - ], - 'GetPredictDoc' => [ - 'methods' => [ - 'head', - 'post', - 'get', + 'title' => 'Add intervention data', + 'summary' => 'Adds the source text and target text to be intervened to the dataset corresponding to the specified ProjectId and PackageId.', + 'description' => 'Before using this operation, make sure that you fully understand the billing method and [pricing](https://common-buy.aliyun.com/?commodityCode=nlp_bag#/buy) of the NLP Self-learning Platform.', + 'changeSet' => [ + ['createdAt' => '2022-03-07T07:22:38.000Z', 'description' => 'Response parameters changed, Error codes changed'], ], - 'schemes' => [ - 'http', - 'https', + 'flowControl' => [ + 'flowControlList' => [ + ['threshold' => '30', 'countWindow' => 1, 'regionId' => '*', 'api' => 'AddMTInterveneWord'], + ], + 'product' => ['code' => 'nlp', 'title' => '自然语言处理'], ], + ], + 'GetPredictDoc' => [ + 'methods' => ['head', 'post', 'get'], + 'schemes' => ['http', 'https'], 'security' => [ [ 'AK' => [], @@ -151,32 +96,17 @@ ], 'operationType' => 'readAndWrite', 'deprecated' => false, - 'systemTags' => [ - 'operationType' => 'get', - ], + 'systemTags' => ['operationType' => 'get'], 'parameters' => [ [ 'name' => 'DocId', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'integer', - 'format' => 'int64', - 'required' => true, - 'docRequired' => true, - 'example' => '1000', - ], + 'schema' => ['description' => 'The document ID.', 'type' => 'integer', 'format' => 'int64', 'required' => true, 'docRequired' => true, 'example' => '1000', 'title' => ''], ], [ 'name' => 'Product', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'string', - 'required' => false, - 'example' => '', - 'default' => 'mt_automl', - ], + 'schema' => ['description' => 'The product code.', 'type' => 'string', 'required' => false, 'default' => 'mt_automl', 'example' => '空', 'title' => ''], ], ], 'responses' => [ @@ -184,43 +114,38 @@ 'schema' => [ 'type' => 'object', 'properties' => [ - 'Status' => [ - 'description' => '', - 'type' => 'integer', - 'format' => 'int32', - 'example' => '2', - ], - 'RequestId' => [ - 'description' => '', - 'type' => 'string', - 'example' => '86D18195-D89C-4C8C-9DC4-5FCE789CE6D5', - ], - 'ResultContent' => [ - 'description' => '', - 'type' => 'string', - 'example' => 'xxx', - ], - 'XLIFFInfo' => [ - 'description' => '', - 'type' => 'string', - 'example' => 'xxx', - ], + 'Status' => ['description' => 'The processing status. Valid values:'."\n" + .'- 0: initialization'."\n" + .'- 1: processing'."\n" + .'- 2: processing succeeded'."\n" + .'- 3: processing failed.', 'type' => 'integer', 'format' => 'int32', 'example' => '2', 'title' => ''], + 'RequestId' => ['description' => 'The request ID.', 'type' => 'string', 'example' => '86D18195-D89C-4C8C-9DC4-5FCE789CE6D5', 'title' => ''], + 'ResultContent' => ['description' => 'The prediction result, in file stream format.', 'type' => 'string', 'example' => 'xxx', 'title' => ''], + 'XLIFFInfo' => ['description' => 'The XLIFF information, in file stream format.', 'type' => 'string', 'example' => 'xxx', 'title' => ''], ], + 'description' => '', + 'title' => '', + 'example' => '', ], ], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"Status\\": 2,\\n \\"RequestId\\": \\"86D18195-D89C-4C8C-9DC4-5FCE789CE6D5\\",\\n \\"ResultContent\\": \\"xxx\\",\\n \\"XLIFFInfo\\": \\"xxx\\"\\n}","type":"json"}]', - ], - 'PredictMTModelByDoc' => [ - 'methods' => [ - 'head', - 'post', - 'get', + 'title' => 'Retrieve document prediction result', + 'summary' => 'Retrieves the prediction result of a document based on the docId returned by PredictMTModelByDoc.', + 'description' => 'Before using this operation, make sure that you fully understand the billing of NLP AutoLearning and its [pricing](https://common-buy.aliyun.com/?commodityCode=nlp_bag#/buy).', + 'changeSet' => [ + ['createdAt' => '2024-07-04T02:12:17.000Z', 'description' => 'Error codes changed'], ], - 'schemes' => [ - 'http', - 'https', + 'flowControl' => [ + 'flowControlList' => [ + ['threshold' => '5', 'countWindow' => 1, 'regionId' => '*', 'api' => 'GetPredictDoc'], + ], + 'product' => ['code' => 'nlp', 'title' => '自然语言处理'], ], + ], + 'PredictMTModelByDoc' => [ + 'methods' => ['head', 'post', 'get'], + 'schemes' => ['http', 'https'], 'security' => [ [ 'AK' => [], @@ -237,64 +162,32 @@ ], 'operationType' => 'readAndWrite', 'deprecated' => false, - 'systemTags' => [ - 'operationType' => 'get', - ], + 'systemTags' => ['operationType' => 'get'], 'parameters' => [ [ 'name' => 'FileContent', 'in' => 'formData', - 'schema' => [ - 'description' => '', - 'type' => 'string', - 'required' => true, - 'docRequired' => true, - 'example' => '[base64 encode content]', - ], + 'schema' => ['description' => 'The file data content. The file content must be processed with Base64 encoding.', 'type' => 'string', 'required' => true, 'docRequired' => true, 'example' => '[base64 encode content]', 'title' => ''], ], [ 'name' => 'FileType', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'string', - 'required' => true, - 'docRequired' => true, - 'example' => 'docx', - ], + 'schema' => ['description' => 'The file type.', 'type' => 'string', 'required' => true, 'docRequired' => true, 'example' => 'docx', 'title' => ''], ], [ 'name' => 'ModelId', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'integer', - 'format' => 'int32', - 'required' => true, - 'docRequired' => true, - 'example' => '1', - ], + 'schema' => ['description' => 'The model ID.', 'type' => 'integer', 'format' => 'int32', 'required' => true, 'docRequired' => true, 'example' => '1', 'title' => ''], ], [ 'name' => 'NeedXLIFF', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'boolean', - 'required' => false, - 'example' => 'true', - ], + 'schema' => ['description' => 'Specifies whether XLIFF information is required.', 'type' => 'boolean', 'required' => false, 'example' => 'true', 'title' => ''], ], [ 'name' => 'ModelVersion', 'in' => 'query', - 'schema' => [ - 'description' => '', - 'type' => 'string', - 'required' => true, - 'docRequired' => true, - 'example' => 'v1', - ], + 'schema' => ['description' => 'The model version.', 'type' => 'string', 'required' => true, 'docRequired' => true, 'example' => 'v1', 'title' => ''], ], ], 'responses' => [ @@ -302,27 +195,107 @@ 'schema' => [ 'type' => 'object', 'properties' => [ - 'DocId' => [ - 'description' => '', - 'type' => 'string', - 'example' => '1', - ], - 'RequestId' => [ - 'description' => '', - 'type' => 'string', - 'example' => '86D18195-D89C-4C8C-9DC4-5FCE789CE6D5', - ], + 'DocId' => ['description' => 'The document ID.', 'type' => 'string', 'example' => '1', 'title' => ''], + 'RequestId' => ['description' => 'The request ID.', 'type' => 'string', 'example' => '86D18195-D89C-4C8C-9DC4-5FCE789CE6D5', 'title' => ''], ], + 'description' => '', + 'title' => '', + 'example' => '', ], ], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"DocId\\": \\"1\\",\\n \\"RequestId\\": \\"86D18195-D89C-4C8C-9DC4-5FCE789CE6D5\\"\\n}","type":"json"}]', + 'title' => 'Submit a document prediction task', + 'summary' => 'Uploads document content and uses a specified model for prediction.', + 'description' => 'Before using this operation, make sure that you fully understand the billing method and [pricing](https://common-buy.aliyun.com/?commodityCode=nlp_bag#/buy) of NLP Self-learning Platform.', + 'changeSet' => [ + ['createdAt' => '2024-07-04T02:12:17.000Z', 'description' => 'Error codes changed'], + ], + 'flowControl' => [ + 'flowControlList' => [ + ['threshold' => '5', 'countWindow' => 1, 'regionId' => '*', 'api' => 'PredictMTModelByDoc'], + ], + 'product' => ['code' => 'nlp', 'title' => '自然语言处理'], + ], ], ], 'endpoints' => [ + ['regionId' => 'cn-hangzhou', 'regionName' => 'China (Hangzhou)', 'areaId' => 'asiaPacific', 'areaName' => 'Asia Pacific', 'public' => 'nlp-automl.cn-hangzhou.aliyuncs.com', 'endpoint' => 'nlp-automl.cn-hangzhou.aliyuncs.com', 'vpc' => 'nlp-automl-vpc.cn-hangzhou.aliyuncs.com'], + ], + 'errorCodes' => [ + ['code' => '40001', 'message' => 'The quota for calling the model is exceeded.', 'http_code' => 403, 'description' => ''], + ['code' => '40002', 'message' => 'The specified interface is throttled.', 'http_code' => 403, 'description' => 'The specified interface is throttled.'], + ['code' => '40003', 'message' => 'An error occurred while authenticating the model.', 'http_code' => 403, 'description' => ''], + ['code' => '40004', 'message' => 'A server error occurred while processing your request. Please try again later or contact customer support.', 'http_code' => 200, 'description' => 'A server error occurred while processing your request. Please try again later or contact customer support.'], + ['code' => '40013', 'message' => 'An error occurred while authenticating the model.', 'http_code' => 403, 'description' => ''], + ['code' => 'Account arrearage', 'message' => 'The account is arrearage.', 'http_code' => 400, 'description' => 'Account Arrears'], + ['code' => 'BaseModelNotFound', 'message' => 'The base model is not found.', 'http_code' => 400, 'description' => ''], + ['code' => 'createModelConcurrency', 'message' => 'Creating multiple models at the same time is not allowed.', 'http_code' => 400, 'description' => ''], + ['code' => 'DataCenter.IllegalDatasetId', 'message' => 'The format of the dataset ID is invalid.', 'http_code' => 403, 'description' => ''], + ['code' => 'DataCenter.IllegalDatasetRecord', 'message' => 'The format of the dataset record is invalid.', 'http_code' => 403, 'description' => ''], + ['code' => 'dataFormatError', 'message' => 'The number of data bars added exceeds 500.', 'http_code' => 400, 'description' => ''], + ['code' => 'DocParseError', 'message' => 'The version of the uploaded DOC file is too early to support parsing. You are advised to replace the DOCX file with the latest version.', 'http_code' => 400, 'description' => ''], + ['code' => 'FileParseError', 'message' => 'The uploaded file failed to be parsed.', 'http_code' => 500, 'description' => ''], + ['code' => 'Forbbiden', 'message' => 'You are not authorized to operate on the specified resource.', 'http_code' => 403, 'description' => 'You are not authorized to operate on the specified resource.'], + ['code' => 'InternalError', 'message' => 'An error occurred while processing your request.', 'http_code' => 500, 'description' => 'An error occurred while processing your request.'], + ['code' => 'InvalidAccountStatus.ServiceLimit', 'message' => 'The maximum number of free API daily visits is exceeded.', 'http_code' => 400, 'description' => ''], + ['code' => 'InvalidAccountStatus.ServiceUnavailable', 'message' => 'The NLP Auto Machine Learning service has not been activated.', 'http_code' => 400, 'description' => 'The NLP Auto Machine Learning service has not been activated.'], + ['code' => 'InvalidContentLength', 'message' => 'The length of content exceeds the limit.', 'http_code' => 400, 'description' => ''], + ['code' => 'InvalidParameter', 'message' => 'The parameter is invalid.', 'http_code' => 400, 'description' => ''], + ['code' => 'InvalidParameter.ModelId', 'message' => 'The specified modelId is invalid.', 'http_code' => 400, 'description' => ''], + ['code' => 'InvalidParameter.ModelVersion', 'message' => 'The specified modelVersion is invalid.', 'http_code' => 400, 'description' => ''], + ['code' => 'InvalidServiceName', 'message' => 'The service does not exist.', 'http_code' => 400, 'description' => 'The service is not exists.'], + ['code' => 'ModelCenter.CreateModelLimit', 'message' => 'The maximum number of models you created is exceeded.', 'http_code' => 403, 'description' => ''], + ['code' => 'ModelCenter.DeployModelLimit', 'message' => 'The maximum number of online models is exceeded. You cannot deploy the model.', 'http_code' => 403, 'description' => ''], + ['code' => 'ModelCenter.IllegalModelName', 'message' => 'The format of the model name is invalid.', 'http_code' => 400, 'description' => ''], + ['code' => 'ModelCenter.MinTrainingcount', 'message' => 'The number of model training records is less than 4.', 'http_code' => 400, 'description' => ''], + ['code' => 'ModelCenter.ModelNotFound', 'message' => 'The model information is not found.', 'http_code' => 400, 'description' => ''], + ['code' => 'ModelCenter.ModelNotInProject', 'message' => 'The model is not in the specified project.', 'http_code' => 400, 'description' => ''], + ['code' => 'ModelCenter.ModelStatusError', 'message' => 'The model status is abnormal.', 'http_code' => 400, 'description' => ''], + ['code' => 'ModelCenter.NoDatasetOnline', 'message' => 'The status of the training dataset is not online.', 'http_code' => 400, 'description' => ''], + ['code' => 'ModelCenter.NoPermission', 'message' => 'You are not authorized to perform the operation.', 'http_code' => 403, 'description' => ''], + ['code' => 'ModelCenter.NotFoundConfig', 'message' => 'The configuration information of the model type is not found.', 'http_code' => 400, 'description' => ''], + ['code' => 'ModelCenter.OnlineModelLimit', 'message' => 'The maximum number of online models is exceeded.', 'http_code' => 403, 'description' => ''], + ['code' => 'ModelGroupNotFound', 'message' => 'The model group is not found.', 'http_code' => 400, 'description' => ''], + ['code' => 'ModelInferenceError', 'message' => 'Failed to obtain the model prediction result.', 'http_code' => 500, 'description' => 'Get model predict result error.'], + ['code' => 'ModelInferenceFailed', 'message' => 'The model inference result is null.', 'http_code' => 500, 'description' => ''], + ['code' => 'NotFoundUploadDataError', 'message' => 'No data set is created.', 'http_code' => 400, 'description' => ''], + ['code' => 'parameterError', 'message' => 'The parameter is invalid.', 'http_code' => 400, 'description' => ''], + ['code' => 'PermissionDeny', 'message' => 'No RAM permission.', 'http_code' => 400, 'description' => 'No permission to change the account'], + ['code' => 'postPaidArrearage', 'message' => 'The service is not opened or the account is overdue.', 'http_code' => 400, 'description' => ''], + ['code' => 'postpaidArrearageError', 'message' => 'You have an overdue payment.', 'http_code' => 400, 'description' => ''], + ['code' => 'predictContentLength', 'message' => 'The length of content exceeds the limit.', 'http_code' => 400, 'description' => ''], + ['code' => 'predictLimit', 'message' => 'The maximum number of submitted tasks is exceeded.', 'http_code' => 400, 'description' => ''], + ['code' => 'predictQpsLimit', 'message' => 'The maximum number of queries-per-second is exceeded.', 'http_code' => 403, 'description' => ''], + ['code' => 'predictTimeout', 'message' => 'model predict cost greater than 9000ms.', 'http_code' => 500, 'description' => ''], + ['code' => 'queryExceedMaxDuration', 'message' => 'The query data exceeds the upper limit.', 'http_code' => 400, 'description' => ''], + ['code' => 'ResourceNotFound', 'message' => 'The specified Model does not exist.', 'http_code' => 404, 'description' => 'The specified Model does not exist.'], + ['code' => 'ServiceUnavailable', 'message' => 'An error occurred while processing your request.', 'http_code' => 503, 'description' => 'An error occurred while processing your request.'], + ['code' => 'UnknownError', 'message' => 'A server error occurred while processing your request. Please try again later or contact customer support.', 'http_code' => 500, 'description' => 'A server error occurred while processing your request. Please try again later or contact customer support.'], + ], + 'changeSet' => [ [ - 'regionId' => 'cn-hangzhou', - 'endpoint' => 'nlp-automl.cn-hangzhou.aliyuncs.com', + 'apis' => [ + ['description' => 'Error codes changed', 'api' => 'GetPredictDoc'], + ['description' => 'Error codes changed', 'api' => 'PredictMTModelByDoc'], + ], + 'createdAt' => '2024-07-04T02:12:21.000Z', + 'description' => '', + ], + [ + 'apis' => [ + ['description' => 'Response parameters changed, Error codes changed', 'api' => 'AddMTInterveneWord'], + ], + 'createdAt' => '2022-03-07T07:23:44.000Z', + 'description' => '修改AddMTInterveneWord这个接口的返回的message和wordId的数据类型,其他接口从public修改为private', + ], + ], + 'flowControl' => [ + 'flowControlList' => [ + ['threshold' => '5', 'countWindow' => 1, 'regionId' => '*', 'api' => 'GetPredictDoc'], + ['threshold' => '5', 'countWindow' => 1, 'regionId' => '*', 'api' => 'PredictMTModelByDoc'], + ['threshold' => '30', 'countWindow' => 1, 'regionId' => '*', 'api' => 'AddMTInterveneWord'], ], + 'product' => ['code' => 'nlp', 'title' => 'nlp-automl'], ], ]; |
