You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 10d7777
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: docs/feature-flags.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -402,8 +402,8 @@ as output formatting) won't appear here.
402
402
-`confidence_threshold`: Minimum similarity threshold a candidate must meet to be returned; higher values are stricter. When omitted, the API's high-precision default is used. The scale is defined by the API, so no client-side bounds are enforced. (number, optional)
403
403
-`issue_number`: The number of the existing issue to find duplicates for (number, required)
404
404
-`owner`: The owner of the repository (string, required)
405
-
-`page`: Page number for pagination (min 1) (number, optional)
406
-
-`perPage`: Results per page for pagination (min 1, max 100) (number, optional)
405
+
-`page`: Page number for pagination (min 1). An explicit 0 is forwarded to the API as-is rather than being replaced with 1. (number, optional)
406
+
-`perPage`: Results per page for pagination (min 1, max 100). An explicit 0 is forwarded to the API as-is rather than being replaced with 30. (number, optional)
407
407
-`repo`: The name of the repository (string, required)
// This endpoint owns its defaults. Unlike issue_dependency_read, explicit
75
-
// zero pagination values must be forwarded, not replaced by SDK defaults.
76
-
for_, field:=range []string{"page", "perPage"} {
77
-
schema.Properties[field].Default=nil
78
-
schema.Properties[field].Minimum=new(0.0)
79
-
}
65
+
// Unlike most tools, find_duplicate does not substitute its own default
66
+
// for an explicit 0: it forwards whatever page/perPage value is supplied
67
+
// (including 0) to the API unchanged, letting the API apply its own
68
+
// default. Document that exception here instead of relying solely on the
69
+
// generic WithPagination wording.
70
+
schema.Properties["page"].Description="Page number for pagination (min 1). An explicit 0 is forwarded to the API as-is rather than being replaced with 1."
71
+
schema.Properties["perPage"].Description="Results per page for pagination (min 1, max 100). An explicit 0 is forwarded to the API as-is rather than being replaced with 30."
// A bare issue (no ranking metadata) means ranked duplicate
137
132
// detection is not enabled for this caller; fail clearly rather
138
133
// than returning incomplete candidates.
139
134
ifres.Confidence==""||res.Issue==nil {
140
135
returnutils.NewToolResultError("ranked duplicate detection is unavailable: the semantic-similarity endpoint returned issues without ranking metadata (the server-side duplicate-ranking feature is not enabled for this caller or repository)"), nil, nil
141
136
}
137
+
ref:=newMinimalIssueRef(
138
+
res.Issue.Number,
139
+
res.Issue.Title,
140
+
res.Issue.State,
141
+
res.Issue.HTMLURL,
142
+
"",
143
+
)
142
144
candidates=append(candidates, DuplicateCandidate{
143
145
// Candidates are always scoped to the requested repository, so the
144
146
// ref's repository field is left empty as it was before.
0 commit comments