@piagent/platform 1.1.8 → 1.2.0
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/CHANGELOG.md +51 -1
- package/README.md +2 -2
- package/docs/command-reference-vietnamese.md +13 -4
- package/docs/distribution-standard.md +7 -7
- package/docs/mcp-and-tools.md +108 -2
- package/docs/model-options.md +10 -8
- package/docs/operator-manual-vietnamese.md +12 -12
- package/docs/publishing-for-teams.md +2 -0
- package/docs/quickstart-vietnamese.md +2 -2
- package/docs/release-install-policy.md +6 -6
- package/docs/security-threat-model.md +1 -1
- package/docs/team-onboarding.md +4 -4
- package/docs/vercel-docs-site.md +34 -4
- package/docs-site/architecture.html +152 -0
- package/docs-site/assets/docs.css +1001 -0
- package/docs-site/assets/docs.js +84 -0
- package/docs-site/commands.html +203 -0
- package/docs-site/content/architecture.html +29 -0
- package/docs-site/content/commands.html +80 -0
- package/docs-site/content/index.html +80 -0
- package/docs-site/content/mcp-approval.html +81 -0
- package/docs-site/content/mcp-auth.html +76 -0
- package/docs-site/content/mcp-servers.html +111 -0
- package/docs-site/content/mcp.html +120 -0
- package/docs-site/content/permissions.html +54 -0
- package/docs-site/content/profiles.html +68 -0
- package/docs-site/content/quickstart.html +144 -0
- package/docs-site/content/runtime.html +45 -0
- package/docs-site/content/scope.html +71 -0
- package/docs-site/content/security.html +51 -0
- package/docs-site/content/team.html +23 -0
- package/docs-site/content/workflows.html +47 -0
- package/docs-site/index.html +131 -1534
- package/docs-site/mcp-approval.html +204 -0
- package/docs-site/mcp-auth.html +199 -0
- package/docs-site/mcp-servers.html +234 -0
- package/docs-site/mcp.html +243 -0
- package/docs-site/permissions.html +177 -0
- package/docs-site/profiles.html +191 -0
- package/docs-site/quickstart.html +267 -0
- package/docs-site/runtime.html +168 -0
- package/docs-site/scope.html +194 -0
- package/docs-site/security.html +174 -0
- package/docs-site/team.html +142 -0
- package/docs-site/workflows.html +170 -0
- package/package.json +4 -2
- package/packages/piagent-core/capabilities/capability-core.js +17 -1
- package/packages/piagent-core/extensions/document-intake.ts +5 -5
- package/packages/piagent-core/extensions/piagent-guard.ts +319 -4
- package/packages/piagent-core/extensions/update-check.js +41 -0
- package/packages/piagent-core/mcp/mcp-approval-store.js +175 -0
- package/packages/piagent-core/mcp/mcp-auth-readiness.js +197 -0
- package/packages/piagent-core/mcp/mcp-command-actions.js +291 -0
- package/packages/piagent-core/mcp/mcp-config-layers.js +133 -0
- package/packages/piagent-core/mcp/mcp-server-catalog.js +150 -0
- package/packages/piagent-core/mcp/mcp-server-entry.js +242 -0
- package/packages/piagent-core/mcp/mcp-session-view.js +185 -0
- package/packages/piagent-core/package.json +7 -3
- package/packages/piagent-core/prompts/model-options.md +8 -8
- package/scripts/build-docs-site.mjs +421 -0
- package/scripts/configure-model-scope.sh +2 -2
- package/scripts/configure-subagents.sh +1 -1
- package/scripts/install-global.sh +5 -5
- package/scripts/mcp-manage.mjs +567 -0
- package/scripts/piagent-cli.mjs +1 -1
- package/scripts/preview-docs-site.mjs +88 -0
- package/scripts/setup.sh +2 -2
- package/scripts/team-doctor.sh +18 -2
- package/scripts/verify-local.sh +46 -19
- package/scripts/verify-release-identity.mjs +8 -2
- package/scripts/configure-mcp.sh +0 -349
package/docs/vercel-docs-site.md
CHANGED
|
@@ -19,6 +19,30 @@ Lý do:
|
|
|
19
19
|
|
|
20
20
|
Tách repository chỉ nên dùng khi docs cần domain, quyền truy cập, hoặc lịch phát hành riêng.
|
|
21
21
|
|
|
22
|
+
## Cấu trúc site
|
|
23
|
+
|
|
24
|
+
Site là nhiều trang tĩnh, mỗi topic một trang, sinh ra từ một shell dùng chung:
|
|
25
|
+
|
|
26
|
+
```text
|
|
27
|
+
docs-site/
|
|
28
|
+
content/<slug>.html # nội dung riêng của từng trang, không có header/sidebar/footer
|
|
29
|
+
assets/docs.css # style dùng chung
|
|
30
|
+
assets/docs.js # sidebar filter, TOC, active-section, copy button
|
|
31
|
+
<slug>.html # output đã generate, được commit
|
|
32
|
+
vercel.json
|
|
33
|
+
scripts/build-docs-site.mjs
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Sidebar chia theo bốn nhóm — Get started, Build, MCP, Operate. Thứ tự nhóm và thứ tự trang nằm trong hằng `NAV` của `scripts/build-docs-site.mjs`; đó cũng là thứ tự của link prev/next ở cuối mỗi trang. Thêm một trang = thêm `docs-site/content/<slug>.html` + một entry trong `NAV`, rồi build lại.
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
npm run site:build
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Output HTML được commit, vì Vercel serve file tĩnh và không có build step. `npm run verify` chạy `build-docs-site.mjs --check`, fail khi output đã commit không còn khớp source — cùng cách `catalog/capabilities.json` đang dùng. Không sửa tay `docs-site/<slug>.html`; sửa fragment trong `content/` hoặc sửa shell trong script.
|
|
43
|
+
|
|
44
|
+
Version badge xuất hiện trên mọi trang, nên `npm run release:identity` kiểm tra tất cả `docs-site/*.html` chứ không riêng `index.html`.
|
|
45
|
+
|
|
22
46
|
## Production promotion policy
|
|
23
47
|
|
|
24
48
|
Production docs không được advertise một release tag chưa tồn tại.
|
|
@@ -96,16 +120,22 @@ curl -I https://www.piagent.io.vn/
|
|
|
96
120
|
curl -sSL https://piagent.io.vn/ | grep 'vX.Y.Z docs'
|
|
97
121
|
```
|
|
98
122
|
|
|
99
|
-
Xác nhận thêm favicon/logo, GitHub/Facebook links, install commands, sidebar anchors và mobile layout.
|
|
123
|
+
Xác nhận thêm favicon/logo, GitHub/Facebook links, install commands, sidebar anchors và mobile layout. Vì site giờ là nhiều trang, kiểm tra thêm clean URL và asset dùng chung:
|
|
124
|
+
|
|
125
|
+
```bash
|
|
126
|
+
curl -o /dev/null -s -w '%{http_code}\n' https://piagent.io.vn/mcp
|
|
127
|
+
curl -o /dev/null -s -w '%{http_code}\n' https://piagent.io.vn/assets/docs.css
|
|
128
|
+
```
|
|
100
129
|
|
|
101
130
|
## Local preview
|
|
102
131
|
|
|
103
132
|
```bash
|
|
104
|
-
|
|
105
|
-
python3 -m http.server 4173
|
|
133
|
+
npm run site:preview
|
|
106
134
|
```
|
|
107
135
|
|
|
108
|
-
Mở `http://localhost:4173`.
|
|
136
|
+
Mở `http://localhost:4321`. Đổi port bằng `npm run site:preview -- --port 4173`.
|
|
137
|
+
|
|
138
|
+
Dùng script này thay vì một static server bất kỳ: `vercel.json` bật `cleanUrls`, nên link nội bộ trỏ tới `/quickstart` chứ không phải `/quickstart.html`. `python3 -m http.server` trả 404 cho tất cả các link đó và preview thành vô dụng để kiểm tra navigation. Script bind loopback và resolve extensionless path đúng như production.
|
|
109
139
|
|
|
110
140
|
## Security notes
|
|
111
141
|
|
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="vi">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
|
+
<title>Kiến trúc repo · Pi Agent Platform Docs</title>
|
|
7
|
+
<meta name="description" content="Repo này không nhét business logic vào core. Core chỉ giữ policy, prompts, guard, skills và scripts dùng lại được." />
|
|
8
|
+
<meta name="theme-color" content="#050505" />
|
|
9
|
+
<link rel="canonical" href="https://piagent.io.vn/architecture" />
|
|
10
|
+
<link rel="icon" href="/favicon.svg" type="image/svg+xml" />
|
|
11
|
+
<meta property="og:title" content="Kiến trúc repo · Pi Agent Platform Docs" />
|
|
12
|
+
<meta property="og:description" content="Repo này không nhét business logic vào core. Core chỉ giữ policy, prompts, guard, skills và scripts dùng lại được." />
|
|
13
|
+
<meta property="og:url" content="https://piagent.io.vn/architecture" />
|
|
14
|
+
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
|
15
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
|
16
|
+
<link
|
|
17
|
+
href="https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap"
|
|
18
|
+
rel="stylesheet"
|
|
19
|
+
/>
|
|
20
|
+
<link rel="stylesheet" href="/assets/docs.css" />
|
|
21
|
+
<script src="/assets/docs.js" defer></script>
|
|
22
|
+
</head>
|
|
23
|
+
<body>
|
|
24
|
+
<header class="topbar">
|
|
25
|
+
<a class="brand" href="/" aria-label="Pi Agent Platform">
|
|
26
|
+
<span class="brand-mark"><img src="/assets/piagent-logo.svg" alt="" /></span>
|
|
27
|
+
<span>Pi Agent Platform</span>
|
|
28
|
+
</a>
|
|
29
|
+
<div class="top-actions">
|
|
30
|
+
<span class="pill"><span class="pill-dot"></span>v1.2.0 docs</span>
|
|
31
|
+
<a class="button social" href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer" aria-label="Mở GitHub repository">
|
|
32
|
+
<svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
|
|
33
|
+
<path d="M7 17 17 7M9 7h8v8" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
|
|
34
|
+
</svg>
|
|
35
|
+
GitHub
|
|
36
|
+
</a>
|
|
37
|
+
<button class="button mobile-menu" type="button" data-menu>Lộ trình</button>
|
|
38
|
+
<a class="button" href="/commands">Commands</a>
|
|
39
|
+
</div>
|
|
40
|
+
</header>
|
|
41
|
+
|
|
42
|
+
<div class="layout with-toc">
|
|
43
|
+
<aside class="sidebar" data-sidebar>
|
|
44
|
+
<div class="sidebar-search" aria-label="Tìm trong tài liệu">
|
|
45
|
+
<svg viewBox="0 0 24 24" fill="none" aria-hidden="true">
|
|
46
|
+
<path d="M10.8 18.1a7.3 7.3 0 1 1 0-14.6 7.3 7.3 0 0 1 0 14.6Zm5.3-1.7 4.4 4.4" stroke="currentColor" stroke-width="2" stroke-linecap="round" />
|
|
47
|
+
</svg>
|
|
48
|
+
<input type="search" placeholder="Tìm trang" data-filter />
|
|
49
|
+
</div>
|
|
50
|
+
|
|
51
|
+
<nav aria-label="Tài liệu">
|
|
52
|
+
<div class="nav-group">
|
|
53
|
+
<p class="nav-title">Get started</p>
|
|
54
|
+
<a class="nav-link" href="/">Overview</a>
|
|
55
|
+
<a class="nav-link" href="/quickstart">Quickstart</a>
|
|
56
|
+
<a class="nav-link" href="/scope">Phạm vi platform</a>
|
|
57
|
+
</div>
|
|
58
|
+
<div class="nav-group">
|
|
59
|
+
<p class="nav-title">Build</p>
|
|
60
|
+
<a class="nav-link" href="/profiles">Project profile</a>
|
|
61
|
+
<a class="nav-link" href="/permissions">Permission modes</a>
|
|
62
|
+
<a class="nav-link" href="/commands">Command catalog</a>
|
|
63
|
+
<a class="nav-link" href="/workflows">Workflows</a>
|
|
64
|
+
</div>
|
|
65
|
+
<div class="nav-group">
|
|
66
|
+
<p class="nav-title">MCP</p>
|
|
67
|
+
<a class="nav-link" href="/mcp">MCP overview</a>
|
|
68
|
+
<a class="nav-link" href="/mcp-servers">Quản lý server</a>
|
|
69
|
+
<a class="nav-link" href="/mcp-auth">Auth và readiness</a>
|
|
70
|
+
<a class="nav-link" href="/mcp-approval">Approval gate</a>
|
|
71
|
+
</div>
|
|
72
|
+
<div class="nav-group">
|
|
73
|
+
<p class="nav-title">Operate</p>
|
|
74
|
+
<a class="nav-link" href="/security">Security model</a>
|
|
75
|
+
<a class="nav-link current" href="/architecture" aria-current="page">Architecture</a>
|
|
76
|
+
<a class="nav-link" href="/runtime">Runtime tools</a>
|
|
77
|
+
<a class="nav-link" href="/team">Team usage</a>
|
|
78
|
+
</div>
|
|
79
|
+
</nav>
|
|
80
|
+
</aside>
|
|
81
|
+
|
|
82
|
+
<main>
|
|
83
|
+
<div class="content-shell" data-article>
|
|
84
|
+
<nav class="breadcrumb" aria-label="Breadcrumb">
|
|
85
|
+
<a href="/">Docs</a>
|
|
86
|
+
<span aria-hidden="true">/</span>
|
|
87
|
+
<span>Operate</span>
|
|
88
|
+
<span aria-hidden="true">/</span>
|
|
89
|
+
<span>Architecture</span>
|
|
90
|
+
</nav>
|
|
91
|
+
<div class="page-head">
|
|
92
|
+
<h1>Kiến trúc repo</h1>
|
|
93
|
+
<p>Repo này không nhét business logic vào core. Core chỉ giữ policy, prompts, guard, skills và scripts dùng lại được.</p>
|
|
94
|
+
</div>
|
|
95
|
+
<section class="section">
|
|
96
|
+
|
|
97
|
+
<div class="grid cols-3">
|
|
98
|
+
<article class="card">
|
|
99
|
+
<h3 id="core-package">Core package</h3>
|
|
100
|
+
<p><span class="inline-code">packages/piagent-core</span> chứa extension guard, prompts, skills và subagent roles.</p>
|
|
101
|
+
</article>
|
|
102
|
+
<article class="card">
|
|
103
|
+
<h3 id="adapters">Adapters</h3>
|
|
104
|
+
<p><span class="inline-code">adapters/</span> chứa profile dùng lại: frontend, backend, fullstack, data, devops, docs.</p>
|
|
105
|
+
</article>
|
|
106
|
+
<article class="card">
|
|
107
|
+
<h3 id="capability-packs">Capability packs</h3>
|
|
108
|
+
<p><span class="inline-code">packs/</span> gom policy, lifecycle, recipes và eval scenarios theo manifest có lock.</p>
|
|
109
|
+
</article>
|
|
110
|
+
<article class="card">
|
|
111
|
+
<h3 id="policies">Policies</h3>
|
|
112
|
+
<p>Base policy định nghĩa protected paths, command rules, permission modes và human-action gates.</p>
|
|
113
|
+
</article>
|
|
114
|
+
<article class="card">
|
|
115
|
+
<h3 id="scripts">Scripts</h3>
|
|
116
|
+
<p>Setup, doctor, model scope, MCP, subagents, benchmark và trusted-run wrapper đều có CLI riêng.</p>
|
|
117
|
+
</article>
|
|
118
|
+
<article class="card">
|
|
119
|
+
<h3 id="docs">Docs</h3>
|
|
120
|
+
<p><span class="inline-code">docs/</span> giữ manual dài. <span class="inline-code">docs-site/</span> là trang HTML gọn cho team.</p>
|
|
121
|
+
</article>
|
|
122
|
+
</div>
|
|
123
|
+
</section>
|
|
124
|
+
<nav class="pager" aria-label="Trang kế tiếp">
|
|
125
|
+
<a class="pager-prev" href="/security">
|
|
126
|
+
<span class="pager-label">Trước</span>
|
|
127
|
+
<span class="pager-title">Security model</span>
|
|
128
|
+
</a>
|
|
129
|
+
<a class="pager-next" href="/runtime">
|
|
130
|
+
<span class="pager-label">Tiếp</span>
|
|
131
|
+
<span class="pager-title">Runtime tools</span>
|
|
132
|
+
</a>
|
|
133
|
+
</nav>
|
|
134
|
+
|
|
135
|
+
<footer class="footer">
|
|
136
|
+
<p>Pi Agent Platform docs · static HTML · governed agent workflow</p>
|
|
137
|
+
<div class="footer-links" aria-label="External links">
|
|
138
|
+
<a href="https://piagent.io.vn" target="_blank" rel="noopener noreferrer">piagent.io.vn</a>
|
|
139
|
+
<a href="https://github.com/Vt-mmm/piagent" target="_blank" rel="noopener noreferrer">GitHub repository</a>
|
|
140
|
+
<a href="https://www.facebook.com/vinhtam0544/" target="_blank" rel="noopener noreferrer">Facebook profile</a>
|
|
141
|
+
</div>
|
|
142
|
+
</footer>
|
|
143
|
+
</div>
|
|
144
|
+
</main>
|
|
145
|
+
|
|
146
|
+
<aside class="toc" aria-label="Mục lục trang">
|
|
147
|
+
<p class="toc-title">Trên trang này</p>
|
|
148
|
+
<nav data-toc></nav>
|
|
149
|
+
</aside>
|
|
150
|
+
</div>
|
|
151
|
+
</body>
|
|
152
|
+
</html>
|