autogen/dotnet/website/tutorial/Chat-with-an-agent.md
Step 4: Generate Response To generate response, you can use one of the overloaded method of @AutoGen.Core.AgentExtension.SendAsync* method. The following code shows how to generate response with text message:  [!code-csharp[Generate Response](../../sample/AutoGen.BasicSamples/GettingStart/Chat_With_Agent.cs?name=Chat_With_Agent)]  To generate response with chat history, you can pass the chat history to the @AutoGen.Core.AgentExtension.SendAsync* method:  [!code-csharp[Generate Response with Chat History](../../sample/AutoGen.BasicSamples/GettingStart/Chat_With_Agent.cs?name=Chat_With_History)]  To streamingly generate response, use @AutoGen.Core.IStreamingAgent.GenerateStreamingReplyAsync*  [!code-csharp[Generate Streaming Response](../../sample/AutoGen.BasicSamples/GettingStart/Chat_With_Agent.cs?name=Streaming_Chat)] 