Logseq is all these things, and open source!
However the interface (like Roam) is too limiting. I am used to split frames of multiple buffers with others a C-x b away, and treemacs and mu4e and Olivetti mode, and eshell, and dired, and...
That's the biggest obstacle for me with these personal knowledge management apps. They're nice to use individually, but when I need to collaborate with someone, there's no way to delegate access—much less granular access.
I believe it's intended for documentation. But I use it as my note taking app.
Syncthing might also work in a rather hacky way, but would probably also run into real-time collisions.