I'm modifying a tool which uses Z3 (specifically the Python API) to solve bitvector constraints. I need to use a particular external SAT solver instead of the internal Z3 one, so I'm first bit-blasting using the tactic
Then('simplify', 'bit-blast', 'tseitin-cnf')
after which I can relatively easily dump the clauses to a DIMACS file. The problem is mapping the resulting propositional model back to a model of the original constraints: as far as I can tell, the Python API doesn't provide a way to access the model converter corresponding to a tactic. Is this true? If so, can it be done using a different API, or is there an easier way altogether? Basically I just need to know how the propositional variables in the final CNF clauses correspond to the original bitvector variables.
This sounds pretty special purpose. The easiest will likely be that you instrument the goal2sat conversion (and recompile Z3) to save a translation table in a file. I don't think any of the functionality exposed over the API would give you this information.