The
libs/kalika/area: ~96 Nx projects making up Oshun's scientific-research platform — a symbolic-algebra core, two Rust compute kernels, a Python/Jupyter SDK surface, and a broad library of mathematics, theoretical-physics, and materials-science code. This page is the entity-catalog view; the narrative architecture lives in the Kalika domain space.
What this area is#
Kalika is the layer underneath Oshun's consumer domains: the symbolic
representation, the provenance model, the compute kernels, the reactive research
notebooks, the autonomous research agents, and a very wide library of
mathematics and physics implementations. The organising idea is the
reproducibility-and-auditability gap in computational science — a bare
number is not a result; the derivation chain, assumptions, units, tolerance, and
verification status are. @kalika/core's ProvenResult<T> and Expr AST carry
that metadata through the stack.
The area is unusually large and unevenly integrated, and the most important
honest fact about it (documented at length on the domain architecture page) is
that it holds two parallel compute substrates that are not yet wired to each
other at runtime: the Rust kernels (@kalika/cas-engine,
@kalika/numerical-engine) and a hand-written TypeScript symbolic/numeric stack
built on @kalika/core. The Rust kernels are genuinely deep (tens of thousands
of lines), but with one exception (@kalika/electronic-structure depends on
@kalika/numerical-engine) no TypeScript package imports them — the
'@kalika/cas-engine' strings in packages like @kalika/arithmetic and
@kalika/calculus are backend-name labels/metadata, not imports.
A handful of packages are deliberately thin: facade/aggregator packages that
only re-export sibling libraries (e.g. @kalika/mathematical-physics,
@kalika/operators, @kalika/cohomology) or declare a capability/metadata
constant (@kalika/arithmetic, @kalika/calculus), and one near-empty
scaffold (@kalika/wannier). The bulk, however, are substantial: dozens of
TypeScript libraries in the multi-thousand-line range with real, domain-specific
module decompositions (named explicitly per entity below).
How it fits the wider system#
These libraries are consumed by the Kalika applications (apps/kalika/* — the
compute service, notebook backend, research-agent runners) and by the
TypeScript/Python SDKs (@kalika/sdk, kalika-sdk-python,
kalika-jupyter-kernel). Internally they form a dependency cone rooted at
@kalika/core (the Expr AST, provenance, rewrite engine): the math/physics
libraries build on core and on each other, the facade packages re-export them
into convenient umbrellas, and the platform libraries (@kalika/database,
@kalika/knowledge-graph, @kalika/renderer, @kalika/notebooks,
@kalika/research-agents, @kalika/training-data) compose the computational
libraries into storage, visualization, notebook, and agentic-research surfaces.
Walk the "used by" edges on any node below to see exactly who depends on it.
Two further families sit alongside the mathematics/physics cone:
- First-principles materials science —
@kalika/crystallographyplus the lattice-dynamics chain (phonons,phonons-dfpt,phonons-anharmonic,phonons-special,thermal-transport,electron-phonon,eliashberg,polarons) and the many-body/correlated-electron chain (many-body,gw,bse,response,tddft,dmft,qmc,cc-solids,embedding,molecular-dynamics, benchmarked bymany-body-benchmarks). Real named algorithms in TypeScript (tetrahedron DOS, CT-HYB, Allen-Dynes, fixed-node DMC), mostly compact/formula-level rather than plane-wave-scale solvers; DFT-engine execution and GPU kernels are explicit fail-loud seams, andmolecular-dynamicscarries Rust crates not yet bridged to TS. - Lab automation / self-driving lab —
@kalika/experiment-orchestration(the shared type backbone) withdoe,protocols,instrument-control,lab-safety,sample-ops,closed-loop-experiments, andresearch-ops: design, compile, safety-gate, track, and close the loop on experiment campaigns. Honestly a control-plane/policy layer — typed models, validators, and planners; no live instrument transport is implemented (drivers are interface seams).
Entity catalog (194)#
The 194 tracked Nx projects in kalika, each a code-linked entity node — package, type, source path, declared targets, and its internal dependency graph (depends-on / used-by, resolved from the package manifests, §6/§8), read from the project graph. Grouped by architectural layer; walk the dependency links to travel the system. 124 of these carry an authored deep-dive (what / why / how it fits); the rest are generated scaffolds awaiting one.
domain (193)#
ABINIT interface: input generation (multi-dataset), pseudopotential handling, and output parsing (main output, GSR/DEN/DDB via structured text).
Abstract & linear algebra (libs/kalika/algebra/src, ~22 files, ~10.7k lines):
linear-algebra, matrix-functions, rings, modules, field-extensions,
galois, finite-groups + finite-group-atlas, decompositions, spectral.
Algebraic combinatorics (libs/kalika/algebraic-combinatorics/src): matroids
matroid-kazhdan-lusztig,posets, andehrhart(Ehrhart polynomials).
A large algebraic-geometry library (libs/kalika/algebraic-geometry/src, ~37
files): schemes, sheaves, divisors, cohomology, derived
categories/functors, bridgeland-stability, fourier-mukai, moduli-spaces,
git-quotients, homotopy-continuation, numerical-irreducible-decomposition,
with msolve/dmodule interfaces.
Real/complex/functional analysis (libs/kalika/analysis/src, ~25 files):
complex-analysis, conformal-mapping, riemann-surfaces, hilbert-space,
operator-theory, distribution-theory,
fourier/laplace/integral-transforms, asymptotics,
dispersion-relations, and series.
Approximation theory (libs/kalika/approximation/src): chebyshev-technology,
polynomial-approximation, and rational-approximation.
A thin facade/metadata package (libs/kalika/arithmetic/src/index.ts, ~10
lines): exports only package/backend-name constants and a frozen
ARITHMETIC_CAS_ENGINE_CAPABILITIES list naming @kalika/cas-engine as the
intended backend. No arithmetic is implemented here — it is a capability label,
not an import.
KALIKA_ARITHMETIC_PACKAGE1KALIKA_ARITHMETIC_BACKEND2ARITHMETIC_CAS_ENGINE_CAPABILITIES4ArithmeticCasEngineCapability12Astrophysics (libs/kalika/astrophysics/src): stellar-structure, tov
(neutron-star structure), compact-objects, accretion-disk, and a mesa
interface.
Atomic & molecular physics (libs/kalika/atomic-physics/src): hartree-fock,
molecular-physics, and spectroscopy.
Higher-level autodiff (libs/kalika/autodiff/src, ~14 files): forward/reverse
mode plus CAS-adjoint, ODE-adjoint, PDE-adjoint, and numerical-compatibility
layers tying AD into the symbolic and numeric engines.
Core automatic differentiation (libs/kalika/autodiff-core/src): forward-mode
and a namespaced reverse-mode — the low-level AD primitives.
First-principles battery-materials workflows: intercalation voltages, convex-hull voltage profiles, capacity and energy density, ion-migration barriers, ionic conductivity, percolation, AIMD diffusion, electrochemical stability windows, and cathode/anode/solid-electrolyte workflows.
Big-Bang nucleosynthesis (libs/kalika/bbn/src): reaction-network,
abundance-prediction, and bsm-constraints.
BoltzTraP2 interface: input preparation from band structures and transport-coefficient output parsing (Seebeck, conductivity, power factor).
The conformal/S-matrix bootstrap (libs/kalika/bootstrap/src, ~14 files):
conformal-blocks, crossing-equations, analytic-bootstrap,
navigator-function, s-matrix-bootstrap, and sdp-bootstrap (numerical
bootstrap via SDP).
Bethe-Salpeter excitonic optics (libs/kalika/bse/src, ~13 files):
electron-hole kernel assembly (bareExchangeElement, screenedDirectElement,
buildBseHamiltonian), Tamm-Dancoff (solveTdaBse) and full A/B-block
solutions (solveFullBse, beyondTdaCorrection), a Haydock-Lanczos spectrum
path (lanczosCoefficients), and optical outputs — absorption, oscillator
strengths, exciton binding energies and radiative lifetimes — plus 2D
keldyshPotential screening, singlet-triplet and spin-orbit excitons, and
kernel interpolation / k-grid extrapolation.
A thin facade/metadata package (libs/kalika/calculus/src/index.ts, ~10
lines): like @kalika/arithmetic, only package/backend-name constants and a
frozen CALCULUS_CAS_ENGINE_CAPABILITIES list. The actual calculus lives in the
Rust cas-engine (not wired) and the live TS engine; this package is metadata.
KALIKA_CALCULUS_PACKAGE1KALIKA_CALCULUS_BACKEND2CALCULUS_CAS_ENGINE_CAPABILITIES4CalculusCasEngineCapability12A real Rust computer-algebra kernel (libs/kalika/cas-engine, ~43k lines of
Rust across three crates: kalika-cas-core plus kalika-cas-native (napi-rs)
and kalika-cas-wasm (wasm-bindgen) bridges). kalika-cas-core mirrors the
@kalika/core AST with arbitrary-precision integers, canonical ordering,
hash-consed storage and the URN1 binary envelope. Substantial and benchmarked,
but per the domain architecture page not imported by any TypeScript package at
runtime today — it is a built-but-not-wired substrate.
Computational catalysis workflows: adsorption energies, free-energy reaction diagrams, Sabatier volcano plots, scaling relations, microkinetics, electrocatalysis (CHE, OER/ORR/HER/CO2RR/N2RR, pH/field/solvation corrections), photocatalysis band alignment, and single-atom/enzyme-inspired catalyst design.
Category theory (libs/kalika/category-theory/src, ~19 files): category,
abelian-categories, monoidal-categories, universal-constructions,
topos-theory, string-diagrams, zx-calculus, tqft, and
compositional-systems.
Coupled-cluster for solids (libs/kalika/cc-solids/src, ~730 lines):
canonical/spin-adapted/Laplace-transform MP2 (canonicalMP2, laplaceMP2 with
its own Laplace quadrature), CCSD correlation energy with DIIS acceleration
(ccsdCorrelationEnergy, diisExtrapolate), perturbative triples and EOM-CCSD
excitations (perturbativeTriples, eomCcsdExcitations), and
local-correlation/finite-size machinery — DLPNO pair-natural-orbital domains,
two-point CBS extrapolation, structure-factor finite-size corrections. Compact,
formula-level implementations; the CCD/FCI "two-electron" functions are analytic
2×2 minimal models used as exactness anchors.
Citation/bibliography management (libs/kalika/citations/src, ~19 files):
arxiv/doi/inspire resolvers, a citation manager, normalization, formats, a
local database, and graph visualization.
Classical mechanics (libs/kalika/classical-mechanics/src, ~35 files):
lagrangian/hamiltonian, poisson, canonical-transformations, noether,
hamilton-jacobi, kam-theory, birkhoff-normal-form, celestial &
restricted-three-body mechanics, perturbation theory, and a symbolic layer.
Closed-loop autonomous-experiment coordination
(libs/kalika/closed-loop-experiments/src/index.ts):
orchestrateExperimentComputeLoop turns DoE candidate runs plus new
measurements into ranked recommendations, protocol requests, and a QC-gated
execution queue; updateSurrogateModels applies weight-averaged moment-based
posterior mean/variance updates — deliberately lightweight Bayesian bookkeeping,
not the GP regression that lives in @kalika/surrogate — and
learnDiscrepancyModel fits per-modality simulation-vs-experiment residual
statistics. Four domain planners (planBatteryClosedLoopCampaign,
planCatalystClosedLoopCampaign, thin-film, structural-alloy) template concrete
campaigns.
KALIKA_CLOSED_LOOP_EXPERIMENTS_PACKAGE4ClosedLoopStage6ClosedLoopExperimentState15ClosedLoopMeasurement24SurrogateModelKind33SurrogateModelState35ClosedLoopPlan45DiscrepancyModel62DomainLoopKind71DomainClosedLoopPlan73orchestrateExperimentComputeLoop93updateSurrogateModels139learnDiscrepancyModel187planBatteryClosedLoopCampaign226 +3 moreCore types and orchestration for computational materials code interoperability: calculation inputs and outputs, job status, structure conversion, unit systems, and ASE/pymatgen ecosystem compatibility shared across DFT, MD, and post-processing codes.
An aggregator facade (libs/kalika/cohomology/src/index.ts, ~11 lines):
re-exports @kalika/topology and @kalika/algebraic-geometry under namespaces
and declares a COHOMOLOGY_SOURCE_MODULES constant. No cohomology code of its
own — it is an umbrella over the two real libraries.
Combinatorics (libs/kalika/combinatorics/src): enumerative, graphs,
species, and tableaux modules.
Condensed-matter physics (libs/kalika/condensed-matter/src): tight-binding,
hubbard-model, bcs-superconductivity, quantum-hall, and
topological-band.
The symbolic foundation (libs/kalika/core/src, ~62 files): the Expr AST
(expr.ts), hash-consing arena, e-graph/rewrite engine (egraph.ts,
rewrite-rule.ts, rewrite-strategy.ts, pattern.ts, matching.ts),
provenance (derivation.ts, proven-result.ts, verification-badge.ts),
numerical compiler, and many interchange formats (openmath, mathml,
smtlib, tptp, scscp, serialization). The most heavily depended-on package
in the area; everything symbolic is rooted here.
Corrosion & degradation workflows: Pourbaix-diagram corrosion assessment, passivation-film stability (Pilling-Bedworth), galvanic corrosion, pitting (PREN), intergranular corrosion, Wagner parabolic oxidation, stress-corrosion cracking (Oriani/K_ISCC), and oxide-scale spallation.
Cosmology (libs/kalika/cosmology/src, ~20 files): friedmann, inflation,
cmb-power-spectrum, dark-energy, structure-formation, cosmological
likelihoods, and Boltzmann-code interfaces (class-interface, camb-interface,
cobaya-interface).
Crystal plasticity & continuum mechanics (Phase 129.3): finite-strain F=Fe.Fp constitutive framework, FCC/BCC/HCP slip systems, rate-dependent kinetics, hardening/twinning/TRIP, CPFEM solver, RVE homogenization, texture, fatigue hooks, and calibration.
WebGPU-accelerated 3D crystal structure visualization: representations, appearance, unit cell/supercell, symmetry, defects, camera, animation, and export (Phase 128.2).
Production-grade crystallography and solid-state physics: Bravais lattices, 230 space groups, symmetry detection, structure I/O, reciprocal space, diffraction, crystal chemistry, surfaces, interfaces, and symmetry-adapted tensor properties.
A very large crystallography & solid-state library
(libs/kalika/crystallography/src, ~209 files, ~25.6k lines): Bravais lattices
with Niggli reduction (lattice/niggli-core.ts), the 230 space groups with Hall
symbols, detection and xyz operator algebra (space-group/), Hinuma-convention
Brillouin-zone k-paths (reciprocal/hinuma.ts), diffraction with form factors,
systematic absences and Le Bail fitting (diffraction/lebail.ts), crystal
chemistry (bond valence, coordination polyhedra, porosity, prototypes),
surfaces/interfaces (Wulff construction, CSL grain boundaries, moiré), magnetic
Shubnikov groups, space-group irreps/corepresentations and distortion modes, and
symmetry-adapted tensor properties (Neumann, elastic, Landau). Structure I/O
covers CIF/POSCAR and more, with COD and Materials-Project database clients.
Damage, fracture, fatigue, creep & tribology (Phase 129.5): phase-field fracture & cohesive zones, LEFM/EPFM (SIF, J-integral, CTOD, R-curve), fatigue (S-N, strain-life, critical-plane, Paris), creep (Norton-Bailey), and tribology.
The persistence + ingestion layer (libs/kalika/database/src, ~40 files):
computation cache, embedding service, schema, migrations, vector search, and a
suite of scientific-database importers (lmfdb, oeis, hepdata, knotinfo,
kreuzer-skarke, sxs-catalog), plus privacy-preserving computation logging.
Production-grade defect physics and surface science: point defects (vacancies, interstitials, substitutionals, antisites, complexes), charged-defect thermodynamics and finite-size corrections (Makov-Payne, Lany-Zunger, FNV), dislocations (Volterra/Peierls-Nabarro), grain boundaries and CSL theory, surface construction, adsorption and catalysis (d-band, BEP, volcano, microkinetics, electrocatalysis), interface band alignment, transition-state search (NEB/dimer/KMC), and alloy thermodynamics (SQS, cluster expansion, Monte Carlo). Parity target: PyCDT, PyDEF, DASP, CatKit, and the defect/surface modules of pymatgen.
An aggregator facade (libs/kalika/differential-geometry/src/index.ts, ~9
lines): re-exports @kalika/general-relativity under a namespace plus a source-
modules constant. The differential-geometry machinery actually lives in
@kalika/general-relativity.
KALIKA_DIFFERENTIAL_GEOMETRY_PACKAGE3DIFFERENTIAL_GEOMETRY_SOURCE_MODULES5DifferentialGeometrySourceModule9Autonomous materials-discovery agents: structure generation, stability assessment, property prediction, literature search, synthesis feasibility, multi-agent orchestration, and goal-directed discovery (Phase 128.6).
Dislocation & defect-mediated mechanics (Phase 129.4): discrete dislocation dynamics kernels, continuum GND/SSD density models, irradiation defect-cluster evolution, hydrogen/solute-drag mobility, atomistic calibration, and DDD-to-CPFEM homogenization.
Dynamical mean-field theory (libs/kalika/dmft/src, ~20 files): a Bethe-lattice
runDmft self-consistency loop with Matsubara Green's functions and
chemical-potential adjustment, a segment-representation CT-HYB
hybridization-expansion Monte-Carlo impurity solver (runCtHyb, deterministic
Mulberry32 PRNG), exact-diagonalization and Wilson-chain NRG solvers
(nrgIterativeDiagonalization on a logarithmic mesh), analytic continuation by
Padé / MaxEnt / Nevanlinna / stochastic methods, cRPA/cLDA interaction-
parameter estimation with Slater-Kanamori conversion, and extended-DMFT /
DFT+DMFT workflow glue with quasiparticle-weight and Mott-transition
observables.
Design of experiments for lab campaigns (libs/kalika/doe/src/index.ts, ~1.9k
lines, single module): classical designs — full/fractional factorial,
plackettBurmanDesign, Taguchi arrays, latinHypercubeDesign, greedy
dOptimalDesign over a candidate set, central-composite responseSurfaceDesign
— filtered by lab-aware constraints (applyDoeConstraints: forbidden
combinations, simplex/mixture, process windows, equipment throughput, precursor
inventory), then Bayesian-optimization candidate ranking with
expected-improvement / UCB / constrained-EI acquisitions, active-learning
planning, adaptive replicate allocation, portfolio scheduling, and campaign
outputs (plate maps, batch sheets, instrument queues, requisitions).
KALIKA_DOE_PACKAGE2DoeLevel4FactorLevels5DoeRunDescriptor7FactorDefinition15NumericFactorDefinition23FractionalFactorialOptions31LatinHypercubeOptions36DOptimalOptions41ResponseSurfaceOptions46ConstraintViolationCode51ConstraintViolation58ForbiddenCombination63SimplexConstraint68 +47 moreElectron energy loss spectroscopy for Kalika (Phase 124): energy loss function and plasmon energy/dispersion, q-dependent dielectric response, Kramers-Kronig analysis with f-sum rule, Cerenkov subtraction, core-loss ELNES double-differential cross-sections, collection/convergence-angle integration, hydrogenic generalized oscillator strengths, white-line ratio analysis, k-factor quantification, momentum-resolved S(q,omega) maps, and vibrational EELS.
Elastic & mechanical properties from first principles: elastic constants (stress-strain, energy-strain), Voigt-Reuss-Hill moduli, hardness models, Born stability, Christoffel wave velocities and Debye temperature for Kalika.
Classical electrodynamics (libs/kalika/electrodynamics/src, ~16 files):
maxwell, fdtd, green-functions, multipole-expansion, radiation,
static-solvers, and waves.
Electron-phonon coupling: matrix elements, Wannier interpolation, Eliashberg spectral function, band-gap renormalization, and phonon-limited transport for Kalika.
Electron-phonon coupling (libs/kalika/electron-phonon/src, ~860 lines):
deformation-potential and Fröhlich matrix elements with Bloch↔Wannier transforms
and a long-range polar correction for interpolation (froehlichMatrixElement,
blochToWannier), the Eliashberg spectral function α²F with λ, ω_log and
mode-resolved decomposition (alpha2F, couplingConstant), Fan-Migdal +
Debye-Waller self-energies for zero-point/temperature band-gap renormalization,
SERTA and iterative-BTE phonon-limited mobility with Seebeck-Mott and
Hall-factor helpers, and Kohn-anomaly/nesting analysis. Compact but
named-formula real; the full gap solvers live in @kalika/eliashberg.
ELECTRON_PHONON_LIBRARY_NAME9addPolarCorrection11blochToWannier11deformationPotential11froehlichMatrixElement11matrixElementSquared11wannierToBloch11Complex11alpha2F21couplingConstant21modeResolvedLambda21omegaLog21hononLinewidthFromEph21ransportAlpha2F21 +21 moreKohn-Sham DFT, plane-wave basis, pseudopotential, band-structure, and Wannier foundations for Kalika.
A pseudopotential / crystallography-and-DFT-types library
(libs/kalika/electronic-structure/src, ~73 TS files, ~17.9k lines). Its
implemented code (everything index.ts re-exports) lives in types (the bulk:
crystallographic and DFT data structures — atoms, lattices, k-point grids/paths,
space groups, symmetry finding, wavefunctions, charge density, band-structure
and DFT-calculation types), pseudopotential (relativistic pseudopotential
physics — Dirac radial solver, spin-orbit Hamiltonians, delta-factor /
equation-of-state validation, library registry), io (POSCAR/CONTCAR, CIF,
Quantum-ESPRESSO, XYZ, ABINIT and Materials-Project parsers/writers), runtime
(kernel loader), and constants (physical constants). The sibling directories
scf, plane-wave, band-structure, charge-analysis, xc, wannier,
parallel, and optimization are empty placeholder directories (each holds
only a .gitkeep, no .ts, none exported) — reserved slots, not yet a working
DFT solver. The one TS library that depends on the Rust
@kalika/numerical-engine.
ELECTRONIC_STRUCTURE_KERNEL_NAMES1ELECTRONIC_STRUCTURE_NATIVE_KERNEL_PACKAGES1ELECTRONIC_STRUCTURE_WASM_KERNEL_PACKAGES1createKernelPackageDescriptor1ElectronicStructureKernelName1KernelPackageDescriptor1KernelRuntimeTarget1Atom11ELEMENT_NUMBERS11ELEMENT_SYMBOLS11STANDARD_ATOMIC_MASSES_AMU11AtomInput11AtomSnapshot11CoordinateSystem11 +468 moreElectronic structure visualization: band structures (fat bands, spin, spin texture), density of states, Fermi surfaces, and charge-density/ELF/Wannier isosurfaces (Phase 128.3).
Eliashberg theory of phonon-mediated superconductivity: McMillan-Allen-Dynes Tc, imaginary-axis gap equations, analytic continuation, and multiband gaps for Kalika.
Eliashberg superconductivity (libs/kalika/eliashberg/src): isotropic
imaginary-axis Matsubara gap equations (solveEliashberg,
criticalTemperature, gap-vs-temperature), McMillan and Allen-Dynes Tc with
Morel-Anderson μ* (allenDynesTc, morelAndersonMuStar), multiband and
anisotropic gap equations (solveMultibandEliashberg,
solveAnisotropicEliashberg), Padé analytic continuation plus a direct
real-axis solver with tunneling DOS (solveRealAxisEliashberg), and derived
properties — gap ratio, specific heat, isotope exponent, strong-coupling shape
factor.
ELIASHBERG_LIBRARY_NAME8allenDynesTc10couplingConstant10mcmillanTc10morelAndersonMuStar10omega210omegaLog10MEV_TO_KELVIN10Alpha2F10AllenDynesResult10criticalTemperature22gapRatio22gapVsTemperature22lambdaOfNu22 +34 moreMultiscale embedding (libs/kalika/embedding/src, ~375 lines): frozen-density
embedding with Thomas-Fermi / von Weizsäcker kinetic functionals and
freeze-and-thaw cycles (fdeEmbeddingPotential, freezeAndThaw), QM/MM with
electrostatic embedding, hydrogen link atoms and ONIOM2/3 subtractive layering,
and many-body/defect embedding — Manby-Miller projectionEmbedding,
Green's-function defect embedding, the Freysoldt-Neugebauer-Van de Walle
fnvCorrection, defect formation energies and transition levels. Compact
scalar-and-small-matrix formula implementations, not a full SCF engine.
Entanglement measures (libs/kalika/entanglement/src): von-neumann-entropy,
renyi-entropy, negativity, mutual-information, and topological-entropy.
The typed backbone of the lab-automation family
(libs/kalika/experiment-orchestration/src): model.ts defines campaigns,
hypotheses, budgets, facility constraints, ExecutableProtocol steps with
tolerances/branches/QC gates, sample-lineage graphs, InstrumentSession, and
the SafetyEnvelope rule types that @kalika/instrument-control and
@kalika/lab-safety import; integration.ts builds an
ExperimentStackManifest (createExperimentStackManifest) linking a campaign
to @kalika/notebooks, @kalika/research-agents and @kalika/knowledge-graph.
Honestly a schema-plus-constructors model layer — the coordination contract, not
an executor.
An aggregator facade (libs/kalika/feynman/src/index.ts, ~11 lines):
re-exports @kalika/quantum-field-theory and @kalika/renderer under
namespaces plus a source-modules constant. The Feynman-diagram math/rendering
lives in those two libraries.
FHI-aims interface: control.in/geometry.in generation, species defaults (light/tight/really_tight), and output parsing.
Fluid dynamics (libs/kalika/fluid-dynamics/src, ~16 files): euler-equations,
navier-stokes, ideal-mhd, shallow-water, turbulence-models,
vortex-dynamics, and standard solutions.
A broad formal-methods bridge (libs/kalika/formal-verification/src, ~56
files): SMT solver, first-order ATP, decision procedures, model/computability
theory, derivation-to-tactic, Lean (lean-process-manager,
lean-source-parser, lean-to-kalika/kalika-to-lean, Mathlib lemma DB), and
bridges to Coq, Isabelle, Metamath, SymPy, Sage, Oscar, Symbolica, Wolfram, plus
cross-CAS/cross-prover verification.
Core types, physical constants, unit conversions, and descriptor framework shared by Kalika's functional-materials workflows (batteries, photovoltaics, thermoelectrics, catalysis, 2D materials, MOFs, polymers, high-entropy alloys, metamaterials, and nuclear materials).
Cross-cutting integration for Kalika functional materials: multi-domain workflows (battery-corrosion, PV-defect, catalysis-2D, MOF-catalysis, HEA-corrosion, nuclear-corrosion), a high-throughput screening pipeline and result database, and validation suites against known experimental/reference values across all functional-materials domains.
A large GR library (libs/kalika/general-relativity/src, ~52 files): tensor
algebra, curvature tensors, covariant derivative, exact solutions, ADM/BSSN
formalisms, geodesic solver, black-hole + cosmological perturbation,
gravitational-wave extraction, post-Minkowskian scattering/EOB, Killing vectors,
Penrose-Carter, and benchmark suites. The home of the tensor-calculus machinery
that @kalika/tensor and @kalika/differential-geometry alias.
Geometric analysis (libs/kalika/geometric-analysis/src): geometric flows —
ricci-flow, mean-curvature-flow, harmonic-map-flow, yang-mills-flow, and
perelman-functionals.
Gravitational-wave science (libs/kalika/gravitational-waves/src):
waveform-models, nr-surrogates, data-analysis, detector-models, and
source-modeling.
GROMACS interface: GRO/TOP/MDP file I/O and trajectory/energy parsing (XTC/TRR/EDR structured readers).
GW quasiparticle theory (libs/kalika/gw/src, ~27 files): Adler-Wiser RPA χ₀
(assembleRpaChi0, head/wing/body blocks), dielectric matrix and screened
interaction with Coulomb truncation, plasmon-pole models — Hybertsen-Louie,
Godby-Needs, and Engel-Farid multipole — one-shot G0W0 (solveG0W0, spectral
functions, DFT-starting-point analysis), static COHSEX, full-frequency
self-energies, eigenvalue-self-consistent GW and QSGW (runQsgw, with a BSE
hand-off), space-time-method pieces, and convergence tooling (band-count /
G-cutoff / k-point extrapolation, static-remainder correction) under a
runGwWorkflow driver.
HEP phenomenology (libs/kalika/hep-phenomenology/src, ~44 files, ~16.8k
lines): PDG database, spectrum generator, flavor physics, dark-matter/axion
modules, electroweak precision, and a wide set of HEP file-format and tool
bridges (lhef, hepmc3, lhapdf, root-file, fits-file, yoda,
openloops, collier, checkmate, smodels, higgsbounds-signals).
High-entropy-alloy workflows: SQS generation via Monte Carlo site swapping, lattice distortion and Warren-Cowley SRO, mixing enthalpy/configurational entropy, phase-stability criteria (delta/Omega/VEC), Varvenne-Leyson-Curtin strengthening, stacking-fault energy, elastic moduli, sluggish diffusion, and Cantor/refractory/lightweight HEA workflows.
Higher category theory (libs/kalika/higher-categories/src): simplicial-sets,
quasicategories, stable-infinity-categories, and homotopy-algebras.
Compute orchestration (libs/kalika/hpc-orchestrator/src): job scheduler,
distributed computation, resource monitor, and a computation cache — the
substrate for farming out long-running scientific jobs.
Information theory (libs/kalika/information-theory/src):
quantum-information, entanglement, information-geometry, and
thermodynamic-geometry.
A typed instrument control plane (libs/kalika/instrument-control/src/index.ts,
~1.2k lines): InstrumentDriver capability/command schemas with parameter
validation (validateInstrumentCommand), a connection-state machine, a
STANDARD_ACQUISITION_ADAPTERS catalog spanning
XRD/Raman/XPS/SEM/TEM/AFM/electrochemistry modalities, facility sessions with
manifest export and archive sync, calibration assessment (assessCalibration),
acquisition-template materialization, in-run QC that emits reacquisition
commands (evaluateInRunQc), and streaming partial-dataset dispatch. Honestly a
control-plane model: no VISA/serial/ vendor-SDK transport is implemented here —
InstrumentDriver is the seam a real hardware driver must fill.
KALIKA_INSTRUMENT_CONTROL_PACKAGE3InstrumentConnectionState5InstrumentHealthStatus14AcquisitionModality16InstrumentParameterSchema31InstrumentCommandSchema41InstrumentCapability48InstrumentStateSnapshot56InstrumentCommand65InstrumentDriver70DriverRuntimeRecord79AcquisitionAdapter87AcquisitionPlan96FacilitySession102 +27 moreClassical/quantum integrable systems (libs/kalika/integrable-systems/src):
lax-pair, inverse-scattering, soliton-solutions, hirota-bilinear,
classical-r-matrix, and bethe-ansatz.
A mathematical knowledge graph (libs/kalika/knowledge-graph/src, ~31 files):
ontology, concept linking, analogy/gap detection, graph-RAG, prerequisite
computation, theorem-dependency graph, Lean-theorem registration and Mathlib
dependency extraction, with persistence and query layers.
Fail-closed safety gating for autonomous lab work
(libs/kalika/lab-safety/src/index.ts, ~1.25k lines): a chemical/process hazard
knowledge base compiled into a SafetyEnvelope (buildSafetyEnvelope),
protocol-DSL validation against incompatibility/PPE/exposure rules
(validateProtocolSafety), per-step execution gating with operator credentials
and approval signatures (gateProtocolStep), pre-flight review packets, an
incident/near-miss ledger, and exportable audit traces. Pure policy/validation
logic over @kalika/protocols documents — it decides and blocks; it does not
actuate hardware.
KALIKA_LAB_SAFETY_PACKAGE4SafetyFindingSeverity6SafetyValidationFinding8ChemicalHazardProfile15ProcessRestriction26FacilitySafetyRule38SafetyKnowledgeBase52OperatorCredential62ProtocolSafetyContext68ProtocolSafetyValidation75ExecutionGateDecision83SafetyApprovalSignature88PreflightSafetyReviewPacket96LabIncidentKind126 +13 moreLAMMPS interface: data file I/O, input script generation, thermo/dump/log parsing, and interatomic potential management.
Lattice gauge theory (libs/kalika/lattice/src, ~14 files): gauge-theory,
fermions, hmc (hybrid Monte Carlo), monte-carlo, measurements, and
gauge-configuration I/O.
Lie theory (libs/kalika/lie-theory/src, ~20 files): lie-groups,
lie-classification, representations, root-operations,
structure-constants, weyl-group, casimir, homogeneous-spaces, and
exceptional-constructions.
LOBSTER interface: lobsterin generation and output parsing (COHP/COOP/COBI, ICOHPLIST, CHARGE, DOSCAR.lobster).
Magnetism from first principles: magnetic structure enumeration, exchange coupling (J_ij) extraction, mean-field & Monte Carlo Curie/Neel temperatures, linear spin-wave theory, magnetic anisotropy, DMI, domain walls and magnetocaloric effect for Kalika.
The shared numerical substrate of the GW/BSE family
(libs/kalika/many-body/src, ~56 files, ~7.6k lines): Matsubara/real-axis
Green's functions, χ₀ polarizability and the ε(G,G′,q,ω) dielectric matrix with
dense inversion and local-field ε_M, bare/truncated Coulomb v(q+G), radix-2
Cooley-Tukey FFT with exact-DFT fallback, k-point / imaginary-time / Matsubara
grids, ScaLAPACK-style block-cyclic parallel-layout, HDF5 checkpointing, a
BerkeleyGW bgw-compat layer, and wavefunction I/O for VASP, Quantum ESPRESSO,
ABINIT, GPAW and Wannier90. The compute-backend GPU path is a fail-loud seam:
selectComputeBackend currently always falls back to the real CPU kernels
because the napi-rs/wgpu addon is not bundled — it never fabricates GPU output.
Validation-only companion to the many-body family
(libs/kalika/many-body-benchmarks/src, ~475 lines): reference-data.ts stores
literature reference values (semiconductor and transition-metal-oxide gaps,
exciton binding energies, HEG energy per electron, SrVO₃ Hubbard bands, diamond
cohesive energy) and benchmarks.ts scores computed results against them
(gw100Benchmark, tmoGapBenchmark, bseOpticalSpectraBenchmark,
srvo3Benchmark) via errorStatistics pass/fail verdicts. A testing/validation
library — it checks results; it computes no physics of its own.
Collaborative research infrastructure: project management, provenance, cross-code benchmarking, publication-ready output (figures/tables/CIF/deposition), sharing, and experimental characterization/lab-data integration (Phase 128.7).
Property visualization dashboards: phase diagrams, phonons, transport, spectroscopy, elastic surfaces, and magnetic structure (Phase 128.4).
Client APIs for materials databases: Materials Project, AFLOW, JARVIS, OQMD, NOMAD, OPTIMADE, COD, and molecular/chemical databases.
Educational and onboarding: interactive tutorials (DFT/phonons/defects/screening/ML potentials), contextual tooltips, method-comparison decision tree, glossary, and error-diagnosis assistant (Phase 128.9).
Materials-science knowledge graph: EMMO/MatOnto-compatible ontology, structure-property linkage, processing-structure-property triangle, genealogy, graph-based property prediction, and literature integration (Phase 128.8).
Performance & scalability infrastructure: computation queue (local + SLURM/PBS/SGE), cloud compute integration, result caching / lazy loading / LOD, and import-export parsers (CIF/POSCAR/XYZ/QE/VASP) with pymatgen interop (Phase 128.10).
Materials-science computational notebooks: structure/band/phase-diagram/reaction/screening/comparison cells, smart autocomplete, template notebooks, and inline computation with hash-based caching (Phase 128.5).
Materials science research platform core: workspace/project model, crystal-structure and calculation records, property dashboards, discovery-agent sessions, notebook references, and unified materials-database query schema (Phase 128).
An aggregator facade (libs/kalika/mathematical-physics/src/index.ts, ~19
lines): re-exports six physics libraries (classical-mechanics,
electrodynamics, general-relativity, quantum-field-theory,
statistical-mechanics, string-theory) under namespaces plus a source-modules
constant — a top-level umbrella, no implementation of its own.
KALIKA_MATHEMATICAL_PHYSICS_PACKAGE8MATHEMATICAL_PHYSICS_SOURCE_MODULES10MathematicalPhysicsSourceModule19Matrix models (libs/kalika/matrix-models/src): one-cut-solver,
topological-recursion, and the jt-syk (JT gravity / SYK) module.
Measure theory (libs/kalika/measure-theory/src): measure-spaces,
integration-theorems, and ergodic-theory.
Metamaterials & photonic-crystal workflows: plane-wave-expansion photonic/phononic band structures, band-gap identification, Maxwell-Garnett/Bruggeman effective medium, Drude/Lorentz dispersion, negative-index verification, split-ring resonators, topological photonics, and plasmonic Mie theory.
Machine-learning interatomic potentials and materials informatics for Kalika: descriptors (ACSF/SOAP/ACE/MTP), equivariant neural network potentials (MACE/NequIP/PaiNN), classical ML potentials (GAP/SNAP), active learning, crystal graph networks, generative models, and high-throughput screening.
Atomistic simulation stack: classical & ab initio molecular dynamics, interatomic potentials, enhanced sampling, free energy methods, trajectory analysis, Green-Kubo transport, NEMD, structure prediction, and coarse-grained methods for Kalika.
Atomistic simulation (libs/kalika/molecular-dynamics/src, ~71 TS files, ~7.1k
lines, plus ~6.2k lines of Rust in
rust/crates/{md-core,md-potentials,md-analysis}): the TS layer carries
VelocityVerlet + MDRunner classical-MD orchestration, enhanced sampling
(metadynamics BiasPotential, nudgedElasticBand, string method, WHAM/MBAR),
free-energy estimators (thermodynamicIntegration, bennettAcceptanceRatio,
Jarzynski/Crooks), coarse-graining (DPD, iterative Boltzmann inversion, force
matching), random-search structure prediction, and wide trajectory I/O
(PDB/GRO/DCD/TRR/LAMMPS-data/POSCAR/restart). The Rust crates implement
EAM/Stillinger-Weber/Tersoff potentials, thermostats/PBC, and Green-Kubo thermal
conductivity / shear viscosity (green_kubo.rs) — but are cargo-tested only,
with no napi/wasm bridge into the TS layer yet.
Mossbauer spectroscopy for Kalika (Phase 124): isomer shift from electron contact density, electric-quadrupole splitting from the EFG tensor, magnetic hyperfine field (Fermi-contact/dipolar/orbital), full nuclear-Hamiltonian sextet simulation, Lamb-Mossbauer recoil-free fraction, and oxidation/spin-state identification for 57Fe and other isotopes.
Multiscale materials-engineering core (Phase 129.1): RVE, field variables, constitutive-model interfaces, microstructure/process-history/performance types, and shared structured-mesh & sparse linear-algebra kernels for phase-field, CPFEM, and process simulation.
Multiscale coupling, UQ & decision support (Phase 129.7-8): atomistic-to-continuum parameter passing, PSPP workflow templates, Gaussian-process surrogates, uncertainty propagation (PCE/MC/Sobol), Bayesian calibration fusion, robust decision metrics, and benchmarks.
Physics-informed machine learning (libs/kalika/neural-physics/src, ~16 files):
pinn + separable-pinn, deeponet, fourier-neural-operator,
neural-operator-pipeline, differentiable-physics, and training
infrastructure.
Neutrino physics (libs/kalika/neutrino-physics/src):
oscillation-probability, cross-sections, mass-mechanisms, leptogenesis,
and sphaleron-rate.
Solid-state NMR for Kalika (Phase 124): chemical shielding tensor analysis (isotropic shift, CSA, asymmetry, eigen-decomposition), point-charge electric field gradients with Sternheimer antishielding and quadrupolar coupling parameters, Knight and paramagnetic shifts, powder-averaged CSA/quadrupolar line shapes (ZCW), MAS spinning-sideband (Herzfeld-Berger) and second-order quadrupolar patterns, 2D HETCOR/MQMAS prediction, and reference-compound calibration.
Non-perturbative field theory (libs/kalika/non-perturbative/src, ~28 files):
instantons (bpst-instanton, instanton-calculus, adhm, nekrasov),
monopoles, vortices, skyrmions, kinks, topological defects, and anomaly
machinery (chiral-anomaly, anomaly-polynomial/-descent/-inflow).
Noncommutative geometry (libs/kalika/noncommutative-geometry/src):
spectral-triples, cyclic-cohomology, cstar-k-theory,
noncommutative-algebras, and a standard-model application module.
Nonlinear dynamics & chaos (libs/kalika/nonlinear-dynamics/src):
dynamical-systems, lyapunov, poincare, fractals, route-to-chaos, and
standard systems.
The reactive research-notebook model (libs/kalika/notebooks/src, ~53 files):
reactive engine, CAS kernel, cell execution, dependency locking, reproducibility
- provenance, Jupyter/Mathematica/Pluto interoperability, LaTeX paper import, collaboration/comments/sharing/versioning, reproducible export.
Nuclear & radiation-materials workflows: threshold displacement energy, Frenkel pairs, defect clusters, NRT cascade analysis, He bubbles and H embrittlement, transmutation, void swelling and RIS, UO2 fuel defects and fission gas, zircaloy hydrides and irradiation growth, tungsten plasma-facing retention and sputtering, and ferritic-martensitic steel dose-dependent property prediction.
Computational number theory (libs/kalika/number-theory/src, ~40 files):
elliptic curves + L-functions, modular forms/symbols/Hecke, number fields, local
fields, rings of integers, factorization, primality, Mordell-Weil, and
high-precision/general L-function machinery.
Numerical computing in TypeScript (libs/kalika/numerical/src, ~28 files):
arbitrary-precision arithmetic, computational geometry, Taylor models, verified
computation, Mellin-Barnes, plus interfaces (gmsh, hdf5) and benchmark/
validation suites (linear-algebra, ODE, PDE, Monte-Carlo). The TS numeric path,
distinct from the Rust numerical-engine.
A real Rust dense/sparse linear-algebra kernel (libs/kalika/numerical-engine;
the core crate's lib.rs is ~27k lines covering matrix decompositions, error
types, SIMD paths). Unlike cas-engine, it is declared as a runtime
dependency in @kalika/electronic-structure's package.json (cas-engine is
absent there — it appears only in the looser project.json
implicitDependencies, alongside numerical-engine), so it is the one Rust
kernel with a TypeScript consumer.
Open quantum systems (libs/kalika/open-quantum-systems/src): lindblad,
beyond-lindblad, and noise-channels.
An aggregator facade (libs/kalika/operators/src/index.ts, ~11 lines):
re-exports @kalika/analysis and @kalika/quantum-mechanics under namespaces
plus a source-modules constant — an umbrella for operator-theory consumers, with
no implementation of its own.
Solid-state optical response from first principles: independent-particle dielectric function, Kramers-Kronig, derived optical spectra, nonlinear optics (SHG/THG/shift current), and IR/static dielectric properties for Kalika. (Phase 123 'optics'; named optical-response to avoid the existing photonics @kalika/optics.)
Optics (libs/kalika/optics/src): geometric-ray-optics, fourier-optics,
nonlinear-optics, and quantum-optics.
Optimal transport (libs/kalika/optimal-transport/src): sinkhorn,
wasserstein, monge-ampere, and displacement-interpolation.
Optimization (libs/kalika/optimization/src, ~22 files, ~15.9k lines): linear /
semidefinite (with sdpb-interface) / convex / nonlinear / global +
verified-global programming, least-squares fitting, variational discretization,
and quantum-variational methods.
An aggregator facade (libs/kalika/particles/src/index.ts, ~11 lines):
re-exports @kalika/hep-phenomenology and @kalika/quantum-field-theory under
namespaces plus a source-modules constant — an umbrella, no implementation of
its own.
Periods and polylogarithms (libs/kalika/periods/src, ~14 files): polylog +
elliptic-polylog, mzv (multiple zeta values), hyperint, single-valued,
and feynman-coaction.
Phase-field microstructure evolution (Phase 129.2): Allen-Cahn/Cahn-Hilliard/PFC solvers (semi-implicit spectral + FV), free-energy functionals, grain growth, spinodal decomposition, precipitation, martensitic/ferroic domains, sintering, corrosion, multiphysics coupling, and statistics.
Lattice dynamics: harmonic phonons, dynamical matrices, phonon DOS, thermodynamics, and quasi-harmonic approximation for Kalika.
Harmonic lattice dynamics (libs/kalika/phonons/src, ~58 files, ~6.7k lines):
finite-displacement force constants with symmetry-reduced displacement sets and
orbit averaging (generateDisplacements, extractForceConstants),
acoustic-sum-rule enforcement and space-group symmetrization, dynamical matrices
with Born-charge LO-TO non-analytic correction and Gonze-Lee damping
(dynamicalMatrixWithNAC), dispersion/DOS with linear tetrahedron integration
(tetrahedronDOS), instability detection, and thermodynamics — harmonic free
energy, Grüneisen parameters, and quasi-harmonic runQHA over Birch-Murnaghan
EOS fits (Gibbs energy, Cp). Parses VASP OUTCAR / QE forces and phonopy BORN
files.
Anharmonic lattice dynamics: third/fourth-order force constants, three-phonon scattering, phonon linewidths and self-energies for Kalika.
Anharmonic lattice dynamics (libs/kalika/phonons-anharmonic/src, ~1k lines):
third-order force-constant extraction from irreducible displacement triplets
with permutation symmetrization and a third-order acoustic sum rule
(extractThirdOrderFC), three-phonon matrix elements with Bose factors and
normal/Umklapp classification (classifyProcess), scattering rates turned into
linewidths, lifetimes and frequency shifts, joint DOS, and adaptive-broadening /
cutoff / q-mesh convergence analysis. A direct dependency of
@kalika/thermal-transport.
Density-functional perturbation theory (DFPT) phonons: Sternheimer linear response, force-constant interpolation, and Quantum ESPRESSO ph.x/matdyn.x orchestration for Kalika.
DFPT phonons (libs/kalika/phonons-dfpt/src, ~700 lines): a Sternheimer
linear-response kernel — conduction-projected sternheimerSolve, first-order
density, selfConsistentResponse — Fourier interpolation of dynamical matrices
over Wigner-Seitz vectors with polar splitting (interpolateDynamicalMatrix),
response properties (Raman tensor, elastic and piezoelectric constants from
strain response), and a checkpointed SCF → ph.x → force-constant recovery →
dispersion pipeline (runDfptWorkflow) with longest-processing-time q-point
load balancing. The DFT stages are supplied as engine callbacks (Quantum
ESPRESSO or another engine); a missing callback fails loud rather than
simulating the run.
PHONONS_DFPT_LIBRARY_NAME10firstOrderDensity12rojectConduction12selfConsistentResponse12sternheimerRHS12sternheimerSolve12LinearOperator12SternheimerResult12assemblePerturbationPotential22bornChargeFromResponse22dielectricTensorFromResponse22dynamicalMatrixElementFromResponse22nforceBornSumRule22interpolateDynamicalMatrix30 +16 morePhonons in special systems: surfaces, 2D materials, interfaces (Kapitza), alloys/disorder, Raman/IR/INS spectroscopy, and phonons under pressure/strain/temperature for Kalika.
Phonons in special systems (libs/kalika/phonons-special/src, ~1.1k lines):
Kapitza interface conductance via acoustic-mismatch and diffuse-mismatch models
plus atomistic-Green's-function transmission and Landauer conductance
(ammConductance, dmmConductance, agfTransmission), alloy/disorder tools
(VCA averaging, SQS pair-correlation error, CPA self-energy, band-unfolding
weights), spectroscopy (Raman/IR, one-phonon INS/IXS with powder averaging,
dynamical structure factor), surface slab phonons, 2D flexural ZA-mode
dispersion/DOS, and pressure/strain/temperature conditions.
PHONONS_SPECIAL_LIBRARY_NAME8buildSlab10rayleighVelocity10rayleighVelocityFromTransverse10surfaceLocalization10surfaceProjectedDOS10Slab10davydovSplitting19flexuralCutoffFrequency19flexuralDispersion19flexuralDOS2D19inPlaneAcoustic19rigidLayerModes19scatteringPhaseSpace2D19 +31 morePhonopy/Phono3py interface: phonopy.yaml/FORCE_SETS/FORCE_CONSTANTS I/O, displacement generation, and band/DOS/thermal-property workflow integration.
Photoemission spectroscopy for Kalika (Phase 124): core-level binding energies (Koopmans, Delta-SCF, Slater-Janak), core-level and surface shifts, XPS chemical shifts, Auger parameters, valence-band XPS with photoionization cross-section weighting, shake-up/shake-off satellites, ARPES spectral functions from DFT/GW, photoemission matrix elements, free-electron final states, kz broadening, resonant photoemission, and spin-resolved ARPES / spin textures.
Photovoltaic-materials workflows: Shockley-Queisser and SLME efficiency limits, multi-junction and temperature-dependent efficiency, absorption coefficients, effective masses, defect tolerance, perovskite-halide screening, and OPV/CIGS/CdTe/TCO screening.
Piezoelectric & ferroelectric properties from first principles: piezoelectric tensors (d/e, symmetry, figures of merit), Berry-phase (King-Smith-Vanderbilt) polarization, switching paths, pyroelectric/electrostriction/flexoelectric coefficients for Kalika.
Plasma physics (libs/kalika/plasma-physics/src): vlasov,
dispersion-relation, mhd-equilibrium, and transport.
Polaron physics: Froehlich (weak-coupling + Feynman variational), Holstein (Lang-Firsov, exact diagonalization), bipolarons, and polaron transport for Kalika.
Polaron physics (libs/kalika/polarons/src, ~660 lines): Fröhlich weak-coupling
perturbation energy plus the all-coupling Feynman path-integral variational
bound minimized over (v, w) (weakCouplingEnergy, feynmanEnergy), Holstein
small polarons via the Lang-Firsov transformation with independent-boson ground
state and tridiagonal-Lanczos lowest eigenvalues (langFirsov,
polaronCrossover), bipolaron binding / effective mass / BEC temperature, and
transport — thermally activated hoppingMobility, band-to-hopping crossover,
photoemission phonon sidebands and quasiparticle residue.
POLARONS_LIBRARY_NAME8ffectiveMassTable10feynmanEnergy10feynmanMass10froehlichCoupling10minimizeFeynman10weakCouplingEnergy10weakCouplingMass10FeynmanSolution10bandMobilityScaling21fhipMobility21opticalAbsorption21holsteinCouplingRatios27independentBosonGroundState27 +17 morePolymer & soft-matter workflows: chain generation (RIS, tacticity), amorphous/semicrystalline models, thermal properties (Tg, Green-Kubo conductivity, expansion), mechanical properties (elastic tensor, stress-strain, crazing), coarse-graining (IBI, force-matching, Flory-Huggins), and applications (block copolymer morphology, dielectric, polymer electrolytes, conjugated polymers, degradation).
Porous-materials workflows: MOF structure decomposition, geometric pore analysis (LIS/LFS/PSD/surface area), Grand Canonical Monte Carlo gas adsorption, UFF/TraPPE force fields, isotherm fitting, Henry's constant, isosteric heat, working capacity, IAST mixture separation, water stability, and zeolite/COF/gas-storage workflows.
Positive geometry (libs/kalika/positive-geometry/src): amplituhedron,
associahedron, cosmological-polytope, positroid, and a general
positive-geometry module.
Probability (libs/kalika/probability/src, ~13 files): distributions,
markov-chains, stochastic-processes, random-matrix, and Schramm-Loewner
evolution (schramm-loewner, sle-cft).
Process simulation & manufacturing digital twins (Phase 129.6): transient heat transfer with moving sources, heat treatment, powder-bed fusion melt pool, DED/welding, process-parameter optimization, powder packing, sintering, casting/solidification, and rolling/forging chains.
The experiment-protocol DSL and execution model
(libs/kalika/protocols/src/index.ts, ~1.6k lines): typed step kinds
(synthesis, annealing, mixing, deposition, curing, transfer, characterization)
in a ProtocolDslDocument, compileProtocol to backend commands,
dryRunProtocol simulation against a declared environment (inventory,
equipment, QC gates), a stateful execution machine (createProtocolExecution,
startNextProtocolStep, sign-offs, pause/resume, exceptions + recovery plans,
evidence, checkpoints), and connector planners for liquid handlers (dispense
commands, dilution trees, tip management), thermal/deposition processes, and
robotic transfer. Connector "plans" are typed command sequences for downstream
drivers — no vendor hardware I/O lives here.
KALIKA_PROTOCOLS_PACKAGE1ProtocolActor3ProtocolStepKind4ProtocolBackend13ProtocolResourceRequirement21ProtocolQcGate28ProtocolBaseStep36SynthesisStep50SampleHandlingStep61AnnealingStep68MixingStep76DepositionStep83CuringStep90TransferStep98 +45 moreQuantum ESPRESSO interface: pw.x/ph.x/dos.x/bands.x input generation, SSSP/PSlibrary pseudopotential management, and output parsing.
Quantum Monte Carlo (libs/kalika/qmc/src, ~1.4k lines): Metropolis VMC with
cusp-conditioned Jastrow factors and Slater log-determinants (runVmc,
jastrowFactor), fixed-node importance-sampled DMC with drift-diffusion moves,
population control, and time-step extrapolation (runDmc, validated against the
exact hydrogen −0.5 Ha ground state), phaseless AFQMC (discrete
Hubbard-Stratonovich decomposition, phaselessWeight, back-propagation),
solid-state machinery (Ewald energy, B-spline orbitals, Hellmann-Feynman + Pulay
forces, twist averaging, KZK and MPC finite-size corrections), and
blocking-analysis error bars with autocorrelation times (blockingAnalysis),
all on a deterministic Mulberry32 PRNG.
Quantum chaos (libs/kalika/quantum-chaos/src): level-statistics, otoc,
spectral-form-factor, spectral-unfolding, and quantum-billiards.
An aggregator facade (libs/kalika/quantum-computing/src/index.ts, ~11
lines): re-exports @kalika/quantum-mechanics and @kalika/information-theory
under namespaces plus a source-modules constant — an umbrella, not its own
implementation.
KALIKA_QUANTUM_COMPUTING_PACKAGE4QUANTUM_COMPUTING_SOURCE_MODULES6QuantumComputingSourceModule11A very large QFT library (libs/kalika/quantum-field-theory/src, ~82 files,
~27k lines): Feynman-rule application, diagram topology, Dirac/color algebra,
IBP reduction, Passarino-Veltman, one-loop scalar integrals, renormalization /
RGE (automated-rge, renormalization-group), Dyson-Schwinger, EFT matching,
NLO automation, and external-tool bridges (amflow, finiteflow).
Quantum gravity (libs/kalika/quantum-gravity/src): loop-quantum-gravity,
causal-dynamical-triangulations, and asymptotic-safety.
Quantum groups (libs/kalika/quantum-groups/src): drinfeld-jimbo,
crystal-bases, r-matrix, and kazhdan-lusztig.
Quantum mechanics (libs/kalika/quantum-mechanics/src, ~35 files):
hilbert-space, operators, time-(in)dependent Schrödinger solvers,
perturbation-theory, path-integral, scattering-formalism,
angular-momentum-coupling, spherical-harmonics, spin-algebra, hybrid
quantum-classical, and a quantum-hardware-interface.
Scientific visualization (libs/kalika/renderer/src, ~40 files): function/data
plotting, complex visualization, vector/field plots, plus physics-specific
diagram renderers (feynman-diagram, tikz-feynman, dynkin-diagram,
penrose-carter-diagram, spacetime-diagram, quantum-circuit-diagram,
tensor-network-diagram, young-diagram), gltf, pgfplots, and
time-evolution animation.
createThreeSurfaceScene20lotImplicitSurface3D20lotParametricSurface3D20lotSurface3D20KALIKA_RENDERER_PACKAGE48Autonomous research agents (libs/kalika/research-agents/src, ~60 files):
conjecture formulation/validation, FunSearch-style generation, proof agent /
proof-search-tree / proof-repair, retrieval-augmented proving, multi-agent
orchestration, plus literature clients (arxiv, inspire-hep,
semantic-scholar, openalex, oeis) and paper-claim/reproduction verifiers.
Federated research operations (libs/kalika/research-ops/src, ~1.9k lines): a
FederatedSiteRegistry with access-policy evaluation and cross-site replication
planning, SHA-256 content-hash provenance signing (canonicalize/contentHash,
signProvenance), an ImmutableArtifactRegistry with integrity reports,
retention classes and checkpoint-cadence rules, execution-environment capture
exported as Spack/Nix/container recipes with validation, workflow replay bundles
gated by a fail-loud assertProductionReady, and a LicenseAwareScheduler with
fair-share priorities. Governance and bookkeeping logic — it does not itself run
the computations it tracks.
Linear-response and dielectric properties (libs/kalika/response/src, ~340
lines): the Dyson equation for the interacting susceptibility (dysonResponse),
static Lindhard function, charge susceptibility and compressibility, macroscopic
dielectric constant / loss function / optical constants and joint DOS, plus
sum-rule diagnostics — f-sum and conductivity sum rules, plasma frequency, and a
Kramers-Kronig transform with residual check (kramersKronigResidual). A
compact formula-level companion to @kalika/many-body's full ε(G,G′,q,ω)
machinery.
Resurgence / asymptotic-series summation (libs/kalika/resurgence/src):
borel-summation, borel-pade, transseries, alien-calculus, and
perturbative-coefficients.
Sample lifecycle operations (libs/kalika/sample-ops/src/index.ts, ~1.5k
lines): hazard-aware inventory assessment against facility rules
(assessInventory), sample registration with barcode/QR/RFID tags over
@kalika/experiment-orchestration lineage types, plate/wafer/single-sample
container builders with position maps, a digitally signed chain-of-custody
ledger (appendChainOfCustodyEvent), batch/queue planning for characterization,
annealing and beamtime, and contamination-rule co-processing validation
(validateCoProcessing). Pure typed ledger/planning logic — the LIMS brain, not
a robot.
KALIKA_SAMPLE_OPS_PACKAGE8HazardClass10FacilityHazardRule23InventoryLot31InventoryCompatibilityIssue49InventoryAssessment56InventoryLedger72SamplePackagingState79SampleArchivalStatus88SampleTagKind90SampleTag92RegisteredSample97SampleRegistry105SampleRegistrationRequest111 +25 moreZero-server TypeScript SDK for Kalika symbolic computation and physics utilities.
The TypeScript client SDK (libs/kalika/sdk/src): engine, numeric,
physics, sdk, types, and wasm-kernel modules — the developer-facing
surface for driving Kalika computations.
A focused semidefinite-programming core (libs/kalika/sdp-core/src): a single
substantial semidefinite-programming module (~2.5k lines) — the SDP solver
primitives reused by bootstrap/optimization consumers.
Spectral geometry (libs/kalika/spectral-geometry/src, ~18 files):
heat-kernel, laplace-beltrami, index-theorem + index-applications,
eta-invariant, spectral-zeta, spin-geometry, and curved-spacetime-qft.
Core spectroscopy types, enums, physical databases (X-ray edges, NMR/Mossbauer nuclei, photoionization cross-sections), spectrum containers, registry and serialization shared across all Kalika spectroscopy modules (Phase 124).
Auxiliary spectroscopies for Kalika (Phase 124): UV-Vis absorption and oscillator strengths, photoluminescence from the configuration-coordinate model (Huang-Rhys, ZPL, Stokes shift, radiative rate, temperature dependence), X-ray emission (Kalpha/Kbeta, valence-to-core, Kbeta mainline spin analysis), resonant inelastic X-ray scattering (Kramers-Heisenberg, RIXS maps, dd excitations), EPR (g-tensor, hyperfine, zero-field splitting, powder spectrum), and Compton profiles / positron annihilation lifetimes.
Cross-technique spectroscopy validation suites for Kalika (Phase 124.11.4): compares computed observables against known experimental values for XAS/EXAFS (Cu), Mossbauer (Fe oxides), EELS plasmons (Al/Si/diamond), Raman (Si/diamond), NMR, and EPR, exercising the @kalika spectroscopy libraries end to end.
SPECTROSCOPY_VALIDATION_LIBRARY_NAME23ValidationCheck25ValidationReport33validateXAS65validateMossbauer110validateEELS128validateRaman147validateEPR171validateXPS194validateNMR227validateMossbauerQuantitative247validateRamanSpectrum273validatePipeline306runAllValidations348Spectroscopy visualization for Kalika (Phase 124): interactive 1D spectrum plots (SVG + JSON scene graph), multi-spectrum overlays/waterfalls, peak-decomposition and theory-vs-experiment panels, 2D maps (RIXS, ARPES with band overlay, 2D NMR correlations) with perceptual colormaps, orbital/atom/band-decomposed contribution plots, and real-space scene descriptors (core orbitals, exciton wavefunctions, NMR shielding ellipsoids).
Spectrum processing for Kalika (Phase 124): analytic line shapes (Gaussian/Lorentzian/Voigt/pseudo-Voigt/Doniach-Sunjic), Levenberg-Marquardt multi-peak fitting and auto peak detection, backgrounds (linear/Shirley/Tougaard), Savitzky-Golay smoothing/derivatives, Richardson-Lucy & Wiener deconvolution, energy calibration, Gaussian/Lorentzian/Voigt broadening, theory-vs-experiment comparison metrics, alignment, and spectrum file parsers (ASCII/XDI/VAMAS/JCAMP-DX).
Spintronics from first principles: spin/anomalous Hall conductivity, Berry curvature, Rashba/Dresselhaus spin splitting, spin textures, spin relaxation (Elliott-Yafet/D'yakonov-Perel), and magnetoresistance devices (TMR/GMR/STT/MTJ) for Kalika.
Statistical mechanics (libs/kalika/statistical-mechanics/src, ~20 files):
partition-functions, classical-lattice-models, mean-field-theory,
quantum-statistical-mechanics, non-equilibrium, RG, exact results, and a
stat-mech-lattice-bridge.
A large string-theory library (libs/kalika/string-theory/src, ~48 files,
~14.9k lines): ads-cft, conformal-field-theory, virasoro,
calabi-yau-geometry, mirror-symmetry, toric-geometry, flux/orbifold
compactification, BCFW recursion, spinor-helicity, generalized unitarity,
color-kinematics, and ML-assisted modules (neural-calabi-yau-metric,
ml-hodge-prediction, rl-string-landscape).
Supersymmetry (libs/kalika/supersymmetry/src): grassmann, superspace +
n2-superspace, superfields, and SUSY lagrangian construction.
Surrogate modelling (libs/kalika/surrogate/src): a single substantial
gaussian-process module (~1.7k lines) for GP regression/emulation.
Symbolic regression / equation discovery (libs/kalika/symbolic-regression/src,
~17 files): genetic-programming, transformer-symbolic-regression,
llm-guided-symbolic-regression, physics-equation-discovery,
separability/symmetry detection, and AI-Feynman benchmarks.
Symplectic geometry (libs/kalika/symplectic/src): symplectic-manifold,
floer-homology, symplectic-capacities, hamiltonian-reduction, and
geometric-integrators.
Time-dependent DFT (libs/kalika/tddft/src, ~420 lines): Casida-equation
excitations in full and Tamm-Dancoff form (solveCasida), exchange-correlation
kernels — ALDA, gradient-corrected, hybrid, and long-range-corrected with α from
ε∞ (aldaKernel, lrcKernel) — real-time propagation via unitary
Crank-Nicolson steps with dipole-to-absorption spectra, Bloch current, and an
Ehrenfest nuclear step (crankNicolsonStep, ehrenfestStep), plus a
TDDFT-vs-BSE spectrum comparison and kernel ranking (compareTddftBse).
Formula-level model dimensions, not a plane-wave TDDFT code.
An aggregator facade (libs/kalika/tensor/src/index.ts, ~7 lines):
re-exports @kalika/general-relativity and declares
TENSOR_SOURCE_MODULES = ['@kalika/general-relativity']. Tensor-calculus code
lives in the GR library; this is a thin alias.
Tensor networks (libs/kalika/tensor-networks/src, ~15 files): mps, peps,
mera, dmrg, lattice-gauge, a generic tensor-network (the einsum
engine), and XXZ benchmarks.
Thermal properties from first principles: specific heat (lattice/electronic/Debye), thermal expansion (QHA/Gruneisen), total thermal conductivity, thermal diffusivity, minimum thermal conductivity and thermal boundary resistance for Kalika.
Lattice thermal conductivity: phonon Boltzmann transport (RTA, iterative, direct, variational BTE), scattering mechanisms, and four-phonon processes for Kalika.
Lattice thermal conductivity (libs/kalika/thermal-transport/src, ~1.1k lines,
depends on @kalika/phonons + @kalika/phonons-anharmonic): phonon-BTE solvers
from RTA through iterative, direct, and variational-bound forms (kappaRTA,
iterativeBTE, directBTE, variationalBound), mode-resolved and
temperature-dependent κ, scattering mechanisms — Tamura isotope mass-variance,
Casimir boundary, alloy, T-matrix and four-phonon rates combined by
Matthiessen's rule — and spectral analysis: mean-free-path accumulation, a
Wigner coherent-transport contribution (wignerCoherentKappa), and
ballistic-diffusive suppression.
THERMAL_TRANSPORT_LIBRARY_NAME8cumulativeByMeanFreePath10groupVelocity10groupVelocityToMetersPerSecond10meanFreePath10modeHeatCapacity10directBTE18isotropicKappa18iterativeBTE18kappaFromF18kappaRTA18modeResolvedKappa18mperatureDependentKappa18variationalBound18 +24 moreThermodynamics (libs/kalika/thermodynamics/src): equations-of-state,
phase-diagrams, thermodynamic-cycles, and thermodynamic-potentials.
Thermoelectric figure of merit (ZT), efficiency, compatibility factor, Pisarenko/SPB analysis, bipolar transport, and band-engineering descriptors (valley degeneracy, quality factor) for Kalika.
Thermoelectric-materials workflows: ZT(T,n) pipelines, optimal doping and power-factor optimization, band-engineering (convergence, resonant levels, gap tuning), phonon-engineering (rattlers, Gruneisen anharmonicity, Callaway nanostructuring, Klemens point-defect scattering), materials-class workflows (Bi2Te3/PbTe/half-Heusler/skutterudite/SnSe), and high-throughput screening.
3-manifold topology (libs/kalika/three-manifolds/src): heegaard-floer, wrt
(Witten-Reshetikhin-Turaev), and interfaces to regina and snappy.
Topological quantum computing (libs/kalika/topological-qc/src): anyon-model,
braiding-simulation, gate-compilation, topological-entanglement, and
standard models.
Topology (libs/kalika/topology/src, ~26 files): simplicial-complex,
cw-complex, homotopy, cohomology, Morse theory/homology, discrete Morse,
knot-theory, persistent-homology, and TDA applied to cosmic structure /
phase transitions (cosmic-structure-tda, phase-transition-tda).
Topological materials from first principles: Z2 invariants (parity, Wilson loop, Pfaffian), Chern numbers (Fukui-Hatsugai-Suzuki), Weyl/Dirac/nodal-line detection, surface Green's functions (Sancho-Rubio), and topological classification for Kalika.
ML training-data pipeline for math models (libs/kalika/training-data/src, ~74
files): arXiv-LaTeX extraction, dedup, domain balancing, proof-pile, tokenizer
extension, embedding/instruction-tuning/reward-model training, RLVF,
constitutional AI, model A/B testing, serving/routing, speculative decoding,
KV-cache. A large self-contained ML-ops corner of the area.
Electronic and thermal transport from first principles: Boltzmann transport equation (CRTA, iterative, variational), Onsager coefficients, scattering mechanisms, magnetotransport, and shared transport tensor/BZ-integration primitives for Kalika.
Tropical geometry (libs/kalika/tropical/src, ~16 files): semiring,
polynomial, convexity, newton-polytope, variety, grassmannian, and a
feynman (tropical-Feynman) module.
Two-dimensional materials workflows: monolayer database, exfoliation energy and stability, van der Waals heterostructures (lattice matching, Moire patterns, twist enumeration, band alignment), twist-angle physics (magic angle, flat bands), 2D magnetism/valley/topology, and 2D alloys/Janus/MXenes.
LaTeX typesetting and import (libs/kalika/typesetting/src): equations,
derivation, latex + latex-import, and paper modules for rendering Kalika
results and ingesting papers.
Shared scientific utilities (libs/kalika/utils/src): dimensions,
physical-constants, and physical-quantity (units-and-dimensions support used
across the physics libraries).
VASP interface: INCAR/POSCAR/KPOINTS/POTCAR generation with Materials Project-compatible presets, output parsing (vasprun.xml, OUTCAR, CHGCAR, DOSCAR, EIGENVAL), and custodian-matching error handling.
Vertex algebras (libs/kalika/vertex-algebras/src): vertex-operator-algebra,
module-theory, w-algebras, standard-constructions, and moonshine.
Vibrational spectroscopy for Kalika (Phase 124): IR intensities from Born effective charges, Raman tensors and intensities, symmetry-based IR/Raman activity and Gamma-point group-theory mode decomposition, polarization/temperature/resonant Raman, SERS enhancement, 2D-material layer/shear modes, anharmonic IR from AIMD dipole autocorrelation, ATR/reflectance IR with Kramers-Kronig, and phonon-mode visualization.
Standalone Wannier function models, interpolation utilities, and WANNIER90-compatible data types for Kalika.
A near-empty scaffold (libs/kalika/wannier/src/index.ts is a single line
exporting WANNIER_PACKAGE_NAME = '@kalika/wannier', plus a trivial spec). No
Wannier-function implementation lives here — and none lives anywhere else
either: electronic-structure/src/wannier/ is itself an empty placeholder
directory (.gitkeep only), and the only wannier references in Kalika TS are
the unrelated Wannier-center-flow (condensed-matter) and Kramers-Wannier
duality (statistical-mechanics/notebooks) uses, not Wannier-function
machinery. Shown as a reserved/placeholder slot, not a working library.
WANNIER_PACKAGE_NAME1computeOverlapMatrix3computeWannierSpread3valuateWannierFunction3spreadGradientPerKPoint3Complex3ComplexMatrix3NeighbourOverlap3Vec33WannierFunctionRealSpaceInput3WannierSpreadResult3arseAmn16arseEig16arseHrDat16 +35 moreWANNIER90 interface: .win input generation, .amn/.mmn/.eig/.chk file I/O, and Wannier output/application parsing (Fermi surface, band interpolation).
Materials workflow engine: DAG execution, provenance tracking, and built-in templates for relaxation, band structure, phonons, elastic, and dielectric workflows.
X-ray absorption spectroscopy for Kalika (Phase 124): muffin-tin potentials, complex radial Schrodinger (Numerov) phase shifts and t-matrices, real-space full multiple scattering XANES (free-electron propagator, FMS matrix inversion, dipole/quadrupole cross-sections, cluster generation), edge types with XNLD/XMCD sum rules and pre-edge analysis, EXAFS path expansion with Debye-Waller factors and cumulants, k/R-space EXAFS fitting, and XAS processing (background, E0, chi(k), Fourier transforms).
Standalone exchange-correlation functional registry and evaluators for Kalika electronic-structure calculations.
DFT exchange-correlation functionals (libs/kalika/xc-functionals/src, ~36
files, ~8.1k lines): organised by rung — lda, gga, and meta-gga modules
exposing many named functionals through the barrel.
XC_FUNCTIONALS_PACKAGE_NAME1PZ81_PARAMETERS3valuatePZ81Channel3rdewZunger81CorrelationFromDensity3rdewZunger81CorrelationFromRadius3z81SpinInterpolation3wignerSeitzRadiusFromDensity3PZ81BranchParameters3PZ81CorrelationChannelResult3PZ81CorrelationResult3PZ81SpinChannel3VWN_PARAMETERS16valuateVWNChannel16voskoWilkNusairCorrelationFromDensity16 +361 morePython bindings (libs/kalika/sdk-python/src/kalika_sdk) exposing a SymPy-like
surface (symbols, diff, integrate, solve); the default backend shells
out to the TypeScript SDK via a Node/tsx subprocess (_bridge.ts,
backends.py, client.py, expressions.py). Nx project name is the un-scoped
kalika-sdk-python.
unclassified (1)#
A Jupyter kernel (libs/kalika/jupyter-kernel/src/kalika_jupyter, ~600 lines
Python) that runs Kalika CAS computations from notebook cells (simplify,
diff, integrate, solve, eval) while preserving derivation chains and
verification metadata in rich output bundles. Nx project name
kalika-jupyter-kernel.