Skip to content
This repository was archived by the owner on Jan 10, 2025. It is now read-only.

Commit 48e091c

Browse files
Add docs for explain_fields param in application labeling through SDK (#34)
1 parent d09303b commit 48e091c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

docs/python-sdk.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -517,6 +517,12 @@ You can also set the optional `explain` parameter to `True` to get an explanatio
517517
}
518518
```
519519

520+
If you would only like to get an explanation for certain fields, you can optionally provide a list of field names in the `explain_fields` parameter for which you want an explanation returned. If `explain_fields` is provided, explanations will be returned regardless of whether `explain` is set to `True` or `False`. Here's an example of how to get explanations for the `sentiment` field in the `my_sentiment_classifier` application:
521+
522+
```python
523+
response = refuel_client.label(application='my_sentiment_classifier', inputs=inputs, explain=True, explain_fields=['sentiment'])
524+
```
525+
520526

521527
### Share feedback for application outputs
522528

0 commit comments

Comments
 (0)