2

I try to run this code with a PDFTool, but I receive this following error

from crewai_tools import PDFSearchTool
rag_tool = PDFSearchTool(pdf='/content/17.pdf',
 config=dict(
 llm=dict(
 provider="groq", # or google, openai, anthropic, llama2, ...
 config=dict(
 model="llama3-8b-8192",
 # temperature=0.5,
 # top_p=1,
 # stream=true,
 ),
 ),
 embedder=dict(
 provider="huggingface", # or openai, ollama, ...
 config=dict(
 model="BAAI/bge-small-en-v1.5",
 #task_type="retrieval_document",
 # title="Embeddings",
 ),
 ),
 )
)

Error:

TypeError: cannot pickle 'classmethod' object

I have already defined the env. keys (GROQ_API_KEY), sounds like a incompatible versions of libraries.

I try to execute the code above, but, the error appear. I Want to use Groq api key to create a agent to search PDF information.

desertnaut
60.8k32 gold badges155 silver badges183 bronze badges
asked Oct 2, 2024 at 2:47

0

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.