3 ms·
Efficient WebAssembly-based vector math engine for JavaScript/TypeScript
Hi, HN!
I've been building a suite of developer tools for developers building AI products, and last week, I decided it might be a good idea to start open-sourcing distinct components of the suite that may be useful to the public.
I've just open-sourced [1] and published the first component, which is a minimal and efficient vector math library for JavaScript/TypeScript I'm calling Vek Engine (see: something about two hard things in Computer Science).
Since this is part of a larger product suite that's not polished or even close to ready for public consumption, I had to carefully extract a slightly slimmed down version of the library, but hopefully, it's useful to someone here. One primary/obvious way I've been using it is to manage embeddings.
I haven't had a chance to explicitly document the library, but for now, the tests [2] are pretty thorough and should be sufficient for understanding how to use it.
Have fun!
[1]: https://github.com/jonathanmarvens/vek-engine https://github.com/jonathanmarvens/vek-engine
[2]: https://github.com/jonathanmarvens/vek-engine/blob/646c049417cf48418d7eed59f52c1cb9bf27877f/src/vector.test.mts https://github.com/jonathanmarvens/vek-engine/blob/646c04941...
- jay-barronville 4y agoHi, HN! I've been building a suite of developer tools for developers building AI products, and last week, I decided it might be a good idea to start open-sourcing distinct components of the suite that may be useful to the public. I've just open-sourced [1] and published the first component, which is a minimal and efficient vector math library for JavaScript/TypeScript I'm calling Vek Engine (see: something about two hard things in Computer Science). Since this is small piece of a much larger codebase that's not polished or even close to ready for public consumption, I had to carefully extract a slightly slimmed down version of the library, but hopefully, it's useful to someone here. One primary/obvious way I've been using it is to process embeddings. I haven't had a chance to explicitly document the library, but for now, the tests [2] are pretty thorough and should be sufficient for understanding how to use it. Have fun! [1]: https://github.com/jonathanmarvens/vek-engine https://github.com/jonathanmarvens/vek-engine [2]: https://github.com/jonathanmarvens/vek-engine/blob/646c049417cf48418d7eed59f52c1cb9bf27877f/src/vector.test.mts https://github.com/jonathanmarvens/vek-engine/blob/646c04941...