ĀKRITI
Assured Knowledge & Reasoning In Topological Inference
An open ecosystem for topological data analysis in Python.
One diagram format across every backend. A statistical layer that turns shape into evidence. A maintained home for published TDA methods, whoever wrote them. Built on GUDHI and Ripser rather than around them — Apache-2.0, openly governed, contributions welcome.
About
Not another library. The connective tissue between the ones that exist.
Python's topological data analysis tools are excellent and unconnected. Persistence engines that don't share a data format. Vectorisations scattered across half-maintained packages. Statistical methods published in papers and never implemented. A scientist who wants to ask a simple question — is this feature real? — has to assemble the answer from four libraries and a stack of PDFs.
Akriti exists to be the layer that holds those pieces together: a common diagram format, the statistics Python has been missing, and a maintained home for methods from across the field. It began as the software behind four papers from our group. It is not that any more, and it should not be — an ecosystem that only implements its founders' work is a library with ambitions.
GUDHI, Ripser and Hera, interoperate with persim, giotto-tda and scikit-tda, and integrate with the scientific Python stack (scikit-learn, AnnData, scanpy). We are not trying to replace any of them.
Why an ecosystem
The gaps are structural, not technical.
Every piece of the Python TDA stack works. What is missing is the coordination between them — and coordination is not something any single library can add to itself.
- No shared format. Every backend emits persistence diagrams its own way, so the first thing anyone writes is conversion glue, and they write it again on the next project. A common interchange type is a small piece of code and a large amount of saved time.
- Statistical inference lives in R. The
TDA,TDAstatsandtdaversepackages have offered permutation tests and bootstrap confidence sets for years, funded and coordinated. Python — with a far larger TDA user base — has had essentially nothing equivalent. - Published methods go unimplemented. Two-sample tests, confidence sets, effect sizes and vectorisations appear in the literature and are never packaged. Each is re-derived by whoever next needs it. A maintained home for them is worth more than any single new method.
- No sample-size calculus exists at all. "How many samples do I need to detect a bottleneck-distance difference of size δ?" is a question applied statistics answers routinely for every standard test, and topology has never answered once.
- Maintenance is fragile. Several of the field's computational cores are maintained by one person, some with no tagged releases. The general-purpose layer, giotto-tda, has had no commits since 2024 while still being installed thousands of times a month. That is a supply-chain problem for everyone downstream, and it is nobody's job to fix.
None of this is a criticism of the projects involved. They are research software written by mathematicians whose institutions reward theorems, not maintenance. The gap is organisational, and the fix has to be organisational too.
What's in it
A toolkit, not a single trick.
Akriti is early. Modules are marked building where work is under way and planned where they are on the roadmap — we would rather be accurate than impressive.
Principles
Commitments we intend to be held to.
- We delegate computation. Persistence, bottleneck and Wasserstein distances go to GUDHI, Ripser and Hera. We do not reimplement them, and we will not. Reinventing the engines is how library projects die.
- We implement other people's methods. A method's home should not depend on who wrote it. If it is published, useful, and unimplemented in Python, it belongs here — cited and benchmarked honestly against the alternatives, including ours.
- We interoperate before we compete. If something here does not work cleanly with your library, that is our bug. Maintainers of neighbouring projects are the contributors we most want.
- We say what we do not know. Where our theory supports a default, we take it and explain why. Where it provably does not, we say so and point at cross-validation. Guardrails, not autopilot.
- We stay installable. One command, no compiler, on every platform. The default dependency closure stays permissively licensed; copyleft backends are opt-in and documented at the install boundary.
- We take maintenance seriously. Signed releases, a published security policy, an audited dependency tree, and more than one maintainer at more than one institution — because the failure mode in this field is not bad code, it is abandonment.
In Python
From diagram to defensible claim.
Bring diagrams from any backend, or let Akriti compute them. Either way you finish with a number you can put in a paper. API shown is indicative and still settling.
import akriti # ── Bring diagrams from wherever you already compute them ───── D = akriti.diagrams.from_gudhi(st.persistence()) # ── Are these two groups topologically different? ───────────── test = akriti.castle.two_sample(group_A, group_B) print(test.p_value, test.effect_size) # ── How much data would I have needed? ──────────────────────── n = akriti.castle.sample_size(effect=0.1, power=0.8, pilot=D) # ── A reporting card for the methods section ────────────────── print(test.report())
Contribute
This is the part that makes it an ecosystem.
An ecosystem is not a licence declaration — it is other people's work, running alongside yours, under governance they can see. Akriti is early enough that joining now shapes what it becomes.
- Review the diagram interchange specification. If it does not fit your library's output, we would rather learn that now than after it ships. This is the single most useful thing a neighbouring maintainer can do.
- Have us implement your method. If you have published TDA statistics with no Python implementation, open an issue. We would rather host it, cited and attributed, than see it re-derived.
- Bring a dataset and a question. Case studies from domain scientists tell us what is missing far faster than we can guess.
- Teach with it. If you run a TDA course, we want to know what confused your students. That feedback is worth more than a feature request.
Apache-2.0 throughout, with an explicit patent grant. Contributions are licensed inbound under the same terms, so there is no CLA to sign.
Team
Maintained across two institutions, by design.
The most common way scientific software fails is that one person stops. Akriti is deliberately maintained by more than one person at more than one university.
Where it started
Founded on our own research. Not limited to it.
Akriti began as the software behind four papers from our group, and those results remain the statistical core. But an ecosystem that implements only its founders' work is a library with ambitions — the roadmap deliberately includes methods we did not write.
Standing on
Akriti delegates persistence computation to GUDHI (INRIA), Ripser and Hera, and builds on the landmark embedding of Mitra & Virk (2024). It exists because of work done across the topological data analysis community — scikit-tda, persim, giotto-tda, the R tdaverse, and decades of inference, vectorisation and stability results we did not produce.
A "Publications using Akriti" section will appear here as case studies are published.