tycono 0.1.28 → 0.1.29
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/bin/tycono.ts +11 -4
- package/package.json +1 -1
- package/src/api/src/engine/context-assembler.ts +2 -2
- package/templates/CLAUDE.md.tmpl +43 -10
package/bin/tycono.ts
CHANGED
|
@@ -131,13 +131,20 @@ async function startServer(): Promise<void> {
|
|
|
131
131
|
const port = process.env.PORT ? Number(process.env.PORT) : await findFreePort();
|
|
132
132
|
process.env.PORT = String(port);
|
|
133
133
|
|
|
134
|
-
// Detect company name from CLAUDE.md
|
|
134
|
+
// Detect company name from company/company.md (user-owned), fallback to CLAUDE.md
|
|
135
135
|
let companyName = 'My Company';
|
|
136
136
|
if (initialized) {
|
|
137
137
|
try {
|
|
138
|
-
const
|
|
139
|
-
|
|
140
|
-
|
|
138
|
+
const companyMdPath = path.join(process.env.COMPANY_ROOT!, 'company', 'company.md');
|
|
139
|
+
if (fs.existsSync(companyMdPath)) {
|
|
140
|
+
const companyContent = fs.readFileSync(companyMdPath, 'utf-8');
|
|
141
|
+
const titleMatch = companyContent.match(/^#\s+(.+)/m);
|
|
142
|
+
if (titleMatch) companyName = titleMatch[1].trim();
|
|
143
|
+
} else {
|
|
144
|
+
const claudeContent = fs.readFileSync(claudeMdPath, 'utf-8');
|
|
145
|
+
const titleMatch = claudeContent.match(/^#\s+(.+)/m);
|
|
146
|
+
if (titleMatch) companyName = titleMatch[1].trim();
|
|
147
|
+
}
|
|
141
148
|
} catch {
|
|
142
149
|
// ignore
|
|
143
150
|
}
|
package/package.json
CHANGED
|
@@ -57,10 +57,10 @@ export function assembleContext(
|
|
|
57
57
|
|
|
58
58
|
const sections: string[] = [];
|
|
59
59
|
|
|
60
|
-
// 1. CLAUDE.md
|
|
60
|
+
// 1. Company Rules (CLAUDE.md + custom-rules.md + company.md)
|
|
61
61
|
const companyRules = loadCompanyRules(companyRoot);
|
|
62
62
|
if (companyRules) {
|
|
63
|
-
sections.push(
|
|
63
|
+
sections.push(companyRules);
|
|
64
64
|
}
|
|
65
65
|
|
|
66
66
|
// 2. Org Context
|
package/templates/CLAUDE.md.tmpl
CHANGED
|
@@ -33,12 +33,35 @@
|
|
|
33
33
|
|
|
34
34
|
## AI Work Rules
|
|
35
35
|
|
|
36
|
+
### The Loop (Work Cycle)
|
|
37
|
+
|
|
38
|
+
Every task follows this cycle. Implementing without completing the cycle is only half the job.
|
|
39
|
+
|
|
40
|
+
| Step | Action | Why |
|
|
41
|
+
|------|--------|-----|
|
|
42
|
+
| ① Knowledge | Check/research related docs | Without context, direction goes wrong |
|
|
43
|
+
| ② Task | Define task from docs | Without requirements, you'll rework |
|
|
44
|
+
| ③ Implement | Execute the actual work | Value creation |
|
|
45
|
+
| ④ Knowledge Update | Update docs with new insights | Prevents knowledge decay |
|
|
46
|
+
| ⑤ Task Update | Update task status, check next work | Ensures continuity |
|
|
47
|
+
|
|
48
|
+
**C-Level**: Execute The Loop autonomously — decompose tasks, analyze dependencies, dispatch independent tasks in parallel, collect results.
|
|
49
|
+
**Member**: After implementation, always complete steps ④ and ⑤.
|
|
50
|
+
|
|
36
51
|
### Hub-First Principle
|
|
37
52
|
|
|
38
|
-
> **Read the relevant Hub document before starting any work.**
|
|
53
|
+
> ⛔ **Read the relevant Hub document before starting any work.**
|
|
39
54
|
|
|
55
|
+
Check the Task Routing table above to find the right "Read First" path.
|
|
40
56
|
Every folder has a Hub file (`{folder-name}.md`) as its entry point.
|
|
41
|
-
|
|
57
|
+
Read the Hub's existing tools/scripts/guides before starting work.
|
|
58
|
+
|
|
59
|
+
### Skill Check Principle
|
|
60
|
+
|
|
61
|
+
> ⛔ **If `.claude/skills/{role-id}/SKILL.md` exists, you MUST read it.**
|
|
62
|
+
|
|
63
|
+
Skill files define the tools, commands, and guides for each Role.
|
|
64
|
+
Working without reading skills means missing existing tools and starting from scratch.
|
|
42
65
|
|
|
43
66
|
### Custom Rules (CRITICAL)
|
|
44
67
|
|
|
@@ -46,6 +69,11 @@ Check the Task Routing table above to find the right Hub, then read it first.
|
|
|
46
69
|
> This file contains company-specific rules, constraints, and processes.
|
|
47
70
|
> If the file doesn't exist, ignore this section.
|
|
48
71
|
|
|
72
|
+
### Git Rules
|
|
73
|
+
|
|
74
|
+
- Source code changes: feature branch → PR → merge
|
|
75
|
+
- Direct push to main is prohibited
|
|
76
|
+
|
|
49
77
|
### Knowledge Gate
|
|
50
78
|
|
|
51
79
|
> **Before creating a new document, search existing docs first.**
|
|
@@ -68,6 +96,7 @@ Check the Task Routing table above to find the right Hub, then read it first.
|
|
|
68
96
|
|------|-------------|
|
|
69
97
|
| No orphan docs | Every document must be reachable from a Hub |
|
|
70
98
|
| Hub pattern | Each folder's entry point is `{folder}.md` |
|
|
99
|
+
| Prefer existing | Adding 1 doc = maintenance cost. Strengthen existing > create new |
|
|
71
100
|
| Cross-link | New docs must reference at least 1 related doc |
|
|
72
101
|
| Source attribution | External research must cite source and date |
|
|
73
102
|
|
|
@@ -145,16 +174,20 @@ Check the Hub's existing tools/guides/constraints before exploring code.
|
|
|
145
174
|
| Process change | Update procedure guide |
|
|
146
175
|
| Feature removed | Remove related section |
|
|
147
176
|
|
|
148
|
-
###
|
|
177
|
+
### AKB Management (CRITICAL)
|
|
149
178
|
|
|
150
|
-
|
|
179
|
+
> **Every Role manages knowledge as part of their work. Don't just code and stop.**
|
|
151
180
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
181
|
+
After completing any task, check:
|
|
182
|
+
|
|
183
|
+
| # | Item | Description |
|
|
184
|
+
|---|------|-------------|
|
|
185
|
+
| 1 | **New knowledge?** | Did this task produce new insights/decisions/analysis? |
|
|
186
|
+
| 2 | **Search existing docs** | Are there related docs already? (grep 3+ keywords) |
|
|
187
|
+
| 3 | **Decide location** | Add to existing doc vs create new (prefer existing) |
|
|
188
|
+
| 4 | **Hub connection** | Is the new/updated doc reachable from a Hub? |
|
|
189
|
+
| 5 | **Cross-link** | Are there mutual references between related docs? |
|
|
190
|
+
| 6 | **Task update** | Is the task status updated? Next work identified? |
|
|
158
191
|
|
|
159
192
|
---
|
|
160
193
|
|