All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Primary API is now
botanu.event(...)— works as context manager, async context manager, and decorator. The legacy@botanu_workflow,workflowalias,run_botanu, and@botanu_outcomedecorators are removed. emit_outcomeis keyword-only and no longer accepts astatusargument. Authoritative event outcome is resolved server-side from SoR connectors, HITL reviews, or eval verdict rollup.- Lean baggage propagation is removed. All seven baggage keys (plus any retry/deadline keys when set) always propagate. The
BOTANU_PROPAGATION_MODEenv var, thepropagation_modefield onBotanuConfig,BAGGAGE_KEYS_LEAN, and thelean_modeparameter onRunContextEnricher/RunContext.to_baggage_dictare all gone.
botanu.event(...)as context manager, async context manager, and decorator — a single API for marking business events.botanu.step(name)for nested phase spans inside an event.- SDK initialises automatically on the first
botanu.event(...)call. Customers no longer need to call any bootstrap function by hand. botanu.set_correlation(**keys)for SoR Tier-1 correlation.- Security: OTLP bearer token is attached only when the endpoint host is botanu-owned (
*.botanu.ai) or a local dev host, preventing tenant API-key leakage via a customer-suppliedOTEL_EXPORTER_OTLP_ENDPOINT. Authorization /x-api-key/botanu-api-keyheaders anduser:pass@URL credentials are redacted in logs. - OTel coexistence: when the host app already has the OTel SDK wired up, botanu preserves the existing sampling ratio and adds itself alongside.
register.pymodule for zero-code initialisation in containers / gunicorn / process runners. - Content capture for eval, gated by
content_capture_rate. Writesbotanu.eval.input_content/botanu.eval.output_contentwith in-process PII scrub (regex by default; optional Microsoft Presidio viapip install botanu[pii-nlp]). ResourceEnricherspan processor for deployment attributes.- Release tooling:
scripts/pre_publish_check.py— builds sdist + wheel, runstwine check, installs into a fresh venv, validates the public API surface, runs an end-to-end smoke test.
SampledSpanProcessor.on_startnow gates on the same ratio decision ason_end; forwardingon_startunconditionally while gatingon_endleaked span bookkeeping inside wrapped exporters.