MCPcopy
hub / github.com/Gracker/awesome-android-ai-dev-sources / bool_value

Function bool_value

process_candidates.py:124–134  ·  view source on GitHub ↗
(value: Any)

Source from the content-addressed store, hash-verified

122
123
124def bool_value(value: Any) -> bool | None:
125 if isinstance(value, bool):
126 return value
127 if isinstance(value, (int, float)):
128 return bool(value)
129 normalized = norm_text(value)
130 if normalized in README_TRUE_VALUES:
131 return True
132 if normalized in README_FALSE_VALUES:
133 return False
134 return None
135
136
137def readme_override(source: dict[str, Any]) -> bool | None:

Callers 1

readme_overrideFunction · 0.85

Calls 1

norm_textFunction · 0.85

Tested by

no test coverage detected