Repository navigation
Trajectory 0.6.4
This release brings Trajectory Lens as the new local session viewer, simplifies installation, updates, and MDM deployment, adds Claude Code prompt-cache optimization and one-step AI Gateway setup, expands cross-OS device and identity attribution, and lowers background service disk I/O. Some unused metrics are retired and MDM kit layouts changed: see Before you upgrade.
Highlights
Trajectory Lens
trajectory lens opens the new local viewer for your coding-agent sessions, with Insights pages for usage, work categories, outliers, reliability, skills, and recommendations. On request, an installed coding agent can investigate an expensive session or reliability problem with read-only access to your local data; its own session runs in incognito mode and Trajectory's internal sessions stay hidden from your session list unless enabled in Settings.
trajectory lenstrajectory view is deprecated in favor of Lens and continues working for now.
Simpler lifecycle commands and MDM kits
trajectory install, trajectory update, and trajectory uninstall now manage the full user lifecycle, and trajectory doctor opens with a concise summary of the release, management state, update ring, version floor, and config sync status. Jamf Pro and Intune kits from trajectory-mdm prepare now ship one MDM script (trajectory-jamf.sh or trajectory-intune.sh) and a configuration profile, while automatic updates (auto_update: true) and hosted client or security module settings can be managed from hosted config.defaults.yaml.
trajectory install --format json
trajectory uninstall --dry-runPrompt-cache optimization and one-step AI Gateway setup
Analyze Claude Code prompt-cache routes and replay transcripts to optimize cache usage with the new trajectory cost optimize command and authenticated /api/trajectory/v2/optimize endpoint. Setting up AI Gateway is now one step with trajectory setup --plugin ai-gateway (or install.sh --plugin ai-gateway), and trajectory plugins ai-gateway setup defaults to the coding agents Trajectory already captures. Filter Claude Code and Codex model pickers to specific Gateway accounts with trajectory claude --provider-slugs or the managed provider_slugs setting.
trajectory cost optimize
trajectory setup --plugin ai-gatewayCross-OS identity and device attribution
Metrics, LLM Observability spans, AI Usage skill events, and Agent Security spans and finding logs now carry trajectory.device_id (or device_id) across macOS, Windows, and non-container Linux hosts. Published metrics and spans also add trajectory.user_source, trajectory.user_email_source, and trajectory.actor_type, alongside opt-in identity settings for username normalization, non-person accounts, allowed email domains, and directory lookups.
Broader client capture and quieter background service
Trajectory now captures OpenCode 2 sessions live (2.0.31+), captures Claude Desktop Cowork sessions and detects tools on PATH on Windows, records Kiro CLI sub-agents, tool durations, and turn replies, and discovers running AI-tool processes with native signing evidence on macOS. trajectory serve writes and reads far less to disk during live capture, restarts, and idle periods.
Pre-invocation local skill security
Local agent skills are assessed before supported invocations following each client's source and name precedence. Skill Scanner findings reach AI Guard and AI-EDR with original assessment details and credential-file exclusions, honor available blocked verdicts when local storage fails, and stay within bounded resource limits.
Improvements
trajectory servereportstrajectory.ops.agent.runningevery minute andtrajectory.ops.update.statefor release ring, version floor, and update state.trajectory pslists all running Trajectory processes with their agent, session, and project.- Completed turns include
gen_ai.request.reasoning_effortandtrajectory.turn.agents.peak_running, Claude Code metrics addtrajectory.client_surface, and Datadog AI Gateway traffic tagstrajectory.provider_route:datadog_ai_gateway. - Restored
trajectory.turn.user_frustrationsandtrajectory.turn.tool_decisionper-turn metrics. trajectory backfill progressreports caller origin, trigger, and outcome, and CLI backfill accepts--origin.- Administrators can drive chosen feature flag defaults from a Datadog Feature Flags environment.
install.shverifies downloaded binaries against release checksums.
Fixes
install.sh --securitysends AI Guard spans to Datadog again.trajectory backfillno longer stops with a timeout error when saving progress is slow and no--timeoutis set.trajectory updaterestores the previous release if the capture service exits within seconds of starting.trajectory servestops repeatedly triggering macOS protected-folder prompts after Don't Allow, andtrajectory installaccepts macOS user home paths that differ only in case.trajectory-mdmbuilds intents authored for earlier releases with warnings instead of errors for retired fields and acceptsdeployment.minimum_versionat anyschema_version.- Fixed Claude Code mid-reply session exits and hook timeouts, Codex provider-only models, Pi rate-card pricing fallbacks, and OpenCode/Kilo provider-error turn status.
Privacy and safety
- Toggling incognito, publish opt-out, or capture no longer sends any metric to Datadog.
trajectory.pr.file_work.cost_indicator.usd.additiveis now off by default because itsfile_pathtag names repository files; setexport.pr_file_work_cost_indicator: trueto re-enable.- Skill security scans exclude credential files from discovery reads and uploads and enforce product authorization and privacy controls.
- Agent Security for Kiro CLI detects additional shell patterns that tamper with Kiro hooks, agents, and MCP configuration.
Before you upgrade
- 101 unused or duplicate metrics and several tags (
git_remote_host,duration_basis,cost_coverage, and redundantagent_role) are retired; move dashboards and monitors to their documented replacements before upgrading. - OpenCode 2.0.0 through 2.0.30 are no longer captured; upgrade to OpenCode 2.0.31 or later and run
trajectory setup --clients opencodeif prompted. - Managed Macs now read
auto_update: truefrom hostedconfig.defaults.yaml, andtrajectory-mdm prepareproduces only the MDM script and configuration profile; regenerate older Jamf Pro or Intune kits to adopt the new layout. - On existing
install.sh --securityinstallations, addmodule_spans(enabled: true,modules: [agent-security],native_composite_attributes: [agent-security]) to theai-guard-apmdestination in~/.trajectory/config.defaults.yamlso AI Guard spans resume.