Flex [1] is a transpiler that converts a series of statements in natural language to either Python, Java or C++, and is trained using Rasa NLU [2], an open-source framework usually used for training chatbots and voice assistants.<p>Flex is a project I made in college in 2018 along with two of my classmates, Gourav and Sanjay. The initial idea was to create a voice assistant you could speak to that wrote code for you, similar to GitHub's upcoming (and a lot more advanced) project "Hey, Github" [3].<p>We then had to reduce the project's scope to complete it in a single semester while writing exams, preparing for job interviews and submitting reports and assignments. So we settled on creating a Python program that takes a file containing statements written in natural language as input and transpiles them to a valid Python/Java/C++ program. The project design is modular, so adding more languages and statement types is easy.<p>The next step we had thought of was to hook it up with some UI with voice input to have some kind of voice-driven IDE, but then as college was over and we got jobs, the project got abandoned as we moved on to other things.<p>Seeing the "Hey, GitHub" project on HackerNews today [4] reminded me of this project, so I just wanted to share it to inspire others to fork it and make something cool. Also looking forward to some feedback on how the project could be improved to make it more useful.<p>[1]: <a href="https://github.com/Flex-lang/transpiler" rel="nofollow">https://github.com/Flex-lang/transpiler</a>. Not to be confused with FLEX, a strictly-typed programming language with the same name (which was released first, so we should have used a different name!)<p>[2]: <a href="https://github.com/rasahq/rasa" rel="nofollow">https://github.com/rasahq/rasa</a><p>[3]: <a href="https://githubnext.com/projects/hey-github/" rel="nofollow">https://githubnext.com/projects/hey-github/</a><p>[4]: <a href="https://news.ycombinator.com/item?id=33543946" rel="nofollow">https://news.ycombinator.com/item?id=33543946</a>
Can anyone explain to me what this does? I would have expected something like GPT-3 Codex or GitHub Copilot. But the example on the page looks a lot different. Specifically, I don’t see any natural language input.
Also flex: fast lexical analyzer generator: <a href="https://en.wikipedia.org/wiki/Flex_(lexical_analyser_generator)" rel="nofollow">https://en.wikipedia.org/wiki/Flex_(lexical_analyser_generat...</a><p>Edit: In case the parentheses don't work (percentage encoding didn't), try: <a href="https://github.com/westes/flex" rel="nofollow">https://github.com/westes/flex</a>
I've been experimenting with chatbot frameworks lately and was getting a little bored of building toy ones, so this might be an interesting idea for me to explore! The dependencies seem a little old though, you should think about keeping them updated.