Skip to content

feat: improve fluency spiderweb for Claude-only users#672

Merged
rajbos merged 1 commit intomainfrom
rajbos/claude-fluency-spiderweb-shortcuts
Apr 25, 2026
Merged

feat: improve fluency spiderweb for Claude-only users#672
rajbos merged 1 commit intomainfrom
rajbos/claude-fluency-spiderweb-shortcuts

Conversation

@rajbos
Copy link
Copy Markdown
Owner

@rajbos rajbos commented Apr 25, 2026

Summary

This PR improves the fluency spiderweb scoring for users who only use Claude Code or Claude Desktop Cowork, by surfacing prompt engineering signals and customization data that were previously invisible to the scorer.

Changes

Bug Fixes

  • **\workspaceHelpers.ts**: \isMcpTool()\ now detects \mcp__\ double-underscore format (Claude Code MCP). Previously only \mcp.\ and \mcp_\ were recognized.
  • **\workspaceHelpers.ts**: \�xtractMcpServerName()\ now correctly parses \mcp__server__tool\ format. Previously returned 'unknown' for all Claude Code MCP tools.
  • **\cli/src/helpers.ts**: \ClaudeDesktopAdapter\ constructor was missing 3 required args. Now passes \isMcpTool, \�xtractMcpServerName, and token estimator.

Claude Slash Command Tracking (Prompt Engineering axis)

  • \claudeCodeAdapter.ts: Added \�xtractClaudeSlashCommand()\ + \CLAUDE_SLASH_ALLOWLIST\ (/review, /bug, /think, /compact, /pr_comments). Slash commands stored as _slash_\ in \ oolCalls.byTool\ without incrementing \ oolCalls.total.
  • \claudeDesktopAdapter.ts: Reuses shared slash command detection.
  • \maturityScoring.ts: Both scorers recognize _slash_*\ as Prompt Engineering evidence and exclude them from
    onAutoToolCount.

CLAUDE.md Customization Support

  • \maturityScoring.ts: Stage 1 tips + evidence mention CLAUDE.md alongside copilot-instructions.md.
  • \cli/src/helpers.ts: \�uildCustomizationMatrix()\ now detects Claude Code workspaces via JSONL \cwd\ field and checks for \CLAUDE.md.
  • Duplicate \�uildCustomizationMatrix\ removed from \ luency.ts\ and \�ll.ts.

Tests

  • 4 new tests for \mcp__\ format in \workspaceHelpers.test.ts\
  • 7 new tests for \�xtractClaudeSlashCommand\ in \�cosystemAdapters.test.ts\
  • All 145 tests pass.

- workspaceHelpers: fix isMcpTool() to detect mcp__ (Claude Code) prefix
- workspaceHelpers: fix extractMcpServerName() to parse mcp__server__tool format
- claudeCodeAdapter: add extractClaudeSlashCommand() + CLAUDE_SLASH_ALLOWLIST
  Slash commands (/review, /bug, /think, /compact, /pr_comments) are stored
  as __slash__<cmd> in toolCalls.byTool without incrementing toolCalls.total
- claudeCodeAdapter: route mcp__ tools to mcpTools instead of toolCalls
- claudeDesktopAdapter: detect slash commands using shared extractClaudeSlashCommand
- maturityScoring: recognize __slash__* entries as Prompt Engineering evidence
  (combined with VS Code slash commands in both personal + team scorers)
- maturityScoring: exclude __slash__* from nonAutoToolCount to avoid inflating
  Tool Usage / Agentic scores for Claude users
- maturityScoring: update customization Stage 1 tips + evidence to mention CLAUDE.md
- cli/helpers: export buildCustomizationMatrix (extracted from fluency.ts + all.ts)
  - detects Claude Code workspaces via cwd field in JSONL events
  - checks for CLAUDE.md in addition to copilot-instructions.md and agents.md
- cli/helpers: fix ClaudeDesktopAdapter constructor (was missing 3 required args)
- cli/commands/fluency.ts + all.ts: use shared buildCustomizationMatrix from helpers
- tests: add mcp__ prefix tests in workspaceHelpers.test.ts
- tests: add extractClaudeSlashCommand tests in ecosystemAdapters.test.ts

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@rajbos rajbos merged commit b416638 into main Apr 25, 2026
18 checks passed
@rajbos rajbos deleted the rajbos/claude-fluency-spiderweb-shortcuts branch April 25, 2026 19:47
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