Skip to content

docs(spec): add Blueprint Specification v1#929

Open
pyramation wants to merge 1 commit intomainfrom
devin/1774691827-blueprint-specification
Open

docs(spec): add Blueprint Specification v1#929
pyramation wants to merge 1 commit intomainfrom
devin/1774691827-blueprint-specification

Conversation

@pyramation
Copy link
Copy Markdown
Contributor

@pyramation pyramation commented Mar 28, 2026

Summary

Adds a formal specification document for the blueprint system at docs/spec/BLUEPRINT.md. This is a documentation-only change — no code, no runtime impact.

The spec defines a three-layer architecture for blueprints:

  • Layer 1 (Core) — rigid structural types (BlueprintTable, BlueprintField, BlueprintPolicy, BlueprintIndex) derived from DB introspection
  • Layer 2 (Registry) — semi-extensible node types (Authz*, Data*, Relation*, View*) driven by the node-type-registry package and its JSON Schema definitions
  • Layer 3 (Extensions) — fully open extension points with namespaced BlueprintExtension entries for frontend scaffolding, deployment recipes, agent skills, etc.

Also documents the type generation pipeline (generate-types.ts), validation rules, versioning policy, and a complete CRM example blueprint.

Review & Testing Checklist for Human

  • Layer 3 (Extensions) is aspirational, not implemented. The BlueprintExtension type with namespace/kind/version/config does not exist in the codebase yet. Verify you're comfortable with the spec documenting this as a design alongside the already-implemented Layers 1 and 2. Consider whether it should be marked more clearly as "proposed" or "future."
  • Verify BlueprintPolicy discriminant field name. The spec and examples use $type for the policy type field. The introspection-derived version uses policy_type (the actual DB column name). Confirm which is canonical and whether the spec/examples are consistent with what construct_blueprint() actually accepts.
  • Spot-check the complete CRM example (lines ~400-520) against the actual generated types — particularly RelationBelongsTo params (field_name, nullable) and DataSearch.full_text_search.source_fields shape.

Notes

  • Companion to the existing docs/spec/SLICING.md (cross-referenced in the doc).
  • No test plan needed — this is pure documentation.

Link to Devin session: https://app.devin.ai/sessions/ce1b2dafd42341bea5d7793b0c05ba6c
Requested by: @pyramation


Open with Devin

@devin-ai-integration
Copy link
Copy Markdown
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 1 additional finding.

Open in Devin Review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant