kedar-bhumkar's picture
Upload 5 files
3d833be verified

A newer version of the Streamlit SDK is available: 1.45.1

Upgrade
metadata
title: Code Impact Analyzer
emoji: πŸ”
colorFrom: blue
colorTo: indigo
sdk: streamlit
sdk_version: 1.32.0
app_file: app.py
pinned: false

Code Impact Analyzer

A powerful tool that analyzes code changes in Git repositories using AI to provide detailed impact analysis.

Features

  • πŸ” Git Repository Analysis: Clone and analyze any public Git repository
  • πŸ€– AI-Powered Analysis: Uses GPT-4 and Claude Sonnet for intelligent code analysis
  • πŸ“Š Impact Assessment: Provides detailed analysis of code changes and their impact
  • πŸ”’ Secure API Key Management: Supports both environment variables and session-based API keys
  • πŸ“ Structured Output: Returns analysis in a standardized JSON format
  • πŸ“¦ Large Codebase Support: Handles large repositories through intelligent chunking

Usage

  1. Enter a Git repository URL
  2. Select your preferred AI model (GPT-4 or Claude Sonnet)
  3. Enter your code/configuration changes
  4. Click "Analyze" to get detailed impact analysis

API Key Setup

Option 1: Environment Variables

Set your API keys in the .env file:

OPENAI_API_KEY=your_openai_key_here
ANTHROPIC_API_KEY=your_anthropic_key_here

Option 2: In-App Input

Enter your OpenAI API key directly in the application interface.

Analysis Output

The tool provides analysis in the following format:

{
    "severity_level": "LOW/MEDIUM/HIGH",
    "number_of_files_impacted": <integer>,
    "files_impacted": [
        {
            "files_impacted": "file_path",
            "impact_details": "detailed_impact_description"
        }
    ]
}

Severity Levels

  • LOW: 1-3 files impacted
  • MEDIUM: 4-8 files impacted
  • HIGH: More than 8 files impacted

Technical Details

  • Built with Streamlit
  • Uses OpenAI's GPT-4 and Anthropic's Claude Sonnet
  • Supports multiple programming languages
  • Handles large codebases through token-based chunking

License

MIT License