Skip to content

solanki505/AWS-Groq-API-Stremlit-summarizer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Screen.Recording.2025-06-25.095937.mp4

🧠 Website & PDF Summarizer App

A powerful and simple Streamlit application to summarize content from websites or PDF documents, and ask questions based on the summarized content using Groq's LLaMA3-8B model via LangChain.


🔧 Features

  • 🌐 Summarize Website URLs
  • 📄 Upload and summarize PDF files
  • ❓ Ask questions based on the summarized content
  • ⚡ Powered by Groq LLaMA3-8B (via LangChain)

File Structure

├── app.py                   # Main Streamlit interface
├── summarizer.py            # Summarization and QA logic
├── requirements.txt         # List of required packages
└── .streamlit/
    └── secrets.toml         # Contains Groq API key

How It Works

  • For websites, content is extracted using WebBaseLoader.
  • For PDFs, content is extracted using UnstructuredPDFLoader.
  • Text is truncated to 12,000 characters to fit the model's input limit.
  • LangChain prompt templates are used to generate:
    • 📄 A concise summary
    • Context-based answers to user questions

📦 Installation

1. Clone the Repository

git clone https://github.com/your-username/your-repo-name.git
cd your-repo-name
pip install -r requirements.txt

Set Up Secrets

Create a file: .streamlit/secrets.toml and add your Groq API key:

groq_api_key = "your_groq_api_key_here"

Run the App

streamlit run app.py

Releases

No releases published

Packages

No packages published

Languages