Packages

Comprehensive benchmarking framework for AI research. Measures latency, throughput, cost, and reliability with percentile analysis and Nx numerical computations.

Current section

Files

Jump to
Raw

mix.exs

defmodule CrucibleBench.MixProject do
use Mix.Project
@version "0.3.2"
@source_url "https://github.com/North-Shore-AI/crucible_bench"
def project do
[
app: :crucible_bench,
version: @version,
elixir: "~> 1.14",
start_permanent: Mix.env() == :prod,
deps: deps(),
description: description(),
package: package(),
docs: docs(),
dialyzer: dialyzer(),
source_url: @source_url,
homepage_url: @source_url,
name: "CrucibleBench"
]
end
def application do
[
extra_applications: [:logger]
]
end
defp deps do
[
{:statistex, "~> 1.0"},
{:nx, "~> 0.7"},
{:crucible_ir, "~> 0.2.0"},
{:eval_ex, "~> 0.1.4"},
{:dialyxir, "~> 1.4", only: :dev, runtime: false},
{:credo, "~> 1.7", only: [:dev, :test], runtime: false},
{:ex_doc, "~> 0.31", only: :dev, runtime: false}
]
end
defp description do
"Comprehensive benchmarking framework for AI research. Measures latency, throughput, cost, and reliability with percentile analysis and Nx numerical computations."
end
defp package do
[
name: "crucible_bench",
description: description(),
files: ~w(lib mix.exs README.md CHANGELOG.md LICENSE),
licenses: ["MIT"],
links: %{
"GitHub" => @source_url,
"Online documentation" => "https://hexdocs.pm/crucible_bench"
},
maintainers: ["nshkrdotcom"]
]
end
defp dialyzer do
[
plt_add_deps: :app_tree,
plt_add_apps: [:mix],
list_unused_filters: true
]
end
defp docs do
[
main: "readme",
name: "CrucibleBench",
source_ref: "v#{@version}",
source_url: @source_url,
homepage_url: @source_url,
extras: ["README.md", "CHANGELOG.md"],
assets: %{"assets" => "assets"},
logo: "assets/crucible_bench.svg",
before_closing_head_tag: &mermaid_config/1
]
end
defp mermaid_config(:html) do
"""
<script defer src="https://cdn.jsdelivr.net/npm/mermaid@10.2.3/dist/mermaid.min.js"></script>
<script>
let initialized = false;
window.addEventListener("exdoc:loaded", () => {
if (!initialized) {
mermaid.initialize({
startOnLoad: false,
theme: document.body.className.includes("dark") ? "dark" : "default"
});
initialized = true;
}
let id = 0;
for (const codeEl of document.querySelectorAll("pre code.mermaid")) {
const preEl = codeEl.parentElement;
const graphDefinition = codeEl.textContent;
const graphEl = document.createElement("div");
const graphId = "mermaid-graph-" + id++;
mermaid.render(graphId, graphDefinition).then(({svg, bindFunctions}) => {
graphEl.innerHTML = svg;
bindFunctions?.(graphEl);
preEl.insertAdjacentElement("afterend", graphEl);
preEl.remove();
});
}
});
</script>
"""
end
defp mermaid_config(_), do: ""
end