This code snippet will help you pass values from the reducing stage to the summarize stage.
// write the parameters in reduce stage
params.write({ "key": custData.csvId, "value": custData.csvId })
// Get values in summerize
context.output.iterator().each(function (key, value) {});