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

Function has_any

agents/reading-agent/main.py:2006–2007  ·  view source on GitHub ↗
(terms: Tuple[str, ...])

Source from the content-addressed store, hash-verified

2004
2005 def has_any(terms: Tuple[str, ...]) -> bool:
2006 return any(re.search(rf"(?<![a-z0-9]){re.escape(term)}(?![a-z0-9])", text) for term in terms)
2007
2008 if has_any(("education", "classroom", "k-12", "school", "curriculum", "pedagogy")):
2009 return "AI for Education"
2010 if has_any(("protein", "molecular", "molecule", "biology", "bio", "chemistry", "materials science", "scientific discovery", "ai for science")):

Callers 1

_daily_note_categoryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected