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

Multiple unclosed brackets slow down/crash Prompt Parser #103

Open
sssemil opened this issue Sep 3, 2024 · 0 comments
Open

Multiple unclosed brackets slow down/crash Prompt Parser #103

sssemil opened this issue Sep 3, 2024 · 0 comments

Comments

@sssemil
Copy link

sssemil commented Sep 3, 2024

This snipped slows it down a lot, and sometimes crashes with too many recursive calls error.

from compel import PromptParser

parser = PromptParser()
for i in range(1, 100):
    print(f"Testing {i}...")
    parser.conjunction.parse_string("(" * i)

Using compel==2.0.3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant