Skip to content

AIGNE-io/aigne-code-smith

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

18 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

AI-Powered Code Reviews & PR Summaries for GitHub

Accelerate your development workflow with intelligent, context-aware code reviews using Claude's advanced reasoning capabilities

License: MIT GitHub Actions Anthropic Claude TypeScript GitHub

πŸš€ Quick Start β€’ πŸ“– Features β€’ βš™οΈ Configuration β€’ 🀝 Contributing


🎯 Why AIGNE CodeSmith?

Transform your code review process with Claude's advanced reasoning. Unlike traditional tools, AIGNE CodeSmith doesn't just check syntaxβ€”it understands context, identifies architectural issues, and provides thoughtful feedback that helps your team grow.

✨ What Makes It Special

  • 🧠 Context-Aware Reviews: Leverages Claude's superior reasoning to understand code intent and architecture
  • ⚑ Dual-Model Efficiency: Smart cost optimization with light models for summaries, heavy models for deep analysis
  • 🎯 Focus on What Matters: Skips trivial changes, highlights critical issues that impact code quality
  • πŸ”§ Fully Customizable: Tailor prompts and behavior to match your team's standards and practices

πŸ“– Features

🎯 Core Capabilities

Feature Description Benefit
πŸ“ PR Summarization Auto-generates concise summaries and release notes Save time understanding changes at a glance
πŸ” Line-by-Line Reviews Contextual suggestions for code improvements Catch issues before they reach production
πŸ’° Cost Optimization Incremental reviews track only changed files Minimize API costs while maximizing coverage
🧠 Smart Analysis Uses Claude-3.5-Sonnet for superior reasoning Get architectural insights, not just syntax checks
⚑ Intelligent Skipping Ignores trivial changes (typos, formatting) Focus reviewer attention on meaningful changes
🎨 Custom Prompts Fully customizable review criteria and tone Adapt to your team's standards and practices

πŸš€ Advanced Features

  • Dual-Model Architecture: Light model for summaries, heavy model for deep analysis
  • Conversation Mode: Respond to review comments with clarifications
  • Flexible Filtering: Include/exclude files with glob patterns
  • Multi-Language Support: Reviews in your preferred language
  • Debug Mode: Detailed logging for troubleshooting and optimization

πŸš€ Quick Start

Get up and running in under 2 minutes! Just add one file to your repository.

Step 1: Add the Workflow

Create .github/workflows/aigne-codesmith.yml in your repository:

name: πŸ€– AI Code Review

permissions:
  contents: read
  pull-requests: write

on:
  pull_request:
  pull_request_review_comment:
    types: [created]

concurrency:
  group:
    ${{ github.repository }}-${{ github.event.number || github.head_ref ||
    github.sha }}-${{ github.workflow }}-${{ github.event_name ==
    'pull_request_review_comment' && 'pr_comment' || 'pr' }}
  cancel-in-progress: ${{ github.event_name != 'pull_request_review_comment' }}

jobs:
  review:
    runs-on: ubuntu-latest
    steps:
      - uses: aigne-io/aigne-codesmith@latest
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
        with:
          debug: false
          review_simple_changes: false
          review_comment_lgtm: false

Step 2: Configure Secrets

Add your Anthropic API key to GitHub Secrets:

  1. Go to your repository Settings β†’ Secrets and variables β†’ Actions
  2. Click New repository secret
  3. Name: ANTHROPIC_API_KEY
  4. Value: Your API key from Anthropic Console

Step 3: That's It! πŸŽ‰

Open a pull request and watch AIGNE CodeSmith provide intelligent reviews automatically.


πŸ’‘ Examples & Use Cases

🏒 Enterprise Teams

  • Large Codebases: Maintain consistent standards across multiple repositories
  • Security Reviews: Catch security vulnerabilities before they reach production
  • Architectural Guidance: Get insights on design patterns and best practices
  • Onboarding: Help new team members learn from AI-powered feedback

πŸš€ Startups & Small Teams

  • Code Quality: Maintain high standards without dedicated reviewers
  • Knowledge Sharing: Learn from AI suggestions and improve coding skills
  • Time Saving: Focus on building features, not catching basic issues
  • 24/7 Reviews: Get feedback immediately, regardless of timezone

πŸ“š Open Source Projects

  • Contributor Guidance: Help newcomers understand project standards
  • Consistent Reviews: Maintain quality across diverse contributors
  • Documentation: Auto-generate release notes and change summaries
  • Accessibility: Support multiple languages for global contributors

🎯 Real-World Impact

"AIGNE CodeSmith caught 3 critical security issues in our authentication system that we missed in manual reviews. The architectural suggestions helped us improve our code structure significantly." β€” Sarah Chen, Lead Developer at TechFlow

"We reduced our code review time by 60% while actually improving code quality. The AI provides context that junior developers found incredibly valuable." β€” Marcus Rodriguez, Engineering Manager at DataSync


βš™οΈ Configuration

πŸŽ›οΈ Basic Configuration

Parameter Description Default
anthropic_light_model Model for summaries claude-3-5-sonnet-latest
anthropic_heavy_model Model for detailed reviews claude-3-5-sonnet-latest
max_files Maximum files to review 150
review_simple_changes Review trivial changes false
language Response language (ISO code) en-US

🎨 Custom Prompts

Tailor the AI's personality and focus areas by customizing the system_message:

🎯 Security-Focused Reviews
system_message: |
  You are a security-focused code reviewer. Prioritize identifying:
  - Authentication and authorization flaws
  - Input validation issues
  - SQL injection vulnerabilities
  - XSS prevention
  - Data exposure risks
  - Cryptographic best practices
πŸ—οΈ Architecture & Performance Reviews
system_message: |
  You are an architectural reviewer focusing on:
  - System design patterns
  - Performance bottlenecks
  - Scalability concerns
  - Code maintainability
  - SOLID principles
  - Database optimization

🚫 Ignoring PRs

Skip AI review for specific PRs by adding this to the PR description:

@codesmith: ignore

πŸ“ File Filtering

Use path_filters to include/exclude files:

path_filters: |
  src/**/*.ts
  !**/*.test.ts
  !dist/**

For complete configuration options, see action.yml


πŸ’° Cost & Performance

πŸ“Š Pricing Transparency

Team Size Daily Usage Estimated Cost*
5 developers ~20 PRs $3-5/day
20 developers ~80 PRs $12-20/day
50+ developers ~200 PRs $30-50/day

*Costs vary based on code complexity and review depth. Claude models are significantly more cost-effective than GPT-4.

⚑ Performance Optimizations

  • Smart Caching: Avoids re-reviewing unchanged code
  • Incremental Analysis: Only reviews modified files
  • Model Selection: Light models for summaries, heavy models for complex analysis
  • Concurrent Processing: Parallel file analysis for faster results

🀝 Contributing

We ❀️ contributions! Whether you're fixing bugs, adding features, or improving documentation, your help makes AIGNE CodeSmith better for everyone.

πŸš€ Quick Development Setup

# Clone the repository
git clone https://github.com/aigne-io/aigne-codesmith.git
cd aigne-codesmith

# Install dependencies (Node 17+ required)
pnpm install

# Build and test
pnpm run build
pnpm test

# Package for distribution
pnpm run package

🎯 How to Contribute

  1. πŸ› Found a Bug? Open an issue with reproduction steps
  2. πŸ’‘ Have an Idea? Discuss it in an issue before implementing
  3. πŸ“ Improving Docs? Documentation PRs are always welcome
  4. πŸ§ͺ Adding Tests? Help us improve our test coverage

πŸ”§ Development Commands

Command Purpose
pnpm run build Compile TypeScript
pnpm test Run test suite
pnpm run lint Check code style
pnpm run format Format code
pnpm run all Full CI pipeline

πŸ“‹ Contribution Guidelines

  • Code Style: We use Prettier and ESLint - run pnpm run format before committing
  • Tests: Add tests for new features, ensure existing tests pass
  • Commits: Use clear, descriptive commit messages
  • PRs: Include a clear description of changes and link to related issues

πŸ† Recognition

Contributors are recognized in our release notes and CONTRIBUTORS.md. Thank you for making AIGNE CodeSmith amazing! πŸ™Œ


πŸ“ž Support & Community

πŸ†˜ Getting Help

πŸ”— Stay Connected

  • ⭐ Star this repo to show your support
  • πŸ‘€ Watch releases to get notified of updates
  • 🍴 Fork to experiment with your own modifications
  • πŸ“’ Share with your team and community

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


Made with ❀️ by the AIGNE Team

⭐ Star on GitHub β€’ πŸ› Report Issues β€’ πŸ’‘ Request Features

About

Code reviewer based on aigne-framework

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •