Skip to content

Enhance tool descriptions with rich keywords for better LLM discoverability - #8

Draft
joshspicer with Copilot wants to merge 3 commits into
mainfrom
copilot/improve-tool-descriptions
Draft

Enhance tool descriptions with rich keywords for better LLM discoverability#8
joshspicer with Copilot wants to merge 3 commits into
mainfrom
copilot/improve-tool-descriptions

Conversation

Copilot AI commented Oct 6, 2025

Copy link
Copy Markdown

Problem

The tool descriptions for the MCP server were too generic and lacked specific keywords that would help LLMs correctly identify when to use each tool. This could lead to suboptimal tool selection when users ask about Apple platform development topics.

Solution

Enhanced all four tool descriptions with rich, keyword-focused language including:

  • Platform keywords: iOS, macOS, watchOS, tvOS, visionOS
  • Language keywords: Swift, Objective-C
  • Framework keywords: UIKit, SwiftUI, Foundation, CoreData, MapKit, AVFoundation, Combine, async/await
  • Action-oriented verbs: Find, discover, fetch, retrieve, extract, analyze
  • Use case keywords: "how to" questions, best practices, troubleshooting, implementation guidance
  • Concrete examples: Added specific examples in parameter descriptions (e.g., "UIViewController", "SwiftUI navigation", "Core Data relationships")

Changes

search_apple_docs

  • Before: Generic "Search Apple Developer Documentation for APIs, frameworks, guides, samples, and videos"
  • After: Explicitly lists all platforms (iOS, macOS, watchOS, tvOS, visionOS), languages (Swift, Objective-C), UI frameworks (UIKit, SwiftUI), and popular frameworks (Foundation, CoreData, MapKit, AVFoundation)
  • Added concrete search examples in parameter descriptions

get_apple_doc_content

  • Before: Technical "Get detailed content from a specific Apple Developer Documentation page"
  • After: Action-oriented description emphasizing what you can "fetch and retrieve" (method signatures, property descriptions, code examples, parameters, return values)
  • Clarified use case: "Perfect for deep-diving into a specific iOS/macOS API...after finding it via search"
  • Added URL examples in parameters

download_apple_code_sample

  • Before: Functional but could be clearer about what "sample code" means
  • After: Emphasized "official sample code projects and Xcode examples", listed all platforms, highlighted automatic features (download, unzip, comprehensive analysis)
  • Clarified ideal use cases: "learning implementation patterns, exploring SwiftUI examples, UIKit demos"

research_apple_docs

  • Before: Generic research capabilities
  • After: Highlighted "AI-powered analysis", listed popular topics (UIKit, SwiftUI, Combine, async/await, CoreData, networking), added concrete question examples
  • Enhanced parameter descriptions with specific examples like "How do I implement custom navigation in SwiftUI?"

Impact

  • Word count: Increased from 121 to 286 words (+136%)
  • Platform/Framework keywords: Increased from 1 to 39 (+3800%)
  • Backward compatibility: ✅ 100% maintained (no changes to tool names, parameters, or types)

Testing

  • ✅ TypeScript compilation successful
  • ✅ All existing tests passing
  • ✅ Verified tool registration with enhanced descriptions
  • ✅ No breaking changes

These improvements dramatically increase the likelihood that LLMs will correctly select these tools when users ask about Apple platform development, whether they're asking about specific frameworks (SwiftUI, UIKit), platforms (iOS, macOS), languages (Swift, Objective-C), or development tasks (implementation, troubleshooting, best practices).

Original prompt

Look at the tool descriptions and improve them so that they will more often be selected by the LLM. Include key words

Created from VS Code via the [GitHub Pull Request](https://marketplace.visualstudio.com/items?itemName=GitHub.vscode-pull-request-github) extension.

💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.

Copilot AI and others added 2 commits October 6, 2025 22:53
Co-authored-by: joshspicer <23246594+joshspicer@users.noreply.github.com>
…bility

Co-authored-by: joshspicer <23246594+joshspicer@users.noreply.github.com>
Copilot AI changed the title [WIP] Refactor tool descriptions for better clarity Enhance tool descriptions with rich keywords for better LLM discoverability Oct 6, 2025
Copilot AI requested a review from joshspicer October 6, 2025 23:01
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.

2 participants