import type { TasksetSourceRef } from "./taskset-draft-core.js"; import { type LearningTextAsset, type RewardBinding, type RewardRelease, type TaskAdmissionDecision, type TaskBatch, type TaskDefinition, type TaskEvidence } from "@openpond/evals"; /** Projects a sealed batch into training inputs. The public batch compiler * rechecks every evidence/decision snapshot before adaptation. */ export declare function materializeLearningBatchTaskset(input: { batch: TaskBatch; definition: TaskDefinition; binding: RewardBinding; rewards: RewardRelease[]; evidence: TaskEvidence[]; decisions: TaskAdmissionDecision[]; profileId: string; source: TasksetSourceRef; assets?: LearningTextAsset[]; assetBytes?: ReadonlyMap; }): { taskset: { schemaVersion: "openpond.taskset.v1"; id: string; revision: number; profileId: string; profileRelease?: { id: string; contentHash: string; revision: number; } | null | undefined; createImproveRunId: string | null; name: string; objective: string; purpose: "benchmark" | "general"; benchmark: { schemaVersion: "openpond.tasksetBenchmark.v1"; definitionId: string; releaseId: string; releaseHash: string; managedReleasePath: string; adaptationSplit: "frozen_eval" | "test" | "train" | "validation"; evaluationSplit: "frozen_eval" | "test" | "train" | "validation"; primaryMetric: "cost_usd" | "foreground_tokens" | "latency_ms" | "success_rate"; qualityGate: "all_pass" | "non_regression" | "none"; source: "builtin" | "imported"; metadata: Record; } | null; preferenceComparison: { schemaVersion: "openpond.tasksetPreferenceComparisonBinding.v1"; releaseId: string; releaseHash: string; publishedAt: string; metadata: Record; } | null; status: "archived" | "awaiting_disclosure_approval" | "awaiting_materialization_approval" | "baselining" | "blocked" | "draft" | "failed" | "materializing" | "needs_review" | "ready" | "validating"; sourceRefs: ({ id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; metadata: Record; schemaVersion: "openpond.huggingFaceDatasetSource.v1"; kind: "huggingface"; repositoryId: string; repositoryUrl: string; revision: string; configuration: string; upstreamSplits: string[]; gated: boolean; private: boolean; declaredLicense: string | null; sourceFileHashes: string[]; } | { id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; metadata: Record; schemaVersion: "openpond.uploadedFileDatasetSource.v1"; kind: "uploaded_file"; originalFileNames: string[]; mediaTypes: string[]; sourceFileHashes: string[]; totalBytes: number; parserVersion: string; } | { id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; metadata: Record; schemaVersion: "openpond.generatedDatasetSource.v1"; kind: "generated"; generatorId: string; generatorVersion: string; seed: number; generatorHash: string; } | { id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; metadata: Record; schemaVersion: "openpond.learningBatchDatasetSource.v1"; kind: "learning_batch"; batch: { id: string; revision: number; contentHash: string; }; taskDefinition: { id: string; revision: number; contentHash: string; }; admittedBy: string; } | { schemaVersion: "openpond.trainingSource.v1"; id: string; profileId: string; sessionId: string; turnIds: string[]; workspaceId: string | null; sourceHash: string; clusterKey: string; title: string; occurredAt: string; consent: { status: "denied" | "granted" | "pending" | "revoked"; scope: "full_session" | "metadata_only" | "selected_turns"; grantedBy: string | null; grantedAt: string | null; purpose: "task_authoring_and_evaluation"; }; connectedAppIds: string[]; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; licensingStatus: "approved" | "blocked" | "pending" | "review"; metadata: Record; } | { schemaVersion: "openpond.connectedDatasetSource.v1"; kind: "connected_activity"; id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; origin: "claude_code" | "codex" | "grok_build" | "hermes" | "native_chat" | "native_work" | "oh_my_pi" | "openclaw" | "opencode" | "pi"; sourceId: string; sessionId: string; normalizerVersion: string; projection: "conversation" | "turn"; ownerUserId: string; purpose: "recorded_evaluation"; sourceFileHashes?: string[] | undefined; metadata: Record; })[]; datasetArtifact?: { schemaVersion: "openpond.datasetArtifact.v1"; id: string; tasksetId: string; tasksetRevision: number; contentHash: string; format: "parquet"; schema: { schemaVersion: "openpond.datasetSemanticSchema.v1"; fields: { name: string; semanticRole: "chosen" | "cluster_id" | "demonstration" | "expected_output" | "feedback" | "messages" | "metadata" | "privileged_context" | "prompt" | "rejected" | "reward" | "row_id" | "tag"; logicalType: "boolean" | "float" | "integer" | "json" | "messages" | "string"; nullable: boolean; policy: "metadata" | "privileged" | "visible"; }[]; schemaHash: string; }; shards: { id: string; split: "frozen_eval" | "test" | "train" | "validation"; path: string; contentHash: string; schemaHash: string; sizeBytes: number; rowCount: number; rowGroupCount: number; }[]; rowCount: number; splitCounts: Record<"frozen_eval" | "test" | "train" | "validation", number>; sourceReceiptRefs: string[]; mappingHash: string; qualityReportHash: string; createdAt: string; } | null | undefined; policy: { policyVisibleFields: string[]; privilegedFields: string[]; hiddenGraderRefs: string[]; connectedAppScopes: string[]; }; environment: { protocolVersion: "openpond.taskEnvironment.v1"; kind: "agent" | "chat" | "program" | "stateful_harness" | "work"; entrypoint: string; stateful: boolean; deterministicSeeds: boolean; toolNames: string[]; actionBindings?: { schemaVersion: "openpond.harnessActionBinding.v1"; actionId: string; modelToolName: string; description: string; inputSchema: Record; actionSchemaHash: string; agentRelease: { id: string; contentHash: string; }; implementationHash: string; runtimeBindingId: string; capabilityReceiptHash: string; sideEffect: "read" | "write"; studentVisible: boolean; timeoutMs: number; episodeArgumentBindings: { argument: string; source: "case_id"; }[]; }[] | undefined; lifecycle: ("cleanup" | "create" | "grade" | "reset" | "step")[]; defaultTimeoutMs: number; networkPolicy: "declared_read_only" | "declared_scoped" | "none"; resources?: { id: string; kind: "catalog" | "code_module" | "configuration" | "file"; path: string; mediaType?: string | null | undefined; visibility: "policy_hidden" | "policy_visible" | "privileged"; required: boolean; metadata: Record; }[] | undefined; metadata: Record; }; capabilities: { schemaVersion: "openpond.tasksetCapabilities.v1"; taskKind: "chat" | "custom_program" | "multi_agent" | "single_agent"; supportedSignals: ("correction" | "demonstration" | "feedback" | "label" | "preference" | "reward")[]; compatibleMethods: ("dpo" | "grpo" | "none" | "opd" | "opsd" | "ppo" | "retrieval" | "sdft" | "sdpo" | "sft")[]; rewardKinds: ("deterministic" | "exact" | "human" | "model_judge" | "none")[]; requiresTools: boolean; requiresState: boolean; requiresPrivilegedGrading: boolean; environmentPlacements: ("colocated" | "local" | "provider_native" | "remote")[]; exportable: boolean; portabilityBlockers: string[]; }; metrics?: { schemaVersion: "openpond.tasksetMetricPolicy.v1"; primaryMetric: string; aggregation: "custom" | "mean_score" | "pass_rate" | "weighted_mean"; missingReward: "exclude" | "zero"; taskWeights?: Record | undefined; customAggregator: { module: string; exportName: string; contentHash: string; timeoutMs: number; networkPolicy: "none"; } | null; } | undefined; tasks: { schemaVersion: "openpond.taskData.v1"; id: string; clusterKey: string; split: "frozen_eval" | "test" | "train" | "validation"; input: Record; expectedOutput: Record | null; policyVisibleContext: Record; privilegedContextRef: string | null; sourceRefs: string[]; assets?: { id: string; sourceRefId: string; artifactRef: string; fileName: string; stagingPath?: string | undefined; mediaType: string; sha256: string; sizeBytes: number; split: "frozen_eval" | "test" | "train" | "validation"; metadata: Record; }[] | undefined; resourceRefs?: string[] | undefined; requiredOutputs?: { path: string; mediaType: string; schemaRef?: string | null | undefined; submissionMode?: "structured_json" | undefined; maxBytes?: number | undefined; metadata: Record; }[] | undefined; tags: string[]; metadata: Record; }[]; graders: ({ id: string; taskIds?: string[] | undefined; version: string; label: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; metadata: Record; kind: "content" | "diff" | "file" | "runtime_event" | "schema" | "state" | "test"; config: Record; } | { id: string; taskIds?: string[] | undefined; version: string; label: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; metadata: Record; kind: "model_judge"; rubric: string; judge: { providerId: "anthropic" | "claude-code" | "codex" | "custom-openai-compatible" | "deepseek" | "google" | "grok-build" | "groq" | "moonshot" | "openai" | "opencode" | "openpond" | "openrouter" | "together" | "xai" | "zai" | `acp:${string}`; modelId: string; }; calibrationFixtureRefs: string[]; calibrationStatus: "failed" | "passed" | "pending"; temperature: number; } | { id: string; taskIds?: string[] | undefined; version: string; label: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; metadata: Record; kind: "human"; form?: { schemaVersion: "openpond.humanForm.v1"; mode: "individual" | "pairwise"; instructions: string; criteria: ({ id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "score"; minimum: number; maximum: number; step: number; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "category"; options: string[]; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "boolean"; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "text"; minimumLength?: number | undefined; maximumLength: number; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "preference"; requireStrength?: boolean | undefined; allowTie: boolean; })[]; } | undefined; rubric: string; reviewerRole: string; } | { id: string; taskIds?: string[] | undefined; version: string; label: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; metadata: Record; kind: "custom_verifier"; runtime?: "isolated_javascript" | "sandbox_process" | undefined; module: string; exportName: string; timeoutMs: number; networkPolicy: "none"; })[]; graderFixtures: { id: string; taskId: string; label: "adversarial" | "boundary" | "infrastructure_failure" | "negative" | "positive" | "prompt_injection"; output: Record; infrastructureError: string | null; expectedPassed: boolean; expectedRewardEligible: boolean; metadata: Record; }[]; learningSignals: { demonstrations: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "demonstration"; prompt: string | null; response: string | null; }[]; preferences: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "preference"; prompt: string; chosen: string; rejected: string; rationale: string | null; }[]; corrections: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "correction"; original: string; corrected: string; rationale: string | null; }[]; feedback: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "feedback"; feedback: string; polarity: "mixed" | "negative" | "neutral" | "positive"; }[]; rewards: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "reward"; task: string; rules: { id: string; points: number; condition: string; }[]; otherwisePoints: number; executable: boolean; }[]; labels: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "label"; labelKind: "rubric"; task: string; criteria: { id: string; label: string; description: string; }[]; calibrationExamples: { positive: string; negative: string; boundary: string; }; }[]; }; authoringProvenance: { schemaVersion: "openpond.taskAuthoringProvenance.v1"; model: { providerId: "anthropic" | "claude-code" | "codex" | "custom-openai-compatible" | "deepseek" | "google" | "grok-build" | "groq" | "moonshot" | "openai" | "opencode" | "openpond" | "openrouter" | "together" | "xai" | "zai" | `acp:${string}`; modelId: string; } | null; modelConfig: Record; skillHash: string; promptTemplateVersion: string; buildIntent: "demonstrations" | "discovery" | "preferences" | "rubric" | "verifiable_reward"; buildSpecification: { kind: "demonstrations"; behavior: string; examples: { id: string; prompt: string; response: string; }[]; } | { kind: "preferences"; preference: string; pairs: { id: string; prompt: string; chosen: string; rejected: string; rationale: string; }[]; } | { kind: "verifiable_reward"; task: string; rules: { id: string; points: number; condition: string; }[]; otherwisePoints: number; } | { kind: "rubric"; task: string; criteria: { id: string; label: string; description: string; }[]; positiveExample: string; negativeExample: string; boundaryExample: string; } | null; evidenceHashes: string[]; tasksetSdkVersion: string; sourceCommit: string | null; repairHistory: { attempt: number; summary: string; createdAt: string; }[]; createdAt: string; }; readiness: { schemaVersion: "openpond.tasksetReadiness.v1"; tasksetId: string; tasksetHash: string; ready: boolean; recommendedMethod: "dpo" | "grpo" | "none" | "opd" | "opsd" | "ppo" | "retrieval" | "sdft" | "sdpo" | "sft"; trainingPath: { primaryMethod: "dpo" | "grpo" | "opsd" | "ppo" | "sdft" | "sdpo" | "sft"; bootstrap: { method: "sft"; purpose: "trajectory_bootstrap"; demonstrationRefs: string[]; limitations: string[]; } | null; } | null; methodReadiness: { method: "dpo" | "grpo" | "ppo" | "sft"; status: "compatible" | "needs_dataset_work" | "recommended"; reasonCodes: ("demonstrations_missing" | "executable_reward_missing" | "frozen_eval_missing" | "preference_pairs_invalid" | "preference_pairs_missing" | "reward_model_missing" | "reward_not_calibrated" | "taskset_not_ready" | "value_model_required")[]; reasons: string[]; }[]; compatibleDestinationClasses: ("custom" | "export" | "hosted_managed")[]; blockers: { code: string; message: string; path: string | null; }[]; advisories: { code: string; message: string; path: string | null; }[]; warnings: string[]; generatedAt: string; } | null; contentHash: string; createdAt: string; updatedAt: string; metadata: Record; }; release: { schemaVersion: "openpond.tasksetRelease.v2"; id: string; revision: number; policy: { policyVisibleFields: string[]; privilegedFields: string[]; hiddenGraderRefs: string[]; connectedAppScopes: string[]; }; environment: { protocolVersion: "openpond.environment.v1"; kind: "agent" | "custom_program" | "text" | "work"; entrypoint: string; stateful: boolean; deterministicSeeds: boolean; lifecycle: ("collect" | "create" | "destroy" | "reset" | "step")[]; networkPolicy: "declared_read_only" | "declared_scoped" | "none"; defaultTimeoutMs: number; }; environmentRelease?: { id: string; contentHash: string; } | undefined; tools: { name: string; description: string; inputSchema: Record; inputSchemaHash: string; sideEffect: "read" | "write"; timeoutMs: number; }[]; capabilities: { id: string; required: boolean; scopes: string[]; portability: "host_adapter" | "hosted_only" | "local_only" | "portable"; }[]; tasks: { id: string; clusterKey: string; split: "frozen_eval" | "test" | "train" | "validation"; input: Record; expectedOutput: Record | null; policyVisibleContext: Record; privilegedContextRef: string | null; artifactRefs: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; }[]; requiredOutputs?: { path: string; mediaType: string; schemaRef: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; } | null; submissionMode?: "structured_json" | undefined; maxBytes: number | null; metadata: Record; }[] | undefined; tags: string[]; }[]; graders: ({ id: string; taskIds?: string[] | undefined; version: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; kind: "artifact" | "content" | "runtime_event" | "schema" | "state"; config: Record; } | { id: string; taskIds?: string[] | undefined; version: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; kind: "model_judge"; rubricRef: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; }; calibrationStatus: "failed" | "passed" | "pending"; model?: { providerId: string; modelId: string; revision: string | null; } | undefined; temperature?: number | undefined; } | { id: string; taskIds?: string[] | undefined; version: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; kind: "custom_verifier"; runtime?: "isolated_javascript" | "sandbox_process" | undefined; verifierRef: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; }; exportName?: string | undefined; timeoutMs: number; networkPolicy: "none"; } | { id: string; taskIds?: string[] | undefined; version: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; kind: "human"; rubricRef: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; }; reviewerRole: string; form?: { schemaVersion: "openpond.humanForm.v1"; mode: "individual" | "pairwise"; instructions: string; criteria: ({ id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "score"; minimum: number; maximum: number; step: number; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "category"; options: string[]; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "boolean"; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "text"; minimumLength?: number | undefined; maximumLength: number; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "preference"; requireStrength?: boolean | undefined; allowTie: boolean; })[]; } | undefined; })[]; verifierSetRelease?: { id: string; contentHash: string; } | undefined; metrics?: { schemaVersion: "openpond.tasksetMetricPolicy.v1"; primaryMetric: string; aggregation: "custom" | "mean_score" | "pass_rate" | "weighted_mean"; missingReward: "exclude" | "zero"; taskWeights?: Record | undefined; customAggregator: { module: string; exportName: string; contentHash: string; timeoutMs: number; networkPolicy: "none"; } | null; } | undefined; metadata: Record; contentHash: string; }; generatedFiles: { path: string; role: "environment" | "fixture" | "verifier"; content: string; }[]; tasksetAssetBytes: Map>; }; /** Shared admission-to-training preparation. No caller may claim a passed * privacy scan without executing the same checks over the pinned evidence. */ export declare function prepareReviewedLearningBatch(input: Omit[0], "source"> & { admissionContext?: "explicit_local_batch_review" | "explicit_hosted_batch_review"; }): { taskset: { schemaVersion: "openpond.taskset.v1"; id: string; revision: number; profileId: string; profileRelease?: { id: string; contentHash: string; revision: number; } | null | undefined; createImproveRunId: string | null; name: string; objective: string; purpose: "benchmark" | "general"; benchmark: { schemaVersion: "openpond.tasksetBenchmark.v1"; definitionId: string; releaseId: string; releaseHash: string; managedReleasePath: string; adaptationSplit: "frozen_eval" | "test" | "train" | "validation"; evaluationSplit: "frozen_eval" | "test" | "train" | "validation"; primaryMetric: "cost_usd" | "foreground_tokens" | "latency_ms" | "success_rate"; qualityGate: "all_pass" | "non_regression" | "none"; source: "builtin" | "imported"; metadata: Record; } | null; preferenceComparison: { schemaVersion: "openpond.tasksetPreferenceComparisonBinding.v1"; releaseId: string; releaseHash: string; publishedAt: string; metadata: Record; } | null; status: "archived" | "awaiting_disclosure_approval" | "awaiting_materialization_approval" | "baselining" | "blocked" | "draft" | "failed" | "materializing" | "needs_review" | "ready" | "validating"; sourceRefs: ({ id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; metadata: Record; schemaVersion: "openpond.huggingFaceDatasetSource.v1"; kind: "huggingface"; repositoryId: string; repositoryUrl: string; revision: string; configuration: string; upstreamSplits: string[]; gated: boolean; private: boolean; declaredLicense: string | null; sourceFileHashes: string[]; } | { id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; metadata: Record; schemaVersion: "openpond.uploadedFileDatasetSource.v1"; kind: "uploaded_file"; originalFileNames: string[]; mediaTypes: string[]; sourceFileHashes: string[]; totalBytes: number; parserVersion: string; } | { id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; metadata: Record; schemaVersion: "openpond.generatedDatasetSource.v1"; kind: "generated"; generatorId: string; generatorVersion: string; seed: number; generatorHash: string; } | { id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; metadata: Record; schemaVersion: "openpond.learningBatchDatasetSource.v1"; kind: "learning_batch"; batch: { id: string; revision: number; contentHash: string; }; taskDefinition: { id: string; revision: number; contentHash: string; }; admittedBy: string; } | { schemaVersion: "openpond.trainingSource.v1"; id: string; profileId: string; sessionId: string; turnIds: string[]; workspaceId: string | null; sourceHash: string; clusterKey: string; title: string; occurredAt: string; consent: { status: "denied" | "granted" | "pending" | "revoked"; scope: "full_session" | "metadata_only" | "selected_turns"; grantedBy: string | null; grantedAt: string | null; purpose: "task_authoring_and_evaluation"; }; connectedAppIds: string[]; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; licensingStatus: "approved" | "blocked" | "pending" | "review"; metadata: Record; } | { schemaVersion: "openpond.connectedDatasetSource.v1"; kind: "connected_activity"; id: string; profileId: string; title: string; sourceHash: string; occurredAt: string; licensingStatus: "approved" | "blocked" | "pending" | "review"; secretScanStatus: "blocked" | "passed" | "pending"; piiScanStatus: "blocked" | "passed" | "pending" | "review"; origin: "claude_code" | "codex" | "grok_build" | "hermes" | "native_chat" | "native_work" | "oh_my_pi" | "openclaw" | "opencode" | "pi"; sourceId: string; sessionId: string; normalizerVersion: string; projection: "conversation" | "turn"; ownerUserId: string; purpose: "recorded_evaluation"; sourceFileHashes?: string[] | undefined; metadata: Record; })[]; datasetArtifact?: { schemaVersion: "openpond.datasetArtifact.v1"; id: string; tasksetId: string; tasksetRevision: number; contentHash: string; format: "parquet"; schema: { schemaVersion: "openpond.datasetSemanticSchema.v1"; fields: { name: string; semanticRole: "chosen" | "cluster_id" | "demonstration" | "expected_output" | "feedback" | "messages" | "metadata" | "privileged_context" | "prompt" | "rejected" | "reward" | "row_id" | "tag"; logicalType: "boolean" | "float" | "integer" | "json" | "messages" | "string"; nullable: boolean; policy: "metadata" | "privileged" | "visible"; }[]; schemaHash: string; }; shards: { id: string; split: "frozen_eval" | "test" | "train" | "validation"; path: string; contentHash: string; schemaHash: string; sizeBytes: number; rowCount: number; rowGroupCount: number; }[]; rowCount: number; splitCounts: Record<"frozen_eval" | "test" | "train" | "validation", number>; sourceReceiptRefs: string[]; mappingHash: string; qualityReportHash: string; createdAt: string; } | null | undefined; policy: { policyVisibleFields: string[]; privilegedFields: string[]; hiddenGraderRefs: string[]; connectedAppScopes: string[]; }; environment: { protocolVersion: "openpond.taskEnvironment.v1"; kind: "agent" | "chat" | "program" | "stateful_harness" | "work"; entrypoint: string; stateful: boolean; deterministicSeeds: boolean; toolNames: string[]; actionBindings?: { schemaVersion: "openpond.harnessActionBinding.v1"; actionId: string; modelToolName: string; description: string; inputSchema: Record; actionSchemaHash: string; agentRelease: { id: string; contentHash: string; }; implementationHash: string; runtimeBindingId: string; capabilityReceiptHash: string; sideEffect: "read" | "write"; studentVisible: boolean; timeoutMs: number; episodeArgumentBindings: { argument: string; source: "case_id"; }[]; }[] | undefined; lifecycle: ("cleanup" | "create" | "grade" | "reset" | "step")[]; defaultTimeoutMs: number; networkPolicy: "declared_read_only" | "declared_scoped" | "none"; resources?: { id: string; kind: "catalog" | "code_module" | "configuration" | "file"; path: string; mediaType?: string | null | undefined; visibility: "policy_hidden" | "policy_visible" | "privileged"; required: boolean; metadata: Record; }[] | undefined; metadata: Record; }; capabilities: { schemaVersion: "openpond.tasksetCapabilities.v1"; taskKind: "chat" | "custom_program" | "multi_agent" | "single_agent"; supportedSignals: ("correction" | "demonstration" | "feedback" | "label" | "preference" | "reward")[]; compatibleMethods: ("dpo" | "grpo" | "none" | "opd" | "opsd" | "ppo" | "retrieval" | "sdft" | "sdpo" | "sft")[]; rewardKinds: ("deterministic" | "exact" | "human" | "model_judge" | "none")[]; requiresTools: boolean; requiresState: boolean; requiresPrivilegedGrading: boolean; environmentPlacements: ("colocated" | "local" | "provider_native" | "remote")[]; exportable: boolean; portabilityBlockers: string[]; }; metrics?: { schemaVersion: "openpond.tasksetMetricPolicy.v1"; primaryMetric: string; aggregation: "custom" | "mean_score" | "pass_rate" | "weighted_mean"; missingReward: "exclude" | "zero"; taskWeights?: Record | undefined; customAggregator: { module: string; exportName: string; contentHash: string; timeoutMs: number; networkPolicy: "none"; } | null; } | undefined; tasks: { schemaVersion: "openpond.taskData.v1"; id: string; clusterKey: string; split: "frozen_eval" | "test" | "train" | "validation"; input: Record; expectedOutput: Record | null; policyVisibleContext: Record; privilegedContextRef: string | null; sourceRefs: string[]; assets?: { id: string; sourceRefId: string; artifactRef: string; fileName: string; stagingPath?: string | undefined; mediaType: string; sha256: string; sizeBytes: number; split: "frozen_eval" | "test" | "train" | "validation"; metadata: Record; }[] | undefined; resourceRefs?: string[] | undefined; requiredOutputs?: { path: string; mediaType: string; schemaRef?: string | null | undefined; submissionMode?: "structured_json" | undefined; maxBytes?: number | undefined; metadata: Record; }[] | undefined; tags: string[]; metadata: Record; }[]; graders: ({ id: string; taskIds?: string[] | undefined; version: string; label: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; metadata: Record; kind: "content" | "diff" | "file" | "runtime_event" | "schema" | "state" | "test"; config: Record; } | { id: string; taskIds?: string[] | undefined; version: string; label: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; metadata: Record; kind: "model_judge"; rubric: string; judge: { providerId: "anthropic" | "claude-code" | "codex" | "custom-openai-compatible" | "deepseek" | "google" | "grok-build" | "groq" | "moonshot" | "openai" | "opencode" | "openpond" | "openrouter" | "together" | "xai" | "zai" | `acp:${string}`; modelId: string; }; calibrationFixtureRefs: string[]; calibrationStatus: "failed" | "passed" | "pending"; temperature: number; } | { id: string; taskIds?: string[] | undefined; version: string; label: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; metadata: Record; kind: "human"; form?: { schemaVersion: "openpond.humanForm.v1"; mode: "individual" | "pairwise"; instructions: string; criteria: ({ id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "score"; minimum: number; maximum: number; step: number; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "category"; options: string[]; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "boolean"; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "text"; minimumLength?: number | undefined; maximumLength: number; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "preference"; requireStrength?: boolean | undefined; allowTie: boolean; })[]; } | undefined; rubric: string; reviewerRole: string; } | { id: string; taskIds?: string[] | undefined; version: string; label: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; metadata: Record; kind: "custom_verifier"; runtime?: "isolated_javascript" | "sandbox_process" | undefined; module: string; exportName: string; timeoutMs: number; networkPolicy: "none"; })[]; graderFixtures: { id: string; taskId: string; label: "adversarial" | "boundary" | "infrastructure_failure" | "negative" | "positive" | "prompt_injection"; output: Record; infrastructureError: string | null; expectedPassed: boolean; expectedRewardEligible: boolean; metadata: Record; }[]; learningSignals: { demonstrations: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "demonstration"; prompt: string | null; response: string | null; }[]; preferences: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "preference"; prompt: string; chosen: string; rejected: string; rationale: string | null; }[]; corrections: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "correction"; original: string; corrected: string; rationale: string | null; }[]; feedback: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "feedback"; feedback: string; polarity: "mixed" | "negative" | "neutral" | "positive"; }[]; rewards: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "reward"; task: string; rules: { id: string; points: number; condition: string; }[]; otherwisePoints: number; executable: boolean; }[]; labels: { id: string; taskId: string | null; sourceRefs: string[]; artifactRef: string; approved: boolean; confidence: number; metadata: Record; kind: "label"; labelKind: "rubric"; task: string; criteria: { id: string; label: string; description: string; }[]; calibrationExamples: { positive: string; negative: string; boundary: string; }; }[]; }; authoringProvenance: { schemaVersion: "openpond.taskAuthoringProvenance.v1"; model: { providerId: "anthropic" | "claude-code" | "codex" | "custom-openai-compatible" | "deepseek" | "google" | "grok-build" | "groq" | "moonshot" | "openai" | "opencode" | "openpond" | "openrouter" | "together" | "xai" | "zai" | `acp:${string}`; modelId: string; } | null; modelConfig: Record; skillHash: string; promptTemplateVersion: string; buildIntent: "demonstrations" | "discovery" | "preferences" | "rubric" | "verifiable_reward"; buildSpecification: { kind: "demonstrations"; behavior: string; examples: { id: string; prompt: string; response: string; }[]; } | { kind: "preferences"; preference: string; pairs: { id: string; prompt: string; chosen: string; rejected: string; rationale: string; }[]; } | { kind: "verifiable_reward"; task: string; rules: { id: string; points: number; condition: string; }[]; otherwisePoints: number; } | { kind: "rubric"; task: string; criteria: { id: string; label: string; description: string; }[]; positiveExample: string; negativeExample: string; boundaryExample: string; } | null; evidenceHashes: string[]; tasksetSdkVersion: string; sourceCommit: string | null; repairHistory: { attempt: number; summary: string; createdAt: string; }[]; createdAt: string; }; readiness: { schemaVersion: "openpond.tasksetReadiness.v1"; tasksetId: string; tasksetHash: string; ready: boolean; recommendedMethod: "dpo" | "grpo" | "none" | "opd" | "opsd" | "ppo" | "retrieval" | "sdft" | "sdpo" | "sft"; trainingPath: { primaryMethod: "dpo" | "grpo" | "opsd" | "ppo" | "sdft" | "sdpo" | "sft"; bootstrap: { method: "sft"; purpose: "trajectory_bootstrap"; demonstrationRefs: string[]; limitations: string[]; } | null; } | null; methodReadiness: { method: "dpo" | "grpo" | "ppo" | "sft"; status: "compatible" | "needs_dataset_work" | "recommended"; reasonCodes: ("demonstrations_missing" | "executable_reward_missing" | "frozen_eval_missing" | "preference_pairs_invalid" | "preference_pairs_missing" | "reward_model_missing" | "reward_not_calibrated" | "taskset_not_ready" | "value_model_required")[]; reasons: string[]; }[]; compatibleDestinationClasses: ("custom" | "export" | "hosted_managed")[]; blockers: { code: string; message: string; path: string | null; }[]; advisories: { code: string; message: string; path: string | null; }[]; warnings: string[]; generatedAt: string; } | null; contentHash: string; createdAt: string; updatedAt: string; metadata: Record; }; release: { schemaVersion: "openpond.tasksetRelease.v2"; id: string; revision: number; policy: { policyVisibleFields: string[]; privilegedFields: string[]; hiddenGraderRefs: string[]; connectedAppScopes: string[]; }; environment: { protocolVersion: "openpond.environment.v1"; kind: "agent" | "custom_program" | "text" | "work"; entrypoint: string; stateful: boolean; deterministicSeeds: boolean; lifecycle: ("collect" | "create" | "destroy" | "reset" | "step")[]; networkPolicy: "declared_read_only" | "declared_scoped" | "none"; defaultTimeoutMs: number; }; environmentRelease?: { id: string; contentHash: string; } | undefined; tools: { name: string; description: string; inputSchema: Record; inputSchemaHash: string; sideEffect: "read" | "write"; timeoutMs: number; }[]; capabilities: { id: string; required: boolean; scopes: string[]; portability: "host_adapter" | "hosted_only" | "local_only" | "portable"; }[]; tasks: { id: string; clusterKey: string; split: "frozen_eval" | "test" | "train" | "validation"; input: Record; expectedOutput: Record | null; policyVisibleContext: Record; privilegedContextRef: string | null; artifactRefs: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; }[]; requiredOutputs?: { path: string; mediaType: string; schemaRef: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; } | null; submissionMode?: "structured_json" | undefined; maxBytes: number | null; metadata: Record; }[] | undefined; tags: string[]; }[]; graders: ({ id: string; taskIds?: string[] | undefined; version: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; kind: "artifact" | "content" | "runtime_event" | "schema" | "state"; config: Record; } | { id: string; taskIds?: string[] | undefined; version: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; kind: "model_judge"; rubricRef: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; }; calibrationStatus: "failed" | "passed" | "pending"; model?: { providerId: string; modelId: string; revision: string | null; } | undefined; temperature?: number | undefined; } | { id: string; taskIds?: string[] | undefined; version: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; kind: "custom_verifier"; runtime?: "isolated_javascript" | "sandbox_process" | undefined; verifierRef: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; }; exportName?: string | undefined; timeoutMs: number; networkPolicy: "none"; } | { id: string; taskIds?: string[] | undefined; version: string; weight: number; hardGate: boolean; rewardEligible: boolean; privileged: boolean; kind: "human"; rubricRef: { id: string; path: string; contentHash: string; sizeBytes: number; mediaType: string; visibility: "host_private" | "policy" | "verifier"; }; reviewerRole: string; form?: { schemaVersion: "openpond.humanForm.v1"; mode: "individual" | "pairwise"; instructions: string; criteria: ({ id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "score"; minimum: number; maximum: number; step: number; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "category"; options: string[]; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "boolean"; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "text"; minimumLength?: number | undefined; maximumLength: number; } | { id: string; label: string; instructions: string; required: boolean; allowAbstain: boolean; requireRationale?: boolean | undefined; anchors?: { value: string | number | boolean; description: string; }[] | undefined; kind: "preference"; requireStrength?: boolean | undefined; allowTie: boolean; })[]; } | undefined; })[]; verifierSetRelease?: { id: string; contentHash: string; } | undefined; metrics?: { schemaVersion: "openpond.tasksetMetricPolicy.v1"; primaryMetric: string; aggregation: "custom" | "mean_score" | "pass_rate" | "weighted_mean"; missingReward: "exclude" | "zero"; taskWeights?: Record | undefined; customAggregator: { module: string; exportName: string; contentHash: string; timeoutMs: number; networkPolicy: "none"; } | null; } | undefined; metadata: Record; contentHash: string; }; generatedFiles: { path: string; role: "environment" | "fixture" | "verifier"; content: string; }[]; tasksetAssetBytes: Map>; }; //# sourceMappingURL=training-learning-batch.d.ts.map