Skip to content

Sequence Likelihood

Jinho D. Choi edited this page Feb 9, 2015 · 1 revision

Segment Abstract Class

  • Create a package segment.
  • Put the Sequence class under segment.
  • Create an abstract class AbstractSegment under segment.
  • Create a constructor.
  • @param model a language model.
  • Create an abstract method segment.
  • @return the word sequence segmented from the string with the highest probability.
  • @param s the string to segment.

Segment

  • Create a class Segment under segment.
  • Extend AbstractSegment.
  • Create a constructor.
  • @param model a language model.
  • Override the segment method.
  • You may want to create an auxiliary method called recursively.

Evaluation

Quiz 2

  • Run SegmentTest using the unigramWeight of 0.5 instead. What are the new sequences and their maximum likelihoods? Explain why the results change.

Artificial Intelligence

Instructor


Emory University

Clone this wiki locally