Ironclad / rivet

The open-source visual AI programming environment and TypeScript library
https://rivet.ironcladapp.com
MIT License
2.71k stars 237 forks source link

[Feature]: general form validation as part of Node descriptions #290

Open codemile opened 9 months ago

codemile commented 9 months ago

Feature Request

Can we add some kind of general form validation for inputs on Node properties. Things like URLs, input names, text prompts, etc. are used "as is" in the current setup.

When I say validation, I'm referring to tools like Joi Validation where the node description for the inputs would include a schema that can be used to give the user feedback.

Code of Conduct

abrenneke commented 9 months ago

Most node inputs are passed through the coercion system so don't need to be validated but yeah, makes sense for those that aren't. Joi looks good, I've also used refine and like it a lot, but it doesn't have fancy validators like email built in.