@torus-engineering/tas-kit 1.9.0 → 1.11.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/.claude/commands/ado-create.md +17 -17
- package/.claude/commands/ado-delete.md +11 -11
- package/.claude/commands/ado-get.md +12 -12
- package/.claude/commands/ado-status.md +12 -12
- package/.claude/commands/ado-update.md +15 -15
- package/.claude/commands/tas-adr.md +33 -33
- package/.claude/commands/tas-apitest-plan.md +173 -173
- package/.claude/commands/tas-apitest.md +143 -143
- package/.claude/commands/tas-brainstorm.md +14 -14
- package/.claude/commands/tas-bug.md +113 -113
- package/.claude/commands/tas-design.md +37 -37
- package/.claude/commands/tas-dev.md +128 -128
- package/.claude/commands/tas-e2e-mobile.md +155 -155
- package/.claude/commands/tas-e2e-web.md +163 -163
- package/.claude/commands/tas-e2e.md +102 -102
- package/.claude/commands/tas-epic.md +35 -35
- package/.claude/commands/tas-feature.md +47 -47
- package/.claude/commands/tas-fix.md +51 -51
- package/.claude/commands/tas-functest-mobile.md +144 -144
- package/.claude/commands/tas-functest-web.md +192 -192
- package/.claude/commands/tas-functest.md +76 -76
- package/.claude/commands/tas-init.md +14 -14
- package/.claude/commands/tas-plan.md +198 -200
- package/.claude/commands/tas-prd.md +37 -37
- package/.claude/commands/tas-review.md +111 -111
- package/.claude/commands/tas-sad.md +43 -43
- package/.claude/commands/tas-security.md +87 -81
- package/.claude/commands/tas-spec.md +20 -20
- package/.claude/commands/tas-status.md +13 -13
- package/.claude/commands/tas-story.md +91 -91
- package/.claude/commands/tas-verify.md +51 -51
- package/.claude/rules/common/post-review-agent.md +49 -49
- package/.claude/rules/common/project-status.md +14 -14
- package/.claude/rules/common/stack-detection.md +6 -6
- package/.claude/rules/common/token-logging.md +27 -27
- package/.claude/rules/csharp/api-testing.md +171 -171
- package/.claude/skills/ado-integration/SKILL.md +36 -36
- package/.claude/skills/tas-conventions/SKILL.md +32 -32
- package/.claude/skills/tas-implementation-complete/SKILL.md +100 -99
- package/.claude/skills/tas-tdd/SKILL.md +123 -123
- package/.claude/skills/token-logger/SKILL.md +19 -19
- package/.tas/README.md +266 -1520
- package/.tas/checklists/code-review.md +13 -13
- package/.tas/checklists/security.md +3 -3
- package/.tas/checklists/story-done.md +11 -11
- package/.tas/hooks/README.md +138 -0
- package/.tas/hooks/pre-commit +26 -0
- package/.tas/hooks/security-scan.js +599 -0
- package/.tas/project-status-example.yaml +3 -3
- package/.tas/tas-example.yaml +25 -8
- package/.tas/templates/ADR.md +16 -16
- package/.tas/templates/API-Test-Spec.md +3 -3
- package/.tas/templates/Bug.md +12 -12
- package/.tas/templates/Design-Spec.md +8 -8
- package/.tas/templates/E2E-Execution-Report.md +1 -1
- package/.tas/templates/Epic.md +1 -1
- package/.tas/templates/Feature.md +10 -10
- package/.tas/templates/Func-Test-Spec.md +3 -3
- package/.tas/templates/SAD.md +106 -106
- package/.tas/templates/Security-Report.md +3 -3
- package/.tas/templates/Story.md +9 -9
- package/.tas/tools/tas-ado-readme.md +169 -169
- package/.tas/tools/tas-ado.py +1 -1
- package/CLAUDE-Example.md +37 -58
- package/README.md +294 -42
- package/bin/cli.js +24 -7
- package/lib/install.js +161 -47
- package/package.json +1 -1
|
@@ -1,91 +1,91 @@
|
|
|
1
|
-
# /tas-story $ARGUMENTS
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
**
|
|
7
|
-
**
|
|
8
|
-
|
|
9
|
-
## Always / Ask / Never
|
|
10
|
-
|
|
11
|
-
| |
|
|
12
|
-
|---|---|
|
|
13
|
-
| **Always** |
|
|
14
|
-
| **Always** | Set `plan_status: pending`
|
|
15
|
-
| **Ask** |
|
|
16
|
-
| **Never** |
|
|
17
|
-
|
|
18
|
-
## Prerequisite
|
|
19
|
-
-
|
|
20
|
-
|
|
21
|
-
##
|
|
22
|
-
|
|
23
|
-
###
|
|
24
|
-
|
|
25
|
-
**
|
|
26
|
-
-
|
|
27
|
-
-
|
|
28
|
-
1.
|
|
29
|
-
2.
|
|
30
|
-
3.
|
|
31
|
-
|
|
32
|
-
**
|
|
33
|
-
-
|
|
34
|
-
-
|
|
35
|
-
|
|
36
|
-
**
|
|
37
|
-
-
|
|
38
|
-
-
|
|
39
|
-
|
|
40
|
-
**
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
a) **User Story**: "As a [role], I want [goal], so that [benefit]"
|
|
45
|
-
|
|
46
|
-
b) **Business Requirements** (
|
|
47
|
-
|
|
48
|
-
c) **Design Notes** (
|
|
49
|
-
|
|
50
|
-
d) **Prerequisites** (
|
|
51
|
-
|
|
52
|
-
e) **Acceptance Criteria**:
|
|
53
|
-
|
|
54
|
-
**
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
- "
|
|
58
|
-
- "
|
|
59
|
-
- "
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
**
|
|
64
|
-
-
|
|
65
|
-
-
|
|
66
|
-
- Frontmatter: `plan_status: pending`, `plan_date:`
|
|
67
|
-
|
|
68
|
-
**
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
**
|
|
72
|
-
> "Story
|
|
73
|
-
|
|
74
|
-
---
|
|
75
|
-
|
|
76
|
-
###
|
|
77
|
-
|
|
78
|
-
1.
|
|
79
|
-
2.
|
|
80
|
-
3.
|
|
81
|
-
4.
|
|
82
|
-
5.
|
|
83
|
-
|
|
84
|
-
##
|
|
85
|
-
- Story
|
|
86
|
-
- Story file = **product artifact**:
|
|
87
|
-
- Story status: New → Committed → In Progress → Deploy Test → Verify Test → Deploy Stag → Verify Stag → Deploy Prod → Verify Prod → Done
|
|
88
|
-
|
|
89
|
-
##
|
|
90
|
-
|
|
91
|
-
Invoke skill `token-logger`:
|
|
1
|
+
# /tas-story $ARGUMENTS
|
|
2
|
+
|
|
3
|
+
Role: PE - Product Engineer
|
|
4
|
+
Create or update User Story document.
|
|
5
|
+
|
|
6
|
+
**Scope:** Business logic, user experience, acceptance criteria, test cases.
|
|
7
|
+
**Out of scope:** Technical implementation, files to modify, database schema — that's `/tas-plan`'s job.
|
|
8
|
+
|
|
9
|
+
## Always / Ask / Never
|
|
10
|
+
|
|
11
|
+
| | Action |
|
|
12
|
+
|---|---|
|
|
13
|
+
| **Always** | Write AC in Given/When/Then format |
|
|
14
|
+
| **Always** | Set `plan_status: pending` for new Story |
|
|
15
|
+
| **Ask** | When Story > 8h — suggest splitting |
|
|
16
|
+
| **Never** | Read SAD, ADR — technical is `/tas-plan`'s job |
|
|
17
|
+
|
|
18
|
+
## Prerequisite
|
|
19
|
+
- At least one Feature must exist
|
|
20
|
+
|
|
21
|
+
## Actions
|
|
22
|
+
|
|
23
|
+
### CREATE mode ($ARGUMENTS is new Story description, or no $ARGUMENTS)
|
|
24
|
+
|
|
25
|
+
**Step 1 — Identify Feature**
|
|
26
|
+
- Read `project.code` from root/`tas.yaml`
|
|
27
|
+
- Prioritize in order:
|
|
28
|
+
1. If `$ARGUMENTS` contains Feature ID → use it
|
|
29
|
+
2. If context has `parent_id` → use it
|
|
30
|
+
3. Ask user: "Which Feature does this Story belong to?" — no directory scan
|
|
31
|
+
|
|
32
|
+
**Step 2 — Gather business context**
|
|
33
|
+
- Read identified Feature file (get business context, scope, existing Stories list)
|
|
34
|
+
- Read PRD (if exists) — only business requirements, user goals
|
|
35
|
+
|
|
36
|
+
**Step 3 — Determine Story ID**
|
|
37
|
+
- Read Stories section in Feature file → determine next index from that list
|
|
38
|
+
- DO NOT scan directory
|
|
39
|
+
|
|
40
|
+
**Step 4 — Draft Story with user**
|
|
41
|
+
|
|
42
|
+
Discuss to fill in:
|
|
43
|
+
|
|
44
|
+
a) **User Story**: "As a [role], I want [goal], so that [benefit]"
|
|
45
|
+
|
|
46
|
+
b) **Business Requirements** (if any): specific business rules, stakeholder constraints
|
|
47
|
+
|
|
48
|
+
c) **Design Notes** (if any): UI/UX specs, mockup links, flow diagrams
|
|
49
|
+
|
|
50
|
+
d) **Prerequisites** (if any): other Stories that must be done first
|
|
51
|
+
|
|
52
|
+
e) **Acceptance Criteria**: each AC is a clear Given/When/Then scenario
|
|
53
|
+
|
|
54
|
+
**Step 5 — Test Case Prompting**
|
|
55
|
+
|
|
56
|
+
After AC confirmed, ask more:
|
|
57
|
+
- "Besides happy path, any edge cases to test?" (empty input, boundary values, concurrent)
|
|
58
|
+
- "Any negative cases to cover?" (unauthorized, invalid data, timeout, not found)
|
|
59
|
+
- "Any external dependencies to mock when testing?" (external APIs, database state)
|
|
60
|
+
|
|
61
|
+
Write all to `## Unit Test Cases` section.
|
|
62
|
+
|
|
63
|
+
**Step 6 — Create file**
|
|
64
|
+
- Read `.tas/templates/Story.md` for format
|
|
65
|
+
- Create `docs/epics/{code}-Epic-{NNN}-{slug}/{code}-Feature-{NNN}-{slug}/{code}-Story-{NNN}-{slug}.md`
|
|
66
|
+
- Frontmatter: `plan_status: pending`, `plan_date:` left empty
|
|
67
|
+
|
|
68
|
+
**Step 7 — Update project-status.yaml**
|
|
69
|
+
Per `.claude/rules/common/project-status.md` — add entry to `epics.{EPIC_ID}.features.{FEATURE_ID}.stories`.
|
|
70
|
+
|
|
71
|
+
**Step 8 — Notify next step**
|
|
72
|
+
> "Story created. Before SE starts coding, run `/tas-plan {Story-ID}` for technical planning."
|
|
73
|
+
|
|
74
|
+
---
|
|
75
|
+
|
|
76
|
+
### UPDATE mode ($ARGUMENTS is Story ID, e.g., "Story-005")
|
|
77
|
+
|
|
78
|
+
1. Find file via glob `docs/epics/**/{code}-Story-{ID}-*.md`
|
|
79
|
+
2. Read current Story file
|
|
80
|
+
3. Ask user what needs changing (update AC, change status, add test cases, fix business rule...)
|
|
81
|
+
4. Update file, add entry to Changelog
|
|
82
|
+
5. Update `project-status.yaml` per `.claude/rules/common/project-status.md`.
|
|
83
|
+
|
|
84
|
+
## Principles
|
|
85
|
+
- Story must be small enough to complete in **4-8 hours**; if larger → split into multiple Stories
|
|
86
|
+
- Story file = **product artifact**: describes *what* and *why*, not *how*
|
|
87
|
+
- Story status: New → Committed → In Progress → Deploy Test → Verify Test → Deploy Stag → Verify Stag → Deploy Prod → Verify Prod → Done
|
|
88
|
+
|
|
89
|
+
## Final Step — Token Log
|
|
90
|
+
|
|
91
|
+
Invoke skill `token-logger`: write AI Usage Log to working Story file.
|
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
Verify Feature
|
|
5
|
-
|
|
6
|
-
## Prerequisite
|
|
7
|
-
- Feature
|
|
8
|
-
-
|
|
9
|
-
|
|
10
|
-
##
|
|
11
|
-
1.
|
|
12
|
-
2. $ARGUMENTS
|
|
13
|
-
3.
|
|
14
|
-
4.
|
|
15
|
-
|
|
16
|
-
###
|
|
17
|
-
4.5. **
|
|
18
|
-
|
|
19
|
-
**Functional Tests** (Layer 2):
|
|
20
|
-
-
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
|
|
24
|
-
**E2E Tests** (Layer 3 -
|
|
25
|
-
> Launch `e2e-runner`: E2E verification
|
|
26
|
-
>
|
|
27
|
-
>
|
|
28
|
-
>
|
|
29
|
-
|
|
30
|
-
5. **
|
|
31
|
-
-
|
|
32
|
-
-
|
|
33
|
-
|
|
34
|
-
6.
|
|
35
|
-
-
|
|
36
|
-
-
|
|
37
|
-
- Bug
|
|
38
|
-
7.
|
|
39
|
-
-
|
|
40
|
-
-
|
|
41
|
-
-
|
|
42
|
-
8.
|
|
43
|
-
|
|
44
|
-
##
|
|
45
|
-
-
|
|
46
|
-
-
|
|
47
|
-
- Feature
|
|
48
|
-
|
|
49
|
-
##
|
|
50
|
-
|
|
51
|
-
Invoke skill `token-logger`:
|
|
1
|
+
# /tas-verify $ARGUMENTS
|
|
2
|
+
|
|
3
|
+
Role: PE - Product Engineer
|
|
4
|
+
Verify Feature on Staging environment (Phase 2).
|
|
5
|
+
|
|
6
|
+
## Prerequisite
|
|
7
|
+
- Feature must have status "Ready To Verify"
|
|
8
|
+
- Staging environment must be ready
|
|
9
|
+
|
|
10
|
+
## Actions
|
|
11
|
+
1. Need context from root/tas.yaml
|
|
12
|
+
2. $ARGUMENTS is Feature ID. If not provided, list features with status "Ready To Verify".
|
|
13
|
+
3. Find Feature file in docs/epics/ tree (using glob)
|
|
14
|
+
4. Need context from current Feature file (especially Integration Test Cases and E2E Test Cases sections)
|
|
15
|
+
|
|
16
|
+
### Verification workflow:
|
|
17
|
+
4.5. **Run Automated Tests** (if available):
|
|
18
|
+
|
|
19
|
+
**Functional Tests** (Layer 2):
|
|
20
|
+
- Check if `docs/epics/{epic-dir}/{feature-dir}/Func-Test-*.md` exists
|
|
21
|
+
- If yes, ask PE: "Run functional test suite? Command: `yarn functest:mobile:{feature-slug}` (or `yarn functest:web:{feature-slug}`)"
|
|
22
|
+
- Note pass/fail of func suite
|
|
23
|
+
|
|
24
|
+
**E2E Tests** (Layer 3 - if Feature has E2E / Acceptance Test Cases):
|
|
25
|
+
> Launch `e2e-runner`: E2E verification for Feature {ID}.
|
|
26
|
+
> Read `## E2E / Acceptance Test Cases` section from Feature file — list each test case.
|
|
27
|
+
> Run those test cases, report results: Pass/Fail per test case with reason if Fail.
|
|
28
|
+
> Don't auto-fix bugs — only report results for PE confirmation.
|
|
29
|
+
|
|
30
|
+
5. **Synthesize results and confirm with PE**:
|
|
31
|
+
- Display automated test results summary (Functional + E2E)
|
|
32
|
+
- Ask PE: "Automated tests passed. Any issues on actual Staging that automated tests didn't catch? (UX, business logic, real-world edge cases...)"
|
|
33
|
+
|
|
34
|
+
6. For each issue PE reports or test case FAIL:
|
|
35
|
+
- Ask PE to describe the bug
|
|
36
|
+
- Automatically create Bug in that Feature directory (use /tas-bug logic)
|
|
37
|
+
- Bug references original test case (FT ID or E2E ID), or notes "found via manual Staging verify"
|
|
38
|
+
7. Update Feature file:
|
|
39
|
+
- Write test results (Pass/Fail + date) to each test case
|
|
40
|
+
- If all Pass: update Feature status to "Verified"
|
|
41
|
+
- If any Fail: keep Feature status "Ready To Verify", list bugs
|
|
42
|
+
8. Update root/project-status.yaml
|
|
43
|
+
|
|
44
|
+
## Principles
|
|
45
|
+
- DO NOT skip any test case, must verify all
|
|
46
|
+
- Bugs found in Phase 2 MUST be recorded as Bug for tracking
|
|
47
|
+
- Feature only moves to Phase 3 (Deploy) when status = "Verified"
|
|
48
|
+
|
|
49
|
+
## Final Step — Token Log
|
|
50
|
+
|
|
51
|
+
Invoke skill `token-logger`: write AI Usage Log to Feature file being verified.
|
|
@@ -1,49 +1,49 @@
|
|
|
1
|
-
# Post-Implementation Review (Isolated Agent)
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
##
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
Artifact: {path-to-artifact-file}
|
|
13
|
-
Changed files: {
|
|
14
|
-
Stack: {stack
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
1. Hygiene scan: debug code
|
|
18
|
-
commented-out blocks
|
|
19
|
-
1b. Silent failure scan —
|
|
20
|
-
- Swallowed exceptions: empty catch {}, catch
|
|
21
|
-
- Silent async failures: fire-and-forget (unawaited task/Promise), async void (.NET),
|
|
22
|
-
.catch(() => {})
|
|
23
|
-
- Null blindspots: .FirstOrDefault()
|
|
24
|
-
optional chaining
|
|
25
|
-
dict.get() result
|
|
26
|
-
- Error propagation
|
|
27
|
-
|
|
28
|
-
- Config reads
|
|
29
|
-
2.
|
|
30
|
-
pytest.ini → python -m pytest), report
|
|
31
|
-
3. Parallel review — launch
|
|
32
|
-
- code-reviewer:
|
|
33
|
-
|
|
34
|
-
- security-reviewer:
|
|
35
|
-
|
|
36
|
-
- {lang_agent}:
|
|
37
|
-
|
|
38
|
-
4.
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
## Gate Rule
|
|
44
|
-
|
|
45
|
-
|
|
|
46
|
-
|---|---|
|
|
47
|
-
|
|
|
48
|
-
|
|
|
49
|
-
|
|
|
1
|
+
# Post-Implementation Review (Isolated Agent)
|
|
2
|
+
|
|
3
|
+
After implementing or fixing, run review through **independent Agent** — don't use current session to avoid reviewer bias from implementation process.
|
|
4
|
+
|
|
5
|
+
## How to use
|
|
6
|
+
|
|
7
|
+
Call `Agent` tool with following prompt (replace placeholders `{}`):
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
You are code reviewer. No context from previous session — review completely objectively.
|
|
11
|
+
|
|
12
|
+
Artifact: {path-to-artifact-file}
|
|
13
|
+
Changed files: {list of files just changed}
|
|
14
|
+
Stack: {stack from CLAUDE.md}
|
|
15
|
+
|
|
16
|
+
Execute:
|
|
17
|
+
1. Hygiene scan: leftover debug code (console.log, debugger, print), hardcoded secrets,
|
|
18
|
+
large commented-out blocks (>5 lines).
|
|
19
|
+
1b. Silent failure scan — find following patterns:
|
|
20
|
+
- Swallowed exceptions: empty catch {}, catch only logs but continues like no error
|
|
21
|
+
- Silent async failures: fire-and-forget (unawaited task/Promise), async void (.NET),
|
|
22
|
+
.catch(() => {}) with no handling
|
|
23
|
+
- Null blindspots: .FirstOrDefault() used directly without null-check (.NET),
|
|
24
|
+
missing optional chaining on deeply nested object access (TS/JS),
|
|
25
|
+
dict.get() result used as non-None (Python)
|
|
26
|
+
- Error propagation wrong: HTTP calls don't check status before parse,
|
|
27
|
+
function returns bool/null when error instead of throwing (caller ignores result)
|
|
28
|
+
- Config reads don't check existence
|
|
29
|
+
2. Run tests: detect test runner (package.json → npm test / *.csproj → dotnet test /
|
|
30
|
+
pytest.ini → python -m pytest), report results.
|
|
31
|
+
3. Parallel review — launch simultaneously:
|
|
32
|
+
- code-reviewer: read .tas/checklists/code-review.md + .claude/rules/common/code-review.md.
|
|
33
|
+
Focus: naming, architecture, error handling, DRY, function size, nesting depth.
|
|
34
|
+
- security-reviewer: read .claude/rules/common/security.md.
|
|
35
|
+
Focus: OWASP Top 10, injection, hardcoded secrets, auth/authz.
|
|
36
|
+
- {lang_agent}: read .claude/rules/[stack]/coding-style.md + .claude/rules/[stack]/patterns.md.
|
|
37
|
+
Focus: async/await, null handling, type safety, stack-specific anti-patterns.
|
|
38
|
+
4. Synthesize findings: Critical / High / Medium / Low with file:line and specific fix.
|
|
39
|
+
|
|
40
|
+
Return full Review Summary.
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
## Gate Rule
|
|
44
|
+
|
|
45
|
+
| Result | Action |
|
|
46
|
+
|---|---|
|
|
47
|
+
| Has **Critical** or **High** | List findings, **STOP**, require fix before continuing |
|
|
48
|
+
| Only **Medium** / **Low** | List suggestions, ask if user wants to fix, then continue |
|
|
49
|
+
| No findings | Continue normally |
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
# project-status.yaml — Update Convention
|
|
2
2
|
|
|
3
|
-
File `project-status.yaml`
|
|
4
|
-
Commands
|
|
3
|
+
File `project-status.yaml` at project root is aggregate index of project status.
|
|
4
|
+
Commands update this file after each artifact or status change.
|
|
5
5
|
|
|
6
|
-
##
|
|
6
|
+
## Always update
|
|
7
7
|
|
|
8
8
|
```yaml
|
|
9
|
-
last_updated: YYYY-MM-DD #
|
|
9
|
+
last_updated: YYYY-MM-DD # current date, each time there's a change
|
|
10
10
|
```
|
|
11
11
|
|
|
12
|
-
## Artifacts (docs
|
|
12
|
+
## Artifacts (individual docs)
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
Update when creating new or changing version:
|
|
15
15
|
|
|
16
16
|
```yaml
|
|
17
17
|
artifacts:
|
|
@@ -19,8 +19,8 @@ artifacts:
|
|
|
19
19
|
file: docs/prd.md
|
|
20
20
|
status: Draft | Review | Approved
|
|
21
21
|
last_updated: YYYY-MM-DD
|
|
22
|
-
version: "1.0" #
|
|
23
|
-
requirements_count: N #
|
|
22
|
+
version: "1.0" # increment minor when updating content, major for large changes
|
|
23
|
+
requirements_count: N # only for PRD — count of FR-xxx
|
|
24
24
|
|
|
25
25
|
sad:
|
|
26
26
|
file: docs/sad.md
|
|
@@ -42,7 +42,7 @@ artifacts:
|
|
|
42
42
|
|
|
43
43
|
## Epics / Features / Stories
|
|
44
44
|
|
|
45
|
-
|
|
45
|
+
Update when creating new or changing status:
|
|
46
46
|
|
|
47
47
|
```yaml
|
|
48
48
|
epics:
|
|
@@ -72,9 +72,9 @@ adrs:
|
|
|
72
72
|
title: "..."
|
|
73
73
|
```
|
|
74
74
|
|
|
75
|
-
##
|
|
75
|
+
## Rules
|
|
76
76
|
|
|
77
|
-
-
|
|
78
|
-
-
|
|
79
|
-
-
|
|
80
|
-
- Version: minor (+0.1)
|
|
77
|
+
- Only update key related to change just occurred — don't rewrite entire file
|
|
78
|
+
- If key doesn't exist yet: add new
|
|
79
|
+
- If key exists: update value
|
|
80
|
+
- Version: minor (+0.1) when updating content; major (+1.0) when large structure change
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
# Stack Detection
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Read `CLAUDE.md` at root, find `## Tech Stack` section, determine following variables for use in agent prompts and rule file lookups.
|
|
4
4
|
|
|
5
5
|
## lang_agent — Backend
|
|
6
6
|
|
|
7
|
-
| Tech Stack
|
|
7
|
+
| Tech Stack contains | lang_agent |
|
|
8
8
|
|---|---|
|
|
9
9
|
| `.NET` / `C#` | `csharp-reviewer` |
|
|
10
10
|
| `Node.js` / `TypeScript` / `NestJS` / `Express` | `typescript-reviewer` |
|
|
11
11
|
| `Python` / `FastAPI` / `Django` / `Flask` | `python-reviewer` |
|
|
12
12
|
|
|
13
|
-
**Frontend
|
|
13
|
+
**Frontend addition:** if Tech Stack contains `React` → add `typescript-reviewer` to lang_agent (if not already).
|
|
14
14
|
|
|
15
|
-
## infra_agent
|
|
15
|
+
## infra_agent and db_agent — Optional
|
|
16
16
|
|
|
17
|
-
| Tech Stack
|
|
17
|
+
| Tech Stack contains | Variable | Value |
|
|
18
18
|
|---|---|---|
|
|
19
19
|
| `AWS` (Infrastructure) | `infra_agent` | `aws-reviewer` |
|
|
20
20
|
| `MySQL` / `PostgreSQL` / `MSSQL` / `SQL Server` / `SQLite` | `db_agent` | `database-reviewer` |
|
|
21
21
|
|
|
22
|
-
## Rules directory
|
|
22
|
+
## Rules directory by stack
|
|
23
23
|
|
|
24
24
|
| lang_agent | Rules directory |
|
|
25
25
|
|---|---|
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
# Token Usage Logging
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
## Token Estimation
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
## Format
|
|
11
|
-
|
|
12
|
-
```markdown
|
|
13
|
-
---
|
|
14
|
-
|
|
15
|
-
## AI Usage Log
|
|
16
|
-
|
|
17
|
-
| # | Date | Command | Input (est.) | Output (est.) |
|
|
18
|
-
|---|------|---------|-------------|---------------|
|
|
19
|
-
| 1 | YYYY-MM-DD | /tas-{name} | ~{N}k | ~{N}k |
|
|
20
|
-
| 2 | YYYY-MM-DD | /tas-{name} (revision) | ~{N}k | ~{N}k |
|
|
21
|
-
| **Total** | | | **~{N}k** | **~{N}k** |
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
## Update Rules
|
|
25
|
-
|
|
26
|
-
- **
|
|
27
|
-
- **
|
|
1
|
+
# Token Usage Logging
|
|
2
|
+
|
|
3
|
+
Write `## AI Usage Log` at end of artifact file when TAS command completes.
|
|
4
|
+
|
|
5
|
+
## Token Estimation
|
|
6
|
+
|
|
7
|
+
Estimate from session awareness: character count of each file `Read` ÷ 4 ≈ tokens (English/code), ÷ 2 (Vietnamese).
|
|
8
|
+
Character count of artifact output ÷ 4. Always append `(est.)`. User verifies with `/cost` (CLI) or `/context` (Desktop app).
|
|
9
|
+
|
|
10
|
+
## Format
|
|
11
|
+
|
|
12
|
+
```markdown
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## AI Usage Log
|
|
16
|
+
|
|
17
|
+
| # | Date | Command | Input (est.) | Output (est.) |
|
|
18
|
+
|---|------|---------|-------------|---------------|
|
|
19
|
+
| 1 | YYYY-MM-DD | /tas-{name} | ~{N}k | ~{N}k |
|
|
20
|
+
| 2 | YYYY-MM-DD | /tas-{name} (revision) | ~{N}k | ~{N}k |
|
|
21
|
+
| **Total** | | | **~{N}k** | **~{N}k** |
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## Update Rules
|
|
25
|
+
|
|
26
|
+
- **First time**: section doesn't exist → append entire section with first row and Total row
|
|
27
|
+
- **Subsequent**: append new row before Total row, update Total (cumulative)
|