GNU Octave is like Matlab. Matplotlib is like Matlab but doesn't support the same syntax.
Will it have a DataFrame API?
Before R data.frame and Pandas DataFrame and substrait.dataframe, there were labeled arrays in NumPy.
Pint uses numpy ufuncs to type numbers with physical units.
Here are the notes I had for pgrust a few months ago: https://news.ycombinator.com/item?id=49112449 ; Polars (already has tested SIMD and GPU-optimized routines), substrait interface, and file formats: LanceDB, Vortex, Arrow recordbatch
Here are my notes for the ArtCraft folks about methods for Rust ports (and whether it's necessary to also port Blender to Rust with an O3/Maturin Python API) https://github.com/storytold/artcraft/issues/2489 :
> port the tests [and check figures] first; use branch coverage metrics when testing;
use cargo-llvm-cov and rust-nightly to test;
make (.sh,) scripts that the .github/workflows/ call so that local builds are easy;
run local builds using nektos/act;
use rstest to keep tests and test fixtures maintainable;
use cargo-insta to snapshot;
use cargo-fuzz, and do coverage-guided fuzzing;
use TLA+, Lean or similar formal methods and tools to model the critical parts of the app at least
In the ArtCraft issues,
there are so many great ideas that any or many or all firms could benefit from.
Does safety matter for this kind of software? It’s mostly internal tooling used by researchers and statisticians. I get it rust is cool but safety isn’t the prime concern here I think.
Author's comments are dead unfortunately so I'll repost w fragment from them here:
> It's not about memory safety per se. It's about not losing an hour of analysis because a malformed .sav file or a zero-variance sample triggered a segfault or silent wrong output. SPSS crashes on bad data.
A couple days ago we had 0-click RCE in MS Paint. At this point, we must think about safety everywhere, we're entering AI era where vulnerabilities are easy and fast to find, exploit and chain in automated ways, and it only accelerating.
Rust is the prime language for vibecoding because the compiler checks most of the issues for you. This is meant to be part of the ArtCraft suite, so it is intended to be developed and managed with AI agents.
People always seems to confuse correctness as in „it compiles“ vs. „it does what I intended it to do“, not sure how Rust helps with that as it won’t solve mismatch between intent and implementation. Or how could it? Main problem with vibe coding is that you almost always under specify requirements so the agent will fill in the blanks and make choices for you, the language it implements these choices in doesn’t matter much in my opinion, agents will produce correct code from a detailed specification almost always which is why they are so good at translating between languages, they are terrible at interpreting requirements not specified or derivable for complex software though. Rust can’t solve that.
> not sure how Rust helps with that as it won’t solve mismatch between intent and implementation.
It's not rust specific, but any language which allows you to work on a higher level and with better typing helps close that gap. For example for a long time Linux kernel had an issue with marking user/kernel addresses which opened it up to bugs and security issues. In C those are just numbers. In Rust this is moot and correct by default because user addresses are explicitly UserPtr.
So yes, sometimes a better language allows you make some unintended things explicitly not compile. It won't solve the issue completely, but the scope of the mismatch gets much smaller.
You don’t even understand my point. It’s about specifying what you want to accomplish, the code can be correct and safe and still do the wrong thing, that’s the most relevant bug for a statistics software like SPSS. Almost no one cares about it segfaulting once in a million runs, people do care about it doing the math right. Rust doesn’t help at all with that. Rust isn’t more high level than C or other languages or how is it? Does it know anything about quantiles or student t distributions and will warn the agent if it implements them wrong?
Full validation of spec to implementation is still close to impossible and nothing that exists today will get us there outside of extremely limited scope. But some language features make the gap just a bit smaller. The less you have to look at details and more at the actual structure, the more you can be sure the implementation matches what you want.
Extreme, unrealistic case: you want to add something to a list of samples - one implementation does list.add(sample), the other inlines all the reference counting, object cloning, memory allocation and possible extension of list over 100 lines. How sure are you that either one of those implements what you want? Now reduce that to more realistic scenarios where C still forces you to either be more verbose or less explicit, while Rust (or any other more expressive language) lets you show exactly what's needed via better features or via types.
> Does it know anything about quantiles or student t distributions and will warn the agent if it implements them wrong?
No, we're not even close to that. But it lets you use stylo and implement `student(PositiveInteger v)`, which you can't achieve in C. So again - nothing can eliminate that gap today, but language features can definitely make it smaller.
Segmentation faults are super easy to get from AI agents writing C. If you want an agent vibecoding in a compiled language, you have to use Rust. That doesn't mean that the software does what is intended (that requires a review agent and then an orchestrator at minimum) but it makes things a lot easier.
There are MANY safer-than-C alternative languages compiled to efficient native code. I don't vibe code, but vibe coding seems popular with Nim, for example. I'm sure it's a very long list. "Safer-than-C" has been a slogan for PLangs for the entire history of modern computing. { Before people groan about "but, but mem.mgmt", that is often negligible overhead in context (depending on context and overhead). When it is not negligible, the same problems in Rust will usually have "allocations optimization" fiddling and such, so you don't really avoid "fighting memory". Ada people often just avoid dynamic allocation entirely. Java people will spot-optimize certain things. Ocaml, etc., etc. AMM is not even a property of a PLang as much as a runtime since even spartan C has -lgc with Boehm. }
I feel like Nim is too expressive to be a good vibe-coding target. That is one feature that I think is generally good for people writing code and really bad for agents.
You can take a lot more "smart" shortcuts in Nim, that are hard to reason about, and probably even harder when an automated system writes them.
It's not about memory safety per se. It's about not losing an hour of analysis because a malformed .sav file or a zero-variance sample triggered a segfault or silent wrong output.
SPSS crashes on bad data. Researchers work with messy data. Rust's Result type makes "handle every error explicitly" the default, not an afterthought. That's why I chose it.
Right, and that happens a lot I’m sure… not once have I had this when using SPSS. I mean good luck with that vibe fest but looking at your GH you seem to be throwing stuff at the wall, look AI ain’t going to rewrite SPSS for you in Rust and if it does you can count on it having a million bugs in it when it’s done, none corruption or segmentation faults but all of them just your version happily doing the wrong thing and corrupting results…
As the author of PSPP, I'm currently rewriting it in Rust myself.
The hard part is figuring out SPSS file formats. They are complex and IBM does not document them. I spent years figuring them out--and I am still working on the format for graphs and charts. Maybe they are trivial for claude, but I doubt it, because there aren't very many examples of the formats easily available. I've collected tens of thousands of examples myself for my use, but I don't have permission to share them, so instead I've documented what I've learned.
I would like to take the opportunity to thank you for your work. Having been taught to use SPSS about twenty years ago while a student (at LSE) I’ve basically been beholden to it ever since. PSPP allowed me to use my skills without paying the extortionate licenses while I learnt R.
I am doing python based pipelines, new pipelines were too slow, I must admit, the first that crossed my mind was to rewrite it in Rust:) But later after detailed analysis it was an architectural problem. You may not need Rust:)
GNU PSPP [0] is what got me into free software after losing access to SPSS in the middle of writing my undergrad capstone.
I’ve long since switched to python & other normal programming for any stats needs. And I only ever scraped the surface of SPSS/PSPP anyways. But, I’d be interested to hear what PSPP doesn’t cover.
I'm (well, my LLM is) Rewriting IBM SPSS Statistics in 100% Safe Rust, Alone (for a given value of alone).
You even let your LLM write the README.
Look, we nearly all use LLMs these days, but the phrasing of "I am... ...alone" is particularly weird when it's obviously not just you, it's you with LLMs.
Maybe title it as "A rewrite of IBM SPSS Statistics in Rust with no unsafe" - the 100% safe claim is something an LLM makes, it's not something a reasonable human would say, as it implies the Rust is totally safe, whereas you're trying to communicate that your Rust code uses no unsafe blocks, and these are two different things.
Why not let go of SPSS instead? It has run its course and is basically legacy legacy software by now. But it good fun I suppose? Are you using SPSS as an oracle? (Guessing that the author is/will be in the comments.)
An oracle and fuzzing have been excellent when reimplementing software. Given implausible inputs, the black box shows its colours quickly. Rounding errors and different representations of floats are and endless source of debugging, eh, joy.
This is one of the things that makes me negative on AI. Before AI, no one would have done this. Because it's a huge amount of effort and a total waste of time. Now we have AI, we have this explosion in people going off and doing all these pointless activities.
What do we gain from a plethora of SPSS-alike tools? Nothing. There's literally no explanation on this page about why anyone who uses SPSS would want to use this. But it's "100% Safe Rust". Yes, that's a feature that someone who likes rust wants, not what someone who uses SPSS wants.
What do we lose by fracturing all academic statistical analysis into a dozen different tools instead of 1? Lots!
It's not even clear the person creating this even intends for anyone to use it. So (a) why are they doing it and (b) how do you even know if it actually works if absolutely no one is using it. In fact the danger now is someone who doesn't know the author is just an AI slop dilletante comes along looking for an SPSS-like tool and makes the mistake of trying to use it.
Is there really any difference between this and the people posting AI slop onto their reddit accounts. It's just raising the noise floor to the point where we're going to have to essentially shut down the public internet, everything of value will move to closed spaces.
I'm extremely on the other side - it's not about what we gain, but what we don't lose. If there's even one person with a dataset they can't process easily without a proprietary tool, why shouldn't this exist?
I'm extremely happy every time a closed format falls. Whether it's this one, Sibelius music scores, records from medical devices, data series from scientific measurements, or something else. Every one of them stopped me from doing something in the past (not on a technical level but "it's not worth spending a month on this") and I'll support efforts like this.
If you want to advocate for open source alternative statistics software, sure, there are plenty of those - you can find half a dozen with a quick Google. None of them are prioritizing Rust Safeness, and they have a hell of a lot more support than "Here's something I vibe coded, I can't actually program so if you have a problem don't ask me"
But regardless, I know about projects like that. And I've been using Octave instead of MATLAB during my uni years. But I suspect the situation is similar here - not all the time, but sometimes you just need something to work precisely like MATLAB.
Sorry, but this really comes across as demonstrating a substantial degree of entitlement. What is the purpose? Easy. A student is trained to use SPSS for their thesis work. They may be given a sitewise license from their university, but only for one device. Then after their training, they lose access to SPSS, but want to do that analysis in their workplace.
Proprietary software, especially at these prices, cause all kinds of issues. SPSS is one of the software packages that has a sizeable audience of people crying out for a true open source alternative. Just because you have the money to afford these things, does not mean that others do.
Also, if you are referring to the similarly named ArtCraft suite as a "pointless activity" then you are really out of touch.
Sorry but the problem is not primarily software, it’s community, teaching and standardization.
We have R/tidyverse which does 90% of everything and has an amazing community and procedures eg. around documentation. For everything else you have excel or python. So I don’t see the use case.
There are tons of people in the social sciences that still, unfortunately, use SPSS to this day. If you think that R/tidyverse/Excel is a true alternative to SPSS, you definitely haven't interacted with any of these people.
Ah, are you a statistical consultant? That would explain a lot, but you should then know why these people need you. Or maybe you're in a department where the statistical standards are much higher than in mine.
The title "I'm...100% Safe Rust, Alone" is obnoxious.
Op, is there any technical merit to this, or is this a step in some process to earn brownie points in some pathetic "I'm a morally superior hero club?"
What'd you expect the rest of us to feel? Chastened?
Thanks everyone for the lively discussion, and huge thanks to the folks who emailed mods and vouched to clear the automated filter flag on my new account!
A few common points raised across the thread that I’d like to address in one place:
1. On "Alone", AI, and the Craft Anything methodology:
Some folks dug into the repo, found the rules and chronicles, and pointed out this is heavily AI-assisted. They are 100% right — and I don't hide it (there is an open public dev chronicle in docs/ detailing every single step). By "alone" I meant no venture backing, no university grant, and no human engineering team.
However, this isn't chaotic one-shot prompting. StatCraft is built as part of the ArtCraft suite, following the philosophy and methodology of Craft Anything (https://github.com/storytold/craft-anything - "understand how any software works, and craft your own"): using evidence-backed, clean-room investigation to replace closed, predatory software with open, reliable tools. We pair an orchestrator with specialized AI agents, constrained by strict compiler invariants and external mathematical oracles. That's also why StatCraft has a native Model Context Protocol (MCP) server: the software itself is designed to live natively in an agent-first world where researchers can interact with deterministic tools via natural language.
2. On "100% Safe Rust" terminology:
Fair critique from the Rust community on the phrasing: what I technically meant is #![forbid(unsafe_code)] across the workspace, zero unsafe blocks, and a zero-panic invariant (Result<T, E> everywhere, zero unwrap/expect in non-test code). The compiler ensures memory safety invariants, while domain correctness is enforced via fuzzing and mathematical oracle tests.
3. On Clean-Room & Legal concerns:
No IBM binaries were reverse-engineered or decompiled. The .sav and .zsav codecs follow open specifications established by GNU PSPP and the MIT-licensed ReadStat library. The statistical procedures are implemented strictly from academic literature and public formula specifications (such as the SPSS 24 Algorithms Guide), validated against SciPy with <= 1e-6 precision.
4. "Why not just use R/Tidyverse?":
R and Python are wonderful for coders. But thousands of students, sociologists, psychologists, and clinicians are trained purely on SPSS's GUI. When their university license expires, they face a $1000+/year paywall from IBM and have legacy .sav files they can't easily open without proprietary software. StatCraft is built for them: a free, native GUI tool that respects their muscle memory, works offline, and never crashes on messy survey data.
If you have old, weird, or corrupted .sav files, or want to audit a statistical procedure against your own SPSS outputs, issues and PRs are very welcome on GitHub.
(Of course it's fine to use AI tools! We use them heavily ourselves. Just please don't use them to generate or edit text to be read by fellow humans on Hacker News.)
It's impossible to know for sure what was LLM generated or edited, but we have to rely on imperfect classifiers or else the site would be completely flooded by genai text, which is not what the community here wants to read, nor in the intended spirit of HN.
Thanks for the explanation! Actually, I don’t speak English at all, so I have to use a translator to read this thread and reply to people here. I didn’t realize that using a translator could make my posts look like AI-generated spam. From now on, I will use a simple, literal Google Translate without any editing of the text.
I'm building StatCraft — an open-source statistical analysis package in 100% Safe Rust,
as a clean-room alternative to IBM SPSS Statistics.
I started this because I believe statistical software should not crash on malformed data,
should be scriptable by AI agents via MCP, and should not cost thousands of dollars per year.
Current state (11 days in, solo):
- 14 statistical blocks audited against SPSS 24 Algorithms Guide with ≤1e-6 SciPy precision
- Full .sav/.zsav codec, Excel/CSV import, SPSS syntax parser (.sps)
GNU Octave is like Matlab. Matplotlib is like Matlab but doesn't support the same syntax.
Will it have a DataFrame API?
Before R data.frame and Pandas DataFrame and substrait.dataframe, there were labeled arrays in NumPy.
Pint uses numpy ufuncs to type numbers with physical units.
Here are the notes I had for pgrust a few months ago: https://news.ycombinator.com/item?id=49112449 ; Polars (already has tested SIMD and GPU-optimized routines), substrait interface, and file formats: LanceDB, Vortex, Arrow recordbatch
Here are my notes for the ArtCraft folks about methods for Rust ports (and whether it's necessary to also port Blender to Rust with an O3/Maturin Python API) https://github.com/storytold/artcraft/issues/2489 :
> port the tests [and check figures] first; use branch coverage metrics when testing; use cargo-llvm-cov and rust-nightly to test; make (.sh,) scripts that the .github/workflows/ call so that local builds are easy; run local builds using nektos/act; use rstest to keep tests and test fixtures maintainable; use cargo-insta to snapshot; use cargo-fuzz, and do coverage-guided fuzzing; use TLA+, Lean or similar formal methods and tools to model the critical parts of the app at least
In the ArtCraft issues, there are so many great ideas that any or many or all firms could benefit from.