# pub.chive.graph.edgeProposal

> Published by [chive.pub](https://lexicon.garden/identity/did:plc:7natp5xae72bddaqlkef2t4e)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.graph.edgeProposal)
- [Documentation](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.graph.edgeProposal/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:7natp5xae72bddaqlkef2t4e/pub.chive.graph.edgeProposal/examples)

## Definitions

### `pub.chive.graph.edgeProposal`

**Type**: `record`

Proposal for creating, updating, or deprecating edges between knowledge graph nodes (stored in user PDS)

**Key**: `tid`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `evidence` | `array` | No | Supporting evidence for the proposal |
| `createdAt` | `string` (datetime) | Yes |  |
| `rationale` | `string` | Yes | Justification for the proposal |
| `proposalType` | `string` | Yes | Type of proposal action |
| `proposedEdge` | `ref` → `#proposedEdgeData` | No | Proposed edge data (for create/update) |
| `targetEdgeUri` | `string` (at-uri) | No | AT-URI of edge to update/deprecate |
| `schemaRevision` | `integer` | No | Schema revision this record was created with. Absent means revision 1. |

### `pub.chive.graph.edgeProposal#proposedEdgeData`

**Type**: `object`

Proposed edge data

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `weight` | `integer` | No | Edge weight (scaled by 1000 for 0.0-1.0 range) |
| `metadata` | `ref` → `pub.chive.graph.edge#edgeMetadata` | No |  |
| `sourceUri` | `string` (at-uri) | Yes | AT-URI of source node |
| `targetUri` | `string` (at-uri) | Yes | AT-URI of target node |
| `relationUri` | `string` (at-uri) | No | AT-URI of relation type node |
| `relationSlug` | `string` | Yes | Relation slug (broader, narrower, related, etc.) |

## Raw Schema

```json
{
  "id": "pub.chive.graph.edgeProposal",
  "defs": {
    "main": {
      "key": "tid",
      "type": "record",
      "record": {
        "type": "object",
        "required": [
          "proposalType",
          "rationale",
          "createdAt"
        ],
        "properties": {
          "evidence": {
            "type": "array",
            "items": {
              "ref": "pub.chive.graph.nodeProposal#evidence",
              "type": "ref"
            },
            "maxLength": 10,
            "description": "Supporting evidence for the proposal"
          },
          "createdAt": {
            "type": "string",
            "format": "datetime"
          },
          "rationale": {
            "type": "string",
            "maxLength": 2000,
            "description": "Justification for the proposal"
          },
          "proposalType": {
            "type": "string",
            "description": "Type of proposal action",
            "knownValues": [
              "create",
              "update",
              "deprecate"
            ]
          },
          "proposedEdge": {
            "ref": "#proposedEdgeData",
            "type": "ref",
            "description": "Proposed edge data (for create/update)"
          },
          "targetEdgeUri": {
            "type": "string",
            "format": "at-uri",
            "description": "AT-URI of edge to update/deprecate"
          },
          "schemaRevision": {
            "type": "integer",
            "minimum": 1,
            "description": "Schema revision this record was created with. Absent means revision 1."
          }
        }
      },
      "description": "Proposal for creating, updating, or deprecating edges between knowledge graph nodes (stored in user PDS)"
    },
    "proposedEdgeData": {
      "type": "object",
      "required": [
        "sourceUri",
        "targetUri",
        "relationSlug"
      ],
      "properties": {
        "weight": {
          "type": "integer",
          "maximum": 1000,
          "minimum": 0,
          "description": "Edge weight (scaled by 1000 for 0.0-1.0 range)"
        },
        "metadata": {
          "ref": "pub.chive.graph.edge#edgeMetadata",
          "type": "ref"
        },
        "sourceUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of source node"
        },
        "targetUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of target node"
        },
        "relationUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of relation type node"
        },
        "relationSlug": {
          "type": "string",
          "maxLength": 50,
          "description": "Relation slug (broader, narrower, related, etc.)"
        }
      },
      "description": "Proposed edge data"
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1,
  "revision": 1
}
```
