# README.md # LangGraph Code Review Agent This repository implements a **LangGraph** agent that takes a Python function as input and produces a code review. The review is evaluated by a critic node that scores it on four criteria: 1. **PEP8 compliance** 2. **Type hints** 3. **Edge case handling** 4. **Naming conventions** If the critic returns **`needs_revision`** the rewrite node improves the weakest part of the review. The process repeats up to ``max_rounds`` times. The implementation uses only the technologies specified in the assignment: ``langgraph`` and ``langchain-ollama`` (or ``langchain-openai`` if you prefer). No vector database is used. ## Installation ```bash pip install -r requirements.txt ``` ## Demo Run the demo with: ```bash python main.py ``` It will review the example function ``sort_numbers`` and print the draft review, scores, and verdict.