There are already several software solutions for polar alignment; NINA, ASI Air, SharpCap, StellarMate etc. Of those I think only NINA is open source. They all use the primary imaging camera and the mount to calculate the polar error and display that for the user to manually correct. So the alignment part is already solved.
You’d need to figure out a good mounting solution for whatever servo/motor used (and this will likely be very mount dependant) and then just translating NINA’s (or whatever’s) output into actions for the motors.
This is how I got started. HP Elite desk Mini. If you want room for full size HDDs then get the SFF version.