Skip to content

Split monolithic documentation resource into logical sections #69

@mattpodwysocki

Description

@mattpodwysocki

Context

Currently, MapboxDocumentationResource serves the entire Mapbox documentation as a single resource. Split this into multiple, focused resources for better discoverability and more efficient context usage.

Motivation

Following Google's Developer Knowledge API approach, providing granular access to documentation helps AI assistants:

  • Load only relevant documentation sections
  • Reduce context window usage
  • Discover specific resource types more easily
  • Better understand the structure of available information

Proposed Implementation

Split resource://mapbox-documentation into:

  1. resource://mapbox-api-reference - API documentation

    • REST API endpoints
    • Parameters and responses
    • Rate limits and authentication
  2. resource://mapbox-style-spec - Style specification

    • Layer types and properties
    • Expression syntax
    • Style structure
  3. resource://mapbox-sdk-docs - SDK documentation

    • Mobile SDKs (iOS, Android)
    • Web SDKs (mapbox-gl-js, mapbox-gl-native)
    • Other SDKs
  4. resource://mapbox-guides - How-to guides

    • Tutorials
    • Best practices
    • Common patterns
  5. resource://mapbox-examples - Code examples

    • Working code snippets
    • Use case demonstrations

Implementation approach:

  • Parse llms.txt and categorize content
  • Create separate resource classes for each category
  • Register all resources in resourceRegistry.ts
  • Keep existing mapbox-documentation for backward compatibility (deprecated)

Acceptance Criteria

  • 5 new resource classes created
  • Content properly categorized from llms.txt
  • All resources registered and accessible
  • Tests for each resource
  • Updates CHANGELOG.md
  • Documentation in README.md
  • Deprecation notice for old resource (don't remove yet)

Related

Part of enhanced documentation discovery initiative

Depends on: None (can be done in parallel with #68)

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions