usta 0.2.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 (250) hide show
  1. usta-0.2.0/.github/workflows/ci.yml +53 -0
  2. usta-0.2.0/.gitignore +13 -0
  3. usta-0.2.0/CHANGELOG.md +34 -0
  4. usta-0.2.0/CONTRIBUTING.md +20 -0
  5. usta-0.2.0/LICENSE +202 -0
  6. usta-0.2.0/Makefile +10 -0
  7. usta-0.2.0/PKG-INFO +211 -0
  8. usta-0.2.0/README.en.md +129 -0
  9. usta-0.2.0/README.md +179 -0
  10. usta-0.2.0/SECURITY.md +60 -0
  11. usta-0.2.0/docs/design.md +170 -0
  12. usta-0.2.0/docs/implementation-audit.md +112 -0
  13. usta-0.2.0/docs/reliability-lab.md +90 -0
  14. usta-0.2.0/docs/v0.2.0-raporu.md +72 -0
  15. usta-0.2.0/pyproject.toml +48 -0
  16. usta-0.2.0/requirements-dev.lock +371 -0
  17. usta-0.2.0/requirements.lock +327 -0
  18. usta-0.2.0/src/usta/__init__.py +0 -0
  19. usta-0.2.0/src/usta/agent.py +319 -0
  20. usta-0.2.0/src/usta/api.py +834 -0
  21. usta-0.2.0/src/usta/apis.py +103 -0
  22. usta-0.2.0/src/usta/attachments.py +60 -0
  23. usta-0.2.0/src/usta/audit.py +47 -0
  24. usta-0.2.0/src/usta/auth.py +55 -0
  25. usta-0.2.0/src/usta/bench.py +904 -0
  26. usta-0.2.0/src/usta/bench_tasks/add-feature/check/test_todo.py +37 -0
  27. usta-0.2.0/src/usta/bench_tasks/add-feature/repo/test_todo.py +11 -0
  28. usta-0.2.0/src/usta/bench_tasks/add-feature/repo/todo.py +10 -0
  29. usta-0.2.0/src/usta/bench_tasks/add-feature/task.json +10 -0
  30. usta-0.2.0/src/usta/bench_tasks/cli-args/check/test_cli.py +44 -0
  31. usta-0.2.0/src/usta/bench_tasks/cli-args/repo/cli.py +2 -0
  32. usta-0.2.0/src/usta/bench_tasks/cli-args/task.json +10 -0
  33. usta-0.2.0/src/usta/bench_tasks/cross-module-bug/check/test_cart.py +19 -0
  34. usta-0.2.0/src/usta/bench_tasks/cross-module-bug/check/test_pricing.py +12 -0
  35. usta-0.2.0/src/usta/bench_tasks/cross-module-bug/repo/cart.py +7 -0
  36. usta-0.2.0/src/usta/bench_tasks/cross-module-bug/repo/pricing.py +5 -0
  37. usta-0.2.0/src/usta/bench_tasks/cross-module-bug/repo/test_cart.py +8 -0
  38. usta-0.2.0/src/usta/bench_tasks/cross-module-bug/repo/test_pricing.py +12 -0
  39. usta-0.2.0/src/usta/bench_tasks/cross-module-bug/task.json +10 -0
  40. usta-0.2.0/src/usta/bench_tasks/csv-quotes/check/test_parse.py +22 -0
  41. usta-0.2.0/src/usta/bench_tasks/csv-quotes/repo/parse.py +2 -0
  42. usta-0.2.0/src/usta/bench_tasks/csv-quotes/task.json +10 -0
  43. usta-0.2.0/src/usta/bench_tasks/deep-merge/check/test_config.py +31 -0
  44. usta-0.2.0/src/usta/bench_tasks/deep-merge/repo/config.py +2 -0
  45. usta-0.2.0/src/usta/bench_tasks/deep-merge/task.json +10 -0
  46. usta-0.2.0/src/usta/bench_tasks/expr-eval/check/test_calc.py +37 -0
  47. usta-0.2.0/src/usta/bench_tasks/expr-eval/repo/calc.py +2 -0
  48. usta-0.2.0/src/usta/bench_tasks/expr-eval/task.json +10 -0
  49. usta-0.2.0/src/usta/bench_tasks/implement-slugify/check/test_slug.py +19 -0
  50. usta-0.2.0/src/usta/bench_tasks/implement-slugify/repo/slug.py +2 -0
  51. usta-0.2.0/src/usta/bench_tasks/implement-slugify/task.json +10 -0
  52. usta-0.2.0/src/usta/bench_tasks/interval-merge/check/test_intervals.py +30 -0
  53. usta-0.2.0/src/usta/bench_tasks/interval-merge/repo/intervals.py +2 -0
  54. usta-0.2.0/src/usta/bench_tasks/interval-merge/task.json +10 -0
  55. usta-0.2.0/src/usta/bench_tasks/leap-dates/check/test_dates.py +34 -0
  56. usta-0.2.0/src/usta/bench_tasks/leap-dates/repo/dates.py +15 -0
  57. usta-0.2.0/src/usta/bench_tasks/leap-dates/repo/test_dates.py +9 -0
  58. usta-0.2.0/src/usta/bench_tasks/leap-dates/task.json +10 -0
  59. usta-0.2.0/src/usta/bench_tasks/lru-cache/check/test_lru.py +50 -0
  60. usta-0.2.0/src/usta/bench_tasks/lru-cache/repo/lru.py +3 -0
  61. usta-0.2.0/src/usta/bench_tasks/lru-cache/task.json +10 -0
  62. usta-0.2.0/src/usta/bench_tasks/money-rounding/check/test_money.py +27 -0
  63. usta-0.2.0/src/usta/bench_tasks/money-rounding/repo/money.py +7 -0
  64. usta-0.2.0/src/usta/bench_tasks/money-rounding/repo/test_money.py +8 -0
  65. usta-0.2.0/src/usta/bench_tasks/money-rounding/task.json +10 -0
  66. usta-0.2.0/src/usta/bench_tasks/multi-file-rename/check/test_users.py +21 -0
  67. usta-0.2.0/src/usta/bench_tasks/multi-file-rename/repo/api.py +5 -0
  68. usta-0.2.0/src/usta/bench_tasks/multi-file-rename/repo/greeting.py +5 -0
  69. usta-0.2.0/src/usta/bench_tasks/multi-file-rename/repo/report.py +5 -0
  70. usta-0.2.0/src/usta/bench_tasks/multi-file-rename/repo/test_users.py +8 -0
  71. usta-0.2.0/src/usta/bench_tasks/multi-file-rename/repo/users.py +2 -0
  72. usta-0.2.0/src/usta/bench_tasks/multi-file-rename/task.json +10 -0
  73. usta-0.2.0/src/usta/bench_tasks/off-by-one/check/test_stats.py +21 -0
  74. usta-0.2.0/src/usta/bench_tasks/off-by-one/repo/stats.py +8 -0
  75. usta-0.2.0/src/usta/bench_tasks/off-by-one/repo/test_stats.py +8 -0
  76. usta-0.2.0/src/usta/bench_tasks/off-by-one/task.json +10 -0
  77. usta-0.2.0/src/usta/bench_tasks/text-wrap/check/test_wrap.py +28 -0
  78. usta-0.2.0/src/usta/bench_tasks/text-wrap/repo/wrap.py +2 -0
  79. usta-0.2.0/src/usta/bench_tasks/text-wrap/task.json +10 -0
  80. usta-0.2.0/src/usta/bench_tasks/tiny-case-insensitive/check/test_find.py +17 -0
  81. usta-0.2.0/src/usta/bench_tasks/tiny-case-insensitive/repo/find.py +3 -0
  82. usta-0.2.0/src/usta/bench_tasks/tiny-case-insensitive/repo/test_find.py +8 -0
  83. usta-0.2.0/src/usta/bench_tasks/tiny-case-insensitive/task.json +11 -0
  84. usta-0.2.0/src/usta/bench_tasks/tiny-default-sep/check/test_words.py +17 -0
  85. usta-0.2.0/src/usta/bench_tasks/tiny-default-sep/repo/test_words.py +8 -0
  86. usta-0.2.0/src/usta/bench_tasks/tiny-default-sep/repo/words.py +3 -0
  87. usta-0.2.0/src/usta/bench_tasks/tiny-default-sep/task.json +11 -0
  88. usta-0.2.0/src/usta/bench_tasks/tiny-greeting/check/test_greet.py +14 -0
  89. usta-0.2.0/src/usta/bench_tasks/tiny-greeting/repo/greet.py +3 -0
  90. usta-0.2.0/src/usta/bench_tasks/tiny-greeting/repo/test_greet.py +8 -0
  91. usta-0.2.0/src/usta/bench_tasks/tiny-greeting/task.json +11 -0
  92. usta-0.2.0/src/usta/bench_tasks/tiny-is-even/check/test_parity.py +18 -0
  93. usta-0.2.0/src/usta/bench_tasks/tiny-is-even/repo/parity.py +5 -0
  94. usta-0.2.0/src/usta/bench_tasks/tiny-is-even/repo/test_parity.py +9 -0
  95. usta-0.2.0/src/usta/bench_tasks/tiny-is-even/task.json +11 -0
  96. usta-0.2.0/src/usta/bench_tasks/tiny-missing-return/check/test_nums.py +19 -0
  97. usta-0.2.0/src/usta/bench_tasks/tiny-missing-return/repo/nums.py +5 -0
  98. usta-0.2.0/src/usta/bench_tasks/tiny-missing-return/repo/test_nums.py +8 -0
  99. usta-0.2.0/src/usta/bench_tasks/tiny-missing-return/task.json +11 -0
  100. usta-0.2.0/src/usta/bench_tasks/tiny-strip-names/check/test_names.py +17 -0
  101. usta-0.2.0/src/usta/bench_tasks/tiny-strip-names/repo/names.py +3 -0
  102. usta-0.2.0/src/usta/bench_tasks/tiny-strip-names/repo/test_names.py +8 -0
  103. usta-0.2.0/src/usta/bench_tasks/tiny-strip-names/task.json +11 -0
  104. usta-0.2.0/src/usta/bench_tasks/tiny-swap-args/check/test_pct.py +17 -0
  105. usta-0.2.0/src/usta/bench_tasks/tiny-swap-args/repo/pct.py +5 -0
  106. usta-0.2.0/src/usta/bench_tasks/tiny-swap-args/repo/test_pct.py +8 -0
  107. usta-0.2.0/src/usta/bench_tasks/tiny-swap-args/task.json +11 -0
  108. usta-0.2.0/src/usta/bench_tasks/tiny-wrong-operator/check/test_avg.py +17 -0
  109. usta-0.2.0/src/usta/bench_tasks/tiny-wrong-operator/repo/avg.py +5 -0
  110. usta-0.2.0/src/usta/bench_tasks/tiny-wrong-operator/repo/test_avg.py +8 -0
  111. usta-0.2.0/src/usta/bench_tasks/tiny-wrong-operator/task.json +11 -0
  112. usta-0.2.0/src/usta/bench_tasks/word-count-fix/check/test_text.py +25 -0
  113. usta-0.2.0/src/usta/bench_tasks/word-count-fix/repo/test_text.py +10 -0
  114. usta-0.2.0/src/usta/bench_tasks/word-count-fix/repo/text.py +5 -0
  115. usta-0.2.0/src/usta/bench_tasks/word-count-fix/task.json +10 -0
  116. usta-0.2.0/src/usta/breaker.py +132 -0
  117. usta-0.2.0/src/usta/capability.py +643 -0
  118. usta-0.2.0/src/usta/cli.py +1358 -0
  119. usta-0.2.0/src/usta/context.py +122 -0
  120. usta-0.2.0/src/usta/fetch.py +406 -0
  121. usta-0.2.0/src/usta/fetch_inner.py +112 -0
  122. usta-0.2.0/src/usta/filetree.py +134 -0
  123. usta-0.2.0/src/usta/jsonproto.py +155 -0
  124. usta-0.2.0/src/usta/lab/__init__.py +4 -0
  125. usta-0.2.0/src/usta/lab/env.py +127 -0
  126. usta-0.2.0/src/usta/lab/evaluator.py +108 -0
  127. usta-0.2.0/src/usta/lab/metrics.py +109 -0
  128. usta-0.2.0/src/usta/lab/report.py +124 -0
  129. usta-0.2.0/src/usta/lab/runner.py +242 -0
  130. usta-0.2.0/src/usta/lab/scenario.py +266 -0
  131. usta-0.2.0/src/usta/lab/scenarios/v1.jsonl +25 -0
  132. usta-0.2.0/src/usta/lab/scripted.py +47 -0
  133. usta-0.2.0/src/usta/mcp.py +344 -0
  134. usta-0.2.0/src/usta/mcp_runtime.py +362 -0
  135. usta-0.2.0/src/usta/mcp_tools.py +162 -0
  136. usta-0.2.0/src/usta/mcpcatalog.py +39 -0
  137. usta-0.2.0/src/usta/mcpconfig.py +306 -0
  138. usta-0.2.0/src/usta/memory.py +218 -0
  139. usta-0.2.0/src/usta/modelctl.py +124 -0
  140. usta-0.2.0/src/usta/modelinfo.py +19 -0
  141. usta-0.2.0/src/usta/models.py +170 -0
  142. usta-0.2.0/src/usta/outline.py +191 -0
  143. usta-0.2.0/src/usta/pdf_inner.py +59 -0
  144. usta-0.2.0/src/usta/phases.py +267 -0
  145. usta-0.2.0/src/usta/policy.py +104 -0
  146. usta-0.2.0/src/usta/portal.py +107 -0
  147. usta-0.2.0/src/usta/profile.py +177 -0
  148. usta-0.2.0/src/usta/projectcfg.py +90 -0
  149. usta-0.2.0/src/usta/projects.py +67 -0
  150. usta-0.2.0/src/usta/proxy.py +302 -0
  151. usta-0.2.0/src/usta/repl.py +590 -0
  152. usta-0.2.0/src/usta/rescue.py +66 -0
  153. usta-0.2.0/src/usta/sandbox.py +359 -0
  154. usta-0.2.0/src/usta/sessions.py +120 -0
  155. usta-0.2.0/src/usta/settings.py +93 -0
  156. usta-0.2.0/src/usta/skills.py +79 -0
  157. usta-0.2.0/src/usta/symbols.py +618 -0
  158. usta-0.2.0/src/usta/tasks.py +633 -0
  159. usta-0.2.0/src/usta/taxonomy.py +169 -0
  160. usta-0.2.0/src/usta/textproto.py +149 -0
  161. usta-0.2.0/src/usta/theme.py +104 -0
  162. usta-0.2.0/src/usta/tools.py +369 -0
  163. usta-0.2.0/src/usta/verify.py +233 -0
  164. usta-0.2.0/src/usta/web/app.css +160 -0
  165. usta-0.2.0/src/usta/web/app.js +1064 -0
  166. usta-0.2.0/src/usta/web/index.html +197 -0
  167. usta-0.2.0/src/usta/web/logic.js +175 -0
  168. usta-0.2.0/src/usta/workspace.py +236 -0
  169. usta-0.2.0/tests/bench_solutions/add-feature/todo.py +32 -0
  170. usta-0.2.0/tests/bench_solutions/cli-args/cli.py +39 -0
  171. usta-0.2.0/tests/bench_solutions/cross-module-bug/cart.py +7 -0
  172. usta-0.2.0/tests/bench_solutions/csv-quotes/parse.py +6 -0
  173. usta-0.2.0/tests/bench_solutions/deep-merge/config.py +15 -0
  174. usta-0.2.0/tests/bench_solutions/expr-eval/calc.py +71 -0
  175. usta-0.2.0/tests/bench_solutions/implement-slugify/slug.py +24 -0
  176. usta-0.2.0/tests/bench_solutions/interval-merge/intervals.py +14 -0
  177. usta-0.2.0/tests/bench_solutions/leap-dates/dates.py +19 -0
  178. usta-0.2.0/tests/bench_solutions/lru-cache/lru.py +30 -0
  179. usta-0.2.0/tests/bench_solutions/money-rounding/money.py +14 -0
  180. usta-0.2.0/tests/bench_solutions/multi-file-rename/api.py +5 -0
  181. usta-0.2.0/tests/bench_solutions/multi-file-rename/greeting.py +5 -0
  182. usta-0.2.0/tests/bench_solutions/multi-file-rename/report.py +5 -0
  183. usta-0.2.0/tests/bench_solutions/multi-file-rename/users.py +2 -0
  184. usta-0.2.0/tests/bench_solutions/off-by-one/stats.py +8 -0
  185. usta-0.2.0/tests/bench_solutions/text-wrap/wrap.py +31 -0
  186. usta-0.2.0/tests/bench_solutions/tiny-case-insensitive/find.py +3 -0
  187. usta-0.2.0/tests/bench_solutions/tiny-default-sep/words.py +3 -0
  188. usta-0.2.0/tests/bench_solutions/tiny-greeting/greet.py +3 -0
  189. usta-0.2.0/tests/bench_solutions/tiny-is-even/parity.py +9 -0
  190. usta-0.2.0/tests/bench_solutions/tiny-missing-return/nums.py +6 -0
  191. usta-0.2.0/tests/bench_solutions/tiny-strip-names/names.py +3 -0
  192. usta-0.2.0/tests/bench_solutions/tiny-swap-args/pct.py +5 -0
  193. usta-0.2.0/tests/bench_solutions/tiny-wrong-operator/avg.py +5 -0
  194. usta-0.2.0/tests/bench_solutions/word-count-fix/text.py +7 -0
  195. usta-0.2.0/tests/conftest.py +10 -0
  196. usta-0.2.0/tests/fake_endpoint.py +53 -0
  197. usta-0.2.0/tests/fake_mcp.py +124 -0
  198. usta-0.2.0/tests/pdfutil.py +28 -0
  199. usta-0.2.0/tests/probe_mcp_src.py +71 -0
  200. usta-0.2.0/tests/test_agent.py +232 -0
  201. usta-0.2.0/tests/test_api.py +409 -0
  202. usta-0.2.0/tests/test_api_mcp.py +193 -0
  203. usta-0.2.0/tests/test_apis.py +115 -0
  204. usta-0.2.0/tests/test_audit.py +69 -0
  205. usta-0.2.0/tests/test_bench.py +563 -0
  206. usta-0.2.0/tests/test_benchdiag.py +355 -0
  207. usta-0.2.0/tests/test_breaker.py +222 -0
  208. usta-0.2.0/tests/test_capability.py +408 -0
  209. usta-0.2.0/tests/test_chat_cli.py +238 -0
  210. usta-0.2.0/tests/test_cli.py +555 -0
  211. usta-0.2.0/tests/test_context.py +305 -0
  212. usta-0.2.0/tests/test_fetch.py +636 -0
  213. usta-0.2.0/tests/test_files_skills.py +277 -0
  214. usta-0.2.0/tests/test_hardening2.py +345 -0
  215. usta-0.2.0/tests/test_hardening3.py +275 -0
  216. usta-0.2.0/tests/test_jsonproto.py +146 -0
  217. usta-0.2.0/tests/test_lab.py +455 -0
  218. usta-0.2.0/tests/test_mcp.py +158 -0
  219. usta-0.2.0/tests/test_mcp_runtime.py +415 -0
  220. usta-0.2.0/tests/test_mcp_tools.py +191 -0
  221. usta-0.2.0/tests/test_mcpconfig.py +120 -0
  222. usta-0.2.0/tests/test_memory.py +219 -0
  223. usta-0.2.0/tests/test_models.py +289 -0
  224. usta-0.2.0/tests/test_netproxy.py +170 -0
  225. usta-0.2.0/tests/test_no_secrets.py +25 -0
  226. usta-0.2.0/tests/test_outline.py +176 -0
  227. usta-0.2.0/tests/test_pdf.py +64 -0
  228. usta-0.2.0/tests/test_phased.py +184 -0
  229. usta-0.2.0/tests/test_phases.py +406 -0
  230. usta-0.2.0/tests/test_policy.py +123 -0
  231. usta-0.2.0/tests/test_portal.py +182 -0
  232. usta-0.2.0/tests/test_profile.py +171 -0
  233. usta-0.2.0/tests/test_projectcfg.py +111 -0
  234. usta-0.2.0/tests/test_projects.py +86 -0
  235. usta-0.2.0/tests/test_proxy.py +295 -0
  236. usta-0.2.0/tests/test_repl.py +444 -0
  237. usta-0.2.0/tests/test_rescue.py +77 -0
  238. usta-0.2.0/tests/test_sandbox.py +182 -0
  239. usta-0.2.0/tests/test_sessions.py +121 -0
  240. usta-0.2.0/tests/test_steer_model.py +213 -0
  241. usta-0.2.0/tests/test_supply_chain.py +126 -0
  242. usta-0.2.0/tests/test_symbols.py +359 -0
  243. usta-0.2.0/tests/test_tasks.py +535 -0
  244. usta-0.2.0/tests/test_textproto.py +136 -0
  245. usta-0.2.0/tests/test_theme.py +136 -0
  246. usta-0.2.0/tests/test_tools.py +191 -0
  247. usta-0.2.0/tests/test_verify.py +318 -0
  248. usta-0.2.0/tests/test_web.py +109 -0
  249. usta-0.2.0/tests/test_workspace.py +159 -0
  250. usta-0.2.0/tests/web/logic.test.cjs +156 -0
@@ -0,0 +1,53 @@
1
+ name: ci
2
+ on:
3
+ push:
4
+ branches: [main, master]
5
+ pull_request:
6
+
7
+ permissions:
8
+ contents: read
9
+
10
+ jobs:
11
+ test:
12
+ runs-on: ubuntu-latest
13
+ strategy:
14
+ fail-fast: false
15
+ matrix:
16
+ python: ["3.11", "3.12"]
17
+ steps:
18
+ - uses: actions/checkout@v4
19
+ - uses: actions/setup-python@v5
20
+ with:
21
+ python-version: ${{ matrix.python }}
22
+ - uses: actions/setup-node@v4
23
+ with:
24
+ node-version: "22"
25
+ - name: Sandbox testleri için imaj
26
+ run: docker pull python:3.12-slim
27
+ - name: Kurulum
28
+ run: |
29
+ python -m pip install --upgrade pip
30
+ python -m pip install --require-hashes -r requirements-dev.lock
31
+ python -m pip install --no-deps -e .
32
+ - name: Lint
33
+ run: ruff check src tests
34
+ - name: Test
35
+ run: pytest -q
36
+ - name: Reliability Lab smoke (harici model gerekmez)
37
+ run: |
38
+ usta lab validate
39
+ usta lab smoke
40
+
41
+ audit:
42
+ runs-on: ubuntu-latest
43
+ steps:
44
+ - uses: actions/checkout@v4
45
+ - uses: actions/setup-python@v5
46
+ with:
47
+ python-version: "3.12"
48
+ - name: Bağımlılık güvenlik taraması
49
+ run: |
50
+ python -m pip install pip-audit
51
+ python -m pip install --require-hashes -r requirements.lock
52
+ python -m pip install --no-deps -e .
53
+ pip-audit --no-deps --disable-pip -r requirements.lock
usta-0.2.0/.gitignore ADDED
@@ -0,0 +1,13 @@
1
+ __pycache__/
2
+ *.pyc
3
+ .venv/
4
+ .pytest_cache/
5
+ .ruff_cache/
6
+ *.egg-info/
7
+ dist/
8
+ build/
9
+ .env
10
+ *.key
11
+ .usta/
12
+ .playwright-mcp/
13
+ *.png
@@ -0,0 +1,34 @@
1
+ # Değişiklik günlüğü
2
+
3
+ ## 0.2.0 — güvenilirlik ve ölçüm
4
+
5
+ Sonuçlar, maliyetler ve doğrulanamayan hipotezler: [docs/v0.2.0-raporu.md](docs/v0.2.0-raporu.md).
6
+
7
+ **Güvenlik (kırıcı değişiklik içerir)**
8
+ - MCP sunucuları varsayılan olarak **yalıtılmış Docker konteynerinde** çalışır (ağ kapalı, salt okunur kök, `cap_drop=ALL`, ev dizini/Docker soketi yok, sınırlar).
9
+ Docker/imaj yoksa sunucu başlamaz, ana makineye düşülmez. `usta mcp add` artık `--image` ister; eski kayıtlar (imajsız) başlamaz ve nedenini söyler.
10
+ Ana makinede çalıştırma ayrı bir uyumluluk modudur: `--isolation host --i-understand-host-risk`. `usta mcp prepare` paket/imaj sabitler.
11
+ Plan modunda MCP sunucuları hiç başlatılmaz.
12
+ - Kalıcı hafıza notları kaynak izi taşır; şüpheli notlar onay ister (oto modda reddedilir).
13
+ - Hash'li kilit dosyaları (`make lock`), CI kilitten kurar; sandbox imaj sabitleme (`usta sandbox pin`).
14
+ - Geri alma yalnız dosyaları kapsar notu; doğrulama ortamı hatası (eksik bağımlılık) kod hatasından ayrıldı.
15
+
16
+ **Ölçüm ve gözlemlenebilirlik**
17
+ - `usta lab`: Reliability Lab (20 saldırı + 4 hata senaryosu, eşleştirilmiş temiz kontroller, ASR/deneme/gerçekleşme/yanlış ret/toparlanma/token/gecikme/tutarlılık).
18
+ - `usta bench`: başarısızlık sınıflandırması, adım izi, `replay`, `diagnose`, `regress`, eşleştirilmiş kol karşılaştırması, altyapı hata oranı, train/dev/final bölümleri
19
+ (varsayılan **final hariç**), 8 yeni kolay görev, deneysel kollar X-BRK/X-CTX/X-ALL/X-FULL/X-SYM (A–D anlamları değişmedi).
20
+ - `usta probe --deep` ve `--protocol auto`: protokol başına yetenek profili (model revizyonu + yapılandırmaya bağlı).
21
+ - Yürütme aşamaları gözlemcisi ve terminal durumlar (`done` olayında `terminal`; denetim kaydında `phase`/`terminal`).
22
+ - Deneysel (varsayılan kapalı): Tree-sitter sembol araçları (`--symbol-tools`, `pip install 'usta[symbols]'`), onarım bütçesi zorlaması.
23
+
24
+ ## 0.1.0 — ilk yayın adayı
25
+
26
+ Terminal + yerel portal, modlar (manuel / oto onay / plan), aşamalı plan uygulama, Docker sandbox + allowlist proxy,
27
+ kalıcı oturumlar, proje hafızası, MCP istemcisi ve kataloğu, beceriler, çok API desteği ve model değiştirme, dosya gezgini,
28
+ önizleme, `usta bench` ölçüm düzeneği (kollar A–D), doğrulama kapısı ve devre kesici, bağlam bütçesi ve kalibrasyonu.
29
+
30
+ Güvenlik: yayın öncesi bağımsız inceleme yapıldı; bulunan sorunlar kapatıldı (geri alma sembolik bağı izlemez, `.git`/`.usta`
31
+ korumalı, çalışma alanı sınırları, giriş kodu komut satırında görünmez, gövde sınırı ve Host denetimi, IPv6 NAT64 SSRF, maskeleme,
32
+ pypdf CVE'leri). Bilinen sınırlar için [SECURITY.md](SECURITY.md).
33
+
34
+ Ön ölçümler için [README](README.md); örneklem küçüktür, harness'ın başarıyı artırdığı iddia edilmez.
@@ -0,0 +1,20 @@
1
+ # Katkı rehberi
2
+
3
+ Katkıların için teşekkürler. Usta küçük, ölçülebilir ve güvenli kalmaya çalışır.
4
+
5
+ ## Başlarken
6
+
7
+ ```bash
8
+ uv venv && uv pip install -e '.[dev]'
9
+ make ci # ruff + pytest (JS mantık testleri için node gerekir; Docker testleri imaj yoksa atlanır)
10
+ ```
11
+
12
+ ## İlkeler
13
+
14
+ - **Önce test yaz** (TDD), küçük ve odaklı commit'ler yap. `make ci` geçmeden PR açma.
15
+ - **Ölçülmeyen özellik varsayılan olmaz.** Harness'a bir yenilik ekliyorsan `usta bench` ile fayda/zarar kanıtını (örneklem büyüklüğüyle birlikte, dürüstçe) PR'a ekle.
16
+ - **Güvenlik:** depoya sır, anahtar, kişisel veri girmez (`tests/test_no_secrets.py` bunu denetler). Ajan çıktısı ve harici içerik her zaman *veri*dir; arayüzde `innerHTML` kullanılmaz (`textContent`). Yol işlemleri `resolve_path`/`filetree` üzerinden gider. Açık bulursan [SECURITY.md](SECURITY.md)'deki yoldan özel bildir.
17
+ - **Bağımlılık değişince kilidi yenile:** `make lock` (hash'li `requirements*.lock`; CI bunlardan kurar). Yeni yetenekleri deneysel bayrak arkasında tut ve `usta lab smoke` + `usta bench` ile etkisini raporla.
18
+ - Bağımlılık eklemeden önce gerçekten gerekip gerekmediğini tartış (az bağımlılık ilkesi).
19
+ - Kod ve yorumlar Türkçe; kullanıcıya dönük metinler Türkçe, `README.en.md` İngilizce.
20
+ - Lisans: katkılar Apache-2.0 altında kabul edilir.
usta-0.2.0/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
usta-0.2.0/Makefile ADDED
@@ -0,0 +1,10 @@
1
+ .PHONY: ci lint test lock
2
+ ci: lint test
3
+ lint:
4
+ ruff check src tests
5
+ test:
6
+ pytest -q
7
+ # Bağımlılık kilidi: hash'li, çok platformlu (tekrarlanabilir kurulum). pyproject değişince yeniden üret.
8
+ lock:
9
+ uv pip compile pyproject.toml --extra symbols --universal --python-version 3.11 --generate-hashes -o requirements.lock
10
+ uv pip compile pyproject.toml --extra symbols --extra dev --universal --python-version 3.11 --generate-hashes -o requirements-dev.lock
usta-0.2.0/PKG-INFO ADDED
@@ -0,0 +1,211 @@
1
+ Metadata-Version: 2.5
2
+ Name: usta
3
+ Version: 0.2.0
4
+ Summary: Genel amaçlı, açık kaynak yapay zekâ ajanı
5
+ Author: Uğur Can Leba
6
+ License: Apache-2.0
7
+ License-File: LICENSE
8
+ Keywords: agent,ai,coding-agent,harness,llm,ollama
9
+ Classifier: Development Status :: 3 - Alpha
10
+ Classifier: Environment :: Console
11
+ Classifier: License :: OSI Approved :: Apache Software License
12
+ Classifier: Programming Language :: Python :: 3
13
+ Classifier: Programming Language :: Python :: 3.11
14
+ Classifier: Programming Language :: Python :: 3.12
15
+ Classifier: Topic :: Software Development
16
+ Requires-Python: >=3.11
17
+ Requires-Dist: fastapi>=0.115
18
+ Requires-Dist: httpx>=0.27
19
+ Requires-Dist: pypdf>=6.21.4
20
+ Requires-Dist: uvicorn>=0.30
21
+ Provides-Extra: dev
22
+ Requires-Dist: pytest>=8; extra == 'dev'
23
+ Requires-Dist: ruff>=0.6; extra == 'dev'
24
+ Provides-Extra: symbols
25
+ Requires-Dist: tree-sitter-go>=0.23; extra == 'symbols'
26
+ Requires-Dist: tree-sitter-javascript>=0.23; extra == 'symbols'
27
+ Requires-Dist: tree-sitter-python>=0.23; extra == 'symbols'
28
+ Requires-Dist: tree-sitter-rust>=0.23; extra == 'symbols'
29
+ Requires-Dist: tree-sitter-typescript>=0.23; extra == 'symbols'
30
+ Requires-Dist: tree-sitter>=0.23; extra == 'symbols'
31
+ Description-Content-Type: text/markdown
32
+
33
+ # Usta
34
+
35
+ [English](README.en.md) · Türkçe
36
+
37
+ Türkiye'den çıkan, genel amaçlı, **açık kaynak (Apache-2.0)** yapay zekâ kod ajanı. Terminalde `usta` yazarsın; ajan
38
+ çalışma klasöründe araçlarla iş yapar, yerel bir web portalı (`127.0.0.1`) canlı akışı, dosyaları ve önizlemeyi gösterir.
39
+ Model bağımsız: Ollama, llama.cpp, DeepSeek, OpenRouter, OpenAI gibi **OpenAI-uyumlu** her uç nokta.
40
+
41
+ > Durum: erken geliştirme (v0.x). Komutlar ve API değişebilir. Tasarım ve tehdit modeli: [docs/design.md](docs/design.md).
42
+
43
+ Odak yalnız "başka bir LLM arayüzü" olmak değil: **küçük ve yerel modelleri gerçek yazılım işlerinde daha güvenilir
44
+ kılan harness** (araç çağrısı, bağlam yönetimi, doğrulama döngüsü, devre kesici) ve bunun **dürüstçe ölçülmesi**
45
+ (`usta bench`). Bir özellik ancak ölçümde faydası görülürse varsayılan olur.
46
+
47
+ ## Hızlı başlangıç
48
+
49
+ ```bash
50
+ git clone https://github.com/SoundByGAIA/usta.git usta && cd usta
51
+ uv venv && uv pip install -e .
52
+ ln -s "$PWD/.venv/bin/usta" ~/.local/bin/usta # ya da: uv tool install --editable .
53
+ cd benim-projem
54
+ usta # terminal + portal (tarayıcıda açılır)
55
+ ```
56
+
57
+ İlk açılışta model uç noktasındaki (varsayılan Ollama `http://127.0.0.1:11434/v1`) modelleri listeler, birini seçersin;
58
+ modelin araç çağırma yeteneğini küçük bir ölçümle tanır (yerel `tool_calls` → JSON şeması → metin protokolü).
59
+
60
+ **Dosyalar nereye yazılır?** `usta`'yı hangi klasörde başlatırsan o klasör çalışma alanıdır ve dosyalar doğrudan orada
61
+ oluşur (açılışta tam yol yazılır). Ajan yalnız o klasörün içine yazabilir. Ev dizininde başlatırsan uyarı alırsın;
62
+ bir proje klasöründe başlatmak daha güvenlidir.
63
+
64
+ ## Terminal komutları
65
+
66
+ | Komut | |
67
+ |---|---|
68
+ | `/mod [manuel\|oto\|plan]` | **manuel**: her onay sorulur · **oto onay**: onay isteyen eylemler sorulmadan çalışır (yasaklar ve sandbox geçerli) · **plan**: yalnız okur ve plan sunar; onayınla **aşama aşama** ya da tek seferde uygular |
69
+ | `/tema [beyaz\|gri\|siyah]` | renk teması (terminal ve portal ortak) |
70
+ | `/koruma [aç\|kapat]`, `/doğrula [komut]` | doğrulama kapısı + devre kesici; proje test komutu |
71
+ | `/diff`, `/geri` | son görevin değişikliklerini renkli göster / geri al |
72
+ | `/token` | token kullanımı, sağlayıcı önbelleği ve bağlam doluluğu |
73
+ | `/hafıza`, `/geçmiş [n]`, `/beceriler`, `/mcp` | proje notları, önceki oturumlar, beceriler, ek araçlar |
74
+ | `/model [[api] ad]`, `/portal` | modeli listele/değiştir (bağlı tüm API'ler), portal adresi |
75
+ | `/ad metin` | `~/.usta/skills/ad.md` becerisini çalıştırır |
76
+
77
+ Seçenekler: `usta --no-portal`, `--no-browser`, `--model`, `--endpoint`, `--mode`, `--theme`, `--context-window`, `--protocol`.
78
+
79
+ ## Portal
80
+
81
+ Terminalle aynı görev yöneticisini kullanır: terminalde başlayan görev portalda canlı görünür ve tersi.
82
+ Yalnız `127.0.0.1`'e bağlanır; tarayıcı jetonla değil, **tek kullanımlık kısa ömürlü kodla** açılır.
83
+
84
+ - **Akış, Değişiklikler, Hafıza, Geçmiş, Önizleme** sekmeleri; renkli diff, iki tıklamalı geri alma, token/önbellek sayacı.
85
+ - **Görev sürerken yönlendirme:** çalışırken yazdığın mesaj ajana bir sonraki adımında iletilir.
86
+ - **Dosya gezgini:** ağacı gez, dosya aç, göreve ekle, dosya/klasör yükle, yeni dosya/klasör, yeniden adlandır, sil.
87
+ - **Dosya ekleme:** metin/Markdown dosyaları isteme *veri olarak* eklenir.
88
+ - **API'ler:** istediğin kadar OpenAI-uyumlu API bağla (Ollama, DeepSeek...). Modelleri üstteki seçicide görünür, oturumdan çıkmadan değişir. Anahtarlar yalnız `~/.usta/apis.json` içindedir (0600), ekranda bir daha gösterilmez.
89
+ - **Önizleme:** statik siteleri (HTML/CSS/JS) yalıtılmış çerçevede gösterir (sandbox iframe; portalın jetonuna ve ağa erişemez).
90
+ - **Araçlar:** beceriler (`.md` yükle) ve katalogdan MCP sunucuları.
91
+ - **Boyut:** arayüz pencere/ekran boyutuna göre otomatik ölçeklenir (%90–%175 elle de seçilebilir); 3 tema.
92
+
93
+ ## Planla, sonra uygula
94
+
95
+ Plan modunda ajan yalnız okur ve plan yazar. Onaylayınca iki yol vardır:
96
+
97
+ - **Aşama aşama (önerilen):** plan `PLAN.md` içinde işaretlenebilir aşamalara bölünür; her aşama **taze bağlamlı ayrı bir görev** olarak koşar
98
+ (okur, uygular, test eder, `- [x]` yapar, durur). İlerleme yoksa, hata, iptal ya da devre kesici durumunda zincir kendiliğinden durur.
99
+ Uzun işlerde istek başına bağlamı sınırlı tutar (küçük, 8K'lık yerel modeller için gerekli). **Toplam token tasarrufu iddia etmiyoruz** (bkz. aşağıdaki ölçüm notu).
100
+ - **Tek seferde:** planın tamamı tek görevde uygulanır.
101
+
102
+ **Ölçüm notu (ara, tek koşu):** aynı onaylı plan (24 bin karakterlik ticari bir e-ticaret sitesi, DeepSeek, 200 adım/görev sınırı, koruma açık). *Tek seferde:* 200 adımda sınıra takıldı — 10,0 milyon girdi token'ı (%94'ü sağlayıcı önbelleğinden), 23 Python dosyası, **hiç test yok**, `PLAN.md`'de 0 madde işaretli. *Aşama aşama:* 11/23 aşamada 18,2 milyon girdi token'ı, 41 dosya, **224 test geçiyor**. Yani aşamalı uygulama toplamda daha çok token harcıyor ama işi doğrulanabilir adımlarla ilerletiyor; tek seferlik koşu ise bağlam şişince adım bütçesini testlere varmadan tüketti. Örneklem tek koşudur; genelleme yapmayın.
103
+
104
+ Plan sunucuda saklanır ve numarasıyla uygulanır; istem yeniden yazılmaz.
105
+
106
+ ## Güvenilirlik ve ölçüm araçları (v0.2.0)
107
+
108
+ Usta'nın amacı modeli olduğundan zeki göstermek değil, mevcut model kapasitesini **güvenilir ve doğrulanabilir** kullanmaktır.
109
+ v0.2.0 bunun için güvenlik ve ölçüm altyapısı ekler. Bunların küçük modellerde görev başarısını artırdığı **kanıtlanmış değildir**;
110
+ hangisinin ne işe yaradığı ve maliyeti [docs/v0.2.0-raporu.md](docs/v0.2.0-raporu.md) içinde sayılarla, başarısız sonuçlar dahil yazılıdır.
111
+
112
+ | Komut | Ne yapar |
113
+ |---|---|
114
+ | `usta lab run/smoke/compare` | **Reliability Lab:** aynı görevi temiz ve saldırılı (araç çıktısı/MCP/README enjeksiyonu, sahte otorite, sızdırma, hafıza zehirleme) çalıştırır; gerçekleşen **araç eylemlerini** değerlendirir (ASR, deneme/gerçekleşme, yanlış ret, toparlanma, token, gecikme). [docs/reliability-lab.md](docs/reliability-lab.md) |
115
+ | `usta bench run --split dev-all\|final` · `diagnose` · `replay` · `regress` | Bench: görevler train/dev/final bölümlü (varsayılan final hariç), her başarısızlık nedene ayrılır (taxonomy), iz kaydı ve **modelsiz tekrar oynatma**, eşleştirilmiş kol karşılaştırması (yalnız yön; küçük örneklemde anlamlılık iddia edilmez), önceki sürüme göre regresyon |
116
+ | `usta probe --deep` · `--protocol auto` | Model yetenek profili: protokol başına 9 sonda (uçtan uca ajan görevleri dahil), model revizyonu + yapılandırmaya bağlı kalıcı profil; `auto` koşu başında bir kez çözülür ve sabitlenir |
117
+ | `usta mcp add --image … / prepare / test` | MCP sunucuları varsayılan olarak **yalıtılmış konteynerde**; paketler `prepare` ile bir kez indirilip sabitlenir |
118
+ | `usta sandbox pin / status` | Sandbox imajının kimliğini sabitler; değişirse çalıştırma reddedilir |
119
+ | `--symbol-tools` (deneysel) | Tree-sitter ile sembol araçları (`pip install 'usta[symbols]'`): `related_files`, `find_symbol`, `symbol_context` |
120
+
121
+ Yürütme aşamaları (DISCOVER → PLAN → EDIT → VERIFY → DIAGNOSE → REPAIR) **gözlemlenir** ve denetim kaydına yazılır; her görev bir terminal
122
+ durumla biter (`COMPLETE_VERIFIED`, `FAILED_VERIFICATION`, `BLOCKED`, …). Başarısız doğrulama başarı olarak gösterilmez; doğrulama ortamındaki
123
+ eksik bağımlılık (kod hatası değil) ayrıca bildirilir. Deneysel olanlar varsayılan **kapalıdır** ve ölçümle doğrulanmadan açılmaz.
124
+
125
+ ## Güvenlik özeti
126
+
127
+ Varsayılan: ağ kapalı, sır yok, yazma yalnız çalışma alanında. Komutlar Docker sandbox'ında; ağ yalnız allowlist proxy'den.
128
+ MCP sunucuları yalıtılmış konteynerde çalışır; kalıcı hafıza notları kaynak izi taşır ve şüpheli notlar onay ister; bağımlılıklar hash'li kilitten kurulur.
129
+ Portal yerel, jetonlu ve CSP'li; model çıktısı hep düz metin basılır. Harici içerik (web, dosya, MCP, ek, plan, hafıza) modele
130
+ *veri* olarak, nonce'lu işaretlerle verilir. Ayrıntı ve açık bildirimi: [SECURITY.md](SECURITY.md), [docs/design.md](docs/design.md).
131
+
132
+ ## Ölçüm: usta bench (ön sonuçlar, dikkatli oku)
133
+
134
+ `usta bench run --arm A|B|C|D` küçük gerçek yazılım görevlerini modelle çalıştırır ve **ajanın göremediği gizli testlerle**
135
+ doğrular (A: yalnız kabuk · B: Usta · C: + doğrulama kapısı · D: + devre kesici). `usta bench compare` katman başına
136
+ tablo ve %95 güven aralığı üretir. Altyapı hataları başarısızlık sayılmaz; token maliyeti raporlanır.
137
+
138
+ | Katman | Model | Kol: geçen/toplam | Not |
139
+ |---|---|---|---|
140
+ | Zayıf | 4B yerel (5 görev × 3) | A 1/15 · B 0/15 · C 1/15 | C ≈ 3,5× token; fark istatistiksel değil |
141
+ | Orta | 7B coder, JSON protokolü (15 × 2) | B 0/30 · D 1/30 | D ≈ 4,5× token; model çözüm üretemiyor |
142
+ | Büyük (API) | DeepSeek (15 × 2) | A 30/30 · B 23/23¹ · C 29/30 · D 30/30 | görevler güçlü model için kolay (tavan etkisi) |
143
+
144
+ ¹ 7 altyapı (ağ) hatası sayılmadı.
145
+
146
+ **Bugün harness'ın başarıyı artırdığını iddia etmiyoruz**: güçlü modelde zarar vermiyor, zayıf modelde tek başına çözüm değil.
147
+ Örneklem küçük, güven aralıkları geniş. Ölçerken bulduklarımız belgelenir (ör. bazı modeller araç çağrısını metin olarak
148
+ yazar → kurtarma ve yetenek sondası eklendi; erken "yazılan dosyayı bağlamdan at" denemesi fayda göstermedi, varsayılan kapalı).
149
+
150
+ ## Geliştirme
151
+
152
+ ```bash
153
+ uv venv && uv pip install -e '.[dev]'
154
+ make ci # ruff + pytest (+ JS mantık testleri için node)
155
+ ```
156
+
157
+ Sandbox testleri için Docker ve yerelde `python:3.12-slim` imajı gerekir (`docker pull python:3.12-slim`; Usta imajı kendiliğinden çekmez). Yoksa bu testler atlanır. Katkı: [CONTRIBUTING.md](CONTRIBUTING.md).
158
+
159
+ ## Ayrıntılar
160
+
161
+ ### Tek seferlik kullanım ve API sunucusu
162
+
163
+ ```bash
164
+ usta run "not.txt dosyasını oku ve özetle" -w ./calisma-alani
165
+ usta serve --model qwen3-vl:4b-instruct # 127.0.0.1:8765; jeton: ~/.usta/token (0600)
166
+ ```
167
+
168
+ `usta serve` REST + SSE API'si sunar (`POST /workspaces/{w}/tasks`, `GET /tasks/{t}/events`, onaylar, diff, geri alma, denetim).
169
+ Bir çalışma alanında aynı anda tek görev çalışır. Loopback dışında dinlemek için `--allow-remote` gerekir.
170
+ Denetim kaydı çalışma alanının dışındadır: `~/.usta/audit/` (`USTA_HOME` ile değişir).
171
+
172
+ ### Sandbox ağı ve web okuma
173
+
174
+ Varsayılan ağ kapalıdır. Operatör olarak alan adı izni: `usta --allow-host pypi.org --allow-host '*.pythonhosted.org'` (ya da `USTA_ALLOW_HOSTS`).
175
+ `fetch_url` ile http/https sayfaları ve PDF'ler (en çok 5 MB / 30 sayfa, metin katmanı) okunur; getirme sandbox içinde, proxy üzerinden yapılır,
176
+ izinli olmayan alan adı **onayla** açılır. Sayfa içeriği modele `<<<HARİCİ-İÇERİK ...>>>` işaretleri arasında *veri* olarak verilir.
177
+
178
+ ### Proje hafızası ve oturumlar
179
+
180
+ `.usta/memory/NOTES.md` (ajanın `remember` ile eklediği notlar) ve son görevler; sonraki görevin başında *veri olarak işaretli* verilir.
181
+ Tüm oturum olayları `~/.usta/sessions/` altında kalıcıdır (portalda **Geçmiş**, terminalde `/geçmiş`).
182
+
183
+ ### Ek araçlar: MCP
184
+
185
+ Hiçbiri varsayılan gelmez; sen eklersin. Sunucular varsayılan olarak **yalıtılmış Docker konteynerinde** çalışır (ağ kapalı, ev dizini ve
186
+ Docker soketi yok, salt okunur kök, CPU/RAM/PID sınırlı; çalışma alanı yalnız istersen bağlanır). Docker/imaj yoksa sunucu başlamaz.
187
+
188
+ ```bash
189
+ docker pull node:22-slim # Usta imajı kendiliğinden çekmez
190
+ usta mcp add arama --image node:22-slim --allow-host api.search.brave.com --env BRAVE_API_KEY \
191
+ -- npx -y @brave/brave-search-mcp-server@2.1.4 --transport stdio
192
+ usta mcp prepare arama # paketleri yalnız paket kayıtlarına açık ağda indirir, imajı ve önbelleği sabitler
193
+ usta mcp test arama
194
+ ```
195
+
196
+ `usta mcp list|enable|disable|remove` de vardır. Sunucuyu ana makinede çalıştırmak (yalıtımsız, senin yetkilerinle) ayrı ve açık bir uyumluluk
197
+ modudur: `--isolation host --i-understand-host-risk`. Anahtar değerleri komut geçmişine yazılmaz. Varsayılan olarak her MCP çağrısı onayına
198
+ sunulur. Portal yalnız gözden geçirilmiş katalogdan ekler (her zaman konteynerde); serbest komut yalnız CLI'dadır.
199
+
200
+ ### Beceriler
201
+
202
+ `~/.usta/skills/ad.md` (ilk satır açıklama). Mesajda ya da terminalde `/ad ek metin` yazınca beceri metni + ek metin istem olur. Portaldan `.md` yüklenir.
203
+
204
+ ### Yerel araç çağrısı olmayan modeller
205
+
206
+ `--protocol json` (şemayla kısıtlı yanıt) ya da `--protocol text` (JSON + ayrı kod blokları). Normalde yetenek sondası en uygununu seçer
207
+ (`usta probe`).
208
+
209
+ ## Lisans
210
+
211
+ Apache-2.0. Bkz. [LICENSE](LICENSE).