DeepFellow DOCS

Propose an ontology change

POST
/v1/graph/ontology/changes

Propose one change to the project's ontology; it applies only once accepted and applied.

Validated against the current ontology: a change it can't apply to (an unknown type, a rename onto an existing one, a backfill the change doesn't support) fails with a 422.

Authorization

headerAuthorizationBearer <token>

Header Parameters

OpenAI-Organization?|

Organization Id from OpenAi compatible endpoint. Required to organization access or project access (with OpenAI-Project header) when logged as User or Admin User.

OpenAI-Project?|

Project Id from OpenAi compatible endpoint. Required to project access for organization api key or User / Admin User access with OpenAI-Organization

Request Body

application/json
  1. body

Request to propose one ontology change.

payload*||||||||||
backfill?BackfillScope

Whether applying a change re-scans already-ingested chunks with the LLM (all) or only affects future ingests (none).

Default"none"
Value in"none""all"

Response Body

Successful Response

application/json
  1. response

API-facing view of one ontology change.

id*string
project_id*string
op*OntologyChangeOp

One kind of ontology change; each maps to one executor in graph_ontology_evolution.

Value in"add_entity""add_relation_pattern""add_attribute""set_description""rename_entity""rename_relation""rename_attribute""drop_entity""drop_relation""drop_relation_pattern""drop_attribute"
payload*||||||||||
risk*OntologyChangeRisk

What applying a change does to existing graph data; destructive changes need explicit confirmation to apply.

Value in"migrating""additive""destructive"
origin*OntologyChangeOrigin

What produced an ontology change. drift is reserved for drift-triggered proposals.

Value in"discovery""user""restore""drift"
backfill*BackfillScope

Whether applying a change re-scans already-ingested chunks with the LLM (all) or only affects future ingests (none).

Value in"none""all"
status*OntologyChangeStatus

Review/apply lifecycle of one ontology change.

Value in"proposed""accepted""rejected""applying""applied""failed"
inverse_of?string|null
data_not_restored?boolean
Defaultfalse
dry_run?|null
result?|null
error?string|null
applied_version?integer|null
created_at*string
Formatdate-time
updated_at*string
Formatdate-time
Example Request
curl -X POST 'https://deepfellow-server-host/v1/graph/ontology/changes' \  -H 'Content-Type: application/json' \  -d '{  "payload": {    "label": "string"  }}'
Example Response
{  "id": "string",  "project_id": "string",  "op": "add_entity",  "payload": {    "op": "add_entity",    "label": "string",    "description": "string",    "properties": [      {        "name": "string",        "type": "STRING",        "description": "string"      }    ]  },  "risk": "migrating",  "origin": "discovery",  "backfill": "none",  "status": "proposed",  "inverse_of": "string",  "data_not_restored": false,  "dry_run": {    "chunks_in_scope": 0,    "affected_nodes": 0,    "affected_edges": 0  },  "result": {    "llm_calls": 0,    "failed_chunks": [      "string"    ],    "nodes_updated": 0,    "edges_updated": 0  },  "error": "string",  "applied_version": 0,  "created_at": "2019-08-24T14:15:22Z",  "updated_at": "2019-08-24T14:15:22Z"}

We use cookies on our website. We use them to ensure proper functioning of the site and, if you agree, for purposes such as analytics, marketing, and targeting ads.