MCPcopy Create free account
hub / github.com/CommonstackAI/UncommonRoute / _has_recent_tool_activity

Function _has_recent_tool_activity

uncommon_route/composition.py:550–558  ·  view source on GitHub ↗
(messages: list[dict[str, Any]])

Source from the content-addressed store, hash-verified

548
549
550def _has_recent_tool_activity(messages: list[dict[str, Any]]) -> bool:
551 for msg in messages:
552 if not isinstance(msg, dict):
553 continue
554 if msg.get("role") == "tool":
555 return True
556 if msg.get("tool_calls"):
557 return True
558 return False
559
560
561def _content_to_text(content: Any) -> str | None:

Callers 1

_checkpoint_historyFunction · 0.85

Calls 1

getMethod · 0.45

Tested by

no test coverage detected