Comments (5)
from autogen.
Seems that you forget to register message connector for the helper agent? ( and maybe admin agent as well)
from autogen.
Seems that you forget to register message connector for the helper agent? ( and maybe admin agent as well)
@LittleLittleCloud Any document about register messsage connector and other api ?
After I register message connector for the helper agent and admin agent, I got another exceptions,below here:
System.InvalidOperationException: Sequence contains no matching element
at System.Linq.ThrowHelper.ThrowNoMatchException()
at System.Linq.Enumerable.First[TSource](IEnumerable1 source, Func
2 predicate)
at AutoGen.Core.GroupChat.SelectNextSpeakerAsync(IAgent currentSpeaker, IEnumerable1 conversationHistory) at AutoGen.Core.GroupChat.CallAsync(IEnumerable
1 conversationWithName, Int32 maxRound, CancellationToken ct)
at AutoGen.Core.AgentExtension.SendMessageToGroupAsync(IAgent _, IGroupChat groupChat, IEnumerable1 chatHistory, Int32 maxRound, CancellationToken ct) at AutoGen.Core.AgentExtension.SendAsync(IAgent agent, IAgent receiver, IEnumerable
1 chatHistory, Int32 maxRound, CancellationToken ct)
at AutoGen.Core.AgentExtension.SendAsync(IAgent agent, IAgent receiver, String message, IEnumerable`1 chatHistory, Int32 maxRound, CancellationToken ct)
at AutoGen.BasicSamples.Example04_Dynamic_GroupChat_Coding_Task.RunAsync(IKernelBuilder kernelBuilder, OpenAIPromptExecutionSettings settings) in C:\Users\Feynman Loo\Documents\Workspaces\AutoGen.BasicSamples\Example04_Dynamic_GroupChat_Coding_Task.cs:line 238
from autogen.
@feynmanloo I need to run your code for further investigation. In the meantime, the error indicates that group admin fails to generate the next speaker that is one of the current group members. The fail reason can be various though, it might because of hallucination (fabric an agent that doesn't exist), fail to follow the prompt and generate next speaker in given format (The legitimate format needs to be From xxx
, or misconfigure in LLM
from autogen.
@feynmanloo I took a look at your code. The issue is caused by missing stop words in admin's prompt setting. You might want to pass [":"]
to stop sequence when creating admin. When I add the right stop sequence to admin, the error was gone.
However, the task still fail because of group admin fails to generate the next speaker in the right format even after I add stop sequence. I note that you are using llama3:7b as the backend model for all agents, including group admin. Yet the prompt for speaker selection used by group admin is based on gpt-3.5/4. So that might be why the admin fails to follow the prompt here because different LLM behaves differently even using the same prompt. And next speaker selection prompt for GPT-series might not work well with llama-series.
So here is the suggestion that you may try
- use gpt-3.5/4 for admin, and llama3 for others.
- If you still want to use llama3 for admin, adding a fallback logic using middleware to admin so it always returns a legitimate next speaker. For example, in the middleware, if the reply from inner agent is not
From xxx
, return a hard-code value. - manually orchestrate agents, for example, having a seperate agent generate step and assign that step to specific agent. In this way you no longer need group chat and can achieve the full flexibility in constructing agentic workflow.
from autogen.
Related Issues (20)
- TYPE ERROR GenerativeServiceClient.count_tokens() takes from 1 to 2 positional arguments but 3 were given
- [Bug]: Missing packaging module HOT 2
- [Feature Request]: Better function return value serialization
- [Feature Request]: support cloudflare AI gateway HOT 5
- [Feature Request]: A Cache.merge() function HOT 2
- [Issue]: quote_from_bytes() expected bytes HOT 1
- [Issue]: In studio, how to display each agent's response in real time instead of showing all at the end? HOT 2
- TypeError: ConversableAgent.__init__() got an unexpected keyword argument 'description'
- [Issue]: Azure ML Studio deployed models and AutoGen HOT 1
- [Issue]: Error while executing "yarn build"
- [Bug]: docs broken link (404) / example notebook agentchat_graph_modelling_language_using_select_speaker.ipynb missing from repo
- [Bug]: 'OpenAIEmbeddingFunction' object has no attribute 'encode' related to pgvectordb HOT 1
- [Bug]: Llava model not compatible with MultimodalConversableAgent
- [issue]: A special requirement, Make a Questionaire, I want to Assistant Agent ask user question and User reply HOT 3
- [Bug]: gemini-1.5-flash causes error
- [Bug]: Missing gpt-4o chat completion pricing
- [Issue]: Group-chat will not call function when using IOStream HOT 1
- [Issue]: Autogen with vision models like GPT-4o creates HUGE spike in usage and bill HOT 1
- [Bug]: Using Mistral model through Azure Endpoint
- [Issue]: chromadb is collecting data silently
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from autogen.