Pinecone-spare-english-v0 doesn't work

I just run the same code as documentation:

from pinecone import Pinecone

pc = Pinecone(PINECONE_API_KEY)

pc.inference.embed(
       model="pinecone-sparse-english-v0",
       inputs=["The share price of NVIDIA is $10"],
	   parameters={
         "input_type": "passage", # or query
         "return_tokens": True,
      }
)
TypeError: object of type 'NoneType' has no len()

Anyone got the same problem as me ?
Many thanks

Thanks for reporting!

@jinghao.yang were weren’t able to reproduce on our end? Could you share the libraries & versions and possibly more of the inputs. I would try running

pip install --upgrade pinecone pinecone-plugin-inference

Hello, Thank you for your quick response. I just restarted the computer, and the problem was solved.

2 Likes