MCPcopy Create free account

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

Functions2,775 in github.com/alibaba/open-code-review

↓ 4 callersFunctionLoadResumeState
LoadResumeState replays a previous session JSONL into a fingerprint index.
internal/session/resume.go:68
↓ 4 callersFunctionParseExtraHeaders
ParseExtraHeaders parses a string of comma-separated key=value pairs into a dictionary. Values may be double-quoted to include commas, e.g. X-Forwarde
internal/llm/resolver.go:609
↓ 4 callersFunctionPrintTraceSummary
PrintTraceSummary prints a one-line summary of the review to stdout.
internal/telemetry/events.go:69
↓ 4 callersMethodProjectSummary
ProjectSummary is the markdown project-level summary produced by scan's PROJECT_SUMMARY_TASK. Empty for review mode and for scans that skipped / faile
cmd/opencodereview/shared.go:252
↓ 4 callersFunctionRecordFilesReviewed
(ctx context.Context, n int64)
internal/telemetry/metrics.go:84
↓ 4 callersFunctionRecordToolResult
RecordToolResult sets the outcome of a tool execution on the span.
internal/telemetry/span.go:90
↓ 4 callersMethodRecordWarning
RecordWarning adds a non-fatal warning.
internal/llmloop/loop.go:89
↓ 4 callersFunctionShutdown
Shutdown flushes and shuts down all initialized providers. It should be called before process exit to ensure buffered data is exported.
internal/telemetry/shutdown.go:12
↓ 4 callersMethodSubmit
Submit runs f in a background goroutine bounded by the semaphore. When f completes its return value is collected internally.
internal/llmloop/pool.go:61
↓ 4 callersFunctionToToolDef
ToToolDef converts an MCP tool definition to an llm.ToolDef.
internal/mcp/provider.go:67
↓ 4 callersMethodTotalInputTokens
TotalInputTokens returns the accumulated input/prompt tokens from all LLM calls.
internal/llmloop/loop.go:63
↓ 4 callersFunctionUseTestSessions
UseTestSessions redirects session persistence to the "test-sessions" subdirectory so that test runs do not pollute the real sessions store. It must b
internal/session/testing.go:8
↓ 4 callersFunctionWithinBase
WithinBase reports whether target is base itself or contained under base.
internal/pathutil/path.go:19
↓ 4 callersMethodacquire
(ctx context.Context)
internal/gitcmd/runner.go:29
↓ 4 callersFunctionapplyModelDeleteToEntry
(entry ProviderEntry, name string)
cmd/opencodereview/provider_tui.go:431
↓ 4 callersFunctionapplyOfficialProviderConfig
(configPath string, cfg *Config, result providerTUIResult)
cmd/opencodereview/provider_cmd.go:227
↓ 4 callersFunctionbatchPaths
(b [][]model.ScanItem)
internal/scan/batch_test.go:18
↓ 4 callersFunctionbuildAllowedHosts
buildAllowedHosts returns the default-deny allowlist used by the host guard. The set always includes the standard loopback names. If bindHost is a con
internal/viewer/hostguard.go:58
↓ 4 callersFunctionclearCfgActiveModelIfDeleted
(cfg *Config, providerName, name string)
cmd/opencodereview/provider_tui.go:439
↓ 4 callersFunctioncmt
(path, content string)
internal/scan/dedup_test.go:10
↓ 4 callersMethodcustomProviderActiveModel
(cp customProviderListItem)
cmd/opencodereview/provider_tui.go:199
↓ 4 callersMethoddedupEnabled
()
internal/scan/agent.go:79
↓ 4 callersFunctiondefaultAuthHeader
(protocol string)
internal/llm/resolver.go:559
↓ 4 callersMethoddispatchSubtasks
dispatchSubtasks groups items into batches per the configured strategy, then processes batches sequentially while running files within each batch conc
internal/scan/agent.go:385
↓ 4 callersFunctionestimateCost
(items []model.ScanItem, planEnabled, dedupEnabled, summaryEnabled bool)
internal/scan/estimate.go:59
↓ 4 callersMethodexecuteSubtask
executeSubtask runs the scan pipeline for one file: 1. Optional PLAN_TASK: produce a JSON checklist of focus areas. 2. MAIN_TASK: review the file with
internal/scan/agent.go:535
↓ 4 callersFunctionfencedBlock
(content, language = "")
scripts/github-actions/post-review-comments.js:1145
↓ 4 callersMethodfilterLargeDiffs
filterLargeDiffs drops diffs whose diff content alone consumes more than 80% of MaxTokens.
internal/agent/agent.go:786
↓ 4 callersMethodfilterLargeScans
filterLargeScans drops items whose content exceeds 80% of MaxTokens.
internal/scan/agent.go:320
↓ 4 callersMethodfindCustomIdx
(name string)
cmd/opencodereview/provider_tui.go:1289
↓ 4 callersFunctionformatPlanGuidance
formatPlanGuidance parses the PLAN_TASK JSON output into a markdown snippet suitable for embedding in MAIN_TASK. On parse failure it returns the raw c
internal/scan/agent.go:840
↓ 4 callersFunctiongetShellEnv
()
extensions/vscode/src/extension/services/shellEnv.ts:26
↓ 4 callersFunctionhandleSession
(w http.ResponseWriter, r *http.Request, root, repo, sessionID string)
internal/viewer/handler.go:61
↓ 4 callersFunctionhandleSessions
(w http.ResponseWriter, r *http.Request, root, repo string)
internal/viewer/handler.go:32
↓ 4 callersFunctionhumanTokens
humanTokens formats a token count as e.g. "1.2M" / "850K" / "420".
internal/scan/estimate.go:111
↓ 4 callersMethodisUserAddedOfficialModel
(name string)
cmd/opencodereview/provider_tui.go:464
↓ 4 callersFunctionitemList
(paths ...string)
internal/scan/batch_test.go:10
↓ 4 callersMethodmaybeRunDedup
maybeRunDedup, when the template has a DedupTask and the batch produced at least DedupMinComments comments, invokes the DEDUP_TASK LLM to merge near-d
internal/scan/agent.go:699
↓ 4 callersMethodmaybeRunProjectSummary
maybeRunProjectSummary runs the post-batch PROJECT_SUMMARY_TASK over the union of all collected comments. Best-effort: any error / empty input no-temp
internal/scan/agent.go:623
↓ 4 callersMethodmodelProviderName
()
cmd/opencodereview/provider_tui.go:394
↓ 4 callersFunctionnKey
()
cmd/opencodereview/provider_tui_test.go:1087
↓ 4 callersFunctionnewModelTUIConfig
(cfg modelTUIConfig)
cmd/opencodereview/provider_tui.go:2497
↓ 4 callersFunctionnormalizeLine
normalizeLine removes leading/trailing whitespace and strips any leading '+' or '-' diff marker (mirrors Java's processTargetLineCode).
internal/diff/resolver.go:232
↓ 4 callersFunctionoutputJSONWithWarnings
(comments []model.LlmComment, warnings []agent.AgentWarning, filesReviewed, inputTokens, outputTokens, totalT
cmd/opencodereview/output.go:267
↓ 4 callersFunctionoutputTextWithWarnings
(comments []model.LlmComment, warnings []agent.AgentWarning)
cmd/opencodereview/output.go:35
↓ 4 callersFunctionparseNameStatus
(output: string)
extensions/vscode/src/extension/services/gitMap.ts:149
↓ 4 callersFunctionparseNonNegInt
(val, defaultVal)
scripts/github-actions/post-review-comments.js:733
↓ 4 callersFunctionparseViewerFlags
(args []string)
cmd/opencodereview/viewer_cmd.go:14
↓ 4 callersFunctionpartitionMessages
partitionMessages divides messages into frozen, compress, and active zones. Frozen zone is always messages[0:2]. Active zone preserves the K most rece
internal/llmloop/compression.go:123
↓ 4 callersFunctionpeekSession
peekSession reads only the first and last record of a JSONL file.
internal/viewer/store.go:122
↓ 4 callersMethodpost
(msg: ConfigPanelHostToWebview)
extensions/vscode/src/extension/providers/ConfigPanelProvider.ts:58
↓ 4 callersFunctionreadAllPages
(tag, pageFn, log, maxPages = 50)
scripts/github-actions/post-review-comments.js:899
↓ 4 callersMethodrelease
()
internal/gitcmd/runner.go:41
↓ 4 callersFunctionrenderListName
(name string, isCursor bool)
cmd/opencodereview/provider_tui.go:1946
↓ 4 callersFunctionresolveBackgroundFilePath
(repoDir, path string)
cmd/opencodereview/background_file.go:22
↓ 4 callersFunctionresolveRepoDir
resolveRepoDir resolves the repo dir for `ocr rules check`. It delegates to resolveWorkingDir(requireGit=true) so it anchors at the git top-level just
cmd/opencodereview/review_cmd.go:197
↓ 4 callersMethodresolvedModel
resolvedModel returns the model to persist, falling back to the in-session pick for the provider being finalized when result.model is empty.
cmd/opencodereview/provider_tui.go:85
↓ 4 callersMethodrunGit
(ctx context.Context, args ...string)
internal/diff/git.go:340
↓ 4 callersFunctionrunLLMTest
()
cmd/opencodereview/llm_cmd.go:31
↓ 4 callersFunctionrunSessionList
(args []string)
cmd/opencodereview/session_cmd.go:33
↓ 4 callersFunctionrunSessionShow
(args []string)
cmd/opencodereview/session_cmd.go:75
↓ 4 callersMethodselectedModel
()
cmd/opencodereview/provider_tui.go:2883
↓ 4 callersMethodselectedModelFromState
()
cmd/opencodereview/provider_tui.go:1819
↓ 4 callersFunctionsetupFileFindRepo
(t *testing.T)
internal/tool/file_find_test.go:89
↓ 4 callersMethodsummaryEnabled
()
internal/scan/agent.go:83
↓ 4 callersFunctiontaskDoneResponse
()
internal/llmloop/loop_test.go:33
↓ 4 callersFunctionunquoteGitPath
(path: string)
extensions/vscode/src/extension/services/gitMap.ts:118
↓ 4 callersFunctionunsetCustomProvider
(configPath, name string)
cmd/opencodereview/config_cmd.go:116
↓ 4 callersFunctionunsetMCPServer
(configPath, name string)
cmd/opencodereview/config_cmd.go:139
↓ 4 callersFunctionuseSectionTitleStyle
()
pages/src/hooks/useResponsiveStyle.ts:12
↓ 4 callersFunctionuserAgent
(provider string)
internal/llm/client.go:26
↓ 4 callersFunctionvalidateTimeoutSec
validateTimeoutSec converts a config-file timeout (in seconds) to time.Duration. Returns 0 for zero input (use default). Rejects negative values and o
internal/llm/resolver.go:146
↓ 3 callersMethodCallTool
CallTool invokes a tool on the MCP server and returns the text result.
internal/mcp/client.go:67
↓ 3 callersMethodCompletionsWithCtx
CompletionsWithCtx sends a Responses API request and maps the result back to the shared ChatResponse shape.
internal/llm/responses_client.go:74
↓ 3 callersFunctionComputeLineDiff
ComputeLineDiff returns a line-level diff between oldLines and newLines. Uses Myers-style LCS to find common subsequences, then emits context/added/de
internal/suggestdiff/diff.go:24
↓ 3 callersFunctionContentLogging
ContentLogging returns true when content logging is enabled via OCR_CONTENT_LOGGING.
internal/telemetry/provider.go:75
↓ 3 callersMethodGet
Get returns the diff text for path.
internal/tool/file_read_diff.go:24
↓ 3 callersFunctionListSessions
ListSessions returns lightweight summaries for all sessions in a repo subdir.
internal/viewer/store.go:94
↓ 3 callersFunctionListSessions
ListSessions enumerates all persisted sessions for the given repository directory, sorted by StartTime descending (most recent first). Missing directo
internal/session/list.go:90
↓ 3 callersFunctionNewClient
NewClient starts an MCP server subprocess, initializes the connection, and caches the list of available tools. The context governs the initialization
internal/mcp/client.go:25
↓ 3 callersFunctionNewToolCallMessage
NewToolCallMessage creates an assistant message with text content and tool invocations.
internal/llm/client.go:67
↓ 3 callersFunctionOf
Of returns a checkpoint with data.
internal/tool/response_message.go:20
↓ 3 callersFunctionPrintToolCallStarted
PrintToolCallStarted prints a line when a tool begins execution. Args are summarized as key-value pairs (path, search terms, etc.). Example: [ocr] ▶
internal/telemetry/events.go:87
↓ 3 callersFunctionRecordLLMRequest
(ctx context.Context, model string, dur time.Duration, totalTokens int64, status string)
internal/telemetry/metrics.go:104
↓ 3 callersFunctionRecordToolCall
(ctx context.Context, name string, dur time.Duration, ok bool)
internal/telemetry/metrics.go:124
↓ 3 callersMethodRemoveByPathAndIndices
RemoveByPathAndIndices removes comments for a given path whose per-path index (0-based position among all comments with that path) is in the indices s
internal/tool/comment_collector.go:93
↓ 3 callersMethodResolve
Resolve returns the rule text for a given file path. Patterns with brace expansion like "*.{go,py}" are expanded into "*.go", "*.py". The first match
internal/config/rules/system_rules.go:127
↓ 3 callersFunctionResolveConfig
ResolveConfig builds the final Config by merging defaults, JSON config, and env vars. Precedence: defaults < config.json < environment variables.
internal/telemetry/config.go:110
↓ 3 callersFunctionSessionFilePath
SessionFilePath returns the JSONL path for a persisted session.
internal/session/resume.go:56
↓ 3 callersMethodSetDiffMap
SetDiffMap replaces the diff snapshot. Must be called before concurrent access begins.
internal/tool/file_read_diff.go:39
↓ 3 callersFunctionShutdownWithTimeout
ShutdownWithTimeout creates a timeout context and calls Shutdown.
internal/telemetry/shutdown.go:33
↓ 3 callersMethodSnapshot
Snapshot returns the current count of stored comments. Pair with Since / ReplaceSince to operate on the comments added between two points in time (e.g
internal/tool/comment_collector.go:53
↓ 3 callersMethodStringVarP
StringVarP registers --name with optional short form -s.
cmd/opencodereview/flags.go:26
↓ 3 callersMethodSubmitFor
SubmitFor is Submit plus registration under key, so AwaitKey can wait for exactly the units submitted under that key instead of the whole pool. Calle
internal/llmloop/pool.go:72
↓ 3 callersMethodTotalOutputTokens
TotalOutputTokens returns the accumulated completion tokens from all LLM calls.
internal/llmloop/loop.go:66
↓ 3 callersMethodTotalTokensUsed
TotalTokensUsed / TotalInputTokens / ... delegate to the underlying runner.
internal/scan/agent.go:180
↓ 3 callersFunctionTraceIDFromContext
TraceIDFromContext returns the hex-encoded trace ID of the span carried by ctx, or "" if ctx carries no valid span (e.g. telemetry is disabled).
internal/telemetry/span.go:45
↓ 3 callersMethodValidateOptions
ValidateOptions verifies that the requested review range matches the prior session.
internal/session/resume.go:174
↓ 3 callersFunctionagentTaskDoneResponse
()
internal/agent/agent_test.go:35
↓ 3 callersFunctionapplyProviderDeletions
(configPath string, cfg *Config, names []string)
cmd/opencodereview/provider_cmd.go:64
← previousnext →301–400 of 2,775, ranked by callers