Skip to content

Configuration

PriorisMCP is configured entirely through environment variables.

Variable Description Default Allowed values
PRIORIS_MCP_LOG_LEVEL Python log level for this server. INFO NOTSET, DEBUG, INFO, WARNING, ERROR, CRITICAL
PRIORIS_MCP_TRANSPORT FastMCP transport for this MCP server. stdio stdio, streamable-http, http
PRIORIS_MCP_RESPONSE_CACHE_TTL Cache time-to-live (TTL), in seconds, for prompt, resource, and tool responses. 0 disables caching. 300 integer, 086400
PRIORIS_MCP_HOST Host address for network transports. localhost
PRIORIS_MCP_PORT Port number for network transports. 8000 integer, 102449151
PRIORIS_MCP_ASGI_CORS_ALLOWED_ORIGINS CORS allowed origins for HTTP-based transports. Override to ["*"] for tools that require it (e.g. the MCP Inspector) — see Security. ["http://localhost", "http://127.0.0.1"]
PRIORIS_MCP_UNVERIFIED_HTTPS Disables HTTPS certificate verification for upstream HTTPS requests (passed straight through to the shared httpx.AsyncClient's verify=). Set to True only for development/testing when you intentionally need unverified HTTPS — enabling it logs a WARNING at startup. Prefer SSL_CERT_FILE/SSL_CERT_DIR (see Security) for a organisational HTTPS-inspecting proxy's self-signed root instead of disabling verification outright. False True, False
PRIORIS_MCP_STORAGE_DIR Directory where fetched full text and parsed Markdown are persisted — see Storage. $XDG_DATA_HOME/prioris-mcp/downloads (~/.local/share/prioris-mcp/downloads if XDG_DATA_HOME is unset)
PRIORIS_MCP_NOTES_DIR Directory where user-authored notes' SQLite databases (notes.sqlite, notes-search.sqlite3) are persisted. A sibling of PRIORIS_MCP_STORAGE_DIR's downloads, not nested inside it — notes are user-authored, not fetched content — see Notes storage. $XDG_DATA_HOME/prioris-mcp/notes (~/.local/share/prioris-mcp/notes if XDG_DATA_HOME is unset)
PRIORIS_MCP_VECTOR_DIR Directory where vector search indices are persisted — see Vector search. A sibling of PRIORIS_MCP_STORAGE_DIR, separate from all other storage roots. $XDG_DATA_HOME/prioris-mcp/vectors (~/.local/share/prioris-mcp/vectors if XDG_DATA_HOME is unset)
PRIORIS_MCP_EMBEDDING_MODEL Name of the embedding model used for vector search (fastEmbed model identifier). Changing this is detected at the next server startup, not the moment this variable is edited — no manual recovery step, but also no live/hot reload. A forced reconnect during that startup drops and recreates the vec0 table if the recorded model differs from the configured one — regardless of whether the new model changes the table's dimension — so vector search for that corpus is empty until background reconciliation re-embeds it back to ready; FTS results stay available and accurate throughout, since only the vector table is affected. Rows already indexed under the previous model report not_built via index_status (not stale — a differently-named record is deleted, not merely flagged, the moment anything connects under the new model) until reindexed — see ADR-00023. See ADR-00030 for the full startup/reconciliation lifecycle. BAAI/bge-small-en-v1.5
PRIORIS_MCP_EMBEDDING_MAX_CONCURRENCY Maximum number of background embedding tasks (per-document/note triggers and corpus-wide startup reconciliation alike) allowed to actually run concurrently, via a shared EmbeddingScheduler semaphore — see ADR-00030. 4 integer, ≥ 1
PRIORIS_MCP_VECTOR_SEARCH_DEFAULT_LIMIT Default result limit for vector-based search in research_search_fetched and research_notes_search. 10 integer, 1200
PRIORIS_MCP_OPENALEX_API_KEY OpenAlex API key, sent as the api_key query parameter on every research_discovery/research://openalex/work-types request — see Discovery → Authentication. OpenAlex has required a key on every request since 2026-02-13 (replacing the deprecated mailto polite-pool parameter): leaving this unset doesn't fail startup, but research_discovery/research://openalex/work-types fail with configuration_error the moment they're used. unset
PRIORIS_MCP_DISCOVERY_MAX_RESULTS Default max_results for research_discovery when the caller doesn't pass one. Capped at 50 — OpenAlex's search.semantic has a hard per-query ceiling at that count, not the ordinary /works per-page cap of 200. 25 integer, 150
PRIORIS_MCP_RATE_LIMIT_BACKOFF_BUDGET_SECONDS Total time a single tool call's rate-limit backoff may spend retrying a provider before giving up with rate_limited — see Non-functional requirements. 60.0 float, 03600
PRIORIS_MCP_JATS_MAX_CONCURRENT_TRANSFORMS Maximum number of JATS-to-HTML XSLT transforms allowed to actually execute concurrently, regardless of how many parse_full_text calls are in flight or have timed out — see Security. Always clamped to the host's CPU count even if set higher. min(4, os.cpu_count()) integer, ≥ 1
PRIORIS_MCP_LOCAL_FILE_MAX_SIZE_BYTES Maximum decoded size of the content_base64 payload research_localfile_fetch_full_text will accept — see Security. 10485760 (10MB) integer, ≥ 1
PRIORIS_MCP_LOCAL_FILE_UPLOAD_SESSION_TTL_SECONDS How long an idle chunked-upload session is kept before being swept as abandoned — see Interface specification. 300 (5 minutes) float, ≥ 1
PRIORIS_MCP_LOCAL_FILE_UPLOAD_MAX_CHUNK_BYTES Maximum size of a single chunk passed to research_localfile_upload_chunk. 1048576 (1MB) integer, ≥ 1
PRIORIS_MCP_LOCAL_FILE_UPLOAD_MAX_CONCURRENT_SESSIONS Maximum number of open chunked-upload sessions at once, bounding worst-case buffered memory. 16 integer, ≥ 1
PRIORIS_MCP_PDF_OCR_ENABLED Whether LiteParsePdfBackend runs OCR on scanned/image-only PDFs — see Security. True True, False
PRIORIS_MCP_PDF_OCR_TESSDATA_PATH Path to a pre-populated directory of Tesseract .traineddata files, for airgapped deployments — see obtaining .traineddata files below. Falls back to the standard TESSDATA_PREFIX if set and this is not. unset (falls back to TESSDATA_PREFIX, then liteparse's own lazy-download behaviour)
PRIORIS_MCP_PDF_OCR_SERVER_URL URL of an external OCR server, as an alternative to the bundled Tesseract engine. unset
PRIORIS_MCP_PDF_OCR_SERVER_HEADERS Extra HTTP headers (e.g. Authorization) sent with requests to PRIORIS_MCP_PDF_OCR_SERVER_URL, as a JSON object. {} JSON object of string keys/values, e.g. {"Authorization": "Bearer <token>"}

Obtaining .traineddata files for PRIORIS_MCP_PDF_OCR_TESSDATA_PATH

PRIORIS_MCP_PDF_OCR_TESSDATA_PATH (or TESSDATA_PREFIX) must point at a directory already containing the Tesseract language file(s) OCR will need, before network access is cut off — liteparse does not fetch or manage these files itself, it only reads whatever is at that path. To populate it:

  1. Pick the language(s) actually expected in scanned PDFs (e.g. eng for English) — each corresponds to one <lang>.traineddata file.
  2. Download the matching .traineddata file(s), while still on a network that can reach GitHub, from one of Tesseract's own model repositories:
    • tessdata_fast — smaller, faster models; the best default for most deployments.
    • tessdata_best — larger, most accurate models, if OCR quality matters more than speed/size.
    • tessdata — the legacy-engine models Tesseract shipped before the LSTM-based models above.
  3. Place the downloaded file(s) directly in the directory PRIORIS_MCP_PDF_OCR_TESSDATA_PATH points at (no subdirectories) and copy that directory into the airgapped environment.

See liteparse's own OCR guide for how tessdata_path and the bundled engine interact, and Security for why this is necessary at all in an airgapped deployment.