Thanks for your interest in contributing to Perplexica! Your help makes this project better. This guide explains how to contribute effectively.
Perplexica is a modern AI chat application with advanced search capabilities.
Perplexica's codebase is organized as follows:
src/components
): Reusable UI components.src/app
): Next.js app directory structure with page components./
), chat (/c
), discover (/discover
), library (/library
), and settings (/settings
).src/app/api
): API endpoints implemented with Next.js API routes./api/chat
: Handles chat interactions./api/search
: Provides direct access to Perplexica's search capabilities.src/lib
): Contains all the backend functionality including search, database, and API logic.
src/lib/search
directory.src/lib/search/metaSearchAgent.ts
.src/lib/db
.src/lib/providers
.src/lib/prompts
and src/lib/chains
respectively.Perplexica exposes several API endpoints for programmatic access, including:
/api/search
endpoint. For detailed documentation, see docs/api/search.md
.Before diving into coding, setting up your local environment is key. Here's what you need to do:
sample.config.toml
file.config.toml
and fill in the necessary configuration fields.npm install
to install all dependencies.npm run db:push
to set up the local sqlite database.npm run dev
to start the application in development mode.Please note: Docker configurations are present for setting up production environments, whereas npm run dev
is used for development purposes.
Before committing changes:
npm run format:write
to format your code according to the project's coding standards. This helps maintain consistency and code quality.Following these steps will help maintain the integrity of Perplexica's codebase and facilitate a smoother integration of your valuable contributions. Thank you for your support and commitment to improving Perplexica.