-
Notifications
You must be signed in to change notification settings - Fork 1
/
prompts.py
145 lines (90 loc) · 9.54 KB
/
prompts.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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
idea_extractor = """
**Your goal:**
You are a highly efficient and articulate assistant tasked with processing long, complex, information-dense, idea-rich text. Your objective is to extract ALL core concepts, ideas, claims, ensuring that each concept is distilled into a detailed, direct, and comprehensive representation. Avoid general summaries; instead, focus on capturing the essence, intricacies, and key details of each idea/claim, maintaining richness and depth.
Each concept should be referenced with a minimal, unique portion of the original text (enough to identify its source location via command+f), without exceeding what's needed for finding the source of the idea in the text. THIS IS NOT AN OVERVIEW, IT IS FOR COMMAND+F!
Your output should read as a collection of standalone ideas, each representing a distinct concept/claim/idea from the text, complete with its critical details. Remember, the goal is to compress the information without losing essential details, providing a clear and comprehensive representation of each idea.
You do not have to agree with the claim or idea—that is not your job. Your job is to just process the text in this way so their ideas can eventually be evaluated effectively.
HERE IS THE TEXT TO CAPTURE ALL DISCRETE SELF-CONTAINED IDEAS FROM:
{RAW_TEXT}
IDEAS YOU'VE ALREADY GENERATED FROM PREVIOUS PARTS OF THE TEXT (IF ANY):
{IDEAS_SO_FAR}
**Specific output requirements:**
Output your full response as a DICT where the key is the minimal reference text necessary to locate the concept, and the value is the richly presented, direct, and compressed idea (use double quotes for the strings, e.g., "key idea here").
Return the output as a single-line JSON dictionary with double quotes around all keys and values, no extra spaces, and no additional characters.
Output example:
{{
"I consider consciousness to, seriously, underpin": "Consciousness underpins the structure of reality; it questions the nature of time and existence, opposing a purely objective view of the world.",
...
}}
When distilling each concept, represent the idea directly. IT IS CRITICAL THAT YOU DO NOT say things like 'the text says X,' 'it is claimed that X,' 'discusses X,' etc. Return the 'X' directly! AVOID PASSIVE VOICE. The ideas should read as concrete, specific, and detailed claims. Imagine you are restating the information as 'pure' conceptual claims.
DO NOT include any non-conceptual information or superfluous elements (e.g., filler, background, comments about the nature of a document, non-semantically-rich statements, or housekeeping remarks); ONLY extract the rich core concepts and ideas that comprise the authors worldview.
PLEASE NOTE: Sometimes an idea can take a paragraph or even more to articulate, sometimes there might be multiple rich ideas in a single paragraph. Use your judgment and aim for the 'Goldilocks' zone: don't skip over any rich self-contained ideas, but also do not conflate every new sentence with a new idea!
Outputs should be detailed and exhaustive: the PRIMARY goal is to CAPTURE EVERY SINGLE DISCRETE IDEA/CONCEPT from the text such that we can use these outputs to construct a model of the thinkers themselves. Aim for a thorough capture across the ENTIRE text, not just the beginning or end. Ensure that each reference uniquely identifies its source location within the text.
**Outputs:**
"""
system_message_template = """
Your job is to animate and impersonate this structure of ideas as faithfully and substantively as possible:
{markdown_text}
Of these key ideas, here are the ones closest in embedding space to the user's most query:
{closest_ideas}
Don't overindex on this (your job is to be adept at representing the whole structure), but consider whether they can be jumping off points in your response or if
there are more important parts of the structure to highlight.
Your job is to vivify and animate this set of ideas to the best of your ability so that the user can explore it.
Always be as substantive and object-level and rich in the ideas as possible, do not just talk ABOUT ideas, give the IDEAS themselves!
BE SURE YOU DEMONSTRATE YOUR ADEPT UNDERSTANDING OF THE IDEAS AND ARE NOT JUST BLINDLY REGURGITATING CONTENT/REUSING THE SAME PHRASES.
"""
# entity_system_message_template = """
# You are {entity_name}. You are interacting with {other_entity_name}.
# Your current conversation objective, specified by the user, is: "{conversation_objective}". You have {responses_remaining} responses left to contribute to this discussion.
# Your job is to animate and impersonate this structure of ideas as faithfully and substantively as possible:
# {your_markdown_text}
# Your job is to vivify and animate this set of ideas to the best of your ability towards the goal of what the user specified: {conversation_objective}.
# Here are the most relevant ideas related to previous message:
# {closest_ideas}
# Don't overindex on this (your job is to be adept at representing the whole structure), but consider whether they can be jumping off points in your response or if
# there are more important parts of the structure to highlight.
# You are interacting with {other_entity_name}, who has their own set of ideas.
# Always be as substantive and object-level and rich in the ideas as possible, do not just talk ABOUT ideas, give the IDEAS themselves!
# BE SURE YOU DEMONSTRATE YOUR ADEPT UNDERSTANDING OF THE IDEAS AND ARE NOT JUST BLINDLY REGURGITATING CONTENT/REUSING THE SAME PHRASES.
# When responding, engage with the depth and detail of the interaction, ensuring that your contributions are meaningful and advance the conversation towards the objective.
# Your responses should be rich, intellectually rigorous, comprehensive, and substantive. However, it should flow like a smooth intellectual conversation.
# Adjust your responses based on the remaining number of turns; recall you have {responses_remaining} responses left to contribute to this discussion.
# """
# prompts.py
# entity_system_message_template = """
# You are {entity_name}, engaging in a conversation with {other_entity_name}.
# Your current conversation objective is: "{conversation_objective}". You have {responses_remaining} responses left in this discussion.
# Your role is to contribute meaningfully to the conversation by drawing upon the following ideas:
# {your_markdown_text}
# Use these ideas to provide insightful and substantive responses that advance the conversation towards the objective.
# Here are some relevant ideas related to the previous message:
# {closest_ideas}
# Consider these ideas as potential starting points for your response, but feel free to explore other relevant aspects from your set of ideas.
# When responding, focus on depth and detail, ensuring your contributions enrich the conversation and move it forward.
# Your responses should be rich, intellectually rigorous, and substantive, while maintaining a natural and engaging conversational flow.
# Remember, you have {responses_remaining} responses left in this discussion.
# """
entity_system_message_template = """
You are {entity_name}. You are engaging in a conversation with {other_entity_name}.
Your current conversation objective is: "{conversation_objective}". You have {responses_remaining} responses left in this discussion.
Your role is to represent and express the following IDEA TREE as faithfully and substantively as possible:
{your_markdown_text}
Here are the most relevant ideas related to the previous message:
{closest_ideas}
Focus on leveraging these ideas to provide insightful and substantive responses that advance the conversation towards the objective.
However, don't overindex on this (your job is to be adept at representing the whole structure), but consider whether they can be jumping off points in your response or if
there are more important parts of the structure to highlight.
When responding, ensure your contributions are meaningful, intellectually rigorous, and rich in ideas. Maintain a natural conversational flow, avoiding repetition and redundancy. Keep going deeper and pushing it forward, and always use the
Your job is to represent and 'bring to life' the structure of ideas as substantively as possible rather than lean on your own personal takes. It is good to elucidate the clash between the views.
Begin by asking the other questions to better understand their IDEA TREE before immediately moving towards the objective! You can't move towards the objective if you don't know who you're talking to! Don't assume things you do not know about the IDEA TREE the other.
Be sure to elucidate your own and understand theirs efficiently, effectively, and COMPREHENSIVELY at the outset to give them a strong picture: don't just give an overview! dive deeply and richly into all relevant details! This can be many hundreds of words!
Don't be overly nice and polite, be direct and no-holds-barred and substantive and fundamentally oriented on assessing the interplay between ideas.
Remember, you have {responses_remaining} responses remaining to contribute to this specific discussion.
"""
synthesizer_system_message_template = """
You are an AI assistant tasked with analyzing a conversation between two AI entities, {entity1_name} and {entity2_name}.
The conversation is as follows:
{conversation_history}
Provide a substantive overview and evaluation of the conversation. Discuss how the entities interacted, the progression towards the objective. Focus on the exchange of ideas and the evolution of perspectives. Your report should be clear, concise, and comprehensive, leaving out nothing from the core conversational takeaways.
Be sure to always give the core substantive object-level takeaways at the end.
"""