promptbench
promptbench copied to clipboard
Try to run the basic sample
I am trying to run basic sample and the error has been reported:
(.venv) PS C:\Users\allan\Documents\promptbench> & c:/Users/allan/Documents/promptbench/.venv/Scripts/python.exe c:/Users/allan/Documents/promptbench/examples/basic.py
Traceback (most recent call last):
File "c:\Users\allan\Documents\promptbench\examples\basic.py", line 5, in
Any help about that? Thanks in advance.
Hi, can you share the code you are running with me?
I tested the following code, it worked well.
import promptbench as pb
dataset = pb.DatasetLoader.load_dataset("sst2")
print(dataset)
BTW, can you please check if the datasets package has been successfully installed?
The code is a python source copied from the notebook "basic.ipynb" and is following attached. Thanks.
Em seg., 17 de mar. de 2025 às 17:03, Kaijie Zhu @.***> escreveu:
Hi, can you share the code you are running with me?
I tested the following code, it worked well.
import promptbench as pb
dataset = pb.DatasetLoader.load_dataset("sst2") print(dataset)
BTW, can you please check if the datasets package has been successfully installed?
— Reply to this email directly, view it on GitHub https://github.com/microsoft/promptbench/issues/94#issuecomment-2730707219, or unsubscribe https://github.com/notifications/unsubscribe-auth/A7KQ4JWU33OHEPJJOW6RDVL2U4TCBAVCNFSM6AAAAABYSVCNZOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDOMZQG4YDOMRRHE . You are receiving this because you authored the thread.Message ID: @.***> [image: Immortalise]Immortalise left a comment (microsoft/promptbench#94) https://github.com/microsoft/promptbench/issues/94#issuecomment-2730707219
Hi, can you share the code you are running with me?
I tested the following code, it worked well.
import promptbench as pb
dataset = pb.DatasetLoader.load_dataset("sst2") print(dataset)
BTW, can you please check if the datasets package has been successfully installed?
— Reply to this email directly, view it on GitHub https://github.com/microsoft/promptbench/issues/94#issuecomment-2730707219, or unsubscribe https://github.com/notifications/unsubscribe-auth/A7KQ4JWU33OHEPJJOW6RDVL2U4TCBAVCNFSM6AAAAABYSVCNZOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDOMZQG4YDOMRRHE . You are receiving this because you authored the thread.Message ID: @.***>
May I ask for more help?
I am trying to load a pre-trained model locally, it is a derivation of llama 3.1, can I load this model locally and make some attacks against it?
BTW!
Em qui., 20 de mar. de 2025 às 12:41, Allan Chamon Figueiredo < @.***> escreveu:
The code is a python source copied from the notebook "basic.ipynb" and is following attached. Thanks.
Em seg., 17 de mar. de 2025 às 17:03, Kaijie Zhu @.***> escreveu:
Hi, can you share the code you are running with me?
I tested the following code, it worked well.
import promptbench as pb
dataset = pb.DatasetLoader.load_dataset("sst2") print(dataset)
BTW, can you please check if the datasets package has been successfully installed?
— Reply to this email directly, view it on GitHub https://github.com/microsoft/promptbench/issues/94#issuecomment-2730707219, or unsubscribe https://github.com/notifications/unsubscribe-auth/A7KQ4JWU33OHEPJJOW6RDVL2U4TCBAVCNFSM6AAAAABYSVCNZOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDOMZQG4YDOMRRHE . You are receiving this because you authored the thread.Message ID: @.***> [image: Immortalise]Immortalise left a comment (microsoft/promptbench#94) https://github.com/microsoft/promptbench/issues/94#issuecomment-2730707219
Hi, can you share the code you are running with me?
I tested the following code, it worked well.
import promptbench as pb
dataset = pb.DatasetLoader.load_dataset("sst2") print(dataset)
BTW, can you please check if the datasets package has been successfully installed?
— Reply to this email directly, view it on GitHub https://github.com/microsoft/promptbench/issues/94#issuecomment-2730707219, or unsubscribe https://github.com/notifications/unsubscribe-auth/A7KQ4JWU33OHEPJJOW6RDVL2U4TCBAVCNFSM6AAAAABYSVCNZOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDOMZQG4YDOMRRHE . You are receiving this because you authored the thread.Message ID: @.***>
I am using datasets package version 2.15.0, I´ve tried to use the 2.19.2 as well, the same erros happens when I try to execute the code snippet you suggested:
`import promptbench as pb
dataset = pb.DatasetLoader.load_dataset("sst2") print(dataset)`
TypeError: unhashable type: 'list'
Solved! I have changed the version of packages below in order to create the conda enviroment correctly: sentencepiece==0.1.99->0.2.0 tokenizers==0.15.0->0.15.1
I have the packages below so that I could use CUDA support: conda install pytorch torchvision torchaudio pytorch-cuda=11.8 -c pytorch -c nvidia
Stale issue message