Skip to main content

Math-proof toolchain skills for NeuroCore: CAS, SMT, ATP, and formal proof assistants

Project description

neurocore-skill-math

A math-proof toolchain for NeuroCore: one package exposing many small, composable skills that wrap computer-algebra systems, SMT solvers, automated theorem provers, and formal proof assistants. A supervisor agent / FlowEngine blueprint composes them into proof-search and proof-validation chains.

pip install neurocore-skill-math          # pulls sympy, mpmath, z3-solver
pip install "neurocore-skill-math[cvc5]"  # + cvc5 SMT backend (optional)

Most external engines (Lean, Vampire, Isabelle, Coq, SageMath, GAP, PARI/GP, …) are not Python packages — install them with the provided script (scripts/install_math_tools.sh, Ubuntu 24.04) and check what's available:

python -m neurocore_skill_math.check      # prints a tool-availability report

Every skill detects whether its backend is installed and degrades gracefully (status tool_unavailable) rather than crashing a flow.

Skills

type Group Backend Reads → writes
math_problem_parser prep LLM problemmath.parsed
math_domain_classifier prep LLM math.parsedmath.domain
math_statement_normalizer prep LLM math.parsedmath.normalized
sympy_simplify / sympy_solve / sympy_calculus symbolic SymPy math.normalizedevidence.sympy
mpmath_high_precision_check numeric mpmath math.normalizedevidence.numeric
pari_gp_number_theory CAS gp math.normalizedevidence.pari
gap_group_theory CAS gap math.normalizedevidence.gap
sagemath_compute CAS sage/Docker math.normalizedevidence.sage
z3_smt_check SMT z3 math.normalizedcounterexamples.z3
cvc5_smt_check SMT cvc5 math.normalizedcounterexamples.cvc5
mace4_countermodel counterexample mace4 math.normalizedcounterexamples.mace4
vampire_prove_tptp / eprover_prove_tptp ATP vampire/eprover math.normalizedproof.*
prover9_prove ATP prover9 math.normalizedproof.prover9
llm_proof_planner planning LLM evidence → proof.strategy
theorem_retriever planning LLM proof.strategyproof.premises
lean4_formalize_statement formal LLM math.normalizedformal.lean_candidate
lean4_check formal lean/lake formal.lean_candidateformal.lean_result
lean4_repair formal LLM formal.lean_candidate + errors → formal.lean_candidate
isabelle_check_theory formal isabelle formal.isabelle_candidateformal.isabelle_result
coq_check formal coqc formal.coq_candidateformal.coq_result
proof_report_builder report all envelopes → validation_status / final_answer / proof_artifacts

Result envelope & ports

Each skill writes a uniform envelope: {status, tool, available, result, log, error, duration_ms} with status ∈ {ok, proved, refuted, unknown, tool_unavailable, error, timeout}.

Skills set output ports so graph blueprints can route:

  • SMT / Mace4: counterexample_found / no_counterexample
  • ATP: proof_found / no_proof
  • Lean/Isabelle/Coq check: verified / repair_needed / failed
  • domain classifier: number_theory / group_theory / …

All skills take configurable input_key / output_key (the doc's dotted-key contract, e.g. evidence.sympy), so the same skill can be wired into different positions in a chain.

Blueprints

blueprints/ ships two reference proof workers from the design:

  • lean-first-math-worker.flow.yaml — a focused parse → explore → refute → formalize → verify → repair → report loop.
  • math-proof-validation-worker.flow.yaml — the full fan-out across CAS/SMT/ATP then Lean/Isabelle/Coq validation.

Graph routing. These workers use edge ports, edge conditions, and a Lean repair loop. With neurocore-ai>=0.4.0 (on flowengine>=0.6.0), NeuroCore routes such graph flows through flowengine's GraphExecutor, which honors port/condition gating and cyclic max_iterations — so the conditional early-exits and the repair loop execute as drawn. Plain DAGs (no ports/conditions/cycles) still use the concurrent layer executor. On older NeuroCore the skills' ports are simply ignored (all reachable nodes run).

Convention

Standard NeuroCore skill package: entry-point group neurocore.skills, import package neurocore_skill_math, kebab distribution neurocore-skill-math. See the skill-authoring guide.

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

neurocore_skill_math-0.1.0.tar.gz (26.7 kB view details)

Uploaded Source

Built Distribution

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

neurocore_skill_math-0.1.0-py3-none-any.whl (26.8 kB view details)

Uploaded Python 3

File details

Details for the file neurocore_skill_math-0.1.0.tar.gz.

File metadata

  • Download URL: neurocore_skill_math-0.1.0.tar.gz
  • Upload date:
  • Size: 26.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for neurocore_skill_math-0.1.0.tar.gz
Algorithm Hash digest
SHA256 01e91f585081d40e3ab0a5c72cffdf6db39923509a685a7ef9e379fbc2305d49
MD5 d01514a5d1ffbc508498b3aa0fe59f61
BLAKE2b-256 69fa922df2f43c52a38c43ed0070af246b5a2651efc9817cad038834956c2ee1

See more details on using hashes here.

File details

Details for the file neurocore_skill_math-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for neurocore_skill_math-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cfcf9f11b60dd9e6ae15b444f5401b751ed6361b7317a59986ddb45750034325
MD5 68b301d41319d8b1819a389109298bfb
BLAKE2b-256 3ca726a2e106d6cc844916e4b5a7ced52aefdeaed06356ea812af90381ff06b2

See more details on using hashes here.

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