prjct-cli 1.6.12 → 1.6.13

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 CHANGED
@@ -1,12 +1,44 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.6.13] - 2026-02-07
4
+
5
+ ### Refactoring
6
+
7
+ - remove unused templates and dead code (PRJ-293) (#138)
8
+ - remove unused templates and dead code (PRJ-293)
9
+
10
+
11
+ ## [1.6.15] - 2026-02-07
12
+
13
+ ### Refactor
14
+ - **Remove unused templates and dead code (PRJ-293)**: Deleted 8 unused template files from `templates/analysis/` (5) and `templates/agentic/` (3) that were never referenced by any code or other templates. Also removed unused type imports flagged by biome's `noUnusedImports` rule from `diff-generator.ts`, `sync-service.ts`, and `citations.ts`. Total: -471 lines removed.
15
+
16
+ ### Implementation Details
17
+ Audited all 135 templates by cross-referencing with code that loads them. Carefully distinguished between templates loaded dynamically via `readdir` (checklists, skills — kept) and templates with zero references (analysis prompts, agentic scaffolding — deleted). Unused imports were types imported for re-export where the `export type` statement imports independently from the source module, making the `import type` line redundant.
18
+
19
+ ### Learnings
20
+ - Dynamic template loading via `readdir` (in `prompt-builder.ts` and `skill-service.ts`) means simple grep searches can't identify all references — must trace runtime loading patterns to distinguish truly unused templates from dynamically loaded ones
21
+ - TypeScript `export type { X } from 'module'` is a standalone declaration that imports independently — a separate `import type { X }` is only needed if `X` is used in the file body
22
+
23
+ ### Test Plan
24
+
25
+ #### For QA
26
+ 1. Run `bun run build` — verify build succeeds with no errors
27
+ 2. Run `bun run lint` — verify zero biome warnings (especially `noUnusedImports`)
28
+ 3. Run `prjct sync` — verify sync still works (deleted templates were unused by sync)
29
+ 4. Verify `templates/checklists/*.md` and `templates/skills/*.md` are untouched (dynamically loaded)
30
+
31
+ #### For Users
32
+ **What changed:** Removed 8 unused internal template files and cleaned up dead imports. No user-facing behavior changes.
33
+ **How to use:** No action needed — this is an internal cleanup.
34
+ **Breaking changes:** None.
35
+
3
36
  ## [1.6.12] - 2026-02-07
4
37
 
5
38
  ### Bug Fixes
6
39
 
7
40
  - replace sync I/O in imports-tool hot path (PRJ-290) (#137)
8
41
 
9
-
10
42
  ## [1.6.14] - 2026-02-07
11
43
 
12
44
  ### Bug Fixes
@@ -9,13 +9,7 @@
9
9
  */
10
10
 
11
11
  import chalk from 'chalk'
12
- import type {
13
- DiffOptions,
14
- DiffSection,
15
- ParsedMarkdownSection,
16
- PreservedInfo,
17
- SyncDiff,
18
- } from '../types'
12
+ import type { DiffOptions, ParsedMarkdownSection, SyncDiff } from '../types'
19
13
 
20
14
  export type {
21
15
  DiffOptions,
@@ -33,7 +33,6 @@ import configManager from '../infrastructure/config-manager'
33
33
  import pathManager from '../infrastructure/path-manager'
34
34
  import { metricsStorage } from '../storage/metrics-storage'
35
35
  import type {
36
- AIToolResult,
37
36
  GitData,
38
37
  ProjectCommands,
39
38
  ProjectStats,
@@ -48,7 +47,6 @@ import { type ContextSources, defaultSources, type SourceInfo } from '../utils/c
48
47
  import * as dateHelper from '../utils/date-helper'
49
48
  import log from '../utils/logger'
50
49
  import { ContextFileGenerator } from './context-generator'
51
- import type { SyncDiff } from './diff-generator'
52
50
  import { localStateGenerator } from './local-state-generator'
53
51
  import { skillInstaller } from './skill-installer'
54
52
  import { StackDetector } from './stack-detector'
@@ -7,7 +7,7 @@
7
7
  * @see PRJ-113
8
8
  */
9
9
 
10
- import type { ContextSources, SourceInfo, SourceType } from '../types/citations'
10
+ import type { ContextSources, SourceInfo } from '../types/citations'
11
11
 
12
12
  export type { ContextSources, SourceInfo, SourceType } from '../types/citations'
13
13
 
@@ -28706,7 +28706,7 @@ var require_package = __commonJS({
28706
28706
  "package.json"(exports, module) {
28707
28707
  module.exports = {
28708
28708
  name: "prjct-cli",
28709
- version: "1.6.12",
28709
+ version: "1.6.13",
28710
28710
  description: "Context layer for AI agents. Project context for Claude Code, Gemini CLI, and more.",
28711
28711
  main: "core/index.ts",
28712
28712
  bin: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "prjct-cli",
3
- "version": "1.6.12",
3
+ "version": "1.6.13",
4
4
  "description": "Context layer for AI agents. Project context for Claude Code, Gemini CLI, and more.",
5
5
  "main": "core/index.ts",
6
6
  "bin": {
@@ -1,35 +0,0 @@
1
- ---
2
- allowed-tools: [Glob, Read]
3
- ---
4
-
5
- # Context Filtering
6
-
7
- Determine relevant files for a task.
8
-
9
- ## Process
10
-
11
- 1. **Get real extensions**: Only include what EXISTS in project
12
- 2. **Identify directories**: Based on task, not assumptions
13
- 3. **Filter by task**: What files will be modified?
14
- 4. **Exclude non-relevant**: node_modules, .git, dist, build
15
-
16
- ## Output
17
-
18
- ```json
19
- {
20
- "include": {
21
- "extensions": [".ts", ".tsx"],
22
- "directories": ["src/", "lib/"]
23
- },
24
- "exclude": {
25
- "directories": ["node_modules/", ".git/", "dist/"]
26
- },
27
- "reasoning": "why these patterns"
28
- }
29
- ```
30
-
31
- ## Rules
32
-
33
- - Use REAL extensions (not assumed)
34
- - Task-specific filtering
35
- - Efficient - focus on what matters
@@ -1,59 +0,0 @@
1
- # Skill Integration
2
-
3
- Agents integrate with Claude Code skills from claude-plugins.dev.
4
-
5
- ## Agent → Skill Mapping
6
-
7
- | Agent | Skill |
8
- |-------|-------|
9
- | frontend.md | frontend-design |
10
- | uxui.md | frontend-design |
11
- | backend.md | javascript-typescript |
12
- | testing.md | developer-kit |
13
- | devops.md | developer-kit |
14
- | prjct-planner.md | feature-dev |
15
- | prjct-shipper.md | code-review |
16
-
17
- ## Installation (during `p. sync`)
18
-
19
- 1. Check existing: `ls ~/.claude/skills/*.md`
20
- 2. Search: `https://claude-plugins.dev/skills?q={term}`
21
- 3. Prefer: @anthropics, high downloads
22
- 4. Write to: `~/.claude/skills/{name}.md`
23
- 5. Save mapping: `{globalPath}/config/skills.json`
24
-
25
- ## Agent Frontmatter
26
-
27
- ```yaml
28
- ---
29
- name: frontend
30
- description: "Frontend specialist. Use PROACTIVELY."
31
- tools: Read, Write, Glob, Grep
32
- skills: [frontend-design]
33
- ---
34
- ```
35
-
36
- ## Usage
37
-
38
- **During `p. task`**:
39
- - Load agent → invoke linked skills
40
-
41
- **During `p. ship`**:
42
- - Invoke code-review skill
43
-
44
- ## Key Skills
45
-
46
- | Skill | Purpose |
47
- |-------|---------|
48
- | frontend-design | UI components, anti-AI-slop |
49
- | javascript-typescript | Node.js, React patterns |
50
- | python-development | Django, FastAPI patterns |
51
- | feature-dev | Architecture, planning |
52
- | code-review | PR review, security |
53
- | developer-kit | Testing, DevOps |
54
-
55
- ## Troubleshooting
56
-
57
- - Skill not invoking? Check agent `skills:` frontmatter
58
- - Wrong skill? Re-run `p. sync`
59
- - Manual invoke: `/frontend-design`
@@ -1,54 +0,0 @@
1
- # Sub-Agent Generation
2
-
3
- Generate project-specific agents based on detected stack.
4
-
5
- ## Output Location
6
-
7
- `{globalPath}/agents/` (NEVER local project)
8
-
9
- ## Agent Format
10
-
11
- ```markdown
12
- ---
13
- name: agent-name
14
- description: When to use. Include "Use PROACTIVELY" for auto-invoke.
15
- tools: Read, Write, Glob, Grep, Bash
16
- model: sonnet
17
- skills: [skill-name]
18
- ---
19
- Agent prompt...
20
- ```
21
-
22
- ## Required Workflow Agents
23
-
24
- | Agent | Purpose | Skill |
25
- |-------|---------|-------|
26
- | prjct-workflow.md | Task lifecycle | - |
27
- | prjct-planner.md | Feature planning | feature-dev |
28
- | prjct-shipper.md | Git, deploy | code-review |
29
-
30
- ## Domain Agents (based on stack)
31
-
32
- | If Detected | Generate | Skill |
33
- |-------------|----------|-------|
34
- | React, Vue, CSS | frontend.md | frontend-design |
35
- | Node, Express, API | backend.md | javascript-typescript |
36
- | PostgreSQL, MongoDB | database.md | - |
37
- | Docker, CI/CD | devops.md | developer-kit |
38
- | Jest, Pytest | testing.md | developer-kit |
39
- | Any UI | uxui.md | frontend-design |
40
-
41
- ## Execution
42
-
43
- 1. Read `{globalPath}/analysis/repo-summary.md`
44
- 2. Create `{globalPath}/agents/` directory
45
- 3. Generate workflow agents (always)
46
- 4. Generate domain agents (based on analysis)
47
- 5. Add skills to frontmatter
48
- 6. Report generated agents
49
-
50
- ## Rules
51
-
52
- - **ALWAYS** write to `{globalPath}/agents/`
53
- - **NEVER** write to `.claude/` or `.prjct/`
54
- - Adapt templates to project context
@@ -1,74 +0,0 @@
1
- ---
2
- name: bug-severity
3
- description: Assess bug severity from description
4
- allowed-tools: [Read]
5
- ---
6
-
7
- # Bug Severity Assessment
8
-
9
- Analyze the bug description to determine its severity and priority.
10
-
11
- ## Input
12
- - Bug: {{description}}
13
- - Context (if available)
14
-
15
- ## Severity Levels
16
-
17
- ### CRITICAL
18
- - System crash or data loss
19
- - Security vulnerability
20
- - Blocks all users
21
- - Production is down
22
-
23
- ### HIGH
24
- - Major feature broken
25
- - Significant user impact
26
- - Workaround difficult
27
- - Affects many users
28
-
29
- ### MEDIUM
30
- - Feature partially broken
31
- - Workaround exists
32
- - Limited user impact
33
- - Non-essential functionality
34
-
35
- ### LOW
36
- - Minor inconvenience
37
- - Cosmetic issue
38
- - Edge case only
39
- - Easy workaround
40
-
41
- ## Analysis Steps
42
-
43
- 1. **Assess Impact**
44
- - Who is affected?
45
- - How many users?
46
- - Is there data loss risk?
47
-
48
- 2. **Check Urgency**
49
- - Is production affected?
50
- - Is there a deadline?
51
- - Are users blocked?
52
-
53
- 3. **Evaluate Workaround**
54
- - Can users continue working?
55
- - How hard is the workaround?
56
-
57
- ## Output Format
58
-
59
- Return JSON:
60
- ```json
61
- {
62
- "severity": "critical|high|medium|low",
63
- "priority": 1-4,
64
- "reasoning": "<brief explanation>",
65
- "suggestedAction": "<what to do next>"
66
- }
67
- ```
68
-
69
- ## Guidelines
70
-
71
- - Err on the side of higher severity if unsure
72
- - Security issues are always CRITICAL
73
- - Data loss is always CRITICAL
74
- - User-reported = add weight
@@ -1,54 +0,0 @@
1
- ---
2
- name: complexity-analysis
3
- description: Analyze task complexity semantically
4
- allowed-tools: [Read]
5
- ---
6
-
7
- # Task Complexity Analysis
8
-
9
- Analyze the given task description and determine its complexity level.
10
-
11
- ## Input
12
- - Task: {{task}}
13
- - Project context (if available)
14
-
15
- ## Analysis Steps
16
-
17
- 1. **Understand the Task**
18
- - What is being asked?
19
- - What systems/files are affected?
20
- - Are there dependencies?
21
-
22
- 2. **Evaluate Scope**
23
- - Single file change → LOW
24
- - Multiple files, same module → MEDIUM
25
- - Cross-module or architectural → HIGH
26
-
27
- 3. **Assess Risk**
28
- - Read-only or additive → LOW risk
29
- - Modifying existing logic → MEDIUM risk
30
- - Refactoring or migration → HIGH risk
31
-
32
- 4. **Consider Dependencies**
33
- - No external deps → LOW
34
- - Some integration → MEDIUM
35
- - Multiple systems → HIGH
36
-
37
- ## Output Format
38
-
39
- Return JSON:
40
- ```json
41
- {
42
- "complexity": "low|medium|high",
43
- "type": "feature|bugfix|refactor|testing|docs|chore",
44
- "estimatedHours": <number>,
45
- "reasoning": "<brief explanation>"
46
- }
47
- ```
48
-
49
- ## Guidelines
50
-
51
- - Be realistic, not optimistic
52
- - Consider testing time in estimates
53
- - If unsure, lean toward higher complexity
54
- - Don't use keyword matching - analyze semantically
@@ -1,66 +0,0 @@
1
- ---
2
- name: health-score
3
- description: Calculate project health score
4
- allowed-tools: [Read]
5
- ---
6
-
7
- # Project Health Score
8
-
9
- Evaluate the project's health based on activity metrics.
10
-
11
- ## Input
12
- - Active task: {{hasActiveTask}}
13
- - Queue size: {{queueSize}}
14
- - Recent ships: {{recentShips}}
15
- - Ideas count: {{ideasCount}}
16
- - Days since last ship: {{daysSinceShip}}
17
-
18
- ## Health Factors
19
-
20
- ### Momentum (40%)
21
- - Active task = good
22
- - Regular shipping = good
23
- - Long gaps = concerning
24
-
25
- ### Focus (30%)
26
- - Queue < 10 = focused
27
- - Queue 10-20 = busy
28
- - Queue > 20 = overloaded
29
-
30
- ### Progress (20%)
31
- - Ships this week > 0 = active
32
- - Ships this month > 2 = productive
33
- - No ships in 7+ days = stalled
34
-
35
- ### Planning (10%)
36
- - Ideas captured = thinking ahead
37
- - Too many ideas = unfocused
38
-
39
- ## Score Calculation
40
-
41
- Evaluate each factor and combine:
42
-
43
- | Score | Label | Meaning |
44
- |-------|-------|---------|
45
- | 80-100 | Excellent | High momentum, focused, shipping |
46
- | 60-79 | Good | Active, some room to improve |
47
- | 40-59 | Fair | Slowing down, needs attention |
48
- | 0-39 | Low | Stalled, intervention needed |
49
-
50
- ## Output Format
51
-
52
- Return JSON:
53
- ```json
54
- {
55
- "score": <0-100>,
56
- "label": "Excellent|Good|Fair|Low",
57
- "momentum": "<assessment>",
58
- "suggestions": ["<action 1>", "<action 2>"]
59
- }
60
- ```
61
-
62
- ## Guidelines
63
-
64
- - Be encouraging but honest
65
- - Suggest specific actions
66
- - Focus on momentum, not perfection
@@ -1,66 +0,0 @@
1
- ---
2
- name: intent-detection
3
- description: Detect user intent from natural language
4
- allowed-tools: []
5
- ---
6
-
7
- # Intent Detection
8
-
9
- Analyze user input to determine their intent and map to appropriate action.
10
-
11
- ## Input
12
- - User message: {{message}}
13
-
14
- ## Intent Categories
15
-
16
- ### Work Intents
17
- - **start_task**: User wants to begin working on something
18
- - **complete_task**: User finished current work
19
- - **ship**: User wants to release/deploy
20
- - **pause**: User needs to pause current work
21
-
22
- ### Planning Intents
23
- - **add_feature**: User has a new feature idea
24
- - **add_idea**: Quick thought to capture
25
- - **add_bug**: Report a problem
26
- - **view_queue**: See what's next
27
-
28
- ### Status Intents
29
- - **check_progress**: View metrics/status
30
- - **get_recap**: Project overview
31
- - **get_help**: Need guidance
32
-
33
- ### System Intents
34
- - **sync**: Update project state
35
- - **analyze**: Analyze codebase
36
- - **cleanup**: Clean up files
37
-
38
- ## Analysis
39
-
40
- Look for semantic meaning, not keywords:
41
- - "I'm done" → complete_task
42
- - "Let's ship this" → ship
43
- - "Quick thought..." → add_idea
44
- - "What should I do?" → get_help OR view_queue
45
-
46
- ## Output Format
47
-
48
- Return JSON:
49
- ```json
50
- {
51
- "intent": "<intent_name>",
52
- "confidence": <0.0-1.0>,
53
- "parameters": {
54
- "task": "<extracted task if any>",
55
- "feature": "<extracted feature if any>"
56
- },
57
- "suggestedCommand": "/p:<command>"
58
- }
59
- ```
60
-
61
- ## Guidelines
62
-
63
- - Use semantic understanding, not regex
64
- - Extract relevant parameters
65
- - High confidence (>0.8) for clear intents
66
- - Ask for clarification if < 0.5
@@ -1,53 +0,0 @@
1
- ---
2
- name: task-breakdown
3
- description: Break down a feature into actionable tasks
4
- allowed-tools: [Read, Glob, Grep]
5
- ---
6
-
7
- # Feature Task Breakdown
8
-
9
- Analyze the feature description and break it into concrete, actionable tasks.
10
-
11
- ## Input
12
- - Feature: {{feature}}
13
- - Project path: {{projectPath}}
14
-
15
- ## Analysis Steps
16
-
17
- 1. **Understand the Feature**
18
- - Read related code if paths are obvious
19
- - Identify affected systems
20
- - Note existing patterns to follow
21
-
22
- 2. **Identify Components**
23
- - What new files/modules are needed?
24
- - What existing code needs modification?
25
- - What tests are required?
26
-
27
- 3. **Order by Dependencies**
28
- - Foundation tasks first (models, types, interfaces)
29
- - Core logic second
30
- - Integration third
31
- - Tests and polish last
32
-
33
- 4. **Size Each Task**
34
- - Each task should be 20-60 minutes
35
- - If larger, break down further
36
- - If smaller, combine with related task
37
-
38
- ## Output Format
39
-
40
- Return a numbered task list:
41
- ```
42
- 1. [20m] Task description - specific action
43
- 2. [30m] Another task - what exactly to do
44
- 3. [45m] Final task - clear deliverable
45
- ```
46
-
47
- ## Guidelines
48
-
49
- - Tasks must be specific and actionable
50
- - Include time estimates in brackets
51
- - Order matters - dependencies first
52
- - Don't assume - if unsure, read code first
53
- - Match project patterns (read existing code)