{"id":31942139,"url":"https://github.com/effectfully/categories","last_synced_at":"2026-02-18T12:31:45.373Z","repository":{"id":34472223,"uuid":"38409491","full_name":"effectfully/Categories","owner":"effectfully","description":"Some basic category theory","archived":false,"fork":false,"pushed_at":"2016-03-24T02:26:45.000Z","size":243,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-10-23T08:44:00.628Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Agda","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/effectfully.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-07-02T03:39:06.000Z","updated_at":"2024-11-25T09:15:47.000Z","dependencies_parsed_at":"2022-08-03T21:00:18.631Z","dependency_job_id":null,"html_url":"https://github.com/effectfully/Categories","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/effectfully/Categories","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/effectfully%2FCategories","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/effectfully%2FCategories/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/effectfully%2FCategories/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/effectfully%2FCategories/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/effectfully","download_url":"https://codeload.github.com/effectfully/Categories/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/effectfully%2FCategories/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29578956,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T08:38:15.585Z","status":"ssl_error","status_checked_at":"2026-02-18T08:38:14.917Z","response_time":162,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-10-14T09:26:16.738Z","updated_at":"2026-02-18T12:31:45.369Z","avatar_url":"https://github.com/effectfully.png","language":"Agda","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Categories\n\n## In short\n\nHere I study some basic category theory.\n\n## [Setoids](https://github.com/effectfully/Categories/blob/master/Setoid/Setoid.agda)\n\nThere are three kinds of setoids in this development:\n\n - usual setoids                   (underlying equality is `_≈_ :            A   -\u003e A   -\u003e Set β`)\n - indexed setoids                 (underlying equality is `_≈_ : ∀ {i}   -\u003e A i -\u003e A i -\u003e Set β`)\n - heterogeneously indexed setoids (underlying equality is `_≈_ : ∀ {i j} -\u003e A i -\u003e A j -\u003e Set β`)\n\nAll of them are used in the code.\n\nThere is a [module](https://github.com/effectfully/Categories/blob/master/Setoid/Setoid.agda#L131) that performs transformation of an indexed setoid into its henerogeneously indexed counterpart. This is used in the [definition](https://github.com/effectfully/Categories/blob/master/Functor/Functor.agda#L130) of a `Functor` setoid. One especially nice thing about this transformation is that we [can](https://github.com/effectfully/Categories/blob/master/Setoid/Instances.agda#L57) define Agda's heterogeneous equality in terms of propositional equality. It's just\n\n    module Just-HEquality {α} = Hetero (≡-ISetoid {α = α} {A = id′}) renaming (_≋_ to _≅_)\n\nI.e. turn indices into sets and your indexed propositional equality is plain heterogeneous equality now. A [test](https://github.com/effectfully/Categories/blob/master/Setoid/Instances.agda#L83).\n\nThere are several functions that allow to define setoids from other setoids ([one family](https://github.com/effectfully/Categories/blob/master/Setoid/Setoid.agda#L69) and [another](https://github.com/effectfully/Categories/blob/master/Setoid/Setoid.agda#L206)). Most setoids in the development are defined with the help from these functions. E.g. a natural transformations setoid\n\n    setoidⁿ : ∀ {α₁ α₂ β₁ β₂ γ₁ γ₂} {C₁ : Category α₁ β₁ γ₁} {C₂ : Category α₂ β₂ γ₂}\n            -\u003e ISetoid₂ (NaturalTransformation {C₁ = C₁} {C₂ = C₂}) (α₁ ⊔ γ₂)\n    setoidⁿ {C₂ = C₂} = comap∀ⁱˢ (λ N A -\u003e let open NaturalTransformation N in η {A}) setoid\n      where open Category C₂\n\nis defined in terms of a target category setoid. One another example is a setoid for the [Comma](https://github.com/effectfully/Categories/blob/master/Categories/Comma.agda#L16) category:\n\n    setoid = comapⁱˢ₁ (λ{ (f₁ , f₂ , _) -\u003e f₁ , f₂ }) (setoid₁ ×ⁱˢ setoid₂)\n\nThis says \"use morphisms equalities from the corresponding categories and ignore commutativity proofs\".\n\n## Some results\n\nCategories stuff is pretty standard and much like in [this](https://github.com/copumpkin/categories) development, on which I consult all the time.\n\n - [Four variants of the `Agda` category with a few simple properties like \"**Set** has pullbacks\"](https://github.com/effectfully/Categories/blob/master/Categories/Agda.agda).\n - [A variant of the Yoneda lemma, stated using Agda's quantification instead of the Yoneda embedding](https://github.com/effectfully/Categories/blob/master/Yoneda/Simple.agda).\n - [The pullback pasting lemma](https://github.com/effectfully/Categories/blob/master/Object/Limit/Properties/Pullback.agda).\n - [Products are limits](https://github.com/effectfully/Categories/blob/master/Object/Limit/Properties/Product.agda).\n - Two failed attempts to construct coequalizers in **FinSet** ([1](https://github.com/effectfully/Categories/tree/master/Utilities/Coequalize/Eqclasses.agda), [2](https://github.com/effectfully/Categories/tree/master/Utilities/Coequalize/DAG.agda)) and one successful ([1](https://github.com/effectfully/Categories/tree/master/Utilities/Coequalize/Coequalize.agda), [**FinSet**](https://github.com/effectfully/Categories/tree/master/Categories/Fins.agda)).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feffectfully%2Fcategories","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feffectfully%2Fcategories","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feffectfully%2Fcategories/lists"}