Fixed syntax and removed deepagents
This commit is contained in:
@@ -75,14 +75,14 @@ Provide the output in the following JSON-like format:
|
|||||||
|
|
||||||
async def rewrite(state: CodeReviewState) -> CodeReviewState:
|
async def rewrite(state: CodeReviewState) -> CodeReviewState:
|
||||||
# Simple rewrite: add a sentence addressing the weakest criterion
|
# Simple rewrite: add a sentence addressing the weakest criterion
|
||||||
additional = f"Additionally, the review should pay more attention to {state['weakest_criterion']}."
|
additional = f"Additionally, the review should pay more attention to {state['weakest_criterion']}.",
|
||||||
state['draft_review'] = state['draft_review'] + "\n" + additional
|
state['draft_review'] = state['draft_review'] + "\n" + additional
|
||||||
state['round'] += 1
|
state['round'] += 1
|
||||||
return state
|
return state
|
||||||
|
|
||||||
# ---------- Graph ----------
|
# ---------- Graph ----------
|
||||||
def build_graph() -> StateGraph[CodeReviewState]:
|
def build_graph() -> StateGraph[CodeReviewState]:
|
||||||
graph = StateGraph(CodeGraphState)
|
graph = StateGraph(CodeReviewState)
|
||||||
graph.add_node("draft_review", draft_review)
|
graph.add_node("draft_review", draft_review)
|
||||||
graph.add_node("reflect", reflect)
|
graph.add_node("reflect", reflect)
|
||||||
graph.add_node("rewrite", rewrite)
|
graph.add_node("rewrite", rewrite)
|
||||||
|
|||||||
Reference in New Issue
Block a user