Model¶
-
class
matchup.models.model.
Model
¶ Bases:
abc.ABC
IR Models base class.
Methods Summary
cast_solution
(structure)process_vocabulary_query_based
(query, vocabulary)Generate document scores based in query run
(query, vocabulary)Define the principal method of IR models. Methods Documentation
-
classmethod
cast_solution
(structure: List[tuple]) → List[matchup.structure.solution.Result]¶
-
classmethod
process_vocabulary_query_based
(query: List[matchup.presentation.text.Term], vocabulary: matchup.structure.vocabulary.Vocabulary) → DefaultDict[str, List[matchup.structure.occurrence.Occurrence]]¶ - Generate document scores based in query
Parameters: - query – query representation
- vocabulary – vocabulary structure
Returns: List of occurrences
-
run
(query: List[matchup.presentation.text.Term], vocabulary: matchup.structure.vocabulary.Vocabulary) → List[matchup.structure.solution.Result]¶ - Define the principal method of IR models.
Parameters: - query – List of all entry terms
- vocabulary – Vocabulary pre-processed
Returns:
-
classmethod