def _stream_requests(sample, language_code=None, max_alternatives=None, profanity_filter=None, speech_context=None, single_utterance=None, interim_results=None):
 config_request = _make_streaming_request(sample, language_code=language_code, max_alternatives=max_alternatives, profanity_filter=profanity_filter, speech_context=SpeechContext(phrases=speech_context), single_utterance=single_utterance, interim_results=interim_results)
 (yield config_request)
 while True:
  data = sample.stream.read(sample.chunk_size)
  if (not data):
   break
  (yield StreamingRecognizeRequest(audio_content=data))

def _stream_requests ( sample , language_code = None , max_alternatives = None , profanity_filter = None , speech_context = None , single_utterance = None , interim_results = None ) : config_request = _make_streaming_request ( sample , language_code = language_code , max_alternatives = max_alternatives , profanity_filter = profanity_filter , speech_context = SpeechContext ( phrases = speech_context ) , single_utterance = single_utterance , interim_results = interim_results ) ( yield config_request ) while True : data = sample . stream . read ( sample . chunk_size ) if ( not data ) : break ( yield StreamingRecognizeRequest ( audio_content = data ) )
generate stream of requests from sample .