Skip to content

Commit d6d9e9c

Browse files
authored
Merge pull request #71 from constructive-io/devin/1774206019-update-skills-data-nodes
docs: add new Data* node types and field-level index API to blueprint format spec
2 parents 31f0dba + 50f390e commit d6d9e9c

1 file changed

Lines changed: 23 additions & 0 deletions

File tree

.agents/skills/constructive/references/blueprint-definition-format.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,11 @@ Common node types:
7979
| `DataOwnershipInEntity` | Adds `owner_id uuid NOT NULL` with FK | Entity-scoped ownership |
8080
| `DataSearch` | Adds full-text search columns | tsvector + GIN index |
8181
| `DataSoftDelete` | Adds `deleted_at` timestamp for soft deletes | Filtered in queries |
82+
| `DataEmbedding` | Adds vector embedding field + HNSW/IVFFlat index | Configurable dimensions, metric, stale tracking, job enqueue |
83+
| `DataTags` | Adds `citext[]` tags field + GIN index | For array containment/overlap queries |
84+
| `DataStatusField` | Adds status field + B-tree index + optional CHECK | Configurable allowed values |
85+
| `DataJsonb` | Adds JSONB field + optional GIN index | For containment queries |
86+
| `DataTrgm` | Adds GIN trigram indexes on existing fields | For fuzzy/LIKE queries, sets `@trgmSearch` smart tag |
8287

8388
**Processing order matters:** The first node in `nodes[]` creates the table (via `secure_table_provision`). Remaining nodes augment the existing table.
8489

@@ -95,6 +100,24 @@ Common node types:
95100

96101
Standard PostgreSQL types are supported: `text`, `integer`, `numeric`, `boolean`, `timestamptz`, `uuid`, `jsonb`, etc.
97102

103+
Optional field properties:
104+
105+
| Property | Type | Description |
106+
|----------|------|-------------|
107+
| `is_required` | boolean | Whether the field is NOT NULL (default: `false`) |
108+
| `default` | string | SQL default expression |
109+
| `min` | float | Minimum value constraint |
110+
| `max` | float | Maximum value constraint |
111+
| `regexp` | string | Regex validation pattern |
112+
| `index` | string | Access method for automatic index creation: `"btree"`, `"gin"`, `"gist"`, `"brin"`, `"hash"` |
113+
114+
Example with index:
115+
```json
116+
{ "name": "email", "type": "citext", "index": "btree" }
117+
{ "name": "tags", "type": "citext[]", "index": "gin" }
118+
{ "name": "location", "type": "geometry", "index": "gist" }
119+
```
120+
98121
### Grants
99122

100123
`grants[]` is an array of privilege tuples:

0 commit comments

Comments
 (0)