A Python tool for querying and extracting detailed SNP and gene information from NCBI, with section parsing and relevance-based summarization.
- Fetch SNP and gene details from NCBI.
- Parse and extract sections using BeautifulSoup.
- Use GPT models to identify relevant sections based on queries.
- Summarize and prune text for efficient output.
Ensure you have Python 3.8 or later installed. Install the required dependencies:
pip install -r requirements.txt
-
Set up your OpenAI API Key:
Update your OpenAI API key in theagent.py
file or set it as an environment variable.os.environ["OPENAI_API_KEY"] = "<YOUR_API_KEY>"
-
Update the Query:
Replace the placeholder query with your desired query in theagent.py
file:query = "<YOUR_QUERY>"
-
Run the Agent:
Execute the script to fetch and process data:python agent.py
-
Output:
The results will be saved to the appropriate directory and displayed in the terminal.
- Ensure you have access to the internet for API calls and data fetching.
- Modify file paths and configurations as needed for your environment.
This project is licensed under the MIT License. See the LICENSE file for details.