MCPcopy Create free account
hub / github.com/anthropics/anthropic-sdk-python / event

Function event

tests/lib/tools/toolsets/test_runner.py:80–81  ·  view source on GitHub ↗
(name: str, data: dict[str, Any])

Source from the content-addressed store, hash-verified

78 events: list[str] = []
79
80 def event(name: str, data: dict[str, Any]) -> None:
81 events.append(f"event: {name}\ndata: {json.dumps(data)}\n\n")
82
83 event("message_start", {"type": "message_start", "message": {**message, "content": [], "stop_reason": None}})
84 for index, block in enumerate(message["content"]):

Callers 1

_sseFunction · 0.85

Calls 1

appendMethod · 0.45

Tested by

no test coverage detected