Back to all questions

What programming languages does MatCraft support?

General
languages
sdk
api

MatCraft is primarily a Python-based platform, but it provides multiple integration points so you can work in your preferred environment.

Python (Primary)

The core library and SDK are written in Python 3.10+. This is the most fully-featured way to interact with MatCraft:

python
from materia import Campaign, Material

material = Material.from_yaml("my_material.yaml")
campaign = Campaign(material=material, max_iterations=20)
campaign.run()
print(campaign.best_candidates(n=5))

REST API (Language-Agnostic)

The FastAPI backend exposes a comprehensive REST API. Any language that can make HTTP requests can interact with MatCraft:

bash
curl -X POST https://api.matcraft.ai/api/v1/campaigns \
  -H "Authorization: Bearer $MATCRAFT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"material_id": "mem-001", "max_iterations": 20}'

CLI

The materia CLI is useful for scripting, CI/CD pipelines, and quick interactions:

bash
materia campaign run --config campaign.yaml --output results/
materia data import --file measurements.csv --material mem-001

YAML Configuration

Most users define their materials and campaigns using YAML files, which require no programming at all. The YAML schema is fully documented and validated at load time.

Jupyter Notebooks

MatCraft integrates well with Jupyter for interactive exploration. The SDK includes built-in visualization helpers that render Pareto plots and convergence charts directly in notebook cells.

Future Language SDKs

We are evaluating TypeScript/JavaScript and Julia SDKs based on community demand. If you need a specific language binding, please open a feature request on GitHub.

Related Questions