Skip to content

feat(ai): make AI tool configs first-class, consistent, and profile-aware#15

Merged
Jake-Prickett merged 1 commit intomainfrom
feat/ai-tooling-improvements
Mar 23, 2026
Merged

feat(ai): make AI tool configs first-class, consistent, and profile-aware#15
Jake-Prickett merged 1 commit intomainfrom
feat/ai-tooling-improvements

Conversation

@Jake-Prickett
Copy link
Copy Markdown
Owner

Summary

  • Copilot instructions → template: global-copilot-instructions.md renamed to .md.tmpl; adds a ## Personal Profile Context section (iOS/SwiftUI, React Native/Expo, Next.js) gated on personal profile, plus a rendered OS/profile footer
  • VS Code MCP config → template: mcp.json renamed to mcp.json.tmpl; entire file wrapped in darwin OS guard; Figma and Notion entries gated on personal profile; GitHub MCP unconditional
  • MCP health check: validate-setup.sh gains check_mcp_server() — warns if github-mcp-server is missing from PATH or gh is unauthenticated
  • AGENTS.md memory note: Added ### Memory subsection under Claude Code in AGENTS.md.tmpl documenting the persistent memory path
  • Docs refresh: docs/ai-tools-integration.md updated with MCP servers table (Tool/Server/Transport/Auth), Claude commands table, Codex skills table (all 9 skills), and a project bootstrapping step-by-step
  • AGENTS-TEMPLATE.md: New static starter at private_dot_claude/AGENTS-TEMPLATE.md for seeding project-level AGENTS.md files

Test plan

  • chezmoi diff — confirm rendered changes look correct for both personal and work profiles
  • chezmoi apply — apply to home directory
  • ./scripts/validate-setup.sh — confirm MCP health check passes (or warns correctly if unauthenticated)
  • Verify ~/.config/github-copilot/global-copilot-instructions.md renders with profile section on personal, without on work
  • Verify ~/Library/Application Support/Code - Insiders/User/mcp.json renders with only GitHub MCP on work profile

🤖 Generated with Claude Code

…ware

- Convert Copilot global instructions to .tmpl with personal profile section
  (iOS/SwiftUI, React Native/Expo, Next.js stacks) and rendered OS/profile footer
- Convert VS Code Insiders mcp.json to .tmpl: darwin-only guard, Figma/Notion
  entries gated on personal profile, GitHub MCP unconditional
- Add check_mcp_server() to validate-setup.sh: warns if github-mcp-server
  missing from PATH or gh is unauthenticated
- Add Claude Code memory system note to AGENTS.md.tmpl
- Refresh docs/ai-tools-integration.md with MCP servers table, Claude commands
  table, Codex skills table (all 9), and project bootstrapping guide
- Add private_dot_claude/AGENTS-TEMPLATE.md as a project-level AGENTS.md starter

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@claude
Copy link
Copy Markdown

claude Bot commented Mar 23, 2026

Claude finished @Jake-Prickett's task —— View job


Code Review Complete ✅

I've analyzed this AI tooling improvements PR and overall it's a well-executed enhancement that makes the AI tool configurations more maintainable and profile-aware. Here's my detailed review:

  • Read and analyze all changed files
  • Review chezmoi template syntax and logic
  • Check profile-aware implementation
  • Evaluate security considerations
  • Assess documentation quality
  • Review validation approach and test coverage
  • Provide structured feedback

🟢 Strengths

1. Excellent Template Design

  • Proper Guards: All profile and OS guards use correct chezmoi template syntax ({{ if eq .profile "personal" }}, {{ if eq .chezmoi.os "darwin" }})
  • Clean Logic: Profile-specific content is properly gated without creating empty sections
  • Consistent Patterns: Template structure follows established conventions across all files

2. Strong Security Implementation

  • No Hardcoded Secrets: GitHub MCP correctly uses $(gh auth token) at runtime
  • Proper Permissions: Maintains private_ prefix for restricted files
  • Environment Variables: API keys properly sourced from env vars, not hardcoded

3. Comprehensive Documentation

The docs/ai-tools-integration.md update is particularly well done:

  • Clear MCP servers table with transport and auth details
  • Complete tool coverage (Claude Code, Codex, VS Code)
  • Helpful project bootstrapping steps

4. Thoughtful Validation

The MCP health check addition in validate-setup.sh:72-83 is excellent:

  • Checks both github-mcp-server availability and gh authentication
  • Provides clear, actionable warning messages
  • Follows the script's existing pattern

🟡 Minor Improvements

1. Template Syntax Consistency (Line-specific feedback)

File: private_dot_config/github-copilot/global-copilot-instructions.md.tmpl:42-48

{{ if eq .profile "personal" }}
## Personal Profile Context

Primary stacks: iOS/SwiftUI, React Native/Expo, Next.js
Prefer Swift concurrency (async/await, actors) over GCD.
Expo Router for navigation in React Native projects.
{{ end }}

Suggestion: Consider adding a blank line before the closing {{ end }} for better readability when rendered.

2. VS Code MCP Configuration

File: private_Library/.../mcp.json.tmpl:4-16
The profile guard for Figma and Notion MCPs is well-implemented, but consider adding version validation or fallback handling if the gallery API changes.

3. Documentation Enhancement

File: docs/ai-tools-integration.md:123-131
The project bootstrapping section could benefit from numbering the CLAUDE-TEMPLATE.md.tmpl reference (should be CLAUDE.md.tmpl based on the context).

🟢 Test Coverage Assessment

The PR includes solid validation through:

  • validate-setup.sh MCP health check function
  • Clear test plan in PR description
  • Profile-aware rendering verification steps

Recommended test additions:

  1. Verify template rendering on both personal and work profiles
  2. Test MCP server connectivity after applying changes
  3. Confirm VS Code MCP config loads correctly on macOS

🟢 Performance & Architecture

  • Minimal Runtime Impact: Templates only execute during chezmoi apply
  • Clean Separation: Profile logic doesn't create complex conditionals
  • Maintainable Structure: Easy to add new AI tools following established patterns

🔒 Security Review

Passed all security checks:

  • No secrets in tracked files
  • Proper use of environment variables
  • Runtime token acquisition vs. storage
  • Appropriate file permissions with private_ prefix

📋 Final Recommendations

  1. Ready to Merge: This PR is well-implemented and follows best practices
  2. Test the Test Plan: Run through the verification steps in the PR description
  3. Consider Future Enhancements: The architecture supports easy addition of new AI tools

🎯 Code Quality Score: 9/10

This is high-quality infrastructure code that makes AI tooling configuration more maintainable and secure. The template design is clean, security practices are solid, and documentation is comprehensive.


@Jake-Prickett Jake-Prickett merged commit 9ec8b6d into main Mar 23, 2026
1 check passed
@Jake-Prickett Jake-Prickett deleted the feat/ai-tooling-improvements branch March 23, 2026 01:40
Jake-Prickett added a commit that referenced this pull request Apr 10, 2026
feat(ai): make AI tool configs first-class, consistent, and profile-aware
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant