Hi,
The default domain for the Serial Number is this.
domain="[('product_id', '=', product_id), '|', ('company_id', '=', False), ('company_id', '=', company_id)]")
this domain is mentioned in the py file so you can replace this in the py side.
Hope it will help you.