Tools are under-specified
Without task preconditions and effects, agents can call the right-looking tool at the wrong time.
Skill for AI agents
A portable AI-agent skill that extracts agent-ready domain models from product docs, APIs, companies, markets, and codebases. Use it with Claude Code, Codex, Cursor, custom agent runners, or any capable agent that can follow AGENT_SKILL.md.
The pain
Agents get tool names. RAG gets chunks. Databases get tables. But the system often lacks a shared map of what the business means, what can happen, and what software objects are allowed to touch it.
Without task preconditions and effects, agents can call the right-looking tool at the wrong time.
Chunks know words, not concepts. "What is a refund?" and "how do I process a refund?" get mixed.
Tables and API types encode implementation details, but not the business concepts they represent.
What it does
The skill gives an agent an operating procedure: mine evidence, build a four-layer ontology, validate the structure, then emit the format your system needs.
Docs, APIs, source code, DB schema, job posts, help centers, standards, events, tests, and tool schemas.
Upper anchors, domain nouns, task verbs, and app bindings tied together with evidence.
MCP tool schemas, RAG metadata, graph schemas, JSON-LD, TypeScript/Pydantic types, and diagrams.
Quick start
Lead with the consumer. The agent should know whether the output is for agent tools, MCP, RAG, a knowledge graph, DB/API design, or documentation.
Use AGENT_SKILL.md as your workflow. Target: [company, codebase, product, API, docs, or market]. Consumer: [MCP agent tools, RAG, knowledge graph, DB/API schema, or docs]. Boundary: [what is in and out]. Deliver the YAML layers, mappings, validation notes, and the consumer binding.
# Universal agent usage
Give the agent AGENT_SKILL.md as instructions.
# Optional packaged-skill usage
unzip ontology-extraction.skill -d ./skills
cd ./skills/ontology-extraction
python scripts/scaffold.py init \
--name my-target \
--out ../../my-target-ontology
python scripts/scaffold.py validate ../../my-target-ontology
python scripts/scaffold.py mappings ../../my-target-ontology
Proof
These are the examples to put near the top of the GitHub repo. They make the agent skill feel concrete in the first scroll.
Extracts Charge, Refund, Dispute, Evidence, Customer, and MerchantAccount, then maps tasks into MCP-friendly support operations.
Maps Prisma models and Express routes to Member, Article, Comment, Tag, Follow, and Favorite concepts.
Finds no strong published ontology, then recommends fresh L1 modeling with L3 alignment to Gnosis CTF vocabulary.
Why builders care
The launch angle is simple: do not let an AI agent act inside a business it does not understand.
L2 tasks become tools. Preconditions and effects become descriptions the model can reason over before acting.
L1 concepts and L2 tasks become filters, routing labels, and chunk tags that make retrieval less sloppy.
Every L3 object must bind upward. Unmapped fields expose app-only details, missing concepts, or stale schema.
Public docs, APIs, pricing pages, and job posts become a structured map of how a company operates.
The skill reuses schema.org, gist, PROV-O, FIBO, FHIR, GS1, and other vocabularies where they fit.
Product, engineering, data, docs, and agents all get the same names for the same business objects.
Repo packaging
Put the examples and validator close to the top. Make the first minute feel obvious.
agent-ontology-kit/
README.md
LICENSE
AGENT_SKILL.md
ontology-extraction.skill
ontology-extraction/
SKILL.md
scripts/
scaffold.py
references/
output-formats.md
reuse-catalog.md
source-mining.md
examples/
stripe-support-agent/
realworld-express/
prediction-markets/
docs/
guide.html
launch.html
screenshots/
hero.png
examples.png
Paste-ready opener
This is the kind of opening that makes the project feel immediately useful instead of academic.
# Agent Ontology Kit
Make AI agents understand a business before they act.
Agent Ontology Kit is a portable skill for AI agents. It extracts
structured, agent-ready domain models from product docs, APIs,
companies, markets, and codebases.
Use it from Claude Code, Codex, Cursor, custom agent runners, or any
capable AI agent through AGENT_SKILL.md. Humans can also run the YAML
templates and validator script directly.
It produces a four-layer ontology:
- L0 upper anchors: universal categories like Agent, Event, Object
- L1 domain concepts: the nouns of the business
- L2 tasks: the verbs, workflows, preconditions, and effects
- L3 application bindings: DB tables, API types, events, tool schemas,
UI objects, and field mappings
Use it to generate:
- safer MCP tool schemas
- RAG metadata and routing labels
- knowledge graph schemas
- DB/API semantic mappings
- codebase audit notes
- market/company structure maps
Why this matters:
Most agent projects define tools before defining the world those tools
operate in. This skill gives the agent a grounded map first.