Skip to content

Commit 42bea9b

Browse files
chunyu3JoshLove-msft
authored andcommitted
upgrade to typespec 0.43.0 syntax (Azure#23574)
Feels valid to me, thanks @chunyu3 !
1 parent d42552b commit 42bea9b

File tree

6 files changed

+16
-25
lines changed

6 files changed

+16
-25
lines changed

specification/cognitiveservices/AnomalyDetector/multivariate/models.tsp

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -103,10 +103,10 @@ model VariableState {
103103
effectiveCount?: int32;
104104

105105
@doc("First valid time stamp with a value of input data.")
106-
firstTimestamp?: zonedDateTime;
106+
firstTimestamp?: utcDateTime;
107107

108108
@doc("Last valid time stamp with a value of input data.")
109-
lastTimestamp?: zonedDateTime;
109+
lastTimestamp?: utcDateTime;
110110
}
111111

112112
@doc("""
@@ -133,19 +133,19 @@ variables for one anomalous time stamp in the response. The default is
133133
Start date/time of data for detection, which should
134134
be in ISO 8601 format.
135135
""")
136-
startTime: zonedDateTime;
136+
startTime: utcDateTime;
137137

138138
@doc("""
139139
End date/time of data for detection, which should
140140
be in ISO 8601 format.
141141
""")
142-
endTime: zonedDateTime;
142+
endTime: utcDateTime;
143143
}
144144

145145
@doc("Anomaly status and information.")
146146
model AnomalyState {
147147
@doc("Time stamp for this anomaly.")
148-
timestamp: zonedDateTime;
148+
timestamp: utcDateTime;
149149
@doc("Detailed value of this anomalous time stamp.")
150150
value?: AnomalyValue;
151151

@@ -218,13 +218,13 @@ is OneTable.
218218
Start date/time of training data, which should be
219219
in ISO 8601 format.
220220
""")
221-
startTime: zonedDateTime;
221+
startTime: utcDateTime;
222222

223223
@doc("""
224224
End date/time of training data, which should be
225225
in ISO 8601 format.
226226
""")
227-
endTime: zonedDateTime;
227+
endTime: utcDateTime;
228228

229229
@doc("""
230230
Display name of the model. Maximum length is 24
@@ -315,10 +315,10 @@ model AnomalyDetectionModel {
315315
modelId: string;
316316

317317
@doc("Date and time (UTC) when the model was created.")
318-
createdTime: zonedDateTime;
318+
createdTime: utcDateTime;
319319

320320
@doc("Date and time (UTC) when the model was last updated.")
321-
lastUpdatedTime: zonedDateTime;
321+
lastUpdatedTime: utcDateTime;
322322

323323
@doc("""
324324
Training result of a model, including its status, errors, and diagnostics

specification/cognitiveservices/AnomalyDetector/univariate/models.tsp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ and imputeMode is \"fixed\".
9999
@doc("Definition of input time series points.")
100100
model TimeSeriesPoint {
101101
@doc("Argument that indicates the time stamp of a data point (ISO8601 format).")
102-
timestamp?: zonedDateTime;
102+
timestamp?: utcDateTime;
103103

104104
@doc("Measurement of that point.")
105105
value: float32;

specification/cognitiveservices/HealthInsights/healthinsights.common/model.common.request.tsp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ model PatientDocument {
9999
language?: string;
100100

101101
@doc("The date and time when the document was created.")
102-
createdDateTime?: zonedDateTime;
102+
createdDateTime?: utcDateTime;
103103

104104
@doc("The content of the patient document.")
105105
content: DocumentContent;

specification/cognitiveservices/HealthInsights/healthinsights.common/model.common.response.tsp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,15 @@ alias Response = {
1313

1414
@doc("The date and time when the processing job was created.")
1515
@visibility("read")
16-
createdDateTime: zonedDateTime;
16+
createdDateTime: utcDateTime;
1717

1818
@doc("The date and time when the processing job is set to expire.")
1919
@visibility("read")
20-
expirationDateTime: zonedDateTime;
20+
expirationDateTime: utcDateTime;
2121

2222
@doc("The date and time when the processing job was last updated.")
2323
@visibility("read")
24-
lastUpdateDateTime: zonedDateTime;
24+
lastUpdateDateTime: utcDateTime;
2525

2626
@doc("The status of the processing job.")
2727
@visibility("read")

specification/cognitiveservices/OpenAI.Authoring/main.tsp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,6 @@ using TypeSpec.Versioning;
2020
}]>)
2121
@service({title: "Azure OpenAI API"})
2222
@versioned(Azure.OpenAI.Versions)
23-
@versionedDependency(
24-
[[Azure.OpenAI.Versions.v2022_06_01_preview, Azure.Core.Versions.v1_0_Preview_1]]
25-
)
2623
@server(
2724
"{endpoint}/openai",
2825
"API for managing and utilizing Azure Open AI endpoints",
@@ -38,5 +35,6 @@ https://westus.api.cognitive.microsoft.com).
3835
namespace Azure.OpenAI;
3936

4037
enum Versions {
38+
@useDependency(Azure.Core.Versions.v1_0_Preview_1)
4139
v2022_06_01_preview: "2022-06-01-preview",
4240
}

specification/cognitiveservices/OpenAI.Inference/main.tsp

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,18 +31,11 @@ https://westus.api.cognitive.microsoft.com).
3131
}
3232
)
3333
@versioned(ServiceApiVersions)
34-
@versionedDependency(
35-
[
36-
[
37-
ServiceApiVersions.v2022_12_01,
38-
Azure.Core.Versions.v1_0_Preview_1
39-
]
40-
]
41-
)
4234
@doc("Azure OpenAI APIs for completions and search")
4335
namespace Azure.OpenAI;
4436

4537
enum ServiceApiVersions {
38+
@useDependency(Azure.Core.Versions.v1_0_Preview_1)
4639
v2022_12_01: "2022-12-01",
4740
}
4841

0 commit comments

Comments
 (0)