@@ -118,12 +118,18 @@ def webrtc(
118118 ),
119119 deployment : str = typer .Option ("gpt-realtime" , "--deployment" , help = "Deployment name" ),
120120 voice : str = typer .Option ("verse" , "--voice" , help = "Voice name" ),
121+ instructions : str = typer .Option (
122+ "You are a helpful AI assistant responding in natural, engaging language." ,
123+ "--instructions" ,
124+ "-i" ,
125+ help = "Initial assistant instructions for the realtime session" ,
126+ ),
121127):
122128 """
123129 Render the realtime_webrtc HTML template with provided parameters and serve it as a static site.
124130
125131 The template is a Jinja2 template and will receive the following variables:
126- - WEBRTC_URL, SESSIONS_URL, API_KEY, DEPLOYMENT, VOICE
132+ - WEBRTC_URL, SESSIONS_URL, API_KEY, DEPLOYMENT, VOICE, INSTRUCTIONS
127133 """
128134 settings = Settings ()
129135 api_key = settings .azure_openai_api_key
@@ -146,6 +152,7 @@ def webrtc(
146152 API_KEY = json .dumps (api_key ),
147153 DEPLOYMENT = json .dumps (deployment ),
148154 VOICE = json .dumps (voice ),
155+ INSTRUCTIONS = json .dumps (instructions ),
149156 )
150157
151158 tempdir = tempfile .TemporaryDirectory ()
0 commit comments