2020-11-12 20:58:09 +00:00
# Squiggle
2022-04-12 05:41:36 +00:00
2022-04-08 18:41:26 +00:00
![Packages check ](https://github.com/QURIresearch/squiggle/actions/workflows/ci.yaml/badge.svg )
2022-04-11 00:45:36 +00:00
[![npm version ](https://badge.fury.io/js/@quri%2Fsquiggle-lang.svg )](https://www.npmjs.com/package/@quri/squiggle-lang)
[![npm version ](https://badge.fury.io/js/@quri%2Fsquiggle-components.svg )](https://www.npmjs.com/package/@quri/squiggle-components)
2020-02-05 21:09:27 +00:00
2022-04-12 05:41:36 +00:00
This is an experimental DSL/language for making probabilistic estimates. The full story can be found [here ](https://www.lesswrong.com/s/rDe8QE5NvXcZYzgZ3 ).
2020-03-09 13:29:18 +00:00
2022-03-25 16:45:40 +00:00
## Our deployments
- **website/docs prod**: https://squiggle-language.com
- **website/docs staging**: https://staging--squiggle-documentation.netlify.app/
- **old playground**: https://playground.squiggle-language.com
2022-03-28 20:26:25 +00:00
## Packages
2022-04-12 05:41:36 +00:00
This monorepo has several packages that can be used for various purposes. All
2022-02-28 23:59:48 +00:00
the packages can be found in `packages` .
2020-03-09 13:29:18 +00:00
2022-03-24 18:42:27 +00:00
- `@quri/squiggle-lang` in `packages/squiggle-lang` contains the core language, particularly
2022-04-12 05:41:36 +00:00
an interface to parse squiggle expressions and return descriptions of distributions
or results.
2022-03-24 18:42:27 +00:00
- `@quri/squiggle-components` in `packages/components` contains React components that
2022-04-12 05:41:36 +00:00
can be passed squiggle strings as props, and return a presentation of the result
of the calculation.
2022-03-24 18:42:27 +00:00
- `@quri/squiggle-website` in `packages/website` The main descriptive website for squiggle,
2022-04-12 05:41:36 +00:00
it is hosted at `squiggle-language.com` .
2022-02-28 23:59:48 +00:00
2022-03-25 00:11:31 +00:00
The playground depends on the components library which then depends on the language. This means that if you wish to work on the components library, you will need to build (no need to bundle) the language, and as of this writing playground doesn't really work.
2022-02-28 23:59:48 +00:00
2022-03-23 22:34:50 +00:00
# Develop
2022-02-28 23:59:48 +00:00
2022-04-12 05:41:36 +00:00
For any project in the repo, begin by running `yarn` in the top level (TODO: is this true?)
2022-03-23 14:39:32 +00:00
2022-04-12 05:41:36 +00:00
```sh
2022-03-23 22:34:50 +00:00
yarn
2022-03-23 14:39:32 +00:00
```
2022-03-23 22:34:50 +00:00
2022-04-12 05:41:36 +00:00
See `packages/*/README.md` to work with whatever project you're interested in.
2022-03-24 18:42:27 +00:00
2022-04-12 05:41:36 +00:00
## `codium` for `rescript`
2022-03-24 18:42:27 +00:00
2022-04-12 05:41:36 +00:00
If you have `nix` installed with `flakes` enabled, you can build a `codium` in this repo for `rescript` development, if you don't want to pollute your machine's global editor with another mode/extension.
2022-03-24 18:42:27 +00:00
2022-04-12 05:41:36 +00:00
```sh
2022-03-24 18:42:27 +00:00
nix develop
2022-04-12 05:41:36 +00:00
codium
2022-03-24 18:42:27 +00:00
```
2022-04-12 05:41:36 +00:00
The `nix develop` shell also provides `yarn` .
2022-03-24 20:05:45 +00:00
2022-03-24 18:42:27 +00:00
# Contributing
2022-04-12 05:41:36 +00:00
See `CONTRIBUTING.md` .