Open WebsheetPlugin opened 3 months ago
@davorrunje have you observed a similar need?
In general, outputting full stack traces is a security issue because it can leak internal secrets used by functions and not accessible to LLM. This is why we catch an exception and write a generic message by default. If users wish to override such behaviour, they can wrap the body of the function and write their own exception handling (outputting string formatted by exception handling code) and assume all risks associated with it. In my opinion, we should not do this automatically because we could easily leak secrets to the LLM and the LLM could easily leak further by calling other functions or executing code.
There is some misunderstanding. Here are three points to consider:
1) Normally, a raised error would stop the execution. So when developing the app it would be best, as it would not wait for the whole conversation to finish.
2) When I proposed to log the stack in B, I did not want to feed it back into the messages. I just wrote we should log those. Because curently you can get very unmeaningful errors.
3) Regarding try/catch proposal. Yes, it would work, but it would make more sense to try to catch it if you like to put it back into the message stream and not the other way around...
My reasoning:
@WebsheetPlugin do you think a "debug mode" for function/tool executor makes sense, in which: every exception is raised and the app just dies?
I tend to agree with Davor that adding the stack trace to the error message should be a conscious choice, we can certainly make it easier to do that by adding an option to show the stack trace (off by default).
Ok guys :) You don't get me. Ofc, I agree with Davor that we should not add the stack trace to the error message. This is not the point I tried to make.
Why are we adding an error message back to the stream by default? Can someone explain to me this logic? Is this normal?
I think all this is done, because of some old openAi example, but if you think about this logic, it's not natural. As it is final and irreversible(Or how can I stop the application with an error now? As Autogen decides for me to catch/try and feed into the message stream).
If someone wants likes this behaviour to happen, then he should put it into try/catch himself. Got me?
@ekzhu, I just read it to the end. Yes, your idea would solve it! but in my opinion, it should be the default state!
I get you. There are two things:
I think we can have options for both of the above.
Hey @ekzhu , is there any update on this? Tool debugging is very hard without this feature...
@WebsheetPlugin we haven't updated this. For (1) above, would you like to submit a PR?
I am a bit late to the party, but here are my two cents on the problem:
Is your feature request related to a problem? Please describe.
A) Is there a possibility of raising the error I get from calling a tool? Curently it's writing only back the text, without the stack trace This would allow me to faster develop the app.
B) Another way of solving the problem would be to log the stack trace.
Describe the solution you'd like
No response
Additional context
No response