agentloop-profiler 0.2.6__tar.gz → 0.2.7__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.
Files changed (340) hide show
  1. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/PKG-INFO +85 -13
  2. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/README.md +84 -12
  3. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/cli.py +123 -0
  4. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/client.py +24 -0
  5. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/improvement.py +38 -11
  6. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/improvement_cli.py +17 -6
  7. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/improvement_init.py +269 -26
  8. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/server.py +40 -0
  9. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/store.py +200 -0
  10. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/version.py +1 -1
  11. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop_profiler.egg-info/PKG-INFO +85 -13
  12. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop_profiler.egg-info/SOURCES.txt +2 -0
  13. agentloop_profiler-0.2.7/dashboard/access.py +103 -0
  14. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/dashboard/app.py +104 -25
  15. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/pyproject.toml +1 -1
  16. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_cli_store_commands.py +61 -0
  17. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_client.py +62 -0
  18. agentloop_profiler-0.2.7/tests/test_dashboard_project_access.py +199 -0
  19. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_improvement.py +35 -3
  20. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_improvement_init.py +88 -0
  21. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_server.py +63 -0
  22. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_store_contract.py +112 -0
  23. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/LICENSE +0 -0
  24. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/THIRD_PARTY_LICENSES.md +0 -0
  25. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/__init__.py +0 -0
  26. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/ablation_protocol.py +0 -0
  27. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/ablations.py +0 -0
  28. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/aggregate_cli.py +0 -0
  29. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/aggregate_stats.py +0 -0
  30. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/aggregates.py +0 -0
  31. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/audit.py +0 -0
  32. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/autoinstrument.py +0 -0
  33. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/batch_experiments.py +0 -0
  34. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/batching.py +0 -0
  35. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/budget_types.py +0 -0
  36. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/budgets.py +0 -0
  37. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/calibration.py +0 -0
  38. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/checkpoint_state.py +0 -0
  39. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/checkpoint_store.py +0 -0
  40. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/ci.py +0 -0
  41. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/cli_paths.py +0 -0
  42. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/completion.py +0 -0
  43. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/completion_types.py +0 -0
  44. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/config.py +0 -0
  45. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/context_controls.py +0 -0
  46. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/context_experiments.py +0 -0
  47. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/context_types.py +0 -0
  48. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/costs.py +0 -0
  49. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/cursor_validation.py +0 -0
  50. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/decorators.py +0 -0
  51. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/demo.py +0 -0
  52. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/doctor.py +0 -0
  53. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/drift.py +0 -0
  54. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/drift_cli.py +0 -0
  55. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/drift_types.py +0 -0
  56. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/drift_windows.py +0 -0
  57. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/entrypoint.py +0 -0
  58. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/estimates.py +0 -0
  59. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/events.py +0 -0
  60. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/experiment_artifacts.py +0 -0
  61. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/experiment_observations.py +0 -0
  62. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/experiment_reports.py +0 -0
  63. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/experiment_types.py +0 -0
  64. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/experiments.py +0 -0
  65. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/exporters.py +0 -0
  66. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/finding_benchmark_types.py +0 -0
  67. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/finding_benchmarks.py +0 -0
  68. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/findings.py +0 -0
  69. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/graph.py +0 -0
  70. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/harness.py +0 -0
  71. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/harness_bench/__init__.py +0 -0
  72. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/harness_bench/cli.py +0 -0
  73. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/harness_bench/drivers.py +0 -0
  74. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/harness_bench/offline.py +0 -0
  75. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/harness_evidence.py +0 -0
  76. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/harness_usage.py +0 -0
  77. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/html_report.py +0 -0
  78. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/improvement_report.py +0 -0
  79. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/improvement_verifier.py +0 -0
  80. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/__init__.py +0 -0
  81. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/crewai.py +0 -0
  82. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/harbor/__init__.py +0 -0
  83. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/harbor/atif.py +0 -0
  84. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/harbor/atif_validation.py +0 -0
  85. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/harbor/cli.py +0 -0
  86. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/harbor/manifest.py +0 -0
  87. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/harbor/trial_evidence.py +0 -0
  88. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/harbor/trials.py +0 -0
  89. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/harbor/verifier.py +0 -0
  90. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/hermes.py +0 -0
  91. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/hermes_cli.py +0 -0
  92. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/hermes_recorder.py +0 -0
  93. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/langgraph.py +0 -0
  94. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/langgraph_harness.py +0 -0
  95. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/langgraph_recovery.py +0 -0
  96. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/omnigent/__init__.py +0 -0
  97. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/omnigent/cli.py +0 -0
  98. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/omnigent/evidence.py +0 -0
  99. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/omnigent/telemetry.py +0 -0
  100. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/openai.py +0 -0
  101. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/openai_agents.py +0 -0
  102. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/sdk.py +0 -0
  103. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/integrations/vercel_ai.py +0 -0
  104. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/__init__.py +0 -0
  105. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/artifacts.py +0 -0
  106. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/cli.py +0 -0
  107. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/cohort_evidence.py +0 -0
  108. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/cohorts.py +0 -0
  109. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/contracts.py +0 -0
  110. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/coordination.py +0 -0
  111. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/evidence.py +0 -0
  112. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/otlp_jsonl.py +0 -0
  113. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/otlp_validation.py +0 -0
  114. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/registry.py +0 -0
  115. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interoperability/validation.py +0 -0
  116. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/intervention_service.py +0 -0
  117. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/intervention_store.py +0 -0
  118. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/interventions.py +0 -0
  119. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/issues.py +0 -0
  120. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/judgment_adapters.py +0 -0
  121. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/judgment_benchmark_types.py +0 -0
  122. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/judgment_benchmarks.py +0 -0
  123. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/judgment_types.py +0 -0
  124. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/judgment_views.py +0 -0
  125. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/judgments.py +0 -0
  126. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/loop_guards.py +0 -0
  127. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/loop_types.py +0 -0
  128. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/markdown.py +0 -0
  129. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/metrics.py +0 -0
  130. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/migrations.py +0 -0
  131. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/model_routing.py +0 -0
  132. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/onboarding.py +0 -0
  133. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/operations.py +0 -0
  134. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/optimizer.py +0 -0
  135. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/otel.py +0 -0
  136. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/otel_ids.py +0 -0
  137. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/otel_semantics.py +0 -0
  138. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/parallelism.py +0 -0
  139. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/patches.py +0 -0
  140. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/plan_export.py +0 -0
  141. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/policy_promotion.py +0 -0
  142. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/promotion_evidence.py +0 -0
  143. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/promotion_types.py +0 -0
  144. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/quality.py +0 -0
  145. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/ranking.py +0 -0
  146. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/recovery_evidence.py +0 -0
  147. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/repetitions.py +0 -0
  148. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/replay.py +0 -0
  149. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/retention.py +0 -0
  150. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/retention_types.py +0 -0
  151. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/reuse_experiments.py +0 -0
  152. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/routing_checks.py +0 -0
  153. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/routing_types.py +0 -0
  154. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/rules.py +0 -0
  155. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/runners/__init__.py +0 -0
  156. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/runners/_common.py +0 -0
  157. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/runners/claude_code.py +0 -0
  158. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/runners/codex.py +0 -0
  159. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/runtime.py +0 -0
  160. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/savings.py +0 -0
  161. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/scheduling_plan.py +0 -0
  162. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/scheduling_types.py +0 -0
  163. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/schema.py +0 -0
  164. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/semantic_rules.py +0 -0
  165. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/semantic_waste.py +0 -0
  166. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/semantic_waste_types.py +0 -0
  167. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/structural_experiments.py +0 -0
  168. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/structural_types.py +0 -0
  169. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/structured_quality.py +0 -0
  170. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/studies.py +0 -0
  171. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/study_statistics.py +0 -0
  172. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/substitution_evidence.py +0 -0
  173. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/substitution_export.py +0 -0
  174. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/substitution_reports.py +0 -0
  175. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/substitution_types.py +0 -0
  176. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/substitutions.py +0 -0
  177. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/timing.py +0 -0
  178. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/tokens.py +0 -0
  179. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/tool_scheduling.py +0 -0
  180. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/trace_sources.py +0 -0
  181. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/tracer.py +0 -0
  182. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/value.py +0 -0
  183. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/workflow_types.py +0 -0
  184. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop/workflows.py +0 -0
  185. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop_profiler.egg-info/dependency_links.txt +0 -0
  186. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop_profiler.egg-info/entry_points.txt +0 -0
  187. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop_profiler.egg-info/requires.txt +0 -0
  188. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/agentloop_profiler.egg-info/top_level.txt +0 -0
  189. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/dashboard/__init__.py +0 -0
  190. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/dashboard/streamlit_compat.py +0 -0
  191. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/dashboard/trace_upload.py +0 -0
  192. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/dashboard/value_view.py +0 -0
  193. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/setup.cfg +0 -0
  194. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_ablations.py +0 -0
  195. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_aggregates.py +0 -0
  196. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_api_versioning.py +0 -0
  197. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_batch_data_pipeline.py +0 -0
  198. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_budgets.py +0 -0
  199. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_bump_version.py +0 -0
  200. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_calibration.py +0 -0
  201. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_capability_registry.py +0 -0
  202. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_checkpoint_recovery.py +0 -0
  203. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_ci_command.py +0 -0
  204. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_ci_evidence.py +0 -0
  205. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_claude_code_runner.py +0 -0
  206. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_cli_output_paths.py +0 -0
  207. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_cli_trace_inputs.py +0 -0
  208. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_client_transport.py +0 -0
  209. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_codex_exec_runner.py +0 -0
  210. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_completion.py +0 -0
  211. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_context_controls.py +0 -0
  212. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_context_reuse_experiments.py +0 -0
  213. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_context_study.py +0 -0
  214. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_costs.py +0 -0
  215. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_crewai_integration.py +0 -0
  216. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_cursor_server.py +0 -0
  217. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_cursor_shape_validation.py +0 -0
  218. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_dashboard_input_validation.py +0 -0
  219. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_dashboard_quality.py +0 -0
  220. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_dashboard_semantic_waste.py +0 -0
  221. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_dashboard_structured_quality.py +0 -0
  222. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_dashboard_trace_upload.py +0 -0
  223. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_dashboard_value_view.py +0 -0
  224. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_dashboard_workflows.py +0 -0
  225. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_decorators.py +0 -0
  226. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_demo_cli.py +0 -0
  227. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_dependabot_config.py +0 -0
  228. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_diagnosis_api.py +0 -0
  229. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_distribution_metadata.py +0 -0
  230. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_docs_site.py +0 -0
  231. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_doctor_autoinstrument.py +0 -0
  232. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_drift.py +0 -0
  233. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_email_workflow.py +0 -0
  234. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_empirical_calibration.py +0 -0
  235. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_enforcement_conformance.py +0 -0
  236. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_estimates.py +0 -0
  237. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_evidence_workflow.py +0 -0
  238. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_experiments.py +0 -0
  239. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_exporters.py +0 -0
  240. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_external_cohorts.py +0 -0
  241. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_finding_benchmarks.py +0 -0
  242. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_finding_identity.py +0 -0
  243. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_finding_rules.py +0 -0
  244. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_first_use_cli.py +0 -0
  245. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_graph.py +0 -0
  246. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_guided_validation.py +0 -0
  247. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_guided_verifier.py +0 -0
  248. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_harbor_atif.py +0 -0
  249. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_harbor_trials.py +0 -0
  250. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_harness.py +0 -0
  251. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_harness_bench.py +0 -0
  252. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_harness_error_usage.py +0 -0
  253. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_harness_evidence.py +0 -0
  254. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_hermes_integration.py +0 -0
  255. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_hermes_replay_capture.py +0 -0
  256. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_hermes_repository_example.py +0 -0
  257. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_hermes_runtime_evidence.py +0 -0
  258. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_html_report.py +0 -0
  259. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_incident_triage.py +0 -0
  260. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_instrumentation_measurement.py +0 -0
  261. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_integration_conformance.py +0 -0
  262. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_interoperability_contracts.py +0 -0
  263. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_interventions.py +0 -0
  264. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_issues.py +0 -0
  265. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_judgment_adapters.py +0 -0
  266. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_judgment_benchmarks.py +0 -0
  267. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_judgment_evidence.py +0 -0
  268. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_judgment_provider_optional.py +0 -0
  269. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_judgments.py +0 -0
  270. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_langgraph_conformance.py +0 -0
  271. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_langgraph_harness.py +0 -0
  272. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_langgraph_integration.py +0 -0
  273. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_langgraph_recovery.py +0 -0
  274. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_loop_guards.py +0 -0
  275. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_markdown.py +0 -0
  276. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_markdown_exporters.py +0 -0
  277. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_marketplace_workflow.py +0 -0
  278. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_metrics.py +0 -0
  279. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_migrations.py +0 -0
  280. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_model_batching.py +0 -0
  281. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_model_routing.py +0 -0
  282. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_multiagent_coordination.py +0 -0
  283. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_non_agent_study.py +0 -0
  284. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_omnigent_telemetry.py +0 -0
  285. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_onboarding.py +0 -0
  286. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_openai_agents_integration.py +0 -0
  287. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_openai_integration.py +0 -0
  288. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_operations.py +0 -0
  289. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_optimizer.py +0 -0
  290. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_otel_ids.py +0 -0
  291. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_otel_interop.py +0 -0
  292. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_otlp_jsonl.py +0 -0
  293. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_parallelization_evidence.py +0 -0
  294. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_patch_plan.py +0 -0
  295. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_patch_source_scope.py +0 -0
  296. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_payment_review.py +0 -0
  297. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_policy_promotion.py +0 -0
  298. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_published_readme.py +0 -0
  299. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_python_support.py +0 -0
  300. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_quality.py +0 -0
  301. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_ranking.py +0 -0
  302. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_real_agent_study.py +0 -0
  303. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_real_calibration_study.py +0 -0
  304. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_real_harness_study.py +0 -0
  305. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_release_workflows.py +0 -0
  306. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_remote_cli_credentials.py +0 -0
  307. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_repetitions.py +0 -0
  308. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_replay.py +0 -0
  309. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_repository_policy_traversal.py +0 -0
  310. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_research_example.py +0 -0
  311. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_retention.py +0 -0
  312. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_retry_recommendations.py +0 -0
  313. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_routing_study.py +0 -0
  314. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_rule_error_privacy.py +0 -0
  315. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_runtime.py +0 -0
  316. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_savings_aggregation.py +0 -0
  317. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_scheduling_study.py +0 -0
  318. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_semantic_findings.py +0 -0
  319. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_semantic_waste.py +0 -0
  320. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_standalone_notices.py +0 -0
  321. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_store.py +0 -0
  322. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_streaming_inventory.py +0 -0
  323. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_streamlit_compat.py +0 -0
  324. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_structural_experiments.py +0 -0
  325. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_structured_quality.py +0 -0
  326. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_structured_quality_evidence.py +0 -0
  327. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_studies.py +0 -0
  328. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_substitutions.py +0 -0
  329. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_telemetry_conformance.py +0 -0
  330. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_timing.py +0 -0
  331. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_token_provenance.py +0 -0
  332. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_tool_scheduling.py +0 -0
  333. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_trace_context.py +0 -0
  334. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_trace_failure_recording.py +0 -0
  335. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_trace_schema.py +0 -0
  336. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_usefulness_benchmark.py +0 -0
  337. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_value.py +0 -0
  338. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_vercel_ai_integration.py +0 -0
  339. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/tests/test_workflow_storage.py +0 -0
  340. {agentloop_profiler-0.2.6 → agentloop_profiler-0.2.7}/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.6
3
+ Version: 0.2.7
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
@@ -71,6 +71,7 @@ Dynamic: license-file
71
71
  <p align="center">
72
72
  <a href="https://github.com/dipeshbabu/agentloop/actions/workflows/ci.yml"><img src="https://github.com/dipeshbabu/agentloop/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
73
73
  <a href="https://pypi.org/project/agentloop-profiler/"><img src="https://img.shields.io/pypi/v/agentloop-profiler.svg?cacheSeconds=300" alt="PyPI"></a>
74
+ <a href="https://www.npmjs.com/package/agentloop-profiler"><img src="https://img.shields.io/npm/v/agentloop-profiler.svg?cacheSeconds=300" alt="npm"></a>
74
75
  <a href="https://pepy.tech/projects/agentloop-profiler"><img src="https://static.pepy.tech/badge/agentloop-profiler/month" alt="Downloads/month"></a>
75
76
  <a href="https://www.python.org/downloads/"><img src="https://img.shields.io/badge/python-3.11%2B-3776AB.svg" alt="Python 3.11 or newer"></a>
76
77
  <a href="https://github.com/dipeshbabu/agentloop/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-Apache--2.0-blue.svg" alt="License: Apache-2.0"></a>
@@ -78,11 +79,13 @@ Dynamic: license-file
78
79
 
79
80
  <p align="center">
80
81
  <a href="https://dipeshbabu.github.io/agentloop/">Documentation</a> ·
82
+ <a href="#install">Install</a> ·
81
83
  <a href="#quickstart">Quickstart</a> ·
82
84
  <a href="#guided-optimization">Improve an agent</a> ·
83
85
  <a href="#record-your-own-run">Trace your code</a> ·
84
86
  <a href="#compare-before-and-after">Compare runs</a> ·
85
87
  <a href="#framework-integrations">Integrations</a> ·
88
+ <a href="#deploy-to-the-cloud">Deploy</a> ·
86
89
  <a href="https://dipeshbabu.github.io/agentloop/FIRST_USE/">Guide</a>
87
90
  </p>
88
91
 
@@ -95,13 +98,24 @@ The core Python SDK and CLI work with JSON files. You can trace and analyze your
95
98
  code without a hosted account or database. A dashboard, HTTP API, and shared
96
99
  storage are available as optional components.
97
100
 
98
- For Node.js and browser applications, the source checkout includes a
99
- [TypeScript SDK](https://github.com/dipeshbabu/agentloop/blob/main/sdk/typescript/README.md) with native tracing and an API v1 client.
100
- It has no runtime dependencies and installs with `npm install agentloop-profiler`.
101
+ ## Install
102
+
103
+ AgentLoop is published as `agentloop-profiler` on PyPI and on npm.
104
+
105
+ | Install | For | Requires |
106
+ | --- | --- | --- |
107
+ | `python -m pip install agentloop-profiler` | Python SDK and the `agentloop` CLI, which analyzes traces, writes reports and runs the guided workflow | Python 3.11+ |
108
+ | `npm install agentloop-profiler` | [TypeScript SDK](https://github.com/dipeshbabu/agentloop/blob/main/sdk/typescript/README.md) for Node.js and browser code: native tracing and an API v1 client, with no runtime dependencies | Node.js 22+ |
109
+ | [Standalone executable](#standalone-cli) | The `agentloop` CLI without installing Python | Linux, macOS or Windows |
110
+
111
+ The two packages are versioned separately and share the trace format, so traces
112
+ recorded with the TypeScript SDK are analyzed with the `agentloop` CLI. See the
113
+ [installation guide](https://dipeshbabu.github.io/agentloop/installation/) for
114
+ virtual environments, optional extras and installing from source.
101
115
 
102
116
  ## Quickstart
103
117
 
104
- Install with Python 3.11 or newer:
118
+ Install the Python package and record an example trace:
105
119
 
106
120
  ```bash
107
121
  python -m pip install agentloop-profiler
@@ -112,9 +126,9 @@ agentloop analyze runs/agentloop_quickstart.json --html runs/report.html --json-
112
126
  Open `runs/report.html` in your browser to inspect the timeline and findings.
113
127
  `runs/analysis.json` contains the trace, metrics, diagnosis, and optimization plan.
114
128
 
115
- The package name is `agentloop-profiler`; the Python import and CLI command are
116
- both `agentloop`. `quickstart` creates a labeled synthetic trace and makes no model
117
- API calls. It tests your installation, not your application's performance.
129
+ The Python import and CLI command are both `agentloop`. `quickstart` creates a
130
+ labeled synthetic trace and makes no model API calls. It tests your installation,
131
+ not your application's performance.
118
132
 
119
133
  If your shell cannot find `agentloop`, activate the Python environment where you
120
134
  installed it. Run `agentloop doctor` to check the installation and available adapters.
@@ -174,7 +188,9 @@ for those agents.
174
188
 
175
189
  To connect your application, run `agentloop improve init --agent my_agent:answer`
176
190
  in its project directory. The generated adapter supports synchronous and async
177
- Python callables. Replace the example task inputs and expected outputs with
191
+ Python callables. For a Node.js agent, run
192
+ `agentloop improve init --language node --agent ./src/agent.mjs:answer`; see
193
+ [connecting a Node.js agent](https://dipeshbabu.github.io/agentloop/GUIDED_OPTIMIZATION/#connect-an-existing-nodejs-agent). Replace the example task inputs and expected outputs with
178
194
  independent checks for your agent, and keep your model and tool instrumentation.
179
195
  Initialization refuses to overwrite existing files. Read the generated
180
196
  `AGENTLOOP.md` and [onboarding guide](https://dipeshbabu.github.io/agentloop/GUIDED_OPTIMIZATION/).
@@ -236,6 +252,40 @@ Saving `metadata["output"]` is an explicit choice in this example. Review the
236
252
  inputs, outputs, errors, and metadata you retain before sharing real traces.
237
253
  See [trace retention](https://dipeshbabu.github.io/agentloop/TRACE_RETENTION/) for capture controls.
238
254
 
255
+ ### From TypeScript or JavaScript
256
+
257
+ After `npm install agentloop-profiler`, save this as `example_agent.mjs`:
258
+
259
+ ```javascript
260
+ import { writeFile } from "node:fs/promises";
261
+ import { AgentTrace } from "agentloop-profiler";
262
+
263
+ const NOTES = {
264
+ tracing: "Record the steps in a workflow.",
265
+ optimization: "Investigate repeated or expensive work.",
266
+ };
267
+
268
+ const trace = new AgentTrace("research_agent", { metadata: { synthetic: true } });
269
+ const notes = [];
270
+ for (const topic of Object.keys(NOTES)) {
271
+ notes.push(await trace.tool("lookup_note", async () => NOTES[topic]));
272
+ }
273
+ trace.setOutput({ notes });
274
+ trace.finish();
275
+ await writeFile("research_agent_js.json", trace.toJSONString());
276
+ ```
277
+
278
+ Run it and analyze the trace with the `agentloop` CLI:
279
+
280
+ ```bash
281
+ node example_agent.mjs
282
+ agentloop analyze research_agent_js.json --html research_agent_js.html
283
+ ```
284
+
285
+ The SDK also records model calls with provider token usage, retries and nested
286
+ spans, and can send traces to the HTTP API. See the
287
+ [TypeScript SDK guide](https://dipeshbabu.github.io/agentloop/reference/typescript/).
288
+
239
289
  ## Inspect findings
240
290
 
241
291
  For a fixed task set, use the [guided workflow](#guided-optimization) to capture
@@ -365,6 +415,8 @@ gate. Run `agentloop COMMAND --help` to see its output options and thresholds.
365
415
  | Source | Integration path |
366
416
  | --- | --- |
367
417
  | Custom Python agents and pipelines | Decorators, context managers, and [workflow annotations](https://dipeshbabu.github.io/agentloop/WORKFLOW_TRACING/). |
418
+ | TypeScript and JavaScript applications | `npm install agentloop-profiler`, then record model, tool and retry spans with the [TypeScript SDK](https://dipeshbabu.github.io/agentloop/reference/typescript/). |
419
+ | OpenAI Codex CLI and Claude Code | Built-in [Codex](https://dipeshbabu.github.io/agentloop/CODEX/) and [Claude Code](https://dipeshbabu.github.io/agentloop/CLAUDE_CODE/) runners for the guided workflow. |
368
420
  | OpenAI SDK | Wrap a client or callable to capture calls, streams, and reported usage. |
369
421
  | OpenAI Agents SDK | Attach an AgentLoop tracing processor. |
370
422
  | LangGraph | Instrument the builder before adding nodes, then wrap the compiled runnable. |
@@ -416,6 +468,24 @@ code changes.
416
468
 
417
469
  </details>
418
470
 
471
+ ## Deploy to the cloud
472
+
473
+ Run a shared AgentLoop server for your team on any cloud. From 0.2.7 each release
474
+ publishes a container image, `ghcr.io/dipeshbabu/agentloop`, and `deploy/`
475
+ contains a production stack for one Linux server: Postgres, the API, the
476
+ dashboard behind a login, and Caddy for automatic HTTPS. Only ports 80 and 443
477
+ are exposed.
478
+
479
+ ```bash
480
+ cp deploy/.env.example deploy/.env # set the image, domains and secrets
481
+ docker compose -f deploy/docker-compose.yml up --detach
482
+ ```
483
+
484
+ CI runs this exact stack over HTTPS on every change. The
485
+ [cloud deployment guide](https://dipeshbabu.github.io/agentloop/CLOUD_DEPLOY/)
486
+ covers server setup, API keys, upgrades, backups, and managed platforms such as
487
+ Cloud Run, App Runner, ECS and Azure Container Apps.
488
+
419
489
  ## Dashboard and persistence
420
490
 
421
491
  From a [source checkout](#source-checkout), load the synthetic example and start
@@ -430,7 +500,9 @@ uv run --frozen --all-extras streamlit run dashboard/app.py
430
500
  Open Streamlit's printed URL and leave the sidebar's Project field set to `default`.
431
501
  Use `store-trace` to load your own files. Storage uses SQLite by default and also
432
502
  supports Postgres. The optional HTTP API serves project-scoped traces and reports
433
- through `/v1` endpoints.
503
+ through `/v1` endpoints. Python applications use `agentloop.AgentLoopClient`;
504
+ TypeScript applications use `AgentLoopClient` from the npm package to upload
505
+ traces and read reports.
434
506
 
435
507
  See [dashboard setup](https://dipeshbabu.github.io/agentloop/DASHBOARD/), [API versioning](https://dipeshbabu.github.io/agentloop/API_VERSIONING/),
436
508
  and [production deployment](https://dipeshbabu.github.io/agentloop/PRODUCTION/) for configuration and authentication.
@@ -461,13 +533,13 @@ where the examples show `agentloop`.
461
533
  <summary>Download and verify a standalone executable</summary>
462
534
 
463
535
  Download the executable and `SHA256SUMS` from the same release. These examples use
464
- version 0.2.6. Change the version when choosing another release.
536
+ version 0.2.7. Change the version when choosing another release.
465
537
 
466
538
  Linux (Bash):
467
539
 
468
540
  ```bash
469
541
  set -euo pipefail
470
- version=0.2.6
542
+ version=0.2.7
471
543
  asset="agentloop-v${version}-linux-x86_64"
472
544
  curl --fail --location --remote-name "https://github.com/dipeshbabu/agentloop/releases/download/v${version}/${asset}"
473
545
  curl --fail --location --remote-name "https://github.com/dipeshbabu/agentloop/releases/download/v${version}/SHA256SUMS"
@@ -484,7 +556,7 @@ chmod +x "$asset"
484
556
  Windows PowerShell:
485
557
 
486
558
  ```powershell
487
- $Version = "0.2.6"
559
+ $Version = "0.2.7"
488
560
  $Asset = "agentloop-v$Version-windows-x86_64.exe"
489
561
  Invoke-WebRequest "https://github.com/dipeshbabu/agentloop/releases/download/v$Version/$Asset" -OutFile agentloop.exe
490
562
  Invoke-WebRequest "https://github.com/dipeshbabu/agentloop/releases/download/v$Version/SHA256SUMS" -OutFile SHA256SUMS
@@ -13,6 +13,7 @@
13
13
  <p align="center">
14
14
  <a href="https://github.com/dipeshbabu/agentloop/actions/workflows/ci.yml"><img src="https://github.com/dipeshbabu/agentloop/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
15
15
  <a href="https://pypi.org/project/agentloop-profiler/"><img src="https://img.shields.io/pypi/v/agentloop-profiler.svg?cacheSeconds=300" alt="PyPI"></a>
16
+ <a href="https://www.npmjs.com/package/agentloop-profiler"><img src="https://img.shields.io/npm/v/agentloop-profiler.svg?cacheSeconds=300" alt="npm"></a>
16
17
  <a href="https://pepy.tech/projects/agentloop-profiler"><img src="https://static.pepy.tech/badge/agentloop-profiler/month" alt="Downloads/month"></a>
17
18
  <a href="https://www.python.org/downloads/"><img src="https://img.shields.io/badge/python-3.11%2B-3776AB.svg" alt="Python 3.11 or newer"></a>
18
19
  <a href="https://github.com/dipeshbabu/agentloop/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-Apache--2.0-blue.svg" alt="License: Apache-2.0"></a>
@@ -20,11 +21,13 @@
20
21
 
21
22
  <p align="center">
22
23
  <a href="https://dipeshbabu.github.io/agentloop/">Documentation</a> ·
24
+ <a href="#install">Install</a> ·
23
25
  <a href="#quickstart">Quickstart</a> ·
24
26
  <a href="#guided-optimization">Improve an agent</a> ·
25
27
  <a href="#record-your-own-run">Trace your code</a> ·
26
28
  <a href="#compare-before-and-after">Compare runs</a> ·
27
29
  <a href="#framework-integrations">Integrations</a> ·
30
+ <a href="#deploy-to-the-cloud">Deploy</a> ·
28
31
  <a href="https://dipeshbabu.github.io/agentloop/FIRST_USE/">Guide</a>
29
32
  </p>
30
33
 
@@ -37,13 +40,24 @@ The core Python SDK and CLI work with JSON files. You can trace and analyze your
37
40
  code without a hosted account or database. A dashboard, HTTP API, and shared
38
41
  storage are available as optional components.
39
42
 
40
- For Node.js and browser applications, the source checkout includes a
41
- [TypeScript SDK](https://github.com/dipeshbabu/agentloop/blob/main/sdk/typescript/README.md) with native tracing and an API v1 client.
42
- It has no runtime dependencies and installs with `npm install agentloop-profiler`.
43
+ ## Install
44
+
45
+ AgentLoop is published as `agentloop-profiler` on PyPI and on npm.
46
+
47
+ | Install | For | Requires |
48
+ | --- | --- | --- |
49
+ | `python -m pip install agentloop-profiler` | Python SDK and the `agentloop` CLI, which analyzes traces, writes reports and runs the guided workflow | Python 3.11+ |
50
+ | `npm install agentloop-profiler` | [TypeScript SDK](https://github.com/dipeshbabu/agentloop/blob/main/sdk/typescript/README.md) for Node.js and browser code: native tracing and an API v1 client, with no runtime dependencies | Node.js 22+ |
51
+ | [Standalone executable](#standalone-cli) | The `agentloop` CLI without installing Python | Linux, macOS or Windows |
52
+
53
+ The two packages are versioned separately and share the trace format, so traces
54
+ recorded with the TypeScript SDK are analyzed with the `agentloop` CLI. See the
55
+ [installation guide](https://dipeshbabu.github.io/agentloop/installation/) for
56
+ virtual environments, optional extras and installing from source.
43
57
 
44
58
  ## Quickstart
45
59
 
46
- Install with Python 3.11 or newer:
60
+ Install the Python package and record an example trace:
47
61
 
48
62
  ```bash
49
63
  python -m pip install agentloop-profiler
@@ -54,9 +68,9 @@ agentloop analyze runs/agentloop_quickstart.json --html runs/report.html --json-
54
68
  Open `runs/report.html` in your browser to inspect the timeline and findings.
55
69
  `runs/analysis.json` contains the trace, metrics, diagnosis, and optimization plan.
56
70
 
57
- The package name is `agentloop-profiler`; the Python import and CLI command are
58
- both `agentloop`. `quickstart` creates a labeled synthetic trace and makes no model
59
- API calls. It tests your installation, not your application's performance.
71
+ The Python import and CLI command are both `agentloop`. `quickstart` creates a
72
+ labeled synthetic trace and makes no model API calls. It tests your installation,
73
+ not your application's performance.
60
74
 
61
75
  If your shell cannot find `agentloop`, activate the Python environment where you
62
76
  installed it. Run `agentloop doctor` to check the installation and available adapters.
@@ -116,7 +130,9 @@ for those agents.
116
130
 
117
131
  To connect your application, run `agentloop improve init --agent my_agent:answer`
118
132
  in its project directory. The generated adapter supports synchronous and async
119
- Python callables. Replace the example task inputs and expected outputs with
133
+ Python callables. For a Node.js agent, run
134
+ `agentloop improve init --language node --agent ./src/agent.mjs:answer`; see
135
+ [connecting a Node.js agent](https://dipeshbabu.github.io/agentloop/GUIDED_OPTIMIZATION/#connect-an-existing-nodejs-agent). Replace the example task inputs and expected outputs with
120
136
  independent checks for your agent, and keep your model and tool instrumentation.
121
137
  Initialization refuses to overwrite existing files. Read the generated
122
138
  `AGENTLOOP.md` and [onboarding guide](https://dipeshbabu.github.io/agentloop/GUIDED_OPTIMIZATION/).
@@ -178,6 +194,40 @@ Saving `metadata["output"]` is an explicit choice in this example. Review the
178
194
  inputs, outputs, errors, and metadata you retain before sharing real traces.
179
195
  See [trace retention](https://dipeshbabu.github.io/agentloop/TRACE_RETENTION/) for capture controls.
180
196
 
197
+ ### From TypeScript or JavaScript
198
+
199
+ After `npm install agentloop-profiler`, save this as `example_agent.mjs`:
200
+
201
+ ```javascript
202
+ import { writeFile } from "node:fs/promises";
203
+ import { AgentTrace } from "agentloop-profiler";
204
+
205
+ const NOTES = {
206
+ tracing: "Record the steps in a workflow.",
207
+ optimization: "Investigate repeated or expensive work.",
208
+ };
209
+
210
+ const trace = new AgentTrace("research_agent", { metadata: { synthetic: true } });
211
+ const notes = [];
212
+ for (const topic of Object.keys(NOTES)) {
213
+ notes.push(await trace.tool("lookup_note", async () => NOTES[topic]));
214
+ }
215
+ trace.setOutput({ notes });
216
+ trace.finish();
217
+ await writeFile("research_agent_js.json", trace.toJSONString());
218
+ ```
219
+
220
+ Run it and analyze the trace with the `agentloop` CLI:
221
+
222
+ ```bash
223
+ node example_agent.mjs
224
+ agentloop analyze research_agent_js.json --html research_agent_js.html
225
+ ```
226
+
227
+ The SDK also records model calls with provider token usage, retries and nested
228
+ spans, and can send traces to the HTTP API. See the
229
+ [TypeScript SDK guide](https://dipeshbabu.github.io/agentloop/reference/typescript/).
230
+
181
231
  ## Inspect findings
182
232
 
183
233
  For a fixed task set, use the [guided workflow](#guided-optimization) to capture
@@ -307,6 +357,8 @@ gate. Run `agentloop COMMAND --help` to see its output options and thresholds.
307
357
  | Source | Integration path |
308
358
  | --- | --- |
309
359
  | Custom Python agents and pipelines | Decorators, context managers, and [workflow annotations](https://dipeshbabu.github.io/agentloop/WORKFLOW_TRACING/). |
360
+ | TypeScript and JavaScript applications | `npm install agentloop-profiler`, then record model, tool and retry spans with the [TypeScript SDK](https://dipeshbabu.github.io/agentloop/reference/typescript/). |
361
+ | OpenAI Codex CLI and Claude Code | Built-in [Codex](https://dipeshbabu.github.io/agentloop/CODEX/) and [Claude Code](https://dipeshbabu.github.io/agentloop/CLAUDE_CODE/) runners for the guided workflow. |
310
362
  | OpenAI SDK | Wrap a client or callable to capture calls, streams, and reported usage. |
311
363
  | OpenAI Agents SDK | Attach an AgentLoop tracing processor. |
312
364
  | LangGraph | Instrument the builder before adding nodes, then wrap the compiled runnable. |
@@ -358,6 +410,24 @@ code changes.
358
410
 
359
411
  </details>
360
412
 
413
+ ## Deploy to the cloud
414
+
415
+ Run a shared AgentLoop server for your team on any cloud. From 0.2.7 each release
416
+ publishes a container image, `ghcr.io/dipeshbabu/agentloop`, and `deploy/`
417
+ contains a production stack for one Linux server: Postgres, the API, the
418
+ dashboard behind a login, and Caddy for automatic HTTPS. Only ports 80 and 443
419
+ are exposed.
420
+
421
+ ```bash
422
+ cp deploy/.env.example deploy/.env # set the image, domains and secrets
423
+ docker compose -f deploy/docker-compose.yml up --detach
424
+ ```
425
+
426
+ CI runs this exact stack over HTTPS on every change. The
427
+ [cloud deployment guide](https://dipeshbabu.github.io/agentloop/CLOUD_DEPLOY/)
428
+ covers server setup, API keys, upgrades, backups, and managed platforms such as
429
+ Cloud Run, App Runner, ECS and Azure Container Apps.
430
+
361
431
  ## Dashboard and persistence
362
432
 
363
433
  From a [source checkout](#source-checkout), load the synthetic example and start
@@ -372,7 +442,9 @@ uv run --frozen --all-extras streamlit run dashboard/app.py
372
442
  Open Streamlit's printed URL and leave the sidebar's Project field set to `default`.
373
443
  Use `store-trace` to load your own files. Storage uses SQLite by default and also
374
444
  supports Postgres. The optional HTTP API serves project-scoped traces and reports
375
- through `/v1` endpoints.
445
+ through `/v1` endpoints. Python applications use `agentloop.AgentLoopClient`;
446
+ TypeScript applications use `AgentLoopClient` from the npm package to upload
447
+ traces and read reports.
376
448
 
377
449
  See [dashboard setup](https://dipeshbabu.github.io/agentloop/DASHBOARD/), [API versioning](https://dipeshbabu.github.io/agentloop/API_VERSIONING/),
378
450
  and [production deployment](https://dipeshbabu.github.io/agentloop/PRODUCTION/) for configuration and authentication.
@@ -403,13 +475,13 @@ where the examples show `agentloop`.
403
475
  <summary>Download and verify a standalone executable</summary>
404
476
 
405
477
  Download the executable and `SHA256SUMS` from the same release. These examples use
406
- version 0.2.6. Change the version when choosing another release.
478
+ version 0.2.7. Change the version when choosing another release.
407
479
 
408
480
  Linux (Bash):
409
481
 
410
482
  ```bash
411
483
  set -euo pipefail
412
- version=0.2.6
484
+ version=0.2.7
413
485
  asset="agentloop-v${version}-linux-x86_64"
414
486
  curl --fail --location --remote-name "https://github.com/dipeshbabu/agentloop/releases/download/v${version}/${asset}"
415
487
  curl --fail --location --remote-name "https://github.com/dipeshbabu/agentloop/releases/download/v${version}/SHA256SUMS"
@@ -426,7 +498,7 @@ chmod +x "$asset"
426
498
  Windows PowerShell:
427
499
 
428
500
  ```powershell
429
- $Version = "0.2.6"
501
+ $Version = "0.2.7"
430
502
  $Asset = "agentloop-v$Version-windows-x86_64.exe"
431
503
  Invoke-WebRequest "https://github.com/dipeshbabu/agentloop/releases/download/v$Version/$Asset" -OutFile agentloop.exe
432
504
  Invoke-WebRequest "https://github.com/dipeshbabu/agentloop/releases/download/v$Version/SHA256SUMS" -OutFile SHA256SUMS
@@ -988,6 +988,85 @@ def create_api_key(project_id: str = "default", name: str = "default") -> None:
988
988
  console.print(key["api_key"])
989
989
 
990
990
 
991
+ @app.command("list-api-keys")
992
+ def list_api_keys(project_id: str = "default") -> None:
993
+ """List a project's API key prefixes and last use; key values are never shown."""
994
+ console.print_json(
995
+ data={"project_id": project_id, "api_keys": get_store().list_api_keys(project_id)}
996
+ )
997
+
998
+
999
+ @app.command("revoke-api-key")
1000
+ def revoke_api_key(
1001
+ prefix: str = typer.Option(..., help="First 10 characters of the key, as listed."),
1002
+ project_id: str = "default",
1003
+ ) -> None:
1004
+ """Revoke a project's API key; it stops working immediately."""
1005
+ try:
1006
+ revoked = get_store().revoke_api_key(project_id, prefix)
1007
+ except ValueError as exc:
1008
+ raise typer.BadParameter(str(exc)) from exc
1009
+ if not revoked:
1010
+ console.print(f"No API key with prefix {prefix} in project {project_id}.", markup=False)
1011
+ raise typer.Exit(1)
1012
+ console.print(
1013
+ f"Revoked {revoked} API key(s) with prefix {prefix} in project {project_id}.", markup=False
1014
+ )
1015
+
1016
+
1017
+ @app.command("delete-trace")
1018
+ def delete_trace(
1019
+ run_id: str,
1020
+ project_id: str = "default",
1021
+ ) -> None:
1022
+ """Delete a stored trace with its findings, usage and interventions."""
1023
+ deleted = get_store().delete_trace(run_id, project_id)
1024
+ if deleted is None:
1025
+ console.print(f"No trace {run_id} in project {project_id}.", markup=False)
1026
+ raise typer.Exit(1)
1027
+ console.print_json(data={"run_id": run_id, "project_id": project_id, "deleted": deleted})
1028
+
1029
+
1030
+ @app.command("purge-traces")
1031
+ def purge_traces(
1032
+ older_than_days: float | None = typer.Option(
1033
+ None,
1034
+ min=0.0001,
1035
+ help="Delete traces stored more than this many days ago. "
1036
+ "Defaults to AGENTLOOP_RETENTION_DAYS.",
1037
+ ),
1038
+ project_id: str | None = typer.Option(None, help="Only purge this project."),
1039
+ ) -> None:
1040
+ """Apply a retention period: delete traces stored longer ago than allowed."""
1041
+ if older_than_days is None:
1042
+ configured = os.getenv("AGENTLOOP_RETENTION_DAYS", "").strip()
1043
+ if not configured:
1044
+ console.print(
1045
+ "Retention is not configured; set --older-than-days or AGENTLOOP_RETENTION_DAYS.",
1046
+ markup=False,
1047
+ )
1048
+ return
1049
+ try:
1050
+ older_than_days = float(configured)
1051
+ except ValueError:
1052
+ raise typer.BadParameter(
1053
+ "AGENTLOOP_RETENTION_DAYS must be a number of days",
1054
+ param_hint="AGENTLOOP_RETENTION_DAYS",
1055
+ ) from None
1056
+ try:
1057
+ deleted = get_store().purge_traces(older_than_days, project_id=project_id)
1058
+ except ValueError as exc:
1059
+ raise typer.BadParameter(str(exc)) from exc
1060
+ scope = f"project {project_id}" if project_id else "all projects"
1061
+ console.print(
1062
+ f"Deleted {deleted['traces']} trace(s) older than {older_than_days:g} days in {scope} "
1063
+ f"({deleted['findings']} findings, {deleted['usage_events']} usage events, "
1064
+ f"{deleted['interventions']} interventions).",
1065
+ markup=False,
1066
+ soft_wrap=True,
1067
+ )
1068
+
1069
+
991
1070
  @app.command("store-trace")
992
1071
  def store_trace(
993
1072
  path: Path = Path("runs/research_agent_baseline.json"),
@@ -1206,6 +1285,19 @@ def upload(
1206
1285
  console.print(f"Project: {response.get('project_id', 'default')}")
1207
1286
 
1208
1287
 
1288
+ @app.command("remote-delete-trace")
1289
+ def remote_delete_trace(
1290
+ run_id: str,
1291
+ api_url: str = typer.Option("http://127.0.0.1:8000", help="AgentLoop API base URL."),
1292
+ api_key: str | None = typer.Option(
1293
+ None, help="Project API key. Defaults to AGENTLOOP_API_KEY."
1294
+ ),
1295
+ ) -> None:
1296
+ """Delete a trace of the key's project on a remote server."""
1297
+ client = _remote_client(api_url, api_key)
1298
+ console.print_json(data=client.delete_trace(run_id))
1299
+
1300
+
1209
1301
  @app.command("remote-optimize")
1210
1302
  def remote_optimize(
1211
1303
  run_id: str,
@@ -1333,6 +1425,37 @@ def remote_create_api_key(
1333
1425
  console.print(key["api_key"])
1334
1426
 
1335
1427
 
1428
+ @app.command("remote-list-api-keys")
1429
+ def remote_list_api_keys(
1430
+ project_id: str = "default",
1431
+ api_url: str = typer.Option("http://127.0.0.1:8000", help="AgentLoop API base URL."),
1432
+ admin_api_key: str | None = typer.Option(
1433
+ None, help="Admin API key. Defaults to AGENTLOOP_ADMIN_API_KEY."
1434
+ ),
1435
+ ) -> None:
1436
+ """List a project's API key prefixes on a remote server."""
1437
+ client = _remote_admin_client(api_url, admin_api_key)
1438
+ console.print_json(data=client.list_api_keys(project_id))
1439
+
1440
+
1441
+ @app.command("remote-revoke-api-key")
1442
+ def remote_revoke_api_key(
1443
+ prefix: str = typer.Option(..., help="First 10 characters of the key, as listed."),
1444
+ project_id: str = "default",
1445
+ api_url: str = typer.Option("http://127.0.0.1:8000", help="AgentLoop API base URL."),
1446
+ admin_api_key: str | None = typer.Option(
1447
+ None, help="Admin API key. Defaults to AGENTLOOP_ADMIN_API_KEY."
1448
+ ),
1449
+ ) -> None:
1450
+ """Revoke a project's API key on a remote server."""
1451
+ client = _remote_admin_client(api_url, admin_api_key)
1452
+ result = client.revoke_api_key(project_id, prefix)
1453
+ console.print(
1454
+ f"Revoked {result['revoked']} API key(s) with prefix {prefix} in project {project_id}.",
1455
+ markup=False,
1456
+ )
1457
+
1458
+
1336
1459
  @app.command()
1337
1460
  def demo(
1338
1461
  kind: str = typer.Option("baseline", help="baseline, optimized, langgraph, or proof"),
@@ -59,6 +59,25 @@ class AgentLoopClient:
59
59
  credential_scope="admin",
60
60
  )
61
61
 
62
+ def list_api_keys(self, project_id: str) -> dict[str, Any]:
63
+ """List a project's key prefixes, names and usage times (admin key required)."""
64
+ return self._request(
65
+ "GET",
66
+ "/api-keys?" + urllib.parse.urlencode({"project_id": project_id}),
67
+ credential_scope="admin",
68
+ )
69
+
70
+ def revoke_api_key(self, project_id: str, prefix: str) -> dict[str, Any]:
71
+ """Revoke a project's key by its prefix (admin key required)."""
72
+ return self._request(
73
+ "DELETE",
74
+ "/api-keys/"
75
+ + urllib.parse.quote(prefix, safe="")
76
+ + "?"
77
+ + urllib.parse.urlencode({"project_id": project_id}),
78
+ credential_scope="admin",
79
+ )
80
+
62
81
  def upload_trace(self, trace: AgentTrace | str | Path | dict[str, Any]) -> dict[str, Any]:
63
82
  if isinstance(trace, AgentTrace):
64
83
  payload = trace.to_dict()
@@ -93,6 +112,11 @@ class AgentLoopClient:
93
112
  route += "?" + urllib.parse.urlencode({"project_id": project_id})
94
113
  return self._request("GET", route)
95
114
 
115
+ def delete_trace(self, run_id: str) -> dict[str, Any]:
116
+ """Delete a trace of this key's project, with its findings, usage and interventions."""
117
+ encoded_run_id = urllib.parse.quote(run_id, safe="")
118
+ return self._request("DELETE", f"/traces/{encoded_run_id}")
119
+
96
120
  def get_report(self, run_id: str) -> dict[str, Any]:
97
121
  encoded_run_id = urllib.parse.quote(run_id, safe="")
98
122
  return self._request("GET", f"/traces/{encoded_run_id}/report")
@@ -24,6 +24,7 @@ from agentloop.repetitions import add_repetition_findings
24
24
  from agentloop.replay import ReplayGates, build_replay_report
25
25
  from agentloop.replay import _summary as replay_summary
26
26
  from agentloop.schema import TraceValidationError, validate_elapsed_ms
27
+ from agentloop.tokens import is_token_basis_evaluable
27
28
  from agentloop.tracer import AgentTrace
28
29
 
29
30
  VERSION = "1.0"
@@ -433,7 +434,9 @@ def planning_guidance(workload, manifest, traces, objective, minimum_improvement
433
434
 
434
435
  The sign test needs at least five pairs before even a unanimous result can
435
436
  fall below p = 0.05. When repeated baseline attempts of the same task vary
436
- by more than the required improvement, smaller differences may be noise.
437
+ in the objective (latency, or estimated cost) by more than the required
438
+ improvement, smaller differences may be noise. For the cost objective,
439
+ attempts whose cost cannot be measured are reported separately.
437
440
  """
438
441
  notes = []
439
442
  pairs = len(workload["tasks"]) * workload["repetitions"]
@@ -455,26 +458,50 @@ def planning_guidance(workload, manifest, traces, objective, minimum_improvement
455
458
  "measured. Use at least 2 repetitions to see how noisy the agent is.",
456
459
  }
457
460
  )
458
- elif objective == "latency":
459
- completed = _completed(manifest, traces)
461
+ else:
462
+ completed = {
463
+ key: trace
464
+ for key, trace in _completed(manifest, traces).items()
465
+ if _trace_usable(trace)
466
+ }
467
+ if objective == "latency":
468
+ values = {key: trace.elapsed_ms for key, trace in completed.items()}
469
+ else:
470
+ values, unmeasurable = {}, 0
471
+ for key, trace in completed.items():
472
+ report = trace.report()
473
+ if report.get("has_unknown_cost") or not is_token_basis_evaluable(
474
+ report.get("token_status")
475
+ ):
476
+ unmeasurable += 1
477
+ else:
478
+ values[key] = float(report.get("estimated_cost_usd") or 0.0)
479
+ if unmeasurable:
480
+ notes.append(
481
+ {
482
+ "kind": "cost_unmeasurable",
483
+ "attempts": unmeasurable,
484
+ "message": f"{unmeasurable} of {len(completed)} completed baseline "
485
+ "attempts have unknown model pricing or estimated token counts, so "
486
+ "their cost cannot be compared and cost gates will be indeterminate. "
487
+ "Record provider token usage and use models with known pricing.",
488
+ }
489
+ )
460
490
  spreads = []
461
491
  for task in workload["tasks"]:
462
- values = [
463
- trace.elapsed_ms
464
- for (task_id, _), trace in completed.items()
465
- if task_id == task["id"] and _trace_usable(trace)
466
- ]
467
- middle = statistics.median(values) if len(values) >= 2 else 0
492
+ task_values = [value for (task_id, _), value in values.items() if task_id == task["id"]]
493
+ middle = statistics.median(task_values) if len(task_values) >= 2 else 0
468
494
  if middle > 0:
469
- spreads.append((max(values) - min(values)) / middle * 100)
495
+ spreads.append((max(task_values) - min(task_values)) / middle * 100)
470
496
  if spreads:
471
497
  spread = statistics.median(spreads)
472
498
  if spread >= NOISY_SPREAD_PCT and spread > minimum_improvement:
473
499
  notes.append(
474
500
  {
475
501
  "kind": "noisy_baseline",
502
+ "objective": objective,
476
503
  "spread_pct": round(spread, 2),
477
- "message": f"Baseline latency of the same task varied by a median "
504
+ "message": f"Baseline {objective} of the same task varied by a median "
478
505
  f"{spread:.1f}% between repetitions, more than the "
479
506
  f"{minimum_improvement:g}% required improvement. Smaller differences "
480
507
  "may be noise: require a larger improvement, add repetitions, or "