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

Function _remove_clause_from_text

agents/coldstart-agent/main.py:1558–1563  ·  view source on GitHub ↗

Remove one resolved clause from the text so generic keywords do not double-fire.

(text: str, clause: str)

Source from the content-addressed store, hash-verified

1556
1557
1558def _remove_clause_from_text(text: str, clause: str) -> str:
1559 """Remove one resolved clause from the text so generic keywords do not double-fire."""
1560 if not text or not clause:
1561 return text
1562 pattern = re.compile(re.escape(clause), re.IGNORECASE)
1563 return pattern.sub(" ", text, count=1)
1564
1565
1566def _derive_methodology_preferences(text_lower: str) -> Dict[str, Any]:

Callers 1

parse_natural_languageFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected