Damus

Recent Notes

hzrd149 profile picture
Cool, although you will have to wait till I'm able to release V5. And there will probably be bugs I'll need help fixing :)
hzrd149 profile picture
How are you supposed to request a relay to delete nip-17 gift wraps when you can't prove you created them?
hzrd149 profile picture
yeah, sorry the config.yml is a bit of a mess. I had plans to make it pretty flexible and configurable but I should have just stuck to a simple whitelist. glad you got it running though
hzrd149 profile picture
cashu-ts, all the operations are just swapping tokens and the state is stored as nostr events.
Its probably not as reliable as coco since nostr events are unreliable.
hzrd149 profile picture
If your using applesauce then there is a simple persistEventsToCache() method that takes an event store and a async methods to save batches of new events to a local cache 👍
hzrd149 profile picture
Been working on applesauce V5 and one of the biggest changes is simplifying the API and hopefully making it so that the user ( and AI agent ) doesn't have to fully understand RxJS when using the library.

To test this I've been having fun building out a NIP-60 wallet that does not show a random balance every time you open it. and it has a much lower chance of loosing your money compared to other NIP-60 wallets I've tested :)

Jokes aside this is 1200 lines of code ( probably 80% is react UI components ) and it has all the features Id want in a wallet. I've still got a few minor bugs and its missing a send and zap tab but when its finished it will probably less than 1500 lines of code
https://cdn.hzrd149.com/4649147547f5a8bad6364c98dcbab334c50be0f323fcc0f3d0e97cf2d2ff6417.webm
hzrd149 profile picture
Discipline them...

Honestly not sure though. the API for applesauce isn't very similar to other libraries that the models are used to. so it either takes a large "rules" context for them to understand it. or I have to clean up the API

For applesauce V4 I've found the most success by pointing them at the specific examples in the "examples" folder that I want them to copy. although that means that depending on how much code you give them it will fill up their context window. So I've been doing a lot of cleanup on the API for V5 that will hopefully make it easier for AI models to at least guess what the method names are :)
hzrd149 profile picture
Not sure, noStrudel overrides the "client" tag when the event is modified in the client but it does it best to preserve any existing tags or extra fields in the JSON. so they are probably coming from another client 🤷
hzrd149 profile picture
I would say use this, https://github.com/hzrd149/window.nostrdb.js
Its built to auto connect to a local relay at ws://localhost:4869 or fallback to indexeddb. I've been meaning to add support for WASM via @npub1v0lxx...'s worker relay but I haven't figured out how to package it yet

And as @npub1elta7... mentioned I built a small extension that automatically injects the window.nostrdb api 😁

If you don't want to use my magic library then https://github.com/hzrd149/nostr-idb or the @npub1v0lxx...'s worker relay is great

https://hzrd149.github.io/applesauce/examples/#database/worker-relay
hzrd149 profile picture
It's definitely got a little more quiet around here. Luckily, it's still easier and more fun building on nostr