Skip to content

pdf qna error #10

@scenaristeur

Description

@scenaristeur

hi running q_a.sh on my CPU (no GPU) laptop, loading a pdf and running "What is this document question? " gives me

You can now view your Streamlit app in your browser.

  URL: http://localhost:8787

/home/user/.local/lib/python3.10/site-packages/langchain/__init__.py:38: UserWarning: Importing HuggingFacePipeline from langchain root module is no longer supported.
  warnings.warn(

according to https://github.com/langchain-ai/langchain/blob/4df31910924c61683526ab5af288e6e44ef32dc9/libs/langchain/langchain/llms/huggingface_pipeline.py#L21

it should be imported from langchain.llm

from langchain.llms import OpenAI, HuggingFacePipeline

pip list --outdated
Package                  Version    Latest    Type
------------------------ ---------- --------- -----
accelerate               0.19.0     0.23.0    wheel
anyio                    3.7.1      4.0.0     wheel
bitsandbytes             0.39.0     0.41.1    wheel
chromadb                 0.3.25     0.4.13    wheel
dataclasses-json         0.5.14     0.6.1     wheel
einops                   0.6.1      0.7.0     wheel
langchain                0.0.189    0.0.306   wheel
nvidia-cublas-cu11       11.10.3.66 11.11.3.6 wheel
nvidia-cuda-cupti-cu11   11.7.101   11.8.87   wheel
nvidia-cuda-nvrtc-cu11   11.7.99    11.8.89   wheel
nvidia-cuda-runtime-cu11 11.7.99    11.8.89   wheel
nvidia-cudnn-cu11        8.5.0.96   8.9.4.25  wheel
nvidia-curand-cu11       10.2.10.91 10.3.0.86 wheel
nvidia-cusolver-cu11     11.4.0.1   11.4.1.48 wheel
nvidia-cusparse-cu11     11.7.4.91  11.7.5.86 wheel
nvidia-nccl-cu11         2.14.3     2.18.3    wheel
nvidia-nvtx-cu11         11.7.91    11.8.86   wheel
openai                   0.27.7     0.28.1    wheel
pdfplumber               0.9.0      0.10.2    wheel
pip                      22.0.2     23.2.1    wheel
pydantic                 1.10.13    2.4.2     wheel
pyre-extensions          0.0.29     0.0.30    wheel
starlette                0.27.0     0.31.1    wheel
tiktoken                 0.4.0      0.5.1     wheel
tokenizers               0.13.3     0.14.0    wheel
transformers             4.29.2     4.33.3    wheel
triton                   2.0.0      2.1.0     wheel
xformers                 0.0.20     0.0.22    wheel

another error :

File "/home/smag/.local/lib/python3.10/site-packages/langchain/document_loaders/pdf.py", line 454, in init
import pdfplumber # noqa:F401
ModuleNotFoundError: No module named 'pdfplumber'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions