Sufiyan-dev / ai-smart-contract-auditor

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ChatGBC - AI Audit your Smart Contracts - Blockhack HyperCycleAI - Decentralized Minds

A platform that leverages GPT AI API for auditing smart contracts.

Table of Contents

Setup

  1. Prerequisites:

    • Ensure you have node and npm installed. If not, download and install them from here.
    • A code editor of your choice.
  2. Install Dependencies:

    • Navigate to both the frontend (BlockHack-Frontend) and backend (smartcontract-analyzer) folders separately and run the following:
      npm install

Running the Project

Since Dockerization is currently facing issues, the recommendation is to run the backend and frontend separately using two terminals.

  1. Backend:

    • Navigate to the smartcontract-analyzer folder.
    • Run the command:
      node server.js
    • The backend should start at localhost:3000.
  2. Frontend:

    • Navigate to the BlockHack-Frontend folder.
    • Run the command:
      npm start
    • Since the backend occupies localhost:3000, the frontend should start at localhost:3001.

Docker Note

Although Docker files are provided, currently only the backend is accessible at localhost:3000 when using Docker. The frontend faces issues. Thus, it's recommended not to use Docker for now.

Environment Variables

For the backend to function properly, you need to set up environment variables:

  1. Without Docker:

    • Create a .env file in the smartcontract-analyzer folder with the following content:
      OPENAI_API_KEY="YOUR_OPENAI_API_KEY"
      PORT=3000
  2. With Docker (not recommended at the moment):

    • Create a .env file in the smartcontract-analyzer folder with just the API key:
      OPENAI_API_KEY="YOUR_OPENAI_API_KEY"

Contributors

  • Sufiyan Memon
  • Anishkumar Patel
  • Kevon Jaggassar
  • Xiaogang Dong
  • Umut Yorulmaz

Acknowledgements

Made with ❤️ by the Decentralized Minds - GBC Blockchain Club.

About


Languages

Language:JavaScript 85.1%Language:CSS 9.4%Language:HTML 4.9%Language:Dockerfile 0.7%