cmpnd 0.112.2__tar.gz → 0.114.0__tar.gz
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.
- {cmpnd-0.112.2 → cmpnd-0.114.0}/PKG-INFO +1 -1
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_authored_import.py +144 -2
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/authored.py +93 -1
- cmpnd-0.114.0/cmpnd/cli/commands/evals.py +247 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/top.py +1 -1
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/verbs.py +2 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/client.py +56 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/optimization.py +20 -2
- cmpnd-0.114.0/cmpnd/optimizers/gepa_callback.py +753 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/optimizers/resume.py +32 -2
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/optimizers/tracker.py +437 -338
- cmpnd-0.114.0/cmpnd/program_evals.py +367 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/bodies.py +6 -73
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/exporter_http.py +87 -175
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/protocols.py +5 -4
- cmpnd-0.114.0/cmpnd_ingest/record_stream.py +203 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/ingest-transport.md +40 -43
- cmpnd-0.114.0/docs/platform-evals.md +82 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/sdk-instrumentation.md +2 -2
- {cmpnd-0.112.2 → cmpnd-0.114.0}/pyproject.toml +1 -1
- cmpnd-0.114.0/scripts/record_gepa_events.py +136 -0
- cmpnd-0.114.0/tests/gepa_record_fixture.py +121 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/ingest_conformance.py +5 -7
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_multi_client_stress.py +6 -11
- cmpnd-0.114.0/tests/test_authored_eval.py +229 -0
- cmpnd-0.114.0/tests/test_cli/test_evals.py +388 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_exporter.py +5 -16
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_exporter_queue.py +7 -5
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_exporter_rejections.py +2 -6
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_gepa_callback.py +2 -459
- cmpnd-0.114.0/tests/test_gepa_fold.py +498 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_gepa_integration.py +2 -2
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_ingest_conformance.py +27 -34
- cmpnd-0.114.0/tests/test_ingest_transport.py +347 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_models.py +31 -23
- cmpnd-0.114.0/tests/test_optimization_progress.py +140 -0
- cmpnd-0.114.0/tests/test_program_evals.py +508 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_queue_budget.py +2 -3
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_reanchor_patch.py +1 -1
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_sender_scenarios.py +2 -8
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_tracked_gepa.py +0 -67
- {cmpnd-0.112.2 → cmpnd-0.114.0}/uv.lock +1 -1
- cmpnd-0.112.2/cmpnd/cli/commands/evals.py +0 -101
- cmpnd-0.112.2/cmpnd/optimizers/gepa_callback.py +0 -604
- cmpnd-0.112.2/cmpnd_ingest/request_log.py +0 -126
- cmpnd-0.112.2/tests/test_cli/test_evals.py +0 -166
- cmpnd-0.112.2/tests/test_ingest_second_producer.py +0 -749
- cmpnd-0.112.2/tests/test_optimization_progress.py +0 -268
- {cmpnd-0.112.2 → cmpnd-0.114.0}/.gitignore +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/AGENTS.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/CLAUDE.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/README.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/LINEAGE.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_account.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_assessments.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_deployments.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_exporter_pool.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_gepa_patch.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_http.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_label_vocabulary.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_program_patch.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_provider_types.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_provider_writes.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_reanchor_evidence.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_reanchor_patch.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_runtime_tools.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_timespec.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_traces.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/_valsets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/callback.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/api_client.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/admin.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/assessments.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/auth.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/datasets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/deployments.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/feedback.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/kernel_lines.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/labels.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/login.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/optimizations.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/org.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/programs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/provider_credentials.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/providers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/skill.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/tool_servers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/traces.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/commands/valsets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/credentials.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/deprecation.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/label_args.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/pagination.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/shell.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/skill/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/skill/_vendor/drskill/LICENSE +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/skill/_vendor/drskill/VENDOR.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/skill/_vendor/drskill/harnesses.toml +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/skill/agents.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/skill/bundle.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/skill/install.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/skill/offer.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/trace_render.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/tree_help.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/cli/views.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/configuration.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/context.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/credentials.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/dataset_sync.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/datasets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/decorators.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/deployment.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/deployment_metadata.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/deployment_runs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/eval_handler.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/execution.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/exporter.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/exporter_http.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/field_types.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/helpers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/identity.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/imaging.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/ir/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/ir/decode.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/ir/encode.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/ir/hash.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/ir/program.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/ir/reflection.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/ir/types.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/ir/xxh64.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/kernel_lines.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/labels.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/lm_configuration.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/mcp_servers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/models.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/named_programs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/optimizers/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/optimizers/gepa.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/packaging.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/program_naming.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/programs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/references.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/retry.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/SKILL.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/examples/support_triage/data/train.jsonl +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/examples/support_triage/data/val.jsonl +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/examples/support_triage/optimize.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/examples/support_triage/program.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/examples/support_triage/task.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/examples/support_triage/task_gpt5mini.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/examples/support_triage/task_haiku.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/references/deploy.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/references/dspy.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/references/feedback.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/references/gaps.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/references/observe.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/references/optimize.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/references/setup.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/references/tools.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/skill_bundle/scripts/tools_block.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/traces.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd/versions.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/LINEAGE.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/client_floor.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/network.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/process_local.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/program_names.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/py.typed +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/queue_budget.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/rejections.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/retry.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/sender.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/span_context.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/storable.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/trace_facts.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/cmpnd_ingest/user_agent.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/2026-04-02-code-review.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/cli.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/client.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/custom-proposer.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/plans/2026-04-05-train-val-dataset-capture-design.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/plans/2026-04-05-train-val-dataset-capture.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/reading-traces.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/docs/versions.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/examples/generalizing_proposer.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/examples/local_ollama.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/audit-sdist.sh +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/capture_review_run.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/check-pip-install.sh +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/check_release_artifacts.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/export-bedrock-token.sh +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/fixtures/review_run.json.gz +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/fork-matrix.sh +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/gepa_resume_bug.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/install-test-env.sh +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/release-gate.sh +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/release-real-models.sh +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/require_version_bump.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/seed_review_run.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/selfhost_compat.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/scripts/test-in-linux.sh +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/stubs/dspy/__init__.pyi +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/stubs/dspy/primitives/__init__.pyi +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/stubs/dspy/primitives/prediction.pyi +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/stubs/dspy/utils/__init__.pyi +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/stubs/dspy/utils/callback.pyi +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/stubs/dspy/utils/dummies.pyi +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/_credential_route.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/_deployment_signature_helpers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/_exporter_helpers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/_fake_clock.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/_fresh_interpreter.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/_identity_helpers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/_resolve_refs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/_traced_run.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/conftest.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/dspy_features.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/committee_task.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/conftest.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/continuation_task.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/data/committee_train.ndjson.gz +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/data/committee_val.ndjson.gz +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/fake_lm.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/helpers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/target_capabilities.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_assessments_cli.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_capture_prompts.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_composite_module.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_dataset_auto_creation.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_deploy_execute.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_deploy_pandas.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_deploy_programs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_edge_cases.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_example_hash.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_gepa_optimization.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_interpreter_spans.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_lm_accuracy.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_module_tracing.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimization_lineage.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimization_metric_identity.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimize_authored_metric.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimize_continuation.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimize_custom_proposer.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimize_failures.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimize_loop.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimize_review_committee.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_optimize_server_owned_completion.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_parallel_export.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_program_versions.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_project_attribution.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_react_tool_spans.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_reanchor_optimization.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_save_load.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_trace_structure.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_traces_read.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_user_attribution.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/e2e/test_valsets_cli.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/01_predict_qa.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/02_predict_renamed_field.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/03_chain_of_thought_qa.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/04_predict_richer_types.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/05_composite_two_predicts.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/06_multichaincomparison.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/07_program_of_thought.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/08_opaque_module.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/09_predict_pydantic_field.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/10_react.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/11_refine.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/12_retrieve.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/13_knn.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/14_parallel.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/identity_vectors/README.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/authored_optimize/judge.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/authored_optimize/optimize_hosted.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/conftest.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/hosted_mcp_tool_optimize_probe.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/hosted_optimize_probe.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/optimization_run_probe.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/system_one_deployment.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/test_cli_deploy_smoketest.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/test_logs_renders_traces.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/test_optimization_run.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/test_optimizing_progress.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/integration/test_unhappy_path.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/lm15_prompt_fixture.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/lm15_prompts/four_turn_predict.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/lm15_prompts/rlm_six_turns.json +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/__main__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/drain.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/ingest.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/latency_transport.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/rlm_shape.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/rlm_size_report.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/README.md +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/asgi_app.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/baseline.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/drive_server.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/exits.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/outage.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/outage_proxy.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/pools.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/program.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sender/verify.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/sweep.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/test_rlm_shape.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/load/test_rlm_size_report.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/conftest.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/seed_parity.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_auth.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_datasets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_deployments.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_evals.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_health.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_modules.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_optimizations.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_programs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_signatures.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_trace_streaming.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/parity/test_traces.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/_provider.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/_readiness.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/_reliability.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/_result.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/mint_bedrock_token.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_bedrock_converse.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_deploy_programs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_optimize_client_committee.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_optimize_continuation.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_optimize_loop.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_optimize_loop_wasm.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_optimize_stress.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_provider_roles.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_readiness.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_real_provider_twins.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_reliability.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_reliability_classify.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_rlm_wasm.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_skill_agent.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/real_models/test_trace_search.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/span_reference_fixture.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_adapter_reentrancy.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_assessments_api.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_authored.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_authored_binding_credentials.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_authored_bundle_collisions.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_authored_metric_contract.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_authored_named_models.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_authored_optimize.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_callback.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_candidate_lineage.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_check_release_artifacts.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/conftest.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_admin.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_api_client.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_assessments.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_auth.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_credentials.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_datasets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_deployment_runs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_deployments.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_feedback.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_json_flag.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_login.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_main.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_optimizations.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_org.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_org_support.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_pagination.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_parity.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_programs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_provider_credentials.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_provider_flags.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_providers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_schema_sample.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_shell.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_skill.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_skill_offer.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_tool_servers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_top.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_traces.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_traces_program_and_module.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_traces_query_needs_program.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_traces_search_wire.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_tree_help.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cli/test_valsets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_client.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_client_floor.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_client_program_names.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_clustering/__init__.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_clustering/conftest.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_clustering/test_edge_cases.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_clustering/test_hash_consistency.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_cmp551_grouping_identity.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_configuration.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_context.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_context_propagation.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_credential_kwargs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_credential_selection.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_dataset_polling.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_dataset_sync.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_datasets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_decision_client_spans.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_decorators.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_deploy.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_deploy_mcp_tool_references.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_deploy_program_id.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_deployment_metadata.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_deployment_runs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_deployment_targets.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_deployments_read.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_dspy_version_label.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_eval.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_eval_example_attribution.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_eval_example_failures.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_eval_program_id.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_eval_start.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_eval_trace_grouping.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_exception_paths.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_execute.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_execute_run_identity.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_exporter_fork_exec.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_exporter_program_names.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_exporter_real.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_fake_lm.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_field_types.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_forward_access_warning.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_gepa_output_normalization.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_gepa_resume.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_identity.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_imaging.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_import_weight.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_integration.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_interpreter_callback.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_ir_encoder_properties.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_ir_golden_vectors.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_ir_roundtrip.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_kernel_lines.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_label_vocabulary.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_lm15_native_calls.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_lm15_prompt_fixtures.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_lm15_prompt_references.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_lm_configuration.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_lm_usage_shapes.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_mcp_tools.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_model_list_protocol.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_multi_client_stress_readiness.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_no_signature_hash_on_the_wire.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimization_phase_callback.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimization_program_names.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimization_start.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_budget.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_gepa_settings.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_labels.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_lift.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_lm_model_type.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_lms.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_proposer.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_reflection_lm.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_split.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_optimize_terminal_failure.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_owned_trace_streaming.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_packaging.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_packaging_callable_source.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_packaging_mcp_tools.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_packaging_program_source.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_poll_until.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_process_local.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_program_id_deprecation.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_program_identity.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_program_lineage_persist.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_program_lm_binding.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_program_names_in_deploy.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_program_naming.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_programs_create.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_project_payload.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_provider_keyword.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_provider_models.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_provider_types.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_provider_values.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_provider_writes.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_real_provider_twins_readiness.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_reanchor_evidence.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_reflector_properties.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_reflector_smoke.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_release_gate_script.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_release_real_models_script.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_replaced_names.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_repro_reactv2_bugs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_require_version_bump.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_retry.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_reversible_failures.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_rlm_tool_spans.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_run_attribution_paths.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_runtime_tools.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_schemas.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_seal_lm_credential.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_seed_review_run.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_sending_settings.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_signature_inputs.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_skill_bundle.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_skill_tools_block.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_span_references.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_span_sent_once.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_span_submission.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_span_submission_wire_contract.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_stored_login.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_system_one.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_token_attribution.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_trace_context_concurrency.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_trace_fact_wire_contract.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_trace_facts.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_trace_labels.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_trace_render.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_traces_label_search_busy.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_traces_query_needs_program.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_traces_read.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_tracker_enrich.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_truncation.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_untraced_spans.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_upload_auth_headers.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_usage_dialect.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_user_agent.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_valsets_api.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_versions.py +0 -0
- {cmpnd-0.112.2 → cmpnd-0.114.0}/tests/test_xxh64.py +0 -0
|
@@ -19,6 +19,14 @@ class BundleCarriesCredential(ValueError):
|
|
|
19
19
|
"""The bundle's import built an LM that holds a provider credential."""
|
|
20
20
|
|
|
21
21
|
|
|
22
|
+
class UnboundLMRefused(ValueError):
|
|
23
|
+
"""The eval's import creates a declared LM that the eval never uses.
|
|
24
|
+
|
|
25
|
+
Its message names each LM and the module variable that holds it, so the answer
|
|
26
|
+
carries no traceback.
|
|
27
|
+
"""
|
|
28
|
+
|
|
29
|
+
|
|
22
30
|
class MetricRefused(ValueError):
|
|
23
31
|
"""The optimize file's metric cannot be called as the kernel calls it.
|
|
24
32
|
|
|
@@ -406,6 +414,135 @@ def _check_optimize(request: dict[str, Any]) -> dict[str, Any]:
|
|
|
406
414
|
return answer
|
|
407
415
|
|
|
408
416
|
|
|
417
|
+
def _check_eval(request: dict[str, Any]) -> dict[str, Any]:
|
|
418
|
+
"""The eval file's answer: its one ``dspy.Evaluate`` checked, its devset and its judges.
|
|
419
|
+
|
|
420
|
+
The file's own bytes ship, so the metric must be a module-level name the worker can
|
|
421
|
+
read from the file. The devset leaves this child as ``devset.ndjson``.
|
|
422
|
+
"""
|
|
423
|
+
import dspy
|
|
424
|
+
|
|
425
|
+
from . import lm_configuration, program_evals
|
|
426
|
+
|
|
427
|
+
# The kernel imports the eval file in authored scope, so the check records the same
|
|
428
|
+
# LM declarations a run will.
|
|
429
|
+
lm_configuration.begin_authored()
|
|
430
|
+
ask = request["eval"]
|
|
431
|
+
with _staged(request) as root, _built_lms(root) as built:
|
|
432
|
+
module = _import_member(str(ask["entry"]))
|
|
433
|
+
found: dict[int, Any] = {}
|
|
434
|
+
for value in vars(module).values():
|
|
435
|
+
if isinstance(value, dspy.Evaluate):
|
|
436
|
+
found[id(value)] = value
|
|
437
|
+
if len(found) != 1:
|
|
438
|
+
raise ValueError(
|
|
439
|
+
f"the eval file binds {len(found)} module-level dspy.Evaluate objects. "
|
|
440
|
+
"Bind exactly one, such as `evaluate = dspy.Evaluate(devset=..., metric=...)`."
|
|
441
|
+
)
|
|
442
|
+
checked = program_evals.check_evaluate(next(iter(found.values())))
|
|
443
|
+
entrypoint = checked.metric.__name__
|
|
444
|
+
if getattr(module, entrypoint, None) is not checked.metric:
|
|
445
|
+
raise ValueError(
|
|
446
|
+
f"the metric {entrypoint!r} is not a module-level name of the eval file, so a worker "
|
|
447
|
+
"cannot read it from the file. Define it, or import it by its own name, at module level."
|
|
448
|
+
)
|
|
449
|
+
declared = getattr(module, "lms", None)
|
|
450
|
+
if declared is not None and not isinstance(declared, dict):
|
|
451
|
+
raise ValueError(f"`lms` in the eval file is a {type(declared).__name__}, not a dict of named LMs")
|
|
452
|
+
judges = program_evals.judges_of(checked.metric, declared)
|
|
453
|
+
_refuse_unbound_lms(root, module, declared or {})
|
|
454
|
+
_refuse_bundled_credentials(built, module.__name__)
|
|
455
|
+
(Path(request["work_dir"]) / "devset.ndjson").write_text(
|
|
456
|
+
"\n".join(json.dumps(row) for row in checked.rows) + "\n"
|
|
457
|
+
)
|
|
458
|
+
return {
|
|
459
|
+
"eval": {
|
|
460
|
+
"metric_entrypoint": entrypoint,
|
|
461
|
+
"input_fields": checked.input_fields,
|
|
462
|
+
"label_fields": checked.label_fields,
|
|
463
|
+
"example_count": len(checked.rows),
|
|
464
|
+
"judges": judges,
|
|
465
|
+
"failure_score": checked.failure_score,
|
|
466
|
+
}
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
|
|
470
|
+
def _lm_label(lm: Any) -> str:
|
|
471
|
+
"""How an LM reads in a refusal: a cmpnd wrapper's own repr, else its class and model."""
|
|
472
|
+
from . import lm_configuration
|
|
473
|
+
|
|
474
|
+
if isinstance(lm, (lm_configuration.SystemOne, lm_configuration.HostedLM)):
|
|
475
|
+
return repr(lm)
|
|
476
|
+
return f"{type(lm).__name__}({getattr(lm, 'model', None)!r})"
|
|
477
|
+
|
|
478
|
+
|
|
479
|
+
def _holders(root: Path, lm: Any) -> list[str]:
|
|
480
|
+
"""Where the staged modules hold ``lm`` at module level, as ``module.name`` or ``module.name['key']``."""
|
|
481
|
+
import dspy
|
|
482
|
+
|
|
483
|
+
found: list[str] = []
|
|
484
|
+
for name, loaded in sorted(sys.modules.items()):
|
|
485
|
+
origin = getattr(loaded, "__file__", None)
|
|
486
|
+
if not origin or not Path(origin).resolve().is_relative_to(root.resolve()):
|
|
487
|
+
continue
|
|
488
|
+
for attr, value in vars(loaded).items():
|
|
489
|
+
if value is lm:
|
|
490
|
+
found.append(f"{name}.{attr}")
|
|
491
|
+
elif isinstance(value, dict):
|
|
492
|
+
found.extend(f"{name}.{attr}[{key!r}]" for key, item in value.items() if item is lm)
|
|
493
|
+
if dspy.settings.lm is lm:
|
|
494
|
+
found.append("dspy.settings.lm")
|
|
495
|
+
return found
|
|
496
|
+
|
|
497
|
+
|
|
498
|
+
def _refuse_unbound_lms(root: Path, module: Any, declared: dict[str, Any]) -> None:
|
|
499
|
+
"""Refuse an eval whose import creates a declared LM that the eval never uses.
|
|
500
|
+
|
|
501
|
+
The platform connects the LMs in the eval file's own ``lms`` dict to providers, and
|
|
502
|
+
the kernel stops a call that holds any other declared LM. Every
|
|
503
|
+
``cmpnd.SystemOne(...)`` and every LM passed to ``cmpnd.configure_lm(...)`` is its own
|
|
504
|
+
declaration, so an identical judge an imported module creates is a second one. A
|
|
505
|
+
declaration on the default LM, the eval's ``judge-lm``, is refused with its own message.
|
|
506
|
+
"""
|
|
507
|
+
import dspy
|
|
508
|
+
|
|
509
|
+
from . import lm_configuration, program_evals
|
|
510
|
+
|
|
511
|
+
# The objects the run matches by identity, as the kernel's `resolve_call` does.
|
|
512
|
+
bound = [lm_configuration.unwrap(lm) for lm in declared.values()]
|
|
513
|
+
unbound = [obj for obj in lm_configuration._objects if not any(obj is lm for lm in bound)]
|
|
514
|
+
if not unbound:
|
|
515
|
+
return
|
|
516
|
+
file = Path(module.__file__).resolve().relative_to(root.resolve()).as_posix()
|
|
517
|
+
|
|
518
|
+
def located(lm: Any) -> str:
|
|
519
|
+
holders = [holder for holder in _holders(root, lm) if holder != "dspy.settings.lm"]
|
|
520
|
+
return f"{_lm_label(lm)} in {holders[0]}" if holders else _lm_label(lm)
|
|
521
|
+
|
|
522
|
+
lines: list[str] = []
|
|
523
|
+
# The default LM is the eval's `judge-lm`, so it is used, and the kernel binds no
|
|
524
|
+
# declared object to that binding.
|
|
525
|
+
default = dspy.settings.lm
|
|
526
|
+
if any(obj is default for obj in unbound):
|
|
527
|
+
unbound = [obj for obj in unbound if obj is not default]
|
|
528
|
+
lines += [
|
|
529
|
+
f"{file} declares capabilities for its default judge {located(default)}, "
|
|
530
|
+
f"which dspy.settings.lm holds as {program_evals.DEFAULT_JUDGE}.",
|
|
531
|
+
"Evals don't support a capability declaration on the default judge yet.",
|
|
532
|
+
f"Name the judge in the `lms` dict of {file} instead, and have the metric take `lms=None` "
|
|
533
|
+
"and select the judge by its name.",
|
|
534
|
+
]
|
|
535
|
+
if unbound:
|
|
536
|
+
found = [located(lm) for lm in unbound]
|
|
537
|
+
noun, pronoun = ("an LM", "it") if len(unbound) == 1 else ("LMs", "them")
|
|
538
|
+
lines += [
|
|
539
|
+
f"{file} creates {noun} it doesn't use: {', and '.join(found)}.",
|
|
540
|
+
"Evals don't support LMs outside the eval file's `lms` dict yet, even unused ones.",
|
|
541
|
+
f"Remove {pronoun}, or add {pronoun} to the `lms` dict of {file}.",
|
|
542
|
+
]
|
|
543
|
+
raise UnboundLMRefused("\n".join(lines))
|
|
544
|
+
|
|
545
|
+
|
|
409
546
|
def _rows(module: Any, name: str) -> list[Any]:
|
|
410
547
|
"""One example set the file built, refused here rather than at the first rollout."""
|
|
411
548
|
rows = getattr(module, name, None)
|
|
@@ -443,10 +580,15 @@ def main() -> int:
|
|
|
443
580
|
# Anything the imported file prints goes to stderr: this process answers one
|
|
444
581
|
# JSON document on stdout, and a module-scope `print` would otherwise be read
|
|
445
582
|
# as part of it.
|
|
446
|
-
|
|
583
|
+
if request.get("eval"):
|
|
584
|
+
answer = _check_eval(request)
|
|
585
|
+
elif request.get("optimize"):
|
|
586
|
+
answer = _check_optimize(request)
|
|
587
|
+
else:
|
|
588
|
+
answer = _check(request)
|
|
447
589
|
print(json.dumps(answer))
|
|
448
590
|
return 0
|
|
449
|
-
except (BundleCarriesCredential, MetricRefused) as exc:
|
|
591
|
+
except (BundleCarriesCredential, MetricRefused, UnboundLMRefused) as exc:
|
|
450
592
|
print(json.dumps({"error": str(exc)}))
|
|
451
593
|
except ModuleNotFoundError as exc:
|
|
452
594
|
print(
|
|
@@ -365,6 +365,97 @@ def _prepare_optimize(
|
|
|
365
365
|
)
|
|
366
366
|
|
|
367
367
|
|
|
368
|
+
@dataclass(frozen=True)
|
|
369
|
+
class EvalFacts:
|
|
370
|
+
"""What one import of the authored eval file found in it."""
|
|
371
|
+
|
|
372
|
+
input_fields: list[str] = field(default_factory=list)
|
|
373
|
+
label_fields: list[str] = field(default_factory=list)
|
|
374
|
+
example_count: int = 0
|
|
375
|
+
judges: dict[str, dict[str, Any]] = field(default_factory=dict)
|
|
376
|
+
failure_score: float = 0.0
|
|
377
|
+
metric_entrypoint: str = "metric"
|
|
378
|
+
|
|
379
|
+
|
|
380
|
+
@dataclass(frozen=True)
|
|
381
|
+
class PreparedEval:
|
|
382
|
+
"""One authored eval file, staged as the bundle a platform eval stores."""
|
|
383
|
+
|
|
384
|
+
eval_bundle: bytes
|
|
385
|
+
facts: EvalFacts
|
|
386
|
+
|
|
387
|
+
|
|
388
|
+
DEVSET_MEMBER = "devset.ndjson"
|
|
389
|
+
|
|
390
|
+
|
|
391
|
+
def prepare_eval_file(
|
|
392
|
+
source: str | Path,
|
|
393
|
+
*,
|
|
394
|
+
source_root: str | Path | None = None,
|
|
395
|
+
includes: list[str | Path] | None = None,
|
|
396
|
+
api_key: str | None = None,
|
|
397
|
+
endpoint: str | None = None,
|
|
398
|
+
) -> PreparedEval:
|
|
399
|
+
"""Stage one authored eval file and its explicit includes."""
|
|
400
|
+
members, entry = _stage(source, source_root, includes, "eval file")
|
|
401
|
+
return _prepare_eval(members, entry, api_key=api_key, endpoint=endpoint)
|
|
402
|
+
|
|
403
|
+
|
|
404
|
+
def prepare_eval_stdin(
|
|
405
|
+
source: bytes | str,
|
|
406
|
+
*,
|
|
407
|
+
api_key: str | None = None,
|
|
408
|
+
endpoint: str | None = None,
|
|
409
|
+
) -> PreparedEval:
|
|
410
|
+
"""Stage stdin as the single authored ``eval.py`` member.
|
|
411
|
+
|
|
412
|
+
The name differs from a stdin program's ``program.py``, because a run merges the eval
|
|
413
|
+
bundle into the deployed program's mount.
|
|
414
|
+
"""
|
|
415
|
+
raw = source.encode() if isinstance(source, str) else source
|
|
416
|
+
return _prepare_eval({"eval.py": raw}, "eval.py", api_key=api_key, endpoint=endpoint)
|
|
417
|
+
|
|
418
|
+
|
|
419
|
+
def _prepare_eval(members: dict[str, bytes], entry: str, *, api_key: str | None, endpoint: str | None) -> PreparedEval:
|
|
420
|
+
"""Build the eval bundle from one import of the staged bytes.
|
|
421
|
+
|
|
422
|
+
The manifest the child imports under names the file only, because the metric's name
|
|
423
|
+
is what the import finds. The final manifest names it.
|
|
424
|
+
"""
|
|
425
|
+
if not members.get(entry, b"").strip():
|
|
426
|
+
raise ValueError("the authored eval file is empty")
|
|
427
|
+
if DEVSET_MEMBER in members:
|
|
428
|
+
raise ValueError(f"{DEVSET_MEMBER} is reserved for the file cmpnd evals push writes; rename the included file")
|
|
429
|
+
versions = _dependency_versions()
|
|
430
|
+
manifest: dict[str, Any] = {
|
|
431
|
+
"metric": entry,
|
|
432
|
+
"members": ["manifest.json", *sorted(members)],
|
|
433
|
+
"authored": True,
|
|
434
|
+
"dependency_versions": versions,
|
|
435
|
+
}
|
|
436
|
+
answer, produced = _run_check(
|
|
437
|
+
_zip(manifest, members),
|
|
438
|
+
api_key=api_key,
|
|
439
|
+
endpoint=endpoint,
|
|
440
|
+
ask={"entry": entry},
|
|
441
|
+
collect=(DEVSET_MEMBER,),
|
|
442
|
+
ask_key="eval",
|
|
443
|
+
)
|
|
444
|
+
found = answer["eval"]
|
|
445
|
+
if DEVSET_MEMBER not in produced:
|
|
446
|
+
raise SourceCheckError(f"the import check reported no {DEVSET_MEMBER}")
|
|
447
|
+
facts = EvalFacts(
|
|
448
|
+
input_fields=found["input_fields"],
|
|
449
|
+
label_fields=found["label_fields"],
|
|
450
|
+
example_count=found["example_count"],
|
|
451
|
+
judges=found["judges"],
|
|
452
|
+
failure_score=found["failure_score"],
|
|
453
|
+
metric_entrypoint=found["metric_entrypoint"],
|
|
454
|
+
)
|
|
455
|
+
manifest["metric_entrypoint"] = facts.metric_entrypoint
|
|
456
|
+
return PreparedEval(eval_bundle=_zip(manifest, {**members, **produced}), facts=facts)
|
|
457
|
+
|
|
458
|
+
|
|
368
459
|
def _dependency_versions() -> dict[str, str]:
|
|
369
460
|
def version(name: str) -> str:
|
|
370
461
|
try:
|
|
@@ -478,6 +569,7 @@ def _run_check(
|
|
|
478
569
|
endpoint: str | None,
|
|
479
570
|
ask: dict[str, Any] | None = None,
|
|
480
571
|
collect: tuple[str, ...] = (),
|
|
572
|
+
ask_key: str = "optimize",
|
|
481
573
|
) -> tuple[dict[str, Any], dict[str, bytes]]:
|
|
482
574
|
"""Import the exact ZIP in a fresh child with no user environment.
|
|
483
575
|
|
|
@@ -500,7 +592,7 @@ def _run_check(
|
|
|
500
592
|
"work_dir": str(work),
|
|
501
593
|
}
|
|
502
594
|
if ask is not None:
|
|
503
|
-
request[
|
|
595
|
+
request[ask_key] = ask
|
|
504
596
|
environment = {
|
|
505
597
|
key: value
|
|
506
598
|
for key, value in os.environ.items()
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
"""Evals commands."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
import sys
|
|
6
|
+
from argparse import ArgumentParser, _SubParsersAction
|
|
7
|
+
from pathlib import Path
|
|
8
|
+
from typing import Any
|
|
9
|
+
|
|
10
|
+
from .. import api_client, deprecation, pagination
|
|
11
|
+
from . import programs
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def _add_list_args(p: ArgumentParser) -> None:
|
|
15
|
+
p.add_argument(
|
|
16
|
+
"--program",
|
|
17
|
+
dest="program_name",
|
|
18
|
+
metavar="NAME",
|
|
19
|
+
type=programs.program_slot,
|
|
20
|
+
help="Only the runs of the program whose current name is NAME",
|
|
21
|
+
)
|
|
22
|
+
p.add_argument(
|
|
23
|
+
"--module",
|
|
24
|
+
dest="module_class",
|
|
25
|
+
metavar="CLASS",
|
|
26
|
+
help="Only the runs that evaluated this module class, matched exactly (e.g. ReAct)",
|
|
27
|
+
)
|
|
28
|
+
p.add_argument("--metric", dest="metric_name", help="Filter by metric name")
|
|
29
|
+
p.add_argument("--status", help="Filter by status (running, completed, failed, cancelled)")
|
|
30
|
+
pagination.add_args(p, with_page_aliases=True, default_limit=50)
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def _add_source_options(parser: ArgumentParser) -> None:
|
|
34
|
+
from . import top
|
|
35
|
+
|
|
36
|
+
top._add_source_options(parser)
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
def register(subparsers: _SubParsersAction[ArgumentParser]) -> None:
|
|
40
|
+
parser = subparsers.add_parser("evals", help="Browse evaluation runs")
|
|
41
|
+
sub = parser.add_subparsers(dest="action")
|
|
42
|
+
|
|
43
|
+
lst = sub.add_parser("list", help="List eval runs, newest first")
|
|
44
|
+
_add_list_args(lst)
|
|
45
|
+
lst.set_defaults(func=handle_list)
|
|
46
|
+
|
|
47
|
+
deprecation.alias(sub, "search", "list", func=handle_list, configure=_add_list_args)
|
|
48
|
+
|
|
49
|
+
show = sub.add_parser("show", help="Show eval run detail")
|
|
50
|
+
show.add_argument("id", help="Eval run ID (ev_...)")
|
|
51
|
+
show.set_defaults(func=handle_show)
|
|
52
|
+
|
|
53
|
+
push = sub.add_parser(
|
|
54
|
+
"push",
|
|
55
|
+
help="Push a dspy.Evaluate file to a program as a named eval",
|
|
56
|
+
description=(
|
|
57
|
+
"Stage a file that binds one module-level dspy.Evaluate and push its devset, its metric and "
|
|
58
|
+
"the judges the metric spends. `-` reads the file from stdin. A module-level `lms` dict "
|
|
59
|
+
"declares named judges, and dspy.settings.lm is recorded as judge-lm. Pushing a name again "
|
|
60
|
+
"replaces an eval that never received its bundle."
|
|
61
|
+
),
|
|
62
|
+
)
|
|
63
|
+
push.add_argument("source", help="Python file binding one dspy.Evaluate, or - for stdin")
|
|
64
|
+
push.add_argument("program_name", metavar="PROGRAM", type=programs.program_slot, help="Program name or p_ id")
|
|
65
|
+
push.add_argument("--name", required=True, help="The eval's name under the program")
|
|
66
|
+
_add_source_options(push)
|
|
67
|
+
from . import top
|
|
68
|
+
|
|
69
|
+
push.add_argument(
|
|
70
|
+
"--lm-provider",
|
|
71
|
+
dest="lm_provider",
|
|
72
|
+
metavar="BINDING=NAME",
|
|
73
|
+
type=top._lm_provider_arg,
|
|
74
|
+
action="append",
|
|
75
|
+
default=None,
|
|
76
|
+
help="The provider one judge of the file's `lms` spends, as judge=typesafe. The eval records it, so "
|
|
77
|
+
"every run spends that provider. Repeat it for each judge",
|
|
78
|
+
)
|
|
79
|
+
push.set_defaults(func=handle_push)
|
|
80
|
+
|
|
81
|
+
run = sub.add_parser("run", help="Run a pushed eval on one deployment of its program")
|
|
82
|
+
run.add_argument("program_name", metavar="PROGRAM", type=programs.program_slot, help="Program name or p_ id")
|
|
83
|
+
run.add_argument("eval_name", metavar="EVAL", help="Name of the pushed eval")
|
|
84
|
+
which = run.add_mutually_exclusive_group(required=True)
|
|
85
|
+
which.add_argument("--deployment", metavar="D_ID", help="The deployment (d_...) to score")
|
|
86
|
+
which.add_argument("--tag", help="The tag whose version to score")
|
|
87
|
+
run.set_defaults(func=handle_run)
|
|
88
|
+
|
|
89
|
+
cancel = sub.add_parser("cancel", help="Cancel a running or queued eval run")
|
|
90
|
+
cancel.add_argument("id", help="Eval run ID")
|
|
91
|
+
cancel.set_defaults(func=handle_cancel)
|
|
92
|
+
|
|
93
|
+
# Recording an eval run is deliberately not a command. `POST /evals` and
|
|
94
|
+
# `PATCH /evals/{id}` are the two halves of one handshake the SDK runs
|
|
95
|
+
# around dspy's evaluate: the start mints the id and files a `running`
|
|
96
|
+
# header, the finish supersedes it with the whole record and its examples.
|
|
97
|
+
# The id lives in memory between them, so neither half stands alone — a
|
|
98
|
+
# start with no finish leaves a run `running` forever, and a finish from
|
|
99
|
+
# here replaces what the SDK recorded, examples included. Use the SDK to
|
|
100
|
+
# record an eval; these commands read what it recorded.
|
|
101
|
+
|
|
102
|
+
delete = sub.add_parser("delete", help="Delete an eval run and its examples")
|
|
103
|
+
delete.add_argument("id", help="Eval run ID (ev_...)")
|
|
104
|
+
delete.set_defaults(func=handle_delete)
|
|
105
|
+
|
|
106
|
+
examples = sub.add_parser("examples", help="List an eval run's per-example rows")
|
|
107
|
+
examples.add_argument("id", help="Eval run ID (ev_...)")
|
|
108
|
+
pagination.add_args(examples, with_page_aliases=False, default_limit=100)
|
|
109
|
+
examples.set_defaults(func=handle_examples)
|
|
110
|
+
|
|
111
|
+
# `evals compare` is deliberately absent. The route requires a
|
|
112
|
+
# `dataset_hash`, and no eval read returns one: neither the list nor the
|
|
113
|
+
# detail projection carries it, and nor does the compare response itself.
|
|
114
|
+
# The only surface that emits one is `programs evals`, so the command
|
|
115
|
+
# would ship with a required argument its own noun cannot produce. It goes
|
|
116
|
+
# in once the projection carries the hash.
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
def handle_list(client: api_client.ApiClient, args: Any) -> Any:
|
|
120
|
+
# This route paginates by page/page_size; the shared helper maps the
|
|
121
|
+
# user-facing --limit/--offset onto that pair. `--metric` posts metric — an
|
|
122
|
+
# unread key raises no error on either side of the wire, so the mapping
|
|
123
|
+
# below is what actually applies the filter.
|
|
124
|
+
body: dict[str, Any] = pagination.wire(args, "page_size")
|
|
125
|
+
for attr, key in [
|
|
126
|
+
("program_name", "program_name"),
|
|
127
|
+
("module_class", "module_class"),
|
|
128
|
+
("metric_name", "metric"),
|
|
129
|
+
("status", "status"),
|
|
130
|
+
]:
|
|
131
|
+
val = getattr(args, attr, None)
|
|
132
|
+
if val is not None:
|
|
133
|
+
body[key] = val
|
|
134
|
+
return client.post("/api/v1/evals/search", json=body)
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
def handle_show(client: api_client.ApiClient, args: Any) -> Any:
|
|
138
|
+
return client.get(f"/api/v1/evals/{args.id}")
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
def handle_delete(client: api_client.ApiClient, args: Any) -> Any:
|
|
142
|
+
# 204 No Content -> delete() returns None; synthesize a confirmation.
|
|
143
|
+
client.delete(f"/api/v1/evals/{args.id}")
|
|
144
|
+
return {"deleted": args.id}
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+
def handle_examples(client: api_client.ApiClient, args: Any) -> Any:
|
|
148
|
+
params = pagination.wire(args, "limit_offset", as_str=True)
|
|
149
|
+
return client.get(f"/api/v1/evals/{args.id}/examples", params=params)
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
def handle_push(client: api_client.ApiClient, args: Any) -> Any:
|
|
153
|
+
"""Stage the file in an isolated import, then create the eval and upload its bundle."""
|
|
154
|
+
from ... import _http, authored, program_evals
|
|
155
|
+
|
|
156
|
+
program_id, _ = programs.resolve(client, args.program_name)
|
|
157
|
+
providers = _judge_providers(client, getattr(args, "lm_provider", None) or [])
|
|
158
|
+
try:
|
|
159
|
+
if args.source == "-":
|
|
160
|
+
prepared = authored.prepare_eval_stdin(
|
|
161
|
+
sys.stdin.buffer.read(), api_key=client._api_key, endpoint=client._endpoint
|
|
162
|
+
)
|
|
163
|
+
else:
|
|
164
|
+
prepared = authored.prepare_eval_file(
|
|
165
|
+
Path(args.source),
|
|
166
|
+
source_root=Path(args.source_root) if args.source_root else None,
|
|
167
|
+
includes=[Path(item) for item in args.include],
|
|
168
|
+
api_key=client._api_key,
|
|
169
|
+
endpoint=client._endpoint,
|
|
170
|
+
)
|
|
171
|
+
facts = prepared.facts
|
|
172
|
+
judges = _with_providers(facts.judges, providers)
|
|
173
|
+
pushed = program_evals.publish(
|
|
174
|
+
_http.ApiClient(client._api_key, client._endpoint),
|
|
175
|
+
program_id,
|
|
176
|
+
args.name,
|
|
177
|
+
bundle=prepared.eval_bundle,
|
|
178
|
+
example_count=facts.example_count,
|
|
179
|
+
input_fields=facts.input_fields,
|
|
180
|
+
label_fields=facts.label_fields,
|
|
181
|
+
judges=judges,
|
|
182
|
+
failure_score=facts.failure_score,
|
|
183
|
+
api_key=client._api_key,
|
|
184
|
+
endpoint=client._endpoint,
|
|
185
|
+
)
|
|
186
|
+
except (OSError, ValueError) as exc:
|
|
187
|
+
raise api_client.CliError(str(exc)) from exc
|
|
188
|
+
return {
|
|
189
|
+
"id": pushed.id,
|
|
190
|
+
"name": pushed.name,
|
|
191
|
+
"example_count": pushed.example_count,
|
|
192
|
+
"judges": pushed.judges,
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
def _judge_providers(client: api_client.ApiClient, pairs: list[tuple[str, str]]) -> dict[str, str]:
|
|
197
|
+
"""The provider name each ``--lm-provider`` judge spends, looked up before the file is staged."""
|
|
198
|
+
from . import top
|
|
199
|
+
|
|
200
|
+
lookup = top._ProviderLookup(client)
|
|
201
|
+
found: dict[str, str] = {}
|
|
202
|
+
for binding, name in pairs:
|
|
203
|
+
if binding in found:
|
|
204
|
+
raise api_client.CliError(
|
|
205
|
+
f"--lm-provider names the judge {binding!r} more than once. Give each judge one provider."
|
|
206
|
+
)
|
|
207
|
+
found[binding] = lookup(f"--lm-provider {binding}={name}", name).name
|
|
208
|
+
return found
|
|
209
|
+
|
|
210
|
+
|
|
211
|
+
def _with_providers(judges: dict[str, Any], providers: dict[str, str]) -> dict[str, Any]:
|
|
212
|
+
"""``judges`` with each named judge recording the provider it spends."""
|
|
213
|
+
unknown = sorted(set(providers) - set(judges))
|
|
214
|
+
if unknown:
|
|
215
|
+
raise api_client.CliError(
|
|
216
|
+
f"--lm-provider names {', '.join(unknown)}, which the eval file declares no judge for. "
|
|
217
|
+
f"Its judges are {', '.join(sorted(judges)) or 'none'}."
|
|
218
|
+
)
|
|
219
|
+
return {
|
|
220
|
+
binding: {**entry, "credential": providers[binding]} if binding in providers else entry
|
|
221
|
+
for binding, entry in judges.items()
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
|
|
225
|
+
def handle_run(client: api_client.ApiClient, args: Any) -> Any:
|
|
226
|
+
"""Start the eval on the deployment ``--deployment`` names or ``--tag`` resolves to."""
|
|
227
|
+
from ... import _http, program_evals, versions
|
|
228
|
+
|
|
229
|
+
api = _http.ApiClient(client._api_key, client._endpoint)
|
|
230
|
+
program_id, _ = programs.resolve(client, args.program_name)
|
|
231
|
+
if args.deployment is not None:
|
|
232
|
+
if not args.deployment.startswith("d_"):
|
|
233
|
+
raise api_client.CliError(f"--deployment takes a d_ id, not {args.deployment!r}. Use --tag for a tag.")
|
|
234
|
+
deployment_id = args.deployment
|
|
235
|
+
else:
|
|
236
|
+
if args.program_name.lower().startswith("p_"):
|
|
237
|
+
raise api_client.CliError("--tag resolves under a program name. Pass the name, or use --deployment.")
|
|
238
|
+
deployment_id = versions.resolve_version(api, versions.ProgramAddress(name=args.program_name, tag=args.tag))
|
|
239
|
+
try:
|
|
240
|
+
started = program_evals.run(api, deployment_id, args.eval_name, program_id, args.program_name)
|
|
241
|
+
except program_evals.DeploymentOfAnotherProgram as exc:
|
|
242
|
+
raise api_client.CliError(str(exc)) from None
|
|
243
|
+
return {"eval_run_id": started.id, "status": started.status, "deployment_id": deployment_id}
|
|
244
|
+
|
|
245
|
+
|
|
246
|
+
def handle_cancel(client: api_client.ApiClient, args: Any) -> Any:
|
|
247
|
+
return client.post(f"/api/v1/eval-runs/{args.id}/cancel")
|
|
@@ -1168,7 +1168,7 @@ def _lm_provider_arg(value: str) -> tuple[str, str]:
|
|
|
1168
1168
|
binding, sep, name = value.partition("=")
|
|
1169
1169
|
if not sep or not binding or not name:
|
|
1170
1170
|
raise ArgumentTypeError(
|
|
1171
|
-
f"{value!r} is not BINDING=NAME. Give the name of an LM the
|
|
1171
|
+
f"{value!r} is not BINDING=NAME. Give the name of an LM the file's `lms` binds, then a "
|
|
1172
1172
|
"provider `cmpnd providers list` shows, as in judge=typesafe"
|
|
1173
1173
|
)
|
|
1174
1174
|
from ... import optimization
|
|
@@ -256,6 +256,8 @@ LEGACY_SPELLINGS: dict[str, str] = {
|
|
|
256
256
|
#: An entry admits one command, not the word: another group that wants the word adds
|
|
257
257
|
#: its own entry and its own reason.
|
|
258
258
|
COMMAND_SPELLINGS: dict[tuple[str, ...], str] = {
|
|
259
|
+
("evals", "push"): "the pushed eval's program names it, as `cmpnd deploy` names a program's source; "
|
|
260
|
+
"create would read as recording an eval run, which the SDK alone does",
|
|
259
261
|
("providers", "add"): "the providers page's Add provider button and every model-provider CLI users "
|
|
260
262
|
"know spell it add; create would read as a provider record apart from its key",
|
|
261
263
|
("providers", "remove"): "the pair of providers add, as the providers page spells it",
|
|
@@ -40,6 +40,7 @@ from . import (
|
|
|
40
40
|
credentials,
|
|
41
41
|
identity,
|
|
42
42
|
kernel_lines,
|
|
43
|
+
program_evals,
|
|
43
44
|
programs,
|
|
44
45
|
)
|
|
45
46
|
from .deployment_metadata import DeploymentSignatureResponse
|
|
@@ -1557,6 +1558,61 @@ class Client:
|
|
|
1557
1558
|
self._check_active()
|
|
1558
1559
|
_assessments.delete(assessment_id, api_key=self._config.api_key, endpoint=self._config.endpoint)
|
|
1559
1560
|
|
|
1561
|
+
def push_eval(
|
|
1562
|
+
self, program: str, name: str, evaluate: Any, *, lms: dict[str, Any] | None = None
|
|
1563
|
+
) -> program_evals.ProgramEval:
|
|
1564
|
+
"""Push a ``dspy.Evaluate`` to ``program`` as the platform eval ``name``.
|
|
1565
|
+
|
|
1566
|
+
``program`` is a program name or ``p_`` id. The eval's devset rows must state their
|
|
1567
|
+
inputs with ``with_inputs``, and its metric must be a module-level ``def`` taking
|
|
1568
|
+
``(example, pred)``. The judges the metric spends are ``dspy.settings.lm`` at push time,
|
|
1569
|
+
recorded as ``judge-lm``, and each LM in ``lms``, recorded under its name. The push
|
|
1570
|
+
prints each recorded judge and sends no credential.
|
|
1571
|
+
"""
|
|
1572
|
+
self._check_active()
|
|
1573
|
+
return program_evals.push(
|
|
1574
|
+
_http.ApiClient(self._config.api_key, self._config.endpoint),
|
|
1575
|
+
self._program_id(program),
|
|
1576
|
+
name,
|
|
1577
|
+
evaluate,
|
|
1578
|
+
lms,
|
|
1579
|
+
api_key=self._config.api_key,
|
|
1580
|
+
endpoint=self._config.endpoint,
|
|
1581
|
+
)
|
|
1582
|
+
|
|
1583
|
+
def list_evals(self, program: str) -> list[program_evals.ProgramEval]:
|
|
1584
|
+
"""The ready evals of ``program``, a program name or ``p_`` id."""
|
|
1585
|
+
self._check_active()
|
|
1586
|
+
return program_evals.list_evals(
|
|
1587
|
+
_http.ApiClient(self._config.api_key, self._config.endpoint), self._program_id(program)
|
|
1588
|
+
)
|
|
1589
|
+
|
|
1590
|
+
def run_eval(self, program: str, name: str, deployment: Any) -> program_evals.EvalRun:
|
|
1591
|
+
"""Start the eval ``name`` on ``deployment``, a ``d_`` id, a deployed program or a ``ProgramAddress``.
|
|
1592
|
+
|
|
1593
|
+
``program`` names the program the eval was pushed to, and ``deployment`` must be one of its
|
|
1594
|
+
versions: serve refuses another program's deployment, raised as ``ValueError``. A key with
|
|
1595
|
+
``evals:run`` starts it. The run starts ``running`` or ``queued``.
|
|
1596
|
+
"""
|
|
1597
|
+
self._check_active()
|
|
1598
|
+
api = _http.ApiClient(self._config.api_key, self._config.endpoint)
|
|
1599
|
+
deployment_id = self._deployment_id(deployment)
|
|
1600
|
+
return program_evals.run(api, deployment_id, name, self._program_id(program), program)
|
|
1601
|
+
|
|
1602
|
+
def get_eval_run(self, run: Any) -> program_evals.EvalRun:
|
|
1603
|
+
"""The state of an eval run, from its ``EvalRun`` or id."""
|
|
1604
|
+
self._check_active()
|
|
1605
|
+
return program_evals.get_run(
|
|
1606
|
+
_http.ApiClient(self._config.api_key, self._config.endpoint), getattr(run, "id", run)
|
|
1607
|
+
)
|
|
1608
|
+
|
|
1609
|
+
def cancel_eval(self, run: Any) -> program_evals.EvalRun:
|
|
1610
|
+
"""Cancel an eval run, from its ``EvalRun`` or id."""
|
|
1611
|
+
self._check_active()
|
|
1612
|
+
return program_evals.cancel(
|
|
1613
|
+
_http.ApiClient(self._config.api_key, self._config.endpoint), getattr(run, "id", run)
|
|
1614
|
+
)
|
|
1615
|
+
|
|
1560
1616
|
def create_valset(self, program: str, *, name: str | None = None) -> dict[str, Any]:
|
|
1561
1617
|
"""Create a valset owned by ``program``, a program name or ``p_`` id; name auto-assigned when omitted."""
|
|
1562
1618
|
self._check_active()
|
|
@@ -510,6 +510,10 @@ def _reflection_config(config: dict[str, Any], reflection_lm: Any) -> None:
|
|
|
510
510
|
# the other and neither may be dropped in favour of it.
|
|
511
511
|
DEFAULT_LM_BINDING = "default-lm"
|
|
512
512
|
|
|
513
|
+
# Names the platform fills itself: the program's model, a run's reflection model and an
|
|
514
|
+
# eval's recorded default judge. A caller's binding never takes one.
|
|
515
|
+
RESERVED_LM_BINDINGS = (DEFAULT_LM_BINDING, "reflection-lm", "judge-lm")
|
|
516
|
+
|
|
513
517
|
|
|
514
518
|
def _lms_config(config: dict[str, Any], lms: Any) -> None:
|
|
515
519
|
"""Merge the run's named LMs into ``config["lms"]``, as the wire's declaration shape.
|
|
@@ -582,6 +586,12 @@ def _lms_config(config: dict[str, Any], lms: Any) -> None:
|
|
|
582
586
|
"binding something else — every other name is yours, and it is the name your "
|
|
583
587
|
"metric selects it by."
|
|
584
588
|
)
|
|
589
|
+
if name in RESERVED_LM_BINDINGS:
|
|
590
|
+
raise ValueError(
|
|
591
|
+
f"{name!r} is a name the platform reserves for its own binding. Name this "
|
|
592
|
+
"binding something else; every other name is yours, and it is the name your "
|
|
593
|
+
"metric selects it by."
|
|
594
|
+
)
|
|
585
595
|
from .lm_configuration import HostedLM, lm_binding, refuse_stated_model_type
|
|
586
596
|
|
|
587
597
|
subject = f"lms[{name!r}]"
|
|
@@ -949,6 +959,15 @@ def _stated_inputs(example: Any) -> list[str] | None:
|
|
|
949
959
|
return None
|
|
950
960
|
|
|
951
961
|
|
|
962
|
+
def lm_restore_preamble(declarations: dict[str, Any]) -> str:
|
|
963
|
+
"""The lines a packaged metric or proposer ends with to restore the run's LM declarations.
|
|
964
|
+
|
|
965
|
+
The kernel reads a binding's protocol from these declarations, so a System One binding
|
|
966
|
+
becomes a System One client.
|
|
967
|
+
"""
|
|
968
|
+
return f"from cmpnd.lm_configuration import restore as _restore_lms\n_restore_lms({declarations!r})\n"
|
|
969
|
+
|
|
970
|
+
|
|
952
971
|
def _build_optimization_bundle(
|
|
953
972
|
trainset: list[dict[str, dict[str, Any]]],
|
|
954
973
|
valset: list[dict[str, dict[str, Any]]],
|
|
@@ -980,8 +999,7 @@ def _build_optimization_bundle(
|
|
|
980
999
|
)
|
|
981
1000
|
|
|
982
1001
|
if lm_capabilities:
|
|
983
|
-
preamble =
|
|
984
|
-
preamble += f"_restore_lms({lm_capabilities!r})\n"
|
|
1002
|
+
preamble = lm_restore_preamble(lm_capabilities)
|
|
985
1003
|
metric_source += "\n" + preamble
|
|
986
1004
|
if proposer_source is not None:
|
|
987
1005
|
proposer_source += "\n" + preamble
|