Description
Feature Request
Is it possible to include just a part of the error when a code is executed? For example if I have in a roleplay one of the two agents that executing the code finds:
Traceback (most recent call last):
File "/home/matt/anaconda3/envs/coder/lib/python3.11/site-packages/autogen/oai/completion.py", line 224, in _get_response
response = openai_completion.create(request_timeout=request_timeout, **config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/matt/anaconda3/envs/coder/lib/python3.11/site-packages/openai/api_resources/chat_completion.py", line 25, in create
return super().create(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/matt/anaconda3/envs/coder/lib/python3.11/site-packages/openai/api_resources/abstract/engine_api_resource.py", line 153, in create
response, _, api_key = requestor.request(
^^^^^^^^^^^^^^^^^^
File "/home/matt/anaconda3/envs/coder/lib/python3.11/site-packages/openai/api_requestor.py", line 226, in request
resp, got_stream = self._interpret_response(result, stream)
Can I decide to send to the other agent just the last line? In this case:
File "/home/matt/anaconda3/envs/coder/lib/python3.11/site-packages/openai/api_requestor.py", line 226, in request
resp, got_stream = self._interpret_response(result, stream)