Learning Structured Models with Weak Supervision