Spaces:
Runtime error
Runtime error
Update processing.py
Browse files- processing.py +5 -2
processing.py
CHANGED
@@ -114,7 +114,8 @@ def truncate_text(text: str, max_tokens: int = 16000) -> str:
|
|
114 |
return text
|
115 |
|
116 |
def process_input(input_text: str, llm):
|
117 |
-
general_task = load_text("tasks/
|
|
|
118 |
attachments_task = load_text("tasks/Attachments_task.txt")
|
119 |
bigfive_task = load_text("tasks/BigFive_task.txt")
|
120 |
personalities_task = load_text("tasks/Personalities_task.txt")
|
@@ -127,6 +128,8 @@ def process_input(input_text: str, llm):
|
|
127 |
|
128 |
prompt = f"""
|
129 |
{general_task}
|
|
|
|
|
130 |
Attachment Styles Task:
|
131 |
{attachments_task}
|
132 |
Big Five Traits Task:
|
@@ -136,7 +139,7 @@ Personality Disorders Task:
|
|
136 |
Retrieved Knowledge: {retrieved_knowledge}
|
137 |
Input: {truncated_input}
|
138 |
Please provide a comprehensive analysis for each speaker, including:
|
139 |
-
1. General
|
140 |
2. Attachment styles (use the format from the Attachment Styles Task)
|
141 |
3. Big Five traits (use the format from the Big Five Traits Task)
|
142 |
4. Personality disorders (use the format from the Personality Disorders Task)
|
|
|
114 |
return text
|
115 |
|
116 |
def process_input(input_text: str, llm):
|
117 |
+
general_task = load_text("tasks/General_tasks_description.txt")
|
118 |
+
general_impression_task = load_text("tasks/General_Impression_task.txt")
|
119 |
attachments_task = load_text("tasks/Attachments_task.txt")
|
120 |
bigfive_task = load_text("tasks/BigFive_task.txt")
|
121 |
personalities_task = load_text("tasks/Personalities_task.txt")
|
|
|
128 |
|
129 |
prompt = f"""
|
130 |
{general_task}
|
131 |
+
Genral Impression Task:
|
132 |
+
{general_impression_task}
|
133 |
Attachment Styles Task:
|
134 |
{attachments_task}
|
135 |
Big Five Traits Task:
|
|
|
139 |
Retrieved Knowledge: {retrieved_knowledge}
|
140 |
Input: {truncated_input}
|
141 |
Please provide a comprehensive analysis for each speaker, including:
|
142 |
+
1. General impressions (answer the sections provided in the General Impression Task.)
|
143 |
2. Attachment styles (use the format from the Attachment Styles Task)
|
144 |
3. Big Five traits (use the format from the Big Five Traits Task)
|
145 |
4. Personality disorders (use the format from the Personality Disorders Task)
|