Project Info
This project did not submit a demo video on Devpost.
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 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
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.
Lifeline Aid
A beacon for refugees in conflict zones. Instantly see nearby food, shelter, and aid. Get alerts on regional hazards. Direct links to humanitarian agencies. Hope in chaos.
Purpose / Movitation
This project was created for Cal Hacks 10.0, an hackathon ran by University of California, Berkeley. The app serves as a beacon for refugees in conflict zones, where affected users can use this app to locate official places that offer humanitarian aid and other essentials (eg. food and water).
This project is developed by Javier Miranda, Noelle Wang, Andres Yllescas and Ashly Benitez within the 30 hour time limit of Cal Hacks.
The "techy side"
This repo serves as a monorepo, most notably these two folders:
multiNew- The React Native (TS) mobile app as the frontendfastapi-backend- FastAPI application (Python w/ type hints) that uses CockroachDB.asyncpg-based project, as CockroachDB natively implements the PGWire Protocol (in simply terms, CockroachDB fully supports any and all PostgreSQL drivers and code).
As a part of a sponsership deal, UC Berkeley partnered up with CockroachLabs in order to provide a prize for whoever which team uses CockroachDB the best. Up to $2000 dollars.
Mobile app
The choice of framework for us would be React Native. We needed something to deploy both to APple devices and Android devices, as people in these countries do not have easy access to the web. The mobile app presented the challenge of learning said framework, but the intergration between the mobile app and backend.
Development of the mobile app were led by Javier Miranda and Andres Yllescas.
Backend
Originally seltting on Django, we figured out that using Django meant wasting more time and the restrictions imposed on ORMs. After noticing the 5.8x (or 580%) performance boost over psycopg2 and 5x (or 500%) over psycopg3 (and 8.2x or 820% faster than node-js), it made sense to break out the big guns - asyncpg. Used by over 40,000 developers, asyncpg's users contain projects such as R. Danny, which are known to be extremely stable and performant. For reasons described above, along with fimliarly with asyncpg, the decision was set to switch over.
The backend implements a connection pool of 25, which is suitable for most instances. All connections are pulled from the pool and sent back once finished.
The future of the app
Ultimately, this app is not finished. There are plans to maintain this as an UCMACM project, continuing the legacy of Lifeline Aid. Plans include:
- User auth
- Rewrite of some of the core parts
- User forums
and many many more.
Analysis
View
Metric
- 15
- 2
- 1
Figures cover GitHub contributors during the hackathon window. A co-authored commit counts in full for each author, so per-member totals add up to more than the whole-team figures.
Technology
- DjangoIn code
- FastAPIIn code
- JavaScriptIn code
- PythonIn code
- ReactIn code
- SQLIn code
- TypeScriptIn code
- Node.jsClaimed
- PostgreSQLClaimed
7 of 9 appear in the indexed code. 2 claimed on Devpost could not be matched to code, which may simply mean the tool leaves no trace in the repository.
AI coding agents
No AI coding agent signals were found in this repository.
Detected from committed agent config files and commit authorship. Absence of a signal is not proof an agent was unused.
Codebase size
Source size
41 KB
Source files
48
Counts recognized source files only; vendored directories, binaries and lockfiles are excluded, so this is smaller than the repository on disk.
Repository
No767/lifelineaid
67 files · 1.1 MB · @ 2287296
Structure
Interface
16 files · 24%Screens, components and styles rendered to the user.
API & routing
9 files · 13%Request entry points: routes, handlers and controllers.
Application logic
15 files · 22%Domain rules, services and shared utilities.
Data & schema
4 files · 6%Schema definitions, migrations and data access.
Supporting
Layers are inferred from where files sit in the tree, not from reading the code. A project that names its directories unconventionally will read oddly here — open the file browser to check anything the diagram implies.
Languages
- TypeScript51%
- Python32%
- Markdown6%
- SQL6%
- YAML3%
- JavaScript2%
Share of indexed source by file size. Binary and vendored files are excluded.
Dependencies
multiNew/package.json
npm · 33- @emotion/react
- @emotion/styled
- @expo/vector-icons
- @mui/material
- @react-navigation/native
- @rneui/themed
- android
- axios
- expo
- expo-font
- expo-linking
- expo-router
- expo-splash-screen
- expo-status-bar
- expo-system-ui
- expo-web-browser
- react
- react-dom
- +15 more
fastapi-backend/requirements.txt
pypi · 8- asyncpg
- asyncpg-trek
- fastapi
- hypercorn
- orjson
- python-dotenv
- shapely
- uvicorn[standard]
backend-django-old/requirements.txt
pypi · 7- django
- django-cockroachdb
- django-filter
- djangorestframework
- markdown
- psycopg[binary]
- python-dotenv
Declared in the repository’s manifests at the indexed commit. A declared package is not proof it is used, and runtime dependencies are listed first.
Feature verification
FastAPI backend with asyncpg and CockroachDBVerified
Backend uses FastAPI with asyncpg-based connection pool to CockroachDB
Claimed on readmehigh confidencefastapi-backend/main.py:18— FastAPI app with asyncpg.create_pool(dsn=COCKROACH_URI, max_size=25, min_size=25) lifespan, matching the described connection pool of 25
Full-text/fuzzy search for alertsVerified
Search functionality for hazard alerts
Claimed on readmehigh confidencefastapi-backend/routes/alerts.py:31— search_alerts endpoint uses pg_trgm similarity operator (%) with GIN trigram index for fuzzy title searchfastapi-backend/migrations/20231028_initial_up_rev1.sql:36— GIN trigram index created on alert.title supporting the similarity search
Geospatial coordinate storage using PostGIS-style geometry/SRID pointsVerified
Geospatial coordinate points stored as points on a map using SRID values
Claimed on Devposthigh confidencefastapi-backend/routes/pins.py:18— ST_MakePoint and location_geom column used to store coordinates as geometryfastapi-backend/migrations/20231028_rev1_up_rev2.sql:12— pin table gets a location_geom GEOMETRY column added via migration
Original Django backend (superseded)Verified
Originally built the web backend using Django before switching to FastAPI
Claimed on readmehigh confidencebackend-django-old/manage.py— Leftover Django project (manage.py, api app, models) present in repo as backend-django-old, confirming the described framework switch
React Native mobile app for iOS and AndroidVerified
Mobile app built with React Native, deployable to Apple and Android devices
Claimed on readmehigh confidencemultiNew/app.json— Expo/React Native app config presentmultiNew/package.json— react-native-maps and Expo React Native dependencies present
Contact/agency directory with contact buttonsCode-supported
The app connects users to local organizations and government agencies for aid
Claimed on readmemedium confidencemultiNew/components/contactScreenInfo.tsx:8— Contact screen renders cards for Local Organizations, Government Agencies, Israel, each with a Contact button, but onPress handlers are empty no-op functions, so nothing actually happens when tapped
Interactive map showing nearby food, shelter, and aid pinsCode-supported
Instantly see nearby food, shelter, and aid on a map
Claimed on Devpostmedium confidencemultiNew/app/(tabs)/index.tsx:17— MapView with hardcoded Markers for medical aid, wildfire, bombing, etc.; not fetched dynamically from backend /pins endpointfastapi-backend/routes/pins.py:45— Backend has a /pins/fetch endpoint returning pin geometry, title, description, but frontend map does not call it
Regional hazard alertsCode-supported
Get alerts on regional hazards
Claimed on Devpostmedium confidencefastapi-backend/routes/alerts.py:10— Backend has alert creation and fuzzy-title search endpoints backed by an alert tablemultiNew/app/(tabs)/two.tsx:1— Alerts tab exists but only renders a static hardcoded card (alertScreenInfo.tsx) with two hand-written example alerts, no API call to fastapi-backend
Direct links to humanitarian agenciesClaimed only
Direct links to humanitarian agencies
Claimed on Devposthigh confidenceLive video sharing and chat updatesClaimed only
Facilitates communication, allowing users to share live videos and chat updates regarding ongoing issues
Claimed on Devposthigh confidenceLocation-based proximity alerts to hazards and aid centersClaimed only
Utilizing the user's location, the app alerts them about the proximity of a situation and centers for help
Claimed on readmehigh confidenceResource/supply level tracking for medical centersClaimed only
An upcoming feature will highlight available resources and notify users if centers are running low on supplies
Claimed on Devposthigh confidenceUser authenticationClaimed only
Plans include user auth (future work)
Claimed on readmehigh confidence
An AI agent derived these features from the project’s Devpost page and readme, then searched the code for each one. Verified features are backed by cited code; claimed-only features had no supporting code, which is not by itself proof a feature is missing.
Export this project's context (description, README, evidence, key source files) to chat with an AI agent elsewhere.