Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] Issue with GibberishText package - False Validation #892

Open
Kashyapiyer opened this issue Jul 9, 2024 · 2 comments
Open

[bug] Issue with GibberishText package - False Validation #892

Kashyapiyer opened this issue Jul 9, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@Kashyapiyer
Copy link

Kashyapiyer commented Jul 9, 2024

Describe the bug
guardrails-ai 0.4.5 is forcing to use Token. Without API token it is not allowing to configure further.

Also gibberish text is falsely reporting validation failure even on correct sentences

Sentence tested : "Hello how is the weather"

Screenshot 2024-07-08 at 9 06 23 PM Screenshot 2024-07-08 at 9 05 14 PM

To Reproduce
Steps to reproduce the behavior:

  1. RAIL spec
  2. Runtime arguments (e.g. guard(...))
    Please refer to the code screenshot
    Expected behavior
    A clear and concise description of what you expected to happen.

Library version:
guardrails-ai 0.4.5

Additional context
Add any other context about the problem here.

Please let us know if you need further information. Appreciate your kind support. Thanks

@Kashyapiyer Kashyapiyer added the bug Something isn't working label Jul 9, 2024
@wylansford
Copy link
Contributor

Hi there,

For issue the first problem regarding the token. Once you install guardrails, you can run
guardrails configure
to get a token. Following the steps there should resolve your issue.

For problem regarding the validator, the validator is an ML based model. It will not always be perfect, so you'll need to adjust the threshold according to the model that is used and the types of inputs you will be using. In this case, if you lower the threshold to .4 it will pass.

Setting the threshold will depend on the system that you are using. If this is a system that involves humans, you may need to lower the threshold to accommodate spelling/grammatical errors. With LLMs, it may be higher. In fact, if you change the input to "How is the weather today?" (using punctuation like an LLM would), then the validator successfully passes.

@Kashyapiyer
Copy link
Author

Hi Wylandsford,
Thanks for looking into this issue. I tested both situations after configuring Guardrails. It would be tricky to ensure that always a context text would end in a specific way. Could you suggest the optimum threshold value that could work in most of cases. Appreciate your kind support.
Regards,
Kashyap

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants