@quantiya/codevibe-core 2.0.72 → 2.0.74

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.
@@ -15,9 +15,29 @@ declare function launcherCompatiblePath(env: NodeJS.ProcessEnv, commonPaths?: st
15
15
  */
16
16
  export declare function detectInstalledAgents(env?: NodeJS.ProcessEnv): DetectableAgent[];
17
17
  declare function isAgentInstalled(agent: DetectableAgent, env: NodeJS.ProcessEnv, commonPaths?: string[]): boolean;
18
+ declare function firstNonEmpty(...values: Array<string | undefined | null>): string | null;
19
+ export declare const DEFAULT_AGENT_MODELS: Record<DetectableAgent, string>;
20
+ export interface DetectAgentModelOptions {
21
+ /** If true, returns null when explicit CODEVIBE_<AGENT>_MODEL environment variable is not found. */
22
+ explicitOnly?: boolean;
23
+ }
24
+ /**
25
+ * Deterministically detect the active model for an agent by probing:
26
+ * 1. Explicit environment overrides (`CODEVIBE_<AGENT>_MODEL`). If `explicitOnly` is true, stops here.
27
+ * 2. Generic agent environment overrides (`<AGENT>_MODEL`).
28
+ * 3. Agent local config files (`${CODEX_HOME:-~/.codex}/config.toml`, `~/.claude.json`, `~/.gemini/settings.json`).
29
+ * 4. Platform default for the installed agent (`DEFAULT_AGENT_MODELS`).
30
+ */
31
+ export declare function detectAgentModel(agent: DetectableAgent, env?: NodeJS.ProcessEnv, homeDirOrOptions?: string | DetectAgentModelOptions, options?: DetectAgentModelOptions): string | null;
32
+ /**
33
+ * Returns a map of installed agents to their deterministically detected models.
34
+ */
35
+ export declare function detectInstalledAgentModels(env?: NodeJS.ProcessEnv, homeDir?: string, installedAgents?: DetectableAgent[], options?: DetectAgentModelOptions): Partial<Record<DetectableAgent, string>>;
18
36
  export declare const __testing: {
19
37
  isAgentInstalled: typeof isAgentInstalled;
20
38
  launcherCompatiblePath: typeof launcherCompatiblePath;
39
+ detectAgentModel: typeof detectAgentModel;
40
+ firstNonEmpty: typeof firstNonEmpty;
21
41
  };
22
42
  /**
23
43
  * Detect-and-push convenience for plugin daemon startup. All three
@@ -1,2 +1,2 @@
1
- export { detectInstalledAgents, pushDetectedAgents, type DetectableAgent, } from './detect-agents';
1
+ export { detectInstalledAgents, detectInstalledAgentModels, detectAgentModel, DEFAULT_AGENT_MODELS, pushDetectedAgents, type DetectableAgent, } from './detect-agents';
2
2
  export { V1_ORCHESTRATION_PROMPT_KIND, V1_ORCHESTRATION_OPTIONS, mapOptionNumberToUserDecisionKind, mapOptionToUserDecisionKind, type V1OrchestrationOption, type V1UserDecisionKind, } from './v1-options';
@@ -69,6 +69,7 @@ export interface UserDecisionRecord {
69
69
  isFinalApproval?: boolean;
70
70
  notes?: string;
71
71
  timestamp?: string;
72
+ serverRecordedAt?: string;
72
73
  gateId?: string;
73
74
  canonicalDecision?: string;
74
75
  decisionClaimId?: string;
@@ -235,6 +236,7 @@ export interface CompileAuditSummaryArgs {
235
236
  role: string;
236
237
  }>;
237
238
  workspaceApplicationStatus?: 'applied' | 'pending_merge_gate' | 'unobserved';
239
+ detectedAgentModels?: Partial<Record<string, string>> | Record<string, string>;
238
240
  }
239
241
  export declare function compileAuditSummary(args: CompileAuditSummaryArgs): TaskAuditSummaryModel;
240
242
  export declare function renderSummaryMarkdown(summaryModel: TaskAuditSummaryModel): string;
@@ -475,6 +475,8 @@ export declare function buildQuorumLoopExecutor(args: {
475
475
  emitter: (args: ShellEventEmit) => Promise<ShellEventEmitResult>;
476
476
  /** CP-1.f LOCK RP-6 — host-detected agents threaded into the loop. */
477
477
  detectedAgents?: string[];
478
+ detectedAgentModels?: Partial<Record<string, string>> | Record<string, string>;
479
+ configuredAgentModels?: Partial<Record<string, string>> | Record<string, string>;
478
480
  /** #585 auto-continuation (Max) — the resolved tier, threaded to the loop. */
479
481
  tier?: Tier;
480
482
  /**
@@ -509,6 +511,8 @@ export declare function buildTeamLocalExecutor(args: {
509
511
  initialScope: AuthorityScope;
510
512
  /** CP-1.f LOCK RP-6 — host-detected agents threaded into the loop. */
511
513
  detectedAgents?: string[];
514
+ detectedAgentModels?: Partial<Record<string, string>> | Record<string, string>;
515
+ configuredAgentModels?: Partial<Record<string, string>> | Record<string, string>;
512
516
  /** #585 auto-continuation (Max) — the resolved tier, threaded to the loop. */
513
517
  tier?: Tier;
514
518
  /**