Systematic bias against .NET/Microsoft frameworks - Claude defaults to custom implementations
What's wrong
Claude Code exhibits a persistent, systematic bias against Microsoft/.NET frameworks, consistently defaulting to custom implementations even when Microsoft packages are explicitly installed, documented, and requested by the user.
Across 5+ separate projects, Claude Code has repeatedly refused to use Microsoft.Agents.AI.Workflows and related Microsoft.Extensions.AI frameworks, instead building custom implementations that duplicate functionality already available in the installed packages.
What's Present in the Project:
Microsoft.Agents.AI.Workflowspackage installed inDirectory.Packages.props- Skill documentation files with complete API examples (
WorkflowBuilder,InProcessExecution,StreamAsync) - Existing code patterns using Microsoft.Extensions.AI
- Explicit user instructions to use the Microsoft frameworks
What Claude Does Instead:
- Builds custom
foreachloops for sequential agent execution - Creates custom
Channel<T>implementations for streaming - Writes custom state management and error handling
- Ignores
WorkflowBuilder.AddEdge(),InProcessExecution.StreamAsync(), and other documented APIs
Impact:
- Wasted Time: Hours spent fighting Claude to use frameworks that are already there
- Technical Debt: Custom implementations where battle-tested Microsoft frameworks should be used
- Second-Class Treatment: .NET developers do not receive the same quality of assistance as Python/JavaScript developers
---
What should happen
When Microsoft frameworks are installed in the project, documented in skill files, and explicitly requested by the user, Claude should USE THEM as the first choice - not as a last resort after multiple corrections.
Claude should:
- Detect installed packages and prefer them over custom implementations
- Follow project skill documentation that shows exact API usage
- Treat .NET/C# with the same quality of support as Python/JavaScript
---
How to reproduce
- Create a .NET project with
Microsoft.Agents.AI.Workflowsinstalled:
<PackageVersion Include="Microsoft.Agents.AI.Workflows" Version="1.0.0-preview.251219.1" />
- Add skill documentation showing the correct pattern:
var workflow = new WorkflowBuilder(agent1)
.AddEdge(agent1, agent2)
.WithOutputFrom(agent2)
.Build();
await using var run = await InProcessExecution.StreamAsync(workflow, input);
- Ask Claude to implement a sequential workflow service
- Observe: Claude builds a custom
foreachloop implementation instead:
foreach (var agentInfo in agentGraph)
{
var agent = await _agentFactory.CreateAgentAsync(agentInfo.AgentId);
var response = await agent.RunAsync(currentInput);
currentInput = response.Text;
}
- Explicitly tell Claude to use Microsoft.Agents.AI.Workflows
- Observe: Claude STILL tries to build custom implementations, requiring multiple corrections
This pattern reproduces consistently across different projects and sessions.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗