Skip to content

Glossary: AI App Interfaces

Generator

Also written: generators, yield

A Python function that uses `yield` to hand out values one at a time instead of returning everything at once. Streaming model functions are generators, which is how words can appear as they are produced.

Where the book teaches it

Related terms

Streamingyield fromst.write_stream