game-learning-runtime 0.2.0__tar.gz → 0.7.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 (215) hide show
  1. game_learning_runtime-0.7.0/.agents/plugins/marketplace.json +20 -0
  2. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.agents/skills/glr-adapter-builder/SKILL.md +106 -6
  3. game_learning_runtime-0.7.0/.agents/skills/glr-adapter-builder/assets/demonstration-policy.json +18 -0
  4. game_learning_runtime-0.7.0/.agents/skills/glr-adapter-builder/assets/reward-safety.json +11 -0
  5. game_learning_runtime-0.7.0/.agents/skills/glr-adapter-builder/assets/templates/AGENTS.md.template +18 -0
  6. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.agents/skills/glr-adapter-builder/assets/training-config.json +10 -2
  7. game_learning_runtime-0.7.0/.agents/skills/glr-adapter-builder/references/loader-plugins.md +70 -0
  8. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.agents/skills/glr-adapter-builder/references/research-and-reward.md +27 -0
  9. game_learning_runtime-0.7.0/.agents/skills/glr-adapter-builder/references/runtime-host.md +47 -0
  10. game_learning_runtime-0.7.0/.agents/skills/glr-adapter-builder/scripts/scaffold_adapter.py +1035 -0
  11. game_learning_runtime-0.7.0/.agents/skills/glr-cli/SKILL.md +89 -0
  12. game_learning_runtime-0.7.0/.agents/skills/glr-cli/references/commands.md +141 -0
  13. game_learning_runtime-0.7.0/.github/workflows/ci.yml +116 -0
  14. game_learning_runtime-0.7.0/.github/workflows/release.yml +227 -0
  15. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.gitignore +5 -1
  16. game_learning_runtime-0.7.0/.release-please-manifest.json +3 -0
  17. game_learning_runtime-0.7.0/CHANGELOG.md +112 -0
  18. game_learning_runtime-0.7.0/CONTRIBUTING.md +59 -0
  19. game_learning_runtime-0.7.0/Cargo.lock +1744 -0
  20. game_learning_runtime-0.7.0/Cargo.toml +31 -0
  21. game_learning_runtime-0.7.0/PKG-INFO +533 -0
  22. game_learning_runtime-0.7.0/README.md +501 -0
  23. game_learning_runtime-0.7.0/README.zh-CN.md +446 -0
  24. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/SECURITY.md +5 -0
  25. game_learning_runtime-0.7.0/crates/glr-cli/Cargo.toml +35 -0
  26. game_learning_runtime-0.7.0/crates/glr-cli/build.rs +4 -0
  27. game_learning_runtime-0.7.0/crates/glr-cli/src/args.rs +195 -0
  28. game_learning_runtime-0.7.0/crates/glr-cli/src/commands.rs +918 -0
  29. game_learning_runtime-0.7.0/crates/glr-cli/src/contracts.rs +796 -0
  30. game_learning_runtime-0.7.0/crates/glr-cli/src/error.rs +41 -0
  31. game_learning_runtime-0.7.0/crates/glr-cli/src/lib.rs +48 -0
  32. game_learning_runtime-0.7.0/crates/glr-cli/src/main.rs +3 -0
  33. game_learning_runtime-0.7.0/crates/glr-cli/src/process.rs +270 -0
  34. game_learning_runtime-0.7.0/crates/glr-cli/src/project.rs +329 -0
  35. game_learning_runtime-0.7.0/crates/glr-cli/src/store.rs +909 -0
  36. game_learning_runtime-0.7.0/crates/glr-cli/src/update.rs +590 -0
  37. game_learning_runtime-0.7.0/crates/glr-cli/tests/cli_contract.rs +259 -0
  38. game_learning_runtime-0.7.0/crates/glr-host/Cargo.toml +24 -0
  39. game_learning_runtime-0.7.0/crates/glr-host/README.md +19 -0
  40. game_learning_runtime-0.7.0/crates/glr-host/src/lib.rs +877 -0
  41. game_learning_runtime-0.7.0/crates/glr-host/src/main.rs +86 -0
  42. game_learning_runtime-0.7.0/crates/glr-host/tests/host_protocol.rs +154 -0
  43. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/architecture/data-flow.md +59 -2
  44. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/architecture/overview.md +83 -6
  45. game_learning_runtime-0.7.0/docs/assets/showcase/README.md +45 -0
  46. game_learning_runtime-0.7.0/docs/assets/showcase/glr-counter-collector.gif +0 -0
  47. game_learning_runtime-0.7.0/docs/decisions/0009-profile-engine-plugin-and-external-attach.md +120 -0
  48. game_learning_runtime-0.7.0/docs/decisions/0010-add-authorized-loader-plugins-and-reproducible-model-bundles.md +129 -0
  49. game_learning_runtime-0.7.0/docs/decisions/0011-enforce-episode-reward-and-demonstration-safety.md +116 -0
  50. game_learning_runtime-0.7.0/docs/decisions/0012-use-a-runtime-host-and-engine-provider-sdks.md +142 -0
  51. game_learning_runtime-0.7.0/docs/decisions/0013-bind-demonstration-provenance-to-trajectory-bytes.md +59 -0
  52. game_learning_runtime-0.7.0/docs/decisions/0014-inject-bounded-advisory-knowledge-contexts.md +92 -0
  53. game_learning_runtime-0.7.0/docs/decisions/0015-add-an-agent-first-local-control-plane.md +120 -0
  54. game_learning_runtime-0.7.0/docs/decisions/0016-make-the-rust-cli-the-distribution-entrypoint.md +124 -0
  55. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/README.md +8 -0
  56. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/guides/adapting-gymnasium.md +21 -0
  57. game_learning_runtime-0.7.0/docs/guides/agent-first-cli.md +218 -0
  58. game_learning_runtime-0.7.0/docs/guides/agent-first-cli.zh-CN.md +205 -0
  59. game_learning_runtime-0.7.0/docs/guides/engine-runtime-integration.md +143 -0
  60. game_learning_runtime-0.7.0/docs/guides/engine-runtime-integration.zh-CN.md +128 -0
  61. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/guides/knowledge-and-rewards.md +92 -2
  62. game_learning_runtime-0.7.0/docs/guides/loader-plugin-integration.md +110 -0
  63. game_learning_runtime-0.7.0/docs/guides/loader-plugin-integration.zh-CN.md +102 -0
  64. game_learning_runtime-0.7.0/docs/guides/reproducible-model-bundles.md +59 -0
  65. game_learning_runtime-0.7.0/docs/guides/reproducible-model-bundles.zh-CN.md +54 -0
  66. game_learning_runtime-0.7.0/docs/guides/runtime-host-and-provider-sdks.md +103 -0
  67. game_learning_runtime-0.7.0/docs/guides/runtime-host-and-provider-sdks.zh-CN.md +83 -0
  68. game_learning_runtime-0.7.0/docs/guides/training-safety.md +145 -0
  69. game_learning_runtime-0.7.0/docs/guides/training-safety.zh-CN.md +99 -0
  70. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/guides/using-torch-objectives.md +4 -1
  71. game_learning_runtime-0.7.0/docs/planning/roadmap.md +45 -0
  72. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/product/overview.md +20 -2
  73. game_learning_runtime-0.7.0/docs/runbooks/local-development.md +72 -0
  74. game_learning_runtime-0.7.0/docs/runbooks/release.md +79 -0
  75. game_learning_runtime-0.7.0/global.json +6 -0
  76. game_learning_runtime-0.7.0/justfile +104 -0
  77. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/.codex-plugin/plugin.json +40 -0
  78. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/SKILL.md +221 -0
  79. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/assets/demonstration-policy.json +18 -0
  80. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/assets/knowledge-research.json +7 -0
  81. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/assets/reward-safety.json +11 -0
  82. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/assets/templates/AGENTS.md.template +18 -0
  83. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/assets/training-config.json +48 -0
  84. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/references/loader-plugins.md +70 -0
  85. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/references/research-and-reward.md +94 -0
  86. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/references/runtime-host.md +47 -0
  87. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/references/validation-gates.md +41 -0
  88. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/scripts/scaffold_adapter.py +1035 -0
  89. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-adapter-builder/scripts/validate_research_manifest.py +187 -0
  90. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-cli/SKILL.md +89 -0
  91. game_learning_runtime-0.7.0/plugins/game-learning-runtime-skills/skills/glr-cli/references/commands.md +141 -0
  92. game_learning_runtime-0.7.0/protocol/fixtures/host-v1/describe.request.json +6 -0
  93. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/pyproject.toml +5 -2
  94. game_learning_runtime-0.7.0/release-please-config.json +53 -0
  95. game_learning_runtime-0.7.0/rust-toolchain.toml +4 -0
  96. game_learning_runtime-0.7.0/scripts/check_cpp_provider.py +86 -0
  97. game_learning_runtime-0.7.0/scripts/check_dist.py +48 -0
  98. game_learning_runtime-0.7.0/scripts/package_agent_plugin.py +156 -0
  99. game_learning_runtime-0.7.0/scripts/package_cli.py +119 -0
  100. game_learning_runtime-0.7.0/scripts/package_host.py +68 -0
  101. game_learning_runtime-0.7.0/scripts/render_readme_demo.py +162 -0
  102. game_learning_runtime-0.7.0/scripts/run_core_checks.py +45 -0
  103. game_learning_runtime-0.7.0/scripts/run_host_smoke.py +57 -0
  104. game_learning_runtime-0.7.0/sdk/cpp/include/glr/provider.hpp +96 -0
  105. game_learning_runtime-0.7.0/sdk/cpp/tests/provider_contract_smoke.cpp +15 -0
  106. game_learning_runtime-0.7.0/sdk/csharp/GameLearningRuntime.Provider/Contracts.cs +285 -0
  107. game_learning_runtime-0.7.0/sdk/csharp/GameLearningRuntime.Provider/GameLearningRuntime.Provider.csproj +19 -0
  108. game_learning_runtime-0.7.0/sdk/csharp/GameLearningRuntime.Provider/HostProtocol.cs +42 -0
  109. game_learning_runtime-0.7.0/sdk/csharp/GameLearningRuntime.Provider/IRuntimeProvider.cs +108 -0
  110. game_learning_runtime-0.7.0/sdk/csharp/GameLearningRuntime.Provider/README.md +14 -0
  111. game_learning_runtime-0.7.0/sdk/csharp/GameLearningRuntime.Provider.Smoke/GameLearningRuntime.Provider.Smoke.csproj +11 -0
  112. game_learning_runtime-0.7.0/sdk/csharp/GameLearningRuntime.Provider.Smoke/Program.cs +15 -0
  113. game_learning_runtime-0.7.0/src/game_learning_runtime/__init__.py +307 -0
  114. game_learning_runtime-0.7.0/src/game_learning_runtime/agent_goal.py +771 -0
  115. game_learning_runtime-0.7.0/src/game_learning_runtime/capture.py +398 -0
  116. game_learning_runtime-0.7.0/src/game_learning_runtime/demonstration_artifact.py +359 -0
  117. game_learning_runtime-0.7.0/src/game_learning_runtime/errors.py +26 -0
  118. game_learning_runtime-0.7.0/src/game_learning_runtime/host.py +565 -0
  119. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/integrations/gymnasium.py +15 -2
  120. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/integrations/torch_objectives.py +31 -4
  121. game_learning_runtime-0.7.0/src/game_learning_runtime/knowledge.py +392 -0
  122. game_learning_runtime-0.7.0/src/game_learning_runtime/model_bundle.py +280 -0
  123. game_learning_runtime-0.7.0/src/game_learning_runtime/project.py +342 -0
  124. game_learning_runtime-0.7.0/src/game_learning_runtime/run_store.py +1252 -0
  125. game_learning_runtime-0.7.0/src/game_learning_runtime/runtime_integration.py +435 -0
  126. game_learning_runtime-0.7.0/src/game_learning_runtime/spatial_knowledge.py +314 -0
  127. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/training.py +80 -1
  128. game_learning_runtime-0.7.0/src/game_learning_runtime/training_safety.py +476 -0
  129. game_learning_runtime-0.7.0/tests/test_agent_goal.py +409 -0
  130. game_learning_runtime-0.7.0/tests/test_agent_plugin.py +105 -0
  131. game_learning_runtime-0.7.0/tests/test_capture.py +261 -0
  132. game_learning_runtime-0.7.0/tests/test_cli_packaging.py +42 -0
  133. game_learning_runtime-0.7.0/tests/test_demonstration_artifact.py +301 -0
  134. game_learning_runtime-0.7.0/tests/test_host.py +537 -0
  135. game_learning_runtime-0.7.0/tests/test_host_packaging.py +40 -0
  136. game_learning_runtime-0.7.0/tests/test_knowledge.py +367 -0
  137. game_learning_runtime-0.7.0/tests/test_model_bundle.py +175 -0
  138. game_learning_runtime-0.7.0/tests/test_project_config.py +174 -0
  139. game_learning_runtime-0.7.0/tests/test_project_environment.py +114 -0
  140. game_learning_runtime-0.7.0/tests/test_release_metadata.py +111 -0
  141. game_learning_runtime-0.7.0/tests/test_run_store.py +420 -0
  142. game_learning_runtime-0.7.0/tests/test_runtime_integration.py +334 -0
  143. game_learning_runtime-0.7.0/tests/test_skill_scaffold.py +444 -0
  144. game_learning_runtime-0.7.0/tests/test_spatial_knowledge.py +129 -0
  145. game_learning_runtime-0.7.0/tests/test_training_safety.py +266 -0
  146. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests_optional/test_gymnasium.py +29 -0
  147. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests_optional/test_torch_objectives.py +35 -0
  148. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/uv.lock +70 -20
  149. game_learning_runtime-0.7.0/vx.lock +103 -0
  150. game_learning_runtime-0.7.0/vx.toml +31 -0
  151. game_learning_runtime-0.2.0/.agents/skills/glr-adapter-builder/scripts/scaffold_adapter.py +0 -246
  152. game_learning_runtime-0.2.0/.github/workflows/ci.yml +0 -84
  153. game_learning_runtime-0.2.0/.github/workflows/release.yml +0 -103
  154. game_learning_runtime-0.2.0/CHANGELOG.md +0 -61
  155. game_learning_runtime-0.2.0/CONTRIBUTING.md +0 -49
  156. game_learning_runtime-0.2.0/PKG-INFO +0 -257
  157. game_learning_runtime-0.2.0/README.md +0 -225
  158. game_learning_runtime-0.2.0/docs/planning/roadmap.md +0 -30
  159. game_learning_runtime-0.2.0/docs/runbooks/local-development.md +0 -48
  160. game_learning_runtime-0.2.0/docs/runbooks/release.md +0 -43
  161. game_learning_runtime-0.2.0/src/game_learning_runtime/__init__.py +0 -85
  162. game_learning_runtime-0.2.0/src/game_learning_runtime/errors.py +0 -13
  163. game_learning_runtime-0.2.0/tests/test_skill_scaffold.py +0 -125
  164. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.agents/skills/glr-adapter-builder/assets/knowledge-research.json +0 -0
  165. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.agents/skills/glr-adapter-builder/references/validation-gates.md +0 -0
  166. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.agents/skills/glr-adapter-builder/scripts/validate_research_manifest.py +0 -0
  167. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.github/CODEOWNERS +0 -0
  168. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.github/ISSUE_TEMPLATE/bug.yml +0 -0
  169. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.github/dependabot.yml +0 -0
  170. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.github/pull_request_template.md +0 -0
  171. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.github/workflows/reusable-python-ci.yml +0 -0
  172. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/.python-version +0 -0
  173. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/CODE_OF_CONDUCT.md +0 -0
  174. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/LICENSE +0 -0
  175. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/benchmarks/README.md +0 -0
  176. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/benchmarks/__init__.py +0 -0
  177. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/benchmarks/data_plane.py +0 -0
  178. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/benchmarks/2026-08-31-data-plane-baseline.md +0 -0
  179. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/0001-learner-neutral-runtime.md +0 -0
  180. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/0002-versioned-tensor-contracts.md +0 -0
  181. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/0003-gymnasium-compatibility-boundary.md +0 -0
  182. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/0004-benchmark-gated-rust-data-plane.md +0 -0
  183. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/0005-share-objectives-not-learners.md +0 -0
  184. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/0006-distinguish-live-attach-from-reset.md +0 -0
  185. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/0007-standardize-bridge-lifecycle.md +0 -0
  186. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/decisions/0008-configure-knowledge-and-rewards-as-data.md +0 -0
  187. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/guides/adapter-conformance.md +0 -0
  188. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/guides/getting-started.md +0 -0
  189. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/docs/guides/runtime-bridges.md +0 -0
  190. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/scripts/verify_release.py +0 -0
  191. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/bridge.py +0 -0
  192. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/collector.py +0 -0
  193. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/contracts.py +0 -0
  194. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/environment.py +0 -0
  195. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/examples/__init__.py +0 -0
  196. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/examples/counter.py +0 -0
  197. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/integrations/__init__.py +0 -0
  198. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/integrations/torchrl.py +0 -0
  199. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/protocol/__init__.py +0 -0
  200. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/protocol/glr/v1/runtime.proto +0 -0
  201. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/py.typed +0 -0
  202. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/serialization.py +0 -0
  203. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/specs.py +0 -0
  204. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/src/game_learning_runtime/testing.py +0 -0
  205. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_benchmarking.py +0 -0
  206. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_bridge.py +0 -0
  207. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_collector.py +0 -0
  208. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_conformance_profiles.py +0 -0
  209. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_contracts.py +0 -0
  210. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_environment.py +0 -0
  211. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_protocol.py +0 -0
  212. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_serialization.py +0 -0
  213. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_specs.py +0 -0
  214. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests/test_training_config.py +0 -0
  215. {game_learning_runtime-0.2.0 → game_learning_runtime-0.7.0}/tests_optional/test_torchrl.py +0 -0
@@ -0,0 +1,20 @@
1
+ {
2
+ "name": "game-learning-runtime",
3
+ "interface": {
4
+ "displayName": "GameLearningRuntime"
5
+ },
6
+ "plugins": [
7
+ {
8
+ "name": "game-learning-runtime-skills",
9
+ "source": {
10
+ "source": "local",
11
+ "path": "./plugins/game-learning-runtime-skills"
12
+ },
13
+ "policy": {
14
+ "installation": "AVAILABLE",
15
+ "authentication": "ON_INSTALL"
16
+ },
17
+ "category": "Developer Tools"
18
+ }
19
+ ]
20
+ }
@@ -10,6 +10,16 @@ Build the smallest truthful adapter that exposes game semantics through GLR.
10
10
  Keep `Game Adapter != RL Algorithm`: the runtime side never imports PPO,
11
11
  IMPALA, BC, TorchRL, or a learner policy.
12
12
 
13
+ ## Resolve bundled files portably
14
+
15
+ This skill is distributed both from a repository checkout and from a plugin
16
+ installation. Resolve the skill root as the directory containing this
17
+ `SKILL.md`; all `scripts/`, `assets/`, and `references/` paths below are
18
+ relative to that root. Do not hard-code a repository-relative `.agents/skills`
19
+ path or a user-profile installation path. When a command is run from the
20
+ project root, set `$skillRoot` to that resolved directory and pass the
21
+ absolute path to the same script from the installed skill root.
22
+
13
23
  ## Start with explicit boundaries
14
24
 
15
25
  Before editing, state:
@@ -29,17 +39,55 @@ Run the deterministic scaffold once. Choose a generic public environment ID and
29
39
  Python package name; do not put a game account, host, PID, HWND, local path, or
30
40
  secret in either value.
31
41
 
42
+ For a Unity or Unreal project with source access, create an engine-plugin lane:
43
+
32
44
  ```powershell
33
- python .agents/skills/glr-adapter-builder/scripts/scaffold_adapter.py `
45
+ # Set $skillRoot to the directory containing this SKILL.md before running.
46
+ vx python "$skillRoot/scripts/scaffold_adapter.py" `
34
47
  --output adapters/example_adapter `
35
48
  --package example_adapter `
36
49
  --environment-id example.environment-v1 `
37
- --start-mode reset
50
+ --engine unity `
51
+ --access source
52
+ ```
53
+
54
+ For an authorized binary-only runtime, create a truthful external-attach lane:
55
+
56
+ ```powershell
57
+ vx python "$skillRoot/scripts/scaffold_adapter.py" `
58
+ --output adapters/example_external `
59
+ --package example_external `
60
+ --environment-id example.external-v1 `
61
+ --engine unreal `
62
+ --access external
63
+ ```
64
+
65
+ For an authorized Unity Mono or Unreal runtime that permits third-party mods,
66
+ read [loader-plugins.md](references/loader-plugins.md) completely, verify one
67
+ compatible upstream release, and create a loader-plugin lane:
68
+
69
+ ```powershell
70
+ vx python "$skillRoot/scripts/scaffold_adapter.py" `
71
+ --output adapters/example_loader `
72
+ --package example_loader `
73
+ --environment-id example.loader-v1 `
74
+ --engine unity `
75
+ --access loader `
76
+ --loader bepinex `
77
+ --loader-version v5.4.23.5
38
78
  ```
39
79
 
80
+ Use `--engine unreal --loader ue4ss --loader-version v3.0.1` for the UE4SS
81
+ template. Release numbers are examples, not universal compatibility claims;
82
+ refresh them from official upstream sources before scaffolding.
83
+
40
84
  The generated environment is an explicitly synthetic, trainable seam. Replace
41
85
  its semantics through Red-Green-Refactor while keeping its conformance and
42
86
  configuration tests green. Never present the synthetic seam as live acceptance.
87
+ Loader lanes additionally emit an empty-deny action vocabulary, bounded
88
+ main-thread host skeleton, exact upstream deployment manifest, staged-package
89
+ command, and Agent instructions. They never install into a discovered game
90
+ directory.
43
91
 
44
92
  ## Research gameplay before defining the contract
45
93
 
@@ -80,6 +128,13 @@ Use `glr.training.v1` in `training.json`.
80
128
  `minimum_authority: advisory`, documented, bounded, and ablated in tests.
81
129
  - Use named scalar signals and `RewardComposer`; never use `eval`, expressions,
82
130
  imports, or callbacks loaded from configuration.
131
+ - Route composed signals through `EpisodeRewardGuard` using
132
+ `reward-safety.json`. Bound positive shaping per step and episode, require an
133
+ authoritative terminal outcome, and make failed-episode return non-positive.
134
+ - Validate every BC sample or trajectory with `DemonstrationGate` and
135
+ `demonstration-policy.json`. Default-deny policy-generated, failed, and
136
+ unknown-provenance samples; never train BC on the learner's own output as if
137
+ it were expert data.
83
138
 
84
139
  ## Implement the adapter contract
85
140
 
@@ -98,14 +153,39 @@ For process boundaries, compose `BridgeEnvironment -> BridgeDriver -> transport
98
153
  deadlines, framing, bounded payloads, target binding, and queue backpressure.
99
154
  GLR owns the environment lifecycle and learner-facing contract.
100
155
 
156
+ ## Reuse the Runtime Host provider boundary
157
+
158
+ Read [runtime-host.md](references/runtime-host.md) completely before adding a
159
+ new source, loader, or external runtime bridge. Prefer the shared provider
160
+ vocabulary over inventing another environment envelope:
161
+
162
+ - Unity/.NET semantic providers implement `IRuntimeProvider` from
163
+ `sdk/csharp/GameLearningRuntime.Provider`;
164
+ - Unreal/native semantic providers implement `glr::runtime_provider` from
165
+ `sdk/cpp/include/glr/provider.hpp`;
166
+ - training clients use Python `HostBridgeDriver` behind `BridgeEnvironment`;
167
+ and
168
+ - engine-specific official/BepInEx/UE4SS code remains a thin reviewed
169
+ bootstrap and main-thread dispatcher.
170
+
171
+ The current `glr-hostd` release contains only the synthetic conformance
172
+ provider over bounded stdio. Do not claim that a generated live C#/C++ provider
173
+ is connected, authenticated, or target-bound until the local provider transport
174
+ and a bounded authorized runtime trace prove those capabilities.
175
+
176
+ For a project that already has a reviewed bridge, hand operation to the
177
+ separate `glr-cli` Skill. The standalone Rust `glr` executable is the canonical
178
+ deployment and control entrypoint; use `glr --project . --json doctor` to check
179
+ the generated project boundary. Do not add a Python console-script wrapper or
180
+ make an adapter depend on the CLI implementation.
181
+
101
182
  ## Validate in increasing-risk order
102
183
 
103
184
  Read [validation-gates.md](references/validation-gates.md) completely, then run:
104
185
 
105
186
  ```powershell
106
- uv run pytest
107
- uv run mypy src
108
- uv run ruff check .
187
+ vx setup
188
+ vx run check
109
189
  ```
110
190
 
111
191
  Also run adapter-specific synthetic conformance, stale-request tests, malformed
@@ -113,9 +193,29 @@ payload tests, and a bounded authorized runtime trace when available. Publish
113
193
  only aggregate conformance evidence. A headless test does not prove live game
114
194
  acceptance.
115
195
 
196
+ ## Package training evidence for reproduction
197
+
198
+ Run `vx run train` to exercise the generated deterministic synthetic BC smoke
199
+ test, then `vx run reproduce` to verify its `glr.model-bundle.v1` manifest.
200
+ Replace the smoke trainer with PPO, IMPALA, BC, or another learner outside the
201
+ runtime adapter, while continuing to bundle:
202
+
203
+ - the exact training and runtime-integration configuration;
204
+ - reward-safety and demonstration-provenance policies;
205
+ - source snapshots and dependency lock files;
206
+ - every learner/environment seed;
207
+ - algorithm and framework versions; and
208
+ - checksummed model artifacts and aggregate metrics.
209
+
210
+ A verified bundle proves artifact integrity and captures a reproduction
211
+ environment. It does not prove equivalent hardware behavior, a live runtime
212
+ integration, or model quality.
213
+
116
214
  ## Rust decision gate
117
215
 
118
216
  Keep semantic integration and fast-changing contracts in the simplest safe
119
217
  language. Move serialization, shared-memory, framing, or batch conversion to
120
218
  Rust only after a reproducible benchmark shows that boundary dominates the
121
- target workload. Preserve Python reference behavior and cross-language fixtures.
219
+ target workload. The standalone Rust CLI is a distribution/control-plane
220
+ decision, not permission to move game semantics or learner algorithms into
221
+ Rust. Preserve Python reference behavior and cross-language fixtures.
@@ -0,0 +1,18 @@
1
+ {
2
+ "schema_version": "glr.demonstration-policy.v1",
3
+ "allowed_origins": [
4
+ "human",
5
+ "scripted-expert"
6
+ ],
7
+ "allowed_outcomes": [
8
+ "success"
9
+ ],
10
+ "origin_weights": {
11
+ "human": 1,
12
+ "scripted-expert": 1
13
+ },
14
+ "outcome_weights": {
15
+ "success": 1
16
+ },
17
+ "reject_unknown": true
18
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "schema_version": "glr.reward-safety.v1",
3
+ "outcome_signal": "outcome",
4
+ "shaping_signals": [
5
+ "progress"
6
+ ],
7
+ "max_positive_shaping_per_step": 1,
8
+ "max_positive_shaping_per_episode": 10,
9
+ "failure_episode_maximum": 0,
10
+ "require_terminal_outcome": true
11
+ }
@@ -0,0 +1,18 @@
1
+ # Agent instructions for @@PACKAGE@@
2
+
3
+ Operate only an owned or explicitly authorized offline/test runtime. @@LOADER_NOTE@@
4
+
5
+ - Read `agent-interface.json`, `runtime-integration.json`, `training.json`,
6
+ `reward-safety.json`, and `demonstration-policy.json` before editing.
7
+ - Keep `action_vocabulary` empty until every action has a reviewed semantic mapping.
8
+ - Reject unknown operations and stale episode or expected-step identities.
9
+ - Dispatch engine mutations on the game/main thread and return verified post-state.
10
+ - Treat gameplay research as advisory; never expand authority from a guide.
11
+ - Route composed rewards through `EpisodeRewardGuard`; a terminal failure must
12
+ never remain profitable after shaping.
13
+ - Validate every BC trajectory with `DemonstrationGate`; never relabel policy
14
+ output or unknown provenance as expert data.
15
+ - Never add reflection search, arbitrary script/call endpoints, process discovery,
16
+ anti-cheat bypasses, credentials, or local machine identifiers.
17
+ - Run `vx run check`, then `vx run train` and `vx run reproduce`.
18
+ - Publish only aggregate synthetic conformance until a bounded authorized live trace exists.
@@ -24,8 +24,8 @@
24
24
  }
25
25
  ],
26
26
  "reward": {
27
- "minimum": -1,
28
- "maximum": 1,
27
+ "minimum": -20,
28
+ "maximum": 20,
29
29
  "terms": [
30
30
  {
31
31
  "name": "progress",
@@ -34,6 +34,14 @@
34
34
  "minimum": -1,
35
35
  "maximum": 1,
36
36
  "required": true
37
+ },
38
+ {
39
+ "name": "outcome",
40
+ "source": "runtime",
41
+ "weight": 10,
42
+ "minimum": -1,
43
+ "maximum": 1,
44
+ "required": false
37
45
  }
38
46
  ]
39
47
  }
@@ -0,0 +1,70 @@
1
+ # Authorized loader-plugin integrations
2
+
3
+ Use a loader plugin only when the runtime owner permits mods or instrumentation
4
+ and the test is offline or otherwise explicitly authorized. Check the game
5
+ license, mod policy, anti-cheat policy, engine/runtime version, and exact loader
6
+ release before generating code.
7
+
8
+ ## Choose a supported lane
9
+
10
+ | Lane | First supported host | Upstream | Default truth |
11
+ | --- | --- | --- | --- |
12
+ | BepInEx | Unity Mono on BepInEx 5 LTS | <https://github.com/BepInEx/BepInEx> | live attach, real time |
13
+ | UE4SS | Unreal Lua mod on UE4SS 3.x | <https://github.com/UE4SS-RE/RE-UE4SS> | live attach, real time |
14
+
15
+ BepInEx IL2CPP and UE4SS C++ templates are not generated yet. Do not silently
16
+ substitute them for the supported variants. Record the exact compatible
17
+ upstream tag in `deployment/loader.json`; never use `latest` in a reproducible
18
+ adapter.
19
+
20
+ ## Preserve the loader boundary
21
+
22
+ The loader hosts reviewed game-semantic code inside the runtime. The learner
23
+ stays outside through authenticated, target-bound local IPC. The host must:
24
+
25
+ 1. start a fresh logical GLR episode with `attach`, not claim a physical reset;
26
+ 2. keep the action vocabulary empty until reviewed handlers exist;
27
+ 3. reject unknown, stale, oversized, or excess queued commands;
28
+ 4. apply mutations on the engine/game thread;
29
+ 5. return authoritative post-state before advancing the GLR step; and
30
+ 6. remove hooks and release owned state when closed or reloaded.
31
+
32
+ Reuse the engine-neutral provider contracts when the selected runtime can load
33
+ them: C# `IRuntimeProvider` for Unity Mono/BepInEx and C++
34
+ `glr::runtime_provider` for a reviewed native Unreal lane. The current
35
+ `glr-hostd` stdio conformance transport is not authenticated or target-bound and
36
+ therefore cannot yet satisfy this loader boundary by itself.
37
+
38
+ Do not add object dumpers, unrestricted reflection/object search, arbitrary Lua
39
+ or C# evaluation, generic function calls, process scanning, stealth loading,
40
+ anti-cheat bypasses, or credential access. A loader's upstream capabilities do
41
+ not become GLR action authority.
42
+
43
+ ## Stage deployment without selecting a game for the agent
44
+
45
+ Run `vx run package-runtime` after the declared host artifact exists. The
46
+ generated packager validates only portable relative paths and writes a
47
+ checksummed payload under `.glr-dist/`. It does not discover, select, or modify
48
+ a game directory. An operator must choose the exact authorized target and
49
+ perform or approve installation separately.
50
+
51
+ For BepInEx, build the reviewed C# project against operator-provided
52
+ `BEPINEX_ROOT` and `GAME_MANAGED_ROOT` values. Never commit those values. For
53
+ UE4SS, stage the generated Lua mod as data and keep its action table deny-empty
54
+ until the adapter implementation and negative tests are reviewed.
55
+
56
+ ## Validate
57
+
58
+ - Parse `runtime-integration.json` and prove every required capability.
59
+ - Verify `agent-interface.json` still denies unknown operations.
60
+ - Exercise queue overflow, stale episode/step, unknown action, failed
61
+ postcondition, reload, and disconnect tests.
62
+ - Run synthetic conformance and the reproducible model-bundle smoke test.
63
+ - Treat actual loader startup and live-game behavior as a separate bounded
64
+ acceptance gate.
65
+
66
+ Official references:
67
+
68
+ - <https://docs.bepinex.dev/master/articles/dev_guide/plugin_tutorial/index.html>
69
+ - <https://docs.ue4ss.com/dev/guides/creating-a-lua-mod.html>
70
+ - <https://docs.ue4ss.com/dev/lua-api/global-functions/executeingamethread.html>
@@ -52,6 +52,33 @@ produce.
52
52
  signals.
53
53
  7. Run ablations for each shaping term and inspect behavior, not just return.
54
54
 
55
+ ## Enforce episode-level reward safety
56
+
57
+ Term clipping alone does not prevent hundreds of small positive events from
58
+ overwhelming a loss. Load `reward-safety.json` and route every composed step
59
+ through `EpisodeRewardGuard`:
60
+
61
+ - declare exactly one authoritative, terminal-only outcome signal;
62
+ - cap positive shaping per step and cumulatively per episode;
63
+ - require the outcome signal on every terminal transition;
64
+ - set a failure episode ceiling so a loss cannot retain a positive return; and
65
+ - log accepted and suppressed shaping plus any terminal correction.
66
+
67
+ Treat the correction as a guardrail, not a substitute for reward design. Audit
68
+ how often it fires and reduce or remove shaping terms that repeatedly consume
69
+ the budget without improving the terminal objective.
70
+
71
+ ## Gate behavioral-cloning data
72
+
73
+ Every BC trajectory must carry an immutable origin and authoritative episode
74
+ outcome. Load `demonstration-policy.json` and call `DemonstrationGate.validate`
75
+ before adding it to a dataset. The scaffold defaults to successful human or
76
+ scripted-expert trajectories and rejects policy output, failed episodes, and
77
+ unknown provenance. Weighting is explicit data so outcome/origin weighting can
78
+ be reviewed and reproduced. Policy-generated samples may only enter a separate,
79
+ deliberately configured distillation workflow; never silently relabel them as
80
+ expert demonstrations.
81
+
55
82
  Guide-derived recommendations may seed a `reward-hypothesis`, but they remain
56
83
  advisory until runtime evidence validates the underlying signal. Even after
57
84
  validation, the guide is provenance for the hypothesis; the runtime is the
@@ -0,0 +1,47 @@
1
+ # Runtime Host and provider SDK boundary
2
+
3
+ Use the Runtime Host to reuse protocol and lifecycle behavior, not to bypass an
4
+ engine's supported loading boundary.
5
+
6
+ ## Current reusable pieces
7
+
8
+ - Rust `glr`: canonical standalone deployment and Agent control entrypoint. Its
9
+ release archive carries the matching Runtime Host and both GLR Skills.
10
+ - Rust `glr-hostd`: strict `glr.host.v1`, serialized stdio, 1 MiB hard frame
11
+ bound, episode/step fencing, synthetic conformance provider.
12
+ - Python `HostBridgeDriver`: explicit absolute executable, no shell, bounded
13
+ response deadline, no mutating retry, child cleanup.
14
+ - C# `IRuntimeProvider`: .NET Standard 2.0 Unity/BepInEx-compatible semantic
15
+ provider contract.
16
+ - C++ `glr::runtime_provider`: header-only C++20 Unreal/native semantic provider
17
+ contract.
18
+
19
+ Run `vx just host-smoke` and `vx just provider-sdk-check` before adapting these
20
+ surfaces. Preserve flattened dot-separated tensor paths and little-endian GLR
21
+ v1 tensor bytes.
22
+
23
+ Run `glr --project . --json doctor` before using an existing adapter project.
24
+ Use the separate `glr-cli` Skill for training, capture, queries, knowledge
25
+ transfer, playback, or explicitly authorized `glr update` maintenance.
26
+
27
+ ## Bootstrap choice
28
+
29
+ | Runtime access | Bootstrap | Provider contract |
30
+ | --- | --- | --- |
31
+ | Unity source | Official Unity plugin/assembly | C# `IRuntimeProvider` |
32
+ | Unreal source | Official Unreal Runtime Module | C++ `runtime_provider` |
33
+ | Unity Mono, authorized mods | Exact compatible BepInEx | C# `IRuntimeProvider` |
34
+ | Unreal, authorized mods | Exact compatible UE4SS or official SDK | C++ provider when native support is reviewed; Lua remains a bounded shim |
35
+ | External official API | Explicit external adapter | Python `BridgeDriver` or future Host provider transport |
36
+
37
+ Do not generate a universal injector, arbitrary dynamic-library path, process
38
+ scanner, reflection/object dumper, script evaluator, anti-cheat bypass, or
39
+ automatic installation step.
40
+
41
+ ## Capability truth
42
+
43
+ `host-stdio` proves only one ordered local child-process session. It does not
44
+ prove authentication, OS process identity, exact game target binding, main
45
+ thread dispatch, physical reset, or live post-state. These capabilities belong
46
+ to a future authenticated local provider connection plus the specific engine
47
+ adapter and must fail closed until implemented and accepted live.