Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…into upgrade/typespec-0.58
  • Loading branch information
timotheeguerin committed Jul 17, 2024
2 parents d39d358 + 5274dcc commit 5f3e64b
Show file tree
Hide file tree
Showing 9 changed files with 114 additions and 83 deletions.
2 changes: 1 addition & 1 deletion specification/batch/Azure.Batch/common.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ alias FileResponseHeaders = {

@header("Content-Length")
@doc("The length of the file.")
contentLength: int64;
contentLength: string;

...BatchEtagResponseHeaders;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"properties": {
"creationTime": "2014-09-19T21:56:17.679195Z",
"lastModified": "2014-09-19T21:56:17.679195Z",
"contentLength": 1813,
"contentLength": "1813",
"contentType": "application/octet-stream"
}
},
Expand All @@ -37,7 +37,7 @@
"properties": {
"creationTime": "2014-09-19T21:56:17.5590855Z",
"lastModified": "2014-09-19T21:56:17.5590855Z",
"contentLength": 0,
"contentLength": "0",
"contentType": "application/octet-stream"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"properties": {
"creationTime": "2014-09-19T21:56:17.679195Z",
"lastModified": "2014-09-19T21:56:17.679195Z",
"contentLength": 1813,
"contentLength": "1813",
"contentType": "application/octet-stream"
}
},
Expand All @@ -32,7 +32,7 @@
"properties": {
"creationTime": "2014-09-19T21:56:17.5590855Z",
"lastModified": "2014-09-19T21:56:17.5590855Z",
"contentLength": 0,
"contentLength": "0",
"contentType": "application/octet-stream"
}
}
Expand Down
2 changes: 1 addition & 1 deletion specification/batch/Azure.Batch/models.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -1051,7 +1051,7 @@ model FileProperties {
lastModified: utcDateTime;

@doc("The length of the file.")
contentLength: int64;
contentLength: string;

@doc("The content type of the file.")
contentType?: string;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2570,8 +2570,7 @@
},
"headers": {
"Content-Length": {
"type": "integer",
"format": "int64",
"type": "string",
"description": "The length of the file."
},
"ETag": {
Expand Down Expand Up @@ -2815,8 +2814,7 @@
"description": "The request has succeeded.",
"headers": {
"Content-Length": {
"type": "integer",
"format": "int64",
"type": "string",
"description": "The length of the file."
},
"ETag": {
Expand Down Expand Up @@ -7031,8 +7029,7 @@
},
"headers": {
"Content-Length": {
"type": "integer",
"format": "int64",
"type": "string",
"description": "The length of the file."
},
"ETag": {
Expand Down Expand Up @@ -7276,8 +7273,7 @@
"description": "The request has succeeded.",
"headers": {
"Content-Length": {
"type": "integer",
"format": "int64",
"type": "string",
"description": "The length of the file."
},
"ETag": {
Expand Down Expand Up @@ -14502,8 +14498,7 @@
"description": "The time at which the file was last modified."
},
"contentLength": {
"type": "integer",
"format": "int64",
"type": "string",
"description": "The length of the file."
},
"contentType": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"properties": {
"creationTime": "2014-09-19T21:56:17.679195Z",
"lastModified": "2014-09-19T21:56:17.679195Z",
"contentLength": 1813,
"contentLength": "1813",
"contentType": "application/octet-stream"
}
},
Expand All @@ -37,7 +37,7 @@
"properties": {
"creationTime": "2014-09-19T21:56:17.5590855Z",
"lastModified": "2014-09-19T21:56:17.5590855Z",
"contentLength": 0,
"contentLength": "0",
"contentType": "application/octet-stream"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"properties": {
"creationTime": "2014-09-19T21:56:17.679195Z",
"lastModified": "2014-09-19T21:56:17.679195Z",
"contentLength": 1813,
"contentLength": "1813",
"contentType": "application/octet-stream"
}
},
Expand All @@ -32,7 +32,7 @@
"properties": {
"creationTime": "2014-09-19T21:56:17.5590855Z",
"lastModified": "2014-09-19T21:56:17.5590855Z",
"contentLength": 0,
"contentLength": "0",
"contentType": "application/octet-stream"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,7 @@
"type": "string"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/ChatCompletionsOptions"
}
"$ref": "#/parameters/GetChatCompletionsBody"
}
],
"responses": {
Expand Down Expand Up @@ -127,13 +121,7 @@
"type": "string"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/CompletionsOptions"
}
"$ref": "#/parameters/GetCompletionsBody"
}
],
"responses": {
Expand Down Expand Up @@ -179,13 +167,7 @@
"type": "string"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/EmbeddingsOptions"
}
"$ref": "#/parameters/GetEmbeddingsBody"
}
],
"responses": {
Expand Down Expand Up @@ -224,13 +206,7 @@
"$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/ImageGenerationOptions"
}
"$ref": "#/parameters/GetImageGenerationsBody"
}
],
"responses": {
Expand Down Expand Up @@ -1481,6 +1457,46 @@
"minLength": 1,
"x-ms-parameter-location": "method",
"x-ms-client-name": "apiVersion"
},
"GetChatCompletionsBody": {
"name": "body",
"in": "body",
"description": "The configuration information for a chat completions request.\nCompletions support a wide variety of tasks and generate text that continues from or \"completes\"\nprovided prompt data.",
"required": true,
"schema": {
"$ref": "#/definitions/ChatCompletionsOptions"
},
"x-ms-parameter-location": "method"
},
"GetCompletionsBody": {
"name": "body",
"in": "body",
"description": "The configuration information for a completions request.\nCompletions support a wide variety of tasks and generate text that continues from or \"completes\"\nprovided prompt data.",
"required": true,
"schema": {
"$ref": "#/definitions/CompletionsOptions"
},
"x-ms-parameter-location": "method"
},
"GetEmbeddingsBody": {
"name": "body",
"in": "body",
"description": "The configuration information for an embeddings request.\nEmbeddings measure the relatedness of text strings and are commonly used for search, clustering,\nrecommendations, and other similar scenarios.",
"required": true,
"schema": {
"$ref": "#/definitions/EmbeddingsOptions"
},
"x-ms-parameter-location": "method"
},
"GetImageGenerationsBody": {
"name": "body",
"in": "body",
"description": "Represents the request data used to generate images.",
"required": true,
"schema": {
"$ref": "#/definitions/ImageGenerationOptions"
},
"x-ms-parameter-location": "method"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,7 @@
"type": "string"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/SpeechGenerationOptions"
}
"$ref": "#/parameters/GenerateSpeechFromTextBody"
}
],
"responses": {
Expand Down Expand Up @@ -436,13 +430,7 @@
"type": "string"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/ChatCompletionsOptions"
}
"$ref": "#/parameters/GetChatCompletionsBody"
}
],
"responses": {
Expand Down Expand Up @@ -509,13 +497,7 @@
"type": "string"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/CompletionsOptions"
}
"$ref": "#/parameters/GetCompletionsBody"
}
],
"responses": {
Expand Down Expand Up @@ -561,13 +543,7 @@
"type": "string"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/EmbeddingsOptions"
}
"$ref": "#/parameters/GetEmbeddingsBody"
}
],
"responses": {
Expand Down Expand Up @@ -613,13 +589,7 @@
"type": "string"
},
{
"name": "body",
"in": "body",
"description": "Body parameter.",
"required": true,
"schema": {
"$ref": "#/definitions/ImageGenerationOptions"
}
"$ref": "#/parameters/GetImageGenerationsBody"
}
],
"responses": {
Expand Down Expand Up @@ -4808,6 +4778,56 @@
"minLength": 1,
"x-ms-parameter-location": "method",
"x-ms-client-name": "apiVersion"
},
"GenerateSpeechFromTextBody": {
"name": "body",
"in": "body",
"description": "A representation of the request options that control the behavior of a text-to-speech operation.",
"required": true,
"schema": {
"$ref": "#/definitions/SpeechGenerationOptions"
},
"x-ms-parameter-location": "method"
},
"GetChatCompletionsBody": {
"name": "body",
"in": "body",
"description": "The configuration information for a chat completions request.\nCompletions support a wide variety of tasks and generate text that continues from or \"completes\"\nprovided prompt data.",
"required": true,
"schema": {
"$ref": "#/definitions/ChatCompletionsOptions"
},
"x-ms-parameter-location": "method"
},
"GetCompletionsBody": {
"name": "body",
"in": "body",
"description": "The configuration information for a completions request.\nCompletions support a wide variety of tasks and generate text that continues from or \"completes\"\nprovided prompt data.",
"required": true,
"schema": {
"$ref": "#/definitions/CompletionsOptions"
},
"x-ms-parameter-location": "method"
},
"GetEmbeddingsBody": {
"name": "body",
"in": "body",
"description": "The configuration information for an embeddings request.\nEmbeddings measure the relatedness of text strings and are commonly used for search, clustering,\nrecommendations, and other similar scenarios.",
"required": true,
"schema": {
"$ref": "#/definitions/EmbeddingsOptions"
},
"x-ms-parameter-location": "method"
},
"GetImageGenerationsBody": {
"name": "body",
"in": "body",
"description": "Represents the request data used to generate images.",
"required": true,
"schema": {
"$ref": "#/definitions/ImageGenerationOptions"
},
"x-ms-parameter-location": "method"
}
}
}

0 comments on commit 5f3e64b

Please sign in to comment.