MCP server for querying the OKN federated SPARQL endpoint over Proto-OKN knowledge graphs
Server has 25 tools with mostly present descriptions (avg ~180 chars), but critical gaps in schema visibility and parameter documentation. Tool names follow verb_noun convention well (get_*, list_*, create_*, sparql_*). However, input schemas are not visible in provided source, only tool 1 (get_valid_contrasts) shows explicit parameter definitions with types and descriptions. Output schemas are documented in docstrings but not as formal JSON Schema. Error handling is minimal, most tools return generic error dicts. No tool annotations (readOnlyHint/destructiveHint) despite 24/25 being read-only. Tool 25 (reset_query_log) is marked WRITE but lacks confirmation/dry-run pattern.
Create a reproducible markdown transcript of the analysis.
Create a reproducibility record for the analysis.
Get rich prose context on a knowledge graph.
Expand an ontology term to include all its subtypes.
Find context sources for an entity across knowledge graphs.
Find crosswalks (identifier mappings) between ontologies or knowledge graphs.
Get a precomputed join strategy between two knowledge graphs.
19 of 25 tools have no visible input schema definitions in source code. Only get_valid_contrasts shows explicit parameter types and descriptions.
24 of 25 tools marked READ_ONLY lack tool annotations (readOnlyHint). reset_query_log marked WRITE lacks destructiveHint and confirmation/dry-run pattern. Agents cannot distinguish safe from risky operations without annotations.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | F | 43 | 2026-07-28+ | v2 |
Get the version of a knowledge graph.
Get the log of executed queries.
Get the schema (classes, predicates, edge/node properties) for one KG. Call this BEFORE writing a `sparql_query` for a KG, to learn its specific entity types, predicates, and property names. Prefers curated metadata and falls back to probing the federation endpoint for the distinct classes and predicates used in the KG's named graph.
Get information about the MCP server.
Get the log of skipped queries.
Return VETTED spaceflight differential-expression contrasts for spoke-genelab. USE THIS before reading any spoke-genelab differential value (expression, methylation, abundance) as a "spaceflight effect". It resolves a request like "spaceflight DEGs in bone marrow" to a list of assays that already pass the two contrast rules, so you never hand-write the comparability self-join (the step LLMs skip, which lets a confounded assay slip through). The server computes, per assay: - Rule 1 (direction): kept only when factor_space_1 = "Space Flight" and factor_space_2 = "Ground Control". With this orientation group 1 = Space Flight, group 2 = Ground Control, so log2fc/lnfc/methylation_diff > 0 means UP in spaceflight. - Rule 2 (within-assay comparability): `is_clean_contrast` is True only when the flight arm (factors_1) and ground arm (factors_2) carry the SAME covariates after the condition labels/codes are stripped, AND material_id_1 = material_id_2. A WildType-flight-vs-knockout-ground assay (or one differing in sex/dose/time point/hardware) is `is_clean_contrast` False with a `confound_reason` — its differential values reflect that covariate, not spaceflight. Do NOT read those as a spaceflight effect. Then read differential expression for the returned `assay` IRIs via the reified relationship, e.g.:: ?stmt rdf:subject ?assay ; rdf:predicate schema:MEASURED_DIFFERENTIAL_EXPRESSION_ASmMG ; rdf:object ?gene ; schema:log2fc ?lfc ; schema:adj_p_value ?p .
Get the latest transcript as an MCP resource.
List available crosswalks between knowledge graphs.
List available knowledge graphs and their descriptions.
Convert a geographic point to an S2 geometry cell.
Probe the namespaces (identifier schemes) used in a knowledge graph predicate.
Reset the query log.
Execute a SPARQL query against the OKN federated endpoint.
Render a SPARQL query as a Mermaid flowchart diagram of its graph pattern. Turns the query's WHERE clause into a `graph TD` diagram: variables and constants become nodes, triple patterns become labeled edges, and OPTIONAL / UNION / FILTER / BIND / VALUES / SERVICE / MINUS / EXISTS blocks and property paths are drawn as their own shapes/subgraphs. Projected variables are highlighted. Use this to help a reader understand the shape of a query you wrote or are about to run with `sparql_query` — it complements `visualize_schema` (which diagrams a KG's schema, not a specific query). IRIs are shortened using the query's own `PREFIX` declarations; by default a curated set of well-known life-science / semantic-web prefixes (MONDO, CHEBI, GO, HP, NCIT, biolink, up, efo, …) also shortens common IRIs the query did not declare.
Bridge spatial data between knowledge graphs.
Perform a spatial join using S2 geometry.
Find taxonomic overlap between knowledge graphs.
Generate a Mermaid class diagram of a KG's schema. Builds the diagram deterministically from `get_schema` (no drafting needed): node classes become class boxes (with node properties as members), edge predicates become labeled arrows, and predicates that carry edge properties become intermediary classes with typed fields wired `source --> edge --> target`. Node (entity) classes are colored light blue and edge (relationship) classes orange, with a legend showing both. When the curated metadata names predicates but not their endpoints (e.g. `sawgraph`), edges are recovered from the graph's `rdfs:domain`/`rdfs:range`, scoped to the curated classes; any predicate still without endpoints is listed as a `%%` comment rather than guessed at.
13 tools (describe_kg, get_kg_version, get_server_info, find_context_sources, get_join_strategy, list_crosswalks, taxon_overlap, find_crosswalks, probe_namespaces, expand_ontology_term, point_to_s2, spatial_bridge, sudokn_spatial_join) have descriptions under 50 characters, too terse to guide LLM tool selection. Baseline is 194 chars avg.
No error handling guidance visible. Tools return generic error dicts without recovery hints (e.g., 'SPARQL endpoint timeout, retry with smaller LIMIT'). Agents cannot self-correct without actionable error messages.
reset_query_log (WRITE tool) lacks confirmation/dry-run pattern. Destructive operations should support a confirmation step to prevent accidental data loss.