PromptWars: Bengaluru Hackathon Submission Track: Societal Benefit
During a crisis, critical seconds are wasted deciphering panicked, unstructured information. Aegis bridges the gap between chaotic human intent and complex response systems. It takes unstructured Real-World Data (images, text) and instantly structures it into verifiable, life-saving action protocols using Google's powerful Gemini models.
This V2 release focuses intensely on Production-grade code quality, efficiency, accessibility, robust security, and deep Google SDK native API usage.
- 🧪 Comprehensive Testing (How easily the code can be tested, validated, and maintained over time): Fully refactored
app.pyinto a highly-maintainableAegisCoreOOP structure. Includes fullpytestunit test coverage intests/test_aegis.pyutilizingpytest-mockto test complex backend networking failures, LLM timeouts, and API credential boundaries (100% Path Coverage). Tests are automatically checked via GitHub Actions CI/CD pipeline (.github/workflows/pytest.yml). - ⚡ Extreme Efficiency (How well code utilizes time and memory):
- Uses strictly optimized
Image.Resampling.LANCZOSdownscaling to lower GenAI payload size and save network latency/memory footprint. - Implements stateful caching via
@st.cache_resourcefor all expensive cloud clients, avoiding memory leaks.
- Uses strictly optimized
- ♿ Web Accessibility & UI: UI utilizes full Semantic HTML (
<main>,<h1>,<h2>), interactivearia-labeltags, high-contrast severity metrics, accessibility tooltips, and dynamic rendering for Image, Text, and Voice.mp3modalities. - ☁️ Massive Google Services Integration (How effectively Google Services are integrated):
- GenAI: Native integration with Google Gemini 2.5 Flash for multimodal (Text, Audio, Photo) crisis structuring.
- Cloud Logging: Utilizes
google-cloud-loggingto transmit structural logs of emergencies context to scalable backend storage. - Cloud Storage: Implemented
google-cloud-storagearchitecture to natively and securely archive live scene evidence (images) for post-incident audits. - Cloud Translation (Societal Impact): Connected to the
google-cloud-translateAPI to instantly localize Action Plans for universally accessible response. - Google Maps: Extracts location entities dynamically and builds interactive routing links for responders.
- 🔒 Defense-in-Depth Security (Whether the code follows safe practices and avoids common vulnerabilities): Safely reads API keys strictly via protected
st.secretsOR dynamic session states (no hardcoded keys). Heavily wraps external cloud logic and File Upload bounds in nativetry/exceptsafeguards to prevent arbitrary code injection or denial-of-service crashes.
- Streamlit: Modern interactive dashboarding.
- Google GenAI (
gemini-2.5-flash): Core intelligence protocol synthesizer. - Google Cloud Logging: Distributed structured backend tracing.
- PyTest: V2 testing suite.
- Install dependencies:
pip install -r requirements.txt
- Run the tests (Coverage: Core Intelligence):
pytest tests/
- Run the Streamlit Application:
streamlit run app.py