Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sketches via data migrations #844

Open
KevinDCarlson opened this issue Aug 30, 2023 · 0 comments
Open

Sketches via data migrations #844

KevinDCarlson opened this issue Aug 30, 2023 · 0 comments

Comments

@KevinDCarlson
Copy link
Contributor

KevinDCarlson commented Aug 30, 2023

We should be able to upgrade @present, or maybe write a new @present_schema to let you write something like

Par = @present_schema begin
X,Y::Ob
f,g::X -> Y
XY = @product X Y
E = @join x::X; y::Y; ff:(x->y)::f; gg:(x->y)::g
end

which will actually generate two schemas, Par and, say, Par_full, where Par only has X,Y,f,g while Par_full also has XY and E together with the components of their limit cones, as well constructing a DataMigration from Par to Par_full that's the identity on Par and literally sends XY to @product X Y and so on. Then when the user instantiates Par, Catlab does the instantiation and the migration to Par_full, and voila, you've got sketch-schemas!

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

No branches or pull requests

2 participants