Recommendica is a research recommendation API powered by AI and Retrieval-Augmented Generation (RAG). It helps users find the most relevant research papers based on their input queries. This project is set up to create a virtual environment, install dependencies, and run a Django server for the Recommendica.
-
Create a Virtual Environment:
python -m venv env
-
Activate the Virtual Environment:
- On macOS and Linux:
source env/bin/activate
- On Windows:
.\env\Scripts\activate
- On macOS and Linux:
-
Install Dependencies:
pip install -r requirements.txt
-
Configure Environment Variables:
- Copy the example environment file to create your own environment configuration:
cp env.example .env
- Copy the example environment file to create your own environment configuration:
-
Import Research Data:
python manage.py import_research
-
Apply Migrations:
python manage.py migrate
-
Run the Django Development Server:
python manage.py runserver
- localhost:8000/api/v1/prompt/
{
"input_prompt": "What is the impact of COVID-19 on the economy?"
}
The return response will be the top 5 most relevant research papers to the input prompt.
{
"status": 200,
"message": "Success",
"data": {
"response": "ai response",
"research_results": [
{
"title": "title",
"category": "category",
"summary": "summary",
"authors": "authors"
}
]
}
}
- localhost:8000/docs/