Skip to content

Commit 90bbfc0

Browse files
chore(litellm): Remove include_prompts parameter (#7679)
The parameter allowed users to opt out of collecting GenAI attributes while keeping `send_default_pii=True`. It is ignored when data collection is used, and the major release drops `send_default_pii` in favor of data collection.
1 parent e88e96e commit 90bbfc0

2 files changed

Lines changed: 34 additions & 75 deletions

File tree

‎sentry_sdk/integrations/litellm.py‎

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ def _input_callback(kwargs: "Dict[str, Any]") -> None:
117117
record_inputs = False
118118
if has_data_collection_enabled(client.options):
119119
record_inputs = client.options["data_collection"]["gen_ai"]["inputs"]
120-
elif should_send_default_pii() and integration.include_prompts:
120+
elif should_send_default_pii():
121121
record_inputs = True
122122

123123
if record_inputs:
@@ -198,7 +198,7 @@ def _success_callback(
198198
record_outputs = False
199199
if has_data_collection_enabled(client.options):
200200
record_outputs = client.options["data_collection"]["gen_ai"]["outputs"]
201-
elif should_send_default_pii() and integration.include_prompts:
201+
elif should_send_default_pii():
202202
record_outputs = True
203203

204204
if record_outputs:
@@ -336,9 +336,6 @@ class LiteLLMIntegration(Integration):
336336
identifier = "litellm"
337337
origin = f"auto.ai.{identifier}"
338338

339-
def __init__(self: "LiteLLMIntegration", include_prompts: bool = True) -> None:
340-
self.include_prompts = include_prompts
341-
342339
@staticmethod
343340
def setup_once() -> None:
344341
"""Set up LiteLLM callbacks for monitoring."""

0 commit comments

Comments
 (0)