A relationship-first social app informed by social brain theory, rebuilt for a world with portable identity.
Tribe is a mobile-first social product for people who want a calmer, more intentional network. Instead of flattening everyone into the same follower graph, Tribe organizes relationships into bounded circles inspired by social brain theory and Dunbar-style limits:
innerup to 5closeup to 15tribeup to 50villageup to 150
It is also the latest step in a much longer product journey.
Tribe is an evolution of earlier attempts to build socially healthier software around the science of human relationship limits.
About five years ago, that idea started as Social Brain Network, an Instagram-style social app built around grouping relationships according to social brain theory. It aimed at the right problem, but ran into the classic cold start problem: a better social graph model does not matter much if your people are not there yet.
That led to a simpler follow-up called Social Brain Contacts, a mobile app that grouped people from your phone contacts into meaningful relationship layers. It reduced the cold start problem by using a graph users already had, but it also gave up the power of a portable online identity and a shared networked social layer.
Tribe is the next swing:
- keep the science-informed model of relationship tiers
- keep the emphasis on intentional social design
- avoid starting from zero
- use the AT Protocol so identity is portable and infrastructure is federated
- tap into an existing online social graph instead of hoping everyone joins a brand-new network from scratch
Most social apps optimize for reach, engagement, and scale. Tribe is designed around a different premise: people have finite attention, finite intimacy, and finite relational bandwidth.
Tribe is for users who want:
- a smaller and quieter social layer
- audience control that maps to real relationships
- identity they can carry with them
- a path beyond the cold start problem of new social apps
This repo is a pnpm monorepo with:
apps/mobile: Expo Router React Native client for iOS and Androidapps/api: Fastify API with Drizzle-based Postgres compatibilitypackages/shared: shared product types, validation schemas, and domain helpers
At the moment, the project uses AT Protocol primarily for identity and authentication. The broader vision is a product where portability, federation, and science-informed social design reinforce each other.
Today the app includes:
- AT Protocol sign-in with native OAuth on iOS development builds
- a demo/local sign-in path for faster product iteration
- onboarding that asks users to shape their circles intentionally
- tier-based feeds and posting
- private relationship tiers rather than one flat friend/follower model
The long-term direction includes deeper Bluesky and AT Protocol interoperability, but the current implementation is intentionally scoped so the core product can be tested quickly.
This repo requires Node.js 20.19.4 or newer.
-
Install dependencies:
nvm use || nvm install 20.19.4 pnpm install -
Copy env files:
cp .env.example .env cp apps/mobile/.env.example apps/mobile/.env
-
For real AT Protocol OAuth, fill in the blank values in
apps/mobile/.env:EXPO_PUBLIC_ATPROTO_CLIENT_IDEXPO_PUBLIC_ATPROTO_CLIENT_URIEXPO_PUBLIC_ATPROTO_REDIRECT_URI
-
Start the API:
pnpm dev:api
-
Start the mobile app:
pnpm dev:mobile
-
Or start both the API and iOS simulator flow together:
pnpm dev:ios
-
To run a native iOS development build with custom native modules such as AT Protocol OAuth:
pnpm dev:ios:native
-
To generate a free-hosted OAuth metadata site for a Cloudflare Pages-style hostname:
pnpm atproto:prepare-pages -- --host tribepreview.pages.dev
That writes a deployable static site to
dist/atproto-oauth-siteand prints the exact mobile env values to copy intoapps/mobile/.env.
- The API runs against in-memory
PGliteifDATABASE_URLis unset, and switches to Postgres-compatible mode whenDATABASE_URLis provided. - Supabase is intended as the managed Postgres and storage layer behind the API, not as the client-auth boundary.
pnpm dev:iosuses Expo Go. That is enough for the demo/local flow, but Expo Go cannot load@atproto/oauth-client-expo; real AT Protocol sign-in needs a native development build.pnpm dev:ios:nativeusesexpo run:iosand requires local Xcode and iOS simulator tooling. On first run it will generate native project files and compile the iOS app.- The native redirect URI must match the app scheme in
apps/mobile/app.config.ts. The mobile app derives its scheme fromEXPO_PUBLIC_ATPROTO_REDIRECT_URI, so changing that value requires rebuilding the iOS development app. - A free
*.pages.devhost works for development. The helper command reverses the host labels into the native callback scheme for you, sotribepreview.pages.devbecomesdev.pages.tribepreview:/auth/callback.