Skip to main content

Language-agnostic correctness checker for scientific numerical code

Project description

AgentBible

Language-agnostic correctness checker for scientific numerical code.

SPEC.md is the mathematical source of truth for every implementation in this repository.

Install

Language Command
Python pip install agentbible
Rust cargo add agentbible
Julia julia -e 'using Pkg; Pkg.add("AgentBible")'
C++ CPMAddPackage("gh:rylanmalarchick/research-code-principles@cpp-v0.1.0")

Python Example

Without validation, a normalization bug can quietly propagate:

import numpy as np


def probabilities(logits: np.ndarray) -> np.ndarray:
    return np.exp(logits)

With AgentBible, the same bug fails at the boundary where it matters:

import numpy as np
from agentbible import validate_finite, validate_normalized_l1, validate_probabilities


@validate_finite
@validate_probabilities
@validate_normalized_l1()
def probabilities(logits: np.ndarray) -> np.ndarray:
    return np.exp(logits)

The invalid output raises immediately instead of silently contaminating later results.

CLI

Validate Python-produced data directly:

bible validate results.npy --check normalized_l1

Inspect a non-Python provenance record through the unified interface:

bible validate --lang rust results.json

Generate a Markdown provenance summary:

bible report results.json

Repository Layout

  • agentbible/: Python package, CLI, provenance, context retrieval
  • languages/rust/: Rust workspace
  • languages/cpp/: header-only C++ library
  • languages/julia/: Julia package
  • schema/provenance_v1.json: cross-language provenance schema

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

agentbible-1.0.0.tar.gz (167.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agentbible-1.0.0-py3-none-any.whl (146.1 kB view details)

Uploaded Python 3

File details

Details for the file agentbible-1.0.0.tar.gz.

File metadata

  • Download URL: agentbible-1.0.0.tar.gz
  • Upload date:
  • Size: 167.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for agentbible-1.0.0.tar.gz
Algorithm Hash digest
SHA256 ec062fbc0ef7f09641c2b0a3f568a9b9b93eac6cf089f5a6d17bedc108969a7c
MD5 7599579226f78b3df1fcb5d417994e51
BLAKE2b-256 54a5dfe5bd21224582d53f7755a4d95074ef9dcb5fec72f037f1607b833cb1db

See more details on using hashes here.

Provenance

The following attestation bundles were made for agentbible-1.0.0.tar.gz:

Publisher: publish-python.yml on rylanmalarchick/research-code-principles

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file agentbible-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: agentbible-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 146.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for agentbible-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7524791468a5401f02f5c592685bc8778c7456cd289cbaa9ee1778e640864cb3
MD5 92406e36ea8da5424a20aee027eaf16f
BLAKE2b-256 90572463c4090b17f721765c558d902f0c854ae712f33777e6f470a0ae89c2c5

See more details on using hashes here.

Provenance

The following attestation bundles were made for agentbible-1.0.0-py3-none-any.whl:

Publisher: publish-python.yml on rylanmalarchick/research-code-principles

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page