Update types for RemainingSteps, return IsLastStep to previous definition

This commit is contained in:
Nuno Campos
2024-10-15 08:35:31 -07:00
parent fd4629e778
commit 649b742e0a
@@ -5,7 +5,7 @@ from langgraph.managed.base import ManagedValue
class IsLastStepManager(ManagedValue[bool]):
def __call__(self) -> bool:
return self.loop.step == self.loop.stop
return self.loop.step == self.loop.stop - 1
IsLastStep = Annotated[bool, IsLastStepManager]