MCPcopy Create free account
hub / github.com/OpenRaiser/PaperFlow / contains_phrase

Function contains_phrase

experiments/baselines/nl_profile/runner.py:130–134  ·  view source on GitHub ↗
(text: str, phrase: str)

Source from the content-addressed store, hash-verified

128
129
130def contains_phrase(text: str, phrase: str) -> bool:
131 normalized_phrase = normalize_phrase_text(phrase)
132 if not normalized_phrase:
133 return False
134 return f" {normalized_phrase} " in f" {text} "
135
136
137def tokenize(text: Any) -> List[str]:

Callers 2

phrase_alignment_scoreFunction · 0.70
aspect_coverage_scoreFunction · 0.70

Calls 1

normalize_phrase_textFunction · 0.70

Tested by

no test coverage detected