You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -225,9 +225,9 @@ This program has the same output has the one from the previous section.
225
225
226
226
## Muting Block Output with contribute
227
227
228
-
By default, when a PDL block is executed it produces a result that gets printed in the output document. It is possible to mute this feature by setting `show_result` to `false` for any block. This feature allows the computation of intermediate values that are not necessarily output in the document. The value of the variable specified in `def` is still set to the result of the block.
228
+
By default, when a PDL block is executed it produces a result that is contributed to the overall result, and it also contributes to the background context. It is possible to mute both contributions by setting `contribute` to `[]` for any block. This feature allows the computation of intermediate values that are not necessarily output in the document. The value of the variable specified in `def` is still set to the result of the block.
229
229
230
-
Consider the same example as above, but with `show_result` set to `false` ([file](https://github.com/IBM/prompt-declaration-language//blob/main/examples/tutorial/muting_block_output.pdl)):
230
+
Consider the same example as above, but with `contribute` set to `[]` ([file](https://github.com/IBM/prompt-declaration-language//blob/main/examples/tutorial/muting_block_output.pdl)):
231
231
232
232
```yaml
233
233
description: function def and call
@@ -261,7 +261,7 @@ In general, `contribute` can be used to set how the result of the block contribu
261
261
Here are its possible values:
262
262
- `[]`: no contribution to either the final result or the background context
263
263
264
-
- `[result]: contribute to the final result but not the background context
264
+
- `[result]`: contribute to the final result but not the background context
265
265
266
266
- `[context]`: contribute to the background context but not the final result
267
267
@@ -738,7 +738,7 @@ To change the log filename, you can pass it to the interpreter as follows:
738
738
739
739
Some of the most common prompt patterns/techniques have been implemented as PDL functions. A demo of the ReAct template:
0 commit comments