agent-trajviz 0.1.0__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 (171) hide show
  1. agent_trajviz-0.1.0/.gitignore +70 -0
  2. agent_trajviz-0.1.0/CHANGELOG.md +172 -0
  3. agent_trajviz-0.1.0/LICENSE +21 -0
  4. agent_trajviz-0.1.0/PKG-INFO +688 -0
  5. agent_trajviz-0.1.0/README.md +635 -0
  6. agent_trajviz-0.1.0/agent_trajviz/__init__.py +80 -0
  7. agent_trajviz-0.1.0/agent_trajviz/__main__.py +6 -0
  8. agent_trajviz-0.1.0/agent_trajviz/_cli.py +27 -0
  9. agent_trajviz-0.1.0/agent_trajviz/_extras.py +53 -0
  10. agent_trajviz-0.1.0/agent_trajviz/_fileio.py +80 -0
  11. agent_trajviz-0.1.0/agent_trajviz/_redact.py +98 -0
  12. agent_trajviz-0.1.0/agent_trajviz/_serve.py +116 -0
  13. agent_trajviz-0.1.0/agent_trajviz/api.py +427 -0
  14. agent_trajviz-0.1.0/agent_trajviz/attribution.py +62 -0
  15. agent_trajviz-0.1.0/agent_trajviz/collect/__init__.py +12 -0
  16. agent_trajviz-0.1.0/agent_trajviz/collect/__main__.py +43 -0
  17. agent_trajviz-0.1.0/agent_trajviz/collect/codearts.py +966 -0
  18. agent_trajviz-0.1.0/agent_trajviz/collect/cursor.py +1420 -0
  19. agent_trajviz-0.1.0/agent_trajviz/collect/opencode.py +499 -0
  20. agent_trajviz-0.1.0/agent_trajviz/converge/__init__.py +1 -0
  21. agent_trajviz-0.1.0/agent_trajviz/converge/__main__.py +56 -0
  22. agent_trajviz-0.1.0/agent_trajviz/converge/alignment.py +540 -0
  23. agent_trajviz-0.1.0/agent_trajviz/converge/anchor.py +205 -0
  24. agent_trajviz-0.1.0/agent_trajviz/converge/app.py +348 -0
  25. agent_trajviz-0.1.0/agent_trajviz/converge/batch.py +388 -0
  26. agent_trajviz-0.1.0/agent_trajviz/converge/canonical.py +654 -0
  27. agent_trajviz-0.1.0/agent_trajviz/converge/charts.py +324 -0
  28. agent_trajviz-0.1.0/agent_trajviz/converge/cli.py +398 -0
  29. agent_trajviz-0.1.0/agent_trajviz/converge/divergence.py +384 -0
  30. agent_trajviz-0.1.0/agent_trajviz/converge/eval_layers.py +178 -0
  31. agent_trajviz-0.1.0/agent_trajviz/converge/intervention.py +456 -0
  32. agent_trajviz-0.1.0/agent_trajviz/converge/milestones.py +282 -0
  33. agent_trajviz-0.1.0/agent_trajviz/converge/rendering.py +269 -0
  34. agent_trajviz-0.1.0/agent_trajviz/converge/styles.py +196 -0
  35. agent_trajviz-0.1.0/agent_trajviz/dashboard.py +172 -0
  36. agent_trajviz-0.1.0/agent_trajviz/errors.py +48 -0
  37. agent_trajviz-0.1.0/agent_trajviz/figures.py +145 -0
  38. agent_trajviz-0.1.0/agent_trajviz/insight/__init__.py +1 -0
  39. agent_trajviz-0.1.0/agent_trajviz/insight/__main__.py +153 -0
  40. agent_trajviz-0.1.0/agent_trajviz/insight/analysis.py +227 -0
  41. agent_trajviz-0.1.0/agent_trajviz/insight/analytics.py +78 -0
  42. agent_trajviz-0.1.0/agent_trajviz/insight/assistant.py +795 -0
  43. agent_trajviz-0.1.0/agent_trajviz/insight/attribution.py +509 -0
  44. agent_trajviz-0.1.0/agent_trajviz/insight/chart_data.py +507 -0
  45. agent_trajviz-0.1.0/agent_trajviz/insight/charts/__init__.py +55 -0
  46. agent_trajviz-0.1.0/agent_trajviz/insight/charts/_layout.py +143 -0
  47. agent_trajviz-0.1.0/agent_trajviz/insight/charts/activity.py +782 -0
  48. agent_trajviz-0.1.0/agent_trajviz/insight/charts/label_charts.py +449 -0
  49. agent_trajviz-0.1.0/agent_trajviz/insight/charts/swimlanes.py +319 -0
  50. agent_trajviz-0.1.0/agent_trajviz/insight/charts/usage.py +726 -0
  51. agent_trajviz-0.1.0/agent_trajviz/insight/comparison.py +163 -0
  52. agent_trajviz-0.1.0/agent_trajviz/insight/context_usage.py +1506 -0
  53. agent_trajviz-0.1.0/agent_trajviz/insight/diagnostics.py +778 -0
  54. agent_trajviz-0.1.0/agent_trajviz/insight/formats/__init__.py +2 -0
  55. agent_trajviz-0.1.0/agent_trajviz/insight/formats/claude_code.py +700 -0
  56. agent_trajviz-0.1.0/agent_trajviz/insight/formats/codearts.py +126 -0
  57. agent_trajviz-0.1.0/agent_trajviz/insight/formats/codex.py +522 -0
  58. agent_trajviz-0.1.0/agent_trajviz/insight/formats/common.py +78 -0
  59. agent_trajviz-0.1.0/agent_trajviz/insight/formats/cursor.py +291 -0
  60. agent_trajviz-0.1.0/agent_trajviz/insight/formats/dsh.py +1132 -0
  61. agent_trajviz-0.1.0/agent_trajviz/insight/formats/icode.py +687 -0
  62. agent_trajviz-0.1.0/agent_trajviz/insight/formats/opencode.py +212 -0
  63. agent_trajviz-0.1.0/agent_trajviz/insight/formats/parse.py +143 -0
  64. agent_trajviz-0.1.0/agent_trajviz/insight/formats/pi.py +322 -0
  65. agent_trajviz-0.1.0/agent_trajviz/insight/formats/sniff.py +177 -0
  66. agent_trajviz-0.1.0/agent_trajviz/insight/formatting.py +491 -0
  67. agent_trajviz-0.1.0/agent_trajviz/insight/help.py +21 -0
  68. agent_trajviz-0.1.0/agent_trajviz/insight/insight.py +360 -0
  69. agent_trajviz-0.1.0/agent_trajviz/insight/issue_judge.py +333 -0
  70. agent_trajviz-0.1.0/agent_trajviz/insight/issues.py +441 -0
  71. agent_trajviz-0.1.0/agent_trajviz/insight/labels.py +176 -0
  72. agent_trajviz-0.1.0/agent_trajviz/insight/llm_config.py +264 -0
  73. agent_trajviz-0.1.0/agent_trajviz/insight/loaders.py +403 -0
  74. agent_trajviz-0.1.0/agent_trajviz/insight/metrics.py +1254 -0
  75. agent_trajviz-0.1.0/agent_trajviz/insight/palette.py +88 -0
  76. agent_trajviz-0.1.0/agent_trajviz/insight/parser.py +767 -0
  77. agent_trajviz-0.1.0/agent_trajviz/insight/patterns.py +983 -0
  78. agent_trajviz-0.1.0/agent_trajviz/insight/presenters/__init__.py +55 -0
  79. agent_trajviz-0.1.0/agent_trajviz/insight/presenters/issues.py +187 -0
  80. agent_trajviz-0.1.0/agent_trajviz/insight/presenters/label_ui.py +80 -0
  81. agent_trajviz-0.1.0/agent_trajviz/insight/presenters/overview.py +526 -0
  82. agent_trajviz-0.1.0/agent_trajviz/insight/presenters/patterns.py +76 -0
  83. agent_trajviz-0.1.0/agent_trajviz/insight/presenters/raw.py +13 -0
  84. agent_trajviz-0.1.0/agent_trajviz/insight/presenters/workflow.py +186 -0
  85. agent_trajviz-0.1.0/agent_trajviz/insight/rendering.py +1401 -0
  86. agent_trajviz-0.1.0/agent_trajviz/insight/report.py +410 -0
  87. agent_trajviz-0.1.0/agent_trajviz/insight/run_group.py +1624 -0
  88. agent_trajviz-0.1.0/agent_trajviz/insight/session.py +197 -0
  89. agent_trajviz-0.1.0/agent_trajviz/insight/shell_cmd.py +537 -0
  90. agent_trajviz-0.1.0/agent_trajviz/insight/step_errors.py +23 -0
  91. agent_trajviz-0.1.0/agent_trajviz/insight/styles.py +1777 -0
  92. agent_trajviz-0.1.0/agent_trajviz/insight/timeline_agents.py +196 -0
  93. agent_trajviz-0.1.0/agent_trajviz/insight/tool_failure.py +92 -0
  94. agent_trajviz-0.1.0/agent_trajviz/insight/ui/__init__.py +1 -0
  95. agent_trajviz-0.1.0/agent_trajviz/insight/ui/attribution_tab.py +172 -0
  96. agent_trajviz-0.1.0/agent_trajviz/insight/ui/comparison_tab.py +359 -0
  97. agent_trajviz-0.1.0/agent_trajviz/insight/ui/load.py +273 -0
  98. agent_trajviz-0.1.0/agent_trajviz/insight/ui/overview_tab.py +701 -0
  99. agent_trajviz-0.1.0/agent_trajviz/insight/ui/patterns_tab.py +70 -0
  100. agent_trajviz-0.1.0/agent_trajviz/insight/ui/raw_tab.py +39 -0
  101. agent_trajviz-0.1.0/agent_trajviz/insight/ui/shared.py +74 -0
  102. agent_trajviz-0.1.0/agent_trajviz/insight/ui/sidebar.py +142 -0
  103. agent_trajviz-0.1.0/agent_trajviz/insight/ui/upload.py +207 -0
  104. agent_trajviz-0.1.0/agent_trajviz/insight/ui/views_tab.py +97 -0
  105. agent_trajviz-0.1.0/agent_trajviz/insight/ui/workflow_tab.py +482 -0
  106. agent_trajviz-0.1.0/agent_trajviz/insight/workflow_role.py +34 -0
  107. agent_trajviz-0.1.0/agent_trajviz/labeling/__init__.py +13 -0
  108. agent_trajviz-0.1.0/agent_trajviz/labeling/__main__.py +6 -0
  109. agent_trajviz-0.1.0/agent_trajviz/labeling/labeler.py +288 -0
  110. agent_trajviz-0.1.0/agent_trajviz/labeling/llm.py +163 -0
  111. agent_trajviz-0.1.0/agent_trajviz/labeling/taxonomy.md +81 -0
  112. agent_trajviz-0.1.0/agent_trajviz/labeling/taxonomy.py +225 -0
  113. agent_trajviz-0.1.0/agent_trajviz/llm.py +133 -0
  114. agent_trajviz-0.1.0/agent_trajviz/model.py +95 -0
  115. agent_trajviz-0.1.0/agent_trajviz/plugins.py +126 -0
  116. agent_trajviz-0.1.0/agent_trajviz/py.typed +0 -0
  117. agent_trajviz-0.1.0/agent_trajviz/schemas/agent_swimlane.schema.json +95 -0
  118. agent_trajviz-0.1.0/agent_trajviz/schemas/agent_tokens.schema.json +113 -0
  119. agent_trajviz-0.1.0/agent_trajviz/schemas/agents.schema.json +150 -0
  120. agent_trajviz-0.1.0/agent_trajviz/schemas/anchor_classes.schema.json +183 -0
  121. agent_trajviz-0.1.0/agent_trajviz/schemas/bottlenecks.schema.json +134 -0
  122. agent_trajviz-0.1.0/agent_trajviz/schemas/comparison_summary.schema.json +215 -0
  123. agent_trajviz-0.1.0/agent_trajviz/schemas/context_pressure.schema.json +314 -0
  124. agent_trajviz-0.1.0/agent_trajviz/schemas/context_usage.schema.json +150 -0
  125. agent_trajviz-0.1.0/agent_trajviz/schemas/diagnostics.schema.json +69 -0
  126. agent_trajviz-0.1.0/agent_trajviz/schemas/divergence.schema.json +86 -0
  127. agent_trajviz-0.1.0/agent_trajviz/schemas/edit_thrash.schema.json +68 -0
  128. agent_trajviz-0.1.0/agent_trajviz/schemas/error_clusters.schema.json +94 -0
  129. agent_trajviz-0.1.0/agent_trajviz/schemas/evaluation_layers.schema.json +181 -0
  130. agent_trajviz-0.1.0/agent_trajviz/schemas/failure_chains.schema.json +94 -0
  131. agent_trajviz-0.1.0/agent_trajviz/schemas/failure_patterns.schema.json +78 -0
  132. agent_trajviz-0.1.0/agent_trajviz/schemas/file_interactions.schema.json +99 -0
  133. agent_trajviz-0.1.0/agent_trajviz/schemas/fruitless_streaks.schema.json +60 -0
  134. agent_trajviz-0.1.0/agent_trajviz/schemas/health.schema.json +62 -0
  135. agent_trajviz-0.1.0/agent_trajviz/schemas/hotspots.schema.json +374 -0
  136. agent_trajviz-0.1.0/agent_trajviz/schemas/issues.schema.json +104 -0
  137. agent_trajviz-0.1.0/agent_trajviz/schemas/label_action_counts.schema.json +52 -0
  138. agent_trajviz-0.1.0/agent_trajviz/schemas/label_action_durations.schema.json +52 -0
  139. agent_trajviz-0.1.0/agent_trajviz/schemas/label_phase_count_comparison.schema.json +76 -0
  140. agent_trajviz-0.1.0/agent_trajviz/schemas/label_phase_counts.schema.json +45 -0
  141. agent_trajviz-0.1.0/agent_trajviz/schemas/label_phase_duration_comparison.schema.json +76 -0
  142. agent_trajviz-0.1.0/agent_trajviz/schemas/label_phase_durations.schema.json +45 -0
  143. agent_trajviz-0.1.0/agent_trajviz/schemas/label_timeline.schema.json +116 -0
  144. agent_trajviz-0.1.0/agent_trajviz/schemas/labels_summary.schema.json +66 -0
  145. agent_trajviz-0.1.0/agent_trajviz/schemas/metrics.schema.json +561 -0
  146. agent_trajviz-0.1.0/agent_trajviz/schemas/milestone_timeline.schema.json +167 -0
  147. agent_trajviz-0.1.0/agent_trajviz/schemas/phase_regressions.schema.json +65 -0
  148. agent_trajviz-0.1.0/agent_trajviz/schemas/phases.schema.json +53 -0
  149. agent_trajviz-0.1.0/agent_trajviz/schemas/plan.schema.json +157 -0
  150. agent_trajviz-0.1.0/agent_trajviz/schemas/premature_compactions.schema.json +77 -0
  151. agent_trajviz-0.1.0/agent_trajviz/schemas/repeated_searches.schema.json +60 -0
  152. agent_trajviz-0.1.0/agent_trajviz/schemas/run_behavior.schema.json +324 -0
  153. agent_trajviz-0.1.0/agent_trajviz/schemas/run_scorecard.schema.json +131 -0
  154. agent_trajviz-0.1.0/agent_trajviz/schemas/run_timelines.schema.json +107 -0
  155. agent_trajviz-0.1.0/agent_trajviz/schemas/segment_costs.schema.json +112 -0
  156. agent_trajviz-0.1.0/agent_trajviz/schemas/session.schema.json +115 -0
  157. agent_trajviz-0.1.0/agent_trajviz/schemas/skill_calls.schema.json +80 -0
  158. agent_trajviz-0.1.0/agent_trajviz/schemas/step_analytics.schema.json +123 -0
  159. agent_trajviz-0.1.0/agent_trajviz/schemas/step_durations.schema.json +88 -0
  160. agent_trajviz-0.1.0/agent_trajviz/schemas/steps.schema.json +144 -0
  161. agent_trajviz-0.1.0/agent_trajviz/schemas/summary.schema.json +185 -0
  162. agent_trajviz-0.1.0/agent_trajviz/schemas/token_usage.schema.json +106 -0
  163. agent_trajviz-0.1.0/agent_trajviz/schemas/tool_durations.schema.json +99 -0
  164. agent_trajviz-0.1.0/agent_trajviz/schemas/tool_outcomes.schema.json +88 -0
  165. agent_trajviz-0.1.0/agent_trajviz/schemas/tool_selection.schema.json +53 -0
  166. agent_trajviz-0.1.0/agent_trajviz/schemas/tool_sequences.schema.json +59 -0
  167. agent_trajviz-0.1.0/agent_trajviz/schemas/tool_usage.schema.json +83 -0
  168. agent_trajviz-0.1.0/agent_trajviz/schemas/workflow.schema.json +152 -0
  169. agent_trajviz-0.1.0/agent_trajviz/tool_vocab.py +123 -0
  170. agent_trajviz-0.1.0/agent_trajviz/views.py +762 -0
  171. agent_trajviz-0.1.0/pyproject.toml +122 -0
@@ -0,0 +1,70 @@
1
+ # Python
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+ *.so
6
+ .Python
7
+
8
+ # Virtual environments
9
+ .venv/
10
+ venv/
11
+ env/
12
+ ENV/
13
+
14
+ # Distribution / packaging
15
+ build/
16
+ dist/
17
+ *.egg-info/
18
+ *.egg
19
+ .eggs/
20
+ pip-wheel-metadata/
21
+
22
+ # Installer logs
23
+ pip-log.txt
24
+ pip-delete-this-directory.txt
25
+
26
+ # Unit test / coverage
27
+ .pytest_cache/
28
+ .coverage
29
+ .coverage.*
30
+ htmlcov/
31
+ .tox/
32
+ .nox/
33
+
34
+ # Type checking
35
+ .mypy_cache/
36
+ .pyright/
37
+ .pyre/
38
+ .ruff_cache/
39
+
40
+ # Jupyter
41
+ .ipynb_checkpoints/
42
+
43
+ # Editor/IDE
44
+ .vscode/
45
+ .idea/
46
+ *.swp
47
+ *.swo
48
+ .DS_Store
49
+
50
+ # Project-specific
51
+ # Local notes and review records: never published.
52
+ docs/
53
+ gradio_cached_examples/
54
+ *.log
55
+ *.db
56
+ .env
57
+ .env.local
58
+
59
+ # Trajectory data (keep small samples, ignore large dumps)
60
+ data/
61
+ # ...but DO track the small, hermetic DECAF-attribution test fixture, whose
62
+ # reference data lives under the `data/` subdir DECAF's layout requires.
63
+ !tests/fixtures/reference/data/
64
+ !tests/fixtures/reference/data/**
65
+ *.trajectory.json.gz
66
+ example_data
67
+ .hypothesis/
68
+
69
+ # The API reference built by pdoc (see the README).
70
+ site/
@@ -0,0 +1,172 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project are documented here. The format follows
4
+ [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and the project uses
5
+ [Semantic Versioning](https://semver.org/): before 1.0, a minor version may
6
+ change the public API (the names exported from `agent_trajviz`).
7
+
8
+ ## [0.1.0] - 2026-10-12
9
+
10
+ First release as the `agent-trajviz` package.
11
+
12
+ ### Added
13
+
14
+ - A public library API: `load()` returns a `Trajectory` (format, normalized
15
+ steps, provenance, load warnings) with cached `metrics`, `health` and
16
+ `agents`, plus `context_pressure()` and a versioned, JSON-serializable
17
+ `to_dict()`; `compare()` aligns two runs; `write_report()` writes the
18
+ standalone HTML report. Steps are described by the `Step`, `ToolCall` and
19
+ `TokenUsage` typed records; errors derive from `TrajVizError` (`LoadError`,
20
+ `ReportError`, `MissingExtraError`). The package ships `py.typed`.
21
+ - Optional extras: `charts` (figures, HTML report), `llm` (AI sidebar, Issues
22
+ judge, labeler), `app` (both dashboards) and `all`. The core needs only the
23
+ standard library, and a command whose extra is missing names it.
24
+ - Console commands: `agent-trajviz` (dashboard, or `--report` for HTML),
25
+ `agent-trajviz-converge`, `agent-trajviz-collect cursor|opencode|codearts`
26
+ and `agent-trajviz-label`; each takes `--version`. The Converge dashboard
27
+ is `python -m agent_trajviz.converge`.
28
+ - Supported formats: Claude Code, Cursor, OpenCode, CodeArts, ICode, Codex CLI,
29
+ Pi and DeepSeek Harness.
30
+ - Dashboard server options shared by both apps: `--host`, `--port`, `--share`
31
+ and `--max-file-size` (default 500 MB), and a login from
32
+ `TRAJVIZ_AUTH=user:password`. The Converge dashboard takes `--data-root`.
33
+ - `SECURITY.md`: how to report a vulnerability, and the security model.
34
+ - Python 3.14 support.
35
+ - Every chart and table as data: `Trajectory.views()` / `.view(id, **options)`
36
+ return `View`s (id, title, kind, description, JSON data) for 35 charts
37
+ and tables, listed in `VIEW_CATALOG`; the dashboard draws its charts from
38
+ exactly this data. `export_json()` writes them (`<id>.json`, `index.json`,
39
+ `trajectory.json`), as does `agent-trajviz --json RUN [-o DIR] [--view ID]`.
40
+ - A JSON Schema (draft 2020-12) for every view's data, shipped in the package:
41
+ `view_schema()`, `view_schemas()` and `agent-trajviz --schemas DIR`;
42
+ `register_view(..., schema=)` describes a view of your own. The test suite
43
+ validates every view strictly against its schema.
44
+ - The dashboard is built on the public API: it opens files with `load()`
45
+ (so formats registered by an application or a plugin open, and so do
46
+ exported `trajectory.json` files), draws its Overview and diagnostics
47
+ charts from the public views with `figures.figure()`, and keeps the
48
+ loaded `Trajectory` for the Comparison tab, the Issues judge and the HTML
49
+ export. Views added with `register_view()` get a Views tab (absent
50
+ otherwise). `write_report()` takes any `Trajectory`, including one built
51
+ with `from_steps()`.
52
+ - Extension points: `Trajectory.from_steps()` analyzes steps parsed by the
53
+ caller (missing keys are filled as for a format that does not record
54
+ them); `register_format()` with `Format` teaches `load()` a format of your
55
+ own; `register_view()` adds a view to `VIEW_CATALOG` and everything that
56
+ reads it; `figures.register_figure()` draws it; `load_plugins()` runs the
57
+ hooks installed packages declare in the `agent_trajviz.plugins`
58
+ entry-point group, as `agent-trajviz` does on start (`PluginError` names a
59
+ failing one). `FORMATS`, `VIEW_CATALOG` and `figures.FIGURE_VIEWS` are live
60
+ read-only views of the registries.
61
+ - Round trip: `Trajectory.to_dict(include_raw=True)` keeps the converted
62
+ export, `Trajectory.from_dict()` rebuilds the trajectory, and `load()`
63
+ reads such a document (the `trajectory.json` that `export_json()` writes)
64
+ back to identical views.
65
+ - The dashboard's inputs as API: `load(..., format=)` (the format selector),
66
+ view options for the context-utilization agent, window and snapshot, a
67
+ `workflow` view (the step browser's classification and filters), a
68
+ `session` view, `compare(..., anchor_patch=)`, `compare_runs()` with
69
+ `run_group_views()` (N-run scorecard), and `label_views()` /
70
+ `label_comparison_views()` (step-label sidecars).
71
+ - Optional public layers: `agent_trajviz.figures` (charts extra) draws any
72
+ chart view with the dashboard's code; `agent_trajviz.dashboard` (app
73
+ extra) launches or embeds the dashboards and turns views into Gradio
74
+ components; `agent_trajviz.llm` (llm extra) is the AI analysis and
75
+ suggested fixes, on the configured endpoint or any chat function you pass
76
+ (`chat=`), in the reply language you choose (`language=`);
77
+ `agent_trajviz.attribution` is DECAF attribution.
78
+ - `examples/`: the dashboard rebuilt on the public API alone, and a small
79
+ app of your own, both driven end to end in the test suite.
80
+
81
+ ### Changed
82
+
83
+ - The import package is `agent_trajviz` (was `trajviz`) and the dashboard
84
+ command is `agent-trajviz` (was `trajviz`). Every command carries the
85
+ `agent-trajviz` prefix; the Converge command line is
86
+ `agent-trajviz-converge` (was `trajectory-converge`).
87
+ - The collection and labeling tools moved from `scripts/` into the package.
88
+ - The step labeler is one command, `agent-trajviz-label`: `--assistant-only`
89
+ replaces the separate compatibility command, the default output is
90
+ `<input>_labeled.json`, and progress goes through `logging`. Module and
91
+ file names no longer carry version labels (`step_labeler_v2` is
92
+ `agent_trajviz.labeling.labeler`); the CodeArts tool writes
93
+ `<session>_trajectory.json`.
94
+ - Every command's entry point takes `argv` and returns its exit status: 0
95
+ success, 1 a failure caused by the input, 2 a usage error, and for
96
+ `agent-trajviz-collect codearts` 3 a partial export (was 2). Input failures
97
+ print one sentence; a genuine bug keeps its traceback.
98
+ - Library code logs through `logging` (the package root has a
99
+ `NullHandler`) instead of printing tracebacks to stderr; the commands
100
+ attach a stderr handler.
101
+ - Agent rows (`Trajectory.agents`, the Agents cards) report
102
+ `output_tokens_per_sec` -- output tokens over generation time, the same
103
+ measurement as the Overview's "gen tok/s" -- with its timed-step coverage,
104
+ instead of all tokens over wall-clock time. Cards count "assistant steps".
105
+ - Converge: the batch aggregate's `success_count`/`failure_count` are
106
+ `compared_count`/`error_count` (they counted comparisons, not successful
107
+ runs) and per-task status is `compared`/`error`; the pairwise summary says
108
+ whether each run "stopped normally" rather than "Success"/"Failure".
109
+ - Converge before/after significance is a pure-Python Wilcoxon signed-rank
110
+ test with Holm correction across metrics (`paired_significance`, was
111
+ `test_significance`), so a result no longer depends on whether SciPy is
112
+ installed.
113
+ - The Converge dashboard listens on port 7861 by default, beside Insight's
114
+ 7860.
115
+ - The AI sidebar and the Issues judge reply in English by default (was
116
+ Simplified Chinese); `ANALYZE_LANGUAGE` still picks any language, and
117
+ Simplified Chinese keeps its own prompt with Chinese headings.
118
+ - `load()` raises `LoadError` with code `unknown_format` for a file no format
119
+ recognizes, where it used to return a trajectory of format `"unknown"`
120
+ when the file happened to parse (the dashboard already refused such a
121
+ file). On a format mismatch, `LoadError.detected` names what the file is.
122
+ - Views on long runs take linear time: each shell command is lexed once
123
+ instead of once per chart that names tools.
124
+ - Dependency lower bounds are the oldest releases the suite passes with:
125
+ plotly 5.15, pygments 2.13, requests 2.32.4, pytest 8.0, hypothesis 6.100.
126
+
127
+ ### Removed
128
+
129
+ - `requirements.txt`; `pyproject.toml` is the single source of dependencies.
130
+ - The `tokens_per_second` field of agent rows (see `output_tokens_per_sec`).
131
+
132
+ ### Fixed
133
+
134
+ - A run with no tool calls reported a tool success rate of 0% ("every call
135
+ failed"); the rate is now `None` and shown as n/a.
136
+ - The per-step token chart stacked the remaining fields of a step whose
137
+ export reported an impossible count (a negative input), drawing it taller
138
+ than its own total. Such steps are drawn as their reported total in a
139
+ separate, labelled series, and the title counts them.
140
+ - The Converge dashboard resolved a manifest's relative paths against the
141
+ upload's temporary directory, so they could never be found.
142
+ - A cleared Token Rate box in the Converge dashboard raised a `TypeError`.
143
+ - `compare_runs()` refused a trajectory that was not loaded from a file, and
144
+ read a file only a registered format understands as an error.
145
+ - The anchor patch, the Converge batch manifest and cached attribution
146
+ verdicts were read in the platform's default encoding, which fails on
147
+ Windows for UTF-8 files; they are read as UTF-8, and a patch byte that is
148
+ not UTF-8 no longer drops the anchor.
149
+ - `agent-trajviz-collect opencode` printed usage examples without its
150
+ subcommand.
151
+ - Help and setup text that described a source checkout to installed users,
152
+ or claimed cache-read anomalies were left out of the token totals.
153
+
154
+ ### Security
155
+
156
+ - An exposed dashboard (`--share`, or a non-loopback `--host`) warns unless
157
+ `TRAJVIZ_AUTH` sets a login, and hides inputs that name paths on the
158
+ serving machine (the Attribution tab's reference-data root), ignoring such
159
+ a value even when a client sends one.
160
+ - Converge manifest paths must stay inside `--data-root`, `..` and symlinks
161
+ included.
162
+ - Errors shown in the Converge dashboard carry no traceback and no server
163
+ paths.
164
+ - The dashboards no longer send Gradio's usage telemetry.
165
+ - `llm.LLMConfig` no longer shows its API key when printed, logged or
166
+ shown in a traceback.
167
+ - Every LLM request (AI sidebar, Issues judge, step labeler) is redacted
168
+ before it leaves: provider API keys, tokens, JWTs, private keys, URL
169
+ passwords, authorization headers and generated-looking values of
170
+ secret-named assignments become `[REDACTED]`.
171
+
172
+ [0.1.0]: https://github.com/rshu/TrajViz/releases/tag/v0.1.0
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Rui Shu
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.