[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-107555":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":13,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":16,"stars30d":13,"stars90d":15,"forks30d":15,"starsTrendScore":17,"compositeScore":18,"rankGlobal":10,"rankLanguage":10,"license":19,"archived":20,"fork":20,"defaultBranch":21,"hasWiki":20,"hasPages":20,"topics":22,"createdAt":10,"pushedAt":23,"updatedAt":24,"readmeContent":25,"aiSummary":26,"trendingCount":15,"starSnapshotCount":15,"syncStatus":13,"lastSyncTime":27,"discoverSource":28},107555,"Trajectory2Gym","yihaohu0118\u002FTrajectory2Gym","yihaohu0118","Trajectory2Gym: Decision-Grounded Compositional Interaction Synthesis for Tool-Use Agents. Official code, training tools, and examples.","https:\u002F\u002Fyihaohu0118.github.io\u002FTrajectory2Gym-page\u002F",null,"Python",67,2,58,0,1,3,44.13,"Apache License 2.0",false,"main",[],"2026-10-24 09:53:42","2026-11-22 07:29:47","# Trajectory2Gym\n\n[![Trajectory2Gym](https:\u002F\u002Fyihaohu0118.github.io\u002FTrajectory2Gym-page\u002Fassets\u002Fposter.png)](https:\u002F\u002Fyihaohu0118.github.io\u002FTrajectory2Gym-page\u002F)\n\n**Decision-Grounded Compositional Interaction Synthesis for Tool-Use Agents**\n\n[Project Homepage](https:\u002F\u002Fyihaohu0118.github.io\u002FTrajectory2Gym-page\u002F) ·\n[Paper](https:\u002F\u002Fyihaohu0118.github.io\u002FTrajectory2Gym-page\u002Fassets\u002FTrajectory2Gym.pdf) ·\n[Dataset](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fmis2\u002FTrajectory2gym) ·\n[Checkpoints](#published-checkpoints)\n\nThis is the code release for the paper's supervised tool-use method. It\ncontains the interaction representation, decision-grounded target construction,\nstructural-support selection, parent-normalized SFT implementation, thin native\nenvironment adapters, and self-contained regression tests.\n\n## Method-to-code map\n\n| Paper component | Main code |\n| --- | --- |\n| Compositional interaction representation and synthesis | `trajectory2gym\u002Ftrajectory\u002F`, `scripts\u002Fanalysis\u002Fbuild_targeted_active_synthesis_overlay.py` |\n| Policy-visible evidence and supervised target admission | `trajectory2gym\u002Ftraining\u002Fpolicy_view.py`, `trajectory2gym\u002Ftraining\u002Fsft.py`, `scripts\u002Fanalysis\u002Frebuild_certified_candidate_pool.py` |\n| Structural-support allocation | `trajectory2gym\u002Ftraining\u002Fglobal_sft_selection.py`, `scripts\u002Fanalysis\u002Fselect_structural_support_scaling_views.py` |\n| Rendering and parent-normalized learning | `scripts\u002Fanalysis\u002Ffinalize_unified_global_sft_view.py`, `scripts\u002Fanalysis\u002Fapply_transport_parent_mass_correction.py`, `scripts\u002Ftrain\u002Ftrain_trajectory2gym_sft_view.py` |\n| Native benchmark interfaces | `env\u002Ftaubench\u002F`, `env\u002Ftau2_bench\u002F`, `env\u002Fbfcl\u002F` |\n\nThe snapshot excludes historical RL utilities. Its training-package\ninitializer exposes only the SFT interface retained here; the reported\nexperiments use ordinary assistant-token cross-entropy, not an RL objective.\n\n## Install and test\n\nUse Python 3.10 or newer. Clone the repository, then install the package:\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Fyihaohu0118\u002FTrajectory2Gym.git\ncd Trajectory2Gym\npython3 -m pip install -e \".[dev]\"\n```\n\nThe full regression suite runs on Linux and requires PyTorch and symbolic-link\nsupport. For CPU tests, install the CPU build before running the suite:\n\n```bash\npython3 -m pip install torch==2.7.0 --index-url https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcpu\npython3 -m pytest -q tests\n```\n\nFor GPU training, select the compatible build from the\n[official PyTorch installation guide](https:\u002F\u002Fpytorch.org\u002Fget-started\u002Flocally\u002F).\nGitHub Actions runs the complete CPU suite, example, and release-manifest checks\non Python 3.11; its lightweight test dependencies are in `requirements-ci.txt`.\n\nThe included tests use small synthetic inputs and do not require benchmark\ncredentials or model checkpoints. Publication-tool tests additionally cover\nmanifest integrity, sensitive-file rejection, and private-only upload guards.\n\nThe selected command-line entry points provide their arguments through\n`--help`. For example:\n\n```bash\npython3 scripts\u002Fanalysis\u002Frebuild_certified_candidate_pool.py --help\npython3 scripts\u002Fanalysis\u002Fselect_structural_support_scaling_views.py --help\npython3 scripts\u002Fanalysis\u002Ffinalize_unified_global_sft_view.py --help\npython3 scripts\u002Ftrain\u002Ftrain_trajectory2gym_sft_view.py --help\n```\n\n## Scope and reproducibility\n\nThe public candidate interactions are available at\n[mis2\u002FTrajectory2gym](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fmis2\u002FTrajectory2gym):\n34,772 semantic interactions in seven compressed JSONL shards (about 125 MB).\nThese are the common candidate pool, not the rendered scale-specific SFT\nexamples or the expanded 30B-A3B corpus. The dataset includes file checksums,\nsource provenance, target masks, and upstream license notices.\n\n## Published checkpoints\n\nAll five paper checkpoints are available with native tokenizers, chat templates,\nmodel cards, upstream licenses, and per-file release manifests:\n\n| Model | Stored precision | Weight files |\n|---|---|---:|\n| [1.7B](https:\u002F\u002Fhuggingface.co\u002Fmis2\u002FTrajectory2Gym-1.7B) | float32 | 8.1 GB |\n| [4B](https:\u002F\u002Fhuggingface.co\u002Fmis2\u002FTrajectory2Gym-4B) | float32 | 17.6 GB |\n| [8B](https:\u002F\u002Fhuggingface.co\u002Fmis2\u002FTrajectory2Gym-8B) | float32 | 32.8 GB |\n| [14B](https:\u002F\u002Fhuggingface.co\u002Fmis2\u002FTrajectory2Gym-14B) | bfloat16 | 29.5 GB |\n| [30B-A3B](https:\u002F\u002Fhuggingface.co\u002Fmis2\u002FTrajectory2Gym-30B-A3B) | bfloat16 | 61.1 GB |\n\nWeights retain their archived precision and exact safetensor bytes; no\nquantization or retraining was performed for publication. Checksums and public\naccess were verified. The reported scores are inherited experiment results,\nnot a new benchmark rerun during release. Original-precision loading can require\nmore memory than a lower-precision deployment.\n\n## Code-only archive boundaries\n\nThis archive intentionally omits raw interaction logs, training\u002Fevaluation\ntask instances, checkpoint weights, private API requests, experiment receipts,\nhost-specific launchers, and vendored third-party runtimes. Official benchmark\npackages and model weights must be obtained under their own licenses. Running\nthe full paper experiments additionally requires the released benchmark\nenvironments and the selected training data; this code snapshot alone does not\nrecreate the reported numeric results.\n\nSee [WORKFLOW](docs\u002FWORKFLOW.md) for construction and explicit training options,\nand [DATA_RELEASE](docs\u002FDATA_RELEASE.md) for reviewed data exports and private\nHugging Face staging. The generic trainer includes historical diagnostic\noptions; its defaults are not a complete paper-reproduction configuration.\n\nThe CPU-only example at examples\u002Fstructural_support_demo.py demonstrates\nnested support allocation using synthetic fixtures, without model downloads.\nThe paper's depth and learning-rate schedule is provided separately in\nconfigs\u002Fpaper_support_depths.json. The 30B-A3B study uses an expanded corpus.\n\nThe release utilities scan code and data locally, produce SHA-256 manifests,\nand build a source archive without Git history or development caches.\nUploads require an explicit execution flag and always use a private dataset\nrepository under the authenticated user's namespace.\n\n## License\n\nThis code retains the existing Apache-2.0 license in LICENSE.\nExternal models, benchmark packages, tasks, and derived datasets retain their\nrespective terms; the code license does not grant redistribution rights to\nthose assets. See [third-party notes](THIRD_PARTY.md).\n","Trajectory2Gym 是一个面向工具调用智能体的监督式训练框架，旨在将人类示范轨迹（trajectory）转化为结构化、可学习的强化学习环境（Gym-style）交互表示。其核心功能包括：基于决策依据的合成目标构建、组合式交互表征、结构支撑选择机制、父节点归一化的监督微调（SFT）实现，以及轻量原生基准环境适配器（如TAUbench、BFCL）。项目采用纯监督学习范式（非RL），避免奖励建模与策略迭代复杂性。适用于需要高保真复现人类工具使用逻辑、构建可控交互环境、或在受限算力下高效训练工具调用Agent的研究与开发场景。","2026-11-24 04:32:13","CREATED_QUERY"]