Skip to content

premAI-io/Premplexity

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Overview

Open-source, Fast, Private

Quench your thirst for discovery while boosting curiosity.

Premplexity is a completely open-source AI-powered utility belt for gathering information fast and privately. Answering questions is a trivial task you can do with any traditional search engine. With Premplexity you can retain full control over your searches and have ownership over the information you gather.

What should I use Premplexity for?

  • Privately explore the web for new topics, and summarize anything without the creepy trackers 🧟‍♂️👣

  • Answering questions: Go from a question to an answer as fast as possible. It doesn't matter if its a simple or complex question. Find the best answers from the most up to date sources. Generate code, summarize anything in one open environment.

  • Exploring topics in depth: Learn new things on the fly and access the main sources of information.

  • Choose the right AI models for your use case: Choose from a variety of AI models and pick the one that best fits your use case.

  • Fork and run locally: Run Premplexity locally on your own machine. Make it your OWN!

Examples

💻 What are some upcoming tech trends for 2024?

🔍 What are the benefits of cloud computing for startups?

📱 How can businesses adapt to digital transformation?

🚀 How can AI revolutionize customer service?

Want to run Premplexity on your own machine?

Requirements

Contributing

  1. Use the correct node version
nvm use
  1. Copy the .env.example file to .env
cp .env.example .env
  1. Run the db with Docker
docker-compose up -d postgres
  1. Install dependencies
npm install
  1. Create Prem project
  • Go to your Prem account and create a new project.
  • Copy the project ID and paste it in the .env file.
  • Create a new API key and paste it in the .env file.
PREM_PROJECT_ID=your_project_id
PREM_API_KEY=your_api_key
  1. Get SerpApi key
  • Go to your SerpAPI account and create a new project.
  • Get your API key and paste it in the .env file.
SERPAPI_KEY=your_api_key

Run the migrations

To apply the migrations, run:

npm run migrate

Run the application

Make sure you have docker running and no other services are running on the ports 5432 and 3000 (or in the ports that you have set on .env file). Start the local infrastructure:

npm run dev

You can now access the application at http://localhost:3000.

Drizzle Studio

If you want to use Drizzle Studio to manage the database, you can run the following command:

npm run studio

Database management

Migrations

To create a new migration, modify the Drizzle models and then run:

npm run makemigrations

Resetting the DB

Run the following command to reset the database (drop all tables, apply all migrations and seed the database):

npm run db:reset

If you want to hard clean the database, you can stop the postgres container and remove the volume:

docker-compose down -v

Cleaning the DB

Run the following command to clean the database (truncate all tables):

npm run db:truncate

Seeding the DB

Run the following command to seed the database with initial data:

npm run db:seed

Self Host Premplexity

Simply run:

docker-compose up -d

And you will have the application running at http://localhost:3000.

Troubleshooting

Error: Missing required environment variable

This error occurs when the application is missing a required environment variable. To resolve this issue, ensure that the required environment variables are set in the .env file.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 5

Languages