@pratik7368patil/anchor-core 0.1.22 → 0.1.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -375,6 +375,8 @@ type OrgStatus = {
375
375
  org: string;
376
376
  root: string;
377
377
  databasePath: string;
378
+ statusReadError?: string;
379
+ activeRun?: OrgRunHeartbeatStatus;
378
380
  repoCount: number;
379
381
  enabledRepoCount: number;
380
382
  clonedRepoCount: number;
@@ -402,6 +404,99 @@ type OrgStatus = {
402
404
  lastError?: string;
403
405
  }>;
404
406
  };
407
+ type OrgRunHeartbeat = {
408
+ pid: number;
409
+ command: string;
410
+ org: string;
411
+ repo?: string;
412
+ repoIndex?: number;
413
+ repoTotal?: number;
414
+ phase: string;
415
+ startedAt: string;
416
+ updatedAt: string;
417
+ };
418
+ type OrgRunHeartbeatStatus = OrgRunHeartbeat & {
419
+ pidRunning: boolean;
420
+ stale: boolean;
421
+ elapsedSeconds: number;
422
+ lastUpdateAgeSeconds: number;
423
+ };
424
+ type OrgLifecycleProgress = {
425
+ stage: "org_sync_started";
426
+ org: string;
427
+ command: string;
428
+ totalRepos: number;
429
+ } | {
430
+ stage: "org_repo_started";
431
+ org: string;
432
+ command: string;
433
+ repo: string;
434
+ current: number;
435
+ total: number;
436
+ } | {
437
+ stage: "org_repo_phase";
438
+ org: string;
439
+ command: string;
440
+ repo: string;
441
+ current: number;
442
+ total: number;
443
+ phase: string;
444
+ detail?: string;
445
+ } | {
446
+ stage: "org_repo_skipped_history";
447
+ org: string;
448
+ command: string;
449
+ repo: string;
450
+ current: number;
451
+ total: number;
452
+ reason: string;
453
+ } | {
454
+ stage: "org_repo_skipped_code";
455
+ org: string;
456
+ command: string;
457
+ repo: string;
458
+ current: number;
459
+ total: number;
460
+ reason: string;
461
+ } | {
462
+ stage: "org_repo_finalizing";
463
+ org: string;
464
+ command: string;
465
+ repo: string;
466
+ current: number;
467
+ total: number;
468
+ } | {
469
+ stage: "org_repo_completed";
470
+ org: string;
471
+ command: string;
472
+ repo: string;
473
+ current: number;
474
+ total: number;
475
+ skippedHistory: boolean;
476
+ skippedCode: boolean;
477
+ prsIndexed: number;
478
+ codeFilesIndexed: number;
479
+ durationMs: number;
480
+ error?: string;
481
+ } | {
482
+ stage: "org_graph_skipped";
483
+ org: string;
484
+ command: string;
485
+ reason: string;
486
+ } | {
487
+ stage: "org_sync_completed";
488
+ org: string;
489
+ command: string;
490
+ totalRepos: number;
491
+ succeededRepos: number;
492
+ failedRepos: number;
493
+ durationMs: number;
494
+ } | {
495
+ stage: "org_sync_failed";
496
+ org: string;
497
+ command: string;
498
+ error: string;
499
+ };
405
500
  type OrgGraphProgress = {
406
501
  stage: "loading_package_manifests";
407
502
  org: string;
@@ -552,6 +647,13 @@ type FetchPullRequestsProgress = {
552
647
  matchedMergedPullRequests: number;
553
648
  pageSize: number;
554
649
  resetAt?: string | null;
650
+ } | {
651
+ stage: "github_graphql_retry";
652
+ repo: string;
653
+ attempt: number;
654
+ maxAttempts: number;
655
+ waitMs: number;
656
+ reason: string;
555
657
  } | {
556
658
  stage: "github_rate_limited";
557
659
  repo: string;
@@ -560,6 +662,10 @@ type FetchPullRequestsProgress = {
560
662
  reason: string;
561
663
  request: string;
562
664
  attempt: number;
665
+ } | {
666
+ stage: "skipped_pull_request_fetch";
667
+ repo: string;
668
+ reason: string;
563
669
  };
564
670
  type IndexPullRequestsProgress = {
565
671
  stage: "indexing_pull_request";
@@ -574,6 +680,7 @@ type IndexPullRequestsProgress = {
574
680
  total: number;
575
681
  prNumber: number;
576
682
  wisdomUnitsCreated: number;
683
+ regressionEventsCreated: number;
577
684
  };
578
685
  type CodeIndexProgress = {
579
686
  stage: "discovering_code_files";
@@ -602,6 +709,17 @@ type CodeIndexProgress = {
602
709
  components: number;
603
710
  patterns: number;
604
711
  imports: number;
712
+ } | {
713
+ stage: "completed_code_index";
714
+ repo: string;
715
+ files: number;
716
+ chunks: number;
717
+ skippedFiles: number;
718
+ testFiles: number;
719
+ testLinks: number;
720
+ architectureComponents: number;
721
+ architecturePatterns: number;
722
+ architectureImports: number;
605
723
  };
606
724
  type IndexSummary = {
607
725
  indexedPrs: number;
@@ -841,6 +959,7 @@ declare function redactedHistoricalText(text: string): string;
841
959
  type AnchorDatabase = Database.Database;
842
960
  declare function defaultDatabasePath(cwd: string): string;
843
961
  declare function openAnchorDatabase(cwd: string, databasePath?: string): AnchorDatabase;
962
+ declare function openAnchorDatabaseReadOnly(databasePath: string): AnchorDatabase;
844
963
  declare function initializeSchema(db: AnchorDatabase): void;
845
964
  declare function checkSchema(db: AnchorDatabase): boolean;
846
965
  declare function ensureRepository(db: AnchorDatabase, fullName: string): number;
@@ -1220,6 +1339,12 @@ type GitHubGraphQLResponse<T> = {
1220
1339
  data: T;
1221
1340
  headers: Record<string, string | number | undefined>;
1222
1341
  };
1342
+ type GitHubGraphQLTransientRetry = {
1343
+ attempt: number;
1344
+ maxAttempts: number;
1345
+ waitMs: number;
1346
+ reason: string;
1347
+ };
1223
1348
  declare class GitHubGraphQLError extends Error {
1224
1349
  readonly status: number;
1225
1350
  readonly response: {
@@ -1239,6 +1364,8 @@ declare function createGitHubGraphQLRequester(options: {
1239
1364
  controller: GitHubRateLimitController;
1240
1365
  requestName: string;
1241
1366
  maxRetries?: number;
1367
+ maxTransientRetries?: number;
1368
+ onTransientRetry?: (retry: GitHubGraphQLTransientRetry) => void;
1242
1369
  }) => Promise<GitHubGraphQLResponse<T>>;
1243
1370
 
1244
1371
  type FetchPullRequestsOptions = {
@@ -1303,7 +1430,18 @@ declare function removeOrgRepoConfig(org: string, repoFullName: string, baseDir?
1303
1430
  declare function listOrgNames(baseDir?: string): string[];
1304
1431
  declare function resolveOrgForTool(org?: string, baseDir?: string): string;
1305
1432
 
1433
+ type OrgGraphState = {
1434
+ org: string;
1435
+ lastBuiltAt?: string;
1436
+ lastStatus?: "success" | "failed" | "skipped" | "unknown";
1437
+ lastDurationMs?: number;
1438
+ edgeCount?: number;
1439
+ apiContractCount?: number;
1440
+ apiConsumerCount?: number;
1441
+ lastError?: string;
1442
+ };
1306
1443
  declare function openOrgDatabase(org: string, baseDir?: string): AnchorDatabase;
1444
+ declare function openOrgDatabaseReadOnly(org: string, baseDir?: string): AnchorDatabase;
1307
1445
  declare function syncOrgConfigToDatabase(db: AnchorDatabase, config: AnchorOrgConfig, baseDir?: string): void;
1308
1446
  declare function updateOrgRepoState(db: AnchorDatabase, state: OrgRepoCloneState): void;
1309
1447
  declare function getOrgRepoState(db: AnchorDatabase, org: string, repo: string): OrgRepoCloneState | undefined;
@@ -1328,12 +1466,22 @@ declare function recordOrgGraphState(db: AnchorDatabase, input: {
1328
1466
  apiConsumerCount?: number;
1329
1467
  error?: string;
1330
1468
  }): void;
1469
+ declare function getOrgGraphState(db: AnchorDatabase, org: string): OrgGraphState | undefined;
1331
1470
  declare function getOrgGraphCounts(db: AnchorDatabase, org: string): {
1332
1471
  edges: number;
1333
1472
  apiContracts: number;
1334
1473
  apiConsumers: number;
1335
1474
  };
1336
- declare function getOrgStatus(db: AnchorDatabase, config: AnchorOrgConfig, baseDir?: string): OrgStatus;
1475
+ declare function getOrgStatus(db: AnchorDatabase, config: AnchorOrgConfig, baseDir?: string, options?: {
1476
+ syncConfig?: boolean;
1477
+ activeRun?: OrgRunHeartbeatStatus;
1478
+ statusReadError?: string;
1479
+ }): OrgStatus;
1480
+
1481
+ declare function orgHeartbeatPath(org: string, baseDir?: string): string;
1482
+ declare function writeOrgHeartbeat(heartbeat: OrgRunHeartbeat, baseDir?: string): void;
1483
+ declare function clearOrgHeartbeat(org: string, baseDir?: string): void;
1484
+ declare function readOrgHeartbeat(org: string, baseDir?: string): OrgRunHeartbeatStatus | undefined;
1337
1485
 
1338
1486
  type GitCommandRunner = (command: string, args: string[], options: {
1339
1487
  cwd?: string;
@@ -1409,6 +1557,8 @@ declare function rebuildOrgGraph(db: AnchorDatabase, config: AnchorOrgConfig, ba
1409
1557
  type OrgRepoIndexResult = {
1410
1558
  repo: string;
1411
1559
  skippedCode: boolean;
1560
+ skippedHistory?: boolean;
1561
+ historySkippedReason?: string;
1412
1562
  currentCommit?: string;
1413
1563
  history?: IndexSummary;
1414
1564
  code?: CodeIndexSummary;
@@ -1437,10 +1587,12 @@ type OrgIndexOptions = {
1437
1587
  command?: "org index" | "org sync";
1438
1588
  baseDir?: string;
1439
1589
  runner?: GitCommandRunner;
1590
+ fetchPullRequests?: typeof fetchMergedPullRequests;
1440
1591
  onFetchProgress?: (progress: FetchPullRequestsProgress) => void;
1441
1592
  onPrIndexProgress?: (progress: IndexPullRequestsProgress) => void;
1442
1593
  onCodeProgress?: (progress: CodeIndexProgress) => void;
1443
1594
  onGraphProgress?: (progress: OrgGraphProgress) => void;
1595
+ onLifecycleProgress?: (progress: OrgLifecycleProgress) => void;
1444
1596
  };
1445
1597
  declare function indexOrgRepos(db: AnchorDatabase, config: AnchorOrgConfig, options?: OrgIndexOptions): Promise<OrgIndexResult>;
1446
1598
 
@@ -1503,4 +1655,4 @@ declare function getAnchorIndexHealth(cwd: string): AnchorIndexHealth & {
1503
1655
  indexStatus: IndexStatus;
1504
1656
  };
1505
1657
 
1506
- export { ANCHOR_CURSOR_RULE, ANCHOR_EVALS_FILE, ANCHOR_PLAYBOOKS_FILE, type AnchorCiInput, type AnchorContextInput, type AnchorDatabase, type AnchorExplainFileInput, type AnchorIndexHealth, type AnchorOrgConfig, type AnchorOrgRepoConfig, type AnchorReviewDiffInput, type ArchitectureArea, type ArchitectureCheckInput, type ArchitectureComponent, type ArchitectureContextInput, type ArchitectureIndexData, type ArchitectureMap, type ArchitectureMapEdge, type ArchitectureMapFormat, type ArchitectureMapInput, type ArchitectureMapNode, type ArchitecturePattern, type ArchitectureQueryInput, type ChunkableCodeFile, type CodeChunk, type CodeFileDiscoveryResult, type CodeFileRecord, type CodeImport, type CodeIndexProgress, type CodeIndexSummary, type ConfidenceLevel, type CoverageGrade, type CoverageInput, type CoverageReport, type CurrentCodeSnapshot, type CursorMcpConfig, DEFAULT_MAX_CODE_FILE_BYTES, DEMO_CODE_FILES, DEMO_PULL_REQUESTS, DEMO_REPO, type DiscoveredCodeFile, type DoctorCheck, type DoctorOptions, type DoctorReport, type EvidenceRef, type FeedbackEvent, type FeedbackRating, type FetchMergedPullRequestsGraphQLOptions, type FetchPullRequestsOptions, type FetchPullRequestsProgress, type FormattedResult, type FreshnessResult, type FreshnessStatus, type GitCommandRunner, type GitHubFetchBackend, GitHubGraphQLError, type GitHubGraphQLFetch, type GitHubGraphQLFetchCheckpoint, type GitHubGraphQLRateLimitState, type GitHubGraphQLResponse, type GitHubRateLimitController, type GitHubRateLimitErrorLike, type GitHubRateLimitProgress, type GitHubRepo, type GitHubTokenResolution, type GitHubTokenResolverOptions, type GitHubTokenSource, type IndexPullRequestsProgress, type IndexRunRecord, type IndexStatus, type IndexSummary, type LocalEmbeddingProvider, type OnboardingInput, type OnboardingPack, type OrgAnomaly, type OrgAnomalyCategory, type OrgApiConsumer, type OrgCloneProgress, type OrgCloneResult, type OrgCrossRepoEdge, type OrgCrossRepoRelationship, type OrgFormattedResult, type OrgGraphProgress, type OrgGraphResult, type OrgImpactResult, type OrgIndexOptions, type OrgIndexResult, type OrgRepoCloneState, type OrgRepoGroup, type OrgRepoIndexResult, type OrgStatus, type Playbook, type PullRequestComment, type PullRequestCommit, type PullRequestFile, type PullRequestPerson, type PullRequestRecord, type RankedArchitecturePattern, type RankedCodeChunk, type RankedRegressionEvent, type RankedTeamRule, type RankedTestFile, type RankedWisdomUnit, type RebuildOrgGraphOptions, type RegressionEvent, type ReliabilityGate, type ReliabilityGateRejection, type ReliabilityGateResult, type ReliabilityGateStatus, type RetrievalEvalCase, type RetrievalEvalResult, type RetrievalEvalRunResult, type RulesAddInput, type RulesAddResult, type RulesEvidenceCheckResult, type RulesInitResult, type RulesSuggestOptions, SCHEMA_SQL, type SearchHistoryInput, type SemanticStatus, type SourceType, type SuggestedPrompt, TEAM_RULES_FILE, type TaskPlan, type TeamRule, type TeamRuleSuggestion, type TeamRulesValidationResult, type TestCommand, type TestFileRecord, type TestLink, type WatchRefreshInput, type WisdomCategory, type WisdomUnit, addOrgRepoConfig, addRetrievalEval, addTeamRule, anchorMcpEntry, architectureFilesFromDiff, buildAnchorContextResult, buildArchitectureIndex, buildArchitectureMap, buildFtsQuery, buildOnboardingPack, buildOrgContextResult, buildQueryTerms, calculateCoverage, canonicalizeText, categorizeWisdom, checkArchitecture, checkOrgImpact, checkSchema, checkTeamRuleEvidence, chunkCodeFile, chunkHistoricalText, claimKeyFor, clampMaxResults, classifyArchitectureArea, clearGraphQLFetchCheckpoint, clipSentence, cloneOrPullOrgRepo, cloneOrgRepos, confidenceAtLeast, confidenceLevelFor, confidenceRank, confidenceReasonsFor, countValidTeamRules, createGitHubClient, createGitHubGraphQLRequester, defaultDatabasePath, defaultGitCommandRunner, defaultOrgBaseDir, defaultOrgCloneUrl, detectGitHubRepo, detectGitRoot, detectTestCommands, detectTestCommandsForFile, discoverCodeFiles, emptyCodeIndexSummary, ensureAnchorGitExclude, ensureCursorConfig, ensureCursorRule, ensureRepository, ensureTeamRulesFile, evaluateFreshness, evaluateIndexHealth, evaluateReliabilityGate, evidenceForWisdom, explainFile, extractCodeImports, extractCodeSymbols, extractRegressionEvents, extractSymbols, extractWisdomUnits, feedbackAdjustedScore, fetchMergedPullRequests, fetchMergedPullRequestsWithGraphQL, fetchPullRequestDetails, filesFromDiff, findOrgApiConsumers, formatAnchorContext, formatIndexStatus, formatSearchHistory, getAnchorIndexHealth, getArchitectureContext, getArchitectureMapContext, getGitHubRateLimitDelayMs, getGraphQLFetchCheckpoint, getIndexStatus, getLastSyncTime, getOrgArchitectureMap, getOrgGraphCounts, getOrgRepoState, getOrgStatus, getPlaybook, getSemanticStatus, getSuggestedPromptTexts, getSuggestedPrompts, getWisdomCategoryCounts, githubAuthFixMessage, graphQLFetchCheckpointScope, hasHighSignalLanguage, indexCodebase, indexOrgRepos, indexPullRequests, inferTestAwareness, initOrgConfig, initPlaybooks, initRetrievalEvals, initializeSchema, isGitHubGraphQLResourceLimitError, isGitHubRateLimitError, isHardExcludedCodePath, isTestFilePath, listFeedbackEvents, listOrgNames, listPlaybooks, loadCurrentCodeSnapshot, loadOrgConfig, loadTeamRulesFile, maybeLoadOrgConfig, mergeAnchorMcpConfig, normalizePullRequest, openAnchorDatabase, openOrgDatabase, orgCloneStateFromResult, orgConfigPath, orgDatabasePath, orgRepoLocalPath, orgReposRoot, orgRoot, paginateWithGitHubRateLimit, parseGitHubRemote, planTask, plannedOrgCloneCommands, rankArchitecturePatterns, rankCodeChunks, rankRegressionEvents, rankRelevantTests, rankTeamRules, rankWisdomUnits, rebuildOrgGraph, recordFeedback, recordIndexRun, recordOrgGraphState, recordOrgIndexRun, redactSecrets, redactedHistoricalText, refreshTestCommands, refreshWatchIndex, removeOrgRepoConfig, replaceCodeIndex, repoAliasFromFullName, requestWithGitHubRateLimit, resolveGitHubToken, resolveOrgForTool, resolvePullRequestDetailConcurrency, resolvePullRequestFetchLimit, reviewDiff, runAnchorCi, runDoctor, runRetrievalEvals, sanitizeHistoricalText, saveGraphQLFetchCheckpoint, saveOrgConfig, shouldFallbackToRestAfterGraphQLError, shouldSyncSince, sourceTypeLabel, stripPromptInjection, suggestPlaybooks, suggestTeamRules, syncOrgConfigToDatabase, syncPlaybooksToDatabase, tokenizeSearchText, truncateText, uniqueStrings, updateGitHubGraphQLRateLimitState, updateOrgRepoState, updateSyncState, upsertPullRequest, validateOrgName, validateOrgRepoFullName, validateOrgRepoGroup, validateTeamRulesFile, watchCodebase };
1658
+ export { ANCHOR_CURSOR_RULE, ANCHOR_EVALS_FILE, ANCHOR_PLAYBOOKS_FILE, type AnchorCiInput, type AnchorContextInput, type AnchorDatabase, type AnchorExplainFileInput, type AnchorIndexHealth, type AnchorOrgConfig, type AnchorOrgRepoConfig, type AnchorReviewDiffInput, type ArchitectureArea, type ArchitectureCheckInput, type ArchitectureComponent, type ArchitectureContextInput, type ArchitectureIndexData, type ArchitectureMap, type ArchitectureMapEdge, type ArchitectureMapFormat, type ArchitectureMapInput, type ArchitectureMapNode, type ArchitecturePattern, type ArchitectureQueryInput, type ChunkableCodeFile, type CodeChunk, type CodeFileDiscoveryResult, type CodeFileRecord, type CodeImport, type CodeIndexProgress, type CodeIndexSummary, type ConfidenceLevel, type CoverageGrade, type CoverageInput, type CoverageReport, type CurrentCodeSnapshot, type CursorMcpConfig, DEFAULT_MAX_CODE_FILE_BYTES, DEMO_CODE_FILES, DEMO_PULL_REQUESTS, DEMO_REPO, type DiscoveredCodeFile, type DoctorCheck, type DoctorOptions, type DoctorReport, type EvidenceRef, type FeedbackEvent, type FeedbackRating, type FetchMergedPullRequestsGraphQLOptions, type FetchPullRequestsOptions, type FetchPullRequestsProgress, type FormattedResult, type FreshnessResult, type FreshnessStatus, type GitCommandRunner, type GitHubFetchBackend, GitHubGraphQLError, type GitHubGraphQLFetch, type GitHubGraphQLFetchCheckpoint, type GitHubGraphQLRateLimitState, type GitHubGraphQLResponse, type GitHubGraphQLTransientRetry, type GitHubRateLimitController, type GitHubRateLimitErrorLike, type GitHubRateLimitProgress, type GitHubRepo, type GitHubTokenResolution, type GitHubTokenResolverOptions, type GitHubTokenSource, type IndexPullRequestsProgress, type IndexRunRecord, type IndexStatus, type IndexSummary, type LocalEmbeddingProvider, type OnboardingInput, type OnboardingPack, type OrgAnomaly, type OrgAnomalyCategory, type OrgApiConsumer, type OrgCloneProgress, type OrgCloneResult, type OrgCrossRepoEdge, type OrgCrossRepoRelationship, type OrgFormattedResult, type OrgGraphProgress, type OrgGraphResult, type OrgGraphState, type OrgImpactResult, type OrgIndexOptions, type OrgIndexResult, type OrgLifecycleProgress, type OrgRepoCloneState, type OrgRepoGroup, type OrgRepoIndexResult, type OrgRunHeartbeat, type OrgRunHeartbeatStatus, type OrgStatus, type Playbook, type PullRequestComment, type PullRequestCommit, type PullRequestFile, type PullRequestPerson, type PullRequestRecord, type RankedArchitecturePattern, type RankedCodeChunk, type RankedRegressionEvent, type RankedTeamRule, type RankedTestFile, type RankedWisdomUnit, type RebuildOrgGraphOptions, type RegressionEvent, type ReliabilityGate, type ReliabilityGateRejection, type ReliabilityGateResult, type ReliabilityGateStatus, type RetrievalEvalCase, type RetrievalEvalResult, type RetrievalEvalRunResult, type RulesAddInput, type RulesAddResult, type RulesEvidenceCheckResult, type RulesInitResult, type RulesSuggestOptions, SCHEMA_SQL, type SearchHistoryInput, type SemanticStatus, type SourceType, type SuggestedPrompt, TEAM_RULES_FILE, type TaskPlan, type TeamRule, type TeamRuleSuggestion, type TeamRulesValidationResult, type TestCommand, type TestFileRecord, type TestLink, type WatchRefreshInput, type WisdomCategory, type WisdomUnit, addOrgRepoConfig, addRetrievalEval, addTeamRule, anchorMcpEntry, architectureFilesFromDiff, buildAnchorContextResult, buildArchitectureIndex, buildArchitectureMap, buildFtsQuery, buildOnboardingPack, buildOrgContextResult, buildQueryTerms, calculateCoverage, canonicalizeText, categorizeWisdom, checkArchitecture, checkOrgImpact, checkSchema, checkTeamRuleEvidence, chunkCodeFile, chunkHistoricalText, claimKeyFor, clampMaxResults, classifyArchitectureArea, clearGraphQLFetchCheckpoint, clearOrgHeartbeat, clipSentence, cloneOrPullOrgRepo, cloneOrgRepos, confidenceAtLeast, confidenceLevelFor, confidenceRank, confidenceReasonsFor, countValidTeamRules, createGitHubClient, createGitHubGraphQLRequester, defaultDatabasePath, defaultGitCommandRunner, defaultOrgBaseDir, defaultOrgCloneUrl, detectGitHubRepo, detectGitRoot, detectTestCommands, detectTestCommandsForFile, discoverCodeFiles, emptyCodeIndexSummary, ensureAnchorGitExclude, ensureCursorConfig, ensureCursorRule, ensureRepository, ensureTeamRulesFile, evaluateFreshness, evaluateIndexHealth, evaluateReliabilityGate, evidenceForWisdom, explainFile, extractCodeImports, extractCodeSymbols, extractRegressionEvents, extractSymbols, extractWisdomUnits, feedbackAdjustedScore, fetchMergedPullRequests, fetchMergedPullRequestsWithGraphQL, fetchPullRequestDetails, filesFromDiff, findOrgApiConsumers, formatAnchorContext, formatIndexStatus, formatSearchHistory, getAnchorIndexHealth, getArchitectureContext, getArchitectureMapContext, getGitHubRateLimitDelayMs, getGraphQLFetchCheckpoint, getIndexStatus, getLastSyncTime, getOrgArchitectureMap, getOrgGraphCounts, getOrgGraphState, getOrgRepoState, getOrgStatus, getPlaybook, getSemanticStatus, getSuggestedPromptTexts, getSuggestedPrompts, getWisdomCategoryCounts, githubAuthFixMessage, graphQLFetchCheckpointScope, hasHighSignalLanguage, indexCodebase, indexOrgRepos, indexPullRequests, inferTestAwareness, initOrgConfig, initPlaybooks, initRetrievalEvals, initializeSchema, isGitHubGraphQLResourceLimitError, isGitHubRateLimitError, isHardExcludedCodePath, isTestFilePath, listFeedbackEvents, listOrgNames, listPlaybooks, loadCurrentCodeSnapshot, loadOrgConfig, loadTeamRulesFile, maybeLoadOrgConfig, mergeAnchorMcpConfig, normalizePullRequest, openAnchorDatabase, openAnchorDatabaseReadOnly, openOrgDatabase, openOrgDatabaseReadOnly, orgCloneStateFromResult, orgConfigPath, orgDatabasePath, orgHeartbeatPath, orgRepoLocalPath, orgReposRoot, orgRoot, paginateWithGitHubRateLimit, parseGitHubRemote, planTask, plannedOrgCloneCommands, rankArchitecturePatterns, rankCodeChunks, rankRegressionEvents, rankRelevantTests, rankTeamRules, rankWisdomUnits, readOrgHeartbeat, rebuildOrgGraph, recordFeedback, recordIndexRun, recordOrgGraphState, recordOrgIndexRun, redactSecrets, redactedHistoricalText, refreshTestCommands, refreshWatchIndex, removeOrgRepoConfig, replaceCodeIndex, repoAliasFromFullName, requestWithGitHubRateLimit, resolveGitHubToken, resolveOrgForTool, resolvePullRequestDetailConcurrency, resolvePullRequestFetchLimit, reviewDiff, runAnchorCi, runDoctor, runRetrievalEvals, sanitizeHistoricalText, saveGraphQLFetchCheckpoint, saveOrgConfig, shouldFallbackToRestAfterGraphQLError, shouldSyncSince, sourceTypeLabel, stripPromptInjection, suggestPlaybooks, suggestTeamRules, syncOrgConfigToDatabase, syncPlaybooksToDatabase, tokenizeSearchText, truncateText, uniqueStrings, updateGitHubGraphQLRateLimitState, updateOrgRepoState, updateSyncState, upsertPullRequest, validateOrgName, validateOrgRepoFullName, validateOrgRepoGroup, validateTeamRulesFile, watchCodebase, writeOrgHeartbeat };