Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change Prompt to Avoid Incorrect Information for PubMed Central Sources #959

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions gpt_researcher/prompts.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,31 @@ def generate_report_prompt(
Additionally, you MUST include hyperlinks to the relevant URLs wherever they are referenced in the report:

eg: Author, A. A. (Year, Month Date). Title of web page. Website Name. [url website](url)

# SPECIAL INSTRUCTIONS FOR PMC
PubMed Central (PMC) references (i.e., those with https://www.ncbi.nlm.nih.gov/pmc URLs) are different and must only use information included in the Information Source and Title. Example:

Source: https://www.ncbi.nlm.nih.gov/pmc/articles/PMC11305834/\nTitle: Calcium plays an essential role in early-stage dendrite injury detection and regeneration - PMC\nContent: While our study ...

should result in a reference:

## CORRECT EXAMPLE
Calcium plays an essential role in early-stage dendrite injury detection and regeneration. [PMC11305834](https://www.ncbi.nlm.nih.gov/pmc/articles/PMC11305834)

## INCORRECT EXAMPLE; This adds unnecessary information
Calcium plays an essential role in early-stage dendrite injury detection and regeneration. (n.d.). PubMed Central (PMC). https://www.ncbi.nlm.nih.gov/pmc/articles/PMC11305834

Do NOT refer to specific authors in cases where the Source includes a NLM PMC URL.

Hyperlinks in the report for PMC references must take the form:

## CORRECT EXAMPLE
Excessive calcium intake can lead to the formation of kidney stones, [PMC11305834](https://www.ncbi.nlm.nih.gov/pmc/articles/PMC11305834).

## INCORRECT EXAMPLE; titles in the links too long
https://www.ncbi.nlm.nih.gov/pmc/articles/PMC11305834

Calcium plays an essential role in early-stage dendrite injury detection and regeneration, [Calcium plays an essential role in early-stage dendrite injury detection and regeneration](https://www.ncbi.nlm.nih.gov/pmc/articles/PMC11305834).
"""
else:
reference_prompt = f"""
Expand Down