Skip to content

Commit aa6c32f

Browse files
committed
feedback service tutorials
1 parent 1580cc0 commit aa6c32f

51 files changed

Lines changed: 3916 additions & 0 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 198 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,198 @@
1+
info:
2+
name: Call orchestration service
3+
type: http
4+
seq: 10
5+
6+
http:
7+
method: POST
8+
url: "{{deploymentUrl}}/v2/completion"
9+
headers:
10+
- name: Authorization
11+
value: Bearer {{access_token}}
12+
- name: AI-Resource-Group
13+
value: "{{resource_group}}"
14+
- name: Content-Type
15+
value: application/json
16+
- name: ai-inference-observability-persistence-mode
17+
value: full
18+
- name: ai-inference-observability-labels
19+
value: ext.ai.sap.com/test=true
20+
- name: ai-object-store-secret-name
21+
value: inference-observability
22+
body:
23+
type: json
24+
data: |-
25+
{
26+
"config": {
27+
"modules": {
28+
"prompt_templating": {
29+
"prompt": {
30+
"template": [
31+
{
32+
"role": "user",
33+
"content": "What is the speed of light?"
34+
}
35+
]
36+
},
37+
"model": {
38+
"name": "gpt-5-mini",
39+
"version": "latest",
40+
"params": {
41+
"max_completion_tokens": 3000
42+
}
43+
}
44+
}
45+
}
46+
}
47+
}
48+
auth: inherit
49+
50+
runtime:
51+
scripts:
52+
- type: after-response
53+
code: |-
54+
if ( res.status == 200 ){
55+
bru.setEnvVar("inferenceId", res.getHeader("ai-inference-id"));
56+
}
57+
58+
settings:
59+
encodeUrl: true
60+
timeout: 0
61+
followRedirects: true
62+
maxRedirects: 5
63+
64+
examples:
65+
- name: example
66+
request:
67+
url: "{{deploymentUrl}}/v2/completion"
68+
method: POST
69+
headers:
70+
- name: Authorization
71+
value: Bearer {{access_token}}
72+
- name: AI-Resource-Group
73+
value: "{{resource-group}}"
74+
- name: Content-Type
75+
value: application/json
76+
- name: ai-inference-observability-persistence-mode
77+
value: full
78+
- name: ai-inference-observability-labels
79+
value: ext.ai.sap.com/test=true
80+
disabled: true
81+
- name: ai-object-store-secret-name
82+
value: inference-observability
83+
body:
84+
type: json
85+
data: |-
86+
{
87+
"config": {
88+
"modules": {
89+
"prompt_templating": {
90+
"prompt": {
91+
"template": [
92+
{
93+
"role": "user",
94+
"content": "What is the speed of light?"
95+
}
96+
]
97+
},
98+
"model": {
99+
"name": "gpt-5-mini",
100+
"version": "latest",
101+
"params": {
102+
"max_completion_tokens": 3000
103+
}
104+
}
105+
}
106+
}
107+
}
108+
}
109+
response:
110+
status: 200
111+
statusText: OK
112+
headers:
113+
- name: date
114+
value: Thu, 26 Mar 2026 13:11:20 GMT
115+
- name: content-type
116+
value: application/json
117+
- name: ai-inference-id
118+
value: 493452f3-6f81-4300-9bb7-52a58e6dcf99
119+
- name: content-length
120+
value: "1996"
121+
- name: x-upstream-service-time
122+
value: "11624"
123+
body:
124+
type: json
125+
data: |-
126+
{
127+
"request_id": "28ed9d67-2497-90f1-bd6d-28eb3532102f",
128+
"intermediate_results": {
129+
"templating": [
130+
{
131+
"content": "What is the speed of light?",
132+
"role": "user"
133+
}
134+
],
135+
"llm": {
136+
"id": "chatcmpl-DNemX4kXudVcEIEjq2IIxqBNmi0GB",
137+
"object": "chat.completion",
138+
"created": 1774530681,
139+
"model": "gpt-5-mini-2025-08-07",
140+
"choices": [
141+
{
142+
"index": 0,
143+
"message": {
144+
"role": "assistant",
145+
"content": "The speed of light in vacuum (symbol c) is exactly 299,792,458 metres per second by definition of the metre. That is about 3.00 × 10^8 m/s, ≈186,282 miles per second, or ≈1.079×10^9 km/h. \n\nNote: in materials (air, glass, water, etc.) light travels more slowly; c is the maximum speed at which information and causal effects can propagate according to relativity."
146+
},
147+
"finish_reason": "stop"
148+
}
149+
],
150+
"usage": {
151+
"completion_tokens": 367,
152+
"prompt_tokens": 13,
153+
"total_tokens": 380,
154+
"prompt_tokens_details": {
155+
"audio_tokens": 0,
156+
"cached_tokens": 0
157+
},
158+
"completion_tokens_details": {
159+
"accepted_prediction_tokens": 0,
160+
"audio_tokens": 0,
161+
"reasoning_tokens": 256,
162+
"rejected_prediction_tokens": 0
163+
}
164+
}
165+
}
166+
},
167+
"final_result": {
168+
"id": "chatcmpl-DNemX4kXudVcEIEjq2IIxqBNmi0GB",
169+
"object": "chat.completion",
170+
"created": 1774530681,
171+
"model": "gpt-5-mini-2025-08-07",
172+
"choices": [
173+
{
174+
"index": 0,
175+
"message": {
176+
"role": "assistant",
177+
"content": "The speed of light in vacuum (symbol c) is exactly 299,792,458 metres per second by definition of the metre. That is about 3.00 × 10^8 m/s, ≈186,282 miles per second, or ≈1.079×10^9 km/h. \n\nNote: in materials (air, glass, water, etc.) light travels more slowly; c is the maximum speed at which information and causal effects can propagate according to relativity."
178+
},
179+
"finish_reason": "stop"
180+
}
181+
],
182+
"usage": {
183+
"completion_tokens": 367,
184+
"prompt_tokens": 13,
185+
"total_tokens": 380,
186+
"prompt_tokens_details": {
187+
"audio_tokens": 0,
188+
"cached_tokens": 0
189+
},
190+
"completion_tokens_details": {
191+
"accepted_prediction_tokens": 0,
192+
"audio_tokens": 0,
193+
"reasoning_tokens": 256,
194+
"rejected_prediction_tokens": 0
195+
}
196+
}
197+
}
198+
}
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
info:
2+
name: Check deployment status
3+
type: http
4+
seq: 9
5+
6+
http:
7+
method: GET
8+
url: "{{AI_API}}/lm/deployments/{{deploymentId}}"
9+
headers:
10+
- name: Authorization
11+
value: Bearer {{access_token}}
12+
- name: AI-Resource-Group
13+
value: "{{resource-group}}"
14+
- name: Content-Type
15+
value: application/json
16+
auth: inherit
17+
18+
runtime:
19+
scripts:
20+
- type: after-response
21+
code: |-
22+
if ( res.status === 200 ){
23+
let data = res.getBody();
24+
if ( data.status == "RUNNING" ){
25+
bru.setEnvVar("deploymentUrl", data.deploymentUrl);
26+
}
27+
}
28+
29+
settings:
30+
encodeUrl: true
31+
timeout: 0
32+
followRedirects: true
33+
maxRedirects: 5
34+
35+
examples:
36+
- name: example
37+
request:
38+
url: "{{AI_API}}/lm/deployments/{{deploymentId}}"
39+
method: GET
40+
headers:
41+
- name: Authorization
42+
value: Bearer {{access_token}}
43+
- name: AI-Resource-Group
44+
value: "{{resource-group}}"
45+
- name: Content-Type
46+
value: application/json
47+
response:
48+
status: 200
49+
statusText: OK
50+
headers:
51+
- name: date
52+
value: Thu, 26 Mar 2026 12:21:25 GMT
53+
- name: content-type
54+
value: application/json
55+
- name: content-length
56+
value: "722"
57+
- name: access-control-allow-origin
58+
value: "null"
59+
- name: access-control-allow-credentials
60+
value: "false"
61+
- name: cache-control
62+
value: no-store, must-revalidate
63+
- name: x-upstream-service-time
64+
value: "41"
65+
body:
66+
type: json
67+
data: |-
68+
{
69+
"id": "db664f32e41f2694",
70+
"createdAt": "2026-03-26T11:44:12Z",
71+
"modifiedAt": "2026-03-26T11:44:12Z",
72+
"status": "RUNNING",
73+
"details": {
74+
"scaling": {
75+
"backendDetails": {},
76+
"backend_details": {}
77+
},
78+
"resources": {
79+
"backendDetails": {},
80+
"backend_details": {}
81+
}
82+
},
83+
"scenarioId": "orchestration",
84+
"configurationId": "a660a213-5933-4b2c-872b-c1dbb3e771c2",
85+
"latestRunningConfigurationId": "a660a213-5933-4b2c-872b-c1dbb3e771c2",
86+
"lastOperation": "CREATE",
87+
"targetStatus": "RUNNING",
88+
"submissionTime": "2026-03-26T11:45:18Z",
89+
"startTime": "2026-03-26T11:46:33Z",
90+
"configurationName": "orchestration-config",
91+
"deploymentUrl": "https://api.ai.internalprod.eu-central-1.aws.ml.hana.ondemand.com/v2/inference/deployments/db664f32e41f2694"
92+
}
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
info:
2+
name: Check resource group status
3+
type: http
4+
seq: 3
5+
6+
http:
7+
method: GET
8+
url: "{{AI_API}}/admin/resourceGroups/{{resource-group}}"
9+
headers:
10+
- name: Authorization
11+
value: Bearer {{access_token}}
12+
- name: Content-Type
13+
value: application/json
14+
auth: inherit
15+
16+
settings:
17+
encodeUrl: true
18+
timeout: 0
19+
followRedirects: true
20+
maxRedirects: 5
21+
22+
examples:
23+
- name: example
24+
request:
25+
url: "{{AI_API}}/admin/resourceGroups/{{resource-group}}"
26+
method: GET
27+
headers:
28+
- name: Authorization
29+
value: Bearer {{access_token}}
30+
- name: Content-Type
31+
value: application/json
32+
response:
33+
status: 200
34+
statusText: OK
35+
headers:
36+
- name: date
37+
value: Thu, 26 Mar 2026 11:41:42 GMT
38+
- name: content-type
39+
value: application/json
40+
- name: content-length
41+
value: "281"
42+
- name: x-upstream-service-time
43+
value: "53"
44+
body:
45+
type: json
46+
data: |-
47+
{
48+
"resourceGroupId": "test-inference-obs",
49+
"status": "PROVISIONED",
50+
"tenantId": "882ce703-31d9-4330-927c-d5e427ebfb87",
51+
"zoneId": "882ce703-31d9-4330-927c-d5e427ebfb87",
52+
"labels": [],
53+
"statusMessage": "All onboarding steps are completed.",
54+
"createdAt": "2026-03-26T11:41:25+00:00"
55+
}

0 commit comments

Comments
 (0)