MCPcopy Create free account

hub / github.com/alibaba/open-code-review / functions

Functions3,271 in github.com/alibaba/open-code-review

↓ 7 callersFunctioncustomConfigModelTUI
(t *testing.T, configPath string, models []string)
cmd/opencodereview/provider_tui_funcs_test.go:969
↓ 7 callersMethodcustomProviderEntry
(name string, fallback ProviderEntry)
cmd/opencodereview/provider_tui.go:565
↓ 7 callersFunctionencodeRepoPath
(p string)
internal/session/persist.go:71
↓ 7 callersFunctionfinishManifestFlow
(t *testing.T, a *Agent)
internal/agent/manifest_integration_test.go:81
↓ 7 callersFunctioninitTestRepo
(t *testing.T)
internal/scan/provider_test.go:81
↓ 7 callersFunctionmakeDiff
()
internal/diff/relocation_test.go:40
↓ 7 callersMethodmapResponsesResponse
mapResponsesResponse converts the SDK Response into the shared ChatResponse. Text output is read via the SDK's OutputText() helper (it walks all outpu
internal/llm/responses_client.go:202
↓ 7 callersFunctionnewManifestFlowAgent
(t *testing.T, diffs []model.Diff, resume *session.ResumeState)
internal/agent/manifest_integration_test.go:41
↓ 7 callersFunctionpeekSession
peekSession reads the first record, all review_item records (for comment count), and the last record of a JSONL file.
internal/viewer/store.go:137
↓ 7 callersMethodrecordWarning
recordWarning adds a non-fatal warning to the agent's warning list.
internal/agent/agent.go:430
↓ 7 callersMethodrepoRoot
()
extensions/vscode/src/extension/services/GitService.ts:251
↓ 7 callersMethodrunCompression
runCompression performs three-zone memory compression on the given messages, summarizing the compress zone while preserving the active zone intact. Re
internal/llmloop/compression.go:209
↓ 7 callersMethodrunGit
(ctx context.Context, args ...string)
internal/diff/git.go:605
↓ 7 callersMethodselectedCustomProvider
()
cmd/opencodereview/provider_tui.go:387
↓ 7 callersMethodsyncSessionModelSelection
()
cmd/opencodereview/provider_tui.go:574
↓ 7 callersFunctionvalidateReviewRefs
validateReviewRefs rejects ref-option injection (#112): any --from/--to/ --commit value must be a real commit ref and must not start with '-'.
cmd/opencodereview/review_cmd.go:328
↓ 6 callersFunctionCanonicalPath
CanonicalPath returns an absolute path with symlinks resolved.
internal/pathutil/path.go:10
↓ 6 callersMethodCommentsForPath
CommentsForPath returns a copy of comments whose Path matches the given path.
internal/tool/comment_collector.go:38
↓ 6 callersMethodCompletionsWithCtx
CompletionsWithCtx sends a chat completion request with context support.
internal/llm/client.go:631
↓ 6 callersFunctionDynamic
Dynamic creates a Tool with the given name for dynamically discovered tools (e.g. MCP).
internal/tool/definitions.go:48
↓ 6 callersMethodEnumerate
Enumerate returns one ScanItem per reviewable file. Binaries are emitted with empty Content + IsBinary=true so previews can show them as excluded.
internal/scan/provider.go:77
↓ 6 callersFunctionIsPathExcluded
IsPathExcluded returns true when relPath matches any of the supplied gitignore-style patterns or any default excluded directory prefix (see ExcludedDi
internal/diff/gitignore.go:22
↓ 6 callersMethodIsUserExcluded
IsUserExcluded reports whether the given path matches any user exclude pattern.
internal/config/rules/system_rules.go:219
↓ 6 callersFunctionNewFileReadDiff
(dm DiffMap)
internal/tool/file_read_diff.go:34
↓ 6 callersFunctionNewLLMClient
--- Factory --- NewLLMClient creates the appropriate client based on the resolved endpoint protocol. protocol dispatch (canonical names from protocol.
internal/llm/client.go:205
↓ 6 callersFunctionNewProvider
NewProvider creates a Provider for range mode: from..to (via merge-base).
internal/diff/git.go:64
↓ 6 callersFunctionNewStub
(t Tool)
internal/tool/stub.go:11
↓ 6 callersFunctionParseComments
ParseComments extracts LlmComment entries from tool call arguments without writing to the Collector. Returns parsed comments and an error message (emp
internal/tool/code_comment.go:71
↓ 6 callersFunctionParseHunks
ParseHunks parses raw unified diff text for a single file into a slice of Hunks. Lines before the first @@ header (file-level headers like "diff --git
internal/diff/hunk.go:37
↓ 6 callersMethodRunManifest
RunManifest returns the frozen v1 coverage result for review runs. Scan remains legacy and returns nil.
cmd/opencodereview/shared.go:300
↓ 6 callersMethodSealSelected
SealSelected closes the selected set. After it returns, RegisterSelected fails and the coverage denominator is fixed; per-item Mark* calls continue to
internal/session/manifest.go:528
↓ 6 callersFunctionStripMarkdownFences
StripMarkdownFences removes ```json and ``` wrappers some models add around structured outputs. Exposed so callers (e.g. agent's review-filter post-st
internal/llmloop/compression.go:159
↓ 6 callersMethodValidate
()
internal/config/template/template.go:188
↓ 6 callersFunctionapplyCLIExcludes
applyCLIExcludes appends user-supplied --exclude patterns (already split into a []string) onto cc.FileFilter.Exclude. Creates the FileFilter if none w
cmd/opencodereview/shared.go:218
↓ 6 callersFunctionapplyCustomProviderConfig
(configPath string, cfg *Config, result providerTUIResult)
cmd/opencodereview/provider_cmd.go:152
↓ 6 callersMethodapplySessionStart
(rec resumeRecord)
internal/session/resume.go:137
↓ 6 callersMethodassert_line
(self, c, want_line)
examples/gerrit_ci/post_review_test.py:56
↓ 6 callersFunctioncharKey
(c rune)
cmd/opencodereview/provider_tui_test.go:39
↓ 6 callersFunctioncompareReadmeStructures
(files)
scripts/github-actions/check-translation-sync.js:124
↓ 6 callersFunctioneffectivePath
(d model.Diff)
internal/agent/preview.go:101
↓ 6 callersFunctionensureMetrics
()
internal/telemetry/metrics.go:29
↓ 6 callersMethodenterEditCustomProvider
()
cmd/opencodereview/provider_tui.go:1017
↓ 6 callersMethodexecuteReviewFilter
executeReviewFilter runs the REVIEW_FILTER_TASK to remove comments that are provably incorrect based solely on the diff. Errors are logged and silentl
internal/agent/agent.go:1231
↓ 6 callersFunctionextractHeadings
(markdown)
scripts/github-actions/check-translation-sync.js:56
↓ 6 callersFunctionextractSideLines
extractSideLines extracts one side of the diff from a hunk. When newSide is true, returns context+added lines with new-file line numbers. When newSide
internal/diff/resolver.go:117
↓ 6 callersFunctiongetPrDiffHunks
({ github, owner, repo, prNumber, commitSha, log, cache })
scripts/github-actions/post-review-comments.js:1971
↓ 6 callersFunctiongitCommit
(t *testing.T, repo, msg string)
internal/scan/provider_test.go:113
↓ 6 callersFunctiongroupBatches
groupBatches partitions items according to strategy, then slices each natural group into BatchSize-sized chunks (when size > 0). Within a batch the in
internal/scan/batch.go:42
↓ 6 callersFunctionhandleRepos
(w http.ResponseWriter, r *http.Request, root string)
internal/viewer/handler.go:9
↓ 6 callersFunctioninitBareRepo
initBareRepo creates an empty (unborn) git repository with identity configured but no commits, returning the repo dir.
internal/diff/git_resolve_test.go:27
↓ 6 callersFunctioninitRepoWithChange
initRepoWithChange creates a real git repository with one committed file and an uncommitted working-tree modification, returning the repo dir. There i
internal/diff/git_test.go:45
↓ 6 callersFunctionlistCursorPrefix
(isCursor bool)
cmd/opencodereview/provider_tui.go:1929
↓ 6 callersFunctionloadPackageJSON
(t *testing.T)
internal/release/asset_naming_test.go:31
↓ 6 callersFunctionlooksLikeFilePath
looksLikeFilePath returns true when s is likely a file path (not inline content). Heuristic: multi-line text is always inline; single-line text withou
internal/config/rules/system_rules.go:500
↓ 6 callersFunctionmaskedSecretPlaceholder
()
cmd/opencodereview/provider_tui.go:847
↓ 6 callersFunctionparseBpeData
parseBpeData parses the base64-encoded BPE data format. Each line: <base64-token> <rank>
internal/llm/embedded_loader.go:53
↓ 6 callersFunctionparseTemplate
(name string)
internal/viewer/server.go:92
↓ 6 callersMethodread
()
extensions/vscode/src/extension/services/ConfigService.ts:17
↓ 6 callersFunctionreadme
(headings)
scripts/github-actions/check-translation-sync.test.js:28
↓ 6 callersFunctionrenderComment
(comment model.LlmComment)
cmd/opencodereview/output.go:86
↓ 6 callersFunctionrunConfig
runConfig provides test compatibility: dispatches config subcommands through a fresh cobra command tree that mirrors the production config command, so
cmd/opencodereview/compat_test.go:112
↓ 6 callersFunctionrunGitCmd
(repoDir string, args ...string)
cmd/opencodereview/git.go:9
↓ 6 callersMethodrunRaw
运行任意参数,流式回调日志,结束返回 stdout 全文。退出码非 0 时 reject,并带上 CLI 报错文本。
extensions/vscode/src/extension/services/CliService.ts:105
↓ 6 callersFunctionsanitizeMarkdown
(s string)
cmd/opencodereview/background_file.go:96
↓ 6 callersFunctionsel
(id string)
internal/session/manifest_test.go:13
↓ 6 callersMethodtrace
(msg: string)
extensions/vscode/src/extension/services/GitService.ts:17
↓ 6 callersMethodtryApplyPendingCompression
tryApplyPendingCompression checks whether a background compression has completed and swaps the rebuilt messages into place. Returns true if applied.
internal/llmloop/compression.go:318
↓ 6 callersFunctionunmarshalResponsesBody
--- helpers ---
internal/llm/responses_client_test.go:666
↓ 6 callersFunctionupKey
()
cmd/opencodereview/provider_tui_funcs_test.go:270
↓ 6 callersMethodwriteRecordLocked
(rec map[string]any)
internal/session/persist.go:120
↓ 5 callersMethodAsDiff
AsDiff returns a Diff suitable for handing to code that expects the diff-based shape (line-number resolver, file_read_diff tool). The Diff field stays
internal/model/scan.go:19
↓ 5 callersMethodBudgetExceeded
BudgetExceeded reports whether the aggregate token budget gate stopped the run before all files were reviewed. It is a diagnostic signal only — it fee
cmd/opencodereview/shared.go:297
↓ 5 callersFunctionCollectToolDefs
CollectToolDefs gathers tool definitions from MCP clients, filtering out tools that conflict with built-in tools or were not successfully registered.
internal/mcp/provider.go:96
↓ 5 callersFunctionContextWithTraceParentFromEnv
ContextWithTraceParentFromEnv extracts W3C traceparent from the TRACEPARENT environment variable and returns a context carrying the upstream span cont
internal/telemetry/span.go:32
↓ 5 callersFunctionCountMessagesTokens
CountMessagesTokens returns the rough token count of msgs by summing the per-message text token count. Exported because both review and scan top layer
internal/llmloop/compression.go:66
↓ 5 callersMethodFilesReviewed
()
cmd/opencodereview/shared.go:274
↓ 5 callersMethodFinalize
Finalize performs the hard-validated close of the run and returns the immutable manifest. In order it: sweeps any item still selected into failed (col
internal/session/manifest.go:739
↓ 5 callersFunctionInit
Init initializes global TracerProvider and MeterProvider based on environment variables and optional config file. Returns true when enabled. Safe to c
internal/telemetry/provider.go:29
↓ 5 callersFunctionLoad
Load parses the tools config file. When path is empty, falls back to the embedded default tools configuration.
internal/config/toolsconfig/toolsconfig.go:24
↓ 5 callersFunctionLoadDetail
LoadDetail returns the summary plus per-file item records for one session.
internal/session/list.go:137
↓ 5 callersFunctionLoadScanDefault
LoadScanDefault parses the embedded scan_template.json.
internal/config/template/template.go:134
↓ 5 callersMethodMarkReused
MarkReused records that the item was reused from a parent session checkpoint.
internal/session/manifest.go:693
↓ 5 callersMethodMarkWaived
MarkWaived records that the user explicitly waived this selected item, which must still be in the pre-terminal (selected) state. reason is required an
internal/session/manifest.go:710
↓ 5 callersMethodPreview
Preview enumerates files and applies the standard reviewability filter without dispatching any LLM calls. Returns a *model.Preview ready for cmd/openc
internal/scan/preview.go:18
↓ 5 callersFunctionReLocateComment
ReLocateComment calls the LLM to regenerate a precise existing_code snippet when text-based matching fails, then retries ResolveComment with the new s
internal/diff/relocation.go:20
↓ 5 callersFunctionRecordCommentsGenerated
(ctx context.Context, n int64)
internal/telemetry/metrics.go:94
↓ 5 callersFunctionRecordReviewDuration
(ctx context.Context, dur time.Duration)
internal/telemetry/metrics.go:74
↓ 5 callersMethodRecordReviewItemFailed
RecordReviewItemFailed persists an incomplete file-level checkpoint.
internal/session/history.go:269
↓ 5 callersMethodReplaceSince
ReplaceSince replaces comments[start:] with the given replacements. Useful for batch-level dedup: take a Snapshot, run a batch, dedup the new comments
internal/tool/comment_collector.go:79
↓ 5 callersFunctionResolveComment
ResolveComment attempts to resolve StartLine/EndLine for a single comment by matching ExistingCode against the diff. Returns true on success.
internal/diff/resolver.go:59
↓ 5 callersMethodRun
Run executes a git command and returns the combined stdout+stderr output.
internal/gitcmd/runner.go:44
↓ 5 callersMethodSetPendingFailureCause
SetPendingFailureCause records the classification Finalize must use when it sweeps items that never received a Mark*. It records no run_failure and tr
internal/session/manifest.go:457
↓ 5 callersFunctionStartLLMSpan
StartLLMSpan creates a span for an LLM request with standard attributes.
internal/telemetry/span.go:106
↓ 5 callersMethodString
String renders a one-line human-readable estimate, matching scan.Estimate's format so diff and scan warnings read consistently. Money is intentionally
internal/agent/estimate.go:91
↓ 5 callersMethodTools
()
internal/mcp/client.go:152
↓ 5 callersFunctionagentTaskDoneResponse
()
internal/agent/agent_test.go:35
↓ 5 callersMethodapiKeyStepCanConfirm
()
cmd/opencodereview/provider_tui.go:914
↓ 5 callersFunctionapplyDedupGroups
applyDedupGroups parses the DEDUP_TASK output and returns the deduped comment slice. Returns (nil, false) when the response is malformed OR when the g
internal/scan/agent.go:818
↓ 5 callersMethodapplyEditCustomProviderSave
()
cmd/opencodereview/provider_tui.go:1219
↓ 5 callersFunctionapplyManualConfig
(configPath string, cfg *Config, result providerTUIResult)
cmd/opencodereview/provider_cmd.go:98
← previousnext →201–300 of 3,271, ranked by callers