Final Project and Deployment
Zack finally had a Streamlit dashboard where he could:
- Read inbox summaries
- Approve/reject reply drafts
- Upload meetings and see notes
It felt like a real assistant. But there was still one problem: only Zack could use it.
Every time he wanted to run the app, he had to:
- Start the Flask backend
- Start the Streamlit frontend
- Keep his laptop on
And if his colleague Sara wanted to try it, she’d have to install Python, dependencies, and set up API keys. Too complicated.
“I want this to be shareable,” Zack thought. “I want to send Sara a link and say: ‘Here, try my assistant.’”
That’s where deployment comes in.
Step 1: What deployment means
Deployment simply means making your app available on the internet instead of just your laptop.
- On your laptop, only you can use it.
- Deployed anyone with the link can open it in a browser.
Deployment can happen in many ways:
- Free hosting services like Streamlit Cloud.
- Cloud servers like AWS, Google Cloud, or Azure.
- Container platforms like Docker + Heroku.
For beginners, Zack chose Streamlit Cloud. It’s the easiest way to put a Streamlit app online.
Step 2: Preparing the final project structure
Zack reorganized his project into one folder:
1 2 3 4 5 6 7 8 9 10 11 12
assistant_app/ │── backend/ │ ├── app.py │ ├── services/ │ │ ├── email_summary.py │ │ ├── reply_drafts.py │ │ ├── meeting_transcription.py │ │ └── meeting_summary.py │── frontend/ │ └── dashboard.py │── requirements.txt │── README.md
- backend/app.py: Flask API
- frontend/dashboard.py: Streamlit dashboard
- requirements.txt: lists dependencies
- README.md: explains how to run the app
Step 3: Writing requirements.txt
Zack created requirements.txt:
1 2 3 4 5 6 7 8 9 10 11
flask streamlit requests openai whisper torch torchaudio beautifulsoup4 google-api-python-client google-auth-httplib2 google-auth-oauthlib
This way, Streamlit Cloud would install everything automatically.
Step 4: Setting up GitHub
To deploy, Zack needed to put his code on GitHub.
- He created a GitHub account.
- Installed Git on his laptop.
- Initialized his project folder:
1 2 3 4 5 6
git init git add . git commit -m "Final assistant project" git branch -M main git remote add origin https://github.com/zack/assistant_app.git git push -u origin main
Now his code lived on GitHub.
Step 5: Deploying on Streamlit Cloud
Zack went to share.streamlit.io.
- Logged in with GitHub.
- Clicked New App.
- Selected his assistant_app repo.
- Set the main file to frontend/dashboard.py.
- Clicked Deploy.
Streamlit Cloud pulled the repo, installed requirements, and started the app.
After a few minutes, Zack got a link:
1
https://zack-assistant.streamlit.app
When Sara opened it, she saw the same dashboard Zack had on his laptop.
Step 6: Managing API keys securely
Zack remembered: his OpenAI key was needed for the backend. But putting it directly in GitHub would expose it to the world.
Instead, Streamlit Cloud lets you set secrets.
- In Streamlit Cloud, go to the app’s settings → Secrets.
- Paste:
1
OPENAI_API_KEY = "sk-abc123..."
- In dashboard.py, replace:
1 2
import os API_KEY = os.environ["OPENAI_API_KEY"]
This way, the key stays private.
Step 7: Backend deployable
At first, Zack tried to deploy Flask + Streamlit separately. It was messy. Then he realized: for his project, he could simplify.
Instead of keeping Flask, he could move the logic directly into Streamlit. Streamlit can call OpenAI, Whisper, and Gmail APIs directly.
So Zack merged everything into dashboard.py:
- Summarize email → direct OpenAI call
- Draft replies → direct OpenAI call
- Transcribe meeting → call Whisper locally
- Summarize meeting → direct OpenAI call
This cut complexity and made deployment smoother.
Step 8: Polishing the dashboard
Zack added final touches:
- Sidebar navigation: Inbox | Replies | Meetings
- Icons: 📧 ✍️ 🎙️
- Download button: Export notes as .txt
- Colors and spacing: Streamlit handles layout, but he used st.markdown for emphasis.
Example:
1 2
st.sidebar.title("Assistant Navigation") page = st.sidebar.radio("Go to:", ["Inbox Summaries", "Reply Drafts", "Meeting Notes"])
Step 9: testing with real use cases
Zack tested with three real scenarios:
Case 1: Inbox summaries
He pasted a real email:
“Hi Zack, please send me the updated budget file by Friday.”
The assistant returned:
“Request to send updated budget file by Friday.”
Case 2: Reply drafts
He tested with:
“Can you confirm our meeting at 2 PM tomorrow?”
The assistant suggested three replies:
- “Yes, confirmed for 2 PM tomorrow.”
- “Dear John, thank you for your message. I confirm our meeting at 2 PM tomorrow.”
- “- Meeting confirmed
- 2 PM tomorrow
- Looking forward to it”
Case 3: Meeting transcription
He uploaded a short audio clip. Whisper transcribed it and GPT-4o summarized:
“Team decided to extend QA testing by three days. Sara will update project plan. Ali to notify client.”
Everything worked smoothly.
Step 10: Exercise
Your task:
- Push your code to GitHub.
- Deploy your Streamlit app on Streamlit Cloud.
- Add your API key as a secret.
- Share your link with a friend.
Expected:
- A working assistant with three features (Inbox, Replies, Meetings).
- Friend can test it in a browser without installing anything.
Zack’s feedback
When Zack shared the link with his team, they were amazed.
“This feels like a real product,” Sara said.
For Zack, the journey was transformative:
- From running messy scripts in a terminal
- To building a backend
- To creating a clean dashboard
- To deploying a shareable app online
He had gone from beginner Python coder to someone who built a full AI-powered assistant.
Conclusion
In this final lesson, Zack brought everything together:
- Organized the project into backend + frontend
- Used GitHub for version control
- Deployed with Streamlit Cloud
- Managed API keys securely with secrets
- Polished the dashboard with navigation and buttons
Now Zack had not just a project, but a deployable application. Something others could use, test, and improve. And that’s the end of this course, but for Zack, it’s just the beginning. His assistant can grow with new features, integrations, and designs. The foundation is solid.
Frequently Asked Questions
Deployment makes the app accessible online. Instead of running scripts locally, Zack can share a simple web link with colleagues.
Streamlit Cloud, which is beginner-friendly and allows hosting Python dashboards directly from GitHub.
By using Streamlit Secrets, which store API keys safely outside of the codebase so they aren’t exposed on GitHub.
Not necessarily. For simplicity, Zack merged backend logic into Streamlit. Flask is useful for larger systems needing separate APIs.
Still have questions?Contact our support team