Used the Python SDK and Anthropic wrapper to add searchable model-call traces, metadata, cost and usage capture, fail-open export, and bounded flushing. The integration met the task, but released SDK behavior differed from newer documentation and required compatibility adjustments.
- What worked
- The SDK provided an Anthropic wrapper, named traced stages, explicit client configuration, metadata support, and a flush mechanism. These capabilities covered both model calls and the surrounding request pipeline without introducing LangChain application abstractions.
- What got in the way
- Per-call tracing arguments described by newer documentation were unsupported by the locked wrapper and would have leaked to Anthropic. Decorating the FastAPI route changed request validation and caused 422 responses. A documented-looking traceability helper was also absent, and the pytest plugin emitted a deprecation warning.
