@equationalapplications/core-llm-wiki 9.5.2 → 9.6.0

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.mts CHANGED
@@ -1,5 +1,5 @@
1
- import { M as MemoryBundle, F as FormatContextOptions, G as GraphNeighborhood, a as MemoryDump, b as FormattedMemoryDump, O as OntologyMode, R as ReadOptions, S as SQLiteAdapter, W as WikiOptions, c as WikiMemory } from './testing-BA6CedgZ.mjs';
2
- export { C as CheckpointIncompleteError, d as ChunkFailure, e as ClassifierAnswer, f as ClassifierQuestion, g as ClassifyRequest, h as ClassifyResponse, D as DegradedRecord, i as DraftPage, E as EmbedFactResult, j as EmbedFailureKind, k as EmbeddingMarkerKind, l as EntityMaintenanceReport, m as EntityStatus, n as EraseReport, o as EraseStepError, p as ExtractedFact, q as ExtractedFactEdge, r as ExtractedFactWithOntology, s as ExtractedTask, t as ForgetParams, u as ForgetResult, v as GraphTraversalOptions, w as GroundingConfig, H as HEAL_BATCH_SIZE, x as HEAL_RECHECK_MS, y as HOOK_TIMEOUT_MARKER, z as HealResult, I as ImportDumpResult, A as IngestDocumentResult, L as LLMProvider, B as LibrarianConfig, J as LibrarianGateConfig, K as LockedMaintenanceJob, N as MaintenanceJob, P as MaintenanceStopReason, Q as MemoryDumpEntity, T as MigrationPolicy, U as ONTOLOGY_BACKFILL_BATCH_SIZE, V as ONTOLOGY_BACKFILL_MAX_PROMPT_CHARS, X as ONTOLOGY_BACKFILL_RECHECK_MS, Y as OntologyBackfillResult, Z as OntologyConfig, _ as OntologyEdgeType, $ as OntologyManifest, a0 as OntologyNodeType, a1 as OntologyPromptContext, a2 as OntologyUpdates, a3 as PendingMaintenance, a4 as PendingMigrationWork, a5 as PendingSourceStatus, a6 as PromptOverrides, a7 as PromptService, a8 as PrunePartialFailureError, a9 as ReembedResult, aa as RememberInput, ab as RunPendingMaintenanceOptions, ac as RunPendingMaintenanceResult, ad as SourcePassage, ae as StoreSourceResult, af as StoredSource, ag as StoredSourceDump, ah as StoredSourceSummary, ai as SupersedeReplacement, aj as VectorRanker, ak as VectorRankerFallback, al as VectorRankerRankArgs, am as VectorRankerSemanticResult, an as WikiBusyError, ao as WikiBusyOperation, ap as WikiCheckpoint, aq as WikiConfig, ar as WikiDiagnostic, as as WikiDiagnosticCode, at as WikiDiagnosticDetail, au as WikiDiagnosticOperation, av as WikiDiagnosticSeverity, aw as WikiDiagnosticTrigger, ax as WikiDraftNotFound, ay as WikiDuplicateHashError, az as WikiEdge, aA as WikiEvent, aB as WikiExternalDeletionError, aC as WikiFact, aD as WikiGraphNodeOwnershipConflict, aE as WikiIngestEmptyError, aF as WikiInstructions, aG as WikiInvalidReadOptions, aH as WikiLintReport, aI as WikiMemoryTestAccess, aJ as WikiMigrationRequiredError, aK as WikiOutboxEvent, aL as WikiParseError, aM as WikiSearchUnavailableError, aN as WikiSourcePointer, aO as WikiSourceRefHashCollision, aP as WikiStrictOntologyViolation, aQ as WikiSupersedeError, aR as WikiSupersedeReason, aS as WikiTask, aT as WikiTransactionError, aU as isWikiSearchUnavailableError, aV as validateManifest } from './testing-BA6CedgZ.mjs';
1
+ import { M as MemoryBundle, F as FormatContextOptions, G as GraphNeighborhood, a as MemoryDump, b as FormattedMemoryDump, O as OntologyMode, R as ReadOptions, c as OntologyConfig, W as WikiConfig, S as SQLiteAdapter, d as WikiOptions, e as WikiMemory } from './testing-BBeQQIYp.mjs';
2
+ export { C as CLASSIFIER_MAX_CHOICES, f as CheckpointIncompleteError, g as ChunkFailure, h as ClassifierAnswer, i as ClassifierQuestion, j as ClassifyRequest, k as ClassifyResponse, D as DegradedRecord, l as DraftPage, E as EmbedFactResult, m as EmbedFailureKind, n as EmbeddingMarkerKind, o as EntityMaintenanceReport, p as EntityStatus, q as EraseReport, r as EraseStepError, s as ExtractedFact, t as ExtractedFactEdge, u as ExtractedFactWithOntology, v as ExtractedTask, w as ForgetParams, x as ForgetResult, y as GraphTraversalOptions, z as GroundingConfig, H as HEAL_BATCH_SIZE, A as HEAL_RECHECK_MS, B as HOOK_TIMEOUT_MARKER, I as HealResult, J as ImportDumpResult, K as IngestDocumentResult, L as LLMProvider, N as LibrarianConfig, P as LibrarianGateConfig, Q as LockedMaintenanceJob, T as MaintenanceJob, U as MaintenanceStopReason, V as MemoryDumpEntity, X as MigrationPolicy, Y as ONTOLOGY_ABSTAIN_SENTINEL, Z as ONTOLOGY_BACKFILL_BATCH_SIZE, _ as ONTOLOGY_BACKFILL_MAX_PROMPT_CHARS, $ as ONTOLOGY_BACKFILL_RECHECK_MS, a0 as OntologyBackfillResult, a1 as OntologyEdgeType, a2 as OntologyManifest, a3 as OntologyNodeType, a4 as OntologyPromptContext, a5 as OntologyUpdates, a6 as PendingMaintenance, a7 as PendingMigrationWork, a8 as PendingSourceStatus, a9 as PromptOverrides, aa as PromptService, ab as PrunePartialFailureError, ac as ReembedResult, ad as RememberInput, ae as RunPendingMaintenanceOptions, af as RunPendingMaintenanceResult, ag as SourcePassage, ah as StoreSourceResult, ai as StoredSource, aj as StoredSourceDump, ak as StoredSourceSummary, al as SupersedeReplacement, am as SystemOneConfig, an as SystemOneThresholdSite, ao as VectorRanker, ap as VectorRankerFallback, aq as VectorRankerRankArgs, ar as VectorRankerSemanticResult, as as WikiBusyError, at as WikiBusyOperation, au as WikiCheckpoint, av as WikiDiagnostic, aw as WikiDiagnosticCode, ax as WikiDiagnosticDetail, ay as WikiDiagnosticOperation, az as WikiDiagnosticSeverity, aA as WikiDiagnosticTrigger, aB as WikiDraftNotFound, aC as WikiDuplicateHashError, aD as WikiEdge, aE as WikiEvent, aF as WikiExternalDeletionError, aG as WikiFact, aH as WikiGraphNodeOwnershipConflict, aI as WikiIngestEmptyError, aJ as WikiInstructions, aK as WikiInvalidReadOptions, aL as WikiLintReport, aM as WikiMemoryTestAccess, aN as WikiMigrationRequiredError, aO as WikiOutboxEvent, aP as WikiParseError, aQ as WikiSearchUnavailableError, aR as WikiSourcePointer, aS as WikiSourceRefHashCollision, aT as WikiStrictOntologyViolation, aU as WikiSupersedeError, aV as WikiSupersedeReason, aW as WikiTask, aX as WikiTransactionError, aY as isReservedAbstainSlug, aZ as isWikiSearchUnavailableError, a_ as validateManifest } from './testing-BBeQQIYp.mjs';
3
3
  import { OkfFile } from '@equationalapplications/core-okf';
4
4
 
5
5
  /**
@@ -167,9 +167,55 @@ declare function validateLibrarianPromptTemplate(template: string, options: {
167
167
  }): string[];
168
168
  declare function mapLibrarianOptionsToReadOptions(options: LibrarianOptions): Pick<ReadOptions, 'tierWeights' | 'includeZeroWeightEntities'>;
169
169
 
170
+ /**
171
+ * The one place the ontology-backfill scheduler default is defined
172
+ * (specs/system-one-config §8). Read sites resolve through this so a host
173
+ * that sets nothing gets the same answer everywhere — the same discipline as
174
+ * `engineDefaults.ts` for the 8.0.0 librarian/maintenance defaults.
175
+ */
176
+ /** Default batch size for scheduler-driven ontology backfill passes. */
177
+ declare const DEFAULT_ONTOLOGY_JOB_BATCH_SIZE = 50;
178
+ interface OntologyJobDefaults {
179
+ batchSize: number;
180
+ }
181
+ /**
182
+ * Resolve the scheduler's ontology-backfill batch size from
183
+ * `WikiConfig.ontology.schedulerBatchSize`. Invalid values (non-finite, < 1)
184
+ * fall back to the default rather than throwing — a bad config value degrades
185
+ * to the default instead of breaking construction or every run.
186
+ */
187
+ declare function resolveOntologyJobDefaults(ontology: OntologyConfig | undefined): OntologyJobDefaults;
188
+
189
+ /**
190
+ * Logs each distinct message at most once per process, sharing the
191
+ * {@link warnedDefaults} set with `warnChangedDefaultsOnce`. System-One
192
+ * resolvers use this for invalid config values (treated as unset) and
193
+ * both-keys-disagree notices (specs/system-one-config §2-§3). Messages carry
194
+ * a distinct `[core-llm-wiki] systemOne:` prefix, so a malformed message can
195
+ * never suppress a defaults-changed warning (plan Risks).
196
+ */
197
+ declare function warnOnce(message: string): void;
198
+ /**
199
+ * Typing-mode resolution chain (specs/system-one-config §2):
200
+ * call option `classifier` → `systemOne.typing` →
201
+ * `ontology.backfillClassifier` → `'llm'`. The caller validates the call
202
+ * option (a TypeError at the pass boundary); config values validate here.
203
+ * `??` throughout — falsy config values never participate by accident.
204
+ */
205
+ declare function resolveSystemOneTyping(config: WikiConfig | undefined, classifierCallOption?: 'auto' | 'llm'): 'auto' | 'llm';
206
+ /** Engine default confidence floor for classifier typing. */
207
+ declare const DEFAULT_TYPING_MIN_CONFIDENCE: 0.5;
208
+ /**
209
+ * Confidence-floor chain (specs/system-one-config §3):
210
+ * `systemOne.minConfidence.typing` → `ontology.classifyMinConfidence` →
211
+ * `0.5`. `??` throughout, so a configured `0` stays `0`. Only the classifier
212
+ * typing path reads this; call it there, never on the generative path.
213
+ */
214
+ declare function resolveTypingMinConfidence(config: WikiConfig | undefined): number;
215
+
170
216
  declare const ONTOLOGY_BACKFILL_SYSTEM_PROMPT = "You are a knowledge classification agent. You will receive existing memory facts that currently have no ontology type. For each input fact { \"id\", \"title\", \"body\", \"tags\" }, assign the best matching okf_type from the ontology manifest and optionally propose edges to related facts by title.\nReturn ONLY a valid JSON object matching this schema:\n{\n \"classifications\": [\n { \"id\": \"string (input fact id, copied verbatim)\", \"okf_type\": \"string (manifest node type slug)\", \"edges\": [{ \"edge_type\": \"string\", \"target_title\": \"string\" }] }\n ]\n}\nIf no manifest type fits a fact, omit that fact from \"classifications\" entirely \u2014 do not guess.\nWhen echoing an existing fact's title verbatim into \"target_title\", preserve every JSON escape sequence (\\\", \\n, \\\\, \\/) exactly as it appeared in the input body \u2014 do not strip backslashes, do not add unescaped quotes. Do not return markdown, just raw JSON.";
171
217
 
172
218
  declare function createWiki(db: SQLiteAdapter, options: WikiOptions): WikiMemory;
173
219
 
174
- export { DEFAULT_CHUNK_OVERLAP, DEFAULT_LIBRARIAN_SYNTHESIS_PROMPT, DEFAULT_MAX_CHUNK_LENGTH, DEFAULT_MAX_EMBED_CHARS, DEFAULT_SETUP_BUDGET_MS, EMBED_CHARS_CEILING, FormatContextOptions, FormattedMemoryDump, GraphNeighborhood, HEAL_ANCHORS_PER_CANDIDATE, HEAL_MAX_FACT_BODY_CHARS_L3, HEAL_MAX_TASKS, MemoryBundle, MemoryDump, ONTOLOGY_BACKFILL_SYSTEM_PROMPT, OntologyMode, ReadOptions, SQLiteAdapter, WikiMemory, WikiOptions, buildOntologyPromptAppendix, chunkText, configureRandomSource, createWiki, formatContext, formatGraphContext, formatMemoryDump, formatOkfBundle, hydrateLibrarianPrompt, mapLibrarianOptionsToReadOptions, parseEmbedding, parseOkfBundle, safeSlice, validUsage, validateLibrarianPromptTemplate };
220
+ export { DEFAULT_CHUNK_OVERLAP, DEFAULT_LIBRARIAN_SYNTHESIS_PROMPT, DEFAULT_MAX_CHUNK_LENGTH, DEFAULT_MAX_EMBED_CHARS, DEFAULT_ONTOLOGY_JOB_BATCH_SIZE, DEFAULT_SETUP_BUDGET_MS, DEFAULT_TYPING_MIN_CONFIDENCE, EMBED_CHARS_CEILING, FormatContextOptions, FormattedMemoryDump, GraphNeighborhood, HEAL_ANCHORS_PER_CANDIDATE, HEAL_MAX_FACT_BODY_CHARS_L3, HEAL_MAX_TASKS, MemoryBundle, MemoryDump, ONTOLOGY_BACKFILL_SYSTEM_PROMPT, OntologyConfig, OntologyMode, ReadOptions, SQLiteAdapter, WikiConfig, WikiMemory, WikiOptions, buildOntologyPromptAppendix, chunkText, configureRandomSource, createWiki, formatContext, formatGraphContext, formatMemoryDump, formatOkfBundle, hydrateLibrarianPrompt, mapLibrarianOptionsToReadOptions, parseEmbedding, parseOkfBundle, resolveOntologyJobDefaults, resolveSystemOneTyping, resolveTypingMinConfidence, safeSlice, validUsage, validateLibrarianPromptTemplate, warnOnce };
175
221
  export type { FormatOkfBundleOptions, LibrarianOptions, LibrarianPromptVariables, OkfFormatProfile, OkfImportOptions };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { M as MemoryBundle, F as FormatContextOptions, G as GraphNeighborhood, a as MemoryDump, b as FormattedMemoryDump, O as OntologyMode, R as ReadOptions, S as SQLiteAdapter, W as WikiOptions, c as WikiMemory } from './testing-BA6CedgZ.js';
2
- export { C as CheckpointIncompleteError, d as ChunkFailure, e as ClassifierAnswer, f as ClassifierQuestion, g as ClassifyRequest, h as ClassifyResponse, D as DegradedRecord, i as DraftPage, E as EmbedFactResult, j as EmbedFailureKind, k as EmbeddingMarkerKind, l as EntityMaintenanceReport, m as EntityStatus, n as EraseReport, o as EraseStepError, p as ExtractedFact, q as ExtractedFactEdge, r as ExtractedFactWithOntology, s as ExtractedTask, t as ForgetParams, u as ForgetResult, v as GraphTraversalOptions, w as GroundingConfig, H as HEAL_BATCH_SIZE, x as HEAL_RECHECK_MS, y as HOOK_TIMEOUT_MARKER, z as HealResult, I as ImportDumpResult, A as IngestDocumentResult, L as LLMProvider, B as LibrarianConfig, J as LibrarianGateConfig, K as LockedMaintenanceJob, N as MaintenanceJob, P as MaintenanceStopReason, Q as MemoryDumpEntity, T as MigrationPolicy, U as ONTOLOGY_BACKFILL_BATCH_SIZE, V as ONTOLOGY_BACKFILL_MAX_PROMPT_CHARS, X as ONTOLOGY_BACKFILL_RECHECK_MS, Y as OntologyBackfillResult, Z as OntologyConfig, _ as OntologyEdgeType, $ as OntologyManifest, a0 as OntologyNodeType, a1 as OntologyPromptContext, a2 as OntologyUpdates, a3 as PendingMaintenance, a4 as PendingMigrationWork, a5 as PendingSourceStatus, a6 as PromptOverrides, a7 as PromptService, a8 as PrunePartialFailureError, a9 as ReembedResult, aa as RememberInput, ab as RunPendingMaintenanceOptions, ac as RunPendingMaintenanceResult, ad as SourcePassage, ae as StoreSourceResult, af as StoredSource, ag as StoredSourceDump, ah as StoredSourceSummary, ai as SupersedeReplacement, aj as VectorRanker, ak as VectorRankerFallback, al as VectorRankerRankArgs, am as VectorRankerSemanticResult, an as WikiBusyError, ao as WikiBusyOperation, ap as WikiCheckpoint, aq as WikiConfig, ar as WikiDiagnostic, as as WikiDiagnosticCode, at as WikiDiagnosticDetail, au as WikiDiagnosticOperation, av as WikiDiagnosticSeverity, aw as WikiDiagnosticTrigger, ax as WikiDraftNotFound, ay as WikiDuplicateHashError, az as WikiEdge, aA as WikiEvent, aB as WikiExternalDeletionError, aC as WikiFact, aD as WikiGraphNodeOwnershipConflict, aE as WikiIngestEmptyError, aF as WikiInstructions, aG as WikiInvalidReadOptions, aH as WikiLintReport, aI as WikiMemoryTestAccess, aJ as WikiMigrationRequiredError, aK as WikiOutboxEvent, aL as WikiParseError, aM as WikiSearchUnavailableError, aN as WikiSourcePointer, aO as WikiSourceRefHashCollision, aP as WikiStrictOntologyViolation, aQ as WikiSupersedeError, aR as WikiSupersedeReason, aS as WikiTask, aT as WikiTransactionError, aU as isWikiSearchUnavailableError, aV as validateManifest } from './testing-BA6CedgZ.js';
1
+ import { M as MemoryBundle, F as FormatContextOptions, G as GraphNeighborhood, a as MemoryDump, b as FormattedMemoryDump, O as OntologyMode, R as ReadOptions, c as OntologyConfig, W as WikiConfig, S as SQLiteAdapter, d as WikiOptions, e as WikiMemory } from './testing-BBeQQIYp.js';
2
+ export { C as CLASSIFIER_MAX_CHOICES, f as CheckpointIncompleteError, g as ChunkFailure, h as ClassifierAnswer, i as ClassifierQuestion, j as ClassifyRequest, k as ClassifyResponse, D as DegradedRecord, l as DraftPage, E as EmbedFactResult, m as EmbedFailureKind, n as EmbeddingMarkerKind, o as EntityMaintenanceReport, p as EntityStatus, q as EraseReport, r as EraseStepError, s as ExtractedFact, t as ExtractedFactEdge, u as ExtractedFactWithOntology, v as ExtractedTask, w as ForgetParams, x as ForgetResult, y as GraphTraversalOptions, z as GroundingConfig, H as HEAL_BATCH_SIZE, A as HEAL_RECHECK_MS, B as HOOK_TIMEOUT_MARKER, I as HealResult, J as ImportDumpResult, K as IngestDocumentResult, L as LLMProvider, N as LibrarianConfig, P as LibrarianGateConfig, Q as LockedMaintenanceJob, T as MaintenanceJob, U as MaintenanceStopReason, V as MemoryDumpEntity, X as MigrationPolicy, Y as ONTOLOGY_ABSTAIN_SENTINEL, Z as ONTOLOGY_BACKFILL_BATCH_SIZE, _ as ONTOLOGY_BACKFILL_MAX_PROMPT_CHARS, $ as ONTOLOGY_BACKFILL_RECHECK_MS, a0 as OntologyBackfillResult, a1 as OntologyEdgeType, a2 as OntologyManifest, a3 as OntologyNodeType, a4 as OntologyPromptContext, a5 as OntologyUpdates, a6 as PendingMaintenance, a7 as PendingMigrationWork, a8 as PendingSourceStatus, a9 as PromptOverrides, aa as PromptService, ab as PrunePartialFailureError, ac as ReembedResult, ad as RememberInput, ae as RunPendingMaintenanceOptions, af as RunPendingMaintenanceResult, ag as SourcePassage, ah as StoreSourceResult, ai as StoredSource, aj as StoredSourceDump, ak as StoredSourceSummary, al as SupersedeReplacement, am as SystemOneConfig, an as SystemOneThresholdSite, ao as VectorRanker, ap as VectorRankerFallback, aq as VectorRankerRankArgs, ar as VectorRankerSemanticResult, as as WikiBusyError, at as WikiBusyOperation, au as WikiCheckpoint, av as WikiDiagnostic, aw as WikiDiagnosticCode, ax as WikiDiagnosticDetail, ay as WikiDiagnosticOperation, az as WikiDiagnosticSeverity, aA as WikiDiagnosticTrigger, aB as WikiDraftNotFound, aC as WikiDuplicateHashError, aD as WikiEdge, aE as WikiEvent, aF as WikiExternalDeletionError, aG as WikiFact, aH as WikiGraphNodeOwnershipConflict, aI as WikiIngestEmptyError, aJ as WikiInstructions, aK as WikiInvalidReadOptions, aL as WikiLintReport, aM as WikiMemoryTestAccess, aN as WikiMigrationRequiredError, aO as WikiOutboxEvent, aP as WikiParseError, aQ as WikiSearchUnavailableError, aR as WikiSourcePointer, aS as WikiSourceRefHashCollision, aT as WikiStrictOntologyViolation, aU as WikiSupersedeError, aV as WikiSupersedeReason, aW as WikiTask, aX as WikiTransactionError, aY as isReservedAbstainSlug, aZ as isWikiSearchUnavailableError, a_ as validateManifest } from './testing-BBeQQIYp.js';
3
3
  import { OkfFile } from '@equationalapplications/core-okf';
4
4
 
5
5
  /**
@@ -167,9 +167,55 @@ declare function validateLibrarianPromptTemplate(template: string, options: {
167
167
  }): string[];
168
168
  declare function mapLibrarianOptionsToReadOptions(options: LibrarianOptions): Pick<ReadOptions, 'tierWeights' | 'includeZeroWeightEntities'>;
169
169
 
170
+ /**
171
+ * The one place the ontology-backfill scheduler default is defined
172
+ * (specs/system-one-config §8). Read sites resolve through this so a host
173
+ * that sets nothing gets the same answer everywhere — the same discipline as
174
+ * `engineDefaults.ts` for the 8.0.0 librarian/maintenance defaults.
175
+ */
176
+ /** Default batch size for scheduler-driven ontology backfill passes. */
177
+ declare const DEFAULT_ONTOLOGY_JOB_BATCH_SIZE = 50;
178
+ interface OntologyJobDefaults {
179
+ batchSize: number;
180
+ }
181
+ /**
182
+ * Resolve the scheduler's ontology-backfill batch size from
183
+ * `WikiConfig.ontology.schedulerBatchSize`. Invalid values (non-finite, < 1)
184
+ * fall back to the default rather than throwing — a bad config value degrades
185
+ * to the default instead of breaking construction or every run.
186
+ */
187
+ declare function resolveOntologyJobDefaults(ontology: OntologyConfig | undefined): OntologyJobDefaults;
188
+
189
+ /**
190
+ * Logs each distinct message at most once per process, sharing the
191
+ * {@link warnedDefaults} set with `warnChangedDefaultsOnce`. System-One
192
+ * resolvers use this for invalid config values (treated as unset) and
193
+ * both-keys-disagree notices (specs/system-one-config §2-§3). Messages carry
194
+ * a distinct `[core-llm-wiki] systemOne:` prefix, so a malformed message can
195
+ * never suppress a defaults-changed warning (plan Risks).
196
+ */
197
+ declare function warnOnce(message: string): void;
198
+ /**
199
+ * Typing-mode resolution chain (specs/system-one-config §2):
200
+ * call option `classifier` → `systemOne.typing` →
201
+ * `ontology.backfillClassifier` → `'llm'`. The caller validates the call
202
+ * option (a TypeError at the pass boundary); config values validate here.
203
+ * `??` throughout — falsy config values never participate by accident.
204
+ */
205
+ declare function resolveSystemOneTyping(config: WikiConfig | undefined, classifierCallOption?: 'auto' | 'llm'): 'auto' | 'llm';
206
+ /** Engine default confidence floor for classifier typing. */
207
+ declare const DEFAULT_TYPING_MIN_CONFIDENCE: 0.5;
208
+ /**
209
+ * Confidence-floor chain (specs/system-one-config §3):
210
+ * `systemOne.minConfidence.typing` → `ontology.classifyMinConfidence` →
211
+ * `0.5`. `??` throughout, so a configured `0` stays `0`. Only the classifier
212
+ * typing path reads this; call it there, never on the generative path.
213
+ */
214
+ declare function resolveTypingMinConfidence(config: WikiConfig | undefined): number;
215
+
170
216
  declare const ONTOLOGY_BACKFILL_SYSTEM_PROMPT = "You are a knowledge classification agent. You will receive existing memory facts that currently have no ontology type. For each input fact { \"id\", \"title\", \"body\", \"tags\" }, assign the best matching okf_type from the ontology manifest and optionally propose edges to related facts by title.\nReturn ONLY a valid JSON object matching this schema:\n{\n \"classifications\": [\n { \"id\": \"string (input fact id, copied verbatim)\", \"okf_type\": \"string (manifest node type slug)\", \"edges\": [{ \"edge_type\": \"string\", \"target_title\": \"string\" }] }\n ]\n}\nIf no manifest type fits a fact, omit that fact from \"classifications\" entirely \u2014 do not guess.\nWhen echoing an existing fact's title verbatim into \"target_title\", preserve every JSON escape sequence (\\\", \\n, \\\\, \\/) exactly as it appeared in the input body \u2014 do not strip backslashes, do not add unescaped quotes. Do not return markdown, just raw JSON.";
171
217
 
172
218
  declare function createWiki(db: SQLiteAdapter, options: WikiOptions): WikiMemory;
173
219
 
174
- export { DEFAULT_CHUNK_OVERLAP, DEFAULT_LIBRARIAN_SYNTHESIS_PROMPT, DEFAULT_MAX_CHUNK_LENGTH, DEFAULT_MAX_EMBED_CHARS, DEFAULT_SETUP_BUDGET_MS, EMBED_CHARS_CEILING, FormatContextOptions, FormattedMemoryDump, GraphNeighborhood, HEAL_ANCHORS_PER_CANDIDATE, HEAL_MAX_FACT_BODY_CHARS_L3, HEAL_MAX_TASKS, MemoryBundle, MemoryDump, ONTOLOGY_BACKFILL_SYSTEM_PROMPT, OntologyMode, ReadOptions, SQLiteAdapter, WikiMemory, WikiOptions, buildOntologyPromptAppendix, chunkText, configureRandomSource, createWiki, formatContext, formatGraphContext, formatMemoryDump, formatOkfBundle, hydrateLibrarianPrompt, mapLibrarianOptionsToReadOptions, parseEmbedding, parseOkfBundle, safeSlice, validUsage, validateLibrarianPromptTemplate };
220
+ export { DEFAULT_CHUNK_OVERLAP, DEFAULT_LIBRARIAN_SYNTHESIS_PROMPT, DEFAULT_MAX_CHUNK_LENGTH, DEFAULT_MAX_EMBED_CHARS, DEFAULT_ONTOLOGY_JOB_BATCH_SIZE, DEFAULT_SETUP_BUDGET_MS, DEFAULT_TYPING_MIN_CONFIDENCE, EMBED_CHARS_CEILING, FormatContextOptions, FormattedMemoryDump, GraphNeighborhood, HEAL_ANCHORS_PER_CANDIDATE, HEAL_MAX_FACT_BODY_CHARS_L3, HEAL_MAX_TASKS, MemoryBundle, MemoryDump, ONTOLOGY_BACKFILL_SYSTEM_PROMPT, OntologyConfig, OntologyMode, ReadOptions, SQLiteAdapter, WikiConfig, WikiMemory, WikiOptions, buildOntologyPromptAppendix, chunkText, configureRandomSource, createWiki, formatContext, formatGraphContext, formatMemoryDump, formatOkfBundle, hydrateLibrarianPrompt, mapLibrarianOptionsToReadOptions, parseEmbedding, parseOkfBundle, resolveOntologyJobDefaults, resolveSystemOneTyping, resolveTypingMinConfidence, safeSlice, validUsage, validateLibrarianPromptTemplate, warnOnce };
175
221
  export type { FormatOkfBundleOptions, LibrarianOptions, LibrarianPromptVariables, OkfFormatProfile, OkfImportOptions };