llama_index
llama_index copied to clipboard
GPT Index and Typescript / Node.js
I work mostly with typescript and node.js, and I think many others do. Any ideas on how to make this thing compatible? Is your api getting stable already? I guess it must be possible then, to create a wrapper package in node.js. I'd like to get in touch with anyone interested in this, I might make it.
UPDATE
What are some of the principles of GPT Index?
It seems to be a library that contains the result of massive amount of work for months. It is certainly the start of "AI search" that helps you answer questions appropriately against large knowledge bases. It is the thing I need.
Can I use GPT Index in node.js easily?
No. We would need to create a typescript wrapper around their python API if we want to use it within node.js. This would a an enourmous task and also we would become dependent on an ever changing library that might make choices that I don't like. For such a crucial part, I think I would be better off creating my own Node.js implementation. Especially looking at long-term, this seems better.
Conclusion
I figured it will be a hassle to make this compatible with Typescript, and since GPT indexation is at the core of my company I decided I will at least try to make my own implementation in Node.js that uses similar principles.
I will try to replicate GPT Index as much as possible and needed in a typescript node.js package. Anyone that wants to help me: please get in touch; https://calendly.com/karsens
I'll regularly update my work in https://github.com/CodeFromAnywhere/gpt-index-js
Hey Karsten - I'd be interested in this. I'm currently trying to combine a Python server that runs GPT index as a Flask API with a Next.js front-end that consumes it.
Building this at Promptable.ai :)
Come join us! https://discord.gg/rNncg23E
After working for +8 years with JavaScript/TypeScript based frameworks I don't see any benefits on porting gpt_index or any other ML python package to JavaScript. That battle was already lost, the community decided to go all in with python and that's not a bad thing. If you still want to continue with the port, just remember that anytime you want to include any other ML library into your project as a replacement or as an integration into your existing codebase, that library will be written in python, so you will have to port it as well or create some sort of bindings.
This isn't on the short-term roadmap atm, going to close issue for now
LangchainJS is a thing now, willing to entertain this in the future?
I have initiated a Node.js version of this project and welcome pr. https://github.com/swk777/llama_index_node