Skip to content

Commit 979bc2b

Browse files
authored
Merge pull request Azure#6 from kseager/fix_error_issue
updates from removing error response
2 parents c416b62 + acb09a4 commit 979bc2b

15 files changed

Lines changed: 214 additions & 152 deletions

specification/machinelearningservices/AzureAI.Assets/routes.tsp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ interface Prompts {
147147
@path
148148
version: string;
149149
},
150-
Prompt | Foundations.ErrorResponse
150+
Prompt
151151
>;
152152

153153
#suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Waiting for bug fix: https://github.com/Azure/typespec-azure-pr/issues/3739."
@@ -169,7 +169,7 @@ interface Prompts {
169169
@body
170170
body: Prompt;
171171
},
172-
ResourceCreatedOrOkResponse<Prompt> | Foundations.ErrorResponse
172+
ResourceCreatedOrOkResponse<Prompt>
173173
>;
174174

175175
#suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Waiting for bug fix: https://github.com/Azure/typespec-azure-pr/issues/3739."
@@ -197,7 +197,7 @@ interface Prompts {
197197

198198
...StandardListQueryParameters;
199199
},
200-
PagedPrompt | Foundations.ErrorResponse
200+
PagedPrompt
201201
>;
202202

203203
#suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Need to define route."
@@ -211,7 +211,7 @@ interface Prompts {
211211
@path
212212
name: string;
213213
},
214-
Prompt | Foundations.ErrorResponse
214+
Prompt
215215
>;
216216

217217
#suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Need to define route."
@@ -225,7 +225,7 @@ interface Prompts {
225225
@path
226226
name: string;
227227
},
228-
VersionInfo | Foundations.ErrorResponse
228+
VersionInfo
229229
>;
230230

231231
#suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Need to define route."
@@ -236,6 +236,6 @@ interface Prompts {
236236
{
237237
...StandardListQueryParameters;
238238
},
239-
PagedPrompt | Foundations.ErrorResponse
239+
PagedPrompt
240240
>;
241241
}

specification/machinelearningservices/data-plane/Microsoft.MachineLearningServices/preview/2024-04-01-preview/azure-ai-assets.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@
7676
"/indexes": {
7777
"get": {
7878
"operationId": "Indexes_ListLatest",
79-
"description": "List the latest version of each index.",
79+
"description": "List the latest version of each index. Latest is defined by most recent created by date.",
8080
"parameters": [
8181
{
8282
"$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter"
@@ -124,7 +124,7 @@
124124
"/indexes/{name}": {
125125
"get": {
126126
"operationId": "Indexes_GetLatest",
127-
"description": "Get latest Index.",
127+
"description": "Get latest version of the Index. Latest is defined by most recent created by date.",
128128
"parameters": [
129129
{
130130
"$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter"
@@ -168,7 +168,7 @@
168168
"/indexes/{name}:getNextVersion": {
169169
"post": {
170170
"operationId": "Indexes_GetNextVersion",
171-
"description": "Get next Index version.",
171+
"description": "Get next Index version. This returns the latest version + 1.",
172172
"parameters": [
173173
{
174174
"$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter"
@@ -212,7 +212,7 @@
212212
"/indexes/{name}/versions": {
213213
"get": {
214214
"operationId": "Indexes_List",
215-
"description": "The most basic operation.",
215+
"description": "List the versions of an Index given the name.",
216216
"parameters": [
217217
{
218218
"$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter"
@@ -236,7 +236,7 @@
236236
{
237237
"name": "orderBy",
238238
"in": "query",
239-
"description": "Ordering of list: Please choose OrderBy value from ['createdtime', 'modifiedtime'].",
239+
"description": "Ordering of list: Please choose orderby value from ['createdAt', 'lastModifiedAt'].",
240240
"required": false,
241241
"type": "string"
242242
},
@@ -290,7 +290,7 @@
290290
"/indexes/{name}/versions/{version}": {
291291
"get": {
292292
"operationId": "Indexes_Get",
293-
"description": "Fetch a IndexVersion by name.",
293+
"description": "Get a specific version of an Index.",
294294
"parameters": [
295295
{
296296
"$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter"
@@ -415,7 +415,7 @@
415415
},
416416
"stage": {
417417
"type": "string",
418-
"description": "Update stage to 'Archive' for soft delete. Default is Development, which means the asset is under development.",
418+
"description": "Update stage to 'Archive' to archive the asset. Default is Development, which means the asset is under development.",
419419
"default": "Development"
420420
},
421421
"description": {
@@ -519,7 +519,7 @@
519519
},
520520
"stage": {
521521
"type": "string",
522-
"description": "Update stage to 'Archive' for soft delete. Default is Development, which means the asset is under development.",
522+
"description": "Update stage to 'Archive' to archive the asset. Default is Development, which means the asset is under development.",
523523
"default": "Development"
524524
},
525525
"description": {

specification/machinelearningservices/data-plane/Microsoft.MachineLearningServices/preview/2024-05-01-preview/azure-ai-assets.json

Lines changed: 48 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@
2121
"in": "path",
2222
"description": "Supported Azure-AI asset endpoints.",
2323
"required": true,
24-
"type": "string"
24+
"type": "string",
25+
"format": "uri",
26+
"x-ms-skip-url-encoding": true
2527
},
2628
{
2729
"name": "subscriptionId",
@@ -112,9 +114,6 @@
112114
"x-ms-examples": {
113115
"Indexes_ListLatest": {
114116
"$ref": "./examples/Indexes_ListLatest_MaximumSet_Gen.json"
115-
},
116-
"Indexes_ListLatest_MaximumSet_Gen": {
117-
"$ref": "./examples/Indexes_ListLatest_MaximumSet_Gen.json"
118117
}
119118
},
120119
"x-ms-pageable": {
@@ -136,8 +135,7 @@
136135
"description": "Name of the index.",
137136
"required": true,
138137
"type": "string",
139-
"pattern": "^[a-zA-Z0-9][a-zA-Z0-9-_]*$",
140-
"maxLength": 254
138+
"pattern": "^[a-zA-Z0-9][a-zA-Z0-9-_]{0,254}$"
141139
}
142140
],
143141
"responses": {
@@ -163,9 +161,6 @@
163161
"x-ms-examples": {
164162
"Indexes_GetLatest": {
165163
"$ref": "./examples/Indexes_GetLatest_MaximumSet_Gen.json"
166-
},
167-
"Indexes_GetLatest_MaximumSet_Gen": {
168-
"$ref": "./examples/Indexes_GetLatest_MaximumSet_Gen.json"
169164
}
170165
}
171166
}
@@ -210,9 +205,6 @@
210205
"x-ms-examples": {
211206
"Indexes_GetNextVersion": {
212207
"$ref": "./examples/Indexes_GetNextVersion_MaximumSet_Gen.json"
213-
},
214-
"Indexes_GetNextVersion_MaximumSet_Gen": {
215-
"$ref": "./examples/Indexes_GetNextVersion_MaximumSet_Gen.json"
216208
}
217209
}
218210
}
@@ -288,9 +280,6 @@
288280
"x-ms-examples": {
289281
"Indexes_List": {
290282
"$ref": "./examples/Indexes_List_MaximumSet_Gen.json"
291-
},
292-
"Indexes_List_MaximumSet_Gen": {
293-
"$ref": "./examples/Indexes_List_MaximumSet_Gen.json"
294283
}
295284
},
296285
"x-ms-pageable": {
@@ -345,9 +334,6 @@
345334
"x-ms-examples": {
346335
"Indexes_Get": {
347336
"$ref": "./examples/Indexes_Get_MaximumSet_Gen.json"
348-
},
349-
"Indexes_Get_MaximumSet_Gen": {
350-
"$ref": "./examples/Indexes_Get_MaximumSet_Gen.json"
351337
}
352338
}
353339
},
@@ -412,9 +398,6 @@
412398
"x-ms-examples": {
413399
"Indexes_CreateOrUpdate": {
414400
"$ref": "./examples/Indexes_CreateOrUpdate_MaximumSet_Gen.json"
415-
},
416-
"Indexes_CreateOrUpdate_MaximumSet_Gen": {
417-
"$ref": "./examples/Indexes_CreateOrUpdate_MaximumSet_Gen.json"
418401
}
419402
}
420403
}
@@ -460,9 +443,6 @@
460443
"x-ms-examples": {
461444
"Prompts_ListLatest": {
462445
"$ref": "./examples/Prompts_ListLatest_MaximumSet_Gen.json"
463-
},
464-
"Prompts_ListLatest_MaximumSet_Gen": {
465-
"$ref": "./examples/Prompts_ListLatest_MaximumSet_Gen.json"
466446
}
467447
},
468448
"x-ms-pageable": {
@@ -510,9 +490,6 @@
510490
"x-ms-examples": {
511491
"Prompts_GetLatest": {
512492
"$ref": "./examples/Prompts_GetLatest_MaximumSet_Gen.json"
513-
},
514-
"Prompts_GetLatest_MaximumSet_Gen": {
515-
"$ref": "./examples/Prompts_GetLatest_MaximumSet_Gen.json"
516493
}
517494
}
518495
}
@@ -557,9 +534,6 @@
557534
"x-ms-examples": {
558535
"Prompts_GetNextVersion": {
559536
"$ref": "./examples/Prompts_GetNextVersion_MaximumSet_Gen.json"
560-
},
561-
"Prompts_GetNextVersion_MaximumSet_Gen": {
562-
"$ref": "./examples/Prompts_GetNextVersion_MaximumSet_Gen.json"
563537
}
564538
}
565539
}
@@ -635,9 +609,6 @@
635609
"x-ms-examples": {
636610
"Prompts_List": {
637611
"$ref": "./examples/Prompts_List_MaximumSet_Gen.json"
638-
},
639-
"Prompts_List_MaximumSet_Gen": {
640-
"$ref": "./examples/Prompts_List_MaximumSet_Gen.json"
641612
}
642613
},
643614
"x-ms-pageable": {
@@ -692,9 +663,6 @@
692663
"x-ms-examples": {
693664
"Prompts_Get": {
694665
"$ref": "./examples/Prompts_Get_MaximumSet_Gen.json"
695-
},
696-
"Prompts_Get_MaximumSet_Gen": {
697-
"$ref": "./examples/Prompts_Get_MaximumSet_Gen.json"
698666
}
699667
}
700668
},
@@ -759,15 +727,55 @@
759727
"x-ms-examples": {
760728
"Prompts_CreateOrUpdate": {
761729
"$ref": "./examples/Prompts_CreateOrUpdate_MaximumSet_Gen.json"
762-
},
763-
"Prompts_CreateOrUpdate_MaximumSet_Gen": {
764-
"$ref": "./examples/Prompts_CreateOrUpdate_MaximumSet_Gen.json"
765730
}
766731
}
767732
}
768733
}
769734
},
770735
"definitions": {
736+
"AssetVersion": {
737+
"type": "object",
738+
"description": "AssetVersion Definition",
739+
"properties": {
740+
"id": {
741+
"type": "string",
742+
"description": "Fully qualified resource Id: azureml://workspace/{workspaceName}/indexes/{name}/versions/{version} of the index.",
743+
"readOnly": true
744+
},
745+
"stage": {
746+
"type": "string",
747+
"description": "Update stage to 'Archive' to archive the asset. Default is Development, which means the asset is under development.",
748+
"default": "Development"
749+
},
750+
"description": {
751+
"type": "string",
752+
"description": "Description information of the asset."
753+
},
754+
"systemData": {
755+
"$ref": "#/definitions/SystemData",
756+
"description": "Metadata containing createdBy and modifiedBy information.",
757+
"readOnly": true
758+
},
759+
"tags": {
760+
"type": "object",
761+
"description": "Asset's tags.",
762+
"additionalProperties": {
763+
"type": "string"
764+
}
765+
},
766+
"properties": {
767+
"type": "object",
768+
"description": "Asset's properties.",
769+
"additionalProperties": {
770+
"type": "string"
771+
}
772+
}
773+
},
774+
"required": [
775+
"id",
776+
"stage"
777+
]
778+
},
771779
"Azure.Core.Foundations.Error": {
772780
"type": "object",
773781
"description": "The error object.",
@@ -868,7 +876,6 @@
868876
},
869877
"storageUri": {
870878
"type": "string",
871-
"format": "uri",
872879
"description": "Default workspace blob storage Uri. Should work across storage types and auth scenarios."
873880
}
874881
},
@@ -961,8 +968,7 @@
961968
},
962969
"dataUri": {
963970
"type": "string",
964-
"format": "uri",
965-
"description": "Default workspace blob storage URI. Should work across storage types and auth scenarios."
971+
"description": "Default workspace blob storage Ui. Should work across storage types and auth scenarios."
966972
},
967973
"templatePath": {
968974
"type": "string",

0 commit comments

Comments
 (0)