Queries production Agentforce session traces from Salesforce Data Cloud's STDM (Session Trace Data Model) to diagnose agent failures and performance regressions. The workflow is observe production issues, reproduce them locally with `sf agent preview`, then edit the `.agent` file and redeploy. Notably includes a Data Space discovery step and a full fallback path when STDM isn't enabled, switching to test suites and local traces instead. The routing logic auto-resolves agent names against the org metadata and works around a known `sf project retrieve` bug that double-nests directories. Most useful when your agent works in dev but breaks in production and you need to see what real users actually said.
npx skills add https://github.com/forcedotcom/afv-library --skill observing-agentforce