@piagent/platform 1.8.0 → 1.9.1
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.
- package/AGENTS.md +7 -0
- package/CHANGELOG.md +132 -2
- package/README.md +45 -70
- package/README.vi.md +34 -61
- package/architecture/layers.json +16 -3
- package/catalog/capabilities.json +14 -7
- package/catalog/claude-model-additions.json +42 -0
- package/docs/auto-delegation-policy.md +2 -0
- package/docs/command-reference-vietnamese.md +68 -90
- package/docs/context-window-policy.md +5 -5
- package/docs/distribution-standard.md +13 -16
- package/docs/en/architecture.md +9 -1
- package/docs/herdr-workflow.md +2 -3
- package/docs/languages.json +4 -4
- package/docs/managed-local-acceptance.md +403 -0
- package/docs/mcp-and-tools.md +5 -7
- package/docs/memory-policy.md +3 -3
- package/docs/model-options.md +2 -2
- package/docs/oauth-providers.md +1 -1
- package/docs/operator-manual-vietnamese.md +82 -127
- package/docs/package-architecture-notes.md +4 -4
- package/docs/piagent-core-improvement-plan.md +3 -5
- package/docs/piagent-core-plan-checkpoint-2026-09-06.json +2 -13
- package/docs/piagent-runtime-benchmark-execution-plan.md +10 -8
- package/docs/project-adapters.md +3 -3
- package/docs/project-onboarding.md +15 -16
- package/docs/publishing-for-teams.md +3 -1
- package/docs/quality-benchmark.md +2 -0
- package/docs/quickstart-vietnamese.md +23 -24
- package/docs/release-install-policy.md +3 -2
- package/docs/research/harness-next-evidence-review.md +7 -7
- package/docs/runtime-harness-standard.md +2 -0
- package/docs/runtime-policy-design.md +2 -0
- package/docs/runtime-quality-baseline.md +2 -0
- package/docs/subagent-orchestration-capabilities.md +1 -1
- package/docs/subagents-and-multiagent.md +10 -8
- package/docs/task-implementation-contract.md +2 -0
- package/docs/task-lifecycle-vietnamese.md +2 -0
- package/docs/team-onboarding.md +28 -59
- package/docs/usage-observability.md +2 -2
- package/docs/vi/architecture.md +9 -1
- package/docs/workflow-recipes.md +6 -10
- package/docs-site/architecture.html +4 -3
- package/docs-site/assets/docs.css +80 -0
- package/docs-site/benchmark.html +7 -1
- package/docs-site/commands.html +37 -23
- package/docs-site/content/architecture.html +2 -2
- package/docs-site/content/benchmark.html +5 -0
- package/docs-site/content/commands.html +35 -22
- package/docs-site/content/ecosystem.html +144 -0
- package/docs-site/content/en/architecture.html +1 -1
- package/docs-site/content/en/benchmark.html +5 -0
- package/docs-site/content/en/commands.html +30 -13
- package/docs-site/content/en/ecosystem.html +144 -0
- package/docs-site/content/en/index.html +24 -9
- package/docs-site/content/en/quickstart.html +10 -12
- package/docs-site/content/en/security.html +1 -1
- package/docs-site/content/en/team.html +2 -2
- package/docs-site/content/en/whats-new.html +92 -1
- package/docs-site/content/en/workflows.html +29 -31
- package/docs-site/content/index.html +24 -9
- package/docs-site/content/quickstart.html +10 -12
- package/docs-site/content/security.html +2 -2
- package/docs-site/content/team.html +2 -2
- package/docs-site/content/whats-new.html +92 -1
- package/docs-site/content/workflows.html +36 -38
- package/docs-site/context-engine.html +2 -1
- package/docs-site/ecosystem.html +283 -0
- package/docs-site/en/architecture.html +3 -2
- package/docs-site/en/benchmark.html +7 -1
- package/docs-site/en/commands.html +32 -14
- package/docs-site/en/context-engine.html +2 -1
- package/docs-site/en/ecosystem.html +283 -0
- package/docs-site/en/index.html +30 -14
- package/docs-site/en/mcp-approval.html +2 -1
- package/docs-site/en/mcp-auth.html +2 -1
- package/docs-site/en/mcp-servers.html +2 -1
- package/docs-site/en/mcp.html +2 -1
- package/docs-site/en/permissions.html +2 -1
- package/docs-site/en/profiles.html +2 -1
- package/docs-site/en/quickstart.html +17 -18
- package/docs-site/en/runtime.html +2 -1
- package/docs-site/en/scope.html +2 -1
- package/docs-site/en/security.html +6 -5
- package/docs-site/en/team.html +4 -3
- package/docs-site/en/whats-new.html +100 -8
- package/docs-site/en/workflows.html +34 -35
- package/docs-site/index.html +30 -14
- package/docs-site/mcp-approval.html +2 -1
- package/docs-site/mcp-auth.html +2 -1
- package/docs-site/mcp-servers.html +2 -1
- package/docs-site/mcp.html +2 -1
- package/docs-site/permissions.html +2 -1
- package/docs-site/profiles.html +2 -1
- package/docs-site/quickstart.html +17 -18
- package/docs-site/runtime.html +2 -1
- package/docs-site/scope.html +2 -1
- package/docs-site/security.html +7 -6
- package/docs-site/team.html +4 -3
- package/docs-site/whats-new.html +100 -8
- package/docs-site/workflows.html +41 -42
- package/evals/fs5-causal-arm.v1.json +2 -2
- package/evals/private-holdout-v1/CURRENT_BOUNDARY.md +17 -0
- package/evals/private-holdout-v1/public-exposure.v2.json +2 -2
- package/package.json +8 -7
- package/packages/piagent-core/README.md +15 -23
- package/packages/piagent-core/docs/context-efficiency-improvement-plan.md +2 -0
- package/packages/piagent-core/extensions/experiment-loop-policy.ts +75 -0
- package/packages/piagent-core/extensions/local-state-path.js +15 -0
- package/packages/piagent-core/extensions/piagent-guard.ts +108 -960
- package/packages/piagent-core/extensions/policy-core.js +2 -2
- package/packages/piagent-core/extensions/source-checkout-paths.ts +54 -0
- package/packages/piagent-core/managed/broker-client.mjs +49 -0
- package/packages/piagent-core/managed/capabilities.mjs +28 -0
- package/packages/piagent-core/managed/client-agent.mjs +6 -0
- package/packages/piagent-core/managed/compaction.mjs +63 -0
- package/packages/piagent-core/managed/doctor.mjs +107 -0
- package/packages/piagent-core/managed/helper-roles.mjs +57 -0
- package/packages/piagent-core/managed/native-catalog.mjs +42 -0
- package/packages/piagent-core/managed/patch-snapshot.mjs +48 -0
- package/packages/piagent-core/managed/repository-operation.mjs +84 -0
- package/packages/piagent-core/managed/request-stream.mjs +130 -0
- package/packages/piagent-core/managed/resource-loader.mjs +42 -0
- package/packages/piagent-core/managed/review-snapshot-worker.mjs +27 -0
- package/packages/piagent-core/managed/sandbox-diagnostic.mjs +12 -0
- package/packages/piagent-core/managed/search-fallback.mjs +93 -0
- package/packages/piagent-core/managed/session.mjs +493 -0
- package/packages/piagent-core/managed/store.d.mts +3 -0
- package/packages/piagent-core/managed/store.mjs +64 -0
- package/packages/piagent-core/managed/tool-boundary.mjs +275 -0
- package/packages/piagent-core/managed/tool-worker.mjs +36 -0
- package/packages/piagent-core/managed/toolchain.mjs +120 -0
- package/packages/piagent-core/managed/web-fetch.mjs +105 -0
- package/packages/piagent-core/managed/web-search.mjs +131 -0
- package/packages/piagent-core/managed/workflow.mjs +326 -0
- package/packages/piagent-core/package.json +2 -5
- package/packages/piagent-core/policies/base-policy.json +80 -26
- package/packages/piagent-core/runtime/hooks/agent-start-hook.ts +3 -3
- package/packages/piagent-core/runtime/hooks/input-hook.ts +35 -196
- package/packages/piagent-core/runtime/hooks/session-start-hook.ts +2 -0
- package/packages/piagent-core/runtime/inspection/approval-broker.ts +9 -1
- package/packages/piagent-core/runtime/managed-failure.d.mts +10 -0
- package/packages/piagent-core/runtime/managed-failure.mjs +166 -0
- package/packages/piagent-core/runtime/orchestration/minimal-delegation-policy.ts +8 -29
- package/packages/piagent-core/runtime/orchestration/owned-work-budget.ts +1 -1
- package/packages/piagent-core/runtime/policy/block-remedy.ts +5 -3
- package/packages/piagent-core/runtime/registration/context-commands.ts +1 -1
- package/packages/piagent-core/runtime/registration/knowledge-tools.ts +7 -7
- package/packages/piagent-core/runtime/registration/policy-tools.ts +2 -2
- package/packages/piagent-core/runtime/registration/session-commands.ts +11 -26
- package/packages/piagent-core/runtime/registration/task-evidence-tools.ts +1 -1
- package/packages/piagent-core/runtime/session/system-prompt.ts +6 -7
- package/packages/piagent-core/runtime/workflows/webui-runtime-command.ts +6 -6
- package/packages/piagent-core/runtime/workflows/webui-workflow.ts +6 -11
- package/packages/piagent-core/security/sensitive-text.js +9 -0
- package/packages/piagent-core/skills/piagent-ops/SKILL.md +8 -10
- package/packages/piagent-core/skills/test-audit/SKILL.md +101 -0
- package/packages/piagent-core/subagents/piagent-planner.md +1 -1
- package/packages/piagent-webui/dist/client/assets/{MarkdownMessage-DMU7Xe_O.js → MarkdownMessage-BRPIMCRh.js} +1 -1
- package/packages/piagent-webui/dist/client/assets/index-DNJ1vH5d.js +228 -0
- package/packages/piagent-webui/dist/client/assets/{index-DVahUVWy.css → index-DgSmcnP8.css} +1 -1
- package/packages/piagent-webui/dist/client/index.html +2 -2
- package/packages/piagent-webui/extension/piagent-webui.ts +11 -11
- package/packages/piagent-webui/extension/session-stream-adapter.ts +3 -1
- package/packages/piagent-webui/extension/terminal-session-adapter.ts +6 -1
- package/packages/piagent-webui/gateway/company-relay.ts +308 -0
- package/packages/piagent-webui/gateway/control-socket.ts +39 -12
- package/packages/piagent-webui/gateway/gateway-service.ts +109 -28
- package/packages/piagent-webui/gateway/gateway-session-stream.ts +58 -2
- package/packages/piagent-webui/gateway/managed-gateway.mjs +41 -0
- package/packages/piagent-webui/gateway/managed-launch.ts +145 -0
- package/packages/piagent-webui/gateway/managed-projection.ts +20 -0
- package/packages/piagent-webui/gateway/pi-host.ts +22 -4
- package/packages/piagent-webui/gateway/runtime-session-controls.ts +5 -2
- package/packages/piagent-webui/gateway/session-approval-authority.ts +28 -0
- package/packages/piagent-webui/gateway/session-catalog.ts +11 -3
- package/packages/piagent-webui/gateway/session-command-controller.ts +8 -2
- package/packages/piagent-webui/gateway/session-file-facts.ts +25 -0
- package/packages/piagent-webui/gateway/session-inspection-registry.ts +40 -9
- package/packages/piagent-webui/gateway/session-list-cache.ts +68 -0
- package/packages/piagent-webui/gateway/session-runtime-ownership.ts +8 -1
- package/packages/piagent-webui/gateway/session-runtime-supervisor.ts +20 -27
- package/packages/piagent-webui/ownership/managed-terminal-lease.ts +27 -0
- package/packages/piagent-webui/ownership/profile-state.ts +2 -0
- package/packages/piagent-webui/ownership/session-lease-store.ts +22 -1
- package/packages/piagent-webui/server/approval-projection.ts +9 -0
- package/packages/piagent-webui/server/core-inspection-provider.ts +4 -9
- package/packages/piagent-webui/server/loopback-server.ts +37 -1
- package/packages/piagent-webui/server/message-stop-reason.ts +11 -0
- package/packages/piagent-webui/server/tool-call-summary.ts +185 -0
- package/packages/piagent-webui/server/transcript-projection.ts +86 -3
- package/packs/engineering-base/pack.json +4 -0
- package/schemas/piagent-webui/runtime-command-v1.schema.json +1 -2
- package/schemas/piagent-webui/session-catalog-v1.schema.json +8 -0
- package/schemas/piagent-webui/transcript-v1.schema.json +94 -1
- package/scripts/build-docs-site.mjs +23 -12
- package/scripts/check-public-wording.mjs +5 -6
- package/scripts/check-runtime-advisories.mjs +23 -6
- package/scripts/claude-model-additions.mjs +33 -0
- package/scripts/configure-model-scope.sh +30 -6
- package/scripts/configure-subagents.sh +1 -1
- package/scripts/explain-command.mjs +5 -6
- package/scripts/init-project.sh +0 -2
- package/scripts/install-global.sh +3 -2
- package/scripts/model-scope-prune.mjs +75 -0
- package/scripts/phase-tools-evaluation.mjs +9 -4
- package/scripts/piagent-cli.mjs +51 -2
- package/scripts/piagent-dashboard.mjs +27 -4
- package/scripts/piagent-installations.mjs +26 -0
- package/scripts/piagent-studio.mjs +155 -0
- package/scripts/runtime-advisory-exceptions.json +29 -0
- package/scripts/setup.sh +10 -6
- package/scripts/team-doctor.sh +20 -1
- package/scripts/typescript-loader.mjs +6 -0
- package/scripts/verify-local.sh +2 -2
- package/templates/global/settings.json +3 -1
- package/templates/project/.pi/project-context.md +3 -3
- package/templates/project/AGENTS.md +4 -5
- package/docs/piagent-core-reasoning-research-2026-09-06.md +0 -225
- package/docs/piagent-core-research-sources-2026-09-06.json +0 -416
- package/packages/piagent-webui/dist/client/assets/index-Cui9AAV_.js +0 -176
package/AGENTS.md
CHANGED
|
@@ -29,3 +29,10 @@ This repository builds reusable Pi agent infrastructure for multiple projects an
|
|
|
29
29
|
- Avoid hidden magic in prompts. If behavior must be enforced, put it in extension/tool-call guard.
|
|
30
30
|
- Source code and identifiers: English.
|
|
31
31
|
- Human-facing long-form docs may be Vietnamese; reusable workflow prompts and command names stay English.
|
|
32
|
+
|
|
33
|
+
## Checks
|
|
34
|
+
```
|
|
35
|
+
npm run typecheck
|
|
36
|
+
npm test
|
|
37
|
+
```
|
|
38
|
+
Run the test files that cover a change first (`node --test tests/<name>.test.mjs`); `npm test` runs everything.
|
package/CHANGELOG.md
CHANGED
|
@@ -2,7 +2,137 @@
|
|
|
2
2
|
|
|
3
3
|
This file records release-facing changes for Pi Agent Platform. Copy the relevant version block into GitHub Releases when publishing a tag.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## v1.9.1 - 2026-10-03
|
|
6
|
+
|
|
7
|
+
Two more company helpers (scout and verify) and web search for every company
|
|
8
|
+
role through the team's search pool. The company sandbox now runs type
|
|
9
|
+
checks, Vitest and end-to-end suites that it used to stop. The installer no
|
|
10
|
+
longer advertises commands 1.9.0 retired.
|
|
11
|
+
|
|
12
|
+
### Install
|
|
13
|
+
|
|
14
|
+
- `piagent-install` no longer ends its next steps with `/workflow task Implement <task>`, a command 1.9.0 retired; typed in Pi, it would have reached the model as a message and started a paid turn. Work is requested in plain language.
|
|
15
|
+
- `/subagents-doctor` is listed in those next steps only when the install includes pi-subagents, which provides it: `piagent-install` adds it only with `--with-subagents` or when it is already installed.
|
|
16
|
+
- `piagent-setup` lists `/mcp` and `/subagents-doctor` in its next steps only when that run installed them (not with `--no-mcp`, `--no-subagents` or `--project-only`), and no longer lists the retired `/onboard` and `/onboard run`; its daily flow says to ask in plain language instead of `/workflow task`. `piagent-init` no longer lists `/onboard` either. A test checks that no install script prints a command 1.9.0 retired.
|
|
17
|
+
|
|
18
|
+
### Managed team harness
|
|
19
|
+
|
|
20
|
+
- Two more helpers when the company Harness enables them, beside research and review. **Scout** reads the project only (no web, no commands) and answers with `file:line` facts. **Verify** checks a result on its own: it runs the repository's checks and confirms claims against the code and primary sources, then answers pass, fail or unverifiable for each claim, with evidence. Its commands run offline, and the project is read-only for them.
|
|
21
|
+
- A check that verify ran and passed counts toward the turn's process, the same as one the main agent ran.
|
|
22
|
+
- The main agent is offered only the helpers its Harness enables, and the prompt says when to use each one. With scout enabled, research is meant for questions that need the web. A call to a helper that the Harness lacks fails at once (`managed-helper-not-configured`).
|
|
23
|
+
- The dashboard counts running helpers against the number enabled, not against two.
|
|
24
|
+
- Every company request names the client to Studio as `piagent/<version>` (model requests and web search), so Studio's reports show Piagent and its version instead of an unknown tool.
|
|
25
|
+
- Company `web_search` asks Studio's search pool first, for every role: the team's search keys, then keyless providers. A Claude or Codex role falls back to its provider's own search tool when the pool is missing (an older Studio) or finds nothing. A role on an API-key vendor model (DeepSeek, MiMo and others), which has no search tool of its own, can now search. The pool request carries the run token and the role id, never a model or effort.
|
|
26
|
+
|
|
27
|
+
### Company sandbox
|
|
28
|
+
|
|
29
|
+
- `auth.json` is blocked only at the project root and in dot folders, where credentials live (Composer, `.codex`). A translation file such as `src/locales/en/auth.json` is readable, so type checks of i18n projects pass.
|
|
30
|
+
- Credential files (`.env*`, `credentials*`, `.npmrc`, `.netrc` and those `auth.json`) are hidden as well as unreadable. A tool that loads them when present (Vite, Vitest, Next) runs without them instead of failing with `EPERM`.
|
|
31
|
+
- Committed templates (`.env.example`, `.env.sample`, `.env.template`, `.env.dist`, `.env.defaults`) are ordinary files.
|
|
32
|
+
- In a folder that is not a git repository, a command that only reads (`ls`, `cat`, `grep`, `git status`…, with nothing written to a file) no longer counts as a code change, so a turn that only read files and ran checks no longer reports "code changed". A command that writes still counts.
|
|
33
|
+
- End-to-end tests run through `run_with_network`. An approved command may start a local server and drive Playwright's Chromium against it, using:
|
|
34
|
+
- listening on loopback;
|
|
35
|
+
- the member's Playwright browsers;
|
|
36
|
+
- Chromium's own rendezvous services.
|
|
37
|
+
|
|
38
|
+
Other system services, Keychain among them, stay closed. The sandbox cannot tell loopback from all interfaces, so the approval card says that a server the command starts accepts connections while it runs.
|
|
39
|
+
- A command's own timeout, up to 30 minutes, now extends the 10-minute limit, so a build followed by an end-to-end suite fits.
|
|
40
|
+
|
|
41
|
+
## v1.9.0 - 2026-10-02
|
|
42
|
+
|
|
43
|
+
Freeform sessions and the managed team harness. This release retires the task
|
|
44
|
+
contract and the workflow commands; work is requested in plain language and the
|
|
45
|
+
guard checks every tool call.
|
|
46
|
+
|
|
47
|
+
### Freeform sessions
|
|
48
|
+
|
|
49
|
+
- Retired the task contract: a session no longer creates a contract, declared scope, work plan, acceptance receipt, completion gate or recovery handoff, and no write waits for one. Task records written by earlier releases under `.pi/piagent-state/tasks` stay readable as history.
|
|
50
|
+
- Retired `/workflow`, `/fresh` (and `/fresh-*`), `/onboard`, `/onboard-project`, `/commands`, `/piagent-commands`, `/model-options`, `/profiles`, `/profile-tech` and the prompt-template aliases (`/task`, `/scout`, `/be-to-fe`, `/plan`, `/discuss`, `/review`, `/commit`, `/pr`, `/platform-improve`). Pi no longer loads `packages/piagent-core/prompts`. Project onboarding is a plain request recorded with `piagent_project_onboarding_record`.
|
|
51
|
+
- Retired the task-bound tools `piagent_task_start`, `piagent_task_progress`, `piagent_task_gate_check`, `piagent_context_record`, `piagent_verify_record`, `piagent_trace_record` and `piagent_memory_citation_record`; a tool group never re-activates them. `piagent_document_read` and `piagent_source_checkout` remain.
|
|
52
|
+
- The input hook passes text through unchanged: pasted checklists are no longer collapsed and long prompts are not stored in a task inbox.
|
|
53
|
+
- Delegation allows up to two fresh read-only helpers; token-saving estimates are telemetry, not an admission gate (bounded-delegation-v2).
|
|
54
|
+
- Kept for freeform turns: protected and read-only paths, permission profiles, the context budget for large files, confirmation for destructive and external-provider actions, and the stale read-to-edit check, which was keyed to the task run and now uses the session.
|
|
55
|
+
|
|
56
|
+
### Managed team harness
|
|
57
|
+
|
|
58
|
+
- Added the managed harness for company sessions imported by Agent Watch (`piagent studio`, `--web`): Studio chooses the main, research and review routes; tools run in a sandboxed worker with per-run authority.
|
|
59
|
+
- Per-turn process from the team's Harness in Studio: plan, checks and review, each `suggest` or `require`, with bounded fix loops. A plan guard refuses edits (including shell edits) until a plan exists and reports `planSkipped` after three refused answers; invented tool names are counted.
|
|
60
|
+
- Process report v2 (`plan_skipped`, `unknown_tools`) is negotiated: Studio lists `process_versions`, Agent Watch advertises `process-v2`.
|
|
61
|
+
- Detached processes are stopped at turn end; stopping during a helper reports `aborted`/`managed-helper-cancelled` instead of a send failure.
|
|
62
|
+
|
|
63
|
+
### Security and fixes
|
|
64
|
+
|
|
65
|
+
- The runtime dependency audit accepts three denial-of-service advisories in `brace-expansion` 5.0.9 (GHSA-q2hr-2g5m-vwhr, GHSA-qhr7-859c-m2p7, GHSA-6j4f-fj2g-mc7p) until 2026-10-31: every published Pi host, 1.0.0 included, pins that version through its npm-shrinkwrap, so no Piagent change can update it. The exceptions live in `scripts/runtime-advisory-exceptions.json`, apply only at the Pi host's own copy, print on every audit and end on their own; any other finding still blocks.
|
|
66
|
+
- Redacted Agent Studio credentials (`as_live_`, `as_device_`, `as_run_`). Write/edit previews and runtime command output are redacted before they are split or truncated, the gateway stream no longer flushes half a credential on a long line, and the client live file label recognises Studio tokens.
|
|
67
|
+
- A shell command can no longer create a new file in a shared source-checkout cache by spelling the path through an alias such as `/var` for `/private/var`.
|
|
68
|
+
- WebUI approvals: an allowed decision is now consumed by the guard, so the decision request receives its receipt and the approval leaves the queue. Before, every decision without a task stayed pending and could fill the broker.
|
|
69
|
+
- Removed the WebUI runtime actions that still sent `/commands` and `/onboard ...`; with those commands gone they would have reached the model as a message and started a paid turn. A test now ties every WebUI runtime action to a registered command.
|
|
70
|
+
- `piagent-explain` no longer lists task-contract, task-scope or lifecycle gates.
|
|
71
|
+
- The sandbox allows signals within the same sandbox, which fixes `grep` EPERM, timeouts and orphaned cancelled commands.
|
|
72
|
+
- The dashboard relay no longer freezes when `project.paths` exceeds the default control response limit.
|
|
73
|
+
|
|
74
|
+
### Dashboard and company mode, from live runs
|
|
75
|
+
|
|
76
|
+
- A company turn now settles once, after its harness rounds (the check request, the review, the fixes). Before, the dashboard treated the turn as finished at the first answer: Stop disappeared, the later rounds were not streamed, and for a moment the turn read "no answer yet, press Continue".
|
|
77
|
+
- `run_with_network` works: the network sandbox now allows the system resolver socket, so an approved command can resolve host names. Before, every approved network command failed with `ENOTFOUND`. When an approved command still cannot reach the network, the agent is told the network is unreachable instead of being pointed back to `run_with_network`.
|
|
78
|
+
- The header and the Workspace panel show a review subagent while it runs ("Subagent 1/2"); its start and end now refresh the conversation.
|
|
79
|
+
- A company conversation opened while company mode is not running (after a restart, a crash or an update) says so and offers Reconnect in place. Reading still never starts company mode, since starting may ask for Keychain access.
|
|
80
|
+
- A conversation whose history cannot be read no longer shows the previous conversation's messages under its title.
|
|
81
|
+
- Approval cards: the network approval shows the exact command; task, tool-call and provider references are gone; paths inside the project are shown relative to it (the project folder reads "The whole project folder"); known reasons and consequences are shown in Vietnamese. The exec-policy reason now reads "Confirmation required: the command runs git push" instead of naming a "legacy policy pattern".
|
|
82
|
+
- An `apply_patch` step is shown as an edit of its files with the patch's diff, like `edit`, in the history and while it runs.
|
|
83
|
+
|
|
84
|
+
### Many members at once, from a 20-developer run
|
|
85
|
+
|
|
86
|
+
- A company request that Studio refuses because every company model account that can serve the conversation is busy (`session_account_busy_retry_later`, `session_account_not_ready_retry_later`, `concurrency_limit`, `account_capacity_unavailable`, `request_rate_limit`) now waits in line and is asked again, for up to 20 minutes. These refusals come before any model is asked, so nothing is sent twice; a failure after admission is still never replayed. The wait is a step of the running turn in the dashboard ("Wait for a free company account") and the working line in the Terminal; Stop ends it. Before, the turn failed after Studio's 30-second wait.
|
|
87
|
+
- Dashboard commands are outdated only when their own conversation changed. Before, any change to any conversation made every other command stale, so with several conversations running a new conversation could fail with `session-revision-stale`. A failure to create a conversation is now shown as a sentence instead of a code. Stop no longer fails while the agent works through quick steps: a running turn changes its conversation after every step, so Stop is bound to the operation it names, not to the page's last read; if Stop still fails, the dashboard says so instead of doing nothing.
|
|
88
|
+
- A company request refused before the model did any work because the account's sign-in was being renewed (`upstream_auth_required`, `execution_precondition_failed`) is asked again up to three times, 3, 6 and 9 s apart; an account that really has to sign in again still says so.
|
|
89
|
+
- Opening a company conversation, starting a run and granting a subagent ask Studio again when it is too busy to answer in time (`serverUnavailable`), as does a request Studio could not check in time (`operation_unavailable`). Under load, most company conversations opened from the dashboard used to fail to open, and most required reviews ended as "review could not run". A review that still cannot run keeps its reason as a code in the conversation file.
|
|
90
|
+
- The dashboard stays fast with many conversations: listing them read every session file in full on every catalog (863 conversations: about 4 s each time, far more under load, so pages waited 30–40 s and timed out). Unchanged files now keep what was read before and only changed ones are read again, by Pi itself (44 ms instead of about 4 s).
|
|
91
|
+
- A member's session can read the skills Pi lists for it where they are installed (the package's and the user's); the guard used to refuse that read as "outside the project". Writes there stay refused.
|
|
92
|
+
- A new conversation whose creation takes longer than the dashboard's 30-second answer (the first one after the Gateway starts, a company runtime opening) is no longer reported as "could not be created" while it is created and runs: the page sends the same command again, which waits behind the create and returns its receipt, for up to two minutes; if it still has no answer it says the conversation may exist. Before, a member who believed the message was lost sent it again and two runs edited the same project.
|
|
93
|
+
- A dashboard message that stays unconfirmed is released after two minutes: its command now expires then, so it can no longer run, and the draft is kept to send again. Before, the composer stayed locked until the page was reloaded.
|
|
94
|
+
- Company sessions recover after the Mac sleeps: a run grant that lapsed under a request (Studio's clock catches up at once after a sleep, and grants last two minutes) is renewed and the request asked again, and an Agent Watch helper killed by a request that outlived the sleep is replaced when the next turn starts. Before, every company conversation failed with `invalid_run_grant` or "the Agent Watch helper stopped" until it was reopened.
|
|
95
|
+
- A request the model's provider declines under its usage policy (seen when a member asked to print an `.env` file encoded in base64) is reported as such, with its own dashboard copy ("ask in a different way"), instead of "the request could not be sent".
|
|
96
|
+
- An answer stream that ended with nothing in it ("stream ended without a stop reason") is reported as "the model returned no response" (`upstream_incomplete`) instead of "the request could not be sent"; it is not sent again, and "tiếp tục" continues. A company failure no code names keeps its own words, redacted, in the conversation file (not shown) so it can be told apart later.
|
|
97
|
+
- Two project folders with the same name (two clones of one repository) show where each one is in the new-conversation menu.
|
|
98
|
+
- A message sent right after Stop reaches the conversation on a busy machine. Every catalog the dashboard built opened and parsed every conversation file to learn its model and thinking level (929 files, 140 MB: about a second of blocked Gateway each time, 1–6 s under load); a Stop then took up to 50 s and the next messages stayed unconfirmed with the composer locked for minutes. A file's facts are now kept until its size, modification time or inode changes: catalogs take 0.1–0.5 s under the same load, and a stop-then-send probe that failed 3 of 4 times passes.
|
|
99
|
+
- A Gateway that is busy is no longer replaced by a second one. `piagent dashboard open` and the company launch took a Gateway that did not answer within 1.5 s for gone and started another; the new one took over the control socket while the first kept running unreachable, serving its pages and holding its conversations (three were found running at once). A Gateway that answers late is waited for (up to 30 s), only a socket nobody listens on is replaced, and an old Gateway that exits no longer removes the running one's socket.
|
|
100
|
+
- `piagent-doctor` lists `enabledModels` patterns that match no model Pi knows (Pi warns about each on every start), and `piagent-model-scope --prune` removes only those; patterns of a provider that is only signed out are kept.
|
|
101
|
+
- Public text names no other agent product or project; the wording check enforces it across docs, the docs site and the core package.
|
|
102
|
+
|
|
103
|
+
### Experiment loops and test audits
|
|
104
|
+
|
|
105
|
+
- The guard covers experiment-loop tools that an optional Pi package can add. `run_experiment` runs its command through `bash -c` itself, so the guard checks that command like `bash` (protected paths, the exec policy, confirmations, read-only profiles). `log_experiment` commits every change when an idea is kept and erases every uncommitted change otherwise, outside the guard, so `init_experiment` and `log_experiment` run only on an `experiment/` branch or a linked worktree, and `init_experiment` only with nothing uncommitted outside `.auto/`. A loop config that moves the commands to another folder is refused. The dashboard shows an experiment run as the command it runs.
|
|
106
|
+
- New packaged skill `test-audit` (`/skill:test-audit`, also chosen by the model when it writes or changes tests): decide whether a new test earns its place, and find tests that cost more than they protect, with a read-only review table before any edit.
|
|
107
|
+
|
|
108
|
+
### Guard cleanup
|
|
109
|
+
|
|
110
|
+
- Removed the guard code that only ran with a task contract: the completion hook, task change and verification recording, the task-bound branches of tool authorization (read-only task rules, opaque-shell rule, semantic repair, phase decisions, performance review), and the phase-tool, semantic-repair and independent-acceptance runtimes it created. The guard went from 4993 to 4139 lines; protected and read-only paths, permission profiles, the context budget, the stale-edit check and confirmations are unchanged.
|
|
111
|
+
- Reopening a session that ran a task before 1.9.0 no longer resumes, re-binds or warns about that task; its records stay as history.
|
|
112
|
+
|
|
113
|
+
### Models
|
|
114
|
+
|
|
115
|
+
- Added reviewed Sonnet 5.5 metadata to explicit Claude/full model-scope setup on Pi 0.87.1: native 1M context, 128K output, adaptive thinking, no unsupported off/minimal modes or temperature override. Existing custom endpoints and model entries are preserved. This does not establish account entitlement.
|
|
116
|
+
- Included Sonnet 5.5 and Opus 5.5 in model selection presets. Agent Watch can supply the same model through a Studio key without changing personal authentication.
|
|
117
|
+
|
|
118
|
+
### Tests and evidence
|
|
119
|
+
|
|
120
|
+
- Retired the test suites that only exercised the task contract (task lifecycle, acceptance gating, workflow dispatch and the scripted production journeys that asserted task records); they remain at commit 85f76db. Security assertions that used a task as setup were rewritten to run without one, and the reconnect, lost-receipt and single-turn HTTP/WebSocket journeys now run as freeform turns.
|
|
121
|
+
- The historical P3 phase-tool counterfactual reports `counterfactual-baseline-retired` instead of a ratio, because its baseline tools no longer exist.
|
|
122
|
+
- Benchmark and journey results published for earlier releases were measured with task contracts and are historical.
|
|
123
|
+
- Live verification on the installed release: 9 personal dashboard scenarios and 4 company scenarios (plan, checks and review; Stop during the review; a network install after approval; a message sent during a turn) pass; 27/27 browser tests.
|
|
124
|
+
- A busy test fixture that ignores SIGTERM now exits when its test runner is killed, instead of spinning a CPU core.
|
|
125
|
+
- Docs site: an Ecosystem page (Piagent, Agent Watch, Agent Studio), a 1.9.0 What's new with dashboard screenshots, and pages that still described the task contract updated. The screenshots are served by the site and not shipped in the npm package.
|
|
126
|
+
|
|
127
|
+
### Install and update
|
|
128
|
+
|
|
129
|
+
```sh
|
|
130
|
+
npm install -g --ignore-scripts @earendil-works/pi-coding-agent@0.87.1
|
|
131
|
+
npm install -g --ignore-scripts @piagent/platform@1.9.0
|
|
132
|
+
piagent-install --stable
|
|
133
|
+
piagent-doctor --offline
|
|
134
|
+
```
|
|
135
|
+
|
|
6
136
|
|
|
7
137
|
## v1.8.0 - 2026-09-23
|
|
8
138
|
|
|
@@ -696,7 +826,7 @@ Four documents restated something the code already knew, and each had drifted. T
|
|
|
696
826
|
and fail-closed shadow/recommend/auto modes. `piagent-route` provides the only
|
|
697
827
|
explicit prelaunch enforcement path; extension auto does not mutate the Pi
|
|
698
828
|
user default or switch models mid-conversation.
|
|
699
|
-
- Added a bounded
|
|
829
|
+
- Added a bounded retrieval route (read-only grep/find/read, up
|
|
700
830
|
to eight parallel searches and four rounds, recommendation-only), a 240-case
|
|
701
831
|
offline routing gate, and a resume-locked 144-session static-versus-adaptive
|
|
702
832
|
protocol dry-run. No authenticated benchmark is implied by these local gates.
|
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
[Tiếng Việt](README.vi.md)
|
|
4
4
|
|
|
5
|
-
Reusable Pi package for
|
|
5
|
+
Reusable Pi package for freeform coding chat, guarded tools, project context and a managed main/research/review harness.
|
|
6
6
|
|
|
7
7
|
Public docs: [piagent.io.vn](https://piagent.io.vn)
|
|
8
8
|
|
|
@@ -46,13 +46,11 @@ cd /path/to/project
|
|
|
46
46
|
pi
|
|
47
47
|
```
|
|
48
48
|
|
|
49
|
-
|
|
49
|
+
Send the request directly in plain language. Since 1.9.0 there is no `/task` or `/workflow` step, no task contract and no projected token-saving threshold.
|
|
50
50
|
|
|
51
|
-
|
|
51
|
+
For the local macOS team harness, import a managed key through Agent Watch and run `piagent studio` or `piagent studio --web`. Studio chooses the main/research/review routes; the member chooses thinking. Managed sessions have isolated tools and per-run authority. Personal sessions keep their own OAuth and model picker under `pi`.
|
|
52
52
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
`/commands` lists everything else. For trusted local runs, `piagent-auto` wraps `pi --approve` and sets a permission profile for that run — it does not bypass protected-path checks, destructive shell checks, task gates, or verification evidence. See the [command reference](docs/command-reference-vietnamese.md).
|
|
53
|
+
See [local acceptance and remaining release gates](docs/managed-local-acceptance.md). Existing direct CLI keys remain compatible and do not gain managed harness enforcement.
|
|
56
54
|
|
|
57
55
|
## Uninstall
|
|
58
56
|
|
|
@@ -69,12 +67,11 @@ Removal targets what is registered in Pi's settings rather than what the current
|
|
|
69
67
|
|
|
70
68
|
## What it provides
|
|
71
69
|
|
|
72
|
-
- Global Pi package with
|
|
73
|
-
-
|
|
74
|
-
-
|
|
75
|
-
- Runtime onboarding via `/onboard`; `/onboard run` launches the first-read onboarding workflow.
|
|
70
|
+
- Global Pi package with runtime commands, skills, guard extensions, and piagent subagents.
|
|
71
|
+
- Freeform turns: a request in plain language is the whole interface. Scouting, planning, review, commits and pull requests are ordinary requests.
|
|
72
|
+
- Project onboarding on request: ask the agent to inspect the project read-only and record its context, and it writes `.pi/project-context.md`.
|
|
76
73
|
- Runtime profile selection via `/profile`, plus select-style tech stack setup via `/profile setup` and `/profile tech`.
|
|
77
|
-
- Runtime usage
|
|
74
|
+
- Runtime usage controls via `/usage`, plus Pi native `/name`, `/new` and `/session`.
|
|
78
75
|
- Explicit project memory via `/memory` or `/memory-policy` and `piagent_memory_*` tools.
|
|
79
76
|
- Local Context Engine controls via `/context`: incremental code index, hybrid search, token-budgeted packs, bounded current-turn source/test snapshots for automatic tasks, test impact, efficiency telemetry, and semantic compaction. Index storage is owner-only and securely purged when exclusion policy changes; manual packs remain advisory, while current-turn snapshots are freshness-checked and exact edits fail closed on a later mismatch.
|
|
80
77
|
- MCP setup helpers for Context7, Chrome DevTools, GitHub, Playwright, and Figma.
|
|
@@ -87,17 +84,14 @@ Removal targets what is registered in Pi's settings rather than what the current
|
|
|
87
84
|
- `piagent_exec_policy_check`
|
|
88
85
|
- `piagent_context_budget`
|
|
89
86
|
- `piagent_tool_policy_check`
|
|
90
|
-
- `piagent_task_gate_check`
|
|
91
87
|
- `piagent_usage_snapshot`
|
|
92
88
|
- `piagent_context_preflight`
|
|
93
89
|
- `piagent_orchestration_policy`
|
|
94
90
|
- Context7-ready tech stack manifest and concise `.pi/tech-context/*` snapshots for selected profile roles.
|
|
95
|
-
- Accident-brake guardrails for protected paths, destructive shell commands,
|
|
96
|
-
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
immutable terminal outcome. These are same-runtime operational records, not
|
|
100
|
-
independent attestation.
|
|
91
|
+
- Accident-brake guardrails for protected and read-only paths, destructive shell commands, external-provider actions, large-file edits, and edits made against a stale read.
|
|
92
|
+
- Task contracts and workflow commands were retired in 1.9.0: a session no longer
|
|
93
|
+
creates a contract, scope, acceptance receipt or final gate. Task records left
|
|
94
|
+
under `.pi/piagent-state/tasks` by earlier releases stay readable as history.
|
|
101
95
|
- Adaptive context planning uses Pi-reported model/thinking/context facts to set
|
|
102
96
|
a bounded context budget; cited repository-memory hints never replace current
|
|
103
97
|
source reads. The parent model stays operator-pinned—there is no automatic
|
|
@@ -119,8 +113,8 @@ Removal targets what is registered in Pi's settings rather than what the current
|
|
|
119
113
|
transactional-config, and exact temporal-billing invariants. It locks
|
|
120
114
|
Piagent/`codex-cli` to Luna/medium and uses three repeats (42 paired sessions) with token, duration,
|
|
121
115
|
full-suite, and zero-retry gates. A separate provider-free WebUI
|
|
122
|
-
parity gate proves the
|
|
123
|
-
|
|
116
|
+
parity gate proves the 31 runtime-control paths before any model quota is
|
|
117
|
+
used (workflow ingress was retired in 1.9.0).
|
|
124
118
|
- The public `v1.6.0` production-v1 run
|
|
125
119
|
`production-v1-20260824T040017Z-05b7cf`, on exact commit
|
|
126
120
|
`3bba8f0b3ff521bc2a355e1f6bef6d1bbdc09511` with GPT-5.6 Luna Medium,
|
|
@@ -142,7 +136,7 @@ Project profiles can declare a runtime `permissionProfile`:
|
|
|
142
136
|
| Profile | Use when | Guard behavior |
|
|
143
137
|
|---|---|---|
|
|
144
138
|
| `read-only` | Scout, audit, review | Allows `read`, `grep`, `find`, `ls`, and piagent state tools; blocks shell, `write`/`edit`/`apply_patch`, and unknown tools. |
|
|
145
|
-
| `workspace-write` | Normal implementation | Default profile. Keeps
|
|
139
|
+
| `workspace-write` | Normal implementation | Default profile. Keeps protected-path, read-only-path, shell and capability checks, and asks before destructive or external actions. |
|
|
146
140
|
| `trusted-full-access` | Trusted local automation | Expands workspace tool/scope autonomy, but still enforces protected paths, secret redaction, capability lock integrity, and destructive/external confirmation. |
|
|
147
141
|
|
|
148
142
|
For one run, set `PIAGENT_PERMISSION_PROFILE=read-only|workspace-write|trusted-full-access`, or use `piagent-auto --read-only`, `--workspace-write`, or `--full-access`.
|
|
@@ -162,7 +156,7 @@ Legacy aliases still work: `/permission-status`, `/read-only`, `/workspace-write
|
|
|
162
156
|
|
|
163
157
|
## Parent-direct orchestration
|
|
164
158
|
|
|
165
|
-
The parent model owns reasoning, implementation, and verification.
|
|
159
|
+
The parent model owns reasoning, implementation, and verification. When helpers are enabled it may delegate up to two fresh read-only helpers, such as an independent research question or a review of its patch. Token-saving estimates are telemetry, not an admission requirement. Helpers never implement, inherit parent history, spawn nested helpers, or retry a deterministic failure.
|
|
166
160
|
|
|
167
161
|
Inside Pi:
|
|
168
162
|
|
|
@@ -170,27 +164,14 @@ Inside Pi:
|
|
|
170
164
|
/piagent-orchestration
|
|
171
165
|
```
|
|
172
166
|
|
|
173
|
-
This shows the active mode,
|
|
174
|
-
|
|
175
|
-
For bounded source work, runtime creates the session-bound contract before the
|
|
176
|
-
model starts and injects its path scope plus concise verifier. Broad, high-risk,
|
|
177
|
-
or ambiguous work falls back to one explicit `piagent_task_start`. A source task
|
|
178
|
-
requires a Git working tree and a meaningful project verifier. Direct and shell
|
|
179
|
-
writes are constrained to declared scope; final completion needs every planned
|
|
180
|
-
verify command and changed-file evidence. Read-only scouts do not need a source
|
|
181
|
-
verifier and must leave the working tree unchanged.
|
|
182
|
-
|
|
183
|
-
The installed v1.8.0 policy treats incomplete acceptance proof as diagnostic:
|
|
184
|
-
unproved criteria remain pending and completion carries no quality claim. Task
|
|
185
|
-
contract, scope, current passing verification, and trace still gate completion.
|
|
186
|
-
Select `acceptanceProofMode: "enforce"` in a reviewed package policy when every
|
|
187
|
-
criterion must be proved before completion.
|
|
167
|
+
This shows the active mode, helper ceiling, review lenses, Field Guide path, writer policy, and dispatch/skip evidence without triggering a model follow-up.
|
|
188
168
|
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
169
|
+
Source work is freeform: the model reads, edits and runs the project's checks
|
|
170
|
+
directly, with no contract, declared scope or final gate. The guard still
|
|
171
|
+
enforces protected and read-only paths, the permission profile, the context
|
|
172
|
+
budget for large files and stale read-to-edit snapshots, and asks before
|
|
173
|
+
destructive or external actions. In the managed company harness the plan,
|
|
174
|
+
check and review steps per turn are set by the team's Harness in Studio.
|
|
194
175
|
|
|
195
176
|
## Profiles
|
|
196
177
|
|
|
@@ -228,28 +209,24 @@ Commands and lock format: [Capability packs](docs/capability-packs.md).
|
|
|
228
209
|
|
|
229
210
|
## Main workflows
|
|
230
211
|
|
|
231
|
-
|
|
212
|
+
Work is requested in plain language; the commands below are settings and read-only views typed inside a Pi session, and none of them starts a model turn. [Command reference](docs/command-reference-vietnamese.md) explains each one.
|
|
232
213
|
|
|
233
214
|
| Command | Use when |
|
|
234
215
|
|---|---|
|
|
235
|
-
| `/
|
|
236
|
-
| `/
|
|
237
|
-
| `/
|
|
238
|
-
| `/
|
|
239
|
-
| `/
|
|
240
|
-
| `/
|
|
241
|
-
| `/
|
|
242
|
-
| `/
|
|
243
|
-
| `/workflow be-to-fe <request>` | Backend or spec is read-only and the implementation target is frontend. Pair with `/profile be-readonly-fe`. |
|
|
244
|
-
| `/workflow platform-improve <request>` | Package-level work: setup, MCP, model scope, memory, runtime policy, prompts, skills, subagents. |
|
|
245
|
-
| `/fresh <workflow> <request>` | The current session is already heavy. Opens a new governed session for any canonical workflow (`/fresh help` lists them) and replays the compact workflow prompt. |
|
|
246
|
-
| `/piagent-inspector` | Open one read-only menu for task files and line diff, commands and failures, safety warnings, and context budget. A four-row panel is always shown beside Pi's native footer and can be hidden for the session with `toggle`. |
|
|
216
|
+
| `/profile` | Show or apply the project profile; `/profile setup` selects the tech for each role. |
|
|
217
|
+
| `/permission` | Show or switch the session permission profile. |
|
|
218
|
+
| `/context` | Context Engine index, search, packs, test impact and compaction. |
|
|
219
|
+
| `/usage` | Session, model, thinking and context usage; `/usage logs` shows compacted tool output. |
|
|
220
|
+
| `/memory` | Explicit project memory. |
|
|
221
|
+
| `/piagent-mcp` | MCP servers, scopes and approvals. |
|
|
222
|
+
| `/piagent-status` | Profile, guard, runtime and authenticated model state. |
|
|
223
|
+
| `/piagent-inspector` | One read-only menu for the session diff, commands and failures, safety warnings, and context budget. A four-row panel is always shown beside Pi's native footer and can be hidden for the session with `toggle`. |
|
|
247
224
|
|
|
248
|
-
|
|
225
|
+
The workflow commands (`/workflow`, `/task`, `/scout`, `/fresh`, `/onboard`, `/commands`, `/model-options`) were retired in 1.9.0. Say what you want instead — "scout the payment flow read-only, do not edit", "review the current diff", "commit these two files". For a heavy session, start a new one with Pi's `/new`.
|
|
249
226
|
|
|
250
|
-
Git stays a capability rather than a `/git-*` namespace, so natural language works
|
|
227
|
+
Git stays a capability rather than a `/git-*` namespace, so natural language works. `git push`, GitHub writes and publishing ask for confirmation first. Broad staging — `git add .`, `git add -A`, `git add --all`, `git add -- .`, `git add :/` — requires confirmation, so unrelated or private files are not swept into a commit silently.
|
|
251
228
|
|
|
252
|
-
Paste a screenshot path straight into a task and the guard attaches it as `[image1]` before the model sees the prompt: `.png`, `.jpg`, `.jpeg`, `.gif`, `.webp`, `.bmp`, up to 4 images at 8 MB each. The target must be inside the project or a directory listed in `additionalReadRoots`; protected paths, paths outside the resolved filesystem read scope, symlink escapes, and extension-only fake images are refused.
|
|
229
|
+
Paste a screenshot path straight into a task and the guard attaches it as `[image1]` before the model sees the prompt: `.png`, `.jpg`, `.jpeg`, `.gif`, `.webp`, `.bmp`, up to 4 images at 8 MB each. The target must be inside the project or a directory listed in `additionalReadRoots`; protected paths, paths outside the resolved filesystem read scope, symlink escapes, and extension-only fake images are refused. Pasted text reaches the model as typed; there is no checklist to paste.
|
|
253
230
|
|
|
254
231
|
Web research and image understanding remain separate capabilities. The pinned `pi-web-access` integration uses the authenticated `openai-codex` route first when it is available and keeps its automatic search fallback; it never copies provider credentials into project or browser state. Images are passed as native image input to the selected session model rather than through a Piagent-owned OCR service. The dashboard reports both effective facts under **Settings → Providers & models**: `Codex Web Search` when that route is ready, and `Codex Vision` only when the current Codex model advertises image input.
|
|
255
232
|
|
|
@@ -259,7 +236,7 @@ A spec that lives outside the project — the one just downloaded to `~/Download
|
|
|
259
236
|
|
|
260
237
|
## Model selection
|
|
261
238
|
|
|
262
|
-
Handled by Pi's native UI: `/model` or `Ctrl+L` to pick, `Ctrl+P` to cycle the scoped set, `Shift+Tab` to cycle thinking level where the model supports it.
|
|
239
|
+
Handled by Pi's native UI: `/model` or `Ctrl+L` to pick, `Ctrl+P` to cycle the scoped set, `Shift+Tab` to cycle thinking level where the model supports it. Global setup seeds `enabledModels`; see [Model options](docs/model-options.md) to inspect or re-apply it.
|
|
263
240
|
|
|
264
241
|
## MCP setup
|
|
265
242
|
|
|
@@ -277,9 +254,9 @@ Keep provider keys in environment variables, never in committed config. Switchin
|
|
|
277
254
|
|
|
278
255
|
## Subagents
|
|
279
256
|
|
|
280
|
-
`piagent-setup` installs the optional `pi-subagents` compatibility runtime with a clamped `safe` preset. Daily tasks stay parent-direct; builtin agents and workers are disabled, and
|
|
257
|
+
`piagent-setup` installs the optional `pi-subagents` compatibility runtime with a clamped `safe` preset. Daily tasks stay parent-direct; builtin agents and workers are disabled, and helper mode allows up to two read-only helpers. The inspector states dispatch/skip reasons.
|
|
281
258
|
|
|
282
|
-
`/subagents-doctor` runs a health check. See [Subagents and multi-agent](docs/subagents-and-multiagent.md) for the
|
|
259
|
+
`/subagents-doctor` runs a health check. See [Subagents and multi-agent](docs/subagents-and-multiagent.md) for the read-only helper opt-in contract.
|
|
283
260
|
|
|
284
261
|
## Repository layout
|
|
285
262
|
|
|
@@ -292,7 +269,7 @@ piagent/
|
|
|
292
269
|
├─ evals/ governed evaluation scenarios
|
|
293
270
|
├─ packs/ versioned capability manifests and recipes
|
|
294
271
|
├─ packages/
|
|
295
|
-
│ ├─ piagent-core/ Pi package: extensions, runtime,
|
|
272
|
+
│ ├─ piagent-core/ Pi package: extensions, runtime, skills, managed harness
|
|
296
273
|
│ └─ piagent-webui/ dashboard: contracts, client, server, gateway, ownership
|
|
297
274
|
├─ schemas/ JSON schemas
|
|
298
275
|
├─ scripts/ setup, doctor, verification helpers
|
|
@@ -356,8 +333,8 @@ This repository intentionally excludes:
|
|
|
356
333
|
- [Subagent orchestration capabilities](docs/subagent-orchestration-capabilities.md)
|
|
357
334
|
- [Context-window policy](docs/context-window-policy.md)
|
|
358
335
|
- [Memory policy](docs/memory-policy.md)
|
|
359
|
-
- [Task lifecycle tiếng Việt](docs/task-lifecycle-vietnamese.md)
|
|
360
|
-
- [Task implementation contract](docs/task-implementation-contract.md)
|
|
336
|
+
- [Task lifecycle tiếng Việt](docs/task-lifecycle-vietnamese.md) (historical, before 1.9.0)
|
|
337
|
+
- [Task implementation contract](docs/task-implementation-contract.md) (historical, before 1.9.0)
|
|
361
338
|
- [Runtime quality baseline](docs/runtime-quality-baseline.md)
|
|
362
339
|
- [Usage observability](docs/usage-observability.md)
|
|
363
340
|
- [Model options](docs/model-options.md)
|
|
@@ -369,7 +346,7 @@ This repository intentionally excludes:
|
|
|
369
346
|
|
|
370
347
|
## Maturity
|
|
371
348
|
|
|
372
|
-
The current package version is read from package metadata and release tags. Personal machines may follow the unpinned package source when accepting ongoing updates; production/team quickstarts and committed project settings should pin an explicit tag such as `v1.
|
|
349
|
+
The current package version is read from package metadata and release tags. Personal machines may follow the unpinned package source when accepting ongoing updates; production/team quickstarts and committed project settings should pin an explicit tag such as `v1.9.1` or a reviewed commit.
|
|
373
350
|
|
|
374
351
|
Ready for:
|
|
375
352
|
|
|
@@ -379,7 +356,7 @@ Ready for:
|
|
|
379
356
|
- read-only scouting and planning;
|
|
380
357
|
- backend-readonly/frontend-write workflows;
|
|
381
358
|
- bounded subagent scouting, planning, implementation, and review;
|
|
382
|
-
- runtime checks for exec policy, context budget, context preflight, tool policy,
|
|
359
|
+
- runtime checks for exec policy, context budget, context preflight, tool policy, and usage snapshot;
|
|
383
360
|
- project-level quality/token/cost benchmarking.
|
|
384
361
|
|
|
385
362
|
Application-level policy layer:
|
|
@@ -394,11 +371,9 @@ Application-level policy layer:
|
|
|
394
371
|
- The ambiguous `source` field remains metadata for configured external providers and piagent tools, but is treated as a filesystem path for file-oriented tools and unknown/local tools; protected-path and read-scope checks then apply before execution.
|
|
395
372
|
- Broad `grep`, `find`, and `ls` sweeps get result-filter backstops: protected file content lines or protected path metadata are redacted before the model sees output. Text tool results and JSON-like result details also pass through shared sensitive-data redaction; image, audio, and resource payloads are left intact.
|
|
396
373
|
- The redaction release gate is a synthetic/internal benchmark for contextual recall, benign preservation, structured fields, and bounded large output. The public security threat model maps current assumptions, attack vectors, controls, and residual risks; it is not an independent audit. Stronger assurance still requires a broader OS/shell matrix, more parser fuzzing, continued symlink/path-traversal testing, third-party review, and an LTS/backport policy. Opaque entropy without a credential-bearing context and transformed output such as base64-encoded content remain outside the redaction guarantee.
|
|
397
|
-
- Raw `bash` access to protected paths is blocked through shell operand extraction. The guard covers partial shell globs, bare filenames, canonical symbolic-link aliases, and attached input/output redirections. `.pi/piagent-state/**` and `.pi/piagent-profile.json` are self-protected; use `piagent_context` and piagent
|
|
374
|
+
- Raw `bash` access to protected paths is blocked through shell operand extraction. The guard covers partial shell globs, bare filenames, canonical symbolic-link aliases, and attached input/output redirections. `.pi/piagent-state/**` and `.pi/piagent-profile.json` are self-protected; use `piagent_context` and the piagent tools instead.
|
|
398
375
|
- External writes launched through guarded shell tools are confirmation-gated as well as direct provider tools. This includes GitHub CLI write actions and non-read-only `curl`/`wget` forms, including common execution wrappers; known read/list/GET forms remain non-interactive.
|
|
399
|
-
-
|
|
400
|
-
- Observed command identity is retained as a SHA-256 hash while sensitive command text is redacted at both the in-memory and persisted evidence boundaries.
|
|
401
|
-
- Passing final gates require an observed exit `0` command that exactly matches one of the task/profile `verifyCommands`; ad-hoc commands such as `true`, `echo ok`, or `npm test || true` are advisory only.
|
|
376
|
+
- Observed bash results are persisted under `.pi/piagent-state/observed-bash.jsonl`, so parent agents can check results produced by guarded subagent processes. Command identity is kept as a SHA-256 hash while sensitive command text is redacted at both the in-memory and persisted boundaries.
|
|
402
377
|
- Project memory files are private-by-default in generated projects; opt in to shared memory only after review/redaction.
|
|
403
378
|
- It is not an OS sandbox or complete security boundary. It depends on the controlled tool paths and shell parsing that the platform observes, and it cannot stop another process with the same OS permissions from reading or writing outside the guard. For untrusted code, untrusted prompts, or adversarial workloads, run Pi inside an isolated container/VM with filesystem, process, network, and credential boundaries.
|
|
404
379
|
- Release verification audits the small helper dependency tree separately from the exact Pi host and pinned optional add-ons at the high-severity gate. Upstream lower-severity findings are still reported and tracked; a green helper-only audit is not treated as proof that the deployed runtime tree is clean.
|
package/README.vi.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
[English](README.md)
|
|
4
4
|
|
|
5
|
-
Pi Agent Platform
|
|
5
|
+
Pi Agent Platform cung cấp chat trực tiếp, công cụ có kiểm soát quyền, ngữ cảnh dự án và khung main/research/review cho tài khoản công ty.
|
|
6
6
|
|
|
7
7
|
Tài liệu public: [piagent.io.vn](https://piagent.io.vn)
|
|
8
8
|
|
|
@@ -22,50 +22,17 @@ cd /path/to/project
|
|
|
22
22
|
pi
|
|
23
23
|
```
|
|
24
24
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
##
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
- Project-specific business logic nằm trong project profile hoặc adapter, không đưa vào core.
|
|
37
|
-
|
|
38
|
-
Task Contract v2 hiện gắn task/session/run identity với current-tree verification,
|
|
39
|
-
acceptance receipt giữ nguyên tiêu chí chưa được chứng minh, hash-chained journal checkpoint, retry có giới hạn và
|
|
40
|
-
terminal outcome bất biến. Đây là operational record do cùng runtime tạo ra,
|
|
41
|
-
không phải independent attestation.
|
|
42
|
-
|
|
43
|
-
Policy cài sẵn của v1.8.0 dùng chế độ diagnostic cho acceptance proof: tiêu chí
|
|
44
|
-
chưa được chứng minh vẫn ở trạng thái pending và khi hoàn tất sẽ ghi rõ không có
|
|
45
|
-
khẳng định chất lượng. Task contract, scope, bước verify đang pass và trace vẫn
|
|
46
|
-
chặn hoàn tất nếu thiếu. Khi cần chứng minh mọi tiêu chí trước khi hoàn tất,
|
|
47
|
-
chọn `acceptanceProofMode: "enforce"` trong package policy đã được review.
|
|
48
|
-
|
|
49
|
-
Adaptive Context Planner dùng model, thinking và context usage do Pi báo để đặt
|
|
50
|
-
budget có giới hạn; repository-memory hint luôn có citation và không thay thế
|
|
51
|
-
việc đọc source hiện tại. Parent model vẫn do operator pin: baseline ổn định này
|
|
52
|
-
chưa ship solver hoặc automatic parent routing. Host execution là mặc định; nếu
|
|
53
|
-
yêu cầu isolation backend chưa có adapter, mutation bị block thay vì âm thầm
|
|
54
|
-
fallback về host.
|
|
55
|
-
|
|
56
|
-
## Điều phối parent-direct
|
|
57
|
-
|
|
58
|
-
Parent model tự sở hữu suy luận, implementation và verification. Helper mặc định
|
|
59
|
-
tắt. Khi operator chủ động bật, runtime chỉ được dispatch tối đa một helper
|
|
60
|
-
read-only dùng context fresh nếu chứng minh có hai lane độc lập và tổng token dự
|
|
61
|
-
kiến sau handoff/merge giảm ít nhất 30%. Worker, retry, nested helper và parallel
|
|
62
|
-
helper đều bị tắt.
|
|
63
|
-
|
|
64
|
-
Trong Pi, `/piagent-orchestration` hiển thị mode hiện tại, trần một helper,
|
|
65
|
-
review lens, writer policy và bằng chứng dispatch/skip mà không tạo model turn.
|
|
66
|
-
`piagent-setup` chỉ cài `pi-subagents` như runtime tương thích tùy chọn với preset
|
|
67
|
-
`safe` đã bị clamp; `/subagents-doctor` dùng để kiểm tra health. Chi tiết nằm tại
|
|
68
|
-
[Subagents và multi-agent](docs/subagents-and-multiagent.md).
|
|
25
|
+
Nhập yêu cầu bằng lời thường trong Pi hoặc WebUI. Từ bản 1.9.0 không còn bước `/task` hay `/workflow`, không còn task contract và không còn ngưỡng tiết kiệm token.
|
|
26
|
+
|
|
27
|
+
## Agent Watch Auto trên macOS
|
|
28
|
+
|
|
29
|
+
Admin cấu hình model cho main, khảo sát và review trong Studio. Thành viên nhập URL/key ở Watch, chọn Piagent rồi Import. Mở **Piagent công ty** từ Watch hoặc chạy `piagent studio`; thêm `--web` để mở dashboard. Người dùng chọn mức suy luận; context theo model thực tế. Phiên cá nhân tiếp tục dùng `pi` và chọn model/OAuth riêng.
|
|
30
|
+
|
|
31
|
+
Key công ty cần loại **Piagent công ty**. Key CLI trực tiếp cũ giữ nguyên; Studio có nút tạo key đi kèm dùng chung hạn mức. Không đổi tài khoản công ty sang cá nhân trong cùng hội thoại.
|
|
32
|
+
|
|
33
|
+
Main có tối đa hai trợ lý chỉ đọc; không sinh nhánh con tiếp. Review gắn với bản chụp patch và báo hết hiệu lực khi code đổi. UI hiển thị token từng trợ lý. Bản macOS managed dùng công cụ cách ly và quyền ngắn hạn theo lượt; chế độ cá nhân vẫn là thực thi trên host.
|
|
34
|
+
|
|
35
|
+
Bản local này chưa phải bản phát hành có Developer ID. [Trạng thái nghiệm thu](docs/managed-local-acceptance.md) phân biệt test nội bộ, gọi provider thật và phần còn thiếu.
|
|
69
36
|
|
|
70
37
|
## Web search và vision
|
|
71
38
|
|
|
@@ -87,27 +54,36 @@ trực tiếp vẫn nằm trong workspace của project thay vì bị nhét vào
|
|
|
87
54
|
tiếp tục áp protected path, redaction, session binding và attachment ref dùng một
|
|
88
55
|
lần.
|
|
89
56
|
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
57
|
+
Màn hình New chat gửi đúng nội dung người dùng nhập; WebUI không còn bộ chọn
|
|
58
|
+
workflow. Trong **Cài đặt → Điều khiển project**, operator có thể xem
|
|
59
|
+
runtime/usage, profile, Context Engine, memory và MCP governance mà không cần nhớ
|
|
60
|
+
slash command. WebUI gửi đúng command vào Pi runtime; thao tác read-only được
|
|
61
|
+
kiểm tra là 0 model token, còn thao tác ghi hoặc semantic compact bắt buộc xác
|
|
62
|
+
nhận rõ ràng. Muốn onboard project, hãy nhờ agent trong chat đọc project (chỉ
|
|
63
|
+
đọc) và ghi lại context.
|
|
97
64
|
|
|
98
65
|
## Command chính
|
|
99
66
|
|
|
67
|
+
Công việc được yêu cầu bằng lời thường; các command dưới đây là thiết lập và màn
|
|
68
|
+
hình chỉ đọc, không command nào mở lượt model.
|
|
69
|
+
|
|
100
70
|
| Command | Mục đích |
|
|
101
71
|
|---|---|
|
|
102
|
-
| `/
|
|
103
|
-
| `/profile` | Xem hoặc đổi project profile |
|
|
72
|
+
| `/profile` | Xem hoặc đổi project profile; `/profile setup` chọn tech cho từng vai trò |
|
|
104
73
|
| `/permission` | Đổi permission mode trong session |
|
|
105
74
|
| `/context` | Xem Context Engine, index, retrieval và telemetry |
|
|
106
75
|
| `/usage` | Xem session, model, thinking và context usage |
|
|
107
76
|
| `/piagent-inspector` | Mở menu read-only để xem task diff, command fail/block, safety warning và context budget; panel bốn dòng tự hiện sát footer native, `toggle` để ẩn trong session |
|
|
108
77
|
| Pi native `/name` | Đặt tên session; Piagent nhận rename event để map Agent Watch/report |
|
|
109
78
|
| `/memory` | Xem hoặc cập nhật explicit project memory |
|
|
110
|
-
| `/
|
|
79
|
+
| `/piagent-mcp` | Xem và quản lý MCP server, scope và phê duyệt |
|
|
80
|
+
| `/piagent-status` | Xem profile, guard, runtime và trạng thái model đã xác thực |
|
|
81
|
+
|
|
82
|
+
Các command workflow (`/workflow`, `/task`, `/scout`, `/fresh`, `/onboard`,
|
|
83
|
+
`/commands`, `/model-options`) đã bỏ từ bản 1.9.0. Hãy nói điều mình cần, ví dụ
|
|
84
|
+
"scout luồng thanh toán, chỉ đọc, không sửa", "review diff hiện tại", "commit hai
|
|
85
|
+
file này". Session đã nặng thì mở session mới bằng `/new` của Pi. `git push`,
|
|
86
|
+
thao tác ghi lên GitHub và publish đều hỏi xác nhận trước.
|
|
111
87
|
|
|
112
88
|
## Architecture
|
|
113
89
|
|
|
@@ -115,7 +91,7 @@ Code được quản lý theo các layer:
|
|
|
115
91
|
|
|
116
92
|
1. Composition root đăng ký Pi extension.
|
|
117
93
|
2. Runtime adapter xử lý Pi hook, command, tool và session UI.
|
|
118
|
-
3. Core service xử lý policy,
|
|
94
|
+
3. Core service xử lý policy, context và state (bản ghi task cũ chỉ còn để đọc lịch sử).
|
|
119
95
|
4. Integration quản lý MCP, capability và security primitive.
|
|
120
96
|
5. CLI trong `scripts/` chỉ parse argument và gọi use case.
|
|
121
97
|
|
|
@@ -144,7 +120,7 @@ piagent/
|
|
|
144
120
|
├─ evals/ kịch bản đánh giá có governance
|
|
145
121
|
├─ packs/ capability manifest và recipe có version
|
|
146
122
|
├─ packages/
|
|
147
|
-
│ ├─ piagent-core/ Pi package: extension, runtime,
|
|
123
|
+
│ ├─ piagent-core/ Pi package: extension, runtime, skill, managed harness
|
|
148
124
|
│ └─ piagent-webui/ dashboard: contract, client, server, gateway, ownership
|
|
149
125
|
├─ schemas/ JSON schema
|
|
150
126
|
├─ scripts/ setup, doctor và helper kiểm tra
|
|
@@ -163,9 +139,6 @@ Adaptive model routing cho fresh task dùng `piagent-route --prompt "<task>" --j
|
|
|
163
139
|
Chỉ `--execute --yes` mới mở provider-backed Pi process; `/model`/CLI pin luôn
|
|
164
140
|
được giữ và extension không đổi model giữa conversation.
|
|
165
141
|
|
|
166
|
-
Khi session đã nặng, `/fresh <workflow> <request>` mở session mới cho bất kỳ
|
|
167
|
-
workflow canonical nào và replay prompt gọn; `/fresh help` liệt kê catalog hiện hành.
|
|
168
|
-
|
|
169
142
|
## Verification
|
|
170
143
|
|
|
171
144
|
```bash
|
|
@@ -202,7 +175,7 @@ Xem [bằng chứng benchmark](https://piagent.io.vn/benchmark) và
|
|
|
202
175
|
|
|
203
176
|
Gate này chạy architecture check, test, typecheck, capability validation, runtime smoke và docs consistency trước khi release.
|
|
204
177
|
|
|
205
|
-
Bản phát hành hiện tại là `v1.
|
|
178
|
+
Bản phát hành hiện tại là `v1.9.1`. Với team hoặc production, hãy pin tag này
|
|
206
179
|
hoặc một commit đã review thay vì dựa vào nguồn package không cố định.
|
|
207
180
|
|
|
208
181
|
## Security
|