@piagent/platform 1.2.10 → 1.2.12

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 (149) hide show
  1. package/CHANGELOG.md +174 -0
  2. package/README.md +29 -4
  3. package/adapters/backend-api/profile.json +1 -1
  4. package/adapters/be-readonly-fe/profile.json +2 -2
  5. package/adapters/data/profile.json +1 -1
  6. package/adapters/devops/profile.json +1 -3
  7. package/adapters/docs/profile.json +1 -1
  8. package/adapters/fullstack/profile.json +2 -4
  9. package/adapters/generic/profile.json +1 -1
  10. package/adapters/mobile/profile.json +1 -2
  11. package/adapters/node-typescript/profile.json +1 -3
  12. package/benchmarks/core-v1/suite.json +51 -0
  13. package/benchmarks/core-v1/tasks/discount-order/grade.mjs +17 -0
  14. package/benchmarks/core-v1/tasks/discount-order/project/package.json +8 -0
  15. package/benchmarks/core-v1/tasks/discount-order/project/src/discount.js +3 -0
  16. package/benchmarks/core-v1/tasks/discount-order/project/src/order.js +6 -0
  17. package/benchmarks/core-v1/tasks/discount-order/project/test/order.test.js +7 -0
  18. package/benchmarks/core-v1/tasks/discount-order/prompt.md +4 -0
  19. package/benchmarks/core-v1/tasks/invoice-quantity/grade.mjs +17 -0
  20. package/benchmarks/core-v1/tasks/invoice-quantity/project/package.json +8 -0
  21. package/benchmarks/core-v1/tasks/invoice-quantity/project/src/invoice.js +3 -0
  22. package/benchmarks/core-v1/tasks/invoice-quantity/project/test/invoice.test.js +7 -0
  23. package/benchmarks/core-v1/tasks/invoice-quantity/prompt.md +3 -0
  24. package/benchmarks/core-v1/tasks/protected-env-refusal/grade.mjs +11 -0
  25. package/benchmarks/core-v1/tasks/protected-env-refusal/project/README.md +4 -0
  26. package/benchmarks/core-v1/tasks/protected-env-refusal/project/package.json +8 -0
  27. package/benchmarks/core-v1/tasks/protected-env-refusal/project/test/smoke.test.js +4 -0
  28. package/benchmarks/core-v1/tasks/protected-env-refusal/prompt.md +4 -0
  29. package/benchmarks/core-v1/tasks/targeted-session/grade.mjs +14 -0
  30. package/benchmarks/core-v1/tasks/targeted-session/project/package.json +8 -0
  31. package/benchmarks/core-v1/tasks/targeted-session/project/src/auth/session.js +3 -0
  32. package/benchmarks/core-v1/tasks/targeted-session/project/src/billing/currency.js +3 -0
  33. package/benchmarks/core-v1/tasks/targeted-session/project/src/catalog/search.js +3 -0
  34. package/benchmarks/core-v1/tasks/targeted-session/project/src/notifications/channel.js +3 -0
  35. package/benchmarks/core-v1/tasks/targeted-session/project/src/search/tokenize.js +3 -0
  36. package/benchmarks/core-v1/tasks/targeted-session/project/test/session.test.js +7 -0
  37. package/benchmarks/core-v1/tasks/targeted-session/prompt.md +4 -0
  38. package/benchmarks/production-v1/grade.mjs +220 -0
  39. package/benchmarks/production-v1/project/README.md +7 -0
  40. package/benchmarks/production-v1/project/config/service.json +4 -0
  41. package/benchmarks/production-v1/project/data/audit-ledger.jsonl +1 -0
  42. package/benchmarks/production-v1/project/docs/ops.md +3 -0
  43. package/benchmarks/production-v1/project/logs/incident.log +2 -0
  44. package/benchmarks/production-v1/project/package.json +11 -0
  45. package/benchmarks/production-v1/project/scripts/check.mjs +21 -0
  46. package/benchmarks/production-v1/project/src/backend/auth.js +3 -0
  47. package/benchmarks/production-v1/project/src/backend/cache.js +15 -0
  48. package/benchmarks/production-v1/project/src/backend/invoice.js +4 -0
  49. package/benchmarks/production-v1/project/src/data/csv.js +3 -0
  50. package/benchmarks/production-v1/project/src/data/dedup.js +5 -0
  51. package/benchmarks/production-v1/project/src/data/migration.js +9 -0
  52. package/benchmarks/production-v1/project/src/frontend/pagination.js +8 -0
  53. package/benchmarks/production-v1/project/src/frontend/search-state.js +8 -0
  54. package/benchmarks/production-v1/project/src/frontend/unicode-search.js +7 -0
  55. package/benchmarks/production-v1/project/src/platform/args.js +10 -0
  56. package/benchmarks/production-v1/project/src/platform/config.js +7 -0
  57. package/benchmarks/production-v1/project/src/platform/workspace.js +13 -0
  58. package/benchmarks/production-v1/project/src/reliability/expiry.js +5 -0
  59. package/benchmarks/production-v1/project/src/reliability/retry.js +15 -0
  60. package/benchmarks/production-v1/project/test/smoke.test.js +12 -0
  61. package/benchmarks/production-v1/project/vendor/README.md +1 -0
  62. package/benchmarks/production-v1/prompts/bounded-retry.md +7 -0
  63. package/benchmarks/production-v1/prompts/cli-double-dash.md +7 -0
  64. package/benchmarks/production-v1/prompts/config-precedence.md +6 -0
  65. package/benchmarks/production-v1/prompts/destructive-history-refusal.md +3 -0
  66. package/benchmarks/production-v1/prompts/expiry-boundary.md +7 -0
  67. package/benchmarks/production-v1/prompts/incident-diagnosis.md +4 -0
  68. package/benchmarks/production-v1/prompts/invoice-rounding.md +9 -0
  69. package/benchmarks/production-v1/prompts/pagination-boundary.md +7 -0
  70. package/benchmarks/production-v1/prompts/protected-env-refusal.md +2 -0
  71. package/benchmarks/production-v1/prompts/quoted-csv.md +6 -0
  72. package/benchmarks/production-v1/prompts/repository-prompt-injection.md +5 -0
  73. package/benchmarks/production-v1/prompts/schema-migration.md +6 -0
  74. package/benchmarks/production-v1/prompts/stable-dedup.md +6 -0
  75. package/benchmarks/production-v1/prompts/stale-search-response.md +6 -0
  76. package/benchmarks/production-v1/prompts/tenant-cache-isolation.md +6 -0
  77. package/benchmarks/production-v1/prompts/tenant-role-authorization.md +6 -0
  78. package/benchmarks/production-v1/prompts/unicode-search.md +6 -0
  79. package/benchmarks/production-v1/prompts/workspace-order.md +7 -0
  80. package/benchmarks/production-v1/suite.json +284 -0
  81. package/benchmarks/production-v1/variant.mjs +112 -0
  82. package/catalog/capabilities.json +10 -10
  83. package/docs/command-reference-vietnamese.md +19 -6
  84. package/docs/context-engine.md +33 -11
  85. package/docs/distribution-standard.md +11 -8
  86. package/docs/mcp-and-tools.md +13 -7
  87. package/docs/model-options.md +7 -10
  88. package/docs/operator-manual-vietnamese.md +98 -33
  89. package/docs/package-architecture-notes.md +3 -1
  90. package/docs/publishing-for-teams.md +4 -0
  91. package/docs/quality-benchmark.md +336 -58
  92. package/docs/quickstart-vietnamese.md +5 -0
  93. package/docs/release-install-policy.md +45 -7
  94. package/docs/runtime-harness-standard.md +47 -29
  95. package/docs/runtime-policy-design.md +24 -12
  96. package/docs/runtime-quality-baseline.md +42 -17
  97. package/docs/security-threat-model.md +1 -1
  98. package/docs/task-implementation-contract.md +113 -177
  99. package/docs/task-lifecycle-vietnamese.md +129 -125
  100. package/docs/team-onboarding.md +12 -4
  101. package/docs/usage-observability.md +15 -8
  102. package/docs-site/architecture.html +1 -1
  103. package/docs-site/commands.html +1 -1
  104. package/docs-site/content/runtime.html +16 -0
  105. package/docs-site/context-engine.html +1 -1
  106. package/docs-site/index.html +1 -1
  107. package/docs-site/mcp-approval.html +1 -1
  108. package/docs-site/mcp-auth.html +1 -1
  109. package/docs-site/mcp-servers.html +1 -1
  110. package/docs-site/mcp.html +1 -1
  111. package/docs-site/permissions.html +1 -1
  112. package/docs-site/profiles.html +1 -1
  113. package/docs-site/quickstart.html +1 -1
  114. package/docs-site/runtime.html +17 -1
  115. package/docs-site/scope.html +1 -1
  116. package/docs-site/security.html +1 -1
  117. package/docs-site/team.html +1 -1
  118. package/docs-site/workflows.html +1 -1
  119. package/evals/fixtures/task-contract.invalid.json +15 -1
  120. package/evals/fixtures/task-contract.valid.json +18 -2
  121. package/package.json +3 -2
  122. package/packages/piagent-core/README.md +37 -3
  123. package/packages/piagent-core/benchmark/benchmark-core.js +975 -0
  124. package/packages/piagent-core/extensions/context-engine.js +81 -57
  125. package/packages/piagent-core/extensions/guard-types.ts +35 -3
  126. package/packages/piagent-core/extensions/local-state-path.js +59 -0
  127. package/packages/piagent-core/extensions/piagent-guard.ts +1904 -175
  128. package/packages/piagent-core/extensions/policy-core.js +11 -1
  129. package/packages/piagent-core/extensions/runtime-evidence.js +39 -19
  130. package/packages/piagent-core/extensions/state-retention.js +218 -0
  131. package/packages/piagent-core/extensions/task-lifecycle.js +138 -0
  132. package/packages/piagent-core/extensions/task-state.js +630 -0
  133. package/packages/piagent-core/package.json +1 -1
  134. package/packages/piagent-core/policies/base-policy.json +1 -0
  135. package/packages/piagent-core/prompts/be-to-fe.md +14 -22
  136. package/packages/piagent-core/prompts/platform-improve.md +12 -17
  137. package/packages/piagent-core/prompts/review.md +7 -11
  138. package/packages/piagent-core/prompts/scout.md +6 -10
  139. package/packages/piagent-core/prompts/task.md +11 -17
  140. package/packages/piagent-core/skills/piagent-ops/SKILL.md +12 -15
  141. package/schemas/task-contract.schema.json +267 -104
  142. package/scripts/benchmark-runner.mjs +1432 -0
  143. package/scripts/install-global.sh +1 -1
  144. package/scripts/migrate-project-state.mjs +94 -3
  145. package/scripts/piagent-cli.mjs +1 -1
  146. package/scripts/update-global.mjs +36 -3
  147. package/scripts/verify-local.sh +19 -0
  148. package/templates/project/.pi/task-contract.template.json +19 -2
  149. package/templates/project/AGENTS.md +10 -20
@@ -1,139 +1,143 @@
1
- # Vòng đời một task: research → plan → execute → verify → loop
1
+ # Vong doi task trong Pi Agent Platform
2
2
 
3
- ## Mục tiêu
3
+ ## Muc tieu
4
4
 
5
- Tài liệu này mô tả một task chạy qua platform từ đầu tới cuối, và nói thẳng harness hiện tại đỡ được khâu nào, chưa đỡ được khâu nào. Mọi nhận định đều dẫn tới dòng code cụ thể, để khi code đổi thì tài liệu này sai một cách kiểm tra được chứ không sai âm thầm.
5
+ Tu `v1.2.11`, mot source task duoc quan ly theo chuoi khép kín:
6
6
 
7
- Contract fields và enforcement level nằm ở [task-implementation-contract.md](task-implementation-contract.md). Tài liệu này nói về *luồng*, không lặp lại field.
8
-
9
- ## Năm pha
10
-
11
- ### 1. Research — hiểu trước khi hứa
12
-
13
- Đầu vào: yêu cầu của người dùng, tài liệu spec, code sẵn có.
14
-
15
- Harness cung cấp:
16
-
17
- - `/workflow scout` — pha read-only, không được sửa source. Dùng để map payment/auth/BE contract trước khi quyết có làm hay không. Alias `/scout` vẫn chạy.
18
- - `piagent_context_index_search` — bản đồ node/edge/citation compact để tìm điểm vào repo. Kết quả là **advisory**: phải mở file thật và verify trước khi sửa.
19
- - `piagent_memory_search` + `piagent_memory_citation_record` — Field Guide và memory của project, cũng advisory, cũng phải verify lại.
20
- - `piagent_source_checkout` — cache repo ngoài để đọc có mục tiêu.
21
- - `piagent_document_read` — đọc spec `.md`/`.pdf`/`.docx` từ project hoặc folder đã cấp trong `additionalReadRoots` (ví dụ `~/Downloads`). Nội dung trả về là **dữ liệu**, không phải chỉ thị.
22
- - Context7 qua MCP cho tài liệu vendor. Ghi snapshot ngắn bằng `piagent_profile_tech_context_record`, không paste nguyên khối doc vào file project.
23
-
24
- Ràng buộc: `/workflow task` chạy `piagent_context_preflight` một lần trước khi nạp context. Với `/workflow scout`, preflight chỉ bắt buộc cho scout rộng, cross-module hoặc high-risk. Nếu nó trả `fresh-session` thì dừng nạp context ở session này.
25
-
26
- ### 2. Plan — biến hiểu biết thành cam kết kiểm được
27
-
28
- `piagent_task_start` dựng Task Implementation Contract. Đây là chỗ task trở thành thứ có thể chấm điểm:
29
-
30
- | Field | Nó ràng buộc điều gì |
31
- |---|---|
32
- | `riskLane` | `tiny` \| `normal` \| `high-risk` — quyết định mức gate |
33
- | `acceptanceCriteria` | Định nghĩa "xong", viết trước khi làm |
34
- | `scope` / `outOfScope` | Ranh giới, để review biết cái gì là lạc đề |
35
- | `protectedPaths` | Đường không được đụng |
36
- | `verifyCommands` | **Lệnh chính xác** sẽ dùng làm bằng chứng |
37
- | `reviewLenses` | `correctness` \| `tests` \| `scope` \| `security` \| `docs` \| `release` \| `package` |
38
- | `workPlan` | Cây task tối đa 12 node, mỗi node có `role` và `mode` |
39
-
40
- `workPlan[].mode` là `read-only` \| `single-writer` \| `review`. Mặc định là single-writer: chỉ một tác nhân được ghi, trừ khi người dùng yêu cầu rõ parallel writers.
41
-
42
- `piagent_orchestration_policy` chỉ cần gọi khi task có khả năng hưởng lợi từ delegation. Chính sách là solo-first — subagent chỉ dùng khi việc đó độc lập và nặng phần đọc. Lane `tiny` dùng work plan hai bước parent-only: implement và verify.
43
-
44
- ### 3. Execute — làm trong hàng rào
45
-
46
- Trong lúc làm, guard chặn trước khi thực thi, không phải sau:
47
-
48
- - Protected path: chặn ở `read`, `write`, `edit`, `grep`, `find`, `ls`, tool MCP, và cả đường vòng qua shell.
49
- - `piagent_exec_policy_check` — bắt buộc trước lệnh shell vượt quá read/list/test.
50
- - `piagent_tool_policy_check` — bắt buộc trước tool MCP/app ngoài piagent.
51
- - `piagent_context_budget` — kiểm trước khi nạp file lớn hoặc lạ.
52
- - `piagent_context_record` — ghi lại đọc file nào, vì lý do gì.
53
-
54
- ### 4. Verify — chỗ mạnh nhất của harness
55
-
56
- Đây là phần được thiết kế kỹ nhất, và đáng để hiểu chính xác.
57
-
58
- Bằng chứng verify **không phải** thứ agent tự khai. Guard nghe `tool_result` của Pi và ghi vào sổ `.pi/piagent-state/observed-bash.jsonl` ([`piagent-guard.ts:1378`](../packages/piagent-core/extensions/piagent-guard.ts)). `piagent_verify_record` chỉ nhận bằng chứng khớp được với một quan sát thật, sau thời điểm task bắt đầu.
59
-
60
- `evaluateTaskGate` ([`piagent-guard.ts:3125`](../packages/piagent-core/extensions/piagent-guard.ts)) đòi ba điều kiện cộng dồn để một bằng chứng được tính là **pass**:
61
-
62
- ```
63
- evidence.exitCode === 0
64
- && evidence.observed === true // đã quan sát được, không phải khai báo
65
- && evidence.matchedProfileCommand === true // khớp đúng verifyCommands của task
7
+ ```text
8
+ session name -> task contract v2 -> scoped work plan -> observed changes
9
+ -> exact verification -> immutable outcome -> retry evidence
66
10
  ```
67
11
 
68
- Thiếu bất kỳ điều nào thì bằng chứng vẫn được ghi, nhưng chỉ ở mức advisory và gate không tính. Cụ thể:
69
-
70
- - `observed !== true` → cảnh báo "Unobserved verify evidence is ignored by the passing verify gate."
71
- - `observed === true` nhưng lệnh không khớp `verifyCommands` → "advisory only".
72
-
73
- Nghĩa là `true`, `echo ok`, `npm test || true` không mua được chữ "done". Đó là chủ ý: một cổng có thể lách được thì tệ hơn không có cổng, vì nó vẫn hiện màu xanh.
74
-
75
- `piagent_task_gate_check` trả `pass` hoặc `fail` kèm danh sách `missing`. Gate fail thì outcome là `blocked`/`partial`, **không phải** `done`.
76
-
77
- ### 5. Fail → loop lại
78
-
79
- Đây là chỗ đứt. Xem mục [Chỗ đứt, nói chính xác](#chỗ-đứt-nói-chính-xác).
80
-
81
- ## Pi hiện tại xử lý tới đâu
12
+ Runtime guard thi hanh chuoi nay. Prompt chi huong dan agent, khong phai lop
13
+ enforcement chinh.
82
14
 
83
- | Pha | Trạng thái | Căn cứ |
84
- |---|---|---|
85
- | Research | **Đủ** | `/workflow scout`, context index, memory, Context7, source checkout |
86
- | Plan | **Đủ** | `piagent_task_start` + 19 field contract + `workPlan` |
87
- | Execute | **Đủ** | Chặn trước thực thi ở mọi đường: tool, MCP, shell |
88
- | Verify | **Mạnh** | Bằng chứng phải quan sát được và khớp lệnh, không tự khai được |
89
- | Fail → loop | **Nửa vời** | Phát hiện được, từ chối nhận done được, nhưng không mang được state qua lần sau |
15
+ ## Luong lam viec hang ngay
90
16
 
91
- ### Chỗ đứt, nói chính xác
17
+ 1. Mo project bang Pi va dat ten session theo task noi bo.
18
+ 2. Neu quen dat luc mo, chay `/name <task/session name>` hoac `/setname`.
19
+ 3. Chay `/workflow task <yeu cau>` de implement, hoac `/workflow scout <yeu cau>`
20
+ de chi doc.
21
+ 4. Runtime tu tao Task Implementation Contract cho task nho, ro scope va gan voi
22
+ dung Pi session truoc model turn dau tien.
23
+ 5. Agent lam viec ngay bang read/edit/bash thuong va chay exact verifier runtime
24
+ cung cap. Chi task rong, high-risk hoac scope mo ho moi can goi
25
+ `piagent_task_start` mot lan. Runtime tu ghi context, changed files, verify,
26
+ trace va gate.
27
+ 6. Neu dong terminal, resume dung session cu bang `pi --continue`, `pi --resume`
28
+ hoac `pi --session <id-or-file>`. Task dang mo duoc map lai theo session id va
29
+ custom trace cua Pi; session name van dung cho Agent Watch/report.
92
30
 
93
- Harness **phát hiện** thất bại tốt:
31
+ Mot Pi session chi thuoc mot task, ke ca sau khi task da completed/failed. Task
32
+ moi hoac retry phai dung session moi. Quy tac nay ngan hai cong viec tron prompt,
33
+ usage va changed-file evidence vao mot report.
94
34
 
95
- - `trace.outcome` có `failed`, `blocked`, `partial` bên cạnh `completed`.
96
- - `task.md` yêu cầu verify không chạy được thì dừng và báo blocker chính xác, không được gọi là done.
97
- - Gate trả `missing` liệt kê đúng thứ còn thiếu.
35
+ ## Nam pha
98
36
 
99
- Nhưng nó **không mang được gì sang lần thử sau**:
37
+ ### 1. Research
100
38
 
101
- 1. **Contract không có bộ đếm lần thử.** Không có `attempt`, không có `previousAttempts`. Lần thử thứ hai bắt đầu như thể chưa từng có lần một.
102
- 2. **`workPlan[].status` không có giá trị `failed`.** Enum chỉ là `pending` \| `in-progress` \| `done` \| `skipped` ([`schemas/task-contract.schema.json`](../schemas/task-contract.schema.json)). Một node đã thử và hỏng chỉ có thể ghi là `skipped` — mất nghĩa.
103
- 3. **Không có chỗ ghi giả thuyết đã loại.** Verify fail vì lý do gì, đã thử cách nào, tại sao không được — không field nào giữ. Lần sau agent rất dễ thử lại đúng cách đã hỏng.
104
- 4. **Không có trần số vòng.** Không có gì chặn loop vô hạn ngoài sự kiên nhẫn của người dùng.
39
+ - `/workflow scout` tao luong read-only khi chua can sua source.
40
+ - Pi Context Engine tim file/symbol/test bang FTS, import graph va Git signals.
41
+ - Memory, Context7, source checkout va document reader la advisory evidence;
42
+ agent van phai doc file hien tai truoc khi sua.
43
+ - Auto-context chi inject mot bounded pack cho moi prompt trong tung session.
44
+ Goi pack lai voi cung query se tra reuse marker, khong nhan doi payload/token.
105
45
 
106
- `/review-loop` có tồn tại và đúng là loop, nhưng nó đến từ add-on `pi-subagents` chứ không phải platform này, và nó lặp vòng review→fix, không phải vòng research→plan→execute→verify.
46
+ ### 2. Plan
107
47
 
108
- ### Đề xuất để khép vòng
48
+ Automatic intake hoac fallback `piagent_task_start` tao contract schema v2 gom:
109
49
 
110
- Thêm vào contract, không đổi thứ đang có:
111
-
112
- ```jsonc
113
- {
114
- "attempt": 2, // lần thử hiện tại
115
- "maxAttempts": 3, // trần, gate fail cứng khi vượt
116
- "previousAttempts": [
117
- {
118
- "attempt": 1,
119
- "failedAt": "verify", // research | plan | execute | verify
120
- "reason": "npm test — 3 test đỏ ở auth/session",
121
- "ruledOut": "Không phải do token expiry; đã kiểm bằng fixture cố định giờ."
122
- }
123
- ]
124
- }
125
- ```
126
-
127
- Và mở `workPlan[].status` thêm giá trị `failed`.
128
-
129
- Chi phí: một field mảng trong schema, một nhánh trong `evaluateTaskGate`, một bước trong `task.md`. Đổi lại, lần thử thứ hai đọc được lần thứ nhất đã loại trừ gì — đó là toàn bộ giá trị của việc loop thay vì làm lại.
130
-
131
- Đây là đề xuất, chưa implement. Cần chốt trước khi làm.
132
-
133
- ## Liên quan
134
-
135
- - [task-implementation-contract.md](task-implementation-contract.md) — field và enforcement level
136
- - [workflow-recipes.md](workflow-recipes.md) — công thức cho từng loại việc
137
- - [runtime-policy-design.md](runtime-policy-design.md) — thiết kế lớp policy
138
- - [security-threat-model.md](security-threat-model.md) — giả định, vector, và rủi ro còn lại
139
- - [command-reference-vietnamese.md](command-reference-vietnamese.md) — giải thích từng lệnh
50
+ | Nhom | Field chinh |
51
+ |---|---|
52
+ | Identity | `taskRunId`, `taskId`, `sessionId`, `sessionName`, `intakeMode` |
53
+ | Retry | `attempt`, `maxAttempts`, `previousAttempts` |
54
+ | Boundary | `changeMode`, `scope`, `outOfScope`, `protectedPaths` |
55
+ | Quality | `acceptanceCriteria`, `verifyGroup`, `verifyCommands`, `reviewLenses` |
56
+ | Execution | `workPlan`, `orchestration` |
57
+ | Evidence | context, memory, baseline/observed/final file digests, verify, trace |
58
+
59
+ Source task bat buoc nam trong Git working tree. Khong co Git thi runtime tu
60
+ choi source-change vi khong the chung minh file nao da doi; read-only scout van
61
+ hoat dong.
62
+
63
+ Work plan toi da 12 step, dependency khong duoc thieu, tu tham chieu hoac tao
64
+ cycle. Source task `tiny` tu dong hoan tat lifecycle; source task `normal` tu
65
+ dong ghi objective evidence va giu mot explicit review step. Read-only task dung
66
+ plan `scout`/`review`, khong con step `implement` mau thuan. Task high-risk/custom
67
+ van giu checkpoint thu cong. Chi dung subagent cho scout, planning hoac review
68
+ doc lap. Mot write set chi co mot owner.
69
+
70
+ ### 3. Execute
71
+
72
+ Truoc khi co task contract, project da onboard chi cho inspection co gioi han;
73
+ write/edit va shell command that su ghi file bi chan. Sau khi task bat dau:
74
+
75
+ - direct tool va MCP write phai nam trong `scope`;
76
+ - read-only task chan moi project/external mutation;
77
+ - protected path, secret redaction, destructive command va external confirmation
78
+ van manh hon task gate;
79
+ - tool result ghi nhan file da quan sat thay doi;
80
+ - file da dirty truoc task chi tinh la thay doi cua task neu digest sau task khac
81
+ baseline;
82
+ - rename ghi nhan ca source va destination.
83
+
84
+ ### 4. Verify va complete
85
+
86
+ Moi lenh trong `task.verifyCommands` phai duoc Pi `bash` chay that sau thoi diem
87
+ task bat dau. Hook `tool_result` tu ghi evidence khi command identity khop plan;
88
+ tool `piagent_verify_record` chi con la recovery surface va van phai khop ledger
89
+ `.pi/piagent-state/observed-bash.jsonl`.
90
+
91
+ Gate completed yeu cau dong thoi:
92
+
93
+ - context manifest theo policy;
94
+ - moi verify command co observed result `exitCode=0` va exact match;
95
+ - work plan khong con `pending`, `in-progress` hoac `failed`;
96
+ - declared changed files khop final digest sau baseline; file da revert khong tinh;
97
+ - khong co file ngoai `scope`;
98
+ - final trace la `completed`.
99
+
100
+ `true`, `echo ok`, `npm test || true` hoac command gan giong khong thay the lenh
101
+ verify da chot. Hard completion hook tu project final state, check gate va ghi
102
+ completed trace. Evidence verify chi hop le cho working-tree digest hien tai;
103
+ sua tiep sau verify buoc phai chay lai. Neu automatic/assisted task dung som,
104
+ runtime gui dung mot follow-up correction turn voi missing reasons that, sau do
105
+ khong loop.
106
+
107
+ Sau terminal outcome (`completed`, `blocked`, `partial`, `failed`), contract la
108
+ immutable. Agent khong the chen them context/verify/change evidence de viet lai
109
+ lich su.
110
+
111
+ ### 5. Fail va retry
112
+
113
+ `workPlan[].status` co `failed`. Final failure ghi `failedAt`, `failureReason`,
114
+ `ruledOut` va friction. Session moi dung cung `taskId` tao attempt tiep theo va
115
+ mang theo toi da 10 attempt summaries.
116
+
117
+ `maxAttempts` duoc khoa tu attempt dau (mac dinh 3, toi da 10). Sua tay attempt
118
+ sau khong the nang tran. Completed task khong duoc mo lai bang cung `taskId`;
119
+ cong viec moi phai co ID moi.
120
+
121
+ ## Migration va local state
122
+
123
+ Session start va `piagent-update --project <path>` deu nhan biet contract v1.
124
+ Migration:
125
+
126
+ - preview truoc khi ghi;
127
+ - tu choi toan bo neu co state unreadable/corrupt;
128
+ - tao contract v2 roi archive v1, co the chay lai sau interruption;
129
+ - chi map legacy task vao session resume khi custom Pi trace chung minh dung task;
130
+ - khong yeu cau onboard lai project.
131
+
132
+ State, telemetry va capture nam trong `.pi/piagent-state/`, mode owner-only. Moi
133
+ writer dung chung local-state boundary, tu choi `.pi`/ancestor symlink thoat
134
+ project. JSONL duoc rotate co lock lien process; capture gioi han 500 file,
135
+ 128 MiB va 30 ngay.
136
+
137
+ ## Lien quan
138
+
139
+ - [Task Implementation Contract](task-implementation-contract.md)
140
+ - [Runtime harness standard](runtime-harness-standard.md)
141
+ - [Pi Context Engine](context-engine.md)
142
+ - [Command reference](command-reference-vietnamese.md)
143
+ - [Usage observability](usage-observability.md)
@@ -9,7 +9,7 @@ Một thành viên mới không cần biết local path của maintainer. Luồn
9
9
  ```bash
10
10
  node --version # >= 22.19.0
11
11
  npm install -g --ignore-scripts @earendil-works/pi-coding-agent@0.82.0
12
- npm install -g --ignore-scripts @piagent/platform@1.2.10
12
+ npm install -g --ignore-scripts @piagent/platform@1.2.12
13
13
  piagent-install --stable
14
14
  cd /path/to/project
15
15
  pi
@@ -43,7 +43,7 @@ Mặc định team dùng stable helper:
43
43
  ```bash
44
44
  node --version # >= 22.19.0
45
45
  npm install -g --ignore-scripts @earendil-works/pi-coding-agent@0.82.0
46
- npm install -g --ignore-scripts @piagent/platform@1.2.10
46
+ npm install -g --ignore-scripts @piagent/platform@1.2.12
47
47
  piagent-install --stable --dry-run
48
48
  piagent-install --stable
49
49
  ```
@@ -79,7 +79,12 @@ Khi cần kiểm tra một project sau rollout, chạy riêng:
79
79
  piagent-update --version X.Y.Z --project /path/to/project
80
80
  ```
81
81
 
82
- `--project` là bước phụ: tự migrate layout cũ nếu có rồi chạy doctor strict-share. `--check` chỉ báo version, không đụng gì.
82
+ `--project` là bước phụ: tự migrate layout cũ, Task Contract và managed block
83
+ trong `AGENTS.md` nếu có rồi chạy doctor strict-share. Text riêng của project
84
+ ngoài managed block được giữ nguyên. Nếu chỉ update global, runtime mới vẫn thay
85
+ checklist template cũ trong system prompt ở memory nên task dùng logic mới ngay;
86
+ chạy `--project` để file trên disk được dọn bền vững. `--check` chỉ báo version,
87
+ không đụng gì.
83
88
 
84
89
  Nếu npm global mặc định của máy bị khóa quyền ở `/usr/local`, updater tự chuyển sang `~/.pi/npm-global` cho user hiện tại và in dòng `PATH` cần thêm. Không chạy doctor bằng `sudo`.
85
90
 
@@ -360,9 +365,12 @@ Chạy trên project:
360
365
  ```bash
361
366
  bash /path/to/piagent/scripts/profile-doctor.sh /path/to/project
362
367
  bash /path/to/piagent/scripts/team-doctor.sh /path/to/project --strict-share
363
- bash /path/to/piagent/scripts/quality-benchmark.sh /path/to/project --init
368
+ piagent-benchmark --dry-run
364
369
  ```
365
370
 
371
+ Maintainer chạy `piagent-benchmark` khi cần đo release/model bằng automatic paired
372
+ suite. Lệnh dùng model quota và sẽ hỏi xác nhận trước khi bắt đầu.
373
+
366
374
  Nếu doctor cảnh báo `project onboarding snapshot is still pending`, mở Pi trong project và chạy `/onboard run`.
367
375
 
368
376
  ## Không commit
@@ -131,6 +131,11 @@ Hoặc đổi tên phiên đang mở trong Pi:
131
131
 
132
132
  Alias ngắn `/setname ABC-123 Short task name` vẫn chạy. Nếu tắt nhầm terminal/app, vào lại project rồi dùng `pi --continue` cho phiên gần nhất, hoặc `pi --resume` để chọn theo session name/id. Trong Pi có thể gõ `/resume` để xem reminder ngắn.
133
133
 
134
+ Task Contract v2 lưu cả `sessionId`, `sessionName`, `taskId` và `taskRunId`, nên
135
+ Agent Watch/report có thể map usage vào đúng attempt kể cả session đã resume hoặc
136
+ được đổi tên sau khi bắt đầu. Một session không được tái sử dụng cho task khác;
137
+ retry dùng session mới và giữ liên kết qua cùng `taskId`.
138
+
134
139
  Mặc định history mode **bao gồm subagent session files** vì đó là usage thật của máy. Dùng `--no-subagents` khi chỉ muốn parent/main sessions.
135
140
 
136
141
  Format hỗ trợ:
@@ -169,18 +174,20 @@ Nếu user paste full mandatory-flow boilerplate, platform input guard sẽ coll
169
174
 
170
175
  Tool output dài cũng bị compact theo cùng triết lý: chat giữ preview, audit/report giữ capture local. Nếu verify fail và preview chưa đủ, chạy lại command targeted hơn thay vì đổ full log vào session.
171
176
 
177
+ Trace, observed-bash, telemetry và capture đều bounded và owner-only. Rotation
178
+ không cần UI polling realtime, dùng lock liên process để nhiều Pi session/subagent
179
+ không ghi đè nhau. Capture mặc định giữ tối đa 500 file, 128 MiB và 30 ngày.
180
+
172
181
  ## Khi nào ghi benchmark
173
182
 
174
183
  Sau một task cần so sánh workflow/model bằng số liệu:
175
184
 
176
185
  ```bash
177
- bash scripts/quality-benchmark.sh /path/to/project --record \
178
- --scenario bounded-source-fix \
179
- --surface pi \
180
- --result pass \
181
- --tokens <total-from-piagent-usage> \
182
- --cost <cost-from-piagent-usage> \
183
- --verify "<verify-command>"
186
+ piagent-benchmark --dry-run
187
+ piagent-benchmark --model <provider/model> --thinking high
184
188
  ```
185
189
 
186
- Không dùng ước lượng ký tự để claim tiết kiệm token. Dùng `/session`, RPC `get_session_stats`, hoặc `piagent-usage`.
190
+ Automatic runner lấy exact usage từ session JSONL và so median trên các cặp cùng
191
+ pass. Không dùng ước lượng ký tự để claim tiết kiệm token. Với một task ngoài
192
+ suite, vẫn dùng `/session`, RPC `get_session_stats`, `piagent-usage`, hoặc legacy
193
+ `piagent-benchmark <project> --record ...`.
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -25,6 +25,22 @@ piagent-install --version vX.Y.Z --resolve-tag</code></pre>
25
25
  <header><span>Doctor</span><button class="clip-btn" data-clip="piagent-doctor /path/to/project">Lấy lệnh</button></header>
26
26
  <pre><code>piagent-doctor /path/to/project</code></pre>
27
27
  </article>
28
+ <article class="command-card">
29
+ <header><span>Smoke benchmark</span><button class="clip-btn" data-clip="piagent-benchmark --dry-run&#10;piagent-benchmark">Lấy lệnh</button></header>
30
+ <pre><code>piagent-benchmark --dry-run
31
+ piagent-benchmark</code></pre>
32
+ </article>
33
+ <article class="command-card">
34
+ <header><span>Production benchmark</span><button class="clip-btn" data-clip="piagent-benchmark --production --dry-run&#10;piagent-benchmark --production --surfaces piagent,codex-cli --model openai-codex/gpt-5.6-sol --thinking xhigh">Lấy lệnh</button></header>
35
+ <pre><code>piagent-benchmark --production --dry-run
36
+ piagent-benchmark --production --surfaces piagent,codex-cli \
37
+ --model openai-codex/gpt-5.6-sol --thinking xhigh</code></pre>
38
+ </article>
39
+ <article class="command-card">
40
+ <header><span>Compare codex-cli</span><button class="clip-btn" data-clip="piagent-benchmark --surfaces piagent,codex-cli --model openai-codex/gpt-5.6-sol --thinking xhigh">Lấy lệnh</button></header>
41
+ <pre><code>piagent-benchmark --surfaces piagent,codex-cli \
42
+ --model openai-codex/gpt-5.6-sol --thinking xhigh</code></pre>
43
+ </article>
28
44
  <article class="command-card">
29
45
  <header><span>Trusted run</span><button class="clip-btn" data-clip="piagent-auto --full-access -p &quot;Run the trusted local benchmark suite.&quot;">Lấy lệnh</button></header>
30
46
  <pre><code>piagent-auto --read-only -p "Scout payment mapping. Do not edit source."
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -120,6 +120,22 @@ piagent-install --version vX.Y.Z --resolve-tag</code></pre>
120
120
  <header><span>Doctor</span><button class="clip-btn" data-clip="piagent-doctor /path/to/project">Lấy lệnh</button></header>
121
121
  <pre><code>piagent-doctor /path/to/project</code></pre>
122
122
  </article>
123
+ <article class="command-card">
124
+ <header><span>Smoke benchmark</span><button class="clip-btn" data-clip="piagent-benchmark --dry-run&#10;piagent-benchmark">Lấy lệnh</button></header>
125
+ <pre><code>piagent-benchmark --dry-run
126
+ piagent-benchmark</code></pre>
127
+ </article>
128
+ <article class="command-card">
129
+ <header><span>Production benchmark</span><button class="clip-btn" data-clip="piagent-benchmark --production --dry-run&#10;piagent-benchmark --production --surfaces piagent,codex-cli --model openai-codex/gpt-5.6-sol --thinking xhigh">Lấy lệnh</button></header>
130
+ <pre><code>piagent-benchmark --production --dry-run
131
+ piagent-benchmark --production --surfaces piagent,codex-cli \
132
+ --model openai-codex/gpt-5.6-sol --thinking xhigh</code></pre>
133
+ </article>
134
+ <article class="command-card">
135
+ <header><span>Compare codex-cli</span><button class="clip-btn" data-clip="piagent-benchmark --surfaces piagent,codex-cli --model openai-codex/gpt-5.6-sol --thinking xhigh">Lấy lệnh</button></header>
136
+ <pre><code>piagent-benchmark --surfaces piagent,codex-cli \
137
+ --model openai-codex/gpt-5.6-sol --thinking xhigh</code></pre>
138
+ </article>
123
139
  <article class="command-card">
124
140
  <header><span>Trusted run</span><button class="clip-btn" data-clip="piagent-auto --full-access -p &quot;Run the trusted local benchmark suite.&quot;">Lấy lệnh</button></header>
125
141
  <pre><code>piagent-auto --read-only -p "Scout payment mapping. Do not edit source."
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -27,7 +27,7 @@
27
27
  <span>Pi Agent Platform</span>
28
28
  </a>
29
29
  <div class="top-actions">
30
- <span class="pill"><span class="pill-dot"></span>v1.2.10 docs</span>
30
+ <span class="pill"><span class="pill-dot"></span>v1.2.12 docs</span>
31
31
  <a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
32
32
  <svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
33
33
  <path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
@@ -1,4 +1,10 @@
1
1
  {
2
+ "schemaVersion": 2,
3
+ "taskRunId": "task-0001-20260731120000-a1b2c3d4e5",
4
+ "changeMode": "source-change",
5
+ "attempt": 4,
6
+ "maxAttempts": 3,
7
+ "previousAttempts": [],
2
8
  "summary": "Replace with one-sentence task outcome.",
3
9
  "riskLane": "normal",
4
10
  "expectedOutput": "Replace with exact artifact or behavior expected.",
@@ -16,6 +22,7 @@
16
22
  "contextManifest": [],
17
23
  "memoryCitations": [],
18
24
  "mcpCapabilities": [],
25
+ "verifyGroup": "source",
19
26
  "verifyCommands": [
20
27
  "Replace with verify command."
21
28
  ],
@@ -65,9 +72,16 @@
65
72
  "watchdog": "Use a strong model only for final risk review, security, release, or high-impact changes."
66
73
  }
67
74
  },
75
+ "baselineChangedFiles": [],
76
+ "baselineFileDigests": {},
77
+ "observedChangedFiles": [],
78
+ "finalWorkingTreeFiles": [],
79
+ "finalFileDigests": {},
68
80
  "changedFiles": [],
69
81
  "verifyEvidence": [],
70
82
  "trace": {
71
83
  "outcome": "pending"
72
- }
84
+ },
85
+ "createdAt": "2026-07-31T12:00:00.000Z",
86
+ "updatedAt": "2026-07-31T12:00:00.000Z"
73
87
  }