mirror of
https://github.com/microsoft/agent-framework.git
synced 2026-06-16 21:04:09 +08:00
.NET: API specification for Foundry SDK alignment (#359)
* API specification for Foundry SDK alignment * Add descriptions to the samples * Add descriptions to the samples * Address some review feedback * Remove sample * Remove sample * Update docs/specs/001-foundry-sdk-alignment.md Co-authored-by: westey <164392973+westey-m@users.noreply.github.com> * Update docs/specs/001-foundry-sdk-alignment.md Co-authored-by: westey <164392973+westey-m@users.noreply.github.com> * Update docs/specs/001-foundry-sdk-alignment.md Co-authored-by: westey <164392973+westey-m@users.noreply.github.com> * Update docs/specs/001-foundry-sdk-alignment.md Co-authored-by: westey <164392973+westey-m@users.noreply.github.com> * Address code review feedback --------- Co-authored-by: westey <164392973+westey-m@users.noreply.github.com>
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
<TargetFrameworks>$(ProjectsTargetFrameworks)</TargetFrameworks>
|
||||
<TargetFrameworks Condition="'$(Configuration)' == 'Debug'">$(ProjectsDebugTargetFrameworks)</TargetFrameworks>
|
||||
</PropertyGroup>
|
||||
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Azure.AI.Agents.Persistent" />
|
||||
<PackageReference Include="Azure.AI.OpenAI" />
|
||||
|
||||
@@ -27,23 +27,19 @@ public sealed class Step09_ChatClientAgent_3rdPartyThreadStorage(ITestOutputHelp
|
||||
[InlineData(ChatClientProviders.OpenAIResponses_InMemoryMessageThread)]
|
||||
public async Task ThirdPartyStorageThread(ChatClientProviders provider)
|
||||
{
|
||||
var inMemoryVectorStore = new InMemoryVectorStore();
|
||||
VectorStore vectorStore = new InMemoryVectorStore();
|
||||
|
||||
// Define the options for the chat client agent.
|
||||
var agentOptions = new ChatClientAgentOptions
|
||||
{
|
||||
Name = JokerName,
|
||||
Instructions = JokerInstructions,
|
||||
|
||||
// Get chat options based on the store type, if needed.
|
||||
ChatOptions = base.GetChatOptions(provider),
|
||||
|
||||
ChatMessageStoreFactory = () =>
|
||||
{
|
||||
// Create a new chat message store for this agent that stores the messages in a vector store.
|
||||
// Each thread must get its own copy of the VectorChatMessageStore, since the store
|
||||
// also contains the id that the thread is stored under.
|
||||
return new VectorChatMessageStore(inMemoryVectorStore);
|
||||
return new VectorChatMessageStore(vectorStore);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user