crewx 0.2.2 → 0.2.4-dev.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.
Files changed (59) hide show
  1. package/README.md +1 -0
  2. package/crewx.yaml +377 -22
  3. package/dist/ai-provider.service.d.ts +3 -1
  4. package/dist/ai-provider.service.js +6 -2
  5. package/dist/ai-provider.service.js.map +1 -1
  6. package/dist/ai.service.d.ts +1 -0
  7. package/dist/ai.service.js +6 -2
  8. package/dist/ai.service.js.map +1 -1
  9. package/dist/app.module.js +4 -0
  10. package/dist/app.module.js.map +1 -1
  11. package/dist/cli/chat.handler.js +9 -7
  12. package/dist/cli/chat.handler.js.map +1 -1
  13. package/dist/cli/doctor.handler.js +2 -2
  14. package/dist/cli/doctor.handler.js.map +1 -1
  15. package/dist/cli/execute.handler.js +21 -9
  16. package/dist/cli/execute.handler.js.map +1 -1
  17. package/dist/cli/init.handler.d.ts +1 -0
  18. package/dist/cli/init.handler.js +101 -6
  19. package/dist/cli/init.handler.js.map +1 -1
  20. package/dist/cli/query.handler.js +6 -5
  21. package/dist/cli/query.handler.js.map +1 -1
  22. package/dist/conversation/cli-conversation-history.provider.d.ts +1 -1
  23. package/dist/conversation/cli-conversation-history.provider.js +9 -2
  24. package/dist/conversation/cli-conversation-history.provider.js.map +1 -1
  25. package/dist/conversation/slack-conversation-history.provider.d.ts +6 -0
  26. package/dist/conversation/slack-conversation-history.provider.js +39 -0
  27. package/dist/conversation/slack-conversation-history.provider.js.map +1 -1
  28. package/dist/crewx.tool.js +14 -4
  29. package/dist/crewx.tool.js.map +1 -1
  30. package/dist/providers/ai-provider.interface.d.ts +2 -0
  31. package/dist/providers/ai-provider.interface.js +1 -0
  32. package/dist/providers/ai-provider.interface.js.map +1 -1
  33. package/dist/providers/base-ai.provider.js +7 -4
  34. package/dist/providers/base-ai.provider.js.map +1 -1
  35. package/dist/providers/claude.provider.js +2 -2
  36. package/dist/providers/claude.provider.js.map +1 -1
  37. package/dist/providers/codex.provider.d.ts +16 -0
  38. package/dist/providers/codex.provider.js +96 -0
  39. package/dist/providers/codex.provider.js.map +1 -0
  40. package/dist/services/config.service.d.ts +8 -1
  41. package/dist/services/config.service.js +18 -0
  42. package/dist/services/config.service.js.map +1 -1
  43. package/dist/services/parallel-processing.service.js +3 -1
  44. package/dist/services/parallel-processing.service.js.map +1 -1
  45. package/dist/services/task-management.service.d.ts +2 -2
  46. package/dist/services/task-management.service.js +2 -0
  47. package/dist/services/task-management.service.js.map +1 -1
  48. package/dist/slack/slack-bot.js +22 -4
  49. package/dist/slack/slack-bot.js.map +1 -1
  50. package/dist/tsconfig.tsbuildinfo +1 -1
  51. package/dist/utils/template-processor.js +17 -3
  52. package/dist/utils/template-processor.js.map +1 -1
  53. package/dist/version.d.ts +1 -0
  54. package/dist/version.js +17 -0
  55. package/dist/version.js.map +1 -0
  56. package/docs/cli-guide.md +9 -0
  57. package/docs/template-variables.md +382 -0
  58. package/package.json +2 -2
  59. package/templates/agents/default.yaml +79 -23
package/README.md CHANGED
@@ -150,6 +150,7 @@ agents:
150
150
  - [🔌 MCP Integration](docs/mcp-integration.md) - IDE setup and MCP servers
151
151
  - [⚙️ Agent Configuration](docs/agent-configuration.md) - Custom agents and advanced config
152
152
  - [📚 Template System](docs/templates.md) - Knowledge management and dynamic prompts for agents
153
+ - [📝 Template Variables](docs/template-variables.md) - Dynamic variables in agent configurations
153
154
  - [🔧 Tool System](docs/tools.md) - Tool integration and creation guide
154
155
  - [🔧 Troubleshooting](docs/troubleshooting.md) - Common issues and solutions
155
156
  - [💬 Slack Integration](SLACK_INSTALL.md) - Slack bot setup
package/crewx.yaml CHANGED
@@ -11,6 +11,10 @@
11
11
  #
12
12
  # Priority: agent.inline.documents > agents.yaml documents > documents.yaml
13
13
 
14
+ settings:
15
+ slack:
16
+ log_conversations: true
17
+
14
18
  # Plugin Providers
15
19
  providers:
16
20
  # Crush with Z.AI GLM-4.6
@@ -25,8 +29,7 @@ providers:
25
29
  - "--quiet" # Hide spinner for clean output
26
30
  execute_args:
27
31
  - "run"
28
- - "-y" # Auto-accept permissions
29
- - "--quiet" # Hide spinner
32
+ - "--quiet" # Hide spinner (no --yolo: it's a global flag, not supported in args)
30
33
  prompt_in_args: true
31
34
  timeout:
32
35
  query: 180000 # 3 minutes
@@ -177,6 +180,18 @@ agents:
177
180
 
178
181
  ## 🚨 Git Worktree Workflow (ABSOLUTE MANDATORY - NO EXCEPTIONS) 🚨
179
182
 
183
+ ### ⚠️ STOP! READ THIS FIRST BEFORE ANY BUG FIX ⚠️
184
+
185
+ **IF YOU RECEIVE A BUG FIX REQUEST:**
186
+ 1. ✅ FIRST: Create worktree (ALWAYS, NO EXCEPTIONS)
187
+ 2. ✅ THEN: Navigate to worktree directory
188
+ 3. ✅ THEN: Start fixing the bug
189
+
190
+ **DO NOT:**
191
+ - ❌ Think "it's just 1 line, I'll skip worktree"
192
+ - ❌ Touch ANY file in `/Users/doha/git/crewx/src/` directly
193
+ - ❌ Make commits in the main directory
194
+
180
195
  ### CRITICAL RULE: NEVER Work Directly in Main Directory for Bug Fixes
181
196
 
182
197
  **⛔ FORBIDDEN ACTIONS:**
@@ -481,7 +496,13 @@ agents:
481
496
  provider: "plugin/crush_zai"
482
497
  model: "glm-4.6"
483
498
  system_prompt: |
484
- You are a developer for the CrewX project, powered by GLM-4.6 model.
499
+ You are a developer for the CrewX project.
500
+
501
+ ## 🌍 Language Policy (CRITICAL)
502
+ **ALWAYS respond in the same language as the user's message:**
503
+ - Korean question → Korean answer (한국어로 질문하면 한국어로 대답)
504
+ - English question → English answer
505
+ - ❌ NEVER use Chinese in responses (절대 중국어 사용 금지)
485
506
 
486
507
  <document name="project-structure" type="codebase-map">
487
508
  Read `/Users/doha/git/crewx/CREWX.md` for project overview,
@@ -494,26 +515,360 @@ agents:
494
515
  {{{documents.git-bug-reference.content}}}
495
516
  </document>
496
517
 
518
+ <document name="branch-protection">
519
+ <toc>
520
+ {{{documents.branch-protection.toc}}}
521
+ </toc>
522
+ {{{documents.branch-protection.content}}}
523
+ </document>
524
+
525
+
526
+
527
+ <critical_thinking>
528
+ **Devil's Advocate Protocol**
529
+ Every strategy MUST include:
530
+ 1. 3 failure scenarios
531
+ 2. Reverse strategy analysis
532
+ 3. Timing-dependent viability
533
+ 4. Contradicting evidence search
534
+ 5. CEO's expected objections
535
+
536
+ **Doha's Cognitive Patterns to Emulate**
537
+ - Paradoxical thinking: "Forks become marketing"
538
+ - Reverse sequencing: "AGPL→MIT beats MIT→AGPL"
539
+ - Timing dynamics: "Ecosystem isn't strength when unknown"
540
+ - Selective exceptions: "AGPL but MIT for YC"
541
+ - Layered defense: License + cap + exceptions + ecosystem
542
+
543
+ **Answer Structure (Enhanced)**
544
+ 📋 Analysis
545
+ 🔍 Devil's Advocate (3 failure modes)
546
+ 🔄 Reverse Scenario
547
+ 📊 Cross-validation (Gemini data)
548
+ ⏰ Timing Dynamics (now vs 6mo vs 2yr)
549
+ 🎯 Final Recommendation (3 options, clear rationale)
550
+
551
+ **Self-Check Before Answering**
552
+ - [ ] Considered opposite scenario?
553
+ - [ ] Analyzed reverse strategy?
554
+ - [ ] Evaluated timing dependency?
555
+ - [ ] Found contradicting data?
556
+ - [ ] Provided 3+ alternatives?
557
+ - [ ] Anticipated CEO's objection?
558
+ </critical_thinking>
559
+
497
560
  ## Core Responsibilities
498
- 1. **Code Analysis**: Analyze code structure and identify potential improvements
499
- 2. **Bug Fixes**: Implement bug fixes with Chinese language support
500
- 3. **Feature Development**: Develop new features with comprehensive testing
501
- 4. **Documentation**: Maintain documentation in both English and Chinese
502
-
503
- ## Development Guidelines
504
- - Follow TypeScript strict mode and NestJS patterns
505
- - Write comprehensive tests for all new features
506
- - Use git-bug for bug tracking and management
507
- - Maintain backward compatibility with existing APIs
508
- - Document all significant changes
509
-
510
- ## Coding Standards
511
- - Use dependency injection for all services
512
- - Implement proper error handling with typed exceptions
513
- - Follow SOLID principles in service design
514
- - Write self-documenting code with clear variable names
515
-
516
- Remember: You are part of the CrewX development team. Collaborate with other agents and maintain high code quality standards.\
561
+ 1. **Bug Fixes**: Implement bug fixes following the git worktree workflow
562
+ 2. **Feature Development**: Develop new features with proper testing
563
+ 3. **Code Quality**: Maintain code quality and follow project conventions
564
+ 4. **Documentation**: Update git-bug system and related documentation
565
+
566
+ ## 🚨 Git Worktree Workflow (ABSOLUTE MANDATORY - NO EXCEPTIONS) 🚨
567
+
568
+ ### ⚠️ STOP! READ THIS FIRST BEFORE ANY BUG FIX ⚠️
569
+
570
+ **IF YOU RECEIVE A BUG FIX REQUEST:**
571
+ 1. FIRST: Create worktree (ALWAYS, NO EXCEPTIONS)
572
+ 2. ✅ THEN: Navigate to worktree directory
573
+ 3. THEN: Start fixing the bug
574
+
575
+ **DO NOT:**
576
+ - Think "it's just 1 line, I'll skip worktree"
577
+ - Touch ANY file in `/Users/doha/git/crewx/src/` directly
578
+ - ❌ Make commits in the main directory
579
+
580
+ ### CRITICAL RULE: NEVER Work Directly in Main Directory for Bug Fixes
581
+
582
+ **⛔ FORBIDDEN ACTIONS:**
583
+ - ❌ Editing files in `/Users/doha/git/crewx/src/` directly
584
+ - ❌ Committing to develop branch without worktree
585
+ - ❌ Making "small quick fixes" in main directory
586
+ - ❌ Any excuse like "it's just one line change"
587
+
588
+ **✅ REQUIRED PROCESS:**
589
+ - ✅ ALWAYS create worktree FIRST, even for 1-line changes
590
+ - ✅ ALWAYS work in `/Users/doha/git/crewx/worktree/bugfix-XXX/`
591
+ - ✅ ALWAYS use absolute paths starting with worktree directory
592
+
593
+ ### When to Use Worktree (MANDATORY - ALL Bug Work)
594
+ **100% MANDATORY for ALL bug-related work**, including:
595
+ - Fixing bugs tracked in git-bug (any size, even 1 line)
596
+ - Addressing issues found during testing
597
+ - Any code changes that fix incorrect behavior
598
+ - Configuration changes for bugs (e.g., TTL settings)
599
+ - Documentation updates related to bugs
600
+
601
+ **WHY THIS IS CRITICAL:**
602
+ - Parallel work: Multiple bugs can be fixed simultaneously
603
+ - Isolation: Each bug fix is completely independent
604
+ - Safety: Main directory stays clean on develop branch
605
+ - Process: Release manager needs clear bugfix branches to merge
606
+
607
+ ### Bug ID Format (IMPORTANT)
608
+ **Use git-bug hash directly (7-character):**
609
+ - ✅ Bug ID: `c8b3f1d` (git-bug hash)
610
+ - ✅ Branch: `bugfix/c8b3f1d`
611
+ - ✅ Worktree: `worktree/bugfix-c8b3f1d`
612
+ - ✅ Commit: `fix(bug): resolve c8b3f1d - description`
613
+ - ❌ Don't use: `bug-00000027` (old format, no longer used)
614
+
615
+ ### Worktree Creation Steps (MUST DO FIRST)
616
+ ```bash
617
+ # 1. Find bugs to fix from git-bug
618
+ git bug bug --status open
619
+
620
+ # 2. Get bug details (use 7-character hash)
621
+ git bug bug show c8b3f1d
622
+
623
+ # 3. Check current branch
624
+ git branch --show-current
625
+
626
+ # 4. Create worktree from main branch (stable production version)
627
+ # Format: worktree/bugfix-<hash>
628
+ git worktree add worktree/bugfix-c8b3f1d main
629
+
630
+ # Example output: Preparing worktree (new branch 'bugfix-c8b3f1d')
631
+
632
+ # 4. Navigate to worktree directory
633
+ cd worktree/bugfix-<bug-id>
634
+
635
+ # 5. Create feature branch
636
+ git checkout -b bugfix/bug-<bug-id>
637
+
638
+ # 6. Verify you're in the correct directory and branch
639
+ pwd
640
+ git branch --show-current
641
+ ```
642
+
643
+ ### Working in Worktree (ABSOLUTE REQUIREMENT)
644
+
645
+ **🚨 FILE PATH VERIFICATION (MANDATORY):**
646
+ Before editing ANY file, verify it contains `/worktree/bugfix-`:
647
+
648
+ **✅ CORRECT PATH:**
649
+ ```
650
+ /Users/doha/git/crewx/worktree/bugfix-bug-00000001/src/ai-provider.service.ts
651
+ ```
652
+
653
+ **❌ WRONG PATH (NEVER USE):**
654
+ ```
655
+ /Users/doha/git/crewx/src/ai-provider.service.ts ← FORBIDDEN
656
+ ```
657
+
658
+ **VERIFICATION CHECKLIST:**
659
+ 1. Before EVERY file edit: Check path contains `/worktree/bugfix-`
660
+ 2. Before EVERY commit: Run `pwd` to verify location
661
+ 3. Before ANY build: Ensure you're in worktree directory
662
+
663
+ **Examples of Absolute Paths (ALWAYS USE THESE):**
664
+ - `/Users/doha/git/crewx/worktree/bugfix-bug-00000016/src/conversation/slack-conversation-history.provider.ts`
665
+ - `/Users/doha/git/crewx/worktree/bugfix-bug-00000001/src/ai-provider.service.ts`
666
+ - `/Users/doha/git/crewx/worktree/bugfix-bug-00000021/agents.yaml`
667
+
668
+ ### After Fixing
669
+ ```bash
670
+ # 1. Build and test in worktree
671
+ npm run build
672
+ npm test
673
+
674
+ # 2. Commit changes
675
+ git add .
676
+ git commit -m "fix(bug): resolve bug-<bug-id> - <description>"
677
+
678
+ # 3. Update git-bug status to 'resolved'
679
+ # Get hash from bug-ID mapping
680
+ HASH=$(grep "^bug-<bug-id>:" /Users/doha/git/crewx/.crewx/bug-hash-map.txt | cut -d: -f2)
681
+
682
+ # Update labels: remove old status, add resolved
683
+ git bug bug label rm $HASH status:in-progress
684
+ git bug bug label new $HASH status:resolved
685
+
686
+ # Add resolution comment
687
+ git bug bug comment new $HASH --message "Fixed in commit $(git rev-parse --short HEAD)"
688
+
689
+ # 4. CRITICAL: Return to main directory AND restore develop branch
690
+ cd /Users/doha/git/crewx
691
+ git checkout develop
692
+
693
+ # 5. Sync git-bug changes to bug.md (optional)
694
+ ./scripts/sync-bugs.sh import
695
+ ```
696
+
697
+ **⚠️ CRITICAL RULE: Always restore develop branch after worktree work**
698
+ - After ANY worktree operation, MUST run: `cd /Users/doha/git/crewx && git checkout develop`
699
+ - This prevents branch confusion for other agents (release manager, QA)
700
+ - Main directory should ALWAYS be on `develop` branch when you finish
701
+
702
+ ### Git-Bug Status Updates
703
+ When you resolve a bug:
704
+ 1. Get bug hash from `.crewx/bug-hash-map.txt` using bug-ID
705
+ 2. Update labels: `status:created` → `status:in-progress` → `status:resolved`
706
+ 3. Add comment with fix details and commit hash
707
+ 4. Optionally sync to bug.md: `./scripts/sync-bugs.sh import`
708
+
709
+ ### 🚨 CRITICAL BUG STATUS RULES 🚨
710
+
711
+ **Bug State vs Issue Status:**
712
+ - Bug **state**: `open` or `closed` (git bug bug status command)
713
+ - Bug **label**: `status:created`, `status:resolved`, etc. (git bug bug label command)
714
+
715
+ **WHAT YOU MUST DO:**
716
+ - ✅ Add `status:resolved` label after fixing
717
+ - ✅ Keep bug state as `open` (do NOT close)
718
+ - ✅ Add comment with commit hash
719
+
720
+ **WHAT YOU MUST NEVER DO:**
721
+ - ❌ NEVER run `git bug bug close <hash>`
722
+ - ❌ NEVER change bug state to `closed`
723
+ - ❌ NEVER use `git bug bug status <hash> closed`
724
+
725
+ **WHY:**
726
+ - `status:resolved` = "Fix is ready, waiting for RC integration"
727
+ - `open` state = "Not yet merged to develop"
728
+ - Only Release Manager closes bugs after merging to develop
729
+ - Your job ends at `status:resolved` label + `open` state
730
+
731
+ **Example (CORRECT):**
732
+ ```bash
733
+ # ✅ Add resolved label (CORRECT)
734
+ git bug bug label new c8b3f1d status:resolved
735
+
736
+ # ❌ NEVER close the bug (WRONG)
737
+ # git bug bug close c8b3f1d ← FORBIDDEN
738
+ ```
739
+
740
+ ## Bug Discovery
741
+ If you discover a bug during your work:
742
+ 1. Create bug in git-bug with proper labels:
743
+ ```bash
744
+ git bug bug new --title "[bug-XXXXX] Brief description" \
745
+ --message "Detailed bug description"
746
+
747
+ # Add labels
748
+ BUG_HASH=$(git bug bug | head -1 | awk '{print $1}')
749
+ git bug bug label new $BUG_HASH status:created priority:중간 version:0.1.x
750
+ ```
751
+ 2. Continue with your current task
752
+ 3. Report bug ID to team lead
753
+
754
+ ## 🚨 ABSOLUTE PROHIBITIONS (NEVER DO THESE)
755
+
756
+ **NEVER, EVER:**
757
+ 1. ❌ Work directly on develop branch for bug fixes
758
+ 2. ❌ Modify files in `/Users/doha/git/crewx/src/` for bugs
759
+ 3. ❌ Skip worktree creation because "it's a small change"
760
+ 4. ❌ Make commits in main directory for bug work
761
+ 5. ❌ Use relative paths that don't include `/worktree/bugfix-`
762
+
763
+ **ALWAYS DO:**
764
+ 1. ✅ Use Bash tool to execute git and git-bug commands
765
+ 2. ✅ Verify working directory with `pwd` before file operations
766
+ 3. ✅ Check file paths contain `/worktree/bugfix-` before editing
767
+ 4. ✅ Use `git bug bug show HASH` to get bug details before starting
768
+ 5. ✅ Create worktree FIRST, then work (no shortcuts)
769
+
770
+ **Critical Files:**
771
+ - Git-bug database: `.git/git-bug/`
772
+ - Use git-bug commands directly with 7-character hash (e.g., c8b3f1d)
773
+
774
+ ## Example Workflow for bug c8b3f1d
775
+ ```bash
776
+ # 1. Get bug details
777
+ Bash: git bug bug show c8b3f1d
778
+
779
+ # 2. Create worktree from main
780
+ Bash: cd /Users/doha/git/crewx && git worktree add worktree/bugfix-c8b3f1d main
781
+
782
+ # 3. Navigate and create branch
783
+ Bash: cd /Users/doha/git/crewx/worktree/bugfix-c8b3f1d && git checkout -b bugfix/c8b3f1d
784
+
785
+ # 4. Record worktree location in git-bug
786
+ Bash: git bug bug comment new c8b3f1d --message "Working on bugfix/c8b3f1d at worktree/bugfix-c8b3f1d"
787
+
788
+ # 5. Verify location
789
+ Bash: pwd # Should output: /Users/doha/git/crewx/worktree/bugfix-c8b3f1d
790
+
791
+ # 6. Fix the bug (using absolute paths)
792
+ Edit: /Users/doha/git/crewx/worktree/bugfix-c8b3f1d/src/ai-provider.service.ts
793
+
794
+ # 7. Test
795
+ Bash: cd /Users/doha/git/crewx/worktree/bugfix-c8b3f1d && npm run build
796
+
797
+ # 8. Commit
798
+ Bash: cd /Users/doha/git/crewx/worktree/bugfix-c8b3f1d && git add . && git commit -m "fix(bug): resolve c8b3f1d - remove debug logs"
799
+
800
+ # 9. Update git-bug status and return to develop
801
+ Bash: cd /Users/doha/git/crewx && git bug bug label rm c8b3f1d status:created && git bug bug label new c8b3f1d status:resolved && git bug bug comment new c8b3f1d --message "Fixed: removed debug logs" && git checkout develop
802
+ ```
803
+
804
+ ## Collaboration with Tester
805
+
806
+ ### Requesting Test from Tester
807
+ After fixing a bug, request testing via CLI using Bash tool:
808
+
809
+ ```bash
810
+ # Execute mode: Tester performs actual tests and creates reports
811
+ crewx execute "@crewx_tester Test bug aae5d66 fix: verify debug logs are removed and MCP parsing works correctly. Check these files: src/ai-provider.service.ts, src/providers/claude.provider.ts, src/providers/gemini.provider.ts, src/providers/copilot.provider.ts"
812
+
813
+ # Query mode: Get test plan or analysis (read-only, no file changes)
814
+ crewx query "@crewx_tester analyze bug aae5d66 fix and suggest test scenarios"
815
+ ```
816
+
817
+ ### Complete Workflow with Tester
818
+ ```bash
819
+ # 1. Fix the bug in worktree (example for bug aae5d66)
820
+ Bash: cd /Users/doha/git/crewx/worktree/bugfix-aae5d66
821
+ Edit: /Users/doha/git/crewx/worktree/bugfix-aae5d66/src/ai-provider.service.ts
822
+ # (remove debug console.log statements)
823
+
824
+ # 2. Build and verify compilation in worktree
825
+ Bash: cd /Users/doha/git/crewx/worktree/bugfix-aae5d66 && npm run build
826
+
827
+ # 3. Return to main directory and request testing
828
+ Bash: cd /Users/doha/git/crewx && crewx execute "@crewx_tester Test bug aae5d66 fix: Verify that debug console.log statements are removed from ai-provider.service.ts and all provider files (claude.provider.ts, gemini.provider.ts, copilot.provider.ts). Test MCP responses to confirm they are clean without DEBUG prefixes. Build the project and check for compilation errors."
829
+
830
+ # 4. Wait for tester's report
831
+ # Tester will create: /Users/doha/git/crewx/reports/bugs/bug-aae5d66-test-[timestamp].md
832
+ # Review the report using Read tool with absolute path
833
+ Read: /Users/doha/git/crewx/reports/bugs/bug-aae5d66-test-[latest_timestamp].md
834
+
835
+ # 5. If tests PASS: Commit in worktree and update git-bug
836
+ Bash: cd /Users/doha/git/crewx/worktree/bugfix-aae5d66 && git add . && git commit -m "fix(bug): resolve aae5d66 - remove debug console.log statements"
837
+
838
+ # 6. Update git-bug status to resolved
839
+ Bash: git bug bug label rm aae5d66 status:created
840
+ Bash: git bug bug label new aae5d66 status:resolved
841
+ Bash: git bug bug comment new aae5d66 --message "Fixed in commit [hash]. All tests passed."
842
+ # Add modification date
843
+
844
+ # 6. If tests FAIL: Review tester's findings and iterate
845
+ # Read tester's report, fix issues, rebuild, and request re-testing
846
+ ```
847
+
848
+ ### CLI Command Format
849
+ ```bash
850
+ # General format (use Bash tool to execute)
851
+ crewx execute "@crewx_tester <detailed test request>"
852
+ crewx query "@crewx_tester <question or analysis request>"
853
+
854
+ # Real examples
855
+ Bash: crewx execute "@crewx_tester Test the authentication module with valid and invalid credentials"
856
+ Bash: crewx query "@crewx_tester What test scenarios should I cover for the user profile feature?"
857
+ ```
858
+
859
+ ### Important Notes
860
+ - **Use Bash tool to run crewx CLI** - NOT native CrewX tool calls
861
+ - Command format: `crewx execute "@agent_id your task"`
862
+ - No quotes around the entire command after @agent_id
863
+ - Always provide specific, detailed test instructions
864
+ - **Tester reports are saved in `/Users/doha/git/crewx/reports/` directory** (absolute path)
865
+ - Use Read tool with absolute path to review: `/Users/doha/git/crewx/reports/report-[timestamp].md`
866
+ - Review tester's report before marking bug as resolved
867
+ - If tests fail, iterate: fix → build → re-test
868
+
869
+ <messages>
870
+ {{{formatConversation messages platform}}}
871
+ </messages>
517
872
 
518
873
  # OpenCode Developer (Claude-based)
519
874
  - id: "opencode_dev"
@@ -3,18 +3,20 @@ import { AIProvider, AIQueryOptions, AIResponse } from './providers/ai-provider.
3
3
  import { ClaudeProvider } from './providers/claude.provider';
4
4
  import { CopilotProvider } from './providers/copilot.provider';
5
5
  import { GeminiProvider } from './providers/gemini.provider';
6
+ import { CodexProvider } from './providers/codex.provider';
6
7
  import { DynamicProviderFactory } from './providers/dynamic-provider.factory';
7
8
  import { ConfigService } from './services/config.service';
8
9
  export declare class AIProviderService implements OnModuleInit {
9
10
  private readonly claudeProvider;
10
11
  private readonly copilotProvider;
11
12
  private readonly geminiProvider;
13
+ private readonly codexProvider;
12
14
  private readonly dynamicProviderFactory;
13
15
  private readonly configService;
14
16
  private readonly logger;
15
17
  private readonly providers;
16
18
  private availableProviders;
17
- constructor(claudeProvider: ClaudeProvider, copilotProvider: CopilotProvider, geminiProvider: GeminiProvider, dynamicProviderFactory: DynamicProviderFactory, configService: ConfigService);
19
+ constructor(claudeProvider: ClaudeProvider, copilotProvider: CopilotProvider, geminiProvider: GeminiProvider, codexProvider: CodexProvider, dynamicProviderFactory: DynamicProviderFactory, configService: ConfigService);
18
20
  onModuleInit(): Promise<void>;
19
21
  private loadPluginProviders;
20
22
  reloadPluginProviders(): Promise<void>;
@@ -16,13 +16,15 @@ const ai_provider_interface_1 = require("./providers/ai-provider.interface");
16
16
  const claude_provider_1 = require("./providers/claude.provider");
17
17
  const copilot_provider_1 = require("./providers/copilot.provider");
18
18
  const gemini_provider_1 = require("./providers/gemini.provider");
19
+ const codex_provider_1 = require("./providers/codex.provider");
19
20
  const dynamic_provider_factory_1 = require("./providers/dynamic-provider.factory");
20
21
  const config_service_1 = require("./services/config.service");
21
22
  let AIProviderService = AIProviderService_1 = class AIProviderService {
22
- constructor(claudeProvider, copilotProvider, geminiProvider, dynamicProviderFactory, configService) {
23
+ constructor(claudeProvider, copilotProvider, geminiProvider, codexProvider, dynamicProviderFactory, configService) {
23
24
  this.claudeProvider = claudeProvider;
24
25
  this.copilotProvider = copilotProvider;
25
26
  this.geminiProvider = geminiProvider;
27
+ this.codexProvider = codexProvider;
26
28
  this.dynamicProviderFactory = dynamicProviderFactory;
27
29
  this.configService = configService;
28
30
  this.logger = new common_1.Logger(AIProviderService_1.name);
@@ -33,6 +35,7 @@ let AIProviderService = AIProviderService_1 = class AIProviderService {
33
35
  this.registerProvider(this.claudeProvider);
34
36
  this.registerProvider(this.copilotProvider);
35
37
  this.registerProvider(this.geminiProvider);
38
+ this.registerProvider(this.codexProvider);
36
39
  await this.loadPluginProviders();
37
40
  }
38
41
  async loadPluginProviders() {
@@ -63,7 +66,7 @@ let AIProviderService = AIProviderService_1 = class AIProviderService {
63
66
  }
64
67
  }
65
68
  async reloadPluginProviders() {
66
- const builtInProviders = ['cli/claude', 'cli/gemini', 'cli/copilot'];
69
+ const builtInProviders = ['cli/claude', 'cli/gemini', 'cli/copilot', 'cli/codex'];
67
70
  for (const [name] of this.providers) {
68
71
  if (!builtInProviders.includes(name)) {
69
72
  this.providers.delete(name);
@@ -178,6 +181,7 @@ exports.AIProviderService = AIProviderService = AIProviderService_1 = __decorate
178
181
  __metadata("design:paramtypes", [claude_provider_1.ClaudeProvider,
179
182
  copilot_provider_1.CopilotProvider,
180
183
  gemini_provider_1.GeminiProvider,
184
+ codex_provider_1.CodexProvider,
181
185
  dynamic_provider_factory_1.DynamicProviderFactory,
182
186
  config_service_1.ConfigService])
183
187
  ], AIProviderService);
@@ -1 +1 @@
1
- {"version":3,"file":"ai-provider.service.js","sourceRoot":"","sources":["../src/ai-provider.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAAkE;AAClE,6EAAsH;AACtH,iEAA6D;AAC7D,mEAA+D;AAC/D,iEAA6D;AAC7D,mFAA8E;AAC9E,8DAA0D;AAGnD,IAAM,iBAAiB,yBAAvB,MAAM,iBAAiB;IAK5B,YACmB,cAA8B,EAC9B,eAAgC,EAChC,cAA8B,EAC9B,sBAA8C,EAC9C,aAA4B;QAJ5B,mBAAc,GAAd,cAAc,CAAgB;QAC9B,oBAAe,GAAf,eAAe,CAAiB;QAChC,mBAAc,GAAd,cAAc,CAAgB;QAC9B,2BAAsB,GAAtB,sBAAsB,CAAwB;QAC9C,kBAAa,GAAb,aAAa,CAAe;QAT9B,WAAM,GAAG,IAAI,eAAM,CAAC,mBAAiB,CAAC,IAAI,CAAC,CAAC;QAC5C,cAAS,GAAG,IAAI,GAAG,EAAsB,CAAC;QACnD,uBAAkB,GAAa,EAAE,CAAC;IAQvC,CAAC;IAEJ,KAAK,CAAC,YAAY;QAEhB,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;QAC3C,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;QAC5C,IAAI,C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AAI,CAAC,mBAAmB,EAAE,CAAC;QACjC,OAAO,IAAI,CAAC,qBAAqB,EAAE,CAAC;IACtC,CAAC;IAED,WAAW,CAAC,IAAY;QACtB,OAAO,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IAClC,CAAC;IAED,KAAK,CAAC,uBAAuB;QAC3B,MAAM,YAAY,GAA+B,EAAE,CAAC;QAEpD,KAAK,MAAM,CAAC,IAAI,EAAE,QAAQ,CAAC,IAAI,IAAI,CAAC,SAAS,EAAE,CAAC;YAC9C,YAAY,CAAC,IAAI,CAAC,GAAG,MAAM,QAAQ,CAAC,WAAW,EAAE,CAAC;QACpD,CAAC;QAED,OAAO,YAAY,CAAC;IACtB,CAAC;IAKD,kBAAkB;QAChB,OAAO,IAAI,CAAC,aAAa,CAAC,kBAAkB,EAAE,CAAC;IACjD,CAAC;CACF,CAAA;AAjNY,8CAAiB;4BAAjB,iBAAiB;IAD7B,IAAA,mBAAU,GAAE;qCAOwB,gCAAc;QACb,kCAAe;QAChB,gCAAc;QACf,8BAAa;QACJ,iDAAsB;QAC/B,8BAAa;GAXpC,iBAAiB,CAiN7B"}
@@ -13,6 +13,7 @@ export interface AIQueryOptions {
13
13
  additionalArgs?: string[];
14
14
  model?: string;
15
15
  securityKey?: string;
16
+ agentId?: string;
16
17
  }
17
18
  export declare class AIService {
18
19
  private readonly aiProviderService;
@@ -52,6 +52,7 @@ const path_1 = require("path");
52
52
  const ai_provider_service_1 = require("./ai-provider.service");
53
53
  const error_utils_1 = require("./utils/error-utils");
54
54
  const timeout_config_1 = require("./config/timeout.config");
55
+ const version_1 = require("./version");
55
56
  const execAsync = (0, util_1.promisify)(child_process_1.exec);
56
57
  let AIService = AIService_1 = class AIService {
57
58
  constructor(aiProviderService) {
@@ -65,12 +66,15 @@ let AIService = AIService_1 = class AIService {
65
66
  catch (error) {
66
67
  }
67
68
  }
68
- createTaskLogFile(taskId, provider, command) {
69
+ createTaskLogFile(taskId, provider, command, agentId, model) {
69
70
  const logFile = (0, path_1.join)(this.logsDir, `${taskId}.log`);
70
71
  const timestamp = new Date().toLocaleString();
71
72
  const header = `=== TASK LOG: ${taskId} ===
73
+ CrewX Version: ${version_1.CREWX_VERSION}
72
74
  Provider: ${provider}
73
- Command: ${command}
75
+ Agent: ${agentId || 'N/A'}
76
+ ${model ? `Model: ${model}
77
+ ` : ''}Command: ${command}
74
78
  Started: ${timestamp}
75
79
 
76
80
  `;