# Browse-for-Humanity

More than 3,500 refugees lost their lives at sea last year while trying to leave their war-torn home. The refugee crisis has ballooned into a humanitarian crisis which requires immediate action to help alleviate hundreds of thousands of dispaced lives.

Browse For Humanity is a parallel computing platform where clients can submit complex computational tasks to be solved by the power of our crowdsourced processing platform. All the revenue accumulated by each volunteer for sharing his processing power is directly donated to the refugee cause. Now, solving the refugee crisis is as simple as browsing the web.

This product connects researchers and professionals who wish to perform computationally intensive tasks with users who are willing to donate computation power to add some goodness to the world. The extension quietly keeps working in the background. The interface for users posting tasks involves a front-facing web application that allows convenient code typing and uploading along with task distribution files.

**Technologies Used:**
The technology stack for this project was: Javascript, CSS, HTML, Python, Git, JQuery, and Flask. The backend involves a job scheduling system based on the Google Map/Reduce algorithm, which will distribute small tasks for particular jobs among users that are currently donating their processing power. The entire system is built around ease for both clients and users, which means that multiple users and clients can be using the application simultaneously through our multi-threaded server. Payment processing is integrated into the system via the Stripe API, allowing users to enter credit card information, and processing payment on data download.
## Inspiration

One of our first ideas was an Instagram-esque social media site for recipe blogs. We also were interested in working with location data - somewhere along the line there was an idea to make an app that allowed you to track down your friends.

Somehow, we managed to combine both of these wildly different ideas into a real-world applicable site. After researching shelters and food banks (aka googling and clicking on the first result), we realized that while these establishments do have a working relationship, oftentimes the shelters and food banks are required to buy key missing ingredients. Thus, our application was created to further personalize the relationship and interaction between these establishments to aid in decreasing food waste and ensuring people are getting culturally-significant, healthy, and delicious food.

## What it does

Markets and Shelters/food banks log in to their respective homepage. From there, they can see the other establishments near them, as well as an interactive sidebar.

For shelters, they can see nearby participating markets and look at their supply of food.

For markets, they will be able to see nearby shelters and their food requests. They will also be able to change their inventory of available foods for those shelters.

## How we built it

We used next.js and a variety of different style options (css, bootstrap, tailwind.css) to make a "dynamic" website.

## Challenges we ran into

We realized the crux of our application, which relies on a google map api to get nearby markets and their distances, is behind a paywall of $0. We didn't want to enter our credit card info to google. Sorry :/

As well, we were using react-native for a good four hours or so in the beginning, but it wasn't displaying on our localport (it was a blank page). Spent a long time trying to debug. So that was fun.

Our team members also used many different stylesheets. The majority of it was in normal style.css, but we have one component that's entirely in bootstrap (installing it for next.js was a pain). Also, there was an attempt to use tailwind.css for some components.

## Accomplishments that we're proud of

Our UI/UX design, including all our styling, was AMAZING. Shoutout to Lindsay for their major contributions.

As well, this was the first time the majority of our team touched react in their lives, so I think our progress was pretty good. Given that we actually chose to slept on Friday night I'd say we accomplished a lot.

## What we learned

Auth is a pain. Never again. It didn't even work :(

## What's next for crumbz

There's a lot to be implemented. From changing our logo to making sure the authentication actually works there is so much more room for crumbz to grow. If we had more time and commitment this application will become so much more.
## Inspiration

In light of the ongoing global conflict between war-torn countries, many civilians face hardships. Recognizing these challenges, LifeLine Aid was inspired to direct vulnerable groups to essential medical care, health services, shelter, food and water assistance, and other deprivation relief.

## What it does

LifeLine Aid provides multifunctional tools that enable users in developing countries to locate resources and identify dangers nearby. Utilizing the user's location, the app alerts them about the proximity of a situation and centers for help. It also facilitates communication, allowing users to share live videos and chat updates regarding ongoing issues. An upcoming feature will highlight available resources, like nearby medical centers, and notify users if these centers are running low on supplies.

## How we built it

Originally, the web backend was to be built using Django, a trusted framework in the industry. As we progressed, we realized that the amount of effort and feasibility of exploiting Django were not sustainable; as we made no progress within the first day. Quickly turning to the in-depth knowledge of one of our team member’s extensive research into asyncio, we decided to switch to FastAPI, a trusted framework used by Microsoft. Using this framework had both its benefits and costs. Realizing after our first day, Django proved to be a roadblock, thus we ultimately decided to switch to FastAPI.

Our backend proudly uses CockroachDB, an unstoppable force to be reckoned with. CockroachDB allowed our code to scale and continue to serve those who suffer from the effects of war.

## Challenges we ran into

In order to pinpoint hazards and help, we would need to obtain, store, and reverse-engineer Geospatial coordinate points which we would then present to users in a map-centric manner. We initially struggled with converting the Geospatial data from a degree, minutes, seconds format to decimal degrees and storing the converted values as points on the map which were then stored as unique 50 character long SRID values. Luckily, one of our teammates had some experience with processing GeoSpatial data so drafting coordinates on a map wasn’t our biggest hurdle to overcome. Another challenge we faced were certain edge cases in our initial Django backend that resulted in invalid data. Since some outputs would be relevant to our project, we had to make an executive decision to change backend midway through. We decided to go with FastApi. Although FastApi brought its own challenge with processing SQL to usable data, it was our way of overcoming our Jango situation. One last challenge we ran into was our overall source control. A mixture of slow and unbearable WiFi, combined with tedious local git repositories not correctly syncing create some frustrating deadlocks and holdbacks. To combat this downtime, we resort to physically drafting and planning out how each component of our code would work.

## Accomplishments that we're proud of

Three out of the four in our team are attending their first hackathon. The experience of crafting an app and seeing the fruits of our labor is truly rewarding. The opportunity to acquire and apply new tools in our project has been exhilarating. Through this hackathon, our team members were all able to learn different aspects of creating an idea into a scalable application. From designing and learning UI/UX, implementing the React-Native framework, emulating iOS and Android devices to test and program compatibility, and creating communication between the frontend and backend/database.

## What we learned

This challenge aimed to dive into technologies that are used widely in our daily lives. Spearheading the competition with a framework trusted by huge companies such as Meta, Discord and others, we chose to explore the capabilities of React Native. Joining our team are three students who have attended their first hackathon, and the grateful opportunity of being able to explore these technologies have led us to take away a skillset of a lifetime.

With the concept of the application, we researched and discovered that the only best way to represent our data is through the usage of Geospatial Data. CockroachDB’s extensive tooling and support allowed us to investigate the usage of geospatial data extensively; as our backend team traversed the complexity and the sheer awe of the scale of said technology. We are extremely grateful to have this opportunity to network and to use these tools that would be useful in the future.

## What's next for LifeLine Aid

There are a plethora of avenues to further develop the app, which include enhanced verification, rate limiting, and many others. Other options include improved hosting using Azure Kubernetes Services (AKS), and many others. This hackathon project is planned to be maintained further into the future as a project for others who may be new or old in this field to collaborate on.