Shaostoul/Humanity
Humanity is an open, public-domain project exploring how humans can live together with dignity, cooperation, and long-term continuity. It combines civilizational principles with rigorous system design to model learning, stewardship, and peaceful scalability.
Humanity
Wholesomely aiding humanity's betterment.
An open-source cooperative project to end poverty through education and technology. Not charity โ capability. Public domain. Built by volunteers. For everyone.
๐ united-humanity.us ยท ๐ฌ Chat ยท ๐ฆ GitHub ยท ๐ Discord
What It Is
Humanity is two things built together:
-
HumanityOS โ a real-world platform for communication, collaboration, and life management. Chat, DMs, voice calls, project boards, marketplace, skill tracking, inventory, maps. Think of it as an operating system for your life that you actually own.
-
Project Universe โ a free game that teaches practical skills (homesteading, agriculture, building, health) by using the same underlying data layer as the real platform. Your in-game skills reflect real-world capability.
Both share the same server, identity system, and data layer. The game is how people learn to use the tools for real.
What's Live
Pages (18 standalone pages at /)
| URL | Page | What it does |
|---|---|---|
/chat |
Network | Chat, DMs, voice, video, streaming |
/home |
Home | Multi-location manager (real, digital, fleet homes) |
/profile |
Profile | Your identity, bio, links, streaming platforms |
/skills |
Skills | Browse and manage skills by domain |
/dashboard |
Dashboard | 10 customizable widget types |
/inventory |
Inventory | Track what you own |
/equipment |
Equipment | Gear and loadout management |
/quests |
Quests | Mission and goal tracker |
/calendar |
Calendar | Events and planning |
/logbook |
Logbook | Personal journal |
/systems |
Systems | Kanban project board with task IDs |
/maps |
Maps | World map, earth view, sky view |
/market |
Market | Peer-to-peer listings for goods, services, skills |
/learn |
Learn | Web directory โ 52 curated sites |
/knowledge |
Knowledge | Knowledge base and wiki |
/streams |
Streams | Live streaming interface |
/settings |
Settings | Themes, fonts, account management |
/ops |
Ops | Server admin and debug tools |
Communication (the core, fully working)
- Channels โ admin-created rooms with descriptions and categories
- E2E encrypted DMs โ ECDH P-256 + AES-256-GCM, server never sees plaintext
- Threaded replies โ reply to any message with collapsible threads
- Voice channels โ persistent, always-on WebRTC mesh rooms
- 1-on-1 video calls โ WebRTC peer-to-peer with audio, video, screen share, PiP
- @mentions, emoji reactions, message editing, message search
- Image sharing with lazy-loaded placeholders
- Browser push notifications and 6 notification sound options
- Typing indicators and unread markers
Identity & Privacy
- Ed25519 cryptographic identity โ keys stored in your browser, never on server
- Multi-device key linking โ same identity across devices
- Device management โ list, label, and revoke linked keys
- Key backup, export, and import
- Encrypted user data sync โ settings, follows, profile encrypted at rest
- No IP logging, no analytics, no tracking
Social
- Follow/friend system โ mutual follow = friends, friends unlock DMs
- Friend codes โ 8-character codes with 24-hour expiry, auto-mutual-follow
- User profiles with bio, pronouns, location, website, privacy controls
- Unique pixel-art identicons per user
- Groups โ private group conversations
- Client-side user blocking and report system
Productivity Tools
- Project board โ kanban-style with visible task IDs
- Marketplace โ peer-to-peer listings, kiosks, donation pricing presets
- Asset library โ file upload, browse, tag, preview
- 118-element catalog, 44 materials, processing chains
- Browse directory โ 52 curated sites with uptime pings and domain info
- Dashboard โ 10 widget types, customizable layout
- Notes, Todos, Garden tracker
Platform
- PWA installable โ works on mobile, add to homescreen
- Desktop app โ Tauri v2 for Windows, macOS, Linux
- Command palette โ quick navigation
- Dark/light themes, accent colors, font size controls
- Auto-reload on deploy โ no manual refresh needed
Moderation & Federation
- Role-based: admin ๐, mod ๐ก๏ธ, verified โฆ, donor ๐
- Kick/ban, invite codes, auto-lockdown when no mods online
- Phase 1 federation โ anyone can host; servers discover each other
- Single binary, zero dependencies, under 10 minutes to self-host
- Verified servers that adopt the Humanity Accord earn highest trust
Architecture
| Component | Technology |
|---|---|
| Server | Rust (axum + tokio) |
| Storage | SQLite (rusqlite) |
| Transport | WebSocket + WebRTC |
| Client | Plain HTML/CSS/JS โ no build step |
| Identity | Ed25519 (signing) + ECDH P-256 (encryption) |
| Desktop | Tauri v2 |
| Hosting | nginx + systemd |
| Layout | Cargo workspace |
Codebase Structure
Humanity/
โโโ crates/
โ โโโ humanity-relay/ โ Rust WebSocket relay server
โ โโโ src/
โ โ โโโ main.rs โ Entry point, routing, axum setup
โ โ โโโ relay.rs โ WebSocket handler (~5600 lines, message routing)
โ โ โโโ handlers/ โ Extracted relay helpers
โ โ โ โโโ broadcast.rs broadcast_peer_list, broadcast_channel_list, etc.
โ โ โ โโโ federation.rs server-to-server connections
โ โ โ โโโ utils.rs is_private_ip, fetch_link_preview, html_decode, etc.
โ โ โโโ storage/ โ SQLite domain modules
โ โ โ โโโ mod.rs Storage struct, open(), schema migrations
โ โ โ โโโ messages.rs, channels.rs, dms.rs, social.rs, profile.rs
โ โ โ โโโ reactions.rs, pins.rs, marketplace.rs, streams.rs
โ โ โ โโโ board.rs, assets.rs, skill_dna.rs, misc.rs, uploads.rs
โ โ โโโ api.rs โ HTTP REST API endpoints
โ โโโ client/ โ Web client (no build step)
โ โโโ index.html โ Chat page โ loads all scripts in order
โ โโโ app.js โ Core: state, connect, handleMessage, switchChannel
โ โโโ chat-messages.js reactions, editing, pins, typing, threads
โ โโโ chat-dms.js DM state and conversation list
โ โโโ chat-social.js follow/friend system, groups
โ โโโ chat-ui.js notifications, sidebar, search, commands
โ โโโ chat-voice.js voice rooms, 1-on-1 calls, video, sidebar
โ โโโ chat-profile.js profile edit/view modals
โ โโโ chat-p2p.js P2P contact cards, WebRTC DataChannel
โ โโโ crypto.js Ed25519/ECDH/AES helpers
โ โโโ base.css, layout.css, sidebar.css, messages.css
โ โโโ modals.css, voice.css, inputs.css
โ โโโ style.css โ Original (kept for reference)
โโโ *.html โ 18 standalone pages (home, profile, skills, etc.)
โโโ shared/
โ โโโ shell.js โ Nav bar โ inject on every page
โ โโโ settings.js โ Theme/font settings
โ โโโ theme.css โ CSS variables and base theme
โโโ game/
โ โโโ index.html โ Game hub (HTML structure only)
โ โโโ js/ โ Game JS modules
โ โ โโโ core.js, reality.js, fantasy.js, celestial.js
โ โ โโโ streams.js, browse.js, map.js, info-market.js
โ โโโ data/ โ Static JSON data (fetched on demand)
โ โโโ solar-system.json, stars-nearby.json, stars-catalog.json
โ โโโ constellations.json, cities.json, coastlines.json, milky-way.json
โโโ desktop/ โ Tauri v2 desktop app
โโโ accord/ โ Humanity Accord (civilizational principles)
โโโ design/ โ Architecture and design documentation
โโโ SELF-HOSTING.md โ Production server setup guide
The client uses no build step โ plain <script src=""> tags load modules in dependency order. All modules share global scope (no ES modules). When in doubt about a function's location, grep the client/ directory.
Adding a New Page
- Create
yourpage.htmlat the repo root (copy any existing page as template) - Add
<script src="/shared/shell.js" data-active="yourkey"></script>in<head> - Add
navTab('/yourpage', 'icon.png', 'Label', 'yourkey')toshared/shell.js - Add a mobile drawer entry to
shared/shell.js - Add nginx route:
location = /yourpage { try_files /yourpage.html =404; }on the server - Deploy:
scp yourpage.html server:/var/www/humanity/
Security
- Server-side Ed25519 signature verification on every message
- E2E encrypted DMs (ECDH P-256 + AES-256-GCM) โ server never sees plaintext
- Encrypted user data sync โ profile, settings, follows encrypted at rest
- Fibonacci rate limiting + new-account slow mode
- Content Security Policy, HSTS, TLS 1.2+ only
- No IP logging
- Per-session upload tokens with magic-byte validation
- HMAC-SHA256 webhook verification
- Non-root systemd service with hardened sandboxing
- Full audit:
SECURITY_AUDIT.md
Transparent AI Development
This project is pioneering fully transparent AI development. Our AI assistant Heron ๐ชถ (named after Hero of Alexandria) operates with complete openness โ public memory files, no black box, every decision documented.
โ See live AI memory ยท AI workspace rules
Host Your Own Server
Anyone can run a Humanity relay. No permission needed.
git clone https://github.com/Shaostoul/Humanity.git
cd Humanity
cargo build --release -p humanity-relay
./target/release/humanity-relayPut it behind nginx with TLS (Let's Encrypt is free). People connect with their existing keypair โ no migration needed.
โ Full self-hosting guide โ nginx config, systemd, federation, admin commands
Want verified federation status? Publicly adopt the Humanity Accord and contact @Shaostoul.
Get Involved
- ๐ฌ Chat first โ united-humanity.us/chat โ no account needed, just a username
- ๐ Discord โ discord.gg/9XxmmeQnWC
- ๐ฆ GitHub โ github.com/Shaostoul/Humanity
- ๐ New contributors โ start with ONBOARDING.md
Writers, designers, developers, educators, translators โ or just someone who cares. Show up and ask what needs doing.
Donate โ Every dollar goes toward development and hosting.
โ GitHub Sponsors
Links
๐ฅ YouTube ยท ๐บ Twitch ยท ๐ข Rumble ยท ๐ X/Twitter ยท ๐ท Instagram ยท ๐ต Bluesky ยท ๐ Reddit
License
Public domain โ CC0 1.0. No permission required. No attribution required. This belongs to humanity.