OSU-NLP-Group/HippoRAG

fail to call the method "encode_text"

Jijun-Shi opened this issue · 5 comments

the retrieve in bash config is colbert by default. when call the fucntion "init_embedding_model" ,it will return None, So, it fail to call the method "encode_text"

Hello, which script are you running? If it's the ircot one (Retrieval - ColBERTv2), please pull the latest code and try again.

Hello, which script are you running? If it's the ircot one (Retrieval - ColBERTv2), please pull the latest code and try again.

hi, I can run the following script(for Indexing) successfully !
###bash src/setup_hipporag_colbert.sh $DATA $LLM $GPUS $SYNONYM_THRESH $LLM_API###

but fail to run the script "python3 src/ircot_hipporag.py"(for retrieving)and I find when I call function “init_embedding_model” in /HippoRAG-main/src/lm_wrapper/util.py, the funciton will return None. Then, the code execute the function "load_node_vectors" in hipporag.py, it will report a error. So, Can I build a new Class for loading some other model to repalce the GritWrapper or HuggingFaceWrapper?

This is a known issue and I think the newest commit has fixed this:

return

Could you check if you're using this version and still have this problem?

ok, but it meet the following mistakes when i run the retrieve.sh
1.[Errno 2] No such file or directory: 'data/lm_vectors/colbert/sample/corpus/indexes/nbits_2/centroids.pt'
the following is all script which I run:

DATA=sample
LLM=gpt-4-1106-preview
SYNONYM_THRESH=0.8
GPUS=0,1,2,3
LLM_API=openai

bash src/setup_hipporag_colbert.sh $DATA $LLM $GPUS $SYNONYM_THRESH $LLM_API

python3 src/ircot_hipporag.py --dataset $DATA --retriever $RETRIEVER --llm $LLM_API --llm_model $LLM --max_steps 1 --doc_ensemble f --top_k 10 --sim_threshold $SYNONYM_THRESH --damping 0.5

Thanks for your response. I have submitted a PR and it should fix this problem after merging:
#32