microsoft / microsoft/agent-framework

.NET: [Bug]: Cannot set ReasoningEffort on gpt-5.6-luna

Open
#8,429 3 comments 0 reactions 1 assignee View on GitHub

@westey-m is already working on this.

Since Sep 18, 2026.

.NET harness
Dominant language
Python
Stars
13.6k
Forks
2.3k
Avg merge
2d 45m
Merged PRs (30d)
358

Description

Description

I created a HarnessAgent backed by a gpt-5.6-luna deployment on Foundry.

After I set the ReasoningOptions, I started getting 400 responses from the Foundry service.

Code Sample

I use the ChatClient from the Aspire Azure OpenAI integration:

var azureOpenAIDeploymentName = builder.Configuration["AzureOpenAI:DeploymentName"];

builder.AddAzureOpenAIClient(connectionName: "openai")
       .AddChatClient(azureOpenAIDeploymentName); // model deployment name from Azure AI Foundry
return sp.GetRequiredService<IChatClient>().AsHarnessAgent(new HarnessAgentOptions
        {
            Name = name,
            HarnessInstructions = Instructions,
            ChatOptions = new ChatOptions { Tools = tools, Reasoning = new() { Effort = ReasoningEffort.Medium, Output = ReasoningOutput.Summary} },
            AIContextProviders = contextProviders,
            DisableWebSearch = true,
            OpenTelemetrySourceName = GenAiSourceNames.Agents,
        });
Error Messages / Stack Traces
HTTP 400 (invalid_request_error: )

Parameter: reasoning_effort

Function tools with reasoning_effort are not supported for gpt-5.6-luna in /v1/chat/completions. To use function tools, use /v1/responses or set reasoning_effort to 'none'.
Package Versions

Microsoft.Agents.AI.Harness: 1.21.0, Aspire.Azure.AI.OpenAI: 13.5.4-preview.1.26464.4

.NET Version

.NET 10.0

Additional Context

The url that Agent Framework calls is:

https://.openai.azure.com/openai/deployments/gpt-5.6-luna/chat/completions?*

It is unclear why the (Azure) OpenAI ChatClient does not use the Responses API instead of the (legacy) Chat Completions API.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.