Skip to content

docs(registry): update README to reflect JSON entry schema#102

Merged
amondnet merged 2 commits intomainfrom
amondnet/readme-registry
Apr 17, 2026
Merged

docs(registry): update README to reflect JSON entry schema#102
amondnet merged 2 commits intomainfrom
amondnet/readme-registry

Conversation

@amondnet
Copy link
Copy Markdown
Contributor

@amondnet amondnet commented Apr 17, 2026

Summary

The README's Registry section described the old Markdown+YAML-frontmatter format. The implementation has since migrated to a Nuxt Content v3 type: 'data' collection backed by .json files and restructured the schema around the Entry → Package → Source hierarchy (ADR-0001). The docs were stale and misleading for contributors.

Changes

  • File format: .md with YAML frontmatter → .json (Nuxt Content v3 type: 'data' collection)
  • Schema restructured: flat aliases/strategies → Entry → Package → Source hierarchy per ADR-0001
  • Source-type reference table added: npm, github, web, llms-txt with required/optional fields
  • Monorepo example added: @mastra/core and @mastra/memory showing multiple packages in one entry
  • Field renames: strategies[].sourcesources[].type, docsPathpath, top-level aliases → per-package aliases
  • Contributing section updated to point at registryEntrySchema in packages/schema/src/registry.ts and call out validation invariants (duplicate aliases, duplicate package names, slug collisions)

Test plan

  • Render README on GitHub and verify code blocks display correctly
  • Confirm all internal links (ADR-0001, packages/schema/src/registry.ts) resolve
  • Spot-check that the JSON examples match the actual schema in packages/schema/src/registry.ts

Summary by cubic

Update the Registry docs in README to the JSON-based schema and Entry → Package → Source structure, replacing the old Markdown + YAML frontmatter format. Adds a source-type reference, a monorepo example (@mastra/core, @mastra/memory), field rename notes, updated contributing guidance pointing to validation in packages/schema/src/registry.ts, and syncs the Next.js example tags (adds vercel) to match the real entry.

Written for commit f1c7345. Summary will update on new commits.

The registry section described the old Markdown+YAML-frontmatter
format, which was replaced by a Nuxt Content v3 type:data collection
backed by .json files.

This commit rewrites the section to match the current implementation:

- File format: .md with YAML frontmatter → .json (type:data collection)
- Schema restructured from flat aliases/strategies into the
  Entry → Package → Source hierarchy introduced in ADR-0001
- Added source-type reference table (npm, github, web, llms-txt)
  with required and optional fields per type
- Added monorepo example (@mastra/core, @mastra/memory) showing
  multiple packages within one entry
- Renamed fields: strategies[].source → sources[].type,
  docsPath → path, top-level aliases → per-package aliases
- Contributing section now points at registryEntrySchema in
  packages/schema/src/registry.ts and calls out validation invariants
@dosubot dosubot bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Apr 17, 2026
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 17, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@dosubot dosubot bot added status:in-progress Currently being worked on type:docs Documentation improvements labels Apr 17, 2026
@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages bot commented Apr 17, 2026

Deploying ask-registry with  Cloudflare Pages  Cloudflare Pages

Latest commit: f1c7345
Status: ✅  Deploy successful!
Preview URL: https://33d8e733.ask-registry.pages.dev
Branch Preview URL: https://amondnet-readme-registry.ask-registry.pages.dev

View logs

Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 1 file

Auto-approved: Documentation-only update to the README to reflect existing architectural changes (ADR-0001) and registry schema migration.

Architecture diagram
sequenceDiagram
    participant Contributor
    participant FS as Registry Storage (JSON)
    participant Schema as Schema Validator
    participant Nuxt as Nuxt Content v3 (Data)
    participant Client as ASK CLI / App
    participant Providers as External (npm/GitHub/Web)

    Note over Contributor, FS: NEW: Entry definition process
    Contributor->>FS: Create/Update <owner>/<repo>.json
    
    Note over FS, Schema: Validation at Build/Runtime
    FS->>Schema: NEW: Validate Entry -> Package -> Source hierarchy
    Schema->>Schema: Check invariants (duplicate aliases, slugs, or package names)
    
    Note over Client, Nuxt: Data Retrieval
    Client->>Nuxt: Query documentation config for package alias
    Nuxt->>FS: NEW: Read type: 'data' collection
    FS-->>Nuxt: JSON Object
    Nuxt-->>Client: Resolved Package Entry (ordered sources)

    Note over Client, Providers: CHANGED: Source Resolution Flow
    loop For each source in sources[]
        Client->>Client: Identify source type (npm, github, web, llms-txt)
        Client->>Providers: Attempt fetch using type-specific fields
        alt Success
            Providers-->>Client: Documentation content
            Note over Client: Resolution Complete
        else Failure / Fallback
            Providers-->>Client: Error
            Note over Client: Try next source in priority list
        end
    end
Loading

The README single-package example claimed to mirror vercel/next.js.json
but dropped the "vercel" tag. Sync the tag array so contributors copying
the example produce a file identical to the real registry entry.

Found by /review:code-review-loop documentation analyzer.
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

0 issues found across 1 file (changes from recent commits).

Auto-approved: Documentation-only update to synchronize the README with the current JSON-based registry schema and reflect the Entry-Package-Source hierarchy.

@amondnet amondnet self-assigned this Apr 17, 2026
@amondnet amondnet merged commit 7c8fc36 into main Apr 17, 2026
5 checks passed
@amondnet amondnet deleted the amondnet/readme-registry branch April 17, 2026 06:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L This PR changes 100-499 lines, ignoring generated files. status:in-progress Currently being worked on type:docs Documentation improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant