langserve icon indicating copy to clipboard operation
langserve copied to clipboard

is their a way customize my output, like drop "metadata"

Open yaohwang opened this issue 1 year ago • 2 comments
trafficstars

{"output":"ashes","metadata":{"run_id":"cb043b82-d879-43fa-8625-c326509bc822","feedback_tokens":[]}}

I don't really want "metadata", and maybe add "session_id", how can I do this? I'm now using langserve add_routes to complete this.

yaohwang avatar May 17 '24 03:05 yaohwang

Metadata cannot be modified. For session_id the only place where you can put it right now is as part of the output.

eyurtsev avatar May 17 '24 20:05 eyurtsev

Metadata cannot be modified. For session_id the only place where you can put it right now is as part of the output.

hi eyurtsev, I think it maybe required for application developer's like me, since langserve is used for web service, if we can change (add or delete) the output json elements, then we can use langserve directly for application.

the metadata or something else maybe useful for langserve itself or LangSmith etc., but not the final application somehow.

yaohwang avatar May 28 '24 09:05 yaohwang