agentloop-profiler 0.2.7__tar.gz → 0.2.9__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.
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/PKG-INFO +6 -5
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/README.md +5 -4
- agentloop_profiler-0.2.9/agentloop/ci_runs.py +104 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/cli.py +119 -13
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/client.py +33 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/doctor.py +120 -5
- agentloop_profiler-0.2.9/agentloop/http_security.py +57 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/migrations.py +19 -0
- agentloop_profiler-0.2.9/agentloop/request_limits.py +102 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/server.py +83 -5
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/store.py +215 -26
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/version.py +1 -1
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop_profiler.egg-info/PKG-INFO +6 -5
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop_profiler.egg-info/SOURCES.txt +8 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/dashboard/app.py +211 -63
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/pyproject.toml +2 -2
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_ci_evidence.py +23 -0
- agentloop_profiler-0.2.9/tests/test_ci_runs.py +107 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_cli_store_commands.py +30 -0
- agentloop_profiler-0.2.9/tests/test_cli_upload.py +96 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_client.py +26 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dashboard_project_access.py +71 -0
- agentloop_profiler-0.2.9/tests/test_dashboard_runs_dir.py +56 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_doctor_autoinstrument.py +62 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_finding_identity.py +2 -1
- agentloop_profiler-0.2.9/tests/test_http_security.py +77 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_migrations.py +2 -2
- agentloop_profiler-0.2.9/tests/test_request_limits.py +91 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_server.py +46 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_store_contract.py +85 -1
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/LICENSE +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/THIRD_PARTY_LICENSES.md +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/__init__.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/ablation_protocol.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/ablations.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/aggregate_cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/aggregate_stats.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/aggregates.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/audit.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/autoinstrument.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/batch_experiments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/batching.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/budget_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/budgets.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/calibration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/checkpoint_state.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/checkpoint_store.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/ci.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/cli_paths.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/completion.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/completion_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/config.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/context_controls.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/context_experiments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/context_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/costs.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/cursor_validation.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/decorators.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/demo.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/drift.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/drift_cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/drift_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/drift_windows.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/entrypoint.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/estimates.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/events.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/experiment_artifacts.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/experiment_observations.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/experiment_reports.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/experiment_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/experiments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/exporters.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/finding_benchmark_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/finding_benchmarks.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/findings.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/graph.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/harness.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/harness_bench/__init__.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/harness_bench/cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/harness_bench/drivers.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/harness_bench/offline.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/harness_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/harness_usage.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/html_report.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/improvement.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/improvement_cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/improvement_init.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/improvement_report.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/improvement_verifier.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/__init__.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/crewai.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/harbor/__init__.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/harbor/atif.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/harbor/atif_validation.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/harbor/cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/harbor/manifest.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/harbor/trial_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/harbor/trials.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/harbor/verifier.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/hermes.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/hermes_cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/hermes_recorder.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/langgraph.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/langgraph_harness.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/langgraph_recovery.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/omnigent/__init__.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/omnigent/cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/omnigent/evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/omnigent/telemetry.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/openai.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/openai_agents.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/sdk.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/integrations/vercel_ai.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/__init__.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/artifacts.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/cohort_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/cohorts.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/contracts.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/coordination.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/otlp_jsonl.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/otlp_validation.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/registry.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interoperability/validation.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/intervention_service.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/intervention_store.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/interventions.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/issues.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/judgment_adapters.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/judgment_benchmark_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/judgment_benchmarks.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/judgment_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/judgment_views.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/judgments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/loop_guards.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/loop_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/markdown.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/metrics.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/model_routing.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/onboarding.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/operations.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/optimizer.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/otel.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/otel_ids.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/otel_semantics.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/parallelism.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/patches.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/plan_export.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/policy_promotion.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/promotion_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/promotion_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/quality.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/ranking.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/recovery_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/repetitions.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/replay.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/retention.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/retention_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/reuse_experiments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/routing_checks.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/routing_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/rules.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/runners/__init__.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/runners/_common.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/runners/claude_code.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/runners/codex.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/runtime.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/savings.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/scheduling_plan.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/scheduling_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/schema.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/semantic_rules.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/semantic_waste.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/semantic_waste_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/structural_experiments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/structural_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/structured_quality.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/studies.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/study_statistics.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/substitution_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/substitution_export.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/substitution_reports.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/substitution_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/substitutions.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/timing.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/tokens.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/tool_scheduling.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/trace_sources.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/tracer.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/value.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/workflow_types.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop/workflows.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop_profiler.egg-info/dependency_links.txt +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop_profiler.egg-info/entry_points.txt +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop_profiler.egg-info/requires.txt +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/agentloop_profiler.egg-info/top_level.txt +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/dashboard/__init__.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/dashboard/access.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/dashboard/streamlit_compat.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/dashboard/trace_upload.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/dashboard/value_view.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/setup.cfg +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_ablations.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_aggregates.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_api_versioning.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_batch_data_pipeline.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_budgets.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_bump_version.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_calibration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_capability_registry.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_checkpoint_recovery.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_ci_command.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_claude_code_runner.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_cli_output_paths.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_cli_trace_inputs.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_client_transport.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_codex_exec_runner.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_completion.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_context_controls.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_context_reuse_experiments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_context_study.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_costs.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_crewai_integration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_cursor_server.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_cursor_shape_validation.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dashboard_input_validation.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dashboard_quality.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dashboard_semantic_waste.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dashboard_structured_quality.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dashboard_trace_upload.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dashboard_value_view.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dashboard_workflows.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_decorators.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_demo_cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_dependabot_config.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_diagnosis_api.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_distribution_metadata.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_docs_site.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_drift.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_email_workflow.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_empirical_calibration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_enforcement_conformance.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_estimates.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_evidence_workflow.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_experiments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_exporters.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_external_cohorts.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_finding_benchmarks.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_finding_rules.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_first_use_cli.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_graph.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_guided_validation.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_guided_verifier.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_harbor_atif.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_harbor_trials.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_harness.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_harness_bench.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_harness_error_usage.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_harness_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_hermes_integration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_hermes_replay_capture.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_hermes_repository_example.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_hermes_runtime_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_html_report.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_improvement.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_improvement_init.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_incident_triage.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_instrumentation_measurement.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_integration_conformance.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_interoperability_contracts.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_interventions.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_issues.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_judgment_adapters.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_judgment_benchmarks.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_judgment_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_judgment_provider_optional.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_judgments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_langgraph_conformance.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_langgraph_harness.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_langgraph_integration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_langgraph_recovery.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_loop_guards.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_markdown.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_markdown_exporters.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_marketplace_workflow.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_metrics.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_model_batching.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_model_routing.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_multiagent_coordination.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_non_agent_study.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_omnigent_telemetry.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_onboarding.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_openai_agents_integration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_openai_integration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_operations.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_optimizer.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_otel_ids.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_otel_interop.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_otlp_jsonl.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_parallelization_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_patch_plan.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_patch_source_scope.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_payment_review.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_policy_promotion.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_published_readme.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_python_support.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_quality.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_ranking.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_real_agent_study.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_real_calibration_study.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_real_harness_study.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_release_workflows.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_remote_cli_credentials.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_repetitions.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_replay.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_repository_policy_traversal.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_research_example.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_retention.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_retry_recommendations.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_routing_study.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_rule_error_privacy.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_runtime.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_savings_aggregation.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_scheduling_study.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_semantic_findings.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_semantic_waste.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_standalone_notices.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_store.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_streaming_inventory.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_streamlit_compat.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_structural_experiments.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_structured_quality.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_structured_quality_evidence.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_studies.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_substitutions.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_telemetry_conformance.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_timing.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_token_provenance.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_tool_scheduling.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_trace_context.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_trace_failure_recording.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_trace_schema.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_usefulness_benchmark.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_value.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_vercel_ai_integration.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_workflow_storage.py +0 -0
- {agentloop_profiler-0.2.7 → agentloop_profiler-0.2.9}/tests/test_workflows.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: agentloop-profiler
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.9
|
|
4
4
|
Summary: Profiler and optimization layer for AI agent execution graphs
|
|
5
5
|
Author: Dipesh Tharu Mahato
|
|
6
6
|
License-Expression: Apache-2.0
|
|
@@ -484,7 +484,8 @@ docker compose -f deploy/docker-compose.yml up --detach
|
|
|
484
484
|
CI runs this exact stack over HTTPS on every change. The
|
|
485
485
|
[cloud deployment guide](https://dipeshbabu.github.io/agentloop/CLOUD_DEPLOY/)
|
|
486
486
|
covers server setup, API keys, upgrades, backups, and managed platforms such as
|
|
487
|
-
Cloud Run, App Runner, ECS and Azure Container Apps.
|
|
487
|
+
Cloud Run, App Runner, ECS and Azure Container Apps. Kubernetes manifests are in
|
|
488
|
+
`deploy/kubernetes/`; see the [Kubernetes guide](https://dipeshbabu.github.io/agentloop/KUBERNETES/).
|
|
488
489
|
|
|
489
490
|
## Dashboard and persistence
|
|
490
491
|
|
|
@@ -533,13 +534,13 @@ where the examples show `agentloop`.
|
|
|
533
534
|
<summary>Download and verify a standalone executable</summary>
|
|
534
535
|
|
|
535
536
|
Download the executable and `SHA256SUMS` from the same release. These examples use
|
|
536
|
-
version 0.2.
|
|
537
|
+
version 0.2.9. Change the version when choosing another release.
|
|
537
538
|
|
|
538
539
|
Linux (Bash):
|
|
539
540
|
|
|
540
541
|
```bash
|
|
541
542
|
set -euo pipefail
|
|
542
|
-
version=0.2.
|
|
543
|
+
version=0.2.9
|
|
543
544
|
asset="agentloop-v${version}-linux-x86_64"
|
|
544
545
|
curl --fail --location --remote-name "https://github.com/dipeshbabu/agentloop/releases/download/v${version}/${asset}"
|
|
545
546
|
curl --fail --location --remote-name "https://github.com/dipeshbabu/agentloop/releases/download/v${version}/SHA256SUMS"
|
|
@@ -556,7 +557,7 @@ chmod +x "$asset"
|
|
|
556
557
|
Windows PowerShell:
|
|
557
558
|
|
|
558
559
|
```powershell
|
|
559
|
-
$Version = "0.2.
|
|
560
|
+
$Version = "0.2.9"
|
|
560
561
|
$Asset = "agentloop-v$Version-windows-x86_64.exe"
|
|
561
562
|
Invoke-WebRequest "https://github.com/dipeshbabu/agentloop/releases/download/v$Version/$Asset" -OutFile agentloop.exe
|
|
562
563
|
Invoke-WebRequest "https://github.com/dipeshbabu/agentloop/releases/download/v$Version/SHA256SUMS" -OutFile SHA256SUMS
|
|
@@ -426,7 +426,8 @@ docker compose -f deploy/docker-compose.yml up --detach
|
|
|
426
426
|
CI runs this exact stack over HTTPS on every change. The
|
|
427
427
|
[cloud deployment guide](https://dipeshbabu.github.io/agentloop/CLOUD_DEPLOY/)
|
|
428
428
|
covers server setup, API keys, upgrades, backups, and managed platforms such as
|
|
429
|
-
Cloud Run, App Runner, ECS and Azure Container Apps.
|
|
429
|
+
Cloud Run, App Runner, ECS and Azure Container Apps. Kubernetes manifests are in
|
|
430
|
+
`deploy/kubernetes/`; see the [Kubernetes guide](https://dipeshbabu.github.io/agentloop/KUBERNETES/).
|
|
430
431
|
|
|
431
432
|
## Dashboard and persistence
|
|
432
433
|
|
|
@@ -475,13 +476,13 @@ where the examples show `agentloop`.
|
|
|
475
476
|
<summary>Download and verify a standalone executable</summary>
|
|
476
477
|
|
|
477
478
|
Download the executable and `SHA256SUMS` from the same release. These examples use
|
|
478
|
-
version 0.2.
|
|
479
|
+
version 0.2.9. Change the version when choosing another release.
|
|
479
480
|
|
|
480
481
|
Linux (Bash):
|
|
481
482
|
|
|
482
483
|
```bash
|
|
483
484
|
set -euo pipefail
|
|
484
|
-
version=0.2.
|
|
485
|
+
version=0.2.9
|
|
485
486
|
asset="agentloop-v${version}-linux-x86_64"
|
|
486
487
|
curl --fail --location --remote-name "https://github.com/dipeshbabu/agentloop/releases/download/v${version}/${asset}"
|
|
487
488
|
curl --fail --location --remote-name "https://github.com/dipeshbabu/agentloop/releases/download/v${version}/SHA256SUMS"
|
|
@@ -498,7 +499,7 @@ chmod +x "$asset"
|
|
|
498
499
|
Windows PowerShell:
|
|
499
500
|
|
|
500
501
|
```powershell
|
|
501
|
-
$Version = "0.2.
|
|
502
|
+
$Version = "0.2.9"
|
|
502
503
|
$Asset = "agentloop-v$Version-windows-x86_64.exe"
|
|
503
504
|
Invoke-WebRequest "https://github.com/dipeshbabu/agentloop/releases/download/v$Version/$Asset" -OutFile agentloop.exe
|
|
504
505
|
Invoke-WebRequest "https://github.com/dipeshbabu/agentloop/releases/download/v$Version/SHA256SUMS" -OutFile SHA256SUMS
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"""Group traces uploaded by CI into runs and pair each run's baseline and candidate.
|
|
2
|
+
|
|
3
|
+
The reusable comparison workflow labels uploaded traces with ``workflow_run``,
|
|
4
|
+
``condition`` (``baseline`` or ``candidate``), ``commit``, ``ref`` and
|
|
5
|
+
``repository``. These helpers read those labels back so a run's comparison can
|
|
6
|
+
be opened without picking traces by hand.
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
from __future__ import annotations
|
|
10
|
+
|
|
11
|
+
from typing import Any
|
|
12
|
+
|
|
13
|
+
from agentloop.store import MAX_PAGE_SIZE
|
|
14
|
+
from agentloop.tracer import AgentTrace
|
|
15
|
+
|
|
16
|
+
RUN_LABEL = "workflow_run"
|
|
17
|
+
CONDITION_LABEL = "condition"
|
|
18
|
+
CONDITIONS = ("baseline", "candidate")
|
|
19
|
+
CONTEXT_LABELS = ("repository", "commit", "ref")
|
|
20
|
+
DEFAULT_SCAN = 500
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
class CIRunNotFoundError(LookupError):
|
|
24
|
+
"""The project has no complete baseline/candidate pair for a CI run."""
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def _pages(store, project_id: str, *, label=None, scan: int = DEFAULT_SCAN):
|
|
28
|
+
cursor = None
|
|
29
|
+
seen = 0
|
|
30
|
+
while seen < scan:
|
|
31
|
+
page = store.list_traces_page(
|
|
32
|
+
project_id=project_id,
|
|
33
|
+
limit=min(MAX_PAGE_SIZE, scan - seen),
|
|
34
|
+
cursor=cursor,
|
|
35
|
+
label=label,
|
|
36
|
+
)
|
|
37
|
+
yield from page["items"]
|
|
38
|
+
seen += len(page["items"])
|
|
39
|
+
cursor = page["next_cursor"]
|
|
40
|
+
if not cursor or not page["items"]:
|
|
41
|
+
return
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def list_ci_runs(store, project_id: str, *, scan: int = DEFAULT_SCAN) -> list[dict[str, Any]]:
|
|
45
|
+
"""CI runs among a project's newest ``scan`` traces, newest run first.
|
|
46
|
+
|
|
47
|
+
Each run lists the newest baseline and candidate run IDs it uploaded (or
|
|
48
|
+
``None``), its repository, commit and ref, and whether it can be compared.
|
|
49
|
+
"""
|
|
50
|
+
if not isinstance(scan, int) or isinstance(scan, bool) or scan < 1:
|
|
51
|
+
raise ValueError("scan must be a positive number of traces")
|
|
52
|
+
runs: dict[str, dict[str, Any]] = {}
|
|
53
|
+
for item in _pages(store, project_id, scan=scan):
|
|
54
|
+
labels = item.get("labels") or {}
|
|
55
|
+
run = labels.get(RUN_LABEL)
|
|
56
|
+
if not isinstance(run, str) or not run:
|
|
57
|
+
continue
|
|
58
|
+
entry = runs.setdefault(
|
|
59
|
+
run,
|
|
60
|
+
{
|
|
61
|
+
RUN_LABEL: run,
|
|
62
|
+
**{name: None for name in CONTEXT_LABELS},
|
|
63
|
+
"baseline_run_id": None,
|
|
64
|
+
"candidate_run_id": None,
|
|
65
|
+
"latest_upload": item.get("created_at"),
|
|
66
|
+
"traces": 0,
|
|
67
|
+
},
|
|
68
|
+
)
|
|
69
|
+
entry["traces"] += 1
|
|
70
|
+
for name in CONTEXT_LABELS:
|
|
71
|
+
if entry[name] is None and isinstance(labels.get(name), str):
|
|
72
|
+
entry[name] = labels[name]
|
|
73
|
+
condition = labels.get(CONDITION_LABEL)
|
|
74
|
+
if condition in CONDITIONS and entry[f"{condition}_run_id"] is None:
|
|
75
|
+
# Listings are newest first, so the first match is the newest upload.
|
|
76
|
+
entry[f"{condition}_run_id"] = item["run_id"]
|
|
77
|
+
for entry in runs.values():
|
|
78
|
+
entry["comparable"] = bool(entry["baseline_run_id"] and entry["candidate_run_id"])
|
|
79
|
+
return list(runs.values())
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
def ci_run_pair(
|
|
83
|
+
store, project_id: str, workflow_run: str, *, scan: int = DEFAULT_SCAN
|
|
84
|
+
) -> tuple[AgentTrace, AgentTrace]:
|
|
85
|
+
"""Load the newest baseline and candidate traces uploaded by one CI run."""
|
|
86
|
+
found: dict[str, str] = {}
|
|
87
|
+
for item in _pages(store, project_id, label=(RUN_LABEL, workflow_run), scan=scan):
|
|
88
|
+
condition = (item.get("labels") or {}).get(CONDITION_LABEL)
|
|
89
|
+
if condition in CONDITIONS and condition not in found:
|
|
90
|
+
found[condition] = item["run_id"]
|
|
91
|
+
if len(found) == len(CONDITIONS):
|
|
92
|
+
break
|
|
93
|
+
missing = [condition for condition in CONDITIONS if condition not in found]
|
|
94
|
+
if missing:
|
|
95
|
+
raise CIRunNotFoundError(
|
|
96
|
+
f"CI run {workflow_run} has no {' or '.join(missing)} trace in this project"
|
|
97
|
+
)
|
|
98
|
+
traces = []
|
|
99
|
+
for condition in CONDITIONS:
|
|
100
|
+
trace = store.get_trace(run_id=found[condition], project_id=project_id)
|
|
101
|
+
if trace is None:
|
|
102
|
+
raise CIRunNotFoundError(f"The {condition} trace of CI run {workflow_run} was deleted")
|
|
103
|
+
traces.append(trace)
|
|
104
|
+
return traces[0], traces[1]
|
|
@@ -56,9 +56,12 @@ from agentloop.ranking import RankingSort, sort_ranked
|
|
|
56
56
|
from agentloop.replay import ReplayGates, build_replay_report, replay_report_to_markdown
|
|
57
57
|
from agentloop.store import (
|
|
58
58
|
DEFAULT_PAGE_SIZE,
|
|
59
|
+
LABEL_KEY_PATTERN,
|
|
60
|
+
MAX_LABEL_VALUE_LENGTH,
|
|
59
61
|
FindingNotFoundError,
|
|
60
62
|
FindingTransitionError,
|
|
61
63
|
get_store,
|
|
64
|
+
parse_label_filter,
|
|
62
65
|
)
|
|
63
66
|
from agentloop.studies import StudyValidationError, study_to_markdown, summarize_study
|
|
64
67
|
from agentloop.timing import format_duration_ms
|
|
@@ -983,7 +986,7 @@ def init_store() -> None:
|
|
|
983
986
|
@app.command("create-api-key")
|
|
984
987
|
def create_api_key(project_id: str = "default", name: str = "default") -> None:
|
|
985
988
|
db = get_store()
|
|
986
|
-
key = db.create_api_key(project_id=project_id, name=name)
|
|
989
|
+
key = db.create_api_key(project_id=project_id, name=name, actor="cli")
|
|
987
990
|
console.print("Created API key. Save it now; it will not be shown again.")
|
|
988
991
|
console.print(key["api_key"])
|
|
989
992
|
|
|
@@ -1003,7 +1006,7 @@ def revoke_api_key(
|
|
|
1003
1006
|
) -> None:
|
|
1004
1007
|
"""Revoke a project's API key; it stops working immediately."""
|
|
1005
1008
|
try:
|
|
1006
|
-
revoked = get_store().revoke_api_key(project_id, prefix)
|
|
1009
|
+
revoked = get_store().revoke_api_key(project_id, prefix, actor="cli")
|
|
1007
1010
|
except ValueError as exc:
|
|
1008
1011
|
raise typer.BadParameter(str(exc)) from exc
|
|
1009
1012
|
if not revoked:
|
|
@@ -1020,7 +1023,7 @@ def delete_trace(
|
|
|
1020
1023
|
project_id: str = "default",
|
|
1021
1024
|
) -> None:
|
|
1022
1025
|
"""Delete a stored trace with its findings, usage and interventions."""
|
|
1023
|
-
deleted = get_store().delete_trace(run_id, project_id)
|
|
1026
|
+
deleted = get_store().delete_trace(run_id, project_id, actor="cli")
|
|
1024
1027
|
if deleted is None:
|
|
1025
1028
|
console.print(f"No trace {run_id} in project {project_id}.", markup=False)
|
|
1026
1029
|
raise typer.Exit(1)
|
|
@@ -1038,6 +1041,7 @@ def purge_traces(
|
|
|
1038
1041
|
project_id: str | None = typer.Option(None, help="Only purge this project."),
|
|
1039
1042
|
) -> None:
|
|
1040
1043
|
"""Apply a retention period: delete traces stored longer ago than allowed."""
|
|
1044
|
+
actor = "cli" if older_than_days is not None else "retention:AGENTLOOP_RETENTION_DAYS"
|
|
1041
1045
|
if older_than_days is None:
|
|
1042
1046
|
configured = os.getenv("AGENTLOOP_RETENTION_DAYS", "").strip()
|
|
1043
1047
|
if not configured:
|
|
@@ -1054,7 +1058,7 @@ def purge_traces(
|
|
|
1054
1058
|
param_hint="AGENTLOOP_RETENTION_DAYS",
|
|
1055
1059
|
) from None
|
|
1056
1060
|
try:
|
|
1057
|
-
deleted = get_store().purge_traces(older_than_days, project_id=project_id)
|
|
1061
|
+
deleted = get_store().purge_traces(older_than_days, project_id=project_id, actor=actor)
|
|
1058
1062
|
except ValueError as exc:
|
|
1059
1063
|
raise typer.BadParameter(str(exc)) from exc
|
|
1060
1064
|
scope = f"project {project_id}" if project_id else "all projects"
|
|
@@ -1067,6 +1071,20 @@ def purge_traces(
|
|
|
1067
1071
|
)
|
|
1068
1072
|
|
|
1069
1073
|
|
|
1074
|
+
@app.command("audit-log")
|
|
1075
|
+
def audit_log(
|
|
1076
|
+
project_id: str | None = typer.Option(None, help="Only this project's events."),
|
|
1077
|
+
limit: int = typer.Option(50, min=1, max=1000, help="Newest events to show."),
|
|
1078
|
+
) -> None:
|
|
1079
|
+
"""Show recent key, deletion and retention events from the store's audit log."""
|
|
1080
|
+
console.print_json(
|
|
1081
|
+
data={
|
|
1082
|
+
"project_id": project_id,
|
|
1083
|
+
"events": get_store().list_audit_events(project_id, limit=limit),
|
|
1084
|
+
}
|
|
1085
|
+
)
|
|
1086
|
+
|
|
1087
|
+
|
|
1070
1088
|
@app.command("store-trace")
|
|
1071
1089
|
def store_trace(
|
|
1072
1090
|
path: Path = Path("runs/research_agent_baseline.json"),
|
|
@@ -1085,14 +1103,24 @@ def list_stored_traces(
|
|
|
1085
1103
|
cursor: str | None = typer.Option(
|
|
1086
1104
|
None, help="Continuation cursor from a previous --limit call's printed next-cursor."
|
|
1087
1105
|
),
|
|
1106
|
+
label: str | None = typer.Option(
|
|
1107
|
+
None, help="Only traces with this KEY=VALUE label, such as commit=abc123."
|
|
1108
|
+
),
|
|
1088
1109
|
) -> None:
|
|
1089
1110
|
db = get_store()
|
|
1090
|
-
|
|
1111
|
+
try:
|
|
1112
|
+
label_filter = parse_label_filter(label) if label is not None else None
|
|
1113
|
+
except ValueError as exc:
|
|
1114
|
+
raise typer.BadParameter(str(exc), param_hint="--label") from exc
|
|
1115
|
+
if limit is None and cursor is None and label_filter is None:
|
|
1091
1116
|
traces = db.list_traces(project_id=project_id)
|
|
1092
1117
|
next_cursor = None
|
|
1093
1118
|
else:
|
|
1094
1119
|
page = db.list_traces_page(
|
|
1095
|
-
project_id=project_id,
|
|
1120
|
+
project_id=project_id,
|
|
1121
|
+
limit=limit or DEFAULT_PAGE_SIZE,
|
|
1122
|
+
cursor=cursor,
|
|
1123
|
+
label=label_filter,
|
|
1096
1124
|
)
|
|
1097
1125
|
traces = page["items"]
|
|
1098
1126
|
next_cursor = page["next_cursor"]
|
|
@@ -1102,8 +1130,11 @@ def list_stored_traces(
|
|
|
1102
1130
|
table.add_column("Name")
|
|
1103
1131
|
table.add_column("Runtime ms")
|
|
1104
1132
|
table.add_column("Cost")
|
|
1133
|
+
show_labels = any(item.get("labels") for item in traces)
|
|
1134
|
+
if show_labels:
|
|
1135
|
+
table.add_column("Labels")
|
|
1105
1136
|
for item in traces:
|
|
1106
|
-
|
|
1137
|
+
row = [
|
|
1107
1138
|
str(item.get("project_id", "")),
|
|
1108
1139
|
str(item.get("run_id", "")),
|
|
1109
1140
|
str(item.get("name", "")),
|
|
@@ -1111,7 +1142,11 @@ def list_stored_traces(
|
|
|
1111
1142
|
if item.get("total_runtime_ms") is None
|
|
1112
1143
|
else f"{float(item.get('total_runtime_ms', 0)):.2f}",
|
|
1113
1144
|
format_cost_usd(item.get("estimated_cost_usd"), item.get("cost_status", "complete")),
|
|
1114
|
-
|
|
1145
|
+
]
|
|
1146
|
+
if show_labels:
|
|
1147
|
+
labels = item.get("labels") or {}
|
|
1148
|
+
row.append(", ".join(f"{key}={value}" for key, value in sorted(labels.items())))
|
|
1149
|
+
table.add_row(*row, end_section=False)
|
|
1115
1150
|
console.print(table)
|
|
1116
1151
|
if next_cursor:
|
|
1117
1152
|
console.print(f"More results available. Next cursor: {next_cursor}")
|
|
@@ -1270,19 +1305,76 @@ def usage_summary(project_id: str | None = None) -> None:
|
|
|
1270
1305
|
console.print(table)
|
|
1271
1306
|
|
|
1272
1307
|
|
|
1308
|
+
def _parse_labels(values: list[str] | None) -> dict[str, str]:
|
|
1309
|
+
labels: dict[str, str] = {}
|
|
1310
|
+
for value in values or []:
|
|
1311
|
+
key, separator, text = value.partition("=")
|
|
1312
|
+
if not separator or not LABEL_KEY_PATTERN.match(key):
|
|
1313
|
+
raise typer.BadParameter(
|
|
1314
|
+
"Use KEY=VALUE with a key of letters, digits, '.', '_' or '-'",
|
|
1315
|
+
param_hint="--label",
|
|
1316
|
+
)
|
|
1317
|
+
if len(text) > MAX_LABEL_VALUE_LENGTH:
|
|
1318
|
+
raise typer.BadParameter(
|
|
1319
|
+
f"Label values are limited to {MAX_LABEL_VALUE_LENGTH} characters",
|
|
1320
|
+
param_hint="--label",
|
|
1321
|
+
)
|
|
1322
|
+
labels[key] = text
|
|
1323
|
+
return labels
|
|
1324
|
+
|
|
1325
|
+
|
|
1326
|
+
def _upload_files(paths: list[Path]) -> list[Path]:
|
|
1327
|
+
files: list[Path] = []
|
|
1328
|
+
for path in paths:
|
|
1329
|
+
if path.is_dir():
|
|
1330
|
+
found = sorted(item for item in path.glob("*.json") if item.is_file())
|
|
1331
|
+
if not found:
|
|
1332
|
+
raise typer.BadParameter(
|
|
1333
|
+
f"No .json trace files in directory {path}", param_hint="--path"
|
|
1334
|
+
)
|
|
1335
|
+
files.extend(found)
|
|
1336
|
+
else:
|
|
1337
|
+
files.append(path)
|
|
1338
|
+
return files
|
|
1339
|
+
|
|
1340
|
+
|
|
1273
1341
|
@app.command()
|
|
1274
1342
|
def upload(
|
|
1275
|
-
path: Path =
|
|
1343
|
+
path: list[Path] = typer.Option(
|
|
1344
|
+
[Path("runs/research_agent_baseline.json")],
|
|
1345
|
+
"--path",
|
|
1346
|
+
help="Trace JSON file, or a directory of them; repeat for several.",
|
|
1347
|
+
),
|
|
1348
|
+
label: list[str] | None = typer.Option(
|
|
1349
|
+
None,
|
|
1350
|
+
"--label",
|
|
1351
|
+
help="KEY=VALUE stored under metadata.labels of each uploaded trace, "
|
|
1352
|
+
"such as commit=abc123; repeat for several.",
|
|
1353
|
+
),
|
|
1276
1354
|
api_url: str = typer.Option("http://127.0.0.1:8000", help="AgentLoop API base URL."),
|
|
1277
1355
|
api_key: str | None = typer.Option(
|
|
1278
1356
|
None, help="Optional API key. Defaults to AGENTLOOP_API_KEY."
|
|
1279
1357
|
),
|
|
1280
1358
|
) -> None:
|
|
1281
|
-
|
|
1359
|
+
"""Upload traces to an AgentLoop API, optionally labelled with CI context."""
|
|
1360
|
+
labels = _parse_labels(label)
|
|
1361
|
+
files = _upload_files(path)
|
|
1362
|
+
traces = [_load_trace(file, param_hint="--path") for file in files]
|
|
1282
1363
|
client = _remote_client(api_url, api_key)
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1364
|
+
project = None
|
|
1365
|
+
for trace in traces:
|
|
1366
|
+
if labels:
|
|
1367
|
+
existing = trace.metadata.get("labels")
|
|
1368
|
+
trace.metadata["labels"] = {
|
|
1369
|
+
**(existing if isinstance(existing, dict) else {}),
|
|
1370
|
+
**labels,
|
|
1371
|
+
}
|
|
1372
|
+
response = client.upload_trace(trace)
|
|
1373
|
+
project = response.get("project_id", "default")
|
|
1374
|
+
console.print(f"Uploaded trace {response['run_id']} to {api_url}", markup=False)
|
|
1375
|
+
if len(traces) > 1:
|
|
1376
|
+
console.print(f"Uploaded {len(traces)} traces.", markup=False)
|
|
1377
|
+
console.print(f"Project: {project}", markup=False)
|
|
1286
1378
|
|
|
1287
1379
|
|
|
1288
1380
|
@app.command("remote-delete-trace")
|
|
@@ -1438,6 +1530,20 @@ def remote_list_api_keys(
|
|
|
1438
1530
|
console.print_json(data=client.list_api_keys(project_id))
|
|
1439
1531
|
|
|
1440
1532
|
|
|
1533
|
+
@app.command("remote-audit-log")
|
|
1534
|
+
def remote_audit_log(
|
|
1535
|
+
project_id: str | None = typer.Option(None, help="Only this project's events."),
|
|
1536
|
+
limit: int = typer.Option(50, min=1, max=1000, help="Newest events to show."),
|
|
1537
|
+
api_url: str = typer.Option("http://127.0.0.1:8000", help="AgentLoop API base URL."),
|
|
1538
|
+
admin_api_key: str | None = typer.Option(
|
|
1539
|
+
None, help="Admin API key. Defaults to AGENTLOOP_ADMIN_API_KEY."
|
|
1540
|
+
),
|
|
1541
|
+
) -> None:
|
|
1542
|
+
"""Show a remote server's audit log (admin key required)."""
|
|
1543
|
+
client = _remote_admin_client(api_url, admin_api_key)
|
|
1544
|
+
console.print_json(data=client.list_audit_events(project_id=project_id, limit=limit))
|
|
1545
|
+
|
|
1546
|
+
|
|
1441
1547
|
@app.command("remote-revoke-api-key")
|
|
1442
1548
|
def remote_revoke_api_key(
|
|
1443
1549
|
prefix: str = typer.Option(..., help="First 10 characters of the key, as listed."),
|
|
@@ -59,6 +59,15 @@ class AgentLoopClient:
|
|
|
59
59
|
credential_scope="admin",
|
|
60
60
|
)
|
|
61
61
|
|
|
62
|
+
def list_audit_events(self, project_id: str | None = None, limit: int = 100) -> dict[str, Any]:
|
|
63
|
+
"""Newest audit events first, optionally for one project (admin key required)."""
|
|
64
|
+
params: dict[str, Any] = {"limit": limit}
|
|
65
|
+
if project_id:
|
|
66
|
+
params["project_id"] = project_id
|
|
67
|
+
return self._request(
|
|
68
|
+
"GET", "/audit-events?" + urllib.parse.urlencode(params), credential_scope="admin"
|
|
69
|
+
)
|
|
70
|
+
|
|
62
71
|
def list_api_keys(self, project_id: str) -> dict[str, Any]:
|
|
63
72
|
"""List a project's key prefixes, names and usage times (admin key required)."""
|
|
64
73
|
return self._request(
|
|
@@ -93,6 +102,7 @@ class AgentLoopClient:
|
|
|
93
102
|
*,
|
|
94
103
|
page_size: int | None = None,
|
|
95
104
|
cursor: str | None = None,
|
|
105
|
+
label: str | None = None,
|
|
96
106
|
) -> dict[str, Any]:
|
|
97
107
|
params: dict[str, Any] = {}
|
|
98
108
|
if project_id:
|
|
@@ -101,11 +111,34 @@ class AgentLoopClient:
|
|
|
101
111
|
params["page_size"] = page_size
|
|
102
112
|
if cursor:
|
|
103
113
|
params["cursor"] = cursor
|
|
114
|
+
if label is not None:
|
|
115
|
+
params["label"] = label
|
|
104
116
|
route = "/traces"
|
|
105
117
|
if params:
|
|
106
118
|
route += "?" + urllib.parse.urlencode(params)
|
|
107
119
|
return self._request("GET", route)
|
|
108
120
|
|
|
121
|
+
def list_ci_runs(self, scan: int = 500) -> dict[str, Any]:
|
|
122
|
+
"""CI runs among this key's project's newest uploads, by workflow_run label."""
|
|
123
|
+
return self._request("GET", "/ci-runs?" + urllib.parse.urlencode({"scan": scan}))
|
|
124
|
+
|
|
125
|
+
def compare_ci_run(
|
|
126
|
+
self,
|
|
127
|
+
workflow_run: str,
|
|
128
|
+
*,
|
|
129
|
+
min_latency_improvement_pct: float = 0.0,
|
|
130
|
+
min_cost_improvement_pct: float = 0.0,
|
|
131
|
+
) -> dict[str, Any]:
|
|
132
|
+
"""Replay comparison and PR Markdown for one CI run's baseline and candidate."""
|
|
133
|
+
params = urllib.parse.urlencode(
|
|
134
|
+
{
|
|
135
|
+
"min_latency_improvement_pct": min_latency_improvement_pct,
|
|
136
|
+
"min_cost_improvement_pct": min_cost_improvement_pct,
|
|
137
|
+
}
|
|
138
|
+
)
|
|
139
|
+
encoded = urllib.parse.quote(workflow_run, safe="")
|
|
140
|
+
return self._request("GET", f"/ci-runs/{encoded}/comparison?{params}")
|
|
141
|
+
|
|
109
142
|
def usage_summary(self, project_id: str | None = None) -> dict[str, Any]:
|
|
110
143
|
route = "/usage"
|
|
111
144
|
if project_id:
|
|
@@ -105,6 +105,86 @@ def _ready_check(api_url: str, timeout: float = 2.0) -> DoctorCheck:
|
|
|
105
105
|
return _fail("api_ready", f"Could not reach {url}: {exc}")
|
|
106
106
|
|
|
107
107
|
|
|
108
|
+
def _is_local_origin(origin: str) -> bool:
|
|
109
|
+
host = urlsplit(origin).hostname or ""
|
|
110
|
+
return host in {"localhost", "127.0.0.1", "::1"} or host.endswith(".localhost")
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
def _hosting_policy_checks() -> list[DoctorCheck]:
|
|
114
|
+
"""Checks for settings added for shared deployments (0.2.7 and newer)."""
|
|
115
|
+
from agentloop.http_security import API_DOCS_VARIABLE, api_docs_enabled
|
|
116
|
+
from agentloop.request_limits import ENVIRONMENT_VARIABLE, max_request_bytes
|
|
117
|
+
|
|
118
|
+
checks: list[DoctorCheck] = []
|
|
119
|
+
try:
|
|
120
|
+
docs = api_docs_enabled()
|
|
121
|
+
except ValueError as exc:
|
|
122
|
+
checks.append(_fail("api_docs", str(exc), f"Set {API_DOCS_VARIABLE}=false."))
|
|
123
|
+
else:
|
|
124
|
+
if docs:
|
|
125
|
+
checks.append(
|
|
126
|
+
_warn(
|
|
127
|
+
"api_docs",
|
|
128
|
+
"/docs, /redoc and /openapi.json describe every route publicly",
|
|
129
|
+
f"Set {API_DOCS_VARIABLE}=false on internet-facing API servers.",
|
|
130
|
+
)
|
|
131
|
+
)
|
|
132
|
+
else:
|
|
133
|
+
checks.append(_ok("api_docs", "interactive API docs disabled"))
|
|
134
|
+
try:
|
|
135
|
+
limit = max_request_bytes()
|
|
136
|
+
except ValueError as exc:
|
|
137
|
+
checks.append(_fail("request_size_limit", str(exc), f"Fix {ENVIRONMENT_VARIABLE}."))
|
|
138
|
+
else:
|
|
139
|
+
if limit is None:
|
|
140
|
+
checks.append(
|
|
141
|
+
_warn(
|
|
142
|
+
"request_size_limit",
|
|
143
|
+
"disabled; request bodies of any size are read into memory",
|
|
144
|
+
f"Unset {ENVIRONMENT_VARIABLE} for the 16 MiB default or set a size.",
|
|
145
|
+
)
|
|
146
|
+
)
|
|
147
|
+
else:
|
|
148
|
+
checks.append(_ok("request_size_limit", f"{limit} bytes"))
|
|
149
|
+
|
|
150
|
+
if _env_enabled("AGENTLOOP_DASHBOARD_REQUIRE_KEY"):
|
|
151
|
+
checks.append(_ok("dashboard_access", "project API key sign-in required"))
|
|
152
|
+
else:
|
|
153
|
+
checks.append(
|
|
154
|
+
_warn(
|
|
155
|
+
"dashboard_access",
|
|
156
|
+
"the dashboard shows any project to anyone who can reach it",
|
|
157
|
+
"Set AGENTLOOP_DASHBOARD_REQUIRE_KEY=true on the dashboard service.",
|
|
158
|
+
)
|
|
159
|
+
)
|
|
160
|
+
|
|
161
|
+
retention = os.getenv("AGENTLOOP_RETENTION_DAYS", "").strip()
|
|
162
|
+
if not retention:
|
|
163
|
+
checks.append(
|
|
164
|
+
_warn(
|
|
165
|
+
"retention",
|
|
166
|
+
"not configured; traces are kept until deleted by hand",
|
|
167
|
+
"Set AGENTLOOP_RETENTION_DAYS and run agentloop purge-traces on a schedule.",
|
|
168
|
+
)
|
|
169
|
+
)
|
|
170
|
+
else:
|
|
171
|
+
try:
|
|
172
|
+
days = float(retention)
|
|
173
|
+
except ValueError:
|
|
174
|
+
days = -1.0
|
|
175
|
+
if days > 0 and days == days and days != float("inf"):
|
|
176
|
+
checks.append(_ok("retention", f"{days:g} days"))
|
|
177
|
+
else:
|
|
178
|
+
checks.append(
|
|
179
|
+
_fail(
|
|
180
|
+
"retention",
|
|
181
|
+
f"AGENTLOOP_RETENTION_DAYS={retention!r} is not a positive number of days",
|
|
182
|
+
"Set it to a positive number of days, or unset it.",
|
|
183
|
+
)
|
|
184
|
+
)
|
|
185
|
+
return checks
|
|
186
|
+
|
|
187
|
+
|
|
108
188
|
def _env_enabled(name: str) -> bool:
|
|
109
189
|
return os.getenv(name, "").lower() in {"1", "true", "yes", "on"}
|
|
110
190
|
|
|
@@ -115,14 +195,14 @@ def run_doctor(*, check_api: bool = True, runs_dir: Path | str = "runs") -> dict
|
|
|
115
195
|
checks: list[DoctorCheck] = []
|
|
116
196
|
|
|
117
197
|
py_version = sys.version_info
|
|
118
|
-
if py_version >= (3,
|
|
198
|
+
if py_version >= (3, 11):
|
|
119
199
|
checks.append(_ok("python", f"Python {platform.python_version()}"))
|
|
120
200
|
else:
|
|
121
201
|
checks.append(
|
|
122
202
|
_fail(
|
|
123
203
|
"python",
|
|
124
204
|
f"Python {platform.python_version()} is too old",
|
|
125
|
-
"Use Python 3.
|
|
205
|
+
"Use Python 3.11 or newer.",
|
|
126
206
|
)
|
|
127
207
|
)
|
|
128
208
|
|
|
@@ -220,14 +300,14 @@ def run_production_check(
|
|
|
220
300
|
checks: list[DoctorCheck] = []
|
|
221
301
|
|
|
222
302
|
py_version = sys.version_info
|
|
223
|
-
if py_version >= (3,
|
|
303
|
+
if py_version >= (3, 11):
|
|
224
304
|
checks.append(_ok("python", f"Python {platform.python_version()}"))
|
|
225
305
|
else:
|
|
226
306
|
checks.append(
|
|
227
307
|
_fail(
|
|
228
308
|
"python",
|
|
229
309
|
f"Python {platform.python_version()} is too old",
|
|
230
|
-
"Use Python 3.
|
|
310
|
+
"Use Python 3.11 or newer.",
|
|
231
311
|
)
|
|
232
312
|
)
|
|
233
313
|
|
|
@@ -313,7 +393,42 @@ def run_production_check(
|
|
|
313
393
|
)
|
|
314
394
|
)
|
|
315
395
|
else:
|
|
316
|
-
|
|
396
|
+
insecure = [
|
|
397
|
+
origin
|
|
398
|
+
for origin in cors_origins
|
|
399
|
+
if not origin.startswith("https://") and not _is_local_origin(origin)
|
|
400
|
+
]
|
|
401
|
+
if insecure and not allow_http:
|
|
402
|
+
checks.append(
|
|
403
|
+
_fail(
|
|
404
|
+
"cors_origins",
|
|
405
|
+
f"non-HTTPS origins: {', '.join(insecure)}",
|
|
406
|
+
"Serve the dashboard over HTTPS and list its https:// origin.",
|
|
407
|
+
)
|
|
408
|
+
)
|
|
409
|
+
elif insecure:
|
|
410
|
+
checks.append(
|
|
411
|
+
_warn(
|
|
412
|
+
"cors_origins",
|
|
413
|
+
f"non-HTTPS origins: {', '.join(insecure)}",
|
|
414
|
+
"Use HTTPS origins for production traffic.",
|
|
415
|
+
)
|
|
416
|
+
)
|
|
417
|
+
else:
|
|
418
|
+
checks.append(_ok("cors_origins", ", ".join(cors_origins)))
|
|
419
|
+
|
|
420
|
+
if os.getenv("AGENTLOOP_API_KEY"):
|
|
421
|
+
checks.append(
|
|
422
|
+
_warn(
|
|
423
|
+
"shared_api_key",
|
|
424
|
+
"AGENTLOOP_API_KEY grants access to project 'default'; it cannot be revoked, "
|
|
425
|
+
"listed or attributed in the audit log",
|
|
426
|
+
"Unset AGENTLOOP_API_KEY on the server and give each team a project key "
|
|
427
|
+
"created with the admin key.",
|
|
428
|
+
)
|
|
429
|
+
)
|
|
430
|
+
|
|
431
|
+
checks.extend(_hosting_policy_checks())
|
|
317
432
|
|
|
318
433
|
api_url = os.getenv("AGENTLOOP_API_URL", "")
|
|
319
434
|
if not api_url:
|