Skip to main content
The Knowledge Graph MCP Server implements the Model Context Protocol ↗ for K-12 educational data. Instead of relying on model recall, the MCP Server relies on tools ↗ and structured Knowledge Graph data to:

What you’ll need

  • MCP Server URL:
    https://kg.mcp.learningcommons.org/mcp
    
  • API keys generated in the Learning Commons Platform ↗ to include in your request headers for authentication:
    x-api-key: YOUR_API_KEY
    
    or
    Authorization: Bearer YOUR_API_KEY
    
    If using an SDK, verify how to pass in the MCP authorization key for your client.

Steps

1

Set up environment variables

.env
OPENAI_API_KEY=sk-...
MCP_AUTH_KEY=your_learning_commons_api_key
MCP_SERVER_URL=https://kg.mcp.learningcommons.org/mcp
2

Connect to the MCP server

Make a request to the MCP server with your question — for example, asking about skills and unfinished learning for California standard 4.OA.A.3:
import os
import requests
from dotenv import load_dotenv

load_dotenv()

openai_api_key = os.getenv("OPENAI_API_KEY")
mcp_server_url = os.getenv("MCP_SERVER_URL")
mcp_auth_key   = os.getenv("MCP_AUTH_KEY")

input_prompt = "I am a 4th grade teacher in California. A new student in my class is struggling with the concepts related to 4.OA.A.3. What are the skills required for mastery and what potential unfinished learning should I address?."

response = requests.post(
  "https://api.openai.com/v1/responses",
  headers={
    "Content-Type":  "application/json",
    "Authorization": f"Bearer {openai_api_key}",
  },
  json={
    "model": "gpt-4o",
    "tools": [
      {
        "type": "mcp",
        "server_label": "learning-commons-kg",
        "server_url": mcp_server_url,
        "require_approval": "never",
        "headers": { "x-api-key": mcp_auth_key }
      }
    ],
    "input": input_prompt
  }
)

print(response.status_code)
for item in response.json()["output"]:
  if item["type"] == "mcp_call":
    print(f"Tool called: {item['name']}")
    print(f"Arguments:   {item['arguments']}")
    print(f"Result:      {item['output']}")
  elif item["type"] == "message":
    print(f"Answer: {item['content'][0]['text']}")
3

Review the response

Your AI client will call Knowledge Graph MCP tools to return structured results (e.g., Academic Standard statements, Learning Components, or Learning Progressions).Inspect mcp_call output entries for tool names, arguments, and results.

Tools

Please review the Knowledge Graph License before using these tools.
The MCP server contains the following tools ↗, which can be used individually or in sequence:
ToolDescription
Find Academic Standard statementResolves an education standard code into its authoritative statement and metadata, optionally scoped to a jurisdiction
Find Learning Components from standardBreaks a broad standard down into granular Learning Components that represent individual teachable skills
Find Learning Progressions from standardIdentifies prior or subsequent standards in a learning progression, based on the Student Achievement Partners (SAP) Coherence Map for Mathematics
A common workflow may use all 3 tools:
  • Resolving a standard code to its official statement
  • Retrieving the associated learning components for targeted instruction
  • Tracing progressions to identify prior or follow-on standards

Inputs

ToolFieldTypeRequiredDescription
Find Academic Standard statementstatementCodestringe.g., RI.5.2 or 8.F.B.4
jurisdictionstringJurisdiction where standard is adopted (e.g., Maryland)
Find Learning Components from standardcaseIdentifierUUIDstringUUID of the standard in the CASE Network
Find Learning Progressions from standardcaseIdentifierUUIDstringUUID of the standard in the CASE Network
directionstringbackward for prerequisites and forward for subsequent