Untitled
unknown
plain_text
a year ago
2.0 kB
6
Indexable
meeting_invite_prompt = PromptTemplate(
template="""
You are a system that parses a user's meeting request: {query}
You must return valid response that replies to the users meeting request which collates all the below factors.:
1. "data_issues"
2. "meeting_start"
3. "meeting_end"
4. "attendees"
Requirements:
- "data_issues":
- If there's ambiguity about which user to add in the scenario of two or more similar names in the user_to_email map: {user_to_email}), provide a clarification message here.
- If there exist only a singular entry most similar to the attendee add that to the attendee list(as an example
the user said 'john' needs to be added but 'john_doe' key exists and we have no other 'john' entries then add
'john_doe" email to attendees).
- If a requested user is not found in user_to_email, provide an appropriate error message here.
- If there are no issues, do not add this factor as part of the response.
- If the meeting_start and "meeting_end" cannot be inferred from the {query} and {current_time} then ask clarifying questioning like
which timezone,date,meeting duration etc
- "meeting_start" / "meeting_end":
-The current timestamp is {current_time} this is the current date and time in UTC with timezone information attached.
-Based on the user query calculate the appropriate meeting_start and meeting_end time stamp
by converting the requested meeting time into meeting_start and meeting_end time stamp given {query} {current_time}
- The meeting_start and meeting_end must be in the same format as current_time: {current_time} format.
- "attendees":
- A list of attendee email addresses.
-If we have "data_issues" ignore the other factors and give only the response relevant to "data_issues".
""",
input_variables=["query", "user_to_email"],
)
chain = meeting_invite_prompt | llm | parserEditor is loading...
Leave a Comment