AGENT SKILL

ontology-validator

Use when validating tool outputs or data against a domain ontology or structured knowledge base. Ensures entities, types, and relations are consistent before side effects.

License 许可
MIT
最近更新
2026-11-15
Stars
★ 0
Forks
1

01 前言 Front Matter

name
ontology-validator
triggers
[ "user", "model" ]
description
Use when validating tool outputs or data against a domain ontology or structured knowledge base. Ensures entities, types, and relations are consistent before side effects.

02 资源文件 1

03 SKILL.md 正文

Ontology Validator

Validates that tool outputs and data changes are consistent with a domain ontology or structured knowledge base. Complements Pydantic (schema/type checking) with domain-level reasonableness.

When to use

  • After a tool returns a result that will drive a side effect (write, DB insert, API call).
  • When the system has a knowledge.json or similar structured knowledge base.
  • When entity types, statuses, or relationships must be enforced.
  • When duplicate operations must be prevented.

Core rule

Pydantic at the door, ontology at the ledger.

  • Pydantic (or equivalent) validates types and required fields at the boundary.
  • Ontology validates domain-level reasonableness: valid statuses, entity types, disjoint relationships, no duplicates.

What to check

  1. Entity type consistency. Is the returned entity type valid for this domain?
  2. Status validity. Is the status value allowed (e.g., pending, in_progress, completed)?
  3. Relationship validity. Does the relation type make sense (e.g., contains, depends_on)?
  4. Duplicate prevention. Would this operation create a duplicate entity or relation?
  5. Disjointness. Are two entities that should be disjoint being treated as the same?

Process

Tool returns result
  → Pydantic/schema check (types, required fields)
  → Ontology check (entity type, status, relation, duplicates)
  → If both pass: proceed to side effect
  → If either fails: return to model or human for correction

Example

# Pydantic validates the shape
class Ticket(BaseModel):
    id: str
    status: Literal["pending", "in_progress", "completed"]

# Ontology validates the domain
if ticket.status == "completed" and ticket.depends_on_open():
    raise ValueError("Cannot complete ticket with open dependencies")

Anti-patterns

  • Trusting tool output without domain validation.
  • Treating Pydantic as sufficient for domain rules.
  • Skipping duplicate checks when creating entities.
  • Assuming all relations are valid because the schema allows them.

Cross-skills

  • verification-before-completion - use as final gate before claiming done.
  • structured-knowledge-extraction - provides knowledge.json for ontology checks.
  • security-audit - ontology can flag insecure states (e.g., status: public on a secret).

04 同仓库更多 Skills

Leostruka
Leostruka/devin-bundle

montador-de-ideias

Use when assembling, expanding, or elevating a raw project idea or initial prompt into an ultra-detailed, first-principles dossier and compiled master prompt with journalistic OSINT market research, Tech Lead and Staff Architect justifications, atomic and modular hardening/optimization, and high-impact contact surfaces.

★ 0
Leostruka
Leostruka/devin-bundle

git-github-adaptive-engineering

Use when any task touches git history, GitHub issues/PRs/releases/CI, repo governance, or branch and merge decisions. Runs the Fase Zero situational-awareness battery, picks one of five delivery flows via the adaptive decision engine, and enforces commit/PR information-density standards. Orchestrates the gh, git-workflows, github-actions, pr, and debug/finish skills.

★ 0
Leostruka
Leostruka/devin-bundle

adaptive-agenda-calendar-routine-engine

Use when planning or executing work across hours, days, weeks, or sprints. Turns the calendar into a strict time-blocked agenda (HH:MM-HH:MM blocks carrying a routine profile, expected inputs, and a handoff output artifact), runs the 5-stage cognitive flow (Radar and Hunt -> Triage plus Steve Jobs conception -> workbench manifest -> >=32-cycle loop -> Close plus Open-Minded Scrum), and unfolds macro calendar milestones into micro agenda blocks through extensions/gcal/wrapper.py.

★ 0
Leostruka
Leostruka/devin-bundle

demo

Use when demonstrating a skill in a fixture project.

★ 0
Leostruka
Leostruka/devin-bundle

duplicate-skill

Use when testing duplicate skill name detection.

★ 0
Leostruka
Leostruka/devin-bundle

duplicate-skill

Use when testing duplicate skill name detection.

★ 0