UNPKG

@yogesh0333/yogiway

Version:

YOGIWAY Format - Ultra-compact, nested-aware data format for LLM prompts. Handles deeply nested JSON efficiently, 10-15% more efficient than TOON.

53 lines 1.61 kB
/** * Converter between YOGIWAY (text) and PATHX (binary) formats */ /** * Convert YOGIWAY text format to PATHX binary format */ export declare function yogiwayToPathx(yogiwayText: string): Uint8Array; /** * Convert PATHX binary format to YOGIWAY text format */ export declare function pathxToYogiway(pathxBinary: Uint8Array, options?: { useTabs?: boolean; compressPaths?: boolean; usePathReferences?: boolean; }): string; /** * Convert JavaScript object to PATHX (for storage/transmission) */ export declare function toPathx(data: any, options?: { compress?: boolean; optimizePaths?: boolean; }): Uint8Array; /** * Convert PATHX binary to JavaScript object */ export declare function fromPathx(data: Uint8Array): any; /** * Convert JavaScript object to YOGIWAY (for LLM prompts) */ export declare function toYogiway(data: any, options?: { useTabs?: boolean; compressPaths?: boolean; usePathReferences?: boolean; }): string; /** * Convert YOGIWAY text to JavaScript object */ export declare function fromYogiway(text: string): any; /** * Smart converter: chooses best format based on use case */ export declare function smartEncode(data: any, useCase?: 'llm' | 'storage' | 'transmission'): string | Uint8Array; declare const _default: { yogiwayToPathx: typeof yogiwayToPathx; pathxToYogiway: typeof pathxToYogiway; toPathx: typeof toPathx; fromPathx: typeof fromPathx; toYogiway: typeof toYogiway; fromYogiway: typeof fromYogiway; smartEncode: typeof smartEncode; }; export default _default; //# sourceMappingURL=converter.d.ts.map