This was inspired by a tumblr screenshot, and I thought it was a good way to get started learning how to use streamlit and Gemini Flash 1.5
GitHub: github.com/shudshudshud/msds-generator-app
Live Demo: MSDS Generator on Streamlit
Status: Early Prototype
Timeline: April 2025
Project Overview
The Material Safety Data Sheet (MSDS) Generator is a fun tool that creates satirical "safety data sheets" for humans based on a viral Tumblr post. Inspired by the humorous take on treating people like chemical compounds, I built this as a way to learn Streamlit and experiment with Google's Gemini API.
This project was a perfect entry point for me to explore AI-powered web applications while creating something amusing that plays on the formal language of chemical safety documentation.
Core Features:
- Human MSDS Generation: Creates a professional-looking safety data sheet for people
- Customizable Parameters: Users can input names and characteristics
- Professional Format: Output mimics the standard sections of a real MSDS, including hazards, handling, and storage
- AI-Generated Content: Uses Gemini to generate creative and humorous safety precautions
Tech Stack:
- Language: Python
- Framework: Streamlit for rapid web app development
- AI Integration: Google's Gemini API for content generation
- Deployment: Streamlit Cloud for hosting
- Version Control: Git/GitHub
Lessons & Next Steps
Key Learnings:
- Setting up a Streamlit application from scratch
- Implementing API authentication with Gemini
- Designing prompt engineering to generate structured outputs
- Managing API rate limits and response handling
Technical Challenges:
- Structuring prompts to get consistent, well-formatted MSDS results
- Handling API errors and timeouts gracefully
- Balancing humorous content with appropriate boundaries
Future Development Plans:
- Improved UI: Add more styling and visual elements to make the application look more professional
- Chemical Compound Generation: Implement a feature to generate fictional chemical formulas for human traits
- PDF Export: Add ability to download the MSDS as a properly formatted PDF
- Extended Parameters: Include more customization options like personality traits, hobbies, etc.
- Image Integration: Generate custom hazard symbols based on the person's characteristics
Version History:
- v0.1 (April 13, 2025): Initial implementation with basic Streamlit interface and Gemini API integration
- v0.2 (Planned): Enhanced UI and additional parameter options
- v0.3 (Planned): Chemical compound generation for human traits