code: def time_context_from_timex(timex):
      
      time_text = timex.get('text')
      constraint = timex['intervals'][0]
      start = _get_time_stamp(constraint.get('start'))
      end = _get_time_stamp(constraint.get('end'))
      duration = constraint['duration']
      tc = TimeContext(text=time_text, start=start, end=end,
                       duration=duration)
      return tc
docs: Return a TimeContext object given a timex entry.