e2b-dev / code-interpreter

Python & JS/TS SDK for running AI-generated code/code interpreting in your AI app
https://e2b.dev
Apache License 2.0
1.28k stars 96 forks source link

Support for Ruby runtime #31

Open andreibondarev opened 5 months ago

andreibondarev commented 5 months ago

Is your feature request related to a problem? Please describe. I'm building https://github.com/patterns-ai-core/langchainrb and I would like to be able to be able to integrate your tool if it's able to execute Ruby code in a sandbox environment. Do you have any plans to add the Ruby runtime?

Describe alternatives you've considered Currently using https://github.com/ukutaht/safe_ruby but it's an extremely outdated library.

ValentaTomas commented 2 months ago

Sorry for the late response @andreibondarev.

I think adding https://github.com/SciRuby/iruby as a custom Jupyter runtime, similar to how we add Java, R, etc. here, https://github.com/e2b-dev/code-interpreter/blob/beta/template/Dockerfile#L26 should allow you to execute Ruby.

The instructions about how to create a custom template with a modified Dockerfile are here: https://e2b.dev/docs/guide/beta-migration#custom-template.