sisyo 1.9.0 → 1.12.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.
@@ -0,0 +1,33 @@
1
+ Quy trình chung cho **mọi dự án** của công ty. Mỗi dự án có một trang trong 🏦 Projects; anh đọc được trên mọi máy và điện thoại. Tài liệu kỹ thuật chi tiết cho agent vẫn ở `docs/` trong repo.
2
+
3
+ ## Anh cần đọc gì
4
+
5
+ - **Trang sprint** (🏃 Sprint, xem theo timeline; các sprint hiện trong cây trang): mỗi sprint là một lần phát hành. Trang sprint ghi ngắn: đã làm gì, đã quyết gì, vài ảnh, test theo cụm, số đo, sprint sau làm gì.
6
+ - **Trang yêu cầu** (nằm trong sprint, tên `R6 · …`): khi agent cần anh quyết. Thẻ anh đã trả lời giữ nguyên, chỉ thêm trạng thái và link.
7
+ - **Trang kết quả** (nằm trong yêu cầu, tên `R6 · Kết quả 1`): mỗi vòng một trang: đã chốt, đã làm, câu hỏi tiếp theo (nếu có thì anh trả lời ngay trên trang đó).
8
+ - **📚 Tài liệu dự án**, 4 trang ngắn: 🧭 Kiến trúc hệ thống (luồng đi, vì sao chọn), 🗄️ Cơ sở dữ liệu (mỗi bảng một dòng), 🧪 Cụm chức năng & test (test từng cụm, số case đạt), 📈 Số đo & cải tiến (trước → sau).
9
+
10
+ Anh không cần theo dõi tiến độ từng việc của agent.
11
+
12
+ ## Vòng đời một yêu cầu
13
+
14
+ 1. **Gửi**: anh nhắn trong Claude Code, hoặc tự viết một trang trong 📥 Yêu cầu.
15
+ 2. **Xác nhận** 🟡: agent tự quyết gom thành một R hay không và đặt vào sprint nào. Trang R có các thẻ: hiện có gì, đề xuất, và chỉ những câu hỏi cần anh quyết (⭐ là phương án agent khuyên). Việc nhỏ (sửa một dòng, câu hỏi) thì làm luôn, ghi vào tổng kết sprint.
16
+ 3. **Duyệt**: anh trả lời trên trang hoặc ngay trong chat.
17
+ 4. **Triển khai** 🔨 → **kiểm thử** 🧪: agent mở trang `R6 · Kết quả 1` (đã chốt), sửa cụm nào test lại cụm đó.
18
+ 5. **Phát hành** ✅: chạy toàn bộ test trước khi lên production hoặc store, backup, deploy, điền trang kết quả (đã làm, câu hỏi tiếp theo), ghi 🚀 Phát hành, viết tổng kết sprint.
19
+
20
+ ## Ba chế độ
21
+
22
+ - **Duyệt trước** (mặc định): chờ anh duyệt rồi mới làm.
23
+ - **Duyệt nhanh**: mục không có câu hỏi thì làm luôn, mục có câu hỏi thì chờ. Anh nói "duyệt nhanh". Trang anh tự viết mặc định là chế độ này.
24
+ - **Làm luôn**: anh nói "làm luôn" hoặc "bận"; agent vẫn ghi lại các lựa chọn đã dùng.
25
+
26
+ ## Trả lời trên thẻ
27
+
28
+ - Chọn phương án là đồng ý; muốn khác thì ghi vào "Khác". Nút **Đồng ý / Đồng ý, có sửa / Để sau / Bỏ** và ô ghi chú khi cần.
29
+ - Cuối trang chọn cách duyệt (tất cả / chỉ mục đã đồng ý / duyệt nhanh), rồi nhắn agent.
30
+
31
+ ## Agent tự nhớ
32
+
33
+ Quyết định của anh được lưu vào bộ nhớ chung của các agent (cùng với doraemon); agent tra lại trước khi hỏi, nên không hỏi lại điều anh đã quyết.
@@ -0,0 +1,63 @@
1
+ {
2
+ "title": "Tên ngắn, tối đa 6 từ (trang sẽ là «R6 · tên»)",
3
+ "mode": "review",
4
+ "agent": "Claude Code (Opus 5.5) trên ubuntu1",
5
+ "intro": "",
6
+ "cards": [
7
+ {
8
+ "key": "A",
9
+ "title": "Tên mục, ngắn",
10
+ "size": "M",
11
+ "area": "Database",
12
+ "quote": "lời anh, trích ngắn",
13
+ "current": "Hiện có: đọc code rồi mới viết. Markdown: danh sách, bảng, `code`.",
14
+ "proposal": "- Đề xuất cụ thể: kích thước, phím tắt, giới hạn\n- Chỗ trong giao diện",
15
+ "questions": [
16
+ {
17
+ "id": "q1",
18
+ "text": "Câu hỏi khi thật sự cần anh quyết?",
19
+ "kind": "single",
20
+ "options": [
21
+ {
22
+ "id": "a",
23
+ "label": "Lựa chọn agent khuyên",
24
+ "description": "vì sao, 1 dòng",
25
+ "recommended": true
26
+ },
27
+ {
28
+ "id": "b",
29
+ "label": "Lựa chọn khác",
30
+ "description": "đánh đổi"
31
+ }
32
+ ]
33
+ },
34
+ {
35
+ "id": "q2",
36
+ "text": "Chọn nhiều thứ cùng lúc?",
37
+ "kind": "multi",
38
+ "options": [
39
+ {
40
+ "id": "x",
41
+ "label": "Thứ nhất",
42
+ "recommended": true
43
+ },
44
+ {
45
+ "id": "y",
46
+ "label": "Thứ hai"
47
+ }
48
+ ]
49
+ }
50
+ ]
51
+ },
52
+ {
53
+ "key": "B",
54
+ "title": "Ý của agent ngoài yêu cầu",
55
+ "size": "S",
56
+ "area": "Quy trình",
57
+ "extra": true,
58
+ "proposal": "Đề xuất thêm, ghi rõ lợi ích."
59
+ }
60
+ ],
61
+ "plan": "1. Việc nào trước\n2. Chia agent theo vùng code\n3. Test chung, kiểm tra trình duyệt, bằng chứng\n4. Backup, test gate, deploy, ghi Phát hành",
62
+ "raw": "Toàn bộ tin nhắn của anh, nguyên văn."
63
+ }
@@ -0,0 +1,57 @@
1
+ **Trạng thái:** {{STATUS}}
2
+
3
+ **Chế độ:** Duyệt trước · **Gửi:** {{DATE}} · **Agent:** <model> trên <máy>
4
+
5
+ **Cách duyệt:** mỗi mục có ô *Đồng ý* và dòng *Phản hồi*. Câu hỏi anh không tick thì làm theo đề xuất. Xong thì tick ở phần cuối trang và nhắn agent "đã duyệt {{REQ}}". Muốn gửi ảnh chụp thì dán thẳng vào trang.
6
+
7
+ ## Tóm tắt
8
+
9
+ | # | Hạng mục | Đề xuất ngắn | Độ lớn |
10
+ |---|---|---|---|
11
+ | A | … | … | S / M / L |
12
+
13
+ ## A. <Tên mục>
14
+
15
+ > "<lời anh, trích ngắn>"
16
+
17
+ **Hiện có:** <đọc code rồi mới viết>
18
+
19
+ **Đề xuất:**
20
+ - <cụ thể: kích thước, phím tắt, giới hạn, chỗ trong giao diện>
21
+
22
+ **Chọn:** <câu hỏi, chỉ khi thật sự cần anh quyết>
23
+ - [ ] A. <lựa chọn agent khuyên> (đề xuất)
24
+ - [ ] B. <lựa chọn khác>
25
+
26
+ **Độ lớn:** S / M / L
27
+
28
+ - [ ] Đồng ý
29
+
30
+ **Phản hồi:**
31
+
32
+ ## Đề xuất thêm
33
+
34
+ <ý của agent ngoài yêu cầu, ghi rõ là đề xuất thêm; mỗi ý có Đồng ý + Phản hồi như một mục>
35
+
36
+ ## Kế hoạch triển khai (sau khi duyệt)
37
+
38
+ 1. <thứ tự, việc nào trước>
39
+ 2. <chia agent theo vùng code>
40
+ 3. <test, kiểm tra trình duyệt, bằng chứng>
41
+ 4. <backup, test gate, deploy, ghi Phát hành>
42
+
43
+ ## Duyệt
44
+
45
+ - [ ] Duyệt tất cả theo đề xuất (câu hỏi không tick = theo đề xuất)
46
+ - [ ] Chỉ làm các mục đã tick Đồng ý; mục chưa tick để lại
47
+ - [ ] Duyệt nhanh: làm luôn mục đã tick, chờ anh ở mục có phản hồi
48
+
49
+ **Phản hồi chung:**
50
+
51
+ ## Báo cáo
52
+
53
+ _Agent điền khi triển khai: việc đã làm, ảnh và video bằng chứng, kết quả test, commit, deploy._
54
+
55
+ ## Nguyên văn yêu cầu
56
+
57
+ > <toàn bộ tin nhắn của anh>
@@ -1,22 +1,24 @@
1
1
  ---
2
2
  name: vibe-docs
3
- description: "Keep the agent docs in docs/ in sync with the code: English, as short as possible, split into folders and files with paths so an agent finds and fixes one fact quickly. Triggers on feature changes, DB schema, API endpoints, frontend pages, infra, testing, security, integrations, decisions, or any task completion. Also triggers on: project status, what is next, update docs, create a plan, log this, handoff. Core principle: read docs/MAP.md first and never load all docs at once. Human-facing docs (architecture overview, key numbers, sprint summaries) do not go here: they go to the project's hub (skill kicho-devflow)."
3
+ description: "Keep the agent docs in docs/ in sync with the code, so any agent (in a new session, another worktree or a parallel batch) can take the project over without missing anything: English, concise, split into folders and files with paths, 3-level routing. Triggers on feature changes, DB schema, API endpoints, frontend pages, infra, testing, security, integrations, decisions, or any task completion. Also triggers on: project status, what is next, update docs, create a plan, log this, handoff, worktree, parallel session, merge pass. Core principle: read docs/MAP.md first and never load all docs at once. Human-facing docs (architecture overview, key numbers, sprint summaries) do not go here: they go to the project's hub (skill kicho-devflow)."
4
4
  ---
5
5
 
6
6
  # Vibe Docs
7
7
 
8
- `docs/` is written **for agents**: English, as short as possible, and easy to find, load and fix
9
- (`.claude/rules/docs.md`). Docs for people are a separate set in the project's hub (skill `kicho-devflow`); never
10
- copy one set into the other.
8
+ `docs/` is written **for agents** (`.claude/rules/docs.md`). The test it must pass: an agent that knows nothing about
9
+ the project, working in a new session or in another worktree, can take the project over from `docs/` plus git without
10
+ missing anything. Docs for people are a separate set in the project's hub (skill `kicho-devflow`). Never copy one
11
+ set into the other.
11
12
 
12
13
  ## Writing rules
13
- - Facts, tables, lists, paths. No prose, no greetings, no story of how something was built.
14
- - Refer to code by path (`src/billing/invoice.ts`) and do not copy it. Write only what the code cannot say: why,
15
- contracts, constraints, gotchas, commands, env vars.
16
- - Describe what is true now. Replace outdated lines; do not append "update:" notes. Git keeps the history.
17
- - One topic per file, under about 100 lines. When a file grows longer, split it and route the parts through
18
- `_summary.md`.
19
- - Never write secrets, tokens, personal data or private hosts.
14
+ - English, concise, but complete: never drop a fact the next agent needs. Prefer facts, tables, lists and paths;
15
+ write prose only for a reason or a flow.
16
+ - Refer to code by path (`src/billing/invoice.ts`) instead of copying it. Write what the code cannot say: why,
17
+ contracts, constraints, gotchas, commands, env vars, where things run, what is unfinished.
18
+ - Describe the current state. Replace outdated lines instead of appending notes; git keeps the history.
19
+ - When you move, merge or shorten a doc, carry every still-true fact into its new place.
20
+ - One topic per file. Split a file when it grows past about 200 lines, and route the parts through `_summary.md`.
21
+ - Never write secrets, tokens or personal data.
20
22
 
21
23
  ## 3-level routing
22
24
  ```
@@ -24,27 +26,57 @@ Level 1 docs/MAP.md one line per folder or file, read ALWAYS (~500
24
26
  Level 2 <folder>/_summary.md one table row per item (~200 tokens)
25
27
  Level 3 <folder>/<item>.md detail, load ONLY to change or deeply understand that item
26
28
  ```
27
- Most tasks need Level 1 + 2. After a change, update bottom-up: detail → `_summary.md` → MAP.md.
29
+ Most tasks need only Level 1 and Level 2. Do not load detail files just to check something; the summary table is
30
+ enough for most decisions. After a change, update bottom-up: detail, then `_summary.md`, then MAP.md.
28
31
 
29
32
  ## Folders (created when there is content, never empty)
30
33
  ```
31
34
  docs/
32
35
  MAP.md
33
36
  00_schedule/ roadmap, milestones
34
- 01_requirements/ feature specs: scope, acceptance criteria
35
- 02_architecture/ components, flows, decisions.md (one row per decision)
36
- 03_database/ tables: columns, indexes, relations
37
+ 01_requirements/ feature specs
38
+ 02_architecture/ components, flows, decisions.md, gotchas
39
+ 03_database/ tables
37
40
  04_api/ endpoints grouped by module
38
41
  05_frontend/ routes, pages, state
39
- 06_infra/ deploy, Docker, CI/CD, env vars
42
+ 06_infra/ deploy, dev environment, Docker, CI/CD, env vars
40
43
  07_testing/ test groups, commands, edge cases
41
44
  08_security/ auth flows, roles, secrets handling
42
- 09_integrations/ third-party services: config, limits, webhooks
43
- 99_progress/ todo.md, handoff.md, features.md
45
+ 09_integrations/ third-party services
46
+ 99_progress/ todo.md, handoff.md, features.md, sessions/<branch>.md
44
47
  ```
45
48
 
49
+ ## When to update, and what the doc holds
50
+ | Done | Update | It holds |
51
+ |---|---|---|
52
+ | Timeline or milestone set | `00_schedule/roadmap.md` | phases, milestones, deadlines |
53
+ | Feature planned | `01_requirements/_summary.md` + `<feature>.md` | scope, user stories, acceptance criteria, what is out |
54
+ | Tech or architecture choice | `02_architecture/decisions.md` | one row: id, date, decision, why, options rejected |
55
+ | Trap found or limitation accepted | `02_architecture/gotchas.md` | symptom, cause, what to do instead |
56
+ | Tables or columns changed | `03_database/_summary.md` + `<table>.md` | columns, types, indexes, relations, migration notes |
57
+ | Endpoints changed | `04_api/_summary.md` + `<module>.md` | request, response, errors, auth, examples |
58
+ | Pages or routes changed | `05_frontend/_summary.md` + `<group>.md` | route, components, state, behaviour |
59
+ | Deploy, infra or env changed | `06_infra/<topic>.md` | hosts, paths, commands, env vars, how to roll back |
60
+ | Tests added or changed | `07_testing/<group>.md` | what each group covers, commands, edge cases |
61
+ | Auth, roles or keys changed | `08_security/<topic>.md` | flow, roles, permissions, where secrets live (never the values) |
62
+ | Third-party service added | `09_integrations/<service>.md` | config, SDK usage, webhooks, limits, costs |
63
+ | Feature done | `99_progress/features.md` | date, feature, status, link to its spec |
64
+ | Task done | `99_progress/todo.md` | doing, next, done with dates |
65
+ | Session ends or `/clear` | `99_progress/handoff.md` | main-line state (below) |
66
+ | Milestone or stop on a parallel branch | `99_progress/sessions/<branch>.md` | branch state (below) |
67
+
68
+ Each change on the main line also updates the folder's `_summary.md` (when it has one) and the MAP.md line. On a
69
+ parallel branch, leave those to the merge pass.
70
+
46
71
  ## _summary.md
47
- One table, one row per item, under 50 lines, with a link to the detail files:
72
+ One table with one row per item, under 50 lines, and a link to the detail files. Put related items in the same row.
73
+ Use columns that fit the folder:
74
+ - database: Table | Purpose | Relations;
75
+ - API: Method | Path | Description | Auth;
76
+ - frontend: Route | Page | Components | Description;
77
+ - requirements: Feature | Status | Scope.
78
+
79
+ Example:
48
80
  ```
49
81
  # Database Tables
50
82
  > Updated: 2026-03-03 | Tables: 3
@@ -59,8 +91,8 @@ Detail: `03_database/<table>.md`
59
91
  ```
60
92
 
61
93
  ## MAP.md
62
- One line per folder (its `_summary.md`) or single file, at most ~15 words with key nouns and counts, ending with
63
- the date:
94
+ One line per folder (pointing to its `_summary.md`) or per single file. Keep each line to about 15 words, with the key
95
+ nouns and counts, and end it with the date:
64
96
  ```
65
97
  # Project Map
66
98
  > Updated: 2026-03-03 | Docs: 9
@@ -69,71 +101,77 @@ the date:
69
101
  - `03_database/_summary.md` -- 3 tables: users, posts, comments (2026-03-03)
70
102
  ```
71
103
 
72
- ## When to update
73
- | Done | Update |
74
- |---|---|
75
- | Timeline or milestone set | `00_schedule/roadmap.md` |
76
- | Feature planned | `01_requirements/_summary.md` + `<feature>.md` |
77
- | Tech or architecture choice | `02_architecture/decisions.md`: id, date, decision, why, rejected |
78
- | Tables or columns changed | `03_database/_summary.md` + `<table>.md` |
79
- | Endpoints changed | `04_api/_summary.md` + `<module>.md` |
80
- | Pages or routes changed | `05_frontend/_summary.md` + `<group>.md` |
81
- | Deploy, infra or env changed | `06_infra/<topic>.md` |
82
- | Tests added or changed | `07_testing/<group>.md` |
83
- | Auth, roles or keys changed | `08_security/<topic>.md` |
84
- | Third-party service added | `09_integrations/<service>.md` |
85
- | Feature done | one line in `99_progress/features.md` |
86
- | Task done | `99_progress/todo.md` |
87
- | Session ends or `/clear` | `99_progress/handoff.md` |
88
-
89
- Each change also updates the folder's `_summary.md` (when it has one) and the MAP.md line.
90
-
91
104
  ## Doc header
92
105
  ```
93
106
  # <Title>
94
107
  > Updated: YYYY-MM-DD | Status: draft/active/done
95
108
  ```
96
109
 
97
- ## Session start (~2-3K tokens)
98
- 1. `docs/MAP.md`
99
- 2. `docs/99_progress/handoff.md`
100
- 3. `docs/99_progress/todo.md`
101
- 4. `_summary.md` of the relevant folder
102
- 5. Only the detail files the task needs
110
+ ## Session start
111
+ 1. `docs/MAP.md`, then `docs/99_progress/handoff.md`.
112
+ 2. `git status`, `git log --oneline -5`, `git worktree list`.
113
+ 3. `docs/99_progress/sessions/<your branch>.md` if it exists.
114
+ 4. `docs/99_progress/todo.md`, the relevant `_summary.md`.
115
+ 5. Only the detail files the task needs.
103
116
 
104
- ## todo.md
117
+ ## handoff.md (main line, updated at the end of each session and by each merge pass)
105
118
  ```
106
- # TODO
107
- > Updated: YYYY-MM-DD
119
+ # Handoff
120
+ > Updated: YYYY-MM-DD HH:MM
108
121
 
109
- ## Doing
110
- - [ ] Task -- `01_requirements/<feature>.md`
122
+ ## Live
123
+ - What runs where (commit, host), link to 06_infra
124
+
125
+ ## In progress
126
+ - Main line: unfinished work, broken things
127
+ - Worktrees / sessions: branch, path, goal, `sessions/<branch>.md`
128
+
129
+ ## Waiting for the owner
130
+ 1. Decision or action, with where to answer
111
131
 
112
132
  ## Next
113
- - [ ] Task
133
+ 1. Highest priority
114
134
 
115
- ## Done
116
- - [x] [YYYY-MM-DD] Task
135
+ ## Recent decisions
136
+ - Chose X over Y: reason (D-n)
117
137
  ```
118
138
 
119
- ## handoff.md (≤ 30 lines, rewritten each session)
139
+ ## sessions/<branch>.md (one per parallel branch, deleted after its merge)
120
140
  ```
121
- # Handoff
122
- > Updated: YYYY-MM-DD HH:MM
141
+ # <branch>
142
+ > Updated: YYYY-MM-DD HH:MM | Worktree: <path> | Base: <commit>
123
143
 
144
+ ## Goal
124
145
  ## Done
125
- - What changed (paths)
146
+ - Change (paths)
147
+ ## Left
148
+ - Step, how to test it
149
+ ## Decisions / open questions
150
+ ## Touched
151
+ - Areas, files, migrations, docs to fold in at merge
152
+ ```
153
+
154
+ ## Merge pass
155
+ 1. Fold each merged branch's session note into the topic docs.
156
+ 2. Update `_summary.md`, MAP.md and the handoff.
157
+ 3. Delete the merged notes.
158
+ 4. If two branches generated migrations or doc rows with the same number, regenerate them once on the merged code.
126
159
 
127
- ## State
128
- - Works / broken / in progress
160
+ ## todo.md
161
+ ```
162
+ # TODO
163
+ > Updated: YYYY-MM-DD
164
+
165
+ ## Doing
166
+ - [ ] Task -- `01_requirements/<feature>.md`
129
167
 
130
168
  ## Next
131
- 1. Highest priority
169
+ - [ ] Task
132
170
 
133
- ## Decisions
134
- - Chose X over Y: reason
171
+ ## Done
172
+ - [x] [YYYY-MM-DD] Task
135
173
  ```
136
174
 
137
175
  ## New project
138
- No `docs/` yet: create `MAP.md` (headers only), `99_progress/todo.md` and `99_progress/handoff.md`. Create
139
- everything else when there is content for it.
176
+ If there is no `docs/` yet, create `MAP.md` (headers only), `99_progress/todo.md` and `99_progress/handoff.md`.
177
+ Create everything else when there is content for it.
@@ -24,16 +24,16 @@
24
24
 
25
25
  ## Docs System
26
26
  Two sets of docs (`.claude/rules/docs.md`, sisyo-managed):
27
- - `docs/` -- for agents: English, as short as possible, paths to code; 3-level routing `MAP.md` → `_summary.md` → detail files.
27
+ - `docs/` -- for agents: English, concise but complete enough that any agent (new session, other worktree) takes over without missing anything; 3-level routing `MAP.md` → `_summary.md` → detail files.
28
28
  - Human docs -- for people, in the project's hub (Kicho, skill `kicho-devflow`) when it has one: architecture, main techniques, key numbers, sprint summaries.
29
29
 
30
- Session start -- read in order:
31
- 1. `docs/MAP.md` -- full project scope (~500 tokens)
32
- 2. `docs/99_progress/handoff.md` -- last session context
33
- 3. `docs/99_progress/todo.md` -- active tasks
34
- 4. Read `_summary.md` of relevant folder -- scope at a glance
35
- 5. Load ONLY the detail docs needed for current task
30
+ Session start -- in order:
31
+ 1. `docs/MAP.md`, then `docs/99_progress/handoff.md` -- scope, live state, work in progress
32
+ 2. `git status`, `git log --oneline -5`, `git worktree list` -- where you are, parallel branches
33
+ 3. `docs/99_progress/sessions/<your branch>.md` -- if you continue a parallel branch
34
+ 4. `docs/99_progress/todo.md` and the relevant `_summary.md`
35
+ 5. ONLY the detail docs needed for the task
36
36
 
37
- During work -- vibe-docs skill keeps `docs/` in sync, bottom-up: detail → `_summary.md` → MAP.md.
37
+ During work -- vibe-docs keeps `docs/` in sync, bottom-up: detail → `_summary.md` → MAP.md (on a parallel branch: detail docs + your session note; the merge pass does the rest).
38
38
 
39
- Before `/clear` -- always write `docs/99_progress/handoff.md` first.
39
+ Before `/clear` or the end of a session -- update `docs/99_progress/handoff.md` (or your session note).