import type { ChunkId, DocumentId, KnowledgeCapsuleId, KnowledgeSourceId } from "@oscharko-dev/keiko-contracts";
import { KnowledgeStoreError } from "../errors.js";
export type TokenEstimator = (text: string) => number;
export interface ChunkingOptions {
    readonly maxTokens?: number;
    readonly minTokens?: number;
    readonly overlapTokens?: number;
    readonly tokenEstimator?: TokenEstimator;
}
export declare const DEFAULT_MAX_TOKENS = 400;
export declare const DEFAULT_MIN_TOKENS = 64;
export declare const DEFAULT_OVERLAP_TOKENS = 32;
export declare const CHUNKING_STRATEGY_VERSION: "issue-195-v1";
export interface ResolvedChunkingOptions {
    readonly maxTokens: number;
    readonly minTokens: number;
    readonly overlapTokens: number;
    readonly tokenEstimator: TokenEstimator;
}
export interface ChunkDocumentParams {
    readonly capsuleId: KnowledgeCapsuleId;
    readonly sourceId: KnowledgeSourceId;
    readonly documentId: DocumentId;
    readonly sourceText: string;
    readonly force?: boolean;
    readonly signal?: AbortSignal;
}
export interface ChunkDocumentResult {
    readonly capsuleId: KnowledgeCapsuleId;
    readonly documentId: DocumentId;
    readonly chunkIds: readonly ChunkId[];
    readonly skippedExisting: boolean;
}
export declare class ChunkingError extends KnowledgeStoreError {
    readonly name: string;
}
export interface ChunkingResult {
    readonly characterStart: number;
    readonly characterEnd: number;
    readonly tokenCount: number;
    readonly safeExcerptHash: string;
}
//# sourceMappingURL=types.d.ts.map