Directory Contents

Multimedia Embeds

🎥 Open Ledger Read Me

OpenLedger - Secure AI Collaboration Platform

🚀 Project Overview

OpenLedger is a secure collaboration platform that enables data providers and model developers to work together in controlled, privacy-preserving dealing spaces. The platform features blockchain-based transaction logging, multi-level access controls, and real-time collaboration tools.

Key Features

  • Multi-Level Access Control: L1 (Zero Exposure), L2 (Controlled Introspection), L3 (Monetized Access)
  • Blockchain Integration: Automatic transaction logging and ledger management
  • Real-time Collaboration: Live participant tracking and file sharing
  • Secure File Processing: AWS S3 integration for secure file storage and retrieval
  • Payment Integration: Built-in payment processing for L3 sessions
  • User Activity Tracking: Comprehensive logging of user actions and session events

🛠️ Tech Stack

Frontend

  • React with TypeScript
  • Vite for build tooling
  • Tailwind CSS for styling
  • shadcn-ui for UI components
  • Framer Motion for animations
  • Sonner for notifications

Backend

  • Python 3.11 with FastAPI
  • AWS S3 for file storage
  • boto3 for AWS integration
  • Blockchain integration for transaction logging

📋 Prerequisites

  • Node.js (v16 or higher)
  • Python 3.11
  • npm or yarn
  • pip (Python package manager)
  • AWS Account (for S3 storage)

🚀 Setup Instructions

1. Clone the Repository

git clone <YOUR_GIT_URL>
cd openledger1

2. Frontend Setup

# Install Node.js dependencies
npm install

# Start the development server
npm run dev

The frontend will be available at http://localhost:5173

3. Backend Setup

# Navigate to backend directory
cd backend/scripts/dealing_space

# Install Python dependencies
pip install -r requirements.txt

# Start the FastAPI backend server
python run_backend.py

The backend API will be available at http://localhost:8000

4. Environment Configuration

Make sure you have the following environment variables set up for AWS S3:

# AWS Credentials (set these in your environment)
AWS_ACCESS_KEY_ID=your_access_key
AWS_SECRET_ACCESS_KEY=your_secret_key
AWS_DEFAULT_REGION=your_region

🎯 How to Use

Creating a Session

  1. Navigate to the home page
  2. Click "Initialize New Session"
  3. Choose your access level (L1, L2, or L3)
  4. Select your role (Data Provider or Model Developer)
  5. Enter session details and initialize

Joining a Session

  1. Use the session ID to join an existing session
  2. Select your role (opposite of the creator)
  3. For L3 sessions, complete payment if joining as Model Developer
  4. Upload files and collaborate

Session Features

  • File Upload: Upload CSV data files or model files
  • Real-time Collaboration: See other participants and their activities
  • Blockchain Ledger: View transaction history and user activities
  • Output Generation: Process files and view results
  • Payment Processing: Handle payments for L3 sessions

📁 Project Structure

openledger1/
├── src/                    # Frontend React application
│   ├── components/         # React components
│   ├── pages/             # Page components
│   ├── contexts/          # React contexts
│   └── lib/               # Utility functions
├── backend/               # Backend Python application
│   └── scripts/
│       ├── dealing_space/ # FastAPI backend
│       └── blockchain/    # Blockchain integration
├── public/                # Static assets
└── package.json          # Node.js dependencies

🔧 Development

Running in Development Mode

  1. Start the backend (Terminal 1):

    cd backend/scripts/dealing_space
    python run_backend.py
    
  2. Start the frontend (Terminal 2):

    npm run dev
    

Building for Production

# Build the frontend
npm run build

# The backend runs directly with Python

🤝 Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Test thoroughly
  5. Submit a pull request

📄 License

This project is licensed under the MIT License.

🆘 Support

For support and questions, please open an issue in the repository or contact the development team.