Skip to content

JimiOwO/F23_Package_Tracker

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

65 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contributors MIT License Activity

Chase Grajeda (grajec)

Jianye Peng (pengj6)

Eddie Poon (poone)

Aneesh Kolukuluri(koluka)

Table of Contents
  1. About the project
  2. Prerequisites
  3. Blockchain Component
  4. Diagrams
  5. License

About

Package Tracker

The Package Tracker introduces faster and safer standards of delivery for cities and local populations. Users may sign up to deliver for us, from which they’ll receive instant payment for successful delivery. Packages are brought from a distribution center and delivered to a local parcel locker. Each package has a unique identifier to be scanned in at each point of the process. Receiving users are given real-time updates on the status of their package, as well as optimized route planning.

Built With

  • Solidity
  • Pytorch
  • React
  • FastAPI

Prerequisites

  • Clone or fork the repo
    • GitHub Desktop: download here
    • Clone repo through Git Bash
    $ git clone https://github.com/AI-and-Blockchain/F23_Package_Tracker
    • To fork, press the fork button on the top right of the repo, or here
  • Install Applications
    • Node.js: download here
    • Ganache: downlaod here
  • Install All Requirements
    • Download through the command line
    $ pip install -r requirements.txt
    $ npm install

Setting up the webpage and API

  • Do the instructions in this order
  • Open Ganache
    • Press Quickstart if it is the first time, otherwise choose an already created workspace
  • Click the key icon on any of the Addresses on the right side of the screen
    • In contractToPy.py, towards the top of the file, change the address and private key to the ones shown in ganache and save the file
  • Run the Blockchain API
    • Change directories
    $ cd Blockchain
    • Run the command in the terminal
    $ uvicorn contractToPy:app --reload
  • Run the AI API
    • Open a new terminal and change directories
    $ cd Webpage/web-page/src
    • Run the server
    $ python server.py
  • Run the frontend
    • Open a new terminal and change directories
    $ cd Webpage/web-page
    • Run npm
    $ npm start

Demo Video

https://www.youtube.com/watch?v=HKp4oUxC0eo

Blockchain Component

QR code creation: We will be required to generate three separate QR codes to call different functions of the smart contract in order to facilitate communication and delivery of information between the three parties: sender, receiver, and courier.

The generation of the QR codes can be done using the following plug-in: https://github.com/jibrelnetwork/ethereum-qr-code/blob/master/README.md

Functions to update state variables, and send status updates such as expected ETA will be created so that the receiver can be aware of the current status of the delivery.

Events can be used to create a log and keep track of the various steps involved from start to finish.

Diagrams

Architecture Diagram

image

Sequence Diagram

image

Flowchart

image

License

Distributed under the Apache License. See LICENSE for more information.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 52.2%
  • JavaScript 29.7%
  • Solidity 9.2%
  • HTML 5.1%
  • CSS 3.8%