Watch the explanation. Practice the skill.
Provider-neutral generation APIs
Connect different model services without hiding their differences.
Captions appear here during playback.
Provider-neutral generation APIs
Connect different model services without hiding their differences.
Video playback is unavailable. Read the descriptive transcript below, go directly to practice, or open the video file.
Source-based teaching example · Fictional data · Reviewed 2026-10-03. Microsoft Mark · locally synthesized. On a small screen, use fullscreen for diagram details or read the transcript.
Read the descriptive transcript
0:00 · What you will learn
Connect different model services without hiding their differences.
What appears on screen
Connect different model services without hiding their differences.
0:06 · The idea
Use a shared result format, but preserve status and capability differences. An adapter should translate fields, not invent missing information. Test failures as carefully as normal answers.
What appears on screen
Use a shared result format, but preserve status and capability differences. An adapter should translate fields, not invent missing information. Test failures as carefully as normal answers.
0:22 · One useful term
Adapter. Code that translates one service’s interface into the interface your application expects.
What appears on screen
Code that translates one service’s interface into the interface your application expects.
0:32 · A worked example
Two mock providers use different field names and refusal signals. Their adapters produce a common result. Refusal, partial output and unknown usage stay explicit instead of becoming empty successful answers.
What appears on screen
Two mock providers use different field names and refusal signals. Their adapters produce a common result. Refusal, partial output and unknown usage stay explicit instead of becoming empty successful answers.
0:49 · Your turn to think
Is missing usage the same as zero usage? Pause and decide before continuing.
What appears on screen
Is missing usage the same as zero usage? Pause the video if you need more time.
1:05 · Why this answer works
No. Keep it unknown. The offline tests show adapter rules, not actual provider or network behavior.
What appears on screen
No. Keep it unknown. The offline tests show adapter rules, not actual provider or network behavior.
1:16 · Check 1
Check declared capabilities.
What appears on screen
Check declared capabilities.
1:21 · Check 2
Keep refusal and partial states visible.
What appears on screen
Keep refusal and partial states visible.
1:26 · Check 3
Reject unknown status values.
What appears on screen
Reject unknown status values.
1:32 · Now try a different case
Open the lesson and try its different practice case. Use every check in the full task. Watching alone does not mark the lesson complete.
What appears on screen
Open the lesson Try the new case Check and revise The full task and its requirements are in the linked lesson.
Watching explains the example. Complete the lesson practice to check what you can do. Explore all visual lessons →