MCP with Claude Code
Install
Install the runtime first:
npx ontoskills install mcpThis gives you the managed runtime binary:
~/.ontoskills/bin/ontomcpRegister the server
Fastest bootstrap:
npx ontoskills install mcp --claudeManual equivalent:
claude mcp add --scope user ontomcp -- \ ~/.ontoskills/bin/ontomcpProject-local instead:
npx ontoskills install mcp --claude --projectIf you want to force a specific ontology root manually:
claude mcp add --scope user ontomcp -- \ ~/.ontoskills/bin/ontomcp --ontology-root ~/.ontoskills/ontologiesVerify
claude mcp get ontomcpclaude mcp listExpected state:
Status: ✓ ConnectedWhat Claude Code can use
Once connected, Claude Code can call:
ontoskill— unified skill discovery and context retrieval. Pass a skill ID (e.g.pdf) for full context, or a natural language query (e.g.create a pdf document) for BM25 search.
This single tool replaces the previous 5-tool workflow (search, get_skill_context, evaluate_execution_plan, query_epistemic_rules, prefetch_knowledge).
Troubleshooting
Connection fails
Check:
~/.ontoskills/bin/ontomcpexists~/.ontoskills/ontologies/existsindex.enabled.ttlor compiled.ttlfiles exist
Ontology not found
Run with an explicit root:
~/.ontoskills/bin/ontomcp --ontology-root ~/.ontoskills/ontologiesRebuilt binary but Claude still behaves strangely
Remove and re-add the MCP server, or restart Claude Code. A stale background process can keep the old binary alive.