Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -42,16 +42,12 @@ def summarize(file, n_words):
|
|
42 |
chunks = text_splitter.create_documents([text])
|
43 |
n_words = n_words
|
44 |
template = '''
|
45 |
-
Your task is to summarize a long text into a
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
Before writing your final summary, first break down the key points of the text in a <scratchpad>. Identify the most important information that should be included in a summary of the specified length.
|
50 |
-
|
51 |
-
Then, write a summary that captures the core ideas and key details of the text. Start with an introductory sentence and then concisely summarize the main points in a logical order. Make sure to stay within the {{N_WORDS}} word limit.
|
52 |
-
|
53 |
Here is the long text to summarize:
|
54 |
-
|
|
|
55 |
{TEXT}
|
56 |
'''
|
57 |
prompt = PromptTemplate(
|
|
|
42 |
chunks = text_splitter.create_documents([text])
|
43 |
n_words = n_words
|
44 |
template = '''
|
45 |
+
Your task is to summarize a long text into a detailed summary.
|
46 |
+
Start with an introductory sentence and then summarize the main points in a logical order, ensuring the summary is very detailed.
|
47 |
+
|
|
|
|
|
|
|
|
|
|
|
48 |
Here is the long text to summarize:
|
49 |
+
|
50 |
+
Text:
|
51 |
{TEXT}
|
52 |
'''
|
53 |
prompt = PromptTemplate(
|