snipara-companion 3.6.23 → 3.6.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/CHANGELOG.md CHANGED
@@ -4,6 +4,23 @@ Release notes for `snipara-companion`, newest first.
4
4
 
5
5
  ## Unreleased
6
6
 
7
+ ## New In 3.6.24 - 2026-09-21
8
+
9
+ - Makes `workflow run` use AUTO mode by default and adds French intent signals
10
+ for LITE, STANDARD, FULL, and ORCHESTRATED routing.
11
+ - Reports an automatic setup card showing when Companion, hosted memory,
12
+ Orchestrator, and policy-gated workers are selected.
13
+ - Keeps standalone `snipara-memory` opt-in and worker execution policy-gated.
14
+
15
+ ## New In 3.6.23 - 2026-09-14
16
+
17
+ - Adds opt-in strict closeout for `workflow task-commit` and
18
+ `workflow phase-commit`, requiring passed verification evidence before a
19
+ task commit and requiring all declared phase tasks to be completed or
20
+ skipped before hosted workflow writes.
21
+ - Keeps the default workflow behavior backward-compatible while making strict
22
+ mode suitable for release, security, and multi-agent dogfooding.
23
+
7
24
  ## New In 3.6.22 - 2026-09-12
8
25
 
9
26
  - Saves explicit session summaries and file checkpoints to the hosted journal,
package/README.md CHANGED
@@ -131,13 +131,13 @@ These commands are useful without hosted Snipara:
131
131
 
132
132
  Use the exact CLI value after `workflow run --mode`:
133
133
 
134
- | CLI value | Guide label | Meaning |
135
- | ------------- | ------------------- | --------------------------------------------------------------------- |
136
- | `lite` | LITE | Small, known-scope work with no mandatory hosted context call |
137
- | `standard` | STANDARD | Normal work with context and code-graph follow-up when needed |
138
- | `auto` | AUTO | Routes by task intent to `lite`, `standard`, `full`, or `orchestrate` |
139
- | `full` | FULL | Managed, phased work with durable context and plan support |
140
- | `orchestrate` | FULL + ORCHESTRATED | Explicit deeper orchestration for multi-agent or proof-gate work |
134
+ | CLI value | Guide label | Meaning |
135
+ | ------------- | ------------------- | ----------------------------------------------------------------------------------- |
136
+ | `lite` | LITE | Small, known-scope work with no mandatory hosted context call |
137
+ | `standard` | STANDARD | Normal work with context and code-graph follow-up when needed |
138
+ | `auto` | AUTO | Default mode; routes by task intent to `lite`, `standard`, `full`, or `orchestrate` |
139
+ | `full` | FULL | Managed, phased work with durable context and plan support |
140
+ | `orchestrate` | FULL + ORCHESTRATED | Explicit deeper orchestration for multi-agent or proof-gate work |
141
141
 
142
142
  The root `run` command is the Project Intelligence judgment/release flow.
143
143
  `workflow run` is the workflow-mode runner. They share a verb but are not
@@ -510,8 +510,11 @@ and file evidence when the Companion hook is installed. `workflow session` deriv
510
510
  Session Snapshot V0 includes latest activity, risk reasons, touched files, a
511
511
  next action, and advisory Intent Detection V0. Intent Detection V0 reports the
512
512
  inferred intent, confidence, reason-code signals, local evidence counts, and a
513
- suggested workflow mode. `workflow run --mode auto` uses that same Control Plane
514
- principle to choose lite, standard, full, or orchestrate. Lite runs with zero
513
+ suggested workflow mode. `workflow run` uses AUTO by default and that same
514
+ Control Plane principle to choose lite, standard, full, or orchestrate. It
515
+ reports an automatic setup card for Companion, hosted memory, Orchestrator,
516
+ and policy-gated workers. Standalone `snipara-memory` remains an explicit
517
+ application choice. Lite runs with zero
515
518
  mandatory hosted context calls; recall/context/code-impact are on-demand
516
519
  escalations, not an entry toll.
517
520
  `workflow timeline --export md` prints a compact redacted Markdown timeline for
package/dist/index.d.ts CHANGED
@@ -4176,6 +4176,20 @@ declare function formatFinalCommitReport(report: FinalCommitReportV1): string;
4176
4176
 
4177
4177
  type SyncDocumentKind = "DOC" | "BINARY";
4178
4178
  type WorkflowMode = "lite" | "standard" | "auto" | "full" | "orchestrate";
4179
+ type AutomaticMemorySetup = "none" | "hosted";
4180
+ type AutomaticOrchestratorSetup = "none" | "available" | "required";
4181
+ type AutomaticWorkerSetup = "none" | "policy_gated";
4182
+ interface AutomaticSetupSelection {
4183
+ requestedMode: WorkflowMode;
4184
+ effectiveMode: Exclude<WorkflowMode, "auto">;
4185
+ companion: "active";
4186
+ memory: AutomaticMemorySetup;
4187
+ orchestrator: AutomaticOrchestratorSetup;
4188
+ workers: AutomaticWorkerSetup;
4189
+ standaloneMemory: "not_selected";
4190
+ tokenStrategy: "minimal" | "budgeted";
4191
+ reasons: string[];
4192
+ }
4179
4193
  type OnboardFolderMode = "auto" | "business_context" | "code_project" | "mixed";
4180
4194
  type DetectedOnboardFolderMode = "business_context" | "code_project" | "mixed" | "unknown";
4181
4195
  type ManagedWorkflowStatus = "active" | "completed" | "blocked";
@@ -4915,6 +4929,15 @@ declare function buildWorkflowPhaseCommitSummary(args: {
4915
4929
  summary: string;
4916
4930
  }): string;
4917
4931
  declare function resolveAutoWorkflowMode(query: string): Exclude<WorkflowMode, "auto">;
4932
+ /**
4933
+ * Describe the smallest effective Snipara setup selected for a task.
4934
+ * This is deliberately a decision card: it never enables standalone memory
4935
+ * or executes a worker by itself. Worker execution remains policy-gated and
4936
+ * requires an explicit orchestrator path or project policy.
4937
+ */
4938
+ declare function resolveAutomaticSetup(query: string, requestedMode: WorkflowMode, options?: {
4939
+ hostedConfigured?: boolean;
4940
+ }): AutomaticSetupSelection;
4918
4941
  /**
4919
4942
  * Compute the impact gate for committed-but-unpushed workflow phases.
4920
4943
  *
@@ -5587,4 +5610,4 @@ declare function installAutomationBundle(args: {
5587
5610
  }): Promise<AutomationInstallResult>;
5588
5611
  declare function getAutomationStatus(projectDir?: string): AutomationStatusResult;
5589
5612
 
5590
- export { AGENT_CONTEXT_EVIDENCE_DEFAULT_LEDGER, AUTOMATION_MANIFEST_RELATIVE_PATH, AutomationInstallConflictError, AutomationUnsupportedHookBundleError, CODING_INTELLIGENCE_LEDGER_VERSION, COLLABORATION_STATE_RELATIVE_PATH, DEFAULT_DOCS_BOOTSTRAP_OUTPUT, DOCS_BOOTSTRAP_VERSION, ENGINEERING_LEAD_EXECUTION_RECEIPT_STAGES, ENGINEERING_LEAD_EXECUTION_RECEIPT_STATUSES, ENGINEERING_LEAD_POSTURES, ENGINEERING_LEAD_PROOF_VERIFICATION_SOURCES, ENGINEERING_LEAD_PROOF_VERIFICATION_STATUSES, ENGINEERING_LEAD_ROUTING_MODES, ENGINEERING_LEAD_STATUSES, ENGINEERING_LEAD_SUPERVISION_STATUSES, ENGINEERING_LEAD_WORKER_ROLES, ENGINEERING_LEAD_WORK_PACKAGE_STATUSES, FEATURE_DEFAULT_OUTPUT_DIR, FEATURE_WORK_ITEM_VERSION, FINAL_COMMIT_REPORT_RELATIVE_PATH, FINAL_COMMIT_REPORT_VERSION, type GeneratedWorkflowTaskDocument, MEMORY_GUARD_CONTEXT_TIMEOUT_MS, MEMORY_GUARD_RECALL_TIMEOUT_MS, type ManagedWorkflowTask, type ManagedWorkflowTaskContextEnvelope, type ManagedWorkflowTaskStatus, ORCHESTRATOR_HANDOFF_RELATIVE_PATH, POLICY_LEDGER_SYNC_REPORT_VERSION, PRODUCER_LOOP_ARTIFACT_VERSION, PRODUCER_LOOP_RELATIVE_DIR, PRODUCER_LOOP_REPORT_VERSION, TEAM_SYNC_STATE_RELATIVE_PATH, WHY_OUTCOME_CAPTURE_VERSION, WORKFLOW_PLANS_RELATIVE_DIR, WORKFLOW_STATE_RELATIVE_PATH, addLocalWorker, agentContextEvidenceCollectCommand, agentContextEvidenceRecordCommand, agentContextEvidenceStatusCommand, agentContextEvidenceTemplateCommand, agentContextResolveCommand, agentContextValidateCommand, agentReadinessAuditCommand, appendActivityEvent, applyLocalContextMutationPlan, applyManagedWorkflowPolicyAutoResponses, archiveInactiveTeamSyncWork, attachLocalContextPackReceipts, autoArchiveTeamSyncState, buildAdaptiveWorkRoutingRecommendation, buildAgentReadinessAuditReport, buildAgenticHandoffMarkdown, buildAgenticTimeline, buildAgenticWorkStatus, buildAutomationInstallPlan, buildCanonicalEvent, buildCodeHooksInstallPlan, buildCodePromotionResult, buildCodeStatusResult, buildCodeSyncResult, buildCodingIntelligenceLedger, buildCollaborationActor, buildCollaborationGuardActionCards, buildCollaborationHooksInstallPlan, buildCommitResultMetadata, buildCompanionEngineeringLeadPlanReport, buildContextPackStats, buildDocsBootstrapResult, buildEvalCaseArtifact, buildFeaturePlanMarkdown, buildFeatureSpecMarkdown, buildFeatureTasksMarkdown, buildFinalCommitReport, buildGeneratedWorkflowPlanDocument, buildHostedCodeOverlayUploadPayload, buildHostedGuardPayload, buildInstalledDependencyEvidence, buildJournalCheckpointEntry, buildLocalAgentContextValidationReport, buildLocalCallersResult, buildLocalCodeOverlay, buildLocalContextMutationPlan, buildLocalContextPackReceipt, buildLocalContextPackReceipts, buildLocalImpactResult, buildLocalImportsResult, buildLocalNeighborsResult, buildLocalProjectContextValidationReport, buildLocalProjectDriftReport, buildLocalProjectRealityCheck, buildLocalProjectRealityCheckWithAutoContext, buildLocalShortestPathResult, buildLocalSourceSnapshot, buildLocalSourceStatus, buildLocalSourceSyncResult, buildMemoryAudit, buildOnboardFolderManifest, buildOrchestratorHandoff, buildPolicyLedgerSyncReport, buildProducerLoopReport, buildProjectBriefMarkdown, buildProjectIntelligenceBrief, buildProjectIntelligenceRun, buildProjectJudgmentCard, buildSessionBootstrapBrief, buildSessionBootstrapQuality, buildSessionSnapshot, buildSmallestSafeDiffEvidence, buildSyncDocumentsDryRun, buildTeamSyncHandoffRecord, buildTeamSyncStartWorkRecord, buildTeamSyncSummary, buildToolCallPayload, buildToolResultPayload, buildVerificationPlan, buildWhyOutcomeCaptureReport, buildWorkerTrustCandidates, buildWorkflowImpactGate, buildWorkflowPhaseCommitReceipt, buildWorkflowPhaseCommitSummary, buildWorkflowPlanScaffold, captureStandaloneCommitWhy, categoryFromGuardTag, classifyToolResult, cleanContextPacks, codingLedgerExportCommand, collaborationIdeStatusCommand, collectAgentReadinessLocalSignals, collectPolicyLedgerSyncArtifacts, collectSyncDocuments, collectSyncDocumentsInput, compactHostedGuardResources, compareLocalSourceSnapshots, completeTeamSyncStateFromEvidence, completeTeamSyncWorkFromEvidence, contextControlApplyCommand, contextControlDriftCommand, contextControlHostedApplyCommand, contextControlHostedDiffCommand, contextControlPlanCommand, contextControlValidateCommand, contextPackCleanCommand, contextPackPackCommand, contextPackRetrieveCommand, contextPackStatsCommand, controlledWorkerExecuteCommand, createClient, createEmptyCollaborationState, createEmptyTeamSyncState, createLocalQueryCache, deriveLocalCollaborationResourcesFromFiles, deriveManagedWorkflowJudgmentResolution, detectReleaseSurfacesFromFiles, detectRuntimeEnvironment, docsBootstrapCommand, evalExportCommand, evalRunCommand, evaluateProjectPolicyGates, extractCommandFromToolInput, extractFilesFromToolInput, featureInitCommand, featurePlanCommand, featureSpecifyCommand, featureStartCommand, featureStatusCommand, featureTasksCommand, formatAgentContextResolution, formatAgentReadinessAuditReport, formatCompanionEngineeringLeadPlanReport, formatFinalCommitReport, formatOrchestratorRecommendationReason, formatPolicyGateDecision, formatProjectJudgmentCard, formatStuckGuardDecision, getAutomationManifestPath, getAutomationStatus, getCollaborationStatePath, getConfigPath, getContextPackStoragePaths, getLocalCodeOverlayCachePath, getLocalCodePromotionStatePath, getLocalSourceSnapshotPath, getOrchestratorRecommendation, getPlanStepDisplayTitle, getStagedFiles, getStuckGuardInjection, getTeamSyncStatePath, hasActiveManagedWorkflow, hashWorkerProfile, ingestReferences, installAutomationBundle, leadPlanCommand, listProjectsForApiKey, loadAutomationManifest, loadCollaborationState, loadConfig, loadTeamSyncState, memoryAuditCommand, memoryCleanCandidatesCommand, memoryCompactCommand, memoryHealthCommand, memoryLocalCommand, memoryReviewsCommand, mergeHybridCodeResults, normalizeCollaborationFiles, normalizeFeatureSlug, normalizeGuardTag, normalizeWorkflowPlanInput, outcomeCapturePreviewCommand, packContext, parseCollaborationResources, projectIntelligenceBriefCommand, projectIntelligenceRunCommand, readActivityTimeline, readAgentContextEvidenceLedger, readLocalCodeOverlayCache, readLocalCodePromotionState, readLocalSourceSnapshot, readLocalWorkersConfig, readSessionSnapshot, readStandaloneCommitEvidence, readWorkerTrustEvent, realityCheckCommand, referencesIngestCommand, referencesScanCommand, resolveAutoWorkflowMode, resolveCodeGraphMode, resolveContextPackRecord, resolveFeatureArtifactPaths, resolveFullWorkflowTokenBudget, resolveLocalWorkerRoutingDefaults, resolveMinimumChangeMode, resolveQueryFromToolInput, retrieveContextPack, runMemoryGuardCheck, saveCollaborationState, saveConfig, saveTeamSyncState, scanReferences, shouldFailCollaborationGuard, shouldSuggestOrchestratorForWorkflow, shouldSuggestRuntimeForWorkflow, summarizeLocalCodeOverlay, teamSyncSweepCommand, validatePlanResult, verifyCommand, workerTrustCandidateCommand, workerTrustReviewCommand, workerTrustStatusCommand, workersLocalAddCommand, workersLocalListCommand, workersLocalProbePrintCommand, workersLocalRemoveCommand, workersLocalStatusCommand, workflowSyncPolicyLedgerCommand, writeFinalCommitReport, writeLocalCodeOverlayCache, writeLocalCodePromotionState, writeLocalSourceSnapshot, writeOrchestratorHandoff, writeProducerLoopArtifact, writeSessionSnapshot };
5613
+ export { AGENT_CONTEXT_EVIDENCE_DEFAULT_LEDGER, AUTOMATION_MANIFEST_RELATIVE_PATH, type AutomaticMemorySetup, type AutomaticOrchestratorSetup, type AutomaticSetupSelection, type AutomaticWorkerSetup, AutomationInstallConflictError, AutomationUnsupportedHookBundleError, CODING_INTELLIGENCE_LEDGER_VERSION, COLLABORATION_STATE_RELATIVE_PATH, DEFAULT_DOCS_BOOTSTRAP_OUTPUT, DOCS_BOOTSTRAP_VERSION, ENGINEERING_LEAD_EXECUTION_RECEIPT_STAGES, ENGINEERING_LEAD_EXECUTION_RECEIPT_STATUSES, ENGINEERING_LEAD_POSTURES, ENGINEERING_LEAD_PROOF_VERIFICATION_SOURCES, ENGINEERING_LEAD_PROOF_VERIFICATION_STATUSES, ENGINEERING_LEAD_ROUTING_MODES, ENGINEERING_LEAD_STATUSES, ENGINEERING_LEAD_SUPERVISION_STATUSES, ENGINEERING_LEAD_WORKER_ROLES, ENGINEERING_LEAD_WORK_PACKAGE_STATUSES, FEATURE_DEFAULT_OUTPUT_DIR, FEATURE_WORK_ITEM_VERSION, FINAL_COMMIT_REPORT_RELATIVE_PATH, FINAL_COMMIT_REPORT_VERSION, type GeneratedWorkflowTaskDocument, MEMORY_GUARD_CONTEXT_TIMEOUT_MS, MEMORY_GUARD_RECALL_TIMEOUT_MS, type ManagedWorkflowTask, type ManagedWorkflowTaskContextEnvelope, type ManagedWorkflowTaskStatus, ORCHESTRATOR_HANDOFF_RELATIVE_PATH, POLICY_LEDGER_SYNC_REPORT_VERSION, PRODUCER_LOOP_ARTIFACT_VERSION, PRODUCER_LOOP_RELATIVE_DIR, PRODUCER_LOOP_REPORT_VERSION, TEAM_SYNC_STATE_RELATIVE_PATH, WHY_OUTCOME_CAPTURE_VERSION, WORKFLOW_PLANS_RELATIVE_DIR, WORKFLOW_STATE_RELATIVE_PATH, addLocalWorker, agentContextEvidenceCollectCommand, agentContextEvidenceRecordCommand, agentContextEvidenceStatusCommand, agentContextEvidenceTemplateCommand, agentContextResolveCommand, agentContextValidateCommand, agentReadinessAuditCommand, appendActivityEvent, applyLocalContextMutationPlan, applyManagedWorkflowPolicyAutoResponses, archiveInactiveTeamSyncWork, attachLocalContextPackReceipts, autoArchiveTeamSyncState, buildAdaptiveWorkRoutingRecommendation, buildAgentReadinessAuditReport, buildAgenticHandoffMarkdown, buildAgenticTimeline, buildAgenticWorkStatus, buildAutomationInstallPlan, buildCanonicalEvent, buildCodeHooksInstallPlan, buildCodePromotionResult, buildCodeStatusResult, buildCodeSyncResult, buildCodingIntelligenceLedger, buildCollaborationActor, buildCollaborationGuardActionCards, buildCollaborationHooksInstallPlan, buildCommitResultMetadata, buildCompanionEngineeringLeadPlanReport, buildContextPackStats, buildDocsBootstrapResult, buildEvalCaseArtifact, buildFeaturePlanMarkdown, buildFeatureSpecMarkdown, buildFeatureTasksMarkdown, buildFinalCommitReport, buildGeneratedWorkflowPlanDocument, buildHostedCodeOverlayUploadPayload, buildHostedGuardPayload, buildInstalledDependencyEvidence, buildJournalCheckpointEntry, buildLocalAgentContextValidationReport, buildLocalCallersResult, buildLocalCodeOverlay, buildLocalContextMutationPlan, buildLocalContextPackReceipt, buildLocalContextPackReceipts, buildLocalImpactResult, buildLocalImportsResult, buildLocalNeighborsResult, buildLocalProjectContextValidationReport, buildLocalProjectDriftReport, buildLocalProjectRealityCheck, buildLocalProjectRealityCheckWithAutoContext, buildLocalShortestPathResult, buildLocalSourceSnapshot, buildLocalSourceStatus, buildLocalSourceSyncResult, buildMemoryAudit, buildOnboardFolderManifest, buildOrchestratorHandoff, buildPolicyLedgerSyncReport, buildProducerLoopReport, buildProjectBriefMarkdown, buildProjectIntelligenceBrief, buildProjectIntelligenceRun, buildProjectJudgmentCard, buildSessionBootstrapBrief, buildSessionBootstrapQuality, buildSessionSnapshot, buildSmallestSafeDiffEvidence, buildSyncDocumentsDryRun, buildTeamSyncHandoffRecord, buildTeamSyncStartWorkRecord, buildTeamSyncSummary, buildToolCallPayload, buildToolResultPayload, buildVerificationPlan, buildWhyOutcomeCaptureReport, buildWorkerTrustCandidates, buildWorkflowImpactGate, buildWorkflowPhaseCommitReceipt, buildWorkflowPhaseCommitSummary, buildWorkflowPlanScaffold, captureStandaloneCommitWhy, categoryFromGuardTag, classifyToolResult, cleanContextPacks, codingLedgerExportCommand, collaborationIdeStatusCommand, collectAgentReadinessLocalSignals, collectPolicyLedgerSyncArtifacts, collectSyncDocuments, collectSyncDocumentsInput, compactHostedGuardResources, compareLocalSourceSnapshots, completeTeamSyncStateFromEvidence, completeTeamSyncWorkFromEvidence, contextControlApplyCommand, contextControlDriftCommand, contextControlHostedApplyCommand, contextControlHostedDiffCommand, contextControlPlanCommand, contextControlValidateCommand, contextPackCleanCommand, contextPackPackCommand, contextPackRetrieveCommand, contextPackStatsCommand, controlledWorkerExecuteCommand, createClient, createEmptyCollaborationState, createEmptyTeamSyncState, createLocalQueryCache, deriveLocalCollaborationResourcesFromFiles, deriveManagedWorkflowJudgmentResolution, detectReleaseSurfacesFromFiles, detectRuntimeEnvironment, docsBootstrapCommand, evalExportCommand, evalRunCommand, evaluateProjectPolicyGates, extractCommandFromToolInput, extractFilesFromToolInput, featureInitCommand, featurePlanCommand, featureSpecifyCommand, featureStartCommand, featureStatusCommand, featureTasksCommand, formatAgentContextResolution, formatAgentReadinessAuditReport, formatCompanionEngineeringLeadPlanReport, formatFinalCommitReport, formatOrchestratorRecommendationReason, formatPolicyGateDecision, formatProjectJudgmentCard, formatStuckGuardDecision, getAutomationManifestPath, getAutomationStatus, getCollaborationStatePath, getConfigPath, getContextPackStoragePaths, getLocalCodeOverlayCachePath, getLocalCodePromotionStatePath, getLocalSourceSnapshotPath, getOrchestratorRecommendation, getPlanStepDisplayTitle, getStagedFiles, getStuckGuardInjection, getTeamSyncStatePath, hasActiveManagedWorkflow, hashWorkerProfile, ingestReferences, installAutomationBundle, leadPlanCommand, listProjectsForApiKey, loadAutomationManifest, loadCollaborationState, loadConfig, loadTeamSyncState, memoryAuditCommand, memoryCleanCandidatesCommand, memoryCompactCommand, memoryHealthCommand, memoryLocalCommand, memoryReviewsCommand, mergeHybridCodeResults, normalizeCollaborationFiles, normalizeFeatureSlug, normalizeGuardTag, normalizeWorkflowPlanInput, outcomeCapturePreviewCommand, packContext, parseCollaborationResources, projectIntelligenceBriefCommand, projectIntelligenceRunCommand, readActivityTimeline, readAgentContextEvidenceLedger, readLocalCodeOverlayCache, readLocalCodePromotionState, readLocalSourceSnapshot, readLocalWorkersConfig, readSessionSnapshot, readStandaloneCommitEvidence, readWorkerTrustEvent, realityCheckCommand, referencesIngestCommand, referencesScanCommand, resolveAutoWorkflowMode, resolveAutomaticSetup, resolveCodeGraphMode, resolveContextPackRecord, resolveFeatureArtifactPaths, resolveFullWorkflowTokenBudget, resolveLocalWorkerRoutingDefaults, resolveMinimumChangeMode, resolveQueryFromToolInput, retrieveContextPack, runMemoryGuardCheck, saveCollaborationState, saveConfig, saveTeamSyncState, scanReferences, shouldFailCollaborationGuard, shouldSuggestOrchestratorForWorkflow, shouldSuggestRuntimeForWorkflow, summarizeLocalCodeOverlay, teamSyncSweepCommand, validatePlanResult, verifyCommand, workerTrustCandidateCommand, workerTrustReviewCommand, workerTrustStatusCommand, workersLocalAddCommand, workersLocalListCommand, workersLocalProbePrintCommand, workersLocalRemoveCommand, workersLocalStatusCommand, workflowSyncPolicyLedgerCommand, writeFinalCommitReport, writeLocalCodeOverlayCache, writeLocalCodePromotionState, writeLocalSourceSnapshot, writeOrchestratorHandoff, writeProducerLoopArtifact, writeSessionSnapshot };
package/dist/index.js CHANGED
@@ -255,6 +255,7 @@ __export(index_exports, {
255
255
  referencesIngestCommand: () => referencesIngestCommand,
256
256
  referencesScanCommand: () => referencesScanCommand,
257
257
  resolveAutoWorkflowMode: () => resolveAutoWorkflowMode,
258
+ resolveAutomaticSetup: () => resolveAutomaticSetup,
258
259
  resolveCodeGraphMode: () => resolveCodeGraphMode,
259
260
  resolveContextPackRecord: () => resolveContextPackRecord,
260
261
  resolveFeatureArtifactPaths: () => resolveFeatureArtifactPaths,
@@ -31527,35 +31528,59 @@ function phaseQuery(state, phase) {
31527
31528
  }
31528
31529
  function resolveAutoWorkflowMode(query) {
31529
31530
  const normalized = query.toLowerCase();
31530
- if (/\b(orchestrate|swarm|htask|handoff|multi-agent|multi agent|worker|proof gate|proof-gate|drift check|release gate|production gate)\b/.test(
31531
+ if (/\b(orchestrate|orchestrat|swarm|essaim|htask|h[- ]?tache|handoff|passation|multi-agent|multi agent|multi-agent|sous-agent|sous agent|worker|travailleur|parall[eè]le|coordonn(?:er|ation)|proof gate|proof-gate|preuve|garde-fou|gate|drift check|d[eé]rive|release gate|production gate|mise en production|contr[oô]le de production)\b/.test(
31531
31532
  normalized
31532
31533
  )) {
31533
31534
  return "orchestrate";
31534
31535
  }
31535
- if (/\b(deploy|deployment|release|merge|push|migration|schema|auth|billing|security|architecture|architectural|multi-phase|multiphase|phase commit|final commit|managed workflow|roadmap|plan)\b/.test(
31536
+ if (/\b(deploy|deployment|d[eé]ployer|d[eé]ploiement|release|livraison|mise en production|merge|fusionner|push|pousser|migration|sch[eé]ma|auth|authentification|billing|facturation|security|s[eé]curit[eé]|architecture|architectural|multi-phase|multiphase|phase commit|commit de phase|final commit|commit final|managed workflow|workflow g[eé]r[eé]|roadmap|feuille de route|plan|chantier)\b/.test(
31536
31537
  normalized
31537
31538
  )) {
31538
31539
  return "full";
31539
31540
  }
31540
- if (/\b(why|pourquoi|decision|décision|rationale|positioning|positionnement|strategy|stratégie|cross-session|previous decision|prior decision|historical context)\b/.test(
31541
+ if (/\b(why|pourquoi|decision|d[eé]cision|rationale|positioning|positionnement|strategy|strat[eé]gie|contexte|pr[eé]f[eé]rence|cross-session|multi-session|previous decision|prior decision|historical context|contexte historique)\b/.test(
31541
31542
  normalized
31542
31543
  )) {
31543
31544
  return "standard";
31544
31545
  }
31545
- if (/\b(status|show|list|read|lookup|recall|brief|summarize|summary|what changed|question|docs?|documentation)\b/.test(
31546
+ if (/\b(status|statut|show|montre|montrer|afficher|list|liste|lister|read|lire|lookup|chercher|retrouver|recall|rappel|brief|r[eé]sum[eé]|summarize|summary|what changed|ce qui a chang[eé]|question|docs?|documentation)\b/.test(
31546
31547
  normalized
31547
31548
  ) && !/\b(implement|change|fix|ship|code|refactor|test|write|create|build)\b/.test(normalized)) {
31548
31549
  return "lite";
31549
31550
  }
31550
- if (/\b(typo|copy edit|small diff|tiny diff|one-line|one line|known file|obvious fix|quick fix|format|formatting|rename)\b/.test(
31551
+ if (/\b(typo|faute|correction de texte|copy edit|petite correction|petit diff|small diff|tiny diff|one-line|one line|une ligne|fichier connu|known file|obvious fix|quick fix|correction rapide|format|formatting|formatage|rename|renommer)\b/.test(
31551
31552
  normalized
31552
- ) && !/\b(architecture|release|deploy|migration|schema|auth|billing|security|multi-file|many files|5\+ files|cross-session|decision|décision)\b/.test(
31553
+ ) && !/\b(architecture|release|deploy|d[eé]ploiement|migration|schema|sch[eé]ma|auth|billing|security|s[eé]curit[eé]|multi-file|multi-fichier|many files|plusieurs fichiers|5\+ files|cross-session|multi-session|decision|d[eé]cision)\b/.test(
31553
31554
  normalized
31554
31555
  )) {
31555
31556
  return "lite";
31556
31557
  }
31557
31558
  return "standard";
31558
31559
  }
31560
+ function resolveAutomaticSetup(query, requestedMode, options = {}) {
31561
+ const effectiveMode = effectiveWorkflowMode(requestedMode, query);
31562
+ const hostedMemory = options.hostedConfigured !== false && effectiveMode !== "lite";
31563
+ const orchestratorRequired = effectiveMode === "orchestrate";
31564
+ const hasOrchestratorSignal = getOrchestratorRecommendation(query, effectiveMode) !== null;
31565
+ return {
31566
+ requestedMode,
31567
+ effectiveMode,
31568
+ companion: "active",
31569
+ memory: hostedMemory ? "hosted" : "none",
31570
+ orchestrator: orchestratorRequired ? "required" : hasOrchestratorSignal ? "available" : "none",
31571
+ workers: orchestratorRequired && /\b(worker|travailleur|sous-agent(?:s)?|sous agent(?:s)?|parall[eè]le(?:s)?|swarm|essaim)\b/i.test(
31572
+ query
31573
+ ) ? "policy_gated" : "none",
31574
+ standaloneMemory: "not_selected",
31575
+ tokenStrategy: effectiveMode === "full" || effectiveMode === "orchestrate" ? "budgeted" : "minimal",
31576
+ reasons: [
31577
+ `task intent selected ${effectiveMode.toUpperCase()}`,
31578
+ hostedMemory ? "hosted memory is used for this workflow depth" : "no mandatory memory call for this workflow depth",
31579
+ orchestratorRequired ? "orchestrator capabilities are required for proof, coordination, or production gates" : hasOrchestratorSignal ? "orchestrator remains available if the task escalates" : "orchestration is not needed for the detected task scope",
31580
+ "standalone snipara-memory is reserved for applications that explicitly choose the autonomous memory package"
31581
+ ]
31582
+ };
31583
+ }
31559
31584
  function effectiveWorkflowMode(mode, query = "") {
31560
31585
  return mode === "auto" ? resolveAutoWorkflowMode(query) : mode;
31561
31586
  }
@@ -32809,6 +32834,26 @@ function printLiteWorkflowRun(query, requestedMode) {
32809
32834
  );
32810
32835
  console.log("");
32811
32836
  }
32837
+ function printAutomaticSetup(selection) {
32838
+ console.log(import_chalk9.default.bold("Automatic Snipara setup"));
32839
+ printKeyValue2("Companion:", "active router");
32840
+ printKeyValue2("Workflow:", `${selection.effectiveMode} (${selection.requestedMode} requested)`);
32841
+ printKeyValue2(
32842
+ "Memory:",
32843
+ selection.memory === "hosted" ? "hosted Snipara memory" : "none required"
32844
+ );
32845
+ printKeyValue2(
32846
+ "Orchestrator:",
32847
+ selection.orchestrator === "required" ? "required" : selection.orchestrator === "available" ? "available on escalation" : "not selected"
32848
+ );
32849
+ printKeyValue2(
32850
+ "Workers:",
32851
+ selection.workers === "policy_gated" ? "policy-gated recommendation" : "not selected"
32852
+ );
32853
+ printKeyValue2("Standalone memory:", "not selected automatically");
32854
+ printKeyValue2("Token strategy:", selection.tokenStrategy);
32855
+ console.log("");
32856
+ }
32812
32857
  function runtimeHintVersionLabel(report) {
32813
32858
  if (!report.runtime.cliVersion) {
32814
32859
  return report.runtime.version ? ` (${report.runtime.version})` : "";
@@ -34951,6 +34996,9 @@ async function sharedContextCommand(options) {
34951
34996
  async function workflowRunCommand(options) {
34952
34997
  const hostedConfigured = isConfigured();
34953
34998
  const effectiveMode = effectiveWorkflowMode(options.mode, options.query);
34999
+ const automaticSetup = resolveAutomaticSetup(options.query, options.mode, {
35000
+ hostedConfigured
35001
+ });
34954
35002
  const localAdaptiveRoutingPolicy = readLocalAdaptiveRoutingProjectPolicy();
34955
35003
  const localAdaptiveRoutingRequested = shouldBuildAdaptiveRouting(options);
34956
35004
  const canRunLocalAdaptiveRouting = !hostedConfigured && effectiveMode !== "orchestrate" && (localAdaptiveRoutingRequested || localAdaptiveRoutingPolicy !== null && localAdaptiveRoutingPolicy.mode !== "off");
@@ -34985,7 +35033,7 @@ async function workflowRunCommand(options) {
34985
35033
  policySource: options.orchestratorPolicySource,
34986
35034
  adaptiveRoutingDryRun: Boolean(adaptiveRouting)
34987
35035
  });
34988
- const shouldEmitOrchestratorHandoff = options.emitOrchestratorHandoff || options.autoRouteOrchestrator;
35036
+ const shouldEmitOrchestratorHandoff = options.emitOrchestratorHandoff || options.autoRouteOrchestrator || options.mode === "auto" && effectiveMode === "orchestrate";
34989
35037
  const preparedHandoff = shouldEmitOrchestratorHandoff && orchestratorRecommendation ? writeOrchestratorHandoff({
34990
35038
  sourceCommand: "workflow run",
34991
35039
  recommendation: orchestratorRecommendation,
@@ -34999,6 +35047,7 @@ async function workflowRunCommand(options) {
34999
35047
  const payload2 = {
35000
35048
  mode: options.mode,
35001
35049
  effective_mode: effectiveMode,
35050
+ automatic_setup: automaticSetup,
35002
35051
  local_only: true,
35003
35052
  local_policy_path: localAdaptiveRoutingPolicy ? ADAPTIVE_ROUTING_POLICY_RELATIVE_PATH2 : null,
35004
35053
  retrieval_policy: effectiveMode === "lite" ? {
@@ -35021,6 +35070,7 @@ async function workflowRunCommand(options) {
35021
35070
  if (effectiveMode === "lite") {
35022
35071
  printLiteWorkflowRun(options.query, options.mode);
35023
35072
  } else {
35073
+ printAutomaticSetup(automaticSetup);
35024
35074
  console.log(import_chalk9.default.bold("Local Adaptive Work Routing"));
35025
35075
  console.log(
35026
35076
  "Hosted Snipara is not configured; no context query, hosted catalog, or planner call ran."
@@ -35038,6 +35088,7 @@ async function workflowRunCommand(options) {
35038
35088
  const payload2 = {
35039
35089
  mode: options.mode,
35040
35090
  effective_mode: effectiveMode,
35091
+ automatic_setup: automaticSetup,
35041
35092
  retrieval_policy: {
35042
35093
  mandatory_calls: [],
35043
35094
  escalation: "Run recall, context_query, or code impact only when the task needs them.",
@@ -35053,6 +35104,7 @@ async function workflowRunCommand(options) {
35053
35104
  return;
35054
35105
  }
35055
35106
  printLiteWorkflowRun(options.query, options.mode);
35107
+ printAutomaticSetup(automaticSetup);
35056
35108
  if (options.runtimeHint !== false) {
35057
35109
  printRuntimeHint(options.query, effectiveMode);
35058
35110
  }
@@ -35072,6 +35124,7 @@ async function workflowRunCommand(options) {
35072
35124
  if (options.json) {
35073
35125
  printJson2({
35074
35126
  mode: options.mode,
35127
+ automatic_setup: automaticSetup,
35075
35128
  orchestrate: result,
35076
35129
  orchestrator_recommendation: orchestratorRecommendation,
35077
35130
  orchestrator_handoff: preparedHandoff,
@@ -35081,6 +35134,7 @@ async function workflowRunCommand(options) {
35081
35134
  return;
35082
35135
  }
35083
35136
  printOrchestrateResult(result);
35137
+ printAutomaticSetup(automaticSetup);
35084
35138
  if (options.runtimeHint !== false) {
35085
35139
  printRuntimeHint(options.query, effectiveMode);
35086
35140
  printOrchestratorHandoffHint(options.query, effectiveMode, orchestratorRecommendation);
@@ -35104,6 +35158,7 @@ async function workflowRunCommand(options) {
35104
35158
  const payload = {
35105
35159
  mode: options.mode,
35106
35160
  effective_mode: effectiveMode,
35161
+ automatic_setup: automaticSetup,
35107
35162
  orchestrator_recommendation: orchestratorRecommendation,
35108
35163
  orchestrator_handoff: preparedHandoff,
35109
35164
  adaptive_routing: adaptiveRouting,
@@ -35183,6 +35238,7 @@ async function workflowRunCommand(options) {
35183
35238
  printJson2(payload);
35184
35239
  return;
35185
35240
  }
35241
+ printAutomaticSetup(automaticSetup);
35186
35242
  if (effectiveMode === "full" && payload.session_bootstrap) {
35187
35243
  const printedBootstrap = printSessionBootstrap(
35188
35244
  payload.session_bootstrap,
@@ -46594,7 +46650,11 @@ workflow.command("final-commit").description("Persist the final workflow outcome
46594
46650
  json: options.json
46595
46651
  });
46596
46652
  });
46597
- workflow.command("run").description("Run a LITE/STANDARD/FULL/orchestrate workflow preset").requiredOption("-q, --query <query>", "Workflow query").option("-M, --mode <mode>", "lite|standard|auto|full|orchestrate", "standard").option(
46653
+ workflow.command("run").description("Run a LITE/STANDARD/FULL/orchestrate workflow preset").requiredOption("-q, --query <query>", "Workflow query").option(
46654
+ "-M, --mode <mode>",
46655
+ "lite|standard|auto|full|orchestrate (auto selects the smallest effective setup)",
46656
+ "auto"
46657
+ ).option(
46598
46658
  "-m, --max-tokens <number>",
46599
46659
  "Maximum tokens; FULL mode splits this across workflow surfaces",
46600
46660
  "8000"
@@ -47963,6 +48023,7 @@ if (require.main === module) {
47963
48023
  referencesIngestCommand,
47964
48024
  referencesScanCommand,
47965
48025
  resolveAutoWorkflowMode,
48026
+ resolveAutomaticSetup,
47966
48027
  resolveCodeGraphMode,
47967
48028
  resolveContextPackRecord,
47968
48029
  resolveFeatureArtifactPaths,
@@ -1131,13 +1131,13 @@ where the specific command needs hosted context or memory:
1131
1131
 
1132
1132
  `workflow run --mode` accepts exactly these values:
1133
1133
 
1134
- | CLI value | Guide label | Runtime behavior |
1135
- | ------------- | ------------------- | --------------------------------------------------------------------- |
1136
- | `lite` | LITE | Small, known-scope work with no mandatory hosted context call |
1137
- | `standard` | STANDARD | Normal work with context and code-graph follow-up when needed |
1138
- | `auto` | AUTO | Routes by task intent to `lite`, `standard`, `full`, or `orchestrate` |
1139
- | `full` | FULL | Managed, phased work with durable context and plan support |
1140
- | `orchestrate` | FULL + ORCHESTRATED | Explicit deeper orchestration for multi-agent or proof-gate work |
1134
+ | CLI value | Guide label | Runtime behavior |
1135
+ | ------------- | ------------------- | ----------------------------------------------------------------------------------- |
1136
+ | `lite` | LITE | Small, known-scope work with no mandatory hosted context call |
1137
+ | `standard` | STANDARD | Normal work with context and code-graph follow-up when needed |
1138
+ | `auto` | AUTO | Default mode; routes by task intent to `lite`, `standard`, `full`, or `orchestrate` |
1139
+ | `full` | FULL | Managed, phased work with durable context and plan support |
1140
+ | `orchestrate` | FULL + ORCHESTRATED | Explicit deeper orchestration for multi-agent or proof-gate work |
1141
1141
 
1142
1142
  The root `run` command is the Project Intelligence judgment/release flow.
1143
1143
  `workflow run` is the workflow-mode runner; they are different commands.
@@ -1672,7 +1672,7 @@ Semantics:
1672
1672
  - `snipara-companion query --follow-recommendation` = execute the hosted recommended structural tool instead of only printing it; context retrieval defaults to a 30-second timeout and supports `--search-mode keyword|semantic|hybrid`, `--no-answer-pack`, `--no-auto-decompose`, and `--no-shared-context`
1673
1673
  - `snipara-companion workflow run --mode lite` = zero mandatory hosted calls for small known-file work
1674
1674
  - `snipara-companion workflow run --mode standard` = context query plus automatic `snipara_code_*` follow-up when Snipara recommends one
1675
- - `snipara-companion workflow run --mode auto` = routes to lite, standard, full, or orchestrate from task intent
1675
+ - `snipara-companion workflow run` = AUTO by default; routes to lite, standard, full, or orchestrate from task intent and reports the selected Companion/memory/orchestrator setup
1676
1676
  - `snipara-companion workflow run --mode full` = budgeted durable bootstrap + optional session context + context query + automatic structural follow-up + hosted plan with quality diagnostics
1677
1677
  - `snipara-companion plan --write-plan-file ./plan.json` = convert hosted `snipara_plan` output into managed workflow JSON
1678
1678
  - `snipara-companion plan --start-workflow` or `workflow run --mode full --start-workflow-from-plan` = create local `.snipara/workflow/current.json` from a valid generated plan
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "snipara-companion",
3
- "version": "3.6.23",
3
+ "version": "3.6.24",
4
4
  "description": "Local-first CLI that asks your repo what breaks before an AI coding agent edits it.",
5
5
  "main": "dist/index.js",
6
6
  "bin": {