Using Kalix to implement Finite State Machines, without third party library

We are trying to implement FSM using Kalix, do we need to use third party libraries like Xstate or Spring State Machine. Or we can implement it through a well defined event sourced entity model