-
Notifications
You must be signed in to change notification settings - Fork 362
docs: add Perplexica web search provider setup guide #525
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
base: main
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,151 @@ | ||||||
| --- | ||||||
| title: Perplexica | ||||||
| icon: Search | ||||||
| description: Configure Perplexica as a self-hosted AI-powered web search backend for LibreChat. | ||||||
| --- | ||||||
|
|
||||||
| [Perplexica](https://github.com/ItzCrazyKns/Perplexica) is an open-source AI-powered search engine (15k+ GitHub stars) that provides cited, context-aware answers by combining web search with LLM reasoning. LibreChat can use Perplexica as a web search backend via the [Model Context Protocol (MCP)](/docs/features/mcp). | ||||||
|
|
||||||
| ## Prerequisites | ||||||
|
|
||||||
| - Perplexica **v1.12.1 or later** (earlier versions used the deprecated `focusMode` parameter) | ||||||
| - A running Perplexica instance (self-hosted or accessible via network) | ||||||
| - A configured SearXNG instance (Perplexica's underlying search engine) | ||||||
|
|
||||||
| ## Deploy Perplexica | ||||||
|
|
||||||
| Add Perplexica and SearXNG to your `docker-compose.yml`: | ||||||
|
|
||||||
| ```yaml | ||||||
| services: | ||||||
| perplexica-backend: | ||||||
| image: itzcrazykns1337/perplexica-backend:main | ||||||
| environment: | ||||||
| - SEARXNG_API_URL=http://searxng:8080 | ||||||
| - OPENAI_API_KEY=${OPENAI_API_KEY} | ||||||
| ports: | ||||||
| - "3001:3001" | ||||||
| depends_on: | ||||||
| - searxng | ||||||
|
|
||||||
| searxng: | ||||||
| image: searxng/searxng:latest | ||||||
| ports: | ||||||
| - "8080:8080" | ||||||
| volumes: | ||||||
| - ./searxng:/etc/searxng | ||||||
| ``` | ||||||
|
|
||||||
| After starting, visit the Perplexica settings UI (typically at `http://localhost:3000`) to configure your chat model and embedding model providers. | ||||||
|
||||||
| After starting, visit the Perplexica settings UI (typically at `http://localhost:3000`) to configure your chat model and embedding model providers. | |
| After starting, visit the Perplexica settings UI (typically at `http://localhost:3001`) to configure your chat model and embedding model providers. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 0fbbfb6 — updated to port 3001 to match the backend-only compose snippet. Also added a note explaining that port 3000 is the Next.js frontend, which is a separate service not included in the minimal deployment snippet shown.
Copilot
AI
Mar 8, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The request-body table markup uses leading double pipes (|| ... | ... |), which renders as an extra empty column in standard Markdown/MDX tables. Use single leading pipes (| Field | Description |) (and similarly for the separator and rows) so the table renders correctly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 0fbbfb6 — double leading pipe removed from the request-body table.
Copilot
AI
Mar 8, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The docs say the NDJSON response is streamed and the answer is assembled incrementally, but this example uses await response.text() which buffers the entire response in memory and only then parses lines. Either update the description to reflect buffered parsing, or switch the example to reading from response.body (streaming) to match the stated behavior and avoid large-memory responses.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good observation — updated in 0fbbfb6. The description now accurately says the example buffers the full response before parsing, with a brief note that production-scale implementations may prefer streaming via response.body. The await response.text() approach is deliberately kept in the example for simplicity and readability.
Copilot
AI
Mar 8, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The troubleshooting table also uses leading double pipes (|| ... | ... |), which will render an extra empty column. Switch to standard Markdown table syntax with single leading pipes for the header/separator/rows.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 0fbbfb6 — same fix applied to the troubleshooting table.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Docker Compose example uses mutable image tags
itzcrazykns1337/perplexica-backend:mainandsearxng/searxng:latest, which creates a supply-chain risk: future pulls may silently run altered or compromised images that have access toOPENAI_API_KEYand other data. An attacker who compromises or hijacks these tags could exfiltrate secrets or tamper with search results. Pin these images to specific versions or immutable digests so updates happen only when you explicitly review and change the reference.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added a warning callout in 0fbbfb6 flagging the supply-chain risk of mutable tags, particularly since both containers have access to API keys via environment variables. The note recommends pinning to specific version digests for production deployments. The mutable tags are kept in the example for readability but the risk is now clearly surfaced.