Skip to content

Latest commit

 

History

History

libs

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

github_banner

discord github_star

Libraries

Contains the source code for software development libraries which HASH has published for general use. Full write-ups of most can be found on the HASH website for developers, and a summary table is included below for convenience.

General Libraries

Directory Language(s) Publication URL Docs URL Description
antsi Rust Crates.io Docs.rs Supports coloring Select Graphic Rendition (as defined in ISO 6429) with no external dependencies
deer Rust Crates.io Docs.rs Experimental backend-agnostic deserialization framework, featuring meaningful error messages and context and fail-slow behavior by default
error-stack Rust Crates.io Docs.rs Context-aware error-handling library that supports arbitrary attached user data
sarif Rust Crates.io Docs.rs Representation of the SARIF specification in Rust
@hashintel/type-editor TypeScript npm To be written UI for editing entity types defined according to the Block Protocol's Type System
@hashintel/query-editor TypeScript npm To be written UI for editing queries (a specific entity type used heavily inside of HASH)

Internal Libraries

Although published to package managers, the following libraries were developed for internal use and may be subject to breaking changes. External consumers should be especially careful when using or upgrading these.

Directory Language(s) Publication URL Docs URL Description
@hashintel/design-system TypeScript npm To be written A collection of styleguide-aligned reusable UI primitives for HASH and our hash.ai website
@hashintel/block-design-system TypeScript npm To be written A relatively unopinionated set of reusable UI primitives for use in building Block Protocol blocks

Those packages inside of @local are libraries used inside this repository which are not published to package managers. All of these libraries may be subject to breaking changes. External consumers should be especially careful when using or upgrading these.

The following list is a non-exhaustive list of packages in @local:

Package Language(s) Docs URL Description
@local/codec-rs Rust Not hosted Implementation of different serde or byte codes used in HASH
@local/hash-authorization-rs Rust Not hosted Provides the authorization interface and logic used in the Graph
@local/hash-graph-client TypeScript To be written A generator to create a TypeScript/JavaScript client for the Graph API
@local/hash-graph-types-rs Rust Not hosted Types used inside of the Graph API
@local/temporal-client-rs Rust Not hosted Client implementation to connect to our Temporal.io service
@local/temporal-versioning-rs Rust Not hosted Implementation of temporal versioning

Contributing

See CONTRIBUTING.md.

Publishing

Rust

Publishable Rust crates are automatically published on merge to main if their version has been modified.

A crate can be marked as publishable by adding it to the list of PUBLISH_PATTERNS in .github/scripts/rust/setup.py

The publishing process is tested automatically, and therefore can be verified through, a dry-run within CI on pull requests.

TypeScript

Publishing of TypeScript libraries is handled via Changesets.

To record a change for publication:

  1. From the root of the repository, run yarn changeset
  2. Select the package(s) affected by this change (space to select, enter to move to the next step)
  • Do not worry about selecting packages which depend on changed packages – Changesets will handle bumping them
  1. Select the semver increment
  2. Describe the change
  3. Commit the created changeset file

When a PR with a changeset file is merged, the change is added to a PR entitled 'Version Packages', which has a diff showing the version increments which will be applied to affected packages, including dependents.

Once the 'Version Packages' PR is merged, the changes are published to npm.