Semurg

Semurg

Semurg - a CPU-native data engine built with Elixir and Rust

Hi all, long-time reader, finally made an account.

I wanted to introduce something my team and I have been building, mostly because the core of it is an Elixir and Rust bet and I would really like this community’s take on it.

Semurg holds every type of data (relational, graph, object, document, search, vector, time-series) as one fixed 64-byte binary container, in a single engine over one copy of the data, CPU-only, on hardware you control. It is a commercial product and closed source. It is also live with no login at semurg.io so you are very welcome to have a play with it.

The part that belongs on this forum is how it is put together:

BEAM conducts, Rust does the heavy lifting. Elixir and OTP own supervision, scheduling and fault tolerance. The per-byte work runs in Rust NIFs, one concurrent arm per physical core, with no shared write lock between them. We hand each NIF a whole batch and fan out inside a single crossing rather than paying the boundary cost per item, and only tokens and offsets ever cross, never materialised data. Long jobs go on dirty schedulers, and every NIF has a pure-BEAM fallback, so a missing or failed native artifact costs us throughput rather than taking the VM down.

The 64 bytes are not arbitrary. One container is a CPU cache line, 64 of them is a 4KB page, so the storage format is aligned to what the hardware actually moves.

Agents are just supervised BEAM processes over the same store, so a swarm gets isolation and concurrency from the runtime rather than from containers.

On scope, so I am not overselling it: the substrate and a gateway that tokenises PII before any external model call are live today. Growing CPU-native models on the same substrate is still research, and I try to keep that line clear.

There is an independent benchmark running at a university lab at the moment which I will happily share when it lands.

Happy to go into as much depth as anyone wants on the orchestration and the BEAM side. The storage layout and IO mechanics are the bit we keep closed, so I will be vaguer there, but everything above that is fair game.

What I would most like is to hear from anyone who has run BEAM and Rust NIFs in production, especially dirty schedulers and large batched crossings. What caught you out? I have a feeling we are not the first to learn some of these the hard way.

Thanks,
Slade

Where Next?

Popular in Announcing Top

kelvinst
Hey everyone! Well, we made this lib a while ago and now we decided to finally go out and public with it! It’s a tool for creating and m...
New
anshuman23
Hello all, I have been working on my proposed project called Tensorflex as part of Google Summer of Code 2018.. Tensorflex can be used f...
New
mathieuprog
Hello :waving_hand: Allow me to introduce you to Tz, an alternative time zone database support to Tzdata. Why another library? First a...
New
mplatts
With HEEX released we decided to start a components library using Tailwind CSS - check it out here: Petal Components. We also have a boi...
New
benlime
LiveMotion enables high performance animations declared on the server and run on the client. As a follow up to my previous thread A libr...
New
type1fool
WebAuthnLiveComponent WebAuthnComponents See this post about renaming the package. Passwordless authentication for Phoenix LiveView app...
New
woylie
Flop is an Elixir library that applies filtering, ordering and pagination parameters to your Ecto queries. offset-based pagination with...
New

Other popular topics Top

JeremM34
Hello, how can I check the Phoenix version ? Thanks !
New
Brian
What is the proper way to load a module from a file in to IEX? In the python world, doing something like this pretty standard: from ....
New
openscript
Hello! Sorry for this astonishing simple question, but I’m really stuck. I try to set up the intellij-elixir plugin, but I don’t know ho...
New
shijith.k
I am trying to start a new phoenix project with elixir 1.9, but mix phx.new does not work. It says that ** (Mix) The task "phx.new" could...
New
WestKeys
Currently suffering from paralysis by [HTTP client] analysis. This is rather unusual in Elixirland as there tends to be consensus on the ...
New
jason.o
In the code below, if the create action is not set to accept “extra_key” as an input, it errors out with a message shown above. Is there ...
New

We're in Beta

About us Mission Statement