guardrails-ai / guardrails

Adding guardrails to large language models.
https://www.guardrailsai.com/docs
Apache License 2.0
3.87k stars 289 forks source link

[bug] Error: zsh: bus error guardrails start --config config.py #968

Open JuanmaMenendez opened 1 month ago

JuanmaMenendez commented 1 month ago

Describe the bug

In v0.5, when I run a SensitiveTopic validation with disable_llm=true (LLM disabled) and device with the default value of -1

NOTE: The validation works as expected if I change device to a positive value like 0. eg: device=0. I am using an M1 Macbook pro laptop.

This is my server config:

guard.name = 'sensitive_topics'
guard.use(SensitiveTopic(
    sensitive_topics=[
        "Politics",
        "Elections"
    ],
    disable_classifier=False,
    disable_llm=True,
    device=-1,
))

Library version: Version (0.5)

CalebCourier commented 1 month ago

@JuanmaMenendez I'm looking into this issue, but as of now I'm unable to reproduce the error with the example provided. Could you share a more complete code sample and stack trace for the errors you are encountering?