Conway and Sloane, as well as Cassels, and also O'Meara, all have their own idiosyncratic way of expressing the following result (for good primes): Every quadratic form with coefficients in $\mathbb{Z}_p$ is equivalent by a change of variables with coefficients $\mathbb{Z}_p$ to one expressible as $\oplus_{i} p^{e_i}h(\epsilon_i, m_i)$, where $h(\epsilon_i, m_i)$ is $y_1^2+y_2^2+\ldots+y_{m_i}^2$ if $\epsilon_i=0$, and $y_1^2+y_2^2+\ldots+ry_{m_i}^2$ with $r$ a quadratic nonresidue if $\epsilon_i=1$.
Furthermore there is a quadratic form $f$ over the integers with given local components $f_i$ if and only if the compatibility conditions for rational equivalence are satisfied.
In the case of rational equivalence this has been given an effective treatment by Kirschmer and a coauthor whose name escapes me right now: given a discriminant and a list of primes where the form should have negative Hasse-Witt invariant, they compute a quadratic form. What I would like is a function that given a discriminant (as an integer), and a list of local components, computes a quadratic form in the given genus, i.e. computes the form $f$ described above.