An AI-powered Senior Engineer Agent for your terminal.
Project description
🕵️♂️ Code Inspector AI
Your AI-Powered Senior Engineer in the Terminal.
Code Inspector is a local-first CLI tool that acts as a Senior Software Engineer. It reads your code (not just diffs), understands your architecture, and provides deep, context-aware reviews—all from your terminal.
✨ Features
- 🧠 Deep Context Analysis: Reads full files to understand architectural impact, not just lines changed.
- 💬 Interactive Reviews: Chat with the AI about its feedback (
--interactive). - 📏 Custom Rules: Enforce your team's style and architecture via
codeinspector.yaml(e.g., "No logic in controllers"). - ⚙️ Configurable Brain: Switch between Gemini Flash, Pro, or Ultra models instantly.
- 🚀 Zero Setup: No servers, no webhooks. Just
pip installand run.
📦 Installation
Install directly from PyPI:
pip install codeinspector
⚡ Quick Start
1. Set your API Key
You need a Google Gemini API key. Getting one is free.
# Windows (PowerShell)
$env:GOOGLE_API_KEY = "your_api_key_here"
# Linux/Mac
export GOOGLE_API_KEY="your_api_key_here"
2. Configure Your Engineer (Optional)
Pick your preferred model and set up rules.
# Switch to a more powerful model
codeinspector config model
# Initialize a rule file for your project
codeinspector config rules init
3. Review Your Code
Stage some changes and let the Senior Engineer take a look.
git add .
codeinspector review --interactive
🛠️ Configuration
codeinspector.yaml
Place this file in your repo root to enforce custom rules. The AI will strictly follow them.
rules:
- "SECURITY: No hardcoded API keys."
- "PERFORMANCE: Avoid N+1 queries in loops."
- "ARCHITECTURE: Business logic belongs in Service layer."
- "STYLE: Variable names must be descriptive."
CLI Commands
| Command | Description |
|---|---|
codeinspector review |
precise, architectural code review of staged changes. |
codeinspector review --interactive |
Chat with the AI about the review. |
codeinspector config model |
Select Gemini model (Flash, Pro, etc.). |
codeinspector config rules init |
Create a starter codeinspector.yaml. |
codeinspector config rules add |
Add a new rule via CLI. |
codeinspector commit |
Generate a Conventional Commit message. |
codeinspector pr |
Generate a PR description and create it on GitHub. |
🤝 Contributing
We welcome contributions! Please see CONTRIBUTING.md for details.
- Fork the repo
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
codeinspector commit) - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
📄 License
Distributed under the MIT License. See LICENSE for more information.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file codeinspector-0.1.1.tar.gz.
File metadata
- Download URL: codeinspector-0.1.1.tar.gz
- Upload date:
- Size: 22.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4dfc72b393f5c880763923fb3d481283252eee18e942a8bc144111114323c6cd
|
|
| MD5 |
44d6187aee0733f5cfdfde8b833dcd44
|
|
| BLAKE2b-256 |
07c53328075409e8654b12f0cb05f9510e703e251bca8560cd7d7ddf5738cfa6
|
File details
Details for the file codeinspector-0.1.1-py3-none-any.whl.
File metadata
- Download URL: codeinspector-0.1.1-py3-none-any.whl
- Upload date:
- Size: 27.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2ecf5ce1a2921b9a0a552f6adb5fcece31cb13381daf174b62512318d55f0228
|
|
| MD5 |
db4e3c0e7066785671ce8e7ce5385c9f
|
|
| BLAKE2b-256 |
e398ce1bd74f4057c45268c5fb5de34e31235728a3540de6d02a0002c3a7e4a3
|