-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug] handles py code? #1062
Comments
@lucasjinreal Can you provide a complete example in English only? |
For summay, the code can not be executed when LLM produces code in markdown format with |
Let's add "py" to line 1119 of conversable_agent.py |
@rickyloynd-microsoft @sonichi is it solved or there is something to be worked on to solve it ?, If yes , I am interested in working on this issue , |
It's not solved. You can assign yourself and work on it. |
@sonichi can you please elaborate what does this mean, I have briefly gone through the conversable_agent.py present at autogen/agentchat/conversable_agent.py and also the line number 1119 It was an else statement. Maybe I am missing a few more details , I am not quite sure of how to proceed
suggestions are appreciated :) |
I'm currently encountering difficulty in assigning myself.
|
I just assigned you. |
The file is updated. The new line is: autogen/autogen/agentchat/conversable_agent.py Line 1395 in 4426093
|
Oh alright, in that case , I believe that the issue has been solved ? @sonichi @rickyloynd-microsoft or the same line has to be added even at line 1119 as mentioned in the below
|
It hasn't been solved. Just the line number has changed. |
can you also add support for language type "yaml" for which a file has to be created ? |
Two places need to be modified to add an "elif" branch: Line 224 in 4426093
autogen/autogen/agentchat/conversable_agent.py Line 1406 in 4426093
|
In that case, I think , adding "py" along with python and all other languages mentioned over there completes this issue , is that all ? |
Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* Add "py" as lang in conversable agent (#1062) * Add conditions to allow for python executable variants (#1062) * reverted import (#1062) * Parameterized tests, moved Python variants to a constant (#1062) * Moved Python variants to a constant (#1062) * Update autogen/code_utils.py (#1062) Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com> * Update autogen/coding/local_commandline_code_executor.py (#1062) Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com> * Added PYTHON_VARIANTS as imported constant (#1062) * ran pre-commit-check (#1062) --------- Co-authored-by: Chi Wang <wang.chi@microsoft.com> Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
* Add "py" as lang in conversable agent (microsoft#1062) * Add conditions to allow for python executable variants (microsoft#1062) * reverted import (microsoft#1062) * Parameterized tests, moved Python variants to a constant (microsoft#1062) * Moved Python variants to a constant (microsoft#1062) * Update autogen/code_utils.py (microsoft#1062) Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com> * Update autogen/coding/local_commandline_code_executor.py (microsoft#1062) Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com> * Added PYTHON_VARIANTS as imported constant (microsoft#1062) * ran pre-commit-check (microsoft#1062) --------- Co-authored-by: Chi Wang <wang.chi@microsoft.com> Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
在您的计算机上创建一个名为
news_report.py
的新文件,并将此代码粘贴到其中。 然后,请替换<your_api_key>
为您的News API密钥。 如果您没有密钥,请访问News API注册并获取一个免费的API密钥。保存文件后,在命令行中运行以下命令以执行脚本:
当脚本成功执行时,它将显示新闻标题列表。 请注意,由于API限制和网络延迟,结果可能有所不同。
exitcode: 1 (execution failed)
Code output:
unknown language py
The text was updated successfully, but these errors were encountered: