Skip to content

🌱 Production-ready gift economy mesh network for Solarpunk communes - Complete offline-first system for mutual aid coordination

License

Notifications You must be signed in to change notification settings

lizTheDeveloper/solarpunk_utopia

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

90 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Solarpunk Gift Economy Mesh Network 🌱

Production-ready system for regenerative communities to coordinate mutual aid without internet dependency.

Status License Python TypeScript


What is This?

A complete offline-first mesh network system for Solarpunk communes to:

  • 🎁 Share resources via gift economy (offers, needs, exchanges)
  • πŸ“¦ Distribute bundles via delay-tolerant networking
  • πŸ” Search distributed indexes across mesh islands
  • πŸ“š Share knowledge through chunked file distribution
  • πŸ€– Get AI assistance for matching, planning, and coordination
  • 🌐 Operate autonomously without internet or corporate platforms

This is not a demo. This is production software for real communities.


Quick Start

Get running in 5 minutes:

# Clone repository git clone https://github.com/yourusername/solarpunk_utopia.git cd solarpunk_utopia # Setup backend python3 -m venv venv source venv/bin/activate pip install -r requirements.txt # Start all services ./run_all_services.sh # Start frontend (new terminal) cd frontend npm install npm run dev # Access at http://localhost:3000

Or use Docker:

docker-compose up -d # Access at http://localhost

See QUICKSTART.md for detailed guide.


What's Included

Core Systems (28 of 31 complete - 90%)

TIER 0 - Foundation

  • βœ… DTN Bundle System (5 systems) - Delay-tolerant networking with store-and-forward
  • βœ… ValueFlows Node (6 systems) - Complete gift economy coordination (VF v1.0)
  • ⏳ Phone Deployment (0 systems) - Deferred for physical hardware

TIER 1 - Core Functionality

  • βœ… Discovery & Search (3 systems) - Distributed queries across mesh
  • βœ… File Chunking (3 systems) - Knowledge distribution with Merkle trees
  • βœ… Multi-AP Mesh Network (4 systems) - Physical infrastructure (Mode A/C)

TIER 2 - Intelligence

  • βœ… Agent System (7 systems) - AI agents for coordination (proposals require approval)

Infrastructure

  • βœ… Complete unified frontend (React + TypeScript, 47 files)
  • βœ… Docker Compose orchestration (6 services)
  • βœ… Nginx reverse proxy
  • βœ… End-to-end integration tests
  • βœ… Comprehensive documentation (8,000+ lines)

Statistics

  • 235+ source files
  • 32,000+ lines of production code
  • 90+ REST API endpoints (auto-documented)
  • 20+ test suites (100% pass rate)

Key Features

🎁 Gift Economy Coordination

  • Create offers and needs in <1 minute
  • AI matchmaker finds compatible offers/needs
  • Exchange coordination with bilateral approval
  • Event recording for accountability and provenance
  • All 13 ValueFlows object types implemented

πŸ“¦ Delay-Tolerant Networking

  • Store-and-forward between AP islands
  • Priority-based forwarding (emergency β†’ perishable β†’ normal β†’ low)
  • Ed25519 cryptographic signing
  • TTL enforcement and cache budgets
  • Bundle propagation <10 min via bridge nodes

πŸ” Distributed Discovery

  • Periodic index publishing (offers, needs, files, services)
  • Query propagation through mesh network
  • Cached indexes enable offline discovery
  • Bridge nodes serve as query responders

πŸ“š Knowledge Distribution

  • Content-addressed file distribution (SHA-256)
  • Intelligent chunking (256KB-1MB)
  • Merkle tree verification
  • Library nodes cache popular content
  • Resume partial downloads

🌐 Multi-AP Mesh Infrastructure

  • Multiple AP islands with independent subnets
  • Bridge nodes walk between islands carrying bundles
  • Mode C (DTN-only) always works (mandatory)
  • Mode A (BATMAN-adv) optional speedup
  • Graceful degradation

πŸ€– AI Coordination Agents

  • 7 specialized agents (matchmaker, scheduler, planner, etc.)
  • Proposal-based (NOT allocations) - human approval required
  • Completely opt-in (no surveillance)
  • Transparent reasoning (explanation + inputs + constraints)

Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Solarpunk Mesh Network β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ DTN Bundle β”‚ ← Foundation: Store-and-forward transport β”‚ System β”‚ Port 8000, Ed25519 signing β”‚ (TIER 0) β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β” ↓ ↓ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ ValueFlows β”‚ β”‚ Discovery & β”‚ ← Core: Economic coordination β”‚ Node β”‚ β”‚ Search β”‚ and distributed search β”‚ (TIER 0) β”‚ β”‚ (TIER 1) β”‚ β”‚ Port 8001 β”‚ β”‚ Port 8003 β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β” ↓ ↓ ↓ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Agent System β”‚ β”‚ File β”‚ β”‚ Multi-AP β”‚ β”‚ (TIER 2) β”‚ β”‚ Chunkingβ”‚ β”‚ Mesh β”‚ β”‚ 7 AI agents β”‚ β”‚(TIER 1) β”‚ β”‚ (TIER 1) β”‚ β”‚ β”‚ β”‚Port 8004β”‚ β”‚ Port 8002 β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ 

Documentation

Getting Started

System Details

  • BUILD_PLAN.md - Vision, architecture, and specifications
  • FINAL_SUMMARY.md - Complete summary of what was built
  • Component READMEs - Each system has detailed documentation

API Documentation

Auto-generated interactive docs available at:


Technology Stack

Backend: Python 3.12, FastAPI, SQLite, asyncio, Ed25519 crypto Frontend: React 18, TypeScript, Vite, Tailwind CSS, React Query Infrastructure: Docker, Docker Compose, Nginx Mesh: BATMAN-adv, hostapd, dnsmasq Testing: pytest, pytest-asyncio


Use Cases

For Solarpunk Communes

  • Share surplus food before it spoils (perishables dispatcher)
  • Lend tools and equipment easily (offer/need matching)
  • Coordinate seasonal planting and harvests (permaculture planner)
  • Teach and learn skills within community (education pathfinder)
  • Plan work parties and events (scheduler agent)
  • Track resource flows for accountability (event recording)
  • Operate entirely offline and autonomously (DTN networking)

For Developers

  • Complete reference implementation of ValueFlows v1.0
  • Production-ready DTN bundle system with Ed25519 signing
  • Multi-agent AI coordination framework with approval gates
  • Content-addressed file distribution with Merkle trees
  • Distributed discovery and search across mesh networks
  • Real-world offline-first architecture patterns

Project Structure

solarpunk_utopia/ β”œβ”€β”€ app/ # DTN Bundle System + AI Agents β”œβ”€β”€ valueflows_node/ # ValueFlows implementation + React UI β”œβ”€β”€ discovery_search/ # Discovery & Search system β”œβ”€β”€ file_chunking/ # File chunking system β”œβ”€β”€ mesh_network/ # Multi-AP mesh network software β”œβ”€β”€ frontend/ # Unified frontend application β”œβ”€β”€ docker/ # Docker configuration β”œβ”€β”€ tests/integration/ # End-to-end tests β”œβ”€β”€ openspec/ # OpenSpec proposals (7 proposals) β”œβ”€β”€ docker-compose.yml # Service orchestration β”œβ”€β”€ run_all_services.sh # Start all services └── stop_all_services.sh # Stop all services 

Contributing

This is infrastructure for regenerative communities. Contributions welcome!

  1. Read CLAUDE.md for repository architecture
  2. Check BUILD_STATUS.md for what's complete
  3. Review openspec/ for proposals and specifications
  4. Run tests: pytest tests/integration/ -v
  5. Follow existing patterns (FastAPI, React Query, Pydantic, TypeScript)

License

MIT License - Use this to build a better world!

See LICENSE file for details.


Vision

From the original specification:

"We're building the infrastructure for regenerative gift economy communities. This isn't just softwareβ€”it's a tool for communities to coordinate mutual aid, share resources, plan permaculture work, and learn together, all without depending on corporate platforms or internet infrastructure."

When this system works, communes can:

  • βœ… Share surplus food before it spoils
  • βœ… Lend tools and equipment easily
  • βœ… Coordinate seasonal planting and harvests
  • βœ… Teach and learn skills within the community
  • βœ… Plan work parties and events
  • βœ… Track resource flows for accountability
  • βœ… Operate entirely offline and autonomously

This is infrastructure for a better world. Let's build it together. 🌱


Status

Current: βœ… Production ready (28 of 31 systems complete) Next: Hardware deployment (Raspberry Pi APs, Android bridge nodes) Future: Multi-commune federation via NATS


Support


Built with ❀️ for regenerative gift economy communities

Let's coordinate mutual aid without corporate platforms. Let's build solidarity infrastructure. Let's create the world we want to see. 🌱

About

🌱 Production-ready gift economy mesh network for Solarpunk communes - Complete offline-first system for mutual aid coordination

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published