Tokens limit in Web Browser Automation

Hello. I often face the problem of token limits when using this code:

Error message:
422 Client Error... Input validation error: 'inputs' tokens + 'max_new_tokens' must be <= 131072. Given: 270767 'inputs' tokens and 0 'max_new_tokens'

I suspect the issue lies in the browser screenshot function — it seems to generate too many tokens per screenshot. How can I resolve this?

1 Like

Oh… Unresolved issue…

Got it, thanks!

1 Like