import type { CodeModule, JsonValue } from '../browser/project-change.js'; export { currentEngineContract, findEngineContract, type EngineContract } from './engine-contract.js'; export type RuntimeModule = Pick; export interface RuntimeProgram { readonly engineContract: string; readonly engineDigest: string; readonly entryModuleId: string; readonly modules: Readonly>; } export interface RuntimeCapabilityCall { readonly invocationId: string; readonly kind: string; readonly payload: JsonValue; readonly signal: AbortSignal; } export interface RuntimeCapabilityResponse { readonly body: JsonValue; readonly status: number; } export interface LlmTaskInvocation { readonly input: Readonly>; readonly invocationId: string; readonly mode: 'chat' | 'json'; readonly signal: AbortSignal; readonly version: 1; } export type LlmTaskResult = { readonly kind: 'completed'; readonly value: JsonValue; readonly version: 1; } | { readonly code: 'llm.output-invalid' | 'llm.unavailable'; readonly kind: 'failed'; readonly message: string; readonly version: 1; }; export type InvokeLlmTask = (invocation: LlmTaskInvocation) => Promise; export interface RuntimeInvocation { readonly capability: (call: RuntimeCapabilityCall) => Promise; readonly input: JsonValue; readonly invocationId: string; readonly program: RuntimeProgram; readonly signal?: AbortSignal; } export interface RuntimeHarness { readonly engineDigest: string; invoke(invocation: RuntimeInvocation): Promise; } export interface RuntimeConformanceCase { readonly name: string; verify(harness: RuntimeHarness): Promise; } export declare const runtimeConformanceCases: readonly RuntimeConformanceCase[];