MCPcopy Create free account
hub / github.com/nlweb-ai/NLWeb / _normalize_bool

Function _normalize_bool

AskAgent/python/webserver/appsdk_adapter_server.py:30–33  ·  view source on GitHub ↗
(value: str | None, default: bool = False)

Source from the content-addressed store, hash-verified

28
29
30def _normalize_bool(value: str | None, default: bool = False) -> bool:
31 if value is None:
32 return default
33 return value.lower() in {"1", "true", "yes", "on"}
34
35
36class AppSDKAdapterServer:

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected