Skip to content

Latest commit

 

History

History
126 lines (93 loc) · 3.44 KB

File metadata and controls

126 lines (93 loc) · 3.44 KB

HackOn Agent

Decentralized P2P AI Agent network using idle compute resources.

Owned by Bernie Nguyen (BernieWeb3) · HackOn Team

About

HackOn Agent is a decentralized AI agent network that leverages idle compute resources to provide AI capabilities without relying on centralized cloud services. The project combines Electron, local AI models (transformers.js, llama.cpp), and P2P networking to create a privacy-focused, distributed AI assistant.

Key Features

  • Local-First Architecture: All AI processing happens on-device using transformers.js and sql.js
  • P2P Network: Share AI responses with other nodes through libp2p
  • Reputation System: Earn ACS (Agent Contribution Score) points for contributions to the network
  • Identity Management: Ed25519 key-based identity for signing and verification
  • Semantic Cache: Vector-based caching using embeddings for fast responses

Tech Stack

Layer Technology
Desktop App Electron, React, TypeScript
Local AI @xenova/transformers, llama.cpp
Database sql.js (SQLite in WASM)
P2P libp2p
Auth Clerk
Backend Fastify, Supabase

Quick Start

Prerequisites

  • Node.js 20+
  • npm or yarn
  • Clerk account (free tier) for authentication
  • Supabase project for database (optional)

Installation

# Clone the repository
git clone https://github.com/hackonteam/hackonagent.git
cd hackonagent

# Install dependencies
npm install

# Copy environment variables
cp .env.example .env
# Edit .env with your Clerk and Supabase credentials

Development

# Start Vite dev server (frontend)
npm run dev:renderer

# Start backend (in another terminal)
cd backend && npm run dev

# Run in Electron
npm run dev:main

Build

# Build all (main, preload, renderer)
npm run build

# Package for distribution
npm run package

Project Structure

hackon-agent/
├── src/
│   ├── main/              # Electron main process
│   │   ├── index.ts        # Entry point
│   │   └── p2p/            # P2P manager
│   ├── preload/            # Electron preload (secure bridge)
│   ├── renderer/           # React frontend
│   │   ├── modules/
│   │   │   ├── ai/         # AI, embeddings, cache
│   │   │   ├── auth/       # Identity (Ed25519)
│   │   │   ├── contrib     # Contributions
│   │   │   └── p2p/        # P2P cache
│   │   ├── components/    # UI components
│   │   └── App.tsx         # Main app
│   └── shared/             # Shared types
├── backend/                # Fastify API server
└── package.json

Environment Variables

Variable Description
VITE_CLERK_PUBLISHABLE_KEY Clerk publishable key
CLERK_JWKS_URL Clerk JWKS endpoint
SUPABASE_URL Supabase project URL
SUPABASE_KEY Supabase anon key
JWT_SECRET Backend JWT secret

License

Business Source License 1.1
Licensed under the BSL 1.1. See LICENSE for details.

The code will be open-sourced on January 1, 2033.

Contributing

This project is developed by Bernie Nguyen (BernieWeb3) under the HackOn Team. For contributions or inquiries, please contact the team through official channels.


© 2026 HackOn Team · Built with ❤️ for decentralized AI