<!--
SPDX-FileCopyrightText: 2026 BaseLabs Holdings LLC

SPDX-License-Identifier: MIT
-->

# Contributing to Arcadic

This guide is for contributors changing the client, documentation, or test
suite. Standard checks run on GitHub-hosted runners against the toolchains
in `.tool-versions`.

## Submit a change

1. Create a topic branch from `main`.
2. Use `mix format` conventions and document public modules and functions
   with `@moduledoc` and `@doc`. Update [CHANGELOG.md](CHANGELOG.md) for
   changes to behavior, dependencies, or published contracts.
3. Push the branch and check the completed quick run. It checks formatting,
   compilation with warnings as errors, and strict Credo, then runs covering
   tests against live HTTP, Bolt, and gRPC endpoints.
4. Open a pull request against `main`. A maintainer qualifies the exact
   commit on `kci/<full-sha>`. The `qualified` job must pass before `main`
   advances.

## Build and test

`mix quality` checks formatting, compiles with warnings as errors, runs
strict Credo and unit tests, and runs Dialyzer. The qualification workflow
also checks dependencies, builds the ExDoc pages, and tests optional
dependency configurations. The TLS and shutdown tests run during
qualification.

The integration workflow starts a disposable ArcadeDB server at the pin
listed in [Compatibility](documentation/topics/client/compatibility.md).
Its test modules describe their variables and setup. The Bolt tests use
`ARCADIC_BOLT_*` and the transaction streaming cases use
`ARCADIC_TEST_BOLT_*`. The Bolt and gRPC suites share the certificate setup
documented in those tests.

Every packaged Livebook runs top to bottom against the checkout and a live
server during qualification. Keep the setup instructions and `Mix.install/2`
cell in each notebook. The runner entry point is
`elixir scripts/run_notebook.exs documentation/tutorials/<name>.livemd`.

The benchmark code, setup, and results are in
[bench/](https://github.com/baselabs/arcadic/tree/main/bench).
The transport builds on [ArcadeDB](https://arcadedb.com), [Req](https://hex.pm/packages/req),
[Finch](https://hex.pm/packages/finch), and [DBConnection](https://hex.pm/packages/db_connection).
[Arcadex](https://hex.pm/packages/arcadex) provides prior art for the HTTP
request and response shapes. The Ecto and Ash projects inspire the split
between the client and the data layer.

## License

Contributions use the [MIT license](LICENSE). All files covered by REUSE
carry SPDX metadata in a header or a `.license` sidecar.
