Assembly of hybrid silver–titania thin films for gas sensors