Skip to main content
Glama
Schema.gov.it MCP Server

Schema.gov.it MCP Server

Official
by italia

Ask DeepWiki Docker ghcr.io

Schema.gov.it MCP Server

Un server MCP (Model Context Protocol) avanzato per interagire semanticamente con il catalogo dati di schema.gov.it.

Questo server permette agli agenti AI (come Claude Code) di esplorare ontologie, analizzare la copertura dei dati, verificare la qualità e scoprire connessioni tra concetti in modo intelligente.

Strumenti disponibili

Il server espone 47 strumenti organizzati in 12 categorie:

1. Operazioni Base

  • query_sparql: Esegue una query SPARQL raw con contesto source. Default: remoto schema.gov.it; supporta anche source="local" con file_path, content o upload_id. source="hybrid" non e' ancora supportato per SPARQL raw.

  • explore_catalog: Elenca i grafi e le ontologie disponibili nell'endpoint.

  • explore_classes: Elenca le classi disponibili con conteggio istanze, con filtro opzionale.

2. Analytics Semantiche

  • check_coverage: Analizza la copertura di una specifica classe/proprietà, o statistiche globali.

  • check_quality: Trova problemi di qualità (label o descrizioni mancanti).

  • check_overlaps: Identifica sovrapposizioni (stesse label) o mapping espliciti.

3. Modello Dati (Ontologie)

  • list_ontologies: Elenca le ontologie disponibili (es. Città, Servizi Pubblici).

  • explore_ontology: Mostra Classi e Proprietà definite in una specifica ontologia.

4. Vocabolari Controllati (Reference Data)

  • list_vocabularies: Elenca i vocabolari controllati disponibili (ConceptScheme) con conteggio istanze.

  • browse_vocabulary: Naviga un vocabolario con paginazione ed e' il default consigliato quando conosci gia' il ConceptScheme. Supporta keyword e lang.

  • search_in_vocabulary: Cerca concetti dentro un vocabolario specifico per label; utile quando vuoi una ricerca diretta senza scorrere le pagine. Supporta lang.

  • navigate_skos_hierarchy: Naviga la gerarchia skos:broader/skos:narrower a partire da un concetto, con direction e depth.

5. Cataloghi e Dataset (Dati)

  • list_datasets: Elenca i dataset DCAT-AP_IT disponibili.

  • explore_dataset: Mostra dettagli e distribuzioni di un dataset.

  • preview_distribution: Scarica e mostra le prime righe di una distribuzione CSV/JSON.

Nota: questi tool restano utili, ma su schema.gov.it sono spesso secondari. Il catalogo contiene soprattutto asset semantici pubblicati come dataset DCAT-AP_IT, ad esempio ontologie, vocabolari controllati e relative distribuzioni. Per esplorare schema.gov.it conviene di norma partire da ontologie, vocabolari, classi, proprietà e query SPARQL; i tool dataset sono più indicati per cataloghi esterni o per casi DCAT-AP_IT specifici.

6. Intelligence (Avanzato)

  • search_concepts: Ricerca fuzzy. Trova concetti (es. "Scuola") senza conoscere l'URI esatto; spesso e' il primo passo prima di inspect_concept o get_property_details. Supporta lang per ridurre duplicati it/en.

  • inspect_concept: Deep Dive. Ottiene in un colpo solo definizione, gerarchia, usage stats e vicini di un concetto. Supporta source="schema" (default), source="local" e source="hybrid" per usare un'ontologia locale come base con arricchimento mirato da schema.gov.it, oltre a lang per filtrare le label.

  • find_relations: Pathfinding. Scopre come due concetti sono collegati; supporta max_hops fino a 3 con flag paths_truncated.

  • suggest_improvements: Euristiche per trovare anomalie strutturali nell'ontologia (classi orfane, cicli, proprietà senza dominio/range, classi molto popolose senza ConceptScheme).

  • describe_resource: CBD. Ottiene tutte le triple di una risorsa (Concise Bounded Description).

7. Proprieta e Relazioni

  • list_properties: Elenca ObjectProperty e DatatypeProperty con dominio e range.

  • get_property_details: Ottiene dettagli completi di una proprieta. Supporta source="schema" (default), source="local" e source="hybrid"; in modalita ibrida arricchisce domini/range e super-proprieta mancanti da schema.gov.it.

  • list_instances_of_class: Elenca le istanze di una classe presente nel catalogo.

  • find_recommended_scheme_for_property: Suggerisce il ConceptScheme più adatto per i valori controllati di una proprietà.

8. Dati Geografici (Italia)

  • list_municipalities: Elenca i comuni italiani con codici ISTAT e Belfiore, con filtro per nome e parametro lang.

  • list_provinces: Elenca le province italiane con sigla automobilistica e codice metro, con parametro lang.

  • list_identifiers: Esplora gli identificatori CLV (Codice Catastale, Sigla Automobilistica, ecc.).

  • resolve_territorial_uri: Risolve codici territoriali italiani verso URI canonici del catalogo.

9. Endpoint SPARQL Esterni (linked data)

  • recommend_external_endpoints: Restituisce una short list curata di endpoint SPARQL pubblici utili da usare insieme a schema.gov.it.

  • list_linked_endpoints: Scopre gli endpoint SPARQL collegati al catalogo via dcat:DataService.

  • query_external_endpoint: Esegue una query SPARQL su qualsiasi endpoint HTTPS pubblico esterno. Non usarlo per schema.gov.it: in quel caso usa query_sparql.

  • find_external_alignments: Trova i mapping verso risorse esterne (Eurostat, DBpedia, ecc.).

  • explore_external_endpoint: Esplora la struttura di un endpoint esterno (classi e conteggi).

10. Ontologia Locale

  • inspect_local_ontology: Carica e riassume un'ontologia RDF/OWL disponibile al server via file_path, contenuto inline o upload_id. Attenzione: file_path indica sempre un path leggibile dal server MCP, non dal laptop dell'utente.

  • inspect_local_concept: Deep dive su una classe (locale o caricata). Tool legacy/compatibile: per i nuovi flussi puoi anche usare inspect_concept con source="local" o source="hybrid".

  • inspect_local_property: Deep dive su una proprietà (locale o caricata). Tool legacy/compatibile: per i nuovi flussi puoi anche usare get_property_details con source="local" o source="hybrid". Espone separatamente: assertedDomain/assertedRange (dichiarati nel file), inheritedDomain/inheritedRange (da super-proprietà via rdfs:subPropertyOf+, con indicazione dell'antenato), effectiveDomain/effectiveRange (unione). Per super-proprietà non presenti nel file locale (es. l0:name, l0:description da ontologie importate), interroga automaticamente schema.gov.it come fallback. Ogni super-proprietà è marcata con source local | remote | not-found. Include nota sul limite Unicode nei nomi locali SPARQL con oxigraph.

  • query_local_ontology: Esegue una query SPARQL SELECT su un'ontologia accessibile dal server o caricata prima via POST /upload. Usalo solo per query custom; per profili standard di concetti/proprieta usa i tool inspect_local_*.

  • compare_local_with_remote: Confronta le classi/proprietà definite in un'ontologia accessibile dal server o via upload_id con quelle presenti in schema.gov.it — utile per scoprire cosa riusare o allineare.

  • query_uploaded_store: Esegue query SPARQL SELECT su uno store temporaneo creato via POST /upload. Tool legacy: per i nuovi flussi e' preferibile query_local_ontology con upload_id.

11. Meta-Ottimizzazione

  • suggest_new_tools: Analizza i log delle query RAW e suggerisce nuovi tool specializzati in base all'utilizzo reale.

  • analyze_usage: Analizza i log interni per identificare pattern, errori e query frequenti.

12. Open Knowledge Graphs (OKG)

Integrazione con api.openknowledgegraphs.com — catalogo di oltre 1.800 ontologie, vocabolari, tassonomie e strumenti semantici con metadati da Wikidata. Tutti i dati sono CC0, nessuna autenticazione richiesta.

  • list_okg_categories: Recupera a runtime le categorie tematiche disponibili nel catalogo OKG (le categorie sono scaricate dinamicamente da api.openknowledgegraphs.com e messe in cache).

  • search_okg_resources: Cerca ontologie, vocabolari e tassonomie nel catalogo OKG per parola chiave e/o categoria tematica.

  • find_okg_alignments: Dato un URI di schema.gov.it, trova le risorse OKG correlate: prima cerca allineamenti Wikidata già presenti nel catalogo (owl:sameAs, skos:exactMatch), poi usa il Wikidata ID come ponte verso OKG per identificare corrispondenze internazionali confermate.

  • find_semantic_software: Cerca strumenti software semantici nel catalogo OKG (editor di ontologie, motori SPARQL, convertitori RDF, reasoner, ecc.).

  • compare_coverage_with_okg: Gap analysis per dominio: confronta le risorse di schema.gov.it con il catalogo OKG internazionale, classificando le risorse come "coperte" (già collegate via Wikidata) o "gap" (non ancora presenti in schema.gov.it).

Related MCP server: OntoPortal MCP Server

Scelta Rapida Dei Tool

Se vuoi fare X

Tool consigliato

Cercare un URI senza conoscerlo

search_concepts

Profilare un concetto gia' presente in schema.gov.it

inspect_concept

Ottenere il dump RDF grezzo di una risorsa remota

describe_resource

Profilare una proprieta gia' presente in schema.gov.it

get_property_details

Fare una query custom su schema.gov.it

query_sparql

Fare una query custom su un endpoint SPARQL esterno

query_external_endpoint

Esplorare un vocabolario noto con paginazione

browse_vocabulary

Riassumere un'ontologia locale o caricata

inspect_local_ontology

Profilare un concetto in un'ontologia locale/uploaded

inspect_local_concept

Profilare una proprieta in un'ontologia locale/uploaded

inspect_local_property

Fare una query custom su un'ontologia locale/uploaded

query_local_ontology

Caricare un file che il server non puo' leggere direttamente

get_upload_instructions


Installazione & Uso

1. Tramite Docker (Consigliato per uso remoto/condiviso)

Il server può essere eseguito come container Docker con trasporto HTTP/SSE, rendendolo accessibile via URL da qualsiasi client MCP.

Avvio rapido con Docker Compose (immagine remota da GHCR)

docker compose up -d mcp

Per default, questo usa l'immagine pubblicata su ghcr.io/italia/dati-semantic-mcp:latest e la aggiorna automaticamente prima dell'avvio.

Con il file docker-compose.yaml il server sarà disponibile su http://localhost:8088/mcp. I log vengono salvati nella cartella ./logs/.

Build locale esplicita con Docker Compose

Se vuoi costruire l'immagine dal checkout locale invece di usare quella remota:

docker compose -f docker-compose.build.yaml up -d mcp

Avvio con Docker

docker run -d \
  --name schema-gov-it-mcp \
  -p 3000:3000 \
  -e MCP_TRANSPORT=sse \
  -v ./logs:/app/logs \
  ghcr.io/italia/dati-semantic-mcp:latest

Verifica

curl http://localhost:3000/health
# {"status":"ok","service":"schema-gov-it-mcp","sessions":0}

2. Tramite NPX (Senza installazione permanente)

npx schema-gov-it-mcp

3. Installazione da GitHub (Senza NPM Registry)

Puoi installare globalmente direttamente dal repository:

npm install -g git+https://github.com/italia/dati-semantic-mcp.git

Poi usa schema-gov-it-mcp come comando.

4. Installazione Locale (Sviluppo)

git clone https://github.com/italia/dati-semantic-mcp.git
cd dati-semantic-mcp
npm install
npm run build   # Automatico via prepare, ma puoi lanciarlo manualmente
node dist/index.js

Configurazione Client MCP

Modalità stdio (processo locale)

Adatta per uso personale: il client lancia il server come processo figlio.

Claude Code

claude mcp add schema-gov-it -- npx -y github:italia/dati-semantic-mcp

Oppure aggiungi manualmente a ~/.claude.json:

{
  "mcpServers": {
    "schema-gov-it": {
      "command": "npx",
      "args": ["-y", "github:italia/dati-semantic-mcp"]
    }
  }
}

VS Code / Cursor

In .vscode/mcp.json:

{
  "servers": {
    "schema-gov-it": {
      "command": "npx",
      "args": ["-y", "github:italia/dati-semantic-mcp"]
    }
  }
}

Modalità HTTP/SSE (server remoto o Docker)

Adatta per ambienti condivisi, CI/CD o deployment remoto. Il server deve essere già in esecuzione (es. via Docker Compose).

Importante: in questa modalità file_path si riferisce al filesystem del server/container. Se il file RDF sta sul computer del client, il flusso corretto è POST /upload e poi uso di upload_id.

Claude Code

claude mcp add --transport http schema-gov-it http://localhost:8088/mcp

Oppure aggiungi manualmente a ~/.claude.json:

{
  "mcpServers": {
    "schema-gov-it": {
      "type": "http",
      "url": "http://localhost:8088/mcp"
    }
  }
}

VS Code / Cursor

In .vscode/mcp.json:

{
  "servers": {
    "schema-gov-it": {
      "type": "http",
      "url": "http://localhost:8088/mcp"
    }
  }
}

Upload di un file locale verso un server remoto

Quando il server gira altrove e non può leggere il file locale del client, evita di provare percorsi diversi. Carica il file una volta e riusa l'id restituito.

Questo punto è importante anche per i costi e l'affidabilità: non usare la conversazione con il modello come canale di trasporto del file, e non incollare ontologie grandi nel prompt. Il file va inviato dal client con un tool locale che spedisca i byte direttamente al server, per esempio curl, nc o un helper equivalente del client MCP.

Con curl:

curl -X POST \
  -H "Content-Type: text/turtle" \
  --data-binary @./mia-ontologia.ttl \
  http://localhost:3000/upload

Se stai usando docker-compose.yaml, sostituisci localhost:3000 con localhost:8088.

Risposta tipica:

{"id":"9d7...","tripleCount":1234,"format":"text/turtle","endpoint":"/sparql/9d7..."}

Poi usa quell'id come upload_id con inspect_local_ontology, query_local_ontology o compare_local_with_remote. L'interrogazione diretta dello store resta possibile, ma per i nuovi flussi e' preferibile query_local_ontology con upload_id:

curl --get \
  --data-urlencode 'query=SELECT ?c WHERE { ?c a <http://www.w3.org/2002/07/owl#Class> } LIMIT 10' \
  http://localhost:3000/sparql/9d7...

Con nc:

{ printf 'POST /upload HTTP/1.1\r\nHost: localhost:3000\r\nContent-Type: text/turtle\r\nContent-Length: %s\r\n\r\n' "$(wc -c < ./mia-ontologia.ttl)"; cat ./mia-ontologia.ttl; } | nc localhost 3000

Esempi di Utilizzo

Una volta configurato, puoi chiedere all'agente cose come:

  • "Cerca concetti relativi alla 'Sanità' e dimmi quali sono le classi principali." (Userà search_concepts)

  • "Analizza la classe Persona e dimmi con chi è collegata." (Userà inspect_concept)

  • "Controlla se ci sono sovrapposizioni tra i concetti di Luogo." (Userà check_overlaps)

  • "Come posso ottimizzare le mie query?" (Userà analyze_usage sui log)

  • "Elenca le ontologie disponibili e mostrami le classi di quella sui Servizi Pubblici." (Userà list_ontologies + explore_ontology)

  • "Trova i comuni della Lombardia e il loro codice Belfiore." (Userà list_municipalities)

  • "Consigliami alcuni endpoint SPARQL esterni da interrogare dopo schema.gov.it." (Userà recommend_external_endpoints)

  • "Esegui una query SPARQL su DBpedia per trovare le città italiane." (Userà query_external_endpoint)

  • "Dammi una panoramica dell'ontologia in /srv/ontologie/mia-ontologia.ttl." (Userà inspect_local_ontology con file_path, se il file è davvero leggibile dal server)

  • "Ho un server MCP remoto e un file TTL sul mio laptop: caricalo via POST /upload e poi confronta le classi con schema.gov.it." (Userà upload_id + compare_local_with_remote)

  • "Trova tutte le classi senza rdfs:label nel file che ho appena caricato via upload." (Userà query_local_ontology con upload_id)

  • "Esistono vocabolari internazionali nel settore pubblico che potremmo allineare a schema.gov.it?" (Userà search_okg_resources)

  • "La classe Person di CPV ha equivalenti riconosciuti a livello internazionale?" (Userà find_okg_alignments)

  • "Quali tool open source posso usare per lavorare con SKOS e OWL?" (Userà find_semantic_software)

  • "Cosa manca a schema.gov.it rispetto agli standard semantici internazionali del settore pubblico?" (Userà compare_coverage_with_okg)

Variabili d'Ambiente

Variabile

Default

Descrizione

MCP_TRANSPORT

stdio

Modalità di trasporto. Usa http o sse per avviare il server HTTP (obbligatorio per l'upload e per l'uso remoto).

PORT

3000

Porta su cui il server HTTP si mette in ascolto (solo in modalità http/sse).

HOST

0.0.0.0

Indirizzo di bind del server HTTP. Usa 127.0.0.1 per limitare l'accesso al solo localhost.

MCP_PUBLIC_URL

(non impostato)

URL esterno del server, usato dal tool get_upload_instructions per restituire l'endpoint di upload raggiungibile dal client. Necessario quando la porta interna differisce da quella esposta (Docker, reverse proxy). Esempio: http://localhost:8080.

Esempi:

# Avvio locale su porta 3000 con upload abilitato
MCP_TRANSPORT=http node dist/index.js

# Porta personalizzata
MCP_TRANSPORT=http PORT=8080 node dist/index.js

# Docker con port mapping 8080→3000 (porta interna 3000, esposta 8080)
docker run -d \
  -e MCP_TRANSPORT=http \
  -e MCP_PUBLIC_URL=http://localhost:8080 \
  -p 8080:3000 \
  ghcr.io/italia/dati-semantic-mcp:latest

Nota upload: La porta HTTP (e di conseguenza /upload) è disponibile solo in modalità http o sse. In modalità stdio il server non espone nessuna porta; per passare file RDF usa il parametro content di inspect_local_ontology per file piccoli, oppure attiva la modalità HTTP.


Note Tecniche

  • Endpoint Esterni: Usa recommend_external_endpoints per una lista curata (es. lod.dati.gov.it come possibile server SPARQL per dati.gov.it, dati.cultura.gov.it, endpoint istituzionali italiani, endpoint europei e knowledge graph pubblici) e list_linked_endpoints per scoprire quelli pubblicati nel catalogo via metadata DCAT.

  • Riduzione Token per Query Esterne: query_external_endpoint restituisce risultati compressi: conserva solo i valori utili, usa un formato tabellare compatto per result set più grandi e tronca risposte eccessive. Non aggiunge automaticamente LIMIT, quindi per query esterne conviene specificarlo sempre.

  • Compatibilità Endpoint Esterni: Per migliorare l'interoperabilità con endpoint protetti da proxy o filtri anti-bot, le query SPARQL verso server esterni vengono inviate con header HTTP più simili a quelli di un browser standard. Se un endpoint esterno rifiuta il POST con 403, il server riprova automaticamente in GET.

  • Prefixes Automatici: Non serve definire rdf:, owl:, skos:, ecc. nelle query interne. Il server li aggiunge automaticamente. Per gli endpoint esterni i prefissi non vengono iniettati di default.

  • Compressione Token: Le liste lunghe (> 5 item) vengono restituite in formato tabellare compatto per risparmiare token.

  • Input Sanitizzati: Tutti i parametri utente sono sanitizzati per prevenire SPARQL injection.

  • Ontologia Locale: I tool del gruppo 10 (inspect_local_ontology, inspect_local_concept, inspect_local_property, query_local_ontology, compare_local_with_remote) usano oxigraph (WASM) per caricare file RDF/OWL in memoria ed eseguire SPARQL. file_path funziona solo per file davvero leggibili dal processo server; non trasferisce file dal client. I file vengono cachati dopo il primo caricamento; le query successive sullo stesso file non rileggono il disco. Formati supportati: .ttl, .owl, .rdf, .nt, .jsonld.

  • Context-aware core tools: inspect_concept, get_property_details e query_sparql accettano ora source="schema" | "local" | "hybrid" dove applicabile. hybrid oggi e' supportato solo sui tool specializzati di concetto/proprieta; per query_sparql raw non e' ancora disponibile un vero grafo unificato locale+remoto.

  • Workflow Upload HTTP: usa get_upload_instructions quando il file sta sul client e il server non puo' leggerlo. Dopo l'upload, il flusso principale consigliato e' query_local_ontology con upload_id; query_uploaded_store resta un percorso legacy specifico dello store temporaneo.

  • Open Knowledge Graphs (OKG): I tool della categoria 12 chiamano api.openknowledgegraphs.com (REST JSON, CC0, nessuna autenticazione, timeout 10s). Le categorie tematiche vengono scaricate dinamicamente dalla root dell'API (GET /) al primo utilizzo e messe in cache in memoria per la durata della sessione; non è più necessario aggiornarle manualmente nel codice. Il tool compare_coverage_with_okg combina una chiamata OKG con una query SPARQL su schema.gov.it usando i Wikidata ID come chiave di collegamento.

  • Test e CI: la CI esegue npm run build, npm run test:http e npm run test:mcp. I test MCP includono anche chiamate live a api.openknowledgegraphs.com, quindi richiedono accesso di rete verso l'esterno.

  • Logging: Tutte le chiamate vengono loggate in logs/usage_log.jsonl per analisi e miglioramento continuo. Ogni entry include argomenti, riepilogo, source_data_metrics e ai_data_metrics: metriche quantitative dei dati ricevuti e del payload finale passato al modello, ad esempio numero di caratteri e, quando rilevabile, righe, colonne o numero di elementi.

  • Trasporto: Il server supporta sia stdio (default, per uso locale) che HTTP/SSE (via MCP_TRANSPORT=sse, per uso remoto/Docker).

Licenza

MIT - vedi LICENSE

Available Tools

47 tools
analyze_usageAnalyze UsageA
Read-only

Analyze the server's own usage logs for patterns and errors.

Args: None

Returns:

  • total_calls: Total number of tool invocations

  • tool_breakdown: Calls per tool

  • recent_errors: Last 5 distinct errors

  • last_activity: Most recent timestamp

Inputs: no named parameters.

browse_vocabularyBrowse VocabularyA
Read-onlyIdempotent

Browse concepts in a vocabulary with pagination support.

Args:

  • schemeUri: URI of the ConceptScheme

  • limit: Items per page (default: 50)

  • offset: Items to skip (default: 0)

  • keyword: (optional) Filter by label

  • lang: "it" | "en" | "any" (default: "any")

Returns:

  • concepts: List of concepts with code and label

  • pagination: Total count, offset, has_more

When to use this vs X:

  • vs search_in_vocabulary: this is the preferred default for exploring a known ConceptScheme because it supports pagination and optional keyword

  • use search_in_vocabulary only for a lightweight keyword lookup when pagination is not needed

Use for: Large vocabularies that need pagination (e.g., ICD codes, municipalities)

Inputs: schemeUri (required), lang, limit, offset, +1 more.

check_coverageCheck CoverageA
Read-onlyIdempotent

Analyze usage coverage of a specific class or property, or get global stats.

Args:

  • targetUri: (optional) URI of class or property to check

Returns:

  • If targetUri provided: instance count and properties used

  • If no targetUri: top 50 types by instance count

Examples:

  • No args: Global coverage statistics

  • targetUri="http://...#Person": Coverage for Person class

How to interpret the two modes:

  • without targetUri = heatmap of the catalog, useful to see which types are most used overall

  • with targetUri = targeted coverage analysis for one URI

Inputs: targetUri.

check_overlapsCheck OverlapsB
Read-onlyIdempotent

Identify potential overlaps (same labels) or explicit mappings.

Args:

  • limit: Maximum results to return (default: 50)

Returns:

  • List of potential overlaps with relation type:

    • owl:sameAs mappings

    • skos:exactMatch mappings

    • Same Label collisions

Inputs: limit.

check_qualityCheck QualityA
Read-onlyIdempotent

Verify quality issues like missing labels or descriptions.

Args:

  • limit: Maximum results to return (default: 50)

  • ontologyUri: (optional) Restrict check to resources whose URI starts with this ontology namespace. Use this to avoid false positives from resources imported from other ontologies (e.g. core ontology classes referenced as range/domain in the target ontology). Mirrors the URI prefix heuristic used by explore_ontology.

Returns:

  • List of resources missing rdfs:label or skos:prefLabel (checked in both default graph and all named graphs)

When to use ontologyUri:

  • Pass the ontology URI (from list_ontologies) when checking a specific ontology to exclude imported resources. Resources imported from another ontology (e.g. a core class used as range) are NOT a quality issue of the importing ontology — they are defined, with their labels, in the originating ontology.

Note: Checks owl:Class, owl:ObjectProperty, owl:DatatypeProperty, and skos:Concept. Label lookup spans both the default graph and all named graphs to avoid false positives caused by label triples residing in a named graph different from where the type assertion was found.

False positive filtering: Resources that have only a bare type declaration (a owl:Class with no other properties) are automatically excluded. These are typically import stubs — classes or properties referenced from another module but never developed locally. Only resources with at least one non-type triple are flagged, ensuring the report covers entities that are being actively developed but are missing editorial metadata.

Inputs: limit, ontologyUri.

compare_coverage_with_okgCompare schema.gov.it Coverage with OKGA
Read-onlyIdempotent

Gap analysis: compare schema.gov.it semantic resources against the international OKG catalog for a given domain.

How it works:

  1. Fetches OKG resources for the given category

  2. For resources that have a Wikidata ID, queries schema.gov.it for matching owl:sameAs / skos:exactMatch links

  3. Classifies each OKG resource as "covered" (linked in schema.gov.it) or "gap" (not linked)

Args:

  • category: OKG thematic category to analyze

  • limit: Max OKG resources to fetch (default: 50)

Returns:

  • summary: total, covered count, gap count, coverage percentage

  • covered: OKG resources already linked in schema.gov.it (with local URI and relation type)

  • gaps: OKG resources with no corresponding link in schema.gov.it

  • without_wikidata: OKG resources without a Wikidata ID (cannot be cross-referenced automatically)

Available categories: fetched dynamically from api.openknowledgegraphs.com at runtime.

Use when: Assessing which international standards are missing in schema.gov.it for a specific domain, or prioritizing new ontology and vocabulary contributions.

Inputs: category (required), limit.

compare_local_with_remoteCompare Local Ontology with schema.gov.itA
Read-onlyIdempotent

Compare classes and/or properties defined in an ontology available on the server filesystem or through HTTP upload against schema.gov.it.

Args (provide exactly one of file_path or upload_id):

  • file_path: Absolute path on the MCP server filesystem. Use only if the server can really read that path.

  • upload_id: UUID returned by POST /upload. Use this in HTTP/remote mode when the ontology file is not present on the server.

  • type: What to compare — "classes" | "properties" | "all" (default: "classes")

  • limit: Max local items to check (default: 50)

Important for remote MCP servers:

  • file_path is not a transport mechanism. It works only for files visible to the server process.

  • If the ontology sits on the client machine, call get_upload_instructions, execute the curl command via Bash tool (without reading the file), then use the upload_id here.

  • Never copy ontology text into the conversation — use get_upload_instructions + Bash tool to send bytes directly.

Returns:

  • matched: URIs found in both local file and schema.gov.it (with Italian label if available)

  • local_only: URIs defined locally but absent from schema.gov.it

  • summary counts

Use when: Starting to build an ontology — quickly discover which of your classes/properties already exist in schema.gov.it so you can reuse or align them.

Inputs: type, limit, file_path, upload_id.

describe_resourceDescribe ResourceA
Read-onlyIdempotent

Get all triples for a resource (Concise Bounded Description).

Args:

  • uri: URI of the resource

  • depth: 1 for direct properties only, 2 to include linked resources (default: 1)

Returns:

  • All properties and values of the resource

When to use this vs X:

  • vs inspect_concept: use this when you need the raw RDF description of a resource; use inspect_concept when you want a semantic profile with hierarchy, usage, and inherited properties

  • vs query_sparql: use this for the standard CBD dump of one resource; use query_sparql only for custom graph patterns not covered here

Use when: You need the complete RDF description of a specific resource.

Inputs: uri (required), depth.

explore_catalogExplore CatalogA
Read-onlyIdempotent

List named graphs and ontologies available in the endpoint.

Args: None

Returns:

  • graphs: List of named graphs in the endpoint

  • ontologies: List of owl:Ontology and skos:ConceptScheme resources

When to use this vs X:

  • use this for a quick structural overview of the endpoint

  • use list_ontologies or list_vocabularies when you want richer, more task-oriented views of ontologies or vocabularies

Note: This tool returns TWO lists in one call (named graphs + ontology/vocabulary resources). Both queries run in parallel for performance.

Inputs: no named parameters.

explore_classesExplore ClassesA
Read-onlyIdempotent

List available classes in the ontology with instance counts.

Args:

  • limit: Maximum number of classes to return (default: 50)

  • filter: Optional regex filter for class URI (case-insensitive)

Returns:

  • List of classes with instance counts, ordered by count descending

Examples:

  • No args: Returns top 50 classes by instance count

  • filter="Person": Returns classes containing "Person" in URI

Inputs: limit, filter.

explore_datasetExplore DatasetA
Read-onlyIdempotent

Get details of a specific Dataset including metadata and distributions.

Use this for targeted DCAT-AP_IT inspection. On schema.gov.it, many datasets describe semantic assets, so this tool is usually secondary to ontology, vocabulary, class/property, and SPARQL exploration.

Args:

  • datasetUri: URI of the dataset to explore

Returns:

  • metadata: Dataset properties (literals and distribution references)

  • distributions: List of distributions with format and download URLs

Note: Both queries run in parallel for performance.

Inputs: datasetUri (required).

explore_external_endpointExplore External SPARQL EndpointA
Read-only

Explore the structure of an external SPARQL endpoint: discover its main classes and instance counts.

Args:

  • endpointUrl: URL of the SPARQL endpoint to explore (must be HTTPS)

  • limit: Maximum number of classes to return (default: 20)

Returns:

  • List of classes with instance counts, ordered by count descending

Security: Only HTTPS endpoints are allowed. Requests timeout after 15 seconds.

Use when: Getting a quick overview of what data an external endpoint contains before writing detailed queries.

Inputs: endpointUrl (required), limit.

explore_ontologyExplore OntologyA
Read-onlyIdempotent

List Classes and Properties defined in a specific Ontology.

Args:

  • ontologyUri: URI of the ontology (from list_ontologies)

Returns:

  • List of classes and properties with labels, grouped by type

Note: Uses URI prefix heuristic - items whose URI starts with the ontology URI.

Inputs: ontologyUri (required).

find_external_alignmentsFind External AlignmentsA
Read-onlyIdempotent

Find all alignment links from a concept in schema.gov.it toward external resources.

Args:

  • uri: URI of the concept in schema.gov.it

Returns:

  • concept: The queried URI

  • alignments: List of external URIs with relation type and domain (base URL)

Alignment types searched:

  • owl:sameAs (bidirectional)

  • skos:exactMatch

  • skos:closeMatch

  • skos:broadMatch

  • skos:narrowMatch

Use when: Understanding how a local concept maps to external systems (Eurostat, DBpedia, EU Publications Office, etc.)

Inputs: uri (required).

find_okg_alignmentsFind OKG Alignments for a schema.gov.it ResourceA
Read-onlyIdempotent

Given a schema.gov.it URI, find related resources in the Open Knowledge Graphs catalog.

How it works (3 steps):

  1. Queries schema.gov.it for the resource's label and any Wikidata alignments (owl:sameAs, skos:exactMatch)

  2. Searches OKG using the resource label

  3. Cross-references OKG results: those whose wikidataId matches a known alignment are "confirmed matches"; the rest are "candidates" (label-based, need manual review)

Args:

  • uri: URI of a schema.gov.it concept, class, or vocabulary

Returns:

  • label: The label used for OKG search

  • wikidata_alignments: Wikidata URIs already present in schema.gov.it for this resource

  • okg_matches: OKG resources with a confirmed Wikidata alignment (high confidence)

  • okg_candidates: OKG resources found by label search only (lower confidence)

Use when: Discovering international equivalents of a local ontology or vocabulary, or checking whether a schema.gov.it concept is represented in global semantic standards.

Inputs: uri (required).

find_relationsFind RelationsA
Read-onlyIdempotent

Find how two concepts are connected.

Args:

  • sourceUri: URI of the source concept

  • targetUri: URI of the target concept

  • max_hops: 1 | 2 | 3 (default: 1)

Returns:

  • Direct connections (single predicate)

  • Multi-hop paths up to the configured depth

Inputs: sourceUri (required), targetUri (required), max_hops.

find_semantic_softwareFind Semantic Software Tools (OKG)A
Read-onlyIdempotent

Search the Open Knowledge Graphs catalog for semantic web software tools.

OKG indexes semantic tools such as ontology editors, SPARQL engines, vocabulary managers, RDF converters, and reasoning engines — with version and release metadata. Data is CC0.

Args:

  • query: Search term (e.g. "SPARQL", "ontology editor", "SKOS", "RDF converter", "reasoner")

  • limit: Maximum results (default: 10)

Returns:

  • List of tools with title, description, latestVersion, releaseDate, homepage, licenses

Use when: Looking for open-source tools to validate ontologies, work with SKOS/OWL/RDF data, or build semantic applications on top of schema.gov.it content.

Inputs: query (required), limit.

get_property_detailsGet Property DetailsA
Read-onlyIdempotent

Get comprehensive details of a specific property from schema.gov.it, with explicit raw vs effective views.

Args:

  • propertyUri: URI of the property

  • mode: "raw" | "effective" (default: "effective")

  • source: "schema" | "local" | "hybrid" (default: "schema")

  • file_path / content / upload_id: local context when source="local" or source="hybrid"

Tip: Use search_concepts first if you do not know the URI.

mode: "raw" — only explicitly asserted triples:

  • definition: type, label, comment, rdfs:domain, rdfs:range, rdfs:subPropertyOf, owl:inverseOf, functional flags

mode: "effective" (default) — full inherited view, adds:

  • assertedDomain: rdfs:domain declared directly on this property

  • assertedRange: rdfs:range declared directly on this property

  • superproperties: ancestor chain via rdfs:subPropertyOf+, each with hasDomainLocally / hasRangeLocally flags

  • inheritedDomain: domain values from super-properties, each annotated with ancestor URI and label

  • inheritedRange: range values from super-properties, each annotated with ancestor URI and label

  • effectiveDomain: deduplicated union of assertedDomain + inheritedDomain

  • effectiveRange: deduplicated union of assertedRange + inheritedRange

  • redundancy_analysis: diagnostic view of each asserted value:

    • "redundant": identical to an inherited value — the axiom can be dropped without semantic loss

    • "specialization": a rdfs:subClassOf of an inherited value — genuinely narrows the domain/range

    • "new": not present in any inherited value — adds information not implied by the super-property chain

    • summary counts per category for quick overview

Interpreting the output:

  • If assertedDomain is empty but effectiveDomain is not → domain is inherited; no need to re-assert it on this property

  • If assertedDomain equals effectiveDomain → the domain is fully explicit, not relying on inheritance

  • Use redundancy_analysis.summary to immediately see if the local TTL has redundant axioms or genuine specializations

  • owl:equivalentProperty and owl:equivalentClass expansions are not included (use query_sparql for those)

Hybrid mode:

  • source="hybrid" uses the local/uploaded ontology as the base graph

  • it enriches missing super-property semantics from schema.gov.it when a super-property URI is known locally but absent from the local store

  • it still does not build a generic unified graph or guarantee full owl:imports resolution

When to use this vs X:

  • vs inspect_local_property: use this for a property already published in schema.gov.it; use inspect_local_property for a local/uploaded ontology

  • vs query_sparql: use this for the standard semantic profile of one property; use query_sparql only for custom questions not covered here

Inputs: propertyUri (required), mode, format, source, +3 more.

get_upload_instructionsGet Upload Instructions for Local OntologyA
Read-onlyIdempotent

Returns the exact curl command to upload a local RDF file to this MCP server and get back an upload_id — without the AI ever reading the file content.

CRITICAL — how to use this tool:

  1. Call this tool with the local file path

  2. Execute the returned curl_command via the Bash tool (do NOT read the file first, do NOT pass its content through the conversation)

  3. Parse the id field from the curl JSON output

  4. Pass the id as upload_id to inspect_local_ontology, query_local_ontology, compare_local_with_remote, or query_uploaded_store

Why this matters: Reading the file and sending its content through the AI conversation wastes tokens and may hit context limits. curl sends the raw bytes directly from the filesystem to the server — the AI never sees the content.

When to use this vs X:

  • use this only when the file is on the client machine and the MCP server cannot read it directly

  • if the server can already read the file, prefer file_path on the local ontology tools

  • if the file is small and you only need a quick summary, inspect_local_ontology with content + format may be enough

HTTP mode only: This workflow requires the MCP server to be running in HTTP mode (MCP_TRANSPORT=http). In stdio mode the HTTP endpoint is not available; use the content parameter of inspect_local_ontology for small files instead.

Docker / reverse-proxy: Set the MCP_PUBLIC_URL env var to the externally reachable base URL (e.g. http://localhost:8080). Without it, the tool falls back to the internal bind address which may be unreachable from outside the container.

Supported formats: .ttl (Turtle), .owl/.rdf (RDF/XML), .nt (N-Triples), .jsonld (JSON-LD), .graphol (Graphol XML)

Uploaded stores expire after 1 hour.

Inputs: file_path (required).

inspect_conceptInspect ConceptA
Read-onlyIdempotent

Get a comprehensive profile of a concept from schema.gov.it, with explicit raw vs effective views.

Args:

  • uri: URI of the concept to inspect

  • mode: "raw" | "effective" (default: "effective")

  • source: "schema" | "local" | "hybrid" (default: "schema")

  • file_path / content / upload_id: local context when source="local" or source="hybrid"

  • lang: "it" | "en" | "any" (default: "any")

Tip: Use search_concepts first if you do not know the URI.

mode: "raw" — only explicitly asserted triples:

  • definition: literal annotations (label, comment, definition…)

  • hierarchy: direct type, parent classes (rdfs:subClassOf / skos:broader), child classes

  • usage: instance count

  • own_properties: properties with rdfs:domain exactly this class

mode: "effective" (default) — full OWL/RDFS-implied view, adds:

  • inherited_properties: properties from ancestor classes via rdfs:subClassOf+/skos:broader+, each row annotated with the ancestor that declares domain (distinguishes asserted-on-this-class from inherited)

  • incoming: properties pointing to instances of this type (data-level)

  • outgoing: properties used by instances of this type (data-level)

Interpreting own vs inherited:

  • own_properties = rdfs:domain written explicitly for this class → if missing, the property may still apply via inheritance

  • inherited_properties = rdfs:domain written on an ancestor → redundant to re-assert on this class unless restricting range

  • A property absent from both may still apply via owl:restriction, owl:equivalentClass, or owl:unionOf/intersectionOf (not shown — use query_sparql for those cases)

Limitations of effective mode:

  • owl:equivalentClass: not expanded (equivalent classes share all properties but this tool shows only the rdfs:subClassOf chain)

  • owl:unionOf / owl:intersectionOf: not traversed (anonymous class expressions)

  • owl:imports: schema.gov.it resolves these server-side; the endpoint already includes imported triples

Hybrid mode:

  • source="hybrid" uses the local/uploaded ontology as the base graph

  • for effective mode it enriches missing inherited properties and labels from schema.gov.it when ancestor URIs are known locally

  • it does not create a fully unified graph and does not resolve arbitrary owl:imports chains

When to use this vs X:

  • vs inspect_local_concept: use this for concepts already in the remote schema.gov.it catalog; use inspect_local_concept for a local/uploaded ontology

  • vs describe_resource: use this for a semantic profile (hierarchy, inherited properties, usage); use describe_resource for the raw RDF dump of a resource

  • vs query_sparql: use this when you want the standard profile of one concept; use query_sparql only for custom questions not covered here

All queries run in parallel for performance.

Inputs: uri (required), lang, mode, format, +4 more.

inspect_local_conceptInspect Concept in Local / Uploaded OntologyA
Read-onlyIdempotent

Get a full profile of a class or concept from a local or uploaded ontology.

CRITICAL — file access workflow:

  1. Try file_path first (works only if the file is readable by the MCP server process).

  2. If file_path fails for any reason → call get_upload_instructions with the local path, execute the returned curl command via Bash tool, parse the id from the JSON response, then call this tool again with upload_id.

  3. NEVER read the file content and pass it through the conversation. NEVER attempt to parse or analyse the TTL text manually. The upload workflow sends raw bytes directly from disk to server without the AI ever seeing the content — it is always faster, cheaper, and more reliable.

Quale modalita di input usare:

  • stdio / stessa macchina → file_path

  • server remoto, file grande → get_upload_instructions + upload_id

  • server remoto, file piccolo (<1 MB) → valuta content + format con inspect_local_ontology, poi passa a upload se servono query ripetute

Args:

  • uri: URI of the class/concept to inspect

  • file_path / upload_id: exactly one (see workflow above)

  • mode: "raw" | "effective" (default: "effective")

Tip: Use search_concepts first if you are checking whether a similar concept already exists in schema.gov.it. Use this tool only after you know you want to inspect the local/uploaded ontology.

mode: "raw" — only triples explicitly present in the local file:

  • definition, hierarchy, usage, own_properties (rdfs:domain asserted directly on this class)

  • No ancestor traversal, no incoming/outgoing

mode: "effective" (default) — full OWL/RDFS-implied view:

  • All raw sections, plus:

  • inherited_properties: properties from superclasses via rdfs:subClassOf+/skos:broader+, each annotated with the ancestor that declares them

  • incoming / outgoing: data-level relations via instances

Distinguishing own vs inherited:

  • own_properties = rdfs:domain explicitly written as this class in the local file

  • inherited_properties = rdfs:domain written on an ancestor class (traversed via property paths)

  • Properties applicable only via owl:restriction or anonymous class expressions are NOT shown — use query_local_ontology for those

Limitation with owl:imports: inherited_properties traverses only superclasses present in the local file. Classes from imported external ontologies (e.g. l0:, COV:, CPV:) are absent from the local store unless the file includes them. For complete property semantics of a property that subPropertyOf an external one, use inspect_local_property instead — it falls back to schema.gov.it for missing super-properties.

When to use this vs X:

  • vs inspect_concept: use this for a local or uploaded ontology; use inspect_concept for the remote schema.gov.it catalog

  • vs query_local_ontology: use this when you want the standard profile of one concept; use query_local_ontology only for custom SPARQL questions not covered here

Unicode SPARQL note: oxigraph rejects prefixed names with non-ASCII local parts (e.g. myont:modalità_cup). Always use full URIs in angle brackets (<https://...#modalità_cup>) for properties or classes with Unicode in the local name.

Inputs: uri (required), mode, file_path, upload_id.

inspect_local_ontologyInspect Local OntologyA
Read-onlyIdempotent

Load and summarize an RDF/OWL ontology from the server filesystem, inline content, or an uploaded HTTP store (TTL, OWL/RDF-XML, NT, JSON-LD, Graphol XML).

Input (provide exactly one):

  • file_path: Absolute path on the MCP server filesystem. Use this only when the server process can really read that path (local stdio, same machine, or Docker with that directory mounted).

  • content + format: Raw RDF text sent inline. Works in remote HTTP mode too, but only for small payloads (max 1 MB).

  • upload_id: UUID returned by POST /upload. This is the preferred remote workflow when the ontology file is on the client machine instead of the server.

Important for remote MCP servers:

  • Do not assume file_path points to the user's laptop or local workstation.

  • If the MCP server runs on another machine/container and cannot access the file directly, call get_upload_instructions first, execute the returned curl command via Bash tool (do NOT read the file), then use the upload_id here.

  • Prefer upload_id over trying many path variants when access to the original file is uncertain.

  • Never read the file content and relay it through the conversation — this wastes tokens. Use get_upload_instructions + Bash tool instead.

format values: "text/turtle" (default), "application/rdf+xml", "application/n-triples", "application/ld+json", "application/graphol+xml"

Returns:

  • File info: format, triple count, source

  • Classes: defined owl:Class / rdfs:Class with instance counts (top 20)

  • Properties: count of object and datatype properties

  • Namespaces used

Efficiency: file_path results are cached by mtime; repeated calls on unchanged files skip re-parsing.

Inputs: format, content, file_path, upload_id.

inspect_local_propertyInspect Property in Local / Uploaded OntologyA
Read-onlyIdempotent

Get the full semantic profile of a property from a local or uploaded ontology, resolving inherited domain and range via rdfs:subPropertyOf+.

CRITICAL — file access workflow:

  1. Try file_path first (works only if the file is readable by the MCP server process).

  2. If file_path fails for any reason → call get_upload_instructions with the local path, execute the returned curl command via Bash tool, parse the id from the JSON response, then call this tool again with upload_id.

  3. NEVER read the file content and pass it through the conversation. NEVER attempt to parse or analyse the TTL text manually. The upload workflow sends raw bytes directly from disk to server without the AI ever seeing the content — it is always faster, cheaper, and more reliable.

Quale modalita di input usare:

  • stdio / stessa macchina → file_path

  • server remoto, file grande → get_upload_instructions + upload_id

  • server remoto, file piccolo (<1 MB) → valuta content + format con inspect_local_ontology, poi passa a upload se servono query ripetute

Tip: Use search_concepts first if you are checking whether an equivalent property already exists in schema.gov.it. Use this tool only after you know you want to inspect the local/uploaded ontology.

Returns:

  • definition: direct attributes from the local store (type, label, comment, subPropertyOf, inverseOf, functional flags)

  • assertedDomain: rdfs:domain declared directly on this property in the local file

  • assertedRange: rdfs:range declared directly on this property in the local file

  • superproperties: ancestor chain via rdfs:subPropertyOf+; each entry has source:

    • "local" = found in the local store

    • "remote" = not in local file, resolved from schema.gov.it

    • "not-found" = absent from both

  • inheritedDomain: domain values collected from super-properties, each annotated with ancestor URI and source

  • inheritedRange: range values collected from super-properties, each annotated with ancestor URI and source

  • effectiveDomain: deduplicated union of assertedDomain + inheritedDomain

  • effectiveRange: deduplicated union of assertedRange + inheritedRange

  • redundancy_analysis: diagnostic view of each asserted value:

    • "redundant": identical to an inherited value — the axiom can be dropped without semantic loss

    • "specialization": a rdfs:subClassOf of an inherited value — genuinely narrows the domain/range

    • "new": not present in any inherited value — adds information not implied by the super-property chain

  • summary counts per category for quick overview

  • warnings: super-properties not resolved, remote lookup failures

owl:imports handling: The local store typically does NOT contain imported ontologies (owl:imports declarations are not followed automatically). Super-properties from external namespaces (e.g. l0:name, l0:description from OntoPiA) are resolved against schema.gov.it automatically, making the effective semantics complete without requiring the full import chain to be loaded.

Use case — subproperty chains: For properties like ha_cup_collegato_per_fusione rdfs:subPropertyOf ha_cup_collegato, this tool shows whether domain/range are asserted directly, inherited from ha_cup_collegato, or need remote resolution. For subPropertyOf l0:name, it fetches l0:name's domain/range from schema.gov.it and shows it as source "remote".

When to use this vs X:

  • vs get_property_details: use this for a local or uploaded ontology; use get_property_details for a property already published in the remote schema.gov.it catalog

  • vs query_local_ontology: use this when you want the standard semantic profile of one property; use query_local_ontology only for custom SPARQL questions not covered here

Unicode SPARQL note: oxigraph rejects prefixed names with non-ASCII local parts. For properties with Unicode in the local name (e.g. myont:modalità_cup), always pass the full URI in angle brackets (<https://...#modalità_cup>).

Inputs: uri (required), file_path, upload_id.

list_datasetsList DatasetsA
Read-onlyIdempotent

List available Datasets (dcatapit:Dataset) in the catalog.

Use this when you explicitly need DCAT-AP_IT dataset records. On schema.gov.it, these are often semantic assets such as ontologies, controlled vocabularies, and related distributions rather than classic tabular datasets, so ontology/vocabulary/SPARQL tools are usually a better starting point.

Args:

  • limit: Maximum datasets per page (default: 20)

  • offset: Number of datasets to skip (default: 0)

Returns:

  • items: List of datasets with labels

  • pagination: Metadata with count, offset, has_more, next_offset

Inputs: limit, offset.

list_identifiersList IdentifiersA
Read-onlyIdempotent

List CLV Identifier resources by type, with counts and sample values.

Args:

  • identifierType: (optional) Filter by identifier type string (e.g. "Codice Catastale", "Sigla Automobilistica")

  • limit: Maximum results (default: 20)

Returns:

  • If no identifierType: Summary of all identifier types with counts

  • If identifierType provided: Sample identifiers of that type with their values and linked entities

Use when: Exploring the clv:Identifier resources and their identifierType values in the triplestore.

Inputs: limit, identifierType.

list_instances_of_classList Instances of ClassA
Read-onlyIdempotent

List instances of a given class in the catalog.

Args:

Returns:

  • instances: list of URIs with labels

  • pagination: total count, offset, has_more

Use when: You found a class and want to know if it has real instances (i.e., whether it is used in the catalog, not just defined theoretically).

Inputs: class_uri (required), limit, offset.

list_linked_endpointsList Linked SPARQL EndpointsA
Read-onlyIdempotent

Discover SPARQL endpoints referenced in the schema.gov.it catalog via dcat:DataService.

Args: None

Returns:

  • List of data services with endpoint URL, title, description, and conformsTo standard

Use when: Exploring what external SPARQL endpoints are connected to the Italian PA semantic catalog.

Inputs: no named parameters.

list_municipalitiesList MunicipalitiesA
Read-onlyIdempotent

Browse Italian municipalities (comuni) with their codes.

Args:

  • limit: Items per page (default: 50, max: 500)

  • offset: Items to skip (default: 0)

  • keyword: (optional) Filter by name (case-insensitive)

  • withBelfiore: (optional) If true, include Belfiore/cadastral codes via URI extraction (slower)

  • lang: "it" | "en" | "any" (default: "any")

Returns:

  • municipalities: List of cities with ISTAT code, name, and optionally Belfiore code

  • pagination: Total count, offset, has_more

Note: Uses BIND+REPLACE URI extraction for Belfiore codes to avoid Virtuoso timeout on identifierType joins. Each ISTAT code may appear with multiple historical names; results are deduplicated by notation.

Inputs: lang, limit, offset, keyword, +1 more.

list_okg_categoriesList OKG Thematic CategoriesA
Read-onlyIdempotent

Fetch the available thematic categories from the Open Knowledge Graphs (OKG) catalog.

Returns: List of category names that can be used as filters in search_okg_resources and compare_coverage_with_okg.

Use when: You need to know which categories are available before filtering OKG searches.

Inputs: no named parameters.

list_ontologiesList OntologiesA
Read-onlyIdempotent

List available Ontologies (Data Models) and their titles.

Args:

  • limit: Maximum number of ontologies to return (default: 50)

  • normalize_trailing_slash: If true, merge ontology IRIs that differ only by a final "/" (default: true)

  • include_variants: If true and normalization is enabled, include raw URI variants to expose catalog inconsistencies

Returns:

  • List of ontology URIs with labels/titles, ordered alphabetically

Note: Some ontologies are duplicated in the catalog with and without a trailing slash. By default this tool normalizes them, but you can inspect the raw variants when cleaning the catalog.

Inputs: limit, include_variants, normalize_trailing_slash.

list_propertiesList PropertiesA
Read-onlyIdempotent

List ObjectProperty and DatatypeProperty defined in an ontology or globally.

Args:

  • ontologyUri: (optional) URI of the ontology to filter by

  • propertyType: (optional) "object", "datatype", or "both" (default: "both")

  • limit: Maximum results (default: 50)

Returns:

  • List of properties with domain, range, and label

Examples:

Inputs: limit, ontologyUri, propertyType.

list_provincesList ProvincesA
Read-onlyIdempotent

List Italian provinces with their codes (ISTAT, car plate, metropolitan city).

Args:

  • keyword: (optional) Filter by province name (case-insensitive)

  • lang: "it" | "en" | "any" (default: "any")

Returns:

  • List of provinces with notation (ISTAT code), name, sigla (car plate), and metro code (if metropolitan city)

Note: Runs 3 parallel queries for names, car plates, and metro codes, then joins client-side. There are ~107 provinces, 14 of which are metropolitan cities.

Inputs: lang, keyword.

list_vocabulariesList VocabulariesA
Read-onlyIdempotent

List available Controlled Vocabularies (ConceptSchemes) and their instance counts.

Args:

  • limit: Maximum vocabularies to return (default: 20)

Returns:

  • List of ConceptSchemes with labels and concept counts, ordered by count descending

Inputs: limit.

preview_distributionPreview DistributionA
Read-onlyIdempotent

Download and preview the first rows of a distribution file.

Most useful after you already identified a concrete distribution URL. On schema.gov.it, distributions often belong to semantic assets rather than classic tabular datasets.

Args:

  • url: Download URL of the distribution (CSV or JSON)

Returns:

  • Preview of first 10-15 rows/items of data

Supported formats: CSV, JSON (auto-detected by content-type or extension) Timeout: 10 seconds

Inputs: url (required).

query_external_endpointQuery External SPARQL EndpointA
Read-onlyIdempotent

Execute a SPARQL query against any public HTTPS SPARQL endpoint.

Args:

  • endpointUrl: URL of the target SPARQL endpoint (must be HTTPS)

  • query: SPARQL query to execute

  • injectPrefixes: Whether to inject schema.gov.it standard prefixes (default: false)

Returns:

  • Compressed SPARQL results in the same format as internal tools

Security: Only HTTPS endpoints are allowed. Requests timeout after 15 seconds.

Examples:

When to use this vs X:

  • vs query_sparql: use this only for an external HTTPS endpoint; use query_sparql for the built-in schema.gov.it endpoint

  • vs explore_external_endpoint: use this when you already know the query you want to run; use explore_external_endpoint first if you just need a structural overview

Do not use this if:

  • you want to query schema.gov.it itself → use query_sparql

  • you want a curated shortlist of endpoints → use recommend_external_endpoints

  • you only need endpoints already linked in the catalog metadata → use list_linked_endpoints

Inputs: query (required), endpointUrl (required), injectPrefixes.

query_local_ontologyQuery Local OntologyA
Read-onlyIdempotent

Execute a SPARQL SELECT query against an ontology available on the server filesystem or through HTTP upload.

Quale modalita di input usare:

  • stdio / stessa macchina → file_path

  • server remoto, file grande → get_upload_instructions + upload_id

  • server remoto, file piccolo (<1 MB) → usa inspect_local_ontology con content + format per l'analisi; per query ripetute preferisci upload + upload_id

Args (provide exactly one of file_path or upload_id):

  • file_path: Absolute path on the MCP server filesystem. Use only if the server can really read that path.

  • upload_id: UUID returned by POST /upload. Use this in HTTP/remote mode when the file is local to the client, not the server.

  • query: SPARQL SELECT query

  • inject_prefixes: Inject standard prefixes (rdf, rdfs, owl, skos, dct…) — default true

Important for remote MCP servers:

  • If a direct file path is not accessible from the server, do not keep retrying with alternative local paths.

  • Call get_upload_instructions with the file path, execute the returned curl command via Bash tool (do NOT read the file first), then use the upload_id here.

  • Never relay the file content through the conversation — this wastes tokens. curl sends bytes directly from disk to server.

Returns:

  • Compressed SPARQL results (tabular for >5 rows, compact for ≤5 rows)

When to use this vs X:

  • vs query_sparql: use this for a local/uploaded ontology; use query_sparql for the default remote catalog

  • vs query_uploaded_store: prefer this tool when you already have an upload_id; query_uploaded_store is only a thinner upload-specific path

Do not use this if:

  • you need a standard profile of a concept or property → use inspect_local_concept or inspect_local_property

  • you just need a summary of the ontology → use inspect_local_ontology

Supported formats: .ttl (Turtle), .owl / .rdf (RDF/XML), .nt (N-Triples), .jsonld (JSON-LD), .graphol (Graphol XML) Efficiency: File is cached after first load; repeated queries on the same unchanged file skip re-parsing. Note: Standard prefixes (rdf, rdfs, owl, skos…) are injected automatically unless inject_prefixes=false.

Inputs: query (required), file_path, upload_id, inject_prefixes.

query_sparqlExecute SPARQL QueryA
Read-onlyIdempotent

Execute a RAW SPARQL query against schema.gov.it.

Args:

  • query: The SPARQL query to execute (prefixes are auto-injected)

  • source: "schema" | "local" | "hybrid" (default: "schema")

  • file_path / content / upload_id: local context when source="local"

Returns:

  • Compressed JSON result (tabular for >5 rows, object array otherwise)

Examples:

  • SELECT ?s ?p ?o WHERE { ?s ?p ?o } LIMIT 10

  • SELECT ?class (COUNT(?s) AS ?count) WHERE { ?s a ?class } GROUP BY ?class

When to use this vs X:

  • vs query_local_ontology: use this for the default remote catalog schema.gov.it; use query_local_ontology for a file/store loaded locally or via upload_id

  • vs query_external_endpoint: use this for the built-in schema.gov.it endpoint; use query_external_endpoint only for another HTTPS SPARQL endpoint

  • vs specialized tools: use this only when no dedicated tool already covers the task

Do not use this if:

  • you need a concept profile → use inspect_concept

  • you need property semantics → use get_property_details

  • you need to search by keyword without a known URI → use search_concepts

  • you need to browse a vocabulary or dataset → use the dedicated vocabulary/dataset tools

Important: raw hybrid SPARQL is not supported yet. Use source="hybrid" only on specialized concept/property tools, not here.

Note: Use this for ad-hoc exploration. Prefer specialized tools for common operations.

Inputs: query (required), format, source, content, +2 more.

query_uploaded_storeQuery Uploaded StoreA
Read-onlyIdempotent

Execute a SPARQL SELECT query against a temporary ontology store created via HTTP upload.

Workflow (HTTP mode only):

  1. Call get_upload_instructions with the local file path → get the curl command

  2. Execute the curl command via Bash tool (file bytes go directly to the server, no AI token consumption)

  3. Parse the id from the curl response

  4. Use id here to run SPARQL queries, OR pass it as upload_id to inspect_local_ontology, query_local_ontology, compare_local_with_remote

When to use this workflow:

  • The MCP server is remote, containerized, or otherwise cannot read the user's local filesystem.

  • A previous file_path attempt failed because the path only exists on the client machine.

  • You want to send raw file bytes directly without consuming model tokens.

When to use this vs X:

  • prefer query_local_ontology with upload_id for the main MCP workflow

  • use this only if you already have the upload store id and explicitly want to query that temporary store directly

Deprecated direction: this is an upload-specific shortcut; for new agent flows prefer query_local_ontology with upload_id

Supported Content-Types for upload: text/turtle, application/rdf+xml, application/n-triples, application/ld+json, application/graphol+xml

Notes:

  • Uploaded stores are kept for 1 hour then evicted

  • Standard prefixes (rdf/rdfs/owl/skos/dct/xsd/dcat/foaf/clv/cpv/l0/sm) are auto-injected

  • The same store is also queryable directly via GET /sparql/<id>?query=...

Inputs: id (required), query (required).

recommend_external_endpointsRecommend External SPARQL EndpointsA
Read-onlyIdempotent

Return a curated list of useful public SPARQL endpoints to pair with schema.gov.it.

Args:

  • category: (optional) Filter by endpoint family: "italian-pa", "eu", or "knowledge-graph"

  • limit: Maximum results (default: 10)

Returns:

  • Curated endpoint recommendations with rationale, suggested use cases, and example query ideas

Use when: You want a high-signal shortlist of external endpoints before using query_external_endpoint or explore_external_endpoint.

Inputs: limit, category.

resolve_territorial_uriResolve Territorial URIA
Read-onlyIdempotent

Resolve an Italian territorial code to its canonical CLV URI with labels and related URIs.

Args:

  • code_type: Type of code: "istat-comune", "istat-provincia", "istat-regione", or "belfiore"

  • code: The code value (e.g. "046030" for ISTAT comune, "F205" for Belfiore)

  • date: (optional) ISO date string (e.g. "2022-08-12") — noted in output, full temporal filtering not yet implemented

Returns:

  • uri: canonical CLV URI

  • name: official name

  • code_type and code

  • related: connected territorial URIs (province for cities, region for provinces)

  • date_note: reminder if date was provided

Use when: You have a raw territorial code (ISTAT or Belfiore) and need the official semantic URI to use in JSON-LD or RDF modeling.

Inputs: code (required), code_type (required), date.

search_conceptsSearch ConceptsA
Read-onlyIdempotent

Fuzzy search for concepts/classes/properties by keyword.

Args:

  • keyword: Search term (e.g. 'amministrazione')

  • limit: Maximum results (default: 10)

  • resource_type: (optional) Filter by type: "class", "property", "concept"

  • ontology_filter: (optional) URI prefix to restrict the search (e.g. 'https://w3id.org/italia/onto/COV/')

  • prefer_core: (optional) If true, results from core ontologies (COV, CPV, CLV, l0) are ranked first

  • lang: "it" | "en" | "any" (default: "any")

Returns:

  • Matching subjects with type and label

When to use this vs X:

  • use this when you do not know the exact URI yet

  • vs search_in_vocabulary: use this to search across the whole catalog; use search_in_vocabulary or browse_vocabulary only when the ConceptScheme is already known

Use when: You don't know the exact URI of a concept. Use resource_type and ontology_filter to reduce noise.

Inputs: keyword (required), lang, limit, prefer_core, +2 more.

search_in_vocabularySearch in VocabularyA
Read-onlyIdempotent

Search for concepts within a specific Controlled Vocabulary (ConceptScheme).

Args:

  • schemeUri: URI of the ConceptScheme (from list_vocabularies)

  • keyword: Search term for label matching (case-insensitive regex)

  • limit: Maximum results (default: 20)

  • lang: "it" | "en" | "any" (default: "any")

Returns:

  • Matching concepts with labels and optional notation codes

When to use this vs X:

  • vs browse_vocabulary: use this only for a quick keyword search inside a scheme you already know

  • browse_vocabulary is usually the better default because it supports pagination and already accepts keyword

Deprecated: Deprecated. Usa browse_vocabulary con il parametro keyword.

Inputs: keyword (required), schemeUri (required), lang, limit.

search_okg_resourcesSearch Open Knowledge Graphs ResourcesA
Read-onlyIdempotent

Search the Open Knowledge Graphs (OKG) catalog for ontologies, vocabularies, and taxonomies.

OKG indexes 1800+ semantic resources with metadata sourced from Wikidata. All data is CC0.

Args:

  • query: Search term (required)

  • category: Optional thematic category filter

  • type: Optional resource type filter ("Ontology", "ControlledVocabulary", "Taxonomy")

  • limit: Maximum results (default: 20)

Returns:

  • List of resources with title, wikidataId, description, category, homepage, licenses, types

Available categories: fetched dynamically from api.openknowledgegraphs.com at runtime.

Use when: Discovering international ontologies and vocabularies in a domain before aligning with schema.gov.it resources. Pair with find_okg_alignments or compare_coverage_with_okg.

Inputs: query (required), type, limit, category.

suggest_improvementsSuggest ImprovementsA
Read-onlyIdempotent

Analyze the ontology for structural issues.

Args:

  • limit: Maximum issues per category (default: 20)

Returns:

  • possible_cycles: Classes with mutual rdfs:subClassOf

  • unused_classes: Classes with no instances and no subclasses

  • properties_missing_domain_or_range: Properties with incomplete domain/range declarations

  • large_classes_without_scheme: Classes with >1000 instances and no evidence of skos:ConceptScheme membership

Note: Both analyses run in parallel.

Inputs: limit.

suggest_new_toolsSuggest New ToolsB
Read-only

Analyze usage logs to suggest new specialized tools.

Args: None

Returns:

  • List of recommendations based on frequently queried types in raw SPARQL

Note: Requires at least 2 queries for the same type to suggest a tool.

Inputs: no named parameters.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.9/5.0

    Scored across 47 tools

    Disambiguation3/5

    Many tools have distinct purposes, but there are several overlapping pairs (e.g., query_sparql vs query_local_ontology vs query_external_endpoint; inspect_concept vs inspect_local_concept). The descriptions help differentiate, but with 47 tools an agent may still struggle to select the correct one.

    Naming Consistency4/5

    Tool names follow a consistent verb_noun pattern with underscores (e.g., list_ontologies, explore_classes). A few names are longer phrases (find_recommended_scheme_for_property), but overall the pattern is predictable.

    Tool Count3/5

    At 47 tools, the count is high for a single server. While the domain is broad (semantic catalog, external endpoints, OKG, territorial codes), many tools are specialized. The count is borderline between 'slightly over' and 'too many' for typical use.

    Completeness4/5

    The tool set covers a wide range: SPARQL execution, ontology/vocabulary/dataset exploration, quality checks, coverage analysis, external endpoint integration, and OKG catalog interaction. Missing reasoning or classification tools, but the surface is largely complete for the stated catalog purpose.

    Maintenance

    ActivityNo data
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      A
      maintenance
      Enables AI assistants to search, explore, and query any CKAN open data portal through natural language, making public datasets accessible without requiring knowledge of the portal's API.
      20
      2,377 npm
      61
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Enables LLMs to access and analyze Italian statistical data from ISTAT via natural language queries, supporting dataset discovery, exploration, and data retrieval.
      9
      18 PyPI
      2
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables querying Italy's open data portal (dati.gov.it) via its CKAN API, providing access to thematic categories and datasets.
      105 npm
      MIT