lcode-cli 0.59.0__tar.gz → 0.60.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 (263) hide show
  1. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/PULL_REQUEST_TEMPLATE.md +1 -1
  2. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/workflows/ci.yml +2 -0
  3. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/AGENTS.md +1 -0
  4. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/CHANGELOG.md +24 -1
  5. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/CONTRIBUTING.md +2 -1
  6. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/PKG-INFO +1 -1
  7. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/how-it-works.md +8 -5
  8. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/public-benchmarks.md +11 -1
  9. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/quickstart.md +1 -1
  10. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/pyproject.toml +13 -1
  11. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/__init__.py +1 -1
  12. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/acp.py +22 -2
  13. lcode_cli-0.60.0/src/lcode/agent.py +683 -0
  14. lcode_cli-0.60.0/src/lcode/agent_base.py +211 -0
  15. lcode_cli-0.60.0/src/lcode/agent_checks.py +136 -0
  16. lcode_cli-0.60.0/src/lcode/agent_context.py +165 -0
  17. lcode_cli-0.60.0/src/lcode/agent_model.py +318 -0
  18. lcode_cli-0.60.0/src/lcode/agent_prompt.py +304 -0
  19. lcode_cli-0.60.0/src/lcode/agent_sessions.py +157 -0
  20. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/api.py +3 -3
  21. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/assistant.py +2 -1
  22. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/bench.py +3 -671
  23. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/bench_backend.py +1 -1
  24. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/bench_budgets.py +1 -1
  25. lcode_cli-0.60.0/src/lcode/bench_checks.py +61 -0
  26. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/bench_dedupe.py +1 -1
  27. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/bench_flaky.py +2 -2
  28. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/bench_logsum.py +1 -1
  29. lcode_cli-0.60.0/src/lcode/bench_quick.py +650 -0
  30. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/bench_quotes.py +1 -1
  31. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/bench_runtime.py +1 -1
  32. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/catalog.py +1 -1
  33. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/checks.py +1 -1
  34. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/cli.py +19 -491
  35. lcode_cli-0.60.0/src/lcode/cli_args.py +230 -0
  36. lcode_cli-0.60.0/src/lcode/clips.py +68 -0
  37. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/comfy.py +5 -4
  38. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/config.py +1 -1
  39. lcode_cli-0.60.0/src/lcode/doctor.py +275 -0
  40. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/edits.py +3 -2
  41. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/escalate.py +2 -2
  42. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/extensions.py +2 -2
  43. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/film.py +4 -4
  44. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/harbor.py +6 -5
  45. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/harbor_bench.py +100 -9
  46. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/hooks.py +1 -1
  47. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/imageopts.py +5 -4
  48. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/lsp.py +6 -5
  49. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/manual.py +5 -4
  50. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/matching.py +2 -2
  51. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/auth.py +2 -1
  52. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/catalog.py +4 -3
  53. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/config.py +9 -7
  54. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/manager.py +2 -1
  55. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/server.py +4 -4
  56. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/media.py +6 -394
  57. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/media_catalog.py +1 -1
  58. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/media_cloud.py +2 -2
  59. lcode_cli-0.60.0/src/lcode/media_video.py +377 -0
  60. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/permissions.py +1 -1
  61. lcode_cli-0.60.0/src/lcode/qt_hook.py +317 -0
  62. lcode_cli-0.60.0/src/lcode/repl.py +860 -0
  63. lcode_cli-0.60.0/src/lcode/repl_history.py +297 -0
  64. lcode_cli-0.60.0/src/lcode/repl_media.py +334 -0
  65. lcode_cli-0.60.0/src/lcode/repl_models.py +311 -0
  66. lcode_cli-0.60.0/src/lcode/repl_sessions.py +137 -0
  67. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/replay.py +6 -5
  68. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/review.py +2 -1
  69. lcode_cli-0.60.0/src/lcode/screenshots.py +677 -0
  70. lcode_cli-0.60.0/src/lcode/screenshots_web.py +400 -0
  71. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/servers/encord.py +3 -2
  72. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/servers/valohai.py +1 -1
  73. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/sessions.py +3 -2
  74. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/steer.py +16 -9
  75. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/subagents.py +3 -3
  76. lcode_cli-0.60.0/src/lcode/tool_helpers.py +128 -0
  77. lcode_cli-0.60.0/src/lcode/tool_schemas.py +319 -0
  78. lcode_cli-0.60.0/src/lcode/tools.py +579 -0
  79. lcode_cli-0.60.0/src/lcode/tools_base.py +78 -0
  80. lcode_cli-0.60.0/src/lcode/tools_edit.py +222 -0
  81. lcode_cli-0.60.0/src/lcode/tools_shell.py +248 -0
  82. lcode_cli-0.60.0/src/lcode/trace_export.py +184 -0
  83. lcode_cli-0.60.0/src/lcode/trace_view.py +313 -0
  84. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/traces.py +9 -452
  85. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_acp.py +39 -11
  86. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_agent.py +1 -1
  87. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_bench.py +6 -6
  88. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_comfy.py +7 -7
  89. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_context_picker.py +2 -1
  90. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_conversations.py +2 -2
  91. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_gitflow.py +1 -1
  92. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_harbor_bench.py +68 -2
  93. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_long_clips.py +7 -7
  94. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_media_cloud.py +3 -3
  95. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_screenshots.py +21 -18
  96. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_tools.py +1 -1
  97. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_traces.py +29 -26
  98. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_video.py +2 -2
  99. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/uv.lock +32 -2
  100. lcode_cli-0.59.0/src/lcode/agent.py +0 -1775
  101. lcode_cli-0.59.0/src/lcode/repl.py +0 -1848
  102. lcode_cli-0.59.0/src/lcode/screenshots.py +0 -1362
  103. lcode_cli-0.59.0/src/lcode/tools.py +0 -1454
  104. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.editorconfig +0 -0
  105. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/CODEOWNERS +0 -0
  106. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/ISSUE_TEMPLATE/bug_report.yml +0 -0
  107. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/ISSUE_TEMPLATE/config.yml +0 -0
  108. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/ISSUE_TEMPLATE/feature_request.yml +0 -0
  109. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/ISSUE_TEMPLATE/model_request.yml +0 -0
  110. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/dependabot.yml +0 -0
  111. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/workflows/docs.yml +0 -0
  112. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.github/workflows/release.yml +0 -0
  113. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.gitignore +0 -0
  114. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/.pre-commit-config.yaml +0 -0
  115. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/CODE_OF_CONDUCT.md +0 -0
  116. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/LICENSE +0 -0
  117. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/README.md +0 -0
  118. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/SECURITY.md +0 -0
  119. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/action.yml +0 -0
  120. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/agents.md +0 -0
  121. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/assets/demo.svg +0 -0
  122. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/assets/extra.css +0 -0
  123. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/assets/film-fox-and-kitten.jpg +0 -0
  124. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/assets/long-clip-tulip.jpg +0 -0
  125. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/automation.md +0 -0
  126. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/bench.md +0 -0
  127. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/changelog.md +0 -0
  128. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/commands.md +0 -0
  129. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/configuration.md +0 -0
  130. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/contributing.md +0 -0
  131. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/editors.md +0 -0
  132. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/git.md +0 -0
  133. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/hooks.md +0 -0
  134. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/index.md +0 -0
  135. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/installation.md +0 -0
  136. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/lsp.md +0 -0
  137. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/mcp.md +0 -0
  138. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/memory.md +0 -0
  139. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/models.md +0 -0
  140. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/modes.md +0 -0
  141. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/sandbox.md +0 -0
  142. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/search.md +0 -0
  143. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/servers.md +0 -0
  144. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/traces.md +0 -0
  145. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/troubleshooting.md +0 -0
  146. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/docs/usage.md +0 -0
  147. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/examples/README.md +0 -0
  148. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/examples/api/fix_tests.py +0 -0
  149. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/examples/commands/review.md +0 -0
  150. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/examples/skills/commit-message/SKILL.md +0 -0
  151. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/examples/skills/commit-message/scripts/staged.sh +0 -0
  152. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/install.sh +0 -0
  153. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/mkdocs.yml +0 -0
  154. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/overrides/main.html +0 -0
  155. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/scripts/make_logos.py +0 -0
  156. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/scripts/record_demo.py +0 -0
  157. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/scripts/social-preview.html +0 -0
  158. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/__main__.py +0 -0
  159. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/action.py +0 -0
  160. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/backends.py +0 -0
  161. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/checkpoints.py +0 -0
  162. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/clipboard.py +0 -0
  163. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/cloud.py +0 -0
  164. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/codesearch.py +0 -0
  165. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/context.py +0 -0
  166. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/frontmatter.py +0 -0
  167. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/gitflow.py +0 -0
  168. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/hardware.py +0 -0
  169. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/jobs.py +0 -0
  170. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/limits.py +0 -0
  171. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/__init__.py +0 -0
  172. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/catalog.toml +0 -0
  173. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/client.py +0 -0
  174. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/commands.py +0 -0
  175. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/http.py +0 -0
  176. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/protocol.py +0 -0
  177. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/mcp/stdio.py +0 -0
  178. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/media.toml +0 -0
  179. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/memory.py +0 -0
  180. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/models.toml +0 -0
  181. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/modes.py +0 -0
  182. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/notify.py +0 -0
  183. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/ollama.py +0 -0
  184. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/planning.py +0 -0
  185. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/preview.py +0 -0
  186. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/render.py +0 -0
  187. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/repeats.py +0 -0
  188. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/repoid.py +0 -0
  189. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/repomap.py +0 -0
  190. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/residency.py +0 -0
  191. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/sandbox.py +0 -0
  192. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/secretscan.py +0 -0
  193. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/servers/__init__.py +0 -0
  194. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/servers/xai.py +0 -0
  195. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/unreachable.py +0 -0
  196. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/update.py +0 -0
  197. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/vision.py +0 -0
  198. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/web.py +0 -0
  199. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/__init__.py +0 -0
  200. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/flux2-klein-4b-t2i.json +0 -0
  201. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/remove-background.json +0 -0
  202. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/smooth-film.json +0 -0
  203. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/sound-stable-audio.json +0 -0
  204. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/upscale-esrgan.json +0 -0
  205. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/upscale-video-esrgan.json +0 -0
  206. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/wan21-fun-camera.json +0 -0
  207. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/wan21-vace.json +0 -0
  208. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/wan22-fun-inp-5b.json +0 -0
  209. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/wan22-ti2v-5b.json +0 -0
  210. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/src/lcode/workflows/z-image-turbo-t2i.json +0 -0
  211. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/comfy_standin.py +0 -0
  212. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/conftest.py +0 -0
  213. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/fake_lsp_server.py +0 -0
  214. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/fake_mcp_server.py +0 -0
  215. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_action.py +0 -0
  216. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_api.py +0 -0
  217. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_assistant.py +0 -0
  218. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_backends.py +0 -0
  219. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_bench_work.py +0 -0
  220. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_catalog.py +0 -0
  221. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_checkpoints.py +0 -0
  222. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_checks.py +0 -0
  223. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_cli.py +0 -0
  224. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_clipboard.py +0 -0
  225. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_cloud.py +0 -0
  226. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_codesearch.py +0 -0
  227. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_config.py +0 -0
  228. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_context.py +0 -0
  229. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_escalate.py +0 -0
  230. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_extensions.py +0 -0
  231. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_film.py +0 -0
  232. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_gpu_handover.py +0 -0
  233. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_hooks.py +0 -0
  234. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_image_edit.py +0 -0
  235. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_image_generate.py +0 -0
  236. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_jobs.py +0 -0
  237. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_look.py +0 -0
  238. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_lsp.py +0 -0
  239. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_manual.py +0 -0
  240. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_matching.py +0 -0
  241. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_mcp.py +0 -0
  242. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_media_catalog.py +0 -0
  243. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_memory.py +0 -0
  244. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_model_picker.py +0 -0
  245. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_modes.py +0 -0
  246. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_permissions.py +0 -0
  247. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_plan_mode.py +0 -0
  248. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_repeats.py +0 -0
  249. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_repomap.py +0 -0
  250. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_residency.py +0 -0
  251. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_review.py +0 -0
  252. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_robustness.py +0 -0
  253. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_sandbox.py +0 -0
  254. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_secretscan.py +0 -0
  255. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_servers.py +0 -0
  256. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_sessions.py +0 -0
  257. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_steer.py +0 -0
  258. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_stuck.py +0 -0
  259. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_subagents.py +0 -0
  260. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_update.py +0 -0
  261. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_vision.py +0 -0
  262. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_web.py +0 -0
  263. {lcode_cli-0.59.0 → lcode_cli-0.60.0}/tests/test_xai.py +0 -0
@@ -8,7 +8,7 @@
8
8
 
9
9
  ## Checklist
10
10
 
11
- - [ ] `uv run pytest` and `uv run ruff check .` pass
11
+ - [ ] `uv run pytest`, `uv run ruff check .` and `uv run basedpyright` pass
12
12
  - [ ] Tests cover the change
13
13
  - [ ] Docs and `CHANGELOG.md` (*Unreleased*) are updated for user-facing changes
14
14
  - [ ] Changes to prompts, tools or context handling: the dev slice before and after is under "How was it tested?" (`lcode bench --compare`)
@@ -21,6 +21,8 @@ jobs:
21
21
  - uses: astral-sh/setup-uv@v10.3.2
22
22
  - run: uv run --group dev ruff check .
23
23
  - run: uv run --group dev ruff format --check .
24
+ - name: Type check
25
+ run: uv run --group dev basedpyright
24
26
  - name: Shellcheck install.sh
25
27
  run: shellcheck install.sh
26
28
 
@@ -14,6 +14,7 @@ packaged with hatchling, managed with uv. Runtime dependencies: requests, rich,
14
14
  uv sync --group dev # set up .venv
15
15
  uv run pytest # tests (no Ollama needed)
16
16
  uv run ruff check . && uv run ruff format --check .
17
+ uv run basedpyright # type check src/lcode
17
18
  uv run --group docs mkdocs build --strict # docs
18
19
  uv run lcode doctor # check a local install against a running Ollama
19
20
  ```
@@ -6,6 +6,28 @@ All notable changes to lcode are documented here. The format follows
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [0.60.0] - 2026-11-04
10
+
11
+ ### Changed
12
+
13
+ - **For contributors:** CI type-checks `src/lcode` with basedpyright, and the eight modules that were
14
+ over 1,000 lines are split into smaller ones, with no change in behavior. The code map in
15
+ `docs/how-it-works.md` lists them (#200).
16
+
17
+ ### Fixed
18
+
19
+ - The Valohai MCP server failed to describe an execution with an output that has no name; it now
20
+ shows it as `?`. Found by the type checks that CI now runs on `src/lcode` (#200).
21
+ - **Cancelling in an editor right after sending a request** (lcode acp) could be lost: the request then
22
+ ran to the end. The editor's messages are handled in threads of their own, and the request's own thread
23
+ reset the cancel when it started late, on a busy machine. The cancel now holds. This was also why
24
+ `tests/test_acp.py` failed now and then under load (#200).
25
+ - **`lcode bench --compare`** left out attempts whose tests ran but didn't finish, as if they hadn't
26
+ run, so a change that makes the tests hang could hide a drop. They count as failed now, as in
27
+ Harbor's own mean, and `--compare` reads both runs again from Harbor's results so that they count
28
+ alike. It also gives each run's model speed, and warns when one ran more than 10% slower, which
29
+ makes the tasks' time limits bite more often. On 0.59.0's gate, both showed (#199).
30
+
9
31
  ## [0.59.0] - 2026-11-03
10
32
 
11
33
  ### Added
@@ -1259,7 +1281,8 @@ First public release.
1259
1281
  - `AGENTS.md` project instructions and `/init` to generate them.
1260
1282
  - One-line installer for Linux and macOS.
1261
1283
 
1262
- [Unreleased]: https://github.com/nasser1941/lcode/compare/v0.59.0...HEAD
1284
+ [Unreleased]: https://github.com/nasser1941/lcode/compare/v0.60.0...HEAD
1285
+ [0.60.0]: https://github.com/nasser1941/lcode/compare/v0.59.0...v0.60.0
1263
1286
  [0.59.0]: https://github.com/nasser1941/lcode/compare/v0.58.0...v0.59.0
1264
1287
  [0.58.0]: https://github.com/nasser1941/lcode/compare/v0.57.0...v0.58.0
1265
1288
  [0.57.0]: https://github.com/nasser1941/lcode/compare/v0.56.0...v0.57.0
@@ -38,6 +38,7 @@ uv run lcode --version # run your working copy
38
38
  uv run pytest # tests
39
39
  uv run ruff check . # lint
40
40
  uv run ruff format . # format
41
+ uv run basedpyright # type check
41
42
  ```
42
43
 
43
44
  Optional: `uvx pre-commit install` runs the linters and a secret scanner before each commit.
@@ -86,7 +87,7 @@ otherwise the first model in catalog order that fits with a useful context windo
86
87
 
87
88
  ## Pull request checklist
88
89
 
89
- - [ ] `uv run pytest` and `uv run ruff check .` pass
90
+ - [ ] `uv run pytest`, `uv run ruff check .` and `uv run basedpyright` pass
90
91
  - [ ] New behavior has tests (the agent loop can be tested with the scripted `FakeOllama` in `tests/conftest.py`)
91
92
  - [ ] User-facing changes are documented in `docs/` and noted under *Unreleased* in `CHANGELOG.md`
92
93
  - [ ] No secrets, tokens, personal paths or private data in code, tests, docs or screenshots
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: lcode-cli
3
- Version: 0.59.0
3
+ Version: 0.60.0
4
4
  Summary: A local-first terminal coding agent powered by open-weight models on your own GPU or Mac, via Ollama.
5
5
  Project-URL: Homepage, https://nasser1941.github.io/lcode/
6
6
  Project-URL: Documentation, https://nasser1941.github.io/lcode/
@@ -181,14 +181,14 @@ the Ollama server you configure, it only contacts the web when the model searche
181
181
 
182
182
  | Module | Responsibility |
183
183
  |---|---|
184
- | `cli.py` | Entry point, subcommands, model and context resolution |
185
- | `repl.py` | Prompt, key bindings, slash commands, status bar |
186
- | `agent.py` | System prompt, streaming, tool loop, compaction, sessions |
187
- | `tools.py` | Tool schemas and implementations |
184
+ | `cli.py`, `cli_args.py`, `doctor.py` | Entry point, subcommands, model and context resolution; the options; `lcode doctor` |
185
+ | `repl.py` | Prompt, key bindings, status bar, and slash commands, with the model, media, memory and checkpoint, and session commands in `repl_models.py`, `repl_media.py`, `repl_history.py` and `repl_sessions.py` |
186
+ | `agent.py` | The tool loop. `Agent`'s state is in `agent_base.py`, and its system prompt and tools, model calls, context window, sessions and checks in `agent_prompt.py`, `agent_model.py`, `agent_context.py`, `agent_sessions.py` and `agent_checks.py` |
187
+ | `tools.py` | The tools and running them, with the schemas in `tool_schemas.py`, what they share in `tool_helpers.py` and `tools_base.py`, and the file and shell tools in `tools_edit.py` and `tools_shell.py` |
188
188
  | `permissions.py` | Approval prompts and the read-only allowlist |
189
189
  | `servers/` | The MCP servers lcode ships for services without one: Encord, Valohai |
190
190
  | `mcp/` | MCP client: stdio and HTTP transports, OAuth sign-in, server settings, the catalog, `lcode mcp` |
191
- | `bench.py` | `lcode bench`: the benchmark tasks, their checks and the reports |
191
+ | `bench.py` | `lcode bench`: running the tasks and the reports; the tasks are in `bench_quick.py` and the other `bench_*.py`, and what their checks share in `bench_checks.py` |
192
192
  | `vision.py` | Looking at images with a model that can see |
193
193
  | `subagents.py` | Subagents: agent types, running them (also in parallel), worktrees for workers |
194
194
  | `hooks.py` | Hooks on lcode's events, and allow and deny rules for permissions |
@@ -205,3 +205,6 @@ the Ollama server you configure, it only contacts the web when the model searche
205
205
  | `hardware.py` | NVIDIA / Apple Silicon detection |
206
206
  | `ollama.py` | Ollama HTTP client |
207
207
  | `config.py` | Settings file and environment variables |
208
+ | `traces.py`, `trace_view.py`, `trace_export.py` | Recording requests; listing and showing traces; exporting them with secrets masked |
209
+ | `media.py`, `media_video.py`, `clips.py` | Image and video mode's jobs in ComfyUI; video jobs and long clips; video files |
210
+ | `screenshots.py`, `screenshots_web.py`, `qt_hook.py` | The screenshot tool: programs, web pages, and the hook it puts into Qt programs |
@@ -86,9 +86,14 @@ With three attempts, the last line also gives each run's pass rate and the sprea
86
86
  [trace](traces.md)). An attempt stopped at the task's time limit counts the tokens recorded
87
87
  until then, and a reply lcode stopped counts with an estimate. `–` means no attempt of the task
88
88
  has a record.
89
+ - **The model's speed**: how many tokens per second it generated, in the median attempt, from the
90
+ same traces. A slower machine (short of memory, or busy with other programs) runs into the
91
+ tasks' time limits more often.
89
92
 
90
93
  Attempts whose container didn't start (a failed image download, say) count neither as passed nor
91
- as failed. The report shows how many there were.
94
+ as failed. Attempts whose tests ran but didn't finish (a time limit, say) or gave no result count
95
+ as failed, as in Harbor's own mean, so a change that makes the tests hang can't hide a drop. The
96
+ report shows how many of each there were.
92
97
 
93
98
  Everything is saved in `~/.local/state/lcode/bench/<slice>-<time>/`:
94
99
 
@@ -111,6 +116,11 @@ It says which lcode, model and context each one ran, warns when they don't match
111
116
  whose results changed (`3/3 → 1/3`), and compares pass@1 over the tasks both ran: within the noise,
112
117
  better, or a drop beyond the noise.
113
118
 
119
+ While Harbor's results are still on the machine, `--compare` reads both runs from them again, so a
120
+ run saved by an older lcode counts its attempts the same way as a new one. It also gives each run's
121
+ model speed, and warns when one ran more than 10% slower: more of its attempts run into their time
122
+ limits, so part of a difference can come from the machine rather than from lcode.
123
+
114
124
  The noise is how far pass@1 moves between runs of the same setup, estimated from how much each
115
125
  task's attempts disagree: a task that always passes or always fails adds nothing, one that passes
116
126
  half the time the most. A change counts when it's more than twice the standard error of the
@@ -12,7 +12,7 @@ lcode
12
12
 
13
13
  ```text
14
14
  ╭──────────────────────────────────────────────╮
15
- │ lcode v0.59.0 — local coding agent │
15
+ │ lcode v0.60.0 — local coding agent │
16
16
  │ │
17
17
  │ model lcode-qwen3.6-35b │
18
18
  │ context 256K tokens │
@@ -52,7 +52,11 @@ lcode-mcp-encord = "lcode.servers.encord:main"
52
52
  lcode-mcp-xai = "lcode.servers.xai:main"
53
53
 
54
54
  [dependency-groups]
55
- dev = ["pytest>=8", "ruff>=0.6"]
55
+ dev = [
56
+ "basedpyright>=1.40.2",
57
+ "pytest>=8",
58
+ "ruff>=0.6",
59
+ ]
56
60
  docs = ["mkdocs-material>=9.5", "mkdocs>=1.6,<2"] # MkDocs 2 drops plugins and themes
57
61
 
58
62
  [tool.hatch.version]
@@ -83,6 +87,8 @@ ignore = [
83
87
 
84
88
  [tool.ruff.lint.per-file-ignores]
85
89
  "src/lcode/agent.py" = ["E501"] # the prompts are prose; wrapping them would change what the model sees
90
+ "src/lcode/agent_prompt.py" = ["E501"] # the same prompts, moved here
91
+ "src/lcode/agent_context.py" = ["E501"] # the summary prompt is prose
86
92
  "src/lcode/manual.py" = ["E501"] # the same for the help prompt
87
93
  "src/lcode/memory.py" = ["E501"]
88
94
  "src/lcode/subagents.py" = ["E501"]
@@ -107,3 +113,9 @@ ignore = [
107
113
  [tool.pytest.ini_options]
108
114
  testpaths = ["tests"]
109
115
  addopts = "-q"
116
+
117
+ [tool.basedpyright]
118
+ # CI type-checks src/lcode (`uv run basedpyright`). Python 3.10, the oldest lcode supports, so newer APIs show up.
119
+ include = ["src/lcode"]
120
+ pythonVersion = "3.10"
121
+ typeCheckingMode = "standard"
@@ -3,7 +3,7 @@
3
3
  From a program: `from lcode import Session` (see lcode.api).
4
4
  """
5
5
 
6
- __version__ = "0.59.0"
6
+ __version__ = "0.60.0"
7
7
 
8
8
  API = ("Session", "Result", "Options", "SetupError")
9
9
 
@@ -19,11 +19,13 @@ the file in LCODE_ACP_LOG), and stdin is the protocol channel only.
19
19
  from __future__ import annotations
20
20
 
21
21
  import base64
22
+ import contextlib
22
23
  import hashlib
23
24
  import json
24
25
  import os
25
26
  import sys
26
27
  import threading
28
+ from collections.abc import Callable
27
29
  from pathlib import Path
28
30
  from typing import IO, TYPE_CHECKING, Any
29
31
  from urllib.parse import unquote, urlparse
@@ -76,6 +78,9 @@ class Connection:
76
78
  self.pending: dict[int, tuple[threading.Event, dict]] = {}
77
79
  self.next_id = 0
78
80
  self.closed = False
81
+ # Called with each message from the editor in the order they came, before it's handled in a thread of
82
+ # its own: for what has to happen in that order (Server.received).
83
+ self.on_message: Callable[[dict], None] | None = None
79
84
 
80
85
  def send(self, message: dict) -> None:
81
86
  data = (json.dumps({"jsonrpc": "2.0", **message}, ensure_ascii=False) + "\n").encode()
@@ -112,6 +117,9 @@ class Connection:
112
117
  self.send({"id": None, "error": {"code": -32700, "message": "parse error"}})
113
118
  continue
114
119
  if "method" in message:
120
+ if self.on_message is not None:
121
+ with contextlib.suppress(Exception): # never stop reading
122
+ self.on_message(message)
115
123
  threading.Thread(target=self._dispatch, args=(handle, message), daemon=True).start()
116
124
  elif message.get("id") in self.pending:
117
125
  done, slot = self.pending.pop(message["id"])
@@ -373,8 +381,7 @@ class Session:
373
381
  return {"stopReason": "end_turn"}
374
382
  if command is not None:
375
383
  text = command
376
- self.agent.cancel.clear()
377
- result = api.run_request(self.agent, text)
384
+ result = api.run_request(self.agent, text) # its cancel was reset when the prompt arrived (Server.received)
378
385
  self.update({"sessionUpdate": "usage_update", "used": self.agent.ctx_used, "size": self.agent.settings.context})
379
386
  self.update({"sessionUpdate": "session_info_update", "title": self.agent.session_title or None})
380
387
  if result.status == "error":
@@ -472,6 +479,19 @@ class Server:
472
479
  self.conn, self.console = conn, console
473
480
  self.client_caps: dict = {}
474
481
  self.sessions: dict[str, Session] = {}
482
+ conn.on_message = self.received
483
+
484
+ def received(self, message: dict) -> None:
485
+ """A new prompt resets its session's cancel as soon as it arrives, in the order the editor sent things.
486
+
487
+ Each message is then handled in a thread of its own, so a cancel sent right after a prompt can run before
488
+ the prompt's thread starts; the cancel then holds, instead of being reset by a prompt that starts late.
489
+ """
490
+ if message.get("method") == "session/prompt":
491
+ params = message.get("params") or {}
492
+ session = self.sessions.get(str(params.get("sessionId", "")))
493
+ if session is not None and session.agent.cancel is not None:
494
+ session.agent.cancel.clear()
475
495
 
476
496
  def handle(self, method: str, params: dict) -> dict | None:
477
497
  handlers = {