feat(runtime): Execute codes in a sandbox environment (#2119)

This commit is contained in:
Fangyin Cheng
2024-11-10 22:36:53 +08:00
committed by GitHub
parent 8593f10ae9
commit a134257e5c
22 changed files with 867 additions and 79 deletions

View File

@@ -276,6 +276,8 @@ class BaseChat(ABC):
)
payload.span_id = span.span_id
try:
msg = "<span style='color:red'>ERROR!</span> No response from model"
view_msg = msg
async for output in self.call_streaming_operator(payload):
# Plugin research in result generation
msg = self.prompt_template.output_parser.parse_model_stream_resp_ex(