Code Monkey home page Code Monkey logo

nostroots's Introduction

nostroots: nostrifying trustroots

Warning

This is not the active repo, we are actively working on nostr-map and that repo is automatically deployed to notes.trustroots.org.

Trustroots is a social network of travelers and hosts that offer couches. Founded in 2014, 108k+ members now. We're working on moving this onto nostr, see e.g. https://nostr.net/

nostroots is an initiative to seamlessly transition Trustroots, the platform for sharing, hosting, and community building, onto the nostr network. By leveraging the unique decentralized and open-source nature of nostr, nostroots aims to enhance Trustroots' community-focused ethos with greater privacy, security, and user autonomy.

So we need to get to a point where we have:

  1. a nostr app for hospitality exchange
  2. a relay server that offers the features we want, e.g. NIP-42

By moving onto Nostr development will become distributed and not centralized like it is now, so everyone can volunteer in their own autonomous way and with whomever they please.

current status

future

  • basic hospitality app
  • how to do profiles?

nostroots relay?

Limited access to the nostroots relay?

  • you can only post if you have credentials
  • you can only read if you have credentials, NIP-42
  • users can additionally choose to connect to other relay servers

There’s already authenticated relays. So only authenticated users can post.

Goals

sufficient decentralization:

  • anyone can run and fork the relay server
  • anyone can fork app

ideas

We could even cut off signups for the relay and let other folks take over. Force decentralisation politically, but might not be necessary.

Background

Hospitality Club was the biggest hospex network in 2004, depended on one person, website down for large parts of 2023. CouchSurfing(tm) sold out to venture capital. Several other networks are based on proprietary software and/or charge money to be a member. As networks grow there is a tendency to grow bureaucracies and budgets, which eventually lead to negative side effects such as usage fees, monetization of user data or too much reliance on donations.

We think it is worth our time and energy to work towards gift economy social networks that do not rely on any specific person or organization, so effectively we want to make ourselves redundant.

The Nostr protocol is a decentralized, open network for social networking and messaging, using cryptographic keys for identity verification.

It is great there are now hospex networks running on open source free software that are free to use, apart from Trustroots there are also BeWelcome and Couchers.org.

What is missing is more space for innovation and taking the gift economy into new directions. Think bicycle sharing, access to awesome parties, ride shares. Enabling Nostr on Trustroots will make it way easier for people with ideas to start off with a kickstart, just like Trustroots was kickstarted off Hitchwiki, but in a much smoother way. The user's data and their connections become portable, so that projects like Trip Hopping can immediately be useful, even if you are the only user.

How is Nostr different?

Data Ownership: In Nostr, users own their data. They can choose where to store it and which Nostr clients to use for interaction. This is in stark contrast to e.g. CouchSurfing(tm), where the company owns and controls user data, including its usage and monetization.

Decentralization: Unlike all existing hospitality networks, which are controlled by a single company or organization, Nostr is decentralized. It doesn't rely on a central server or entity. Instead, it operates through a network of independent servers, allowing for greater resistance to censorship and central control.

Identity Verification: Nostr uses cryptographic keys for identity verification. Each user has a unique pair of keys (public and private) for identity and authentication, contrasting with reliance on user-provided information like email or phone number that is used on almost all existing networks.

FAQ

(edit this: improve, add questions, answers)

Are you sure adopting new web technologies is a good idea for user experience?

"I've seen the sleepy.bike prototype from OpenHospitalityNetwork using Solid and I really think it's too much to expect from users to use decentralized web for now. I know even I would be reluctant on creating some "new tech account" just to use some hospitality website."

Generally we want to see an explosion of gift economy ideas… and all kinds of remixes of ideas around geo data, meeting people and organizing events. Trustroots is good at hospitality, so for the foreseeable future we will keep this working as is. But the meet functionality is hardly used by anyone, and there is a lot of untapped potential around circles, and connecting this to for example Hitchwiki and maps. We want to try to add Nostr functionality in this direction, without breaking the hospitality part, and in a way that it's easy for anyone to try to use or even build new things if they choose to.

ActivityPub, Solid vs Nostr

ActivityPub heavily relies on specific domains and sysadmins running servers. Solid is similar, but the protocol is kinda W3C-bloat. And there's no good profile portability. So if your favorite ActivityPub/Solid hospex network goes rogue and you want to move elsewhere you are out of luck.

Note that https://gitlab.com/soapbox-pub/mostr is a project to bridge ActivityPub and Nostr.

BeWelcome, couchers.org?

It would be great to at some point connect with BW and Couchers over Nostr.

tokens, dao, blockchain, other scams?

If you see "nostr token", run away, it is a scam. There's no nostr token. There was no nostr ICO, nostr is not a DAO, there is no blockchain. Nostr makes it easy to integrate bitcoin lightning, which may at some point be helpful to for example keep out spammers. But this is not something we are interested in for the foreseeable future.

nostroots's People

Contributors

chmac avatar guaka avatar joshuatbrown avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

nostroots's Issues

app thoughts

thoughts about the web client

  • we only care about the web app, others can and will build ios and android apps
  • turn circles into #tags?
  • forget about meet initially, it's hardly used now and we try a proper implementation later

parts that are mostly there in nostr clients:

  • messages
  • profile

essential and probably not there yet in existing clients:

  • map search
  • hosting profile -> #offer notes?

nice to have but not essential

  • contacts, especially experiences

NIP-72 for Developing a Decentralized TR Platform

copied here from https://pad.riseup.net/p/to2tz1IAWj06zPN3pUIF (mostly not my work except for fixing some typos etc)

TRIP-01 TRustroots Improvement Proposal

We propose leveraging NIP-72 to develop a decentralized TR platform. After evaluating various NIPs, NIP-72 stands out as an equally sensible and feasible approach.

It follows a rough outline to make the main technical spec easier to follow:

  • The core functionality involves users posting offers, profiles, and other actions as nostr events. 30397. These events will then be approved and signed by a NIP-72 TR moderator (30398), guaranteeing authentication and authorization as well as preventing spam and other abuse.
  • For private communication, NIP-17 messages will be used to facilitate direct messaging between TR users.
  • Sign-ups will still require an email account and verification. This offers the same spam protection from sybil attacks as now, which seems to suffice. At signup, we will offer a choice between a BYOK (Bring Your Own Key) approach and an IDKAK (I Don't Know or Don't Care About Keys) approach. Keys can also be exported at any point by the user. (This implies key rotation which is feasible because we are using 30xxx events, meaning we can rotate keys and then update and resign moderation messages)

Although there are minor issues to address, such as image hosting and out-of-band user notifications via email, these can be seen as difficult and without a straightforward solution (one due to Nostr not having a solution for decentralized image sources and the other due to private messages meaning we do not know who the sender of a message is). These challenges have multiple existing solutions, albeit not the most elegant ones and all not without trade-offs. Our focus remains on solving core problems, which appear to be manageable with sufficient elegance.

Profile Event

Kind 0

content

name

about

profile_pic (HARD)

Offer Event

Kind 30397 (updateable)

content, text description of the offer

tags

d: client-generated-unique-id

L: open-location-code, l: 22222222+222

Where this is, at some level of imprecision

L: open-location-code-prefix-6, l: 222222

The olc prefix so we can filter for this

L: open-gifting-spec, l: wheelchair-accessible

tags:

[L, open-gifting-spec]

[l, wheelchair-accessible, open-gifting-spec]

Query would be:

#L: open-gifting-spec

#l: wheelchair-accessible

Alternate idea:

L: open-gifting-spec, l: ogn-wheelchair-accessible

Query would be:

#L: open-gifting-spec

#l: ogn-wheelchair-accessible

L: open-gifting-spec, l: really-wide-open-eagerness-person-1-million

L: open-gifting-spec, l: ogn-can-host-6, ogn-can-host-5, ogn-can-host-4, ogn-can-host-3, ogn-can-host-2, ogn-can-host-1, open-gifting-spec

Alternate idea:

Query: ogn-can-host-3, ogn-can-host-4, ogn-can-host-5, ogn-can-host-6...

Moderation Event

Kind 30398

content: ""

Tags

d: 30397-author-public-key:30397-d-tag

L: open-location-code, l: 22222222+222, open-location-code

L: open-location-code-prefix-6, l: 222222, open-location-code-prefix-6

Copy other L/l tag combos, after some validation

Ideas

Add some kind of L:open-gifting-network-tribe, l: tribe-uuid

Some summary of the user's trust as defined by trustroots

e: 30397-event-id

This would link us to uniquely identifying a single 30397, if that event has been replaced, then our link would no longer work, rather than pointing to whatever the latest version of the event happens to be

FAQ

How does this approach allow us to combat spam?

Firstly, we maintain a list of all trustroots users and their public keys. Then, if a user who is not a trustroots user posts a 30397 event, we will not post a matching 30398 events. As clients should search for 30398 events, then anything we don't approve won't be included on the map.

If a site like triphopping.com also uses the same approach, interoperating could look like triphopping asking each user if they want to see "trustroots certified users", "triphopping certified user", both, or potentially "everything including potential spam". The everything option could query for 30397 events instead of 30398. When querying for 30398 events clients should specify a set of public keys that must have signed those events. That means if a user posts a 30398 event directly, it won't be included in the query, and so won't be shown on the map.

How do we handle users losing their private keys?

As we control (and publish) all 30398 events, we can just update them. If we believe a user has a new private key, we can remove all 30398 events that point to their previous events, and instead point to their new events. In effect, we can moderate what is shown on the map, but if we start making bad policy decisions, clients can decide 

How do we query for data?

Essentially, the idea is that users post events, and we watch for those events and post "we approve of this" type events. Then our clients search for the approval events instead of the original.

That means, if we change the format of our filters, we could update our approval events to include the new filter format. This is possible even though we can't control the private keys of all our users. The original user's event may not be updated for years, meanwhile we could go through several versions of the format for approval events.

What nostr apps would be a culture fit for trustroots?

The nostr community tends to be very bitcoin centric, which is not a good fit for the trustroots community. Are there corners of the nostr world which are a better fit culturally? If we can find some projects whose homepages don't read like a bitcoin maximalist bro party, that would be incredibly valuable as we could encourage trustroots users to experiment with them. Especially anything which fits into the gifting / no money space.

nostr rideshares

Some pointers around ridesharing:

  • it heavily relates to meet #12
  • we have hitchwiki.org which has plenty visits from hitchhikers, so we can kickstart this if we focus on this target group
  • we have rideshares.org and there's a repo https://github.com/Hitchwiki/nostrides

Random thoughts from v1

The prototype works. At least, you can publish a profile and some info. It doesn't have private messages. They would be next. But the underlying code already exists in nostr-tools for encrypting messages.

  • How do we handle the async data flows?
    • Redux?
    • Sagas?
    • Thunks?
  • Do we store data somewhere?
  • Do we keep subscriptions open? There's no clear need to unsubscribe.
    • But how do we feed data into React in that case?
  • Write a nostr-redux layer?
    • Dispatch actions, get data from nostr, fill redux
    • Is using the browser storage more idiomatic?
  • Do we cache data in browser storage?
    • Relays seem to be pretty quick so far, maybe simplest to leave this alone for now

Nostroots Collective 2024-05

tl;dr We’re organizing a Nostr Trustroots Collective this May near Berlin.

What

We want to nostrify trustroots.

When

Wednesday 22nd to Sunday 26th of May 2024.
Feel free to arrive a day or three beforehand.

Where

1 hour train ride from Berlin. Precise details shared with participants.

Why

In 2022 the main person behind Trustroots stepped away from the project, without even a message. When we realized email had been down for 5 weeks, we fixed it and made sure to increase the bus factor a little.

We think it is worth our time and energy to work towards gift economy social networks that do not rely on any specific person or organization, so effectively we want to make ourselves redundant. By moving onto Nostr development will become distributed and not centralized like it is now, so everyone can volunteer in their own autonomous way and with whomever they please.

Read more at https://github.com/Trustroots/nostroots

How, goals

Implement basic features in Trustroots that will make it possible for anyone to build Nostr apps connecting this.

Wanna come join? Fill in this form.

(If you can't make it or want to participate remotely you can use this Google Form)

NOTE: We are not seeking general feedback on this nostr mission, but if you insist on sharing that, please do so in a new issue and not here. This issue is about organising the collective.

Test keys

Logging test private keys here just in case we want to clean up our mess...

eec991e291ecf1868cf1fdb38c3fa83500b4334192ac518ba378e6d8ace477e4

thoughts on contacts and experiences

  • turn contacts and experiences into notes
  • ideally thru NIP standard
  • nice to display as map
  • nice to display as graph
  • nice to use FOAF connections (friend of a friend)
  • this could be a separate app

`README.md` has link to relative URL `nostr.net` which does not work (points to something at github.com). Should be `https://nostr.net/`.

In the README.md, there is a link to nostr.net:

[https://nostr.net/](nostr.net)

This does not work, as the link target points to the relative URL nostr.net. When the README.md is viewed just by opening https://github.com/Trustroots/nostroots, for example, it will point to https://github.com/Trustroots/nostroots/blob/main/nostr.net, which does not exist.

The link target needs to be https://nostr.net/, not nostr.net.

Regards!

Research nostr based chat apps

We have a basic prototype running nostr-map. One way to expand that test would be to encourage users to use their trustroots created private key on another app. For example, adding some kind of chat feature to the map which is also usable from a separate nostr app. The task here is to research which apps or projects could be a good fit for this.

Some thoughts to consider include:

  • What kind of nostr messages does the app use?
  • Does the chat app send notifications somehow? For example, if it's a mobile app versus a web app and so on.
  • Do you think the app maintainers would be open to collaboration? If it's a smaller app with few users, then promotion on trustroots could be valuable to them.
  • What's the culture like? Nostr in general can be very bitcoin bro heavy, which is a bad fit for trustroots. Ideally we'd find potential collaborators from the nostr space which are more culturally compatible.

ideas

possible steps, not per se in this order, many of these should have instant gratification

  • NIP-05 on trustroots.org
  • set up relay server that only accepts notes from @trustroots.org users
  • and ideally only allows sharing with @trustroots.org users
  • show notes at https://www.trustroots.org/circles/hitchhikers
  • connect with ~400 hitchhikers on signal/matrix group
  • get more people to play with this in other ways
  • heuristics to map notes to other circles if appropriate (e.g. dumpster, trash)
  • add geo data to notes
  • build hospitality-style features
  • build map-like features, could be hospitality, but also hitchmap, trashmap
  • run an additional relay on another domain

I hate to do this.

Post by @zweifeln

I hate to do this.

I love open source. I love the sharing economy. (Though I don't really believe in the "gift" economy. Gift and economy doesn't go together. But that's beside the point.)

Every de-central approach; every maintained open source project has someone (or a rather small group of people) who take care of it. Sometimes they have a business model (like my employer does), sometimes these people have a different form of income and do it as their hobby. That's great. Sometimes these people will stop maintaining things and then half the internet may break. That's bad but it is how it has been the past 30 years.
I strongly believe it is very helpful to acknowledge that before going forward with any decentralizing idea.

Someone is actually in charge.
Someone needs to write the code and maintain it. Install updates and keep the servers running. Yes, software can update itself - but only as long as the updating part of the software itself works all fine. Software the harddrives need to be changed and sometimes software just breaks. Then there is need for someone who knows what's happening. So we rely on them.
That is the case no matter how good a programmer one might be. If you didn't work with that software, you don't know the libraries and frameworks.
We're having this topic here on Github. A platform owned (and maintained) by microsoft.
The only really free, decentralized software widely used out there … is e-mail. But who of you actually runs their own e-mail server? (I don't. It's too much pain.)
The point cannot be to be totally independent. Yes, that sounds nice but in reality it means, you are alone.
The point is trust. The thing that is already in our name. Some people have the knowledge and willpower to develop software and run it. Others will trust them and use it. That is okay. And that means, the people not running the software will trust their platform. Or not - then they will leave the platform.
Similar to how not every human on earth is making their own bread. Most of us are just buying it in a bakery. (Or don't eat bread). It is not sustainable for everyone to make their own bread. And certainly not practicable for everyone to grow their own grain.

We rely on people not on software. That is a good thing. Let's acknowledge that.
When we do that, we can go forward and make some system that is easier to maintain and better usable to more people - also non tech-people.
Running decentralized software is - unfortunately - not actually decentralized. No matter how easy it seems to tech people. It may seem easy for us who we are comfortable using Github. But it actually is quite elite. Most people I have met traveling the past 8 weeks don't know what Github is.

The point is not the software. The point is how to make it sustainable. How to have a community that is trusting each other and how that spirit might continue even when central people step back for whatever reasons. There are lots of good reasons. So often people get pressured into keeping a central role as it all would fall apart if they step back. But maybe they got sick or take care of sick people or children or maybe they are just tired after doing it for so long and actually just wanna travel themselves and enjoy live.
The the hard question is: how to keep things running. How to make sure the community has enough trusted people to step in if someone steps back. How to develop and maintain a beautiful community.
That is more a philosophical than a technical question but that is the central question.

Originally posted by @zweifeln in #11 (comment)

What to put on nostr?

Here's a little essay that I had thought to tell @guaka by phone!

I was thinking this morning about the nostr experiment. What can people do on it? That's the question I focused on. Replicating a poor quality copy of the current trustroots experience doesn't make a lot of sense. Folks might use it, but presumably they only use it if they're really motivated to try nostr, or just love p2p, etc. Otherwise, why bother?

Which led me to consider, what about putting something else on nostr? A few ideas came up:

  1. Events, start time, end time, location, description, show events sorted by date in a given location...
  2. Real time chat per circle
  • This might not be the best experience if there are no notifications
  • We could probably rig up something to send emails when people receive messages, but that will require a bunch of custom server side code I believe
  1. A forum style of discussion, something where it's more expected that you won't get immediate replies so notifications won't be such an issue
  2. A question & answer style site, stackoverflow but on nostr
  3. Other kinds of gifts, which could be anything, shown on a map
  • The obvious challenge with this seems to be that if nobody uses it, it's kinda pointless to put a gift on it, chicken and egg problem...
  1. Tour guide type recommendations, stuff that's recommended by trustrooters to see in a given location
  2. Notes with locations, put any text with a location and show them all on a map
  3. Expiring notes with locations, same as above but they expire after 1, 7, 30 days or something

What else?

Thoughts

Personally, I think it makes sense not to put hospex on nostr at first.

We could also launch a simple demo without doing any trustroots integration. It just gets linked from trustroots. It might get spammed. We can see how it goes. Most likely it'll simply be ignored.

I'm leaning towards starting with simple notes and adding a location. We don't need to add any extra functionality to nostr to be able to do that. We can just designate a location field and then crack on. We can load all the data on every page view. If that becomes problematic we could react accordingly.

I'm liable to proceed with something like this unless I hear contra feedback or better ideas are proposed...

Blog post

@guaka started writing a blog post...

tl;dr - We want to make sure that Trustroots exists 2 decades from now and unlock sharing beyond hospitality: rides, bicycles, meals, parties, etc.

Trustroots has already had a brush with death. The project lead stepped away without a word. Only one other person had access to most of the servers. We've seen the same issue with other hospitality sites. CouchSurfing took venture capital investment which slowly rotted out the site. Warm showers had major management clashes. Hospitality Club has had long periods of downtime as there's only one person running it.

Instead of just having one Trustroots, with one set of administrators, we want to have many. A network of connected sites. Maybe focused on different things. Some focused on bike tourers. Some on sharing rides. But each user's data, it lives across multiple sites. The user themselves has control over the data. If one site dies, you can log in somewhere else and still keep all of your connections, messages, and references. No one person can step away from the project and have it all come crashing down.

Plus, people can start sites with new features. Instead of sites like couchers starting over and building a network from scratch, they could start from the Trustroots users. When trustroots user logs into to a new site, all of their data comes with them. This is the major challenge for all new networks. When there's nobody on the network, it's not very useful. This makes it hard to experiment, to try new features. Hopefully, we can, slowly, make this easier.

We hope this is possible on something called nostr. We've looked at other decentralised technologies, but nostr is the first option that seems like it might work.

We don't have the illusion that we can move all of Trustroots over to nostr in a year. But we don't need to. We can enable small parts and then others can build on these foundations.

NIP-05: [email protected]

Seems easy to implement early 2024:

UPDATE: better provide nsecs for everyone right away

  • nsecbunkerd #17
  • .well-known/nostr.json
  • show npub and NIP-05 on profiles (

probably add another section here, replace ELSEWHERE with NOSTR:
image
(and NOSTR can even link to a page with apps that can use this)

Current state and roadmap

Current state: there is a basic nostr app in this repo but it is no way connected to the web app running at trustroots.org.

Before we get to a roadmap we first need to clarify how we want to approach this. So I will just write down some of my thoughts.

Rewriting the entire Trustroots app based on nostr is too much, the architecture of the app isn't great. I think it's better to slap nsecs (e.g. with #17) onto user profiles and enable NIP-05 #4 so that trustroots users can use any nostr app as [email protected].

Now if we build one or more basic nostr apps we can encourage people to use these. Good candidates are something around chat and location, we can use geo tagged nostr notes for this #10. Since the current Meet functionality is hardly used by anyone we can rip this out and instead link to a "Beta" page that shows these apps (@chmac idea). App ideas:

Comments very welcome.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.