code: def polys(*, nonzero=False, domain="ZZ"):
      # This is a simple strategy, but sufficient the tests below
      elems = {"ZZ": st.integers(), "QQ": st.fractions()}
      coeff_st = st.lists(elems[domain])
      if nonzero:
          coeff_st = coeff_st.filter(any)
      return st.builds(
          Poly, coeff_st, st.just(x), domain=st.just(domain)
      )
  
file_path: sympy/sympy/polys/tests/test_hypothesis.py
imports: from hypothesis import given
  from hypothesis import strategies
  from sympy.abc import x
  from sympy.polys.polytools import Poly
label_desc: Use image node_id 1 for calling a global function with example usage: polys() and returns: st