A Streamlit application that combines AWS resource management with intelligent file organization using AI agents powered by Strands Agents Framework.
USE AT YOUR OWN RISK: This code is provided as-is for educational and demonstration purposes only. Amazon Web Services (AWS) is not responsible for any damages, data loss, costs, or issues that may arise from using this application. Users are solely responsible for:
- Testing in safe, non-production environments
- Backing up important data before use
- Understanding AWS costs and potential charges
- Ensuring proper security and access controls
- Any consequences of file operations or AWS resource management
By using this application, you acknowledge and accept full responsibility for all outcomes.
This application provides a natural language interface to manage your AWS infrastructure and organize your local files. Simply ask questions in plain English or use quick action buttons to:
- Manage AWS Resources: Query S3 buckets, EC2 instances, Lambda functions, and monitor costs
- Organize Files: Automatically sort files by type into organized folders
- Multi-Region Support: Switch between AWS regions seamlessly
- Real-Time Operations: Get instant results with live feedback
- 🪣 S3 Management: List buckets, filter by patterns, check sizes
- 💻 EC2 Monitoring: View instances, check status across regions
- ⚡ Lambda Functions: List functions, analyze performance
- 💰 Cost Tracking: Monitor AWS billing and usage
- 🌍 Multi-Region: Support for 7 major AWS regions
- 📁 Smart Sorting: Automatically categorize files by type
- 🔄 Cross-Platform: Works on Windows, macOS, and Linux
- 📊 Detailed Reports: See before/after states and file movements
- 🛡️ Safe Operations: Handles duplicates and preserves data
- 💬 Natural Language: Ask questions like "Show running instances"
- 🚀 Quick Actions: Pre-configured buttons for common tasks
- 📱 Responsive Design: Clean, intuitive interface
- 🔒 Secure: Standard AWS credential handling
- Python: 3.10 or higher
- Operating System: Windows, macOS, or Linux
- AWS Credentials: Required for AWS operations (optional for file organization)
- AWS Bedrock Access: Must have access to Anthropic Claude 3.5 Haiku model in AWS Bedrock
Windows:
python --versionMac:
python3 --versionEnsure you have Python 3.10 or higher
Windows:
# Create virtual environment
python -m venv venv
# Activate virtual environment
venv\Scripts\activateMac:
# Create virtual environment
python3 -m venv venv
# Activate virtual environment
source venv/bin/activateInstall from requirements.txt (Recommended):
pip install -r requirements.txtConfigure AWS Credentials:
aws configureOr set environment variables:
export AWS_ACCESS_KEY_ID=your_access_key
export AWS_SECRET_ACCESS_KEY=your_secret_key
export AWS_DEFAULT_REGION=us-east-1Enable Claude 3.5 Haiku in AWS Bedrock:
- Go to AWS Console → Amazon Bedrock
- Navigate to "Model access" in the left sidebar
- Click "Request model access"
- Find "Anthropic Claude 3.5 Haiku" and click "Request access"
- Wait for approval (usually instant for most accounts)
- Ensure your region supports Bedrock (us-west-2, us-east-1, etc.)
Both Windows & Mac:
streamlit run AWS_file_mgmt_assistant.py🚨 FILE ORGANIZATION SAFETY:
- DO NOT run file organization on system drives (C:, root directories)
- DO NOT use on important folders like Downloads, Documents, Desktop
- ONLY use on dedicated test folders you create specifically for testing
- This app is for educational purposes to demonstrate Strands Agents capabilities
- Always backup important files before testing
Safe Test Folder Examples:
C:\Users\YourName\TestFolder/Users/YourName/TestFolder/home/username/TestFolder
- Launch the app - Run the Streamlit command above
- Open your browser - Navigate to http://localhost:8501
- Select AWS region - Choose from the dropdown (default: us-east-1)
- Type natural language queries: "List all S3 buckets"
- Use quick action buttons: Click pre-configured options in sidebar
- Switch regions: Select different AWS regions for queries
Example Queries:
- "Show me buckets starting with 'data'"
- "How many EC2 instances are running?"
- "List Lambda functions with errors"
- "What's my AWS cost summary?"
- Enter folder path: Type the full path to organize
- Click organize button: Files will be sorted automatically
- View results: See detailed before/after reports
Safe Test Folder Paths:
- Windows:
C:\Users\YourName\TestFolder - Mac:
/Users/YourName/TestFolder - Linux:
/home/username/TestFolder
C:\or/(root drives)C:\Users\YourName\DownloadsC:\Users\YourName\DocumentsC:\Users\YourName\Desktop
Files are automatically organized into:
- Documents: Word, Excel, PowerPoint, PDF
- Media: Images, Videos, Audio files
- Archives: ZIP, RAR, TAR files
- Code: Python, JavaScript, HTML, CSS
- Executables: Platform-specific executable files
- Other: Unrecognized file types
To reactivate later:
Windows:
venv\Scripts\activate
streamlit run AWS_file_mgmt_assistant.pyMac:
source venv/bin/activate
streamlit run AWS_file_mgmt_assistant.pyTo deactivate:
deactivateCommon Issues:
- Python Version: Ensure Python 3.10+ (
python --version) - Virtual Environment: Always activate before running
- AWS Permissions: Verify credentials have proper permissions
- File Permissions: Run as administrator for system folders
- Import Errors: Reinstall dependencies in virtual environment
Quick Fixes:
- Restart the Streamlit app if it becomes unresponsive
- Check AWS credentials if getting permission errors
- Use full file paths for file organization
- Ensure virtual environment is activated before each session
See CONTRIBUTING for more information.
This library is licensed under the MIT-0 License. See the LICENSE file.
