From 2901b99567180a4d629ee04d855b211fb6b675cd Mon Sep 17 00:00:00 2001
From: s mz <69295615+smz202000@users.noreply.github.com>
Date: Fri, 17 Jul 2026 16:06:58 +0800
Subject: [PATCH] docs: fix EnableConfigDiscovery summary to accurately
describe agent discovery behavior
The previous documentation incorrectly stated that custom instruction files
are always loaded from the working directory regardless of the
EnableConfigDiscovery setting. In practice, agent files (e.g. .github/agents/)
are only discovered when EnableConfigDiscovery is true.
Update the summary to clarify that:
- Agent discovery is gated by EnableConfigDiscovery
- Use SkipCustomInstructions to independently control instruction file loading
Fixes #1887
---
dotnet/src/Types.cs | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/dotnet/src/Types.cs b/dotnet/src/Types.cs
index 2bb643c75..f41d5d679 100644
--- a/dotnet/src/Types.cs
+++ b/dotnet/src/Types.cs
@@ -2983,8 +2983,9 @@ protected SessionConfigBase(SessionConfigBase? other)
/// and , with explicit
/// values taking precedence on name collision.
///
- /// Custom instruction files (.github/copilot-instructions.md, AGENTS.md, etc.)
- /// are always loaded from the working directory regardless of this setting.
+ /// Agent discovery (e.g. .github/agents/) is only performed when this is
+ /// . Use to control
+ /// loading of custom instruction files independently.
///
///
public bool? EnableConfigDiscovery { get; set; }