xsavikx/okf-skills

okf-graphql

GraphQL connector that produces and ingests Open Knowledge Format (OKF) bundles from a GraphQL SDL document.

Voir la source
Document Skill original

Rendu depuis le dépôt source en conservant titres, exemples, code, tableaux, liens et images.

GraphQL OKF Connector

This skill provides a Go-based CLI tool to document a GraphQL schema (SDL) as an Open Knowledge Format (OKF) bundle: one concept per user-defined type and per root operation, with fields and operations linked to the types they reference. It needs only the SDL file — no live server.

When to Use

Use this skill when you need to:

  1. Catalog a GraphQL API from its SDL — types under types/, queries under

queries/, mutations under mutations/ (subscriptions under subscriptions/).

  1. Turn the type graph into a connected, browsable view — field→type and

operation→type references edges render as typed edges in okf-viz.

  1. Round-trip enriched descriptions back to a .okf-metadata.yaml sidecar.

Setup

bash
go install github.com/xSAVIKx/okf-skills/skills/okf-graphql@latest
# …or: cd skills/okf-graphql && go build -o okf-graphql .

How to Use

1. Produce an OKF bundle

bash
./okf-graphql produce --schema <schema.graphql> --out <bundle-dir>
  • --schema (required): path to the GraphQL SDL document.
  • --out (required): output OKF bundle directory.

Each object/input/interface type becomes types/<Name>.md with a # Columns field table (Name | Type | Required); enums emit a # Values list; unions emit their members. Each root field becomes an operation concept with its arguments and return type. Fields/operations link to the types they reference under # Relationships. Re-running preserves enriched descriptions.

2. Ingest / sync descriptions

bash
./okf-graphql ingest --schema <schema.graphql> --bundle <bundle-dir> [--sync]
  • Verifies each concept still exists in the schema (reports drift); the SDL is never

modified.

  • --sync: writes the bundle's descriptions to .okf-metadata.yaml next to the SDL.

3. Inspect the schema (self-description)

bash
./okf-graphql schema

Prints the machine-readable JSON description used by okf-mcp to expose the skill.

du même dépôt

Autres Skills

Tous les Skills
xsavikx
Communauté

okf-csv

CSV connector that produces and ingests Open Knowledge Format (OKF) bundles from a directory of CSV files. Infers each file's column schema (integer/number/boolean/date/string) by sampling rows, optionally embeds a per-column data profile and sample rows, and syncs descriptions back to a .okf-metadata.yaml sidecar. Use when documenting or cataloging a folder of CSV/flat files, or capturing their inferred schema and stats as an OKF bundle. CGO-free, pure Go.

installations
1
GitHub Stars
34
Mis à jour
30 août
xsavikx
Communauté

okf-enrich

Guidance for an AI agent to enrich an Open Knowledge Format (OKF) bundle with high-quality concept descriptions using its own LLM — grounded in the bundle's schema, data profile, and samples — then optionally sync them back to the source. Use when an OKF bundle has missing, weak, or low-quality descriptions that should be improved before publishing or ingestion. Instructions-only; no binary required.

installations
1
GitHub Stars
34
Mis à jour
30 août
xsavikx
Communauté

okf-fs

Local filesystem connector that produces and ingests Open Knowledge Format (OKF) bundles documenting directory trees and file metadata, honoring .okfignore and .okf-metadata.yaml. Use when documenting or cataloging a local folder structure, or capturing filesystem metadata as an OKF bundle.

installations
1
GitHub Stars
34
Mis à jour
30 août
xsavikx
Communauté

okf-mysql

MySQL connector that produces and ingests Open Knowledge Format (OKF) bundles from database schemas and table/column comments. Use when documenting or cataloging a MySQL database, extracting its schema and comments into OKF, or syncing descriptions back to MySQL via DDL.

installations
1
GitHub Stars
34
Mis à jour
30 août