Solution published with README: add README.md

This commit is contained in:
2026-06-18 13:05:39 +00:00
parent 1300548963
commit f5681155ff
+29
View File
@@ -0,0 +1,29 @@
# 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.