MCPcopy Index your code
hub / github.com/AI45Lab/Code / log

Function log

examples/ahp_agent_monitors_agent.py:61–64  ·  view source on GitHub ↗

输出诊断日志到 stderr(stdout 保留给 JSON-RPC)

(msg: str)

Source from the content-addressed store, hash-verified

59
60
61def log(msg: str):
62 """输出诊断日志到 stderr(stdout 保留给 JSON-RPC)"""
63 ts = datetime.now().strftime("%H:%M:%S")
64 print(f"[{ts}] [AHP-Server] {msg}", file=sys.stderr, flush=True)
65
66
67PRE_TOOL_PROMPT = """\

Callers 6

_ensure_sessionMethod · 0.70
_llm_decideMethod · 0.70
_handle_pre_tool_useMethod · 0.70
_handle_notificationMethod · 0.70
_handle_handshakeMethod · 0.70
runMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected