mesh2cad is an open source Python CLI and MCP server. Give it an STL of a simple mechanical part (plates, brackets, boxes with holes, chamfers, fillets) and it writes a CadQuery script and a STEP solid where the sizes are named parameters, so you can change a hole size and rebuild. It only writes a script when the rebuilt solid matches the mesh within tolerance and refuses otherwise. Install: pip install mesh2cad. MIT licensed, free.
I wanted to edit STL files of simple mechanical parts without remaking them in CAD by hand. Instead of a dead mesh, mesh2cad gives named parameters I can change and rebuild, and it refuses when the fit is not accurate.