From 21c83b6398ae8f0a3b130c280b5b3174492933e1 Mon Sep 17 00:00:00 2001 From: BukeLy Date: Wed, 27 May 2026 14:34:42 +0800 Subject: [PATCH] fix(filesystem): run pifs from local venv --- pifs | 12 ++++++++---- requirements.txt | 3 ++- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/pifs b/pifs index 46b6e0e..fb2dbc0 100755 --- a/pifs +++ b/pifs @@ -1,6 +1,10 @@ -#!/usr/bin/env python3 -from pageindex.filesystem.cli import main +#!/bin/sh +set -eu +SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd) -if __name__ == "__main__": - raise SystemExit(main()) +if [ -x "$SCRIPT_DIR/.venv/bin/python" ]; then + exec "$SCRIPT_DIR/.venv/bin/python" -m pageindex.filesystem.cli "$@" +fi + +exec python3 -m pageindex.filesystem.cli "$@" diff --git a/requirements.txt b/requirements.txt index e6ad805..f88e7cb 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,7 @@ litellm==1.83.7 -# openai-agents # optional: required for examples/agentic_vectorless_rag_demo.py +# openai-agents==0.17.2 # optional: required for pifs chat/ask and examples/agentic_vectorless_rag_demo.py pymupdf==1.26.4 PyPDF2==3.0.1 python-dotenv==1.2.2 pyyaml==6.0.2 +sqlite-vec>=0.1.9