homotopy-io / homotopy-rs

A Rust/WASM implementation of homotopy.io
https://homotopy.io
BSD 3-Clause "New" or "Revised" License
84 stars 7 forks source link

Combine signatures #523

Open calintat opened 2 years ago

calintat commented 2 years ago

In the "Signature" panel, we should be able to insert the signature of a different workspace to our current signature. This is different from the import functionality which replaces the current project so it doesn't let you combine signatures.

This way, we could easily add structures such as monoids to the signature.

calintat commented 2 years ago

Maybe place the inserted signature in a folder.

regular-citizen commented 2 years ago

Do we have some UI in mind for how to do this without creating a "checkbox hell"? I really like the idea of "import workspace inside a new folder", but I still can't picture a non-clunky UI.

jamievicary commented 2 years ago

Drag the .hom file onto the directory icon?

On Mon, 5 Sept 2022, 09:17 Chiara Sarti, @.***> wrote:

Do we have some UI in mind for how to do this without creating a "checkbox hell"? I really like the idea of "import workspace inside a new folder", but I still can't picture a non-clunky UI.

— Reply to this email directly, view it on GitHub https://github.com/homotopy-io/homotopy-rs/issues/523#issuecomment-1236681982, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACQ4OHS2IYTN2S3ODRXXY4DV4WUC3ANCNFSM5ZIEOVWQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

regular-citizen commented 2 years ago

I like this idea. Though if we do it for folders we should also support it for old-school "replace workspace" imports.

mlharaujo commented 2 years ago

It would be nice if you could also choose how to attach the new cells. For example, you might want to add a monoid structure to an already existing cell (or even to a diagram).

jamievicary commented 2 years ago

The way to do this would be by first importing the external signature by disjoint union, then identifying generators with the same boundary.

doctorn commented 2 years ago

This is a restricted push-out of computads right?

jamievicary commented 2 years ago

Hi Nathan yes definitely that would be the expectation.

mlharaujo commented 2 years ago

What do you mean by "restricted"?

doctorn commented 2 years ago

Restricted in the sense that extending a signature like this will only provide you with a subclass of all push-outs of computads (my hunch is that not all of them will be constructible without assuming the existence of inverses and postulating some coherence data — something we can only do on the labelled branch).

jamievicary commented 2 years ago

This is something we do not yet give a full mathematical treatment of, however it is clear that identifying two variables with identical boundaries is a very simple sort of pushout, which can be computed more straightforwardly than other richer sorts of pushouts one might consider.