You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
prompt=f"Below is a numbered list of the text in all the <p> tags on a web page:\n{pgraphs}\nSome of these lines may not be part of the main content of the page (e.g. footer text, ads, etc). Please list the line numbers that *are* part of the main content (i.e. the article's paragraphs) of the page. You can list consecutive line numbers as a range (e.g. 23-27) and separated by a comma."
94
-
response=claude.completions.create(
95
-
model="claude-2",
96
-
prompt=f"\n\nHuman: {prompt}\n\nAssistant: Here are the line numbers of the main content:",
95
+
prompt=HumanAssistantPrompt(
96
+
human_prompt=f"Below is a numbered list of the text in all the <p> tags on a web page:\n{pgraphs}\nSome of these lines may not be part of the main content of the page (e.g. footer text, ads, etc). Please list the line numbers that *are* part of the main content (i.e. the article's paragraphs) of the page. You can list consecutive line numbers as a range (e.g. 23-27) and separated by a comma.",
97
+
assistant_prompt="Here are the line numbers of the main content:",
# Claude: find search keywords that content focuses on
121
-
prompt=f"Below is content from a web article:\n{content}\nPlease list the keywords that best describe the content of the article. Format them so we can use them to query a search engine effectively."
122
-
response=claude.completions.create(
123
-
model="claude-2",
124
-
prompt=f"\n\nHuman: {prompt}\n\nAssistant: Here is a short search query that best matches the content of the article:",
126
+
prompt=HumanAssistantPrompt(
127
+
human_prompt=f"Below is content from a web article:\n{content}\nPlease list the keywords that best describe the content of the article. Format them so we can use them to query a search engine effectively.",
128
+
assistant_prompt="Here is a short search query that best matches the content of the article:",
# Claude: info mentioned in source that is not mentioned in target
152
-
prompt=f"Below is the TARGET article:\n{target}\n----------------\nBelow is the SOURCE article:\n{source}\n----------------\nIn a bullet point list, identify all facts, figures, or ideas that are mentioned in the SOURCE article but not in the TARGET article."
153
-
response=claude.completions.create(
154
-
model="claude-2",
155
-
prompt=f"\n\nHuman: {prompt}\n\nAssistant: Here is a list of claims in the SOURCE that are not in the TARGET:",
156
+
prompt=HumanAssistantPrompt(
157
+
human_prompt=f"Below is the TARGET article:\n{target}\n----------------\nBelow is the SOURCE article:\n{source}\n----------------\nIn a bullet point list, identify all facts, figures, or ideas that are mentioned in the SOURCE article but not in the TARGET article.",
158
+
assistant_prompt="Here is a list of claims in the SOURCE that are not in the TARGET:",
prompt=f"Below are notes from some SOURCE articles:\n{info}\n----------------\nBelow is the TARGET article:\n{target}\n----------------\nPlease rewrite the TARGET article to include the information from the SOURCE articles."
167
-
response=claude.completions.create(
168
-
model="claude-2",
169
-
prompt=f"\n\nHuman: {prompt}\n\nAssistant: Here is a rewritten version of the target article that incorporates relevant information from the source articles:",
172
+
prompt=HumanAssistantPrompt(
173
+
human_prompt=f"Below are notes from some SOURCE articles:\n{info}\n----------------\nBelow is the TARGET article:\n{target}\n----------------\nPlease rewrite the TARGET article to include the information from the SOURCE articles.",
174
+
assistant_prompt="Here is a rewritten version of the target article that incorporates relevant information from the source articles:",
0 commit comments