Simple AMM routing and Aggregation


I am trying to creati simple effective AMM aggregator with on chain routing, i tried looking into 1inchProtocol but seems like it has been deprecated along with that it is quite complex for a begginer. I tried modifying the normal router for pancakeswap but ended up with quite some issues. Is there any good publically avaialble opnesource aggregation router which allows on chain routing and swaps?