Reference · release 0.2.11
Python API & error handling
Use the stable public workflow, and distinguish interface stability from numerical qualification.
Source and release provenance · v0.2.11
docs/reference/qf_solver_api.md ↗Four stable entry points
| Function | Contract |
|---|---|
| load_model(path) | Read a JSON file and return FiniteElementModel |
| check_mesh(model) | Return MeshReport: PASS, WARNING or FAIL |
| solve_model(model, *, enforce_policy=True) | Apply the active verification profile and return the result |
| save_result(result, path) | Serialize finite JSON using the result to_dict() method |
Handle failures by their meaning
| Exception | Meaning |
|---|---|
| InputValidationError | Unreadable, malformed or schema-invalid input |
| MeshValidationError | Invalid mesh, connectivity or boundary conditions |
| NumericalConvergenceError | Numerical method failure with diagnostics |
| QualificationGateError | Completed result rejected by its verification profile |
| InfrastructureError | Missing optional dependency or backend/runtime failure |
Additional stable tools
The documented facade also includes inspect_model, assess_result, save_model, import_gmsh_model, save_result_csv, save_result_vtu, save_audit_markdown, save_evidence and verify_evidence.
Provisional boundaries
read_inp and the family-aware mixed HDF5 functions are provisional. Their signatures or result schemas may evolve in a later minor release. Large-model and campaign helpers also have provisional contracts. No facade symbol is currently marked deprecated; legacy solveur and CLI compatibility paths have their own migration policy.