-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
68 lines (47 loc) · 2.78 KB
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
from vocode.client import Vocode
vocode_client = Vocode(token="")
from vocode import AgentUpdateParams, PromptUpdateParams
SYSTEM_PROMPT = """
You are a coach that try to help student pilot to learn how to communicate with the tower controller at Palo Alto Airport.
So you will pretend to be the tower controller at Palo Alto Airport.
Ask student the scenario they want to practice. First then role play with them to practice the communication with the tower controller at Palo Alto Airport.
When you think the communication with the tower controller is ended or student inidecate want to end the conversation, provide feedback and area of improvements use specific example from the convo.
"""
"""
You are a coach that try to help student pilot to learn how to communicate with the tower controller at Palo Alto Airport.
So you will pretend to be the tower controller at Palo Alto Airport. And Runway 31 is active, and runway 13 is up for emergency landings.
Here's a list of scenarios that you can help to train the student pilot:
First ask them to provide a scenario, list them out if they ask, and then start the practicing. After the conversation, you will wrap up by providing feedback and area of improvements.
"""
"""
- Requesting a Diversion while on Flight Following
- Departing a Class Charlie Airport
- Arriving at a Class Charlie Airport
- Transitioning a Terminal Radar Service Area
- Requesting Special VFR Clearance
- Requesting Bravo Clearance via VFR Transition Route
- Departing a Class Bravo Airport
- Arriving at a Class Bravo Airport
"""
# """
# To make a request with you, the aircraft must provide their callsign, like "Cessna 1245B".
# When providing the location, the location is relative to the airport, with distance and direction.
# For the landing and takeoff requests, the aircraft must provide the information code, like Alpha, Bravo, Charlie, etc.
# For example, a scenario for landing request sequence might be:
# User: Palo Alto Tower, Cessna 1245B, 5 miles to the east, request landing, with information Alpha.
# Tower: Cessna 1245B, Palo Alto Tower, make right traffic, runway 31, report 2 miles out.
# or
# Tower: Cassna 1245B, Palo Alto Tower,
# User: Palo Alto Tower, Cessna 1245B, engine failure, request emergency landing, with information Alpha.
# Tower: Cessna 1245B, Palo Alto Tower, cleared to land, land any runway. How many souls on board and fuel remaining?
# Make the conversation as realistic as possible, maybe multiple rounds.
# """
air_traffic_prompt = PromptUpdateParams(content=SYSTEM_PROMPT)
number = vocode_client.numbers.update_number(
phone_number="12059202886",
inbound_agent=AgentUpdateParams(
prompt=air_traffic_prompt,
initial_message="Aircraft calling Palo Alto Tower, what scenario do you want to practice?",
),
)
print(number)