Avatar
Bitcoin Research Kit
9751bdc4d12ff6e4cc6b61b102f71e445ef245bc830bf40af6566a6a246137c6
All of Bitcoin's data ready to be explored

Working hard 🫡

#Bitcoin is hope 🕊️

Pebble is coming back ! 🙌

and this time open source

Always found the idea better than Apple Watch and co, let’s see what they come up with

https://repebble.com/

Server shut down unexpectedly and corrupted a bunch of files

Had to recompute everything (kind of like when the core chain corrupts), which is still ongoing and so the data won't be up to date for a little while, sorry about that

It's been a while since I posted an update

So for anyone wondering I'm in the middle of R&D and trying out two major tasks:

- Fjall the key value store instead of Sanakirja

- Extracting and improving the parsing part (think creating a database from the blocks) from the "parser" crate (or folder, in the v0.5 codebase) which would end up being only a "computer" now (and thus a more organized codebase with 4 major parts: iterator, parser, computer and server)

Both have the same goal which is massively improve the self-hosting experience

The latter is going well I think and is looking like a good base for a mempool.space like database/explorer/whatever (which was kind of already needed and there but in the right shape)

The reason for doing is because up to the v0.5 the databases are stateful, by that I mean that when you compute a block you can't go back as the databases have the state at a current height, it's to save disk space since sanakirja is very demanding on this side but had the disadvantage is the need to recompute the databases again each time we need to start from the beginning (because of a new dataset for example) which is a lot (like a LOT) of disk writes (and time !)

So the goal is to have an append only database instead which is pretty much one and done like the chain itself (and no I can't just use the chain, it's too slow)

The former on the other hand, isn't going as well as I hoped, reads and writes are okay, the space needed is absolutely great the database is tiny but the RAM usage is quite high (12-13 GB at block 400 000 which is not great) with fjall. I'll do more research and see what I can do with fjall but also trying out sanakirja with the new code and maybe even manually with mmaps by hand if none of them satisfy the requirements.

Again the reason for this is to limit disk usage as it's currently very very high and this takes priority over anything else

Overall I'm happy with my progress, you can check the current state of the extracted parser (named "bitbase") here: https://github.com/kibo-money/kibo/tree/v0.6-fjall/src/crates/bitbase

Please note that I might change to branch's name so the link might break at some point

nostr:nevent1qvzqqqqqqypzp963hhzdztlkunxxkcd3qtm3u3z77fzmeqct7s90v4n2dgjxzd7xqqsfksjccf5hnxymul6pz03w7pwfah59hwjw55ng2del4h3v7wnw3wq0khfvz

Fjall was nice but too slow, tried canopydb but it's a bit too raw and harder to use; so I'm gonna stick with Sanakirja which is the devil I know and can manage

I also created a new crate `storable_vec` which is, as the name suggests, a list that can be saved on disk

It's push only for now (as it's all that I needed) and very fast, small and simple. It only stores the raw list for now, there is not even a header yet, so disk usage is incredibly efficient.

As many store use some kind of index as keys (height/txindex/txoutindex) I was able to migrate many of them to storable_vec (only 6 out of ~30 will use sanakirja) and the speed gain AND storage reduction is very noticeable

There is a lot more work left before the v0.6 is done but it will be the biggest update yet

#Bitcoin is hope 🕊️

nostr:nevent1qvzqqqqqqypzp963hhzdztlkunxxkcd3qtm3u3z77fzmeqct7s90v4n2dgjxzd7xqy88wumn8ghj7mn0wvhxcmmv9uq3uamnwvaz7tmwdaehgu3dwp6kytnhv4kxcmmjv3jhytnwv46z7qgawaehxw309ahx7um5wghxy6t5vdhkjmn9wgh8xmmrd9skctcqyqw3frcm4l0q9tcsk3jrx38urth03jtdfrqzlex3t4gnweqkyts4g9atjca

It's been a while since I posted an update

So for anyone wondering I'm in the middle of R&D and trying out two major tasks:

- Fjall the key value store instead of Sanakirja

- Extracting and improving the parsing part (think creating a database from the blocks) from the "parser" crate (or folder, in the v0.5 codebase) which would end up being only a "computer" now (and thus a more organized codebase with 4 major parts: iterator, parser, computer and server)

Both have the same goal which is massively improve the self-hosting experience

The latter is going well I think and is looking like a good base for a mempool.space like database/explorer/whatever (which was kind of already needed and there but in the right shape)

The reason for doing is because up to the v0.5 the databases are stateful, by that I mean that when you compute a block you can't go back as the databases have the state at a current height, it's to save disk space since sanakirja is very demanding on this side but had the disadvantage is the need to recompute the databases again each time we need to start from the beginning (because of a new dataset for example) which is a lot (like a LOT) of disk writes (and time !)

So the goal is to have an append only database instead which is pretty much one and done like the chain itself (and no I can't just use the chain, it's too slow)

The former on the other hand, isn't going as well as I hoped, reads and writes are okay, the space needed is absolutely great the database is tiny but the RAM usage is quite high (12-13 GB at block 400 000 which is not great) with fjall. I'll do more research and see what I can do with fjall but also trying out sanakirja with the new code and maybe even manually with mmaps by hand if none of them satisfy the requirements.

Again the reason for this is to limit disk usage as it's currently very very high and this takes priority over anything else

Overall I'm happy with my progress, you can check the current state of the extracted parser (named "bitbase") here: https://github.com/kibo-money/kibo/tree/v0.6-fjall/src/crates/bitbase

Please note that I might change to branch's name so the link might break at some point

nostr:nevent1qvzqqqqqqypzp963hhzdztlkunxxkcd3qtm3u3z77fzmeqct7s90v4n2dgjxzd7xqqsfksjccf5hnxymul6pz03w7pwfah59hwjw55ng2del4h3v7wnw3wq0khfvz

Happy new year !

Stay humble, stack sats and let's keep building 🫡

Merry Christmas everybody 🎄🕊️

Fjall (storage) looks very promising on the disk space side and write speed, not sure about reads as I’m still benchmarking it

If reads are at worst slightly slower, I’ll start replacing Sanakirja by this thing

It could be a huge improvement for all self hosters

Links:

https://github.com/fjall-rs/fjall

https://docs.rs/sanakirja

And making an app for iOS and/or Android is better ?

Piracy exists thanks to the web, like I said, freedom.

and of course I forgot the sign the note again 🥲

#Bitcoin is hope 🕊️

Historically the True Market Mean (which is basically the average price paid by investors, is pretty straightforward and doesn't use any magic number or crazy formula and was created by nostr:npub1qh5sal68c8swet6ut0w5evjmj6vnw29x3k967h7atn45unzjyeyq6ceh9r) with some probabilities (again without any magic just using past data) was enough to know the top (and the bottom)

I'm curious if it will hold true this cycle too

To learn more about it go to: https://kibo.money/assets/pdfs/glassnode/cointime-economics.pdf

I tried to make it super clear but it's not that easy but think of it as two balances, dollars and bitcoin

Here's how it works:

With the default settings, you start with $1000 and top up $150 every month and then you use the $1000 to buy bitcoin the first day and then you swap $5 every day, so basically every month you have a dollar balance of $150 that slowly goes down

Now if you change to swap amount from $5 to $10 you'll use your monthly $150 in 15 days instead of 30, which will change your average buy price, of course after setting it higher than 150 it won't change anymore

Hope it's clearer now

Sigh.. just realized that by fixing an issue for the Brave browser, I broke something for everybody but it’s fixed now, sorry !

And if you see a blank page, just refresh the page

#Bitcoin is hope 🕊️

Found and fixed the issue, brave devs are f*cking stupid even safari behaves properly

There is still a small bug where the input that you clicked on might not come to view, but again it seems to only be a Brave issue, they might fix it someday

That's definitely not intended, very weird ! I don't have an android but I hope I'll find a way to reproduce and fix it asap