frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Incant – add magic spells to your code

https://github.com/montyanderson/incant
21•montyanderson•7mo ago

Comments

marcus_holmes•7mo ago
I'm curious how the hallucination-free guarantee works? Does it only guarantee that the output is a subset of the input?

In the case of the male names, if I include a gender-neutral name like "Sam" does that include it because it is a male name, or exclude it because it is a female name? Can I set this to be inclusive or exclusive?

Looks interesting, though. Nice work.

kinduff•7mo ago
There is a filter for `createFilter` [1] and there is a throw if the index of the array doesn't exist for `createSelector` [2]. Maybe this is what the author refers to as hallucination-free, but falls pretty short.

[1]: https://github.com/montyanderson/incant/blob/master/mod.ts#L...

[2]: https://github.com/montyanderson/incant/blob/master/mod.ts#L...

marcus_holmes•7mo ago
Yeah, so it's just guaranteeing that the output is a subset of the inputs, thanks for the clarification.
helloplanets•7mo ago
How does this differ from function calling? For example, the basic enums example for Gemini function calling:

> color_temp: { type: Type.STRING, enum: ['daylight', 'cool', 'warm'], description: 'Color temperature of the light fixture, which can be `daylight`, `cool` or `warm`.', }

https://ai.google.dev/gemini-api/docs/function-calling?examp...

supermatt•7mo ago
It’s the inverse of function calling. Here the function is calling the LLM, not vice versa.
supermatt•7mo ago
> no hallucinations possible

It can still hallucinate a response that is defined in the filter.

E.g if you have a filter with names of capital cities [“London”, “Paris”, “Madrid”] , and you ask “What is the capital of France” it could respond “Madrid”

ycombinatrix•7mo ago
Is that a hallucination, or is it just plain wrong?
supermatt•7mo ago
An AI hallucination is any response that contains false or misleading information presented as fact. So a wrong answer is an hallucination.
thih9•7mo ago
Note that this is a very simple library and not very efficient. E.g. for the code that filters an array, it would run N prompts[1]:

    `You are a filter agent.\nYour job is to return whether an item matches the criteria: ${criteria}\nRespond only with true or false.`
It's a cool demo, but I wouldn't use that in production; IMO having that code in a separate library offers little benefit and increases the risk of misuse.

[1]: https://github.com/montyanderson/incant/blob/73606e826d6e5b0...

voidUpdate•7mo ago
So this is just asking an LLM to filter or select from an array? Where do the magic spells come in?
jollyllama•7mo ago
vibecoding is a hell of a drug

Omarchy First Impressions

https://brianlovin.com/writing/omarchy-first-impressions-CEEstJk
1•tosh•1m ago•0 comments

Reinforcement Learning from Human Feedback

https://arxiv.org/abs/2504.12501
1•onurkanbkrc•2m ago•0 comments

Show HN: Versor – The "Unbending" Paradigm for Geometric Deep Learning

https://github.com/Concode0/Versor
1•concode0•2m ago•1 comments

Show HN: HypothesisHub – An open API where AI agents collaborate on medical res

https://medresearch-ai.org/hypotheses-hub/
1•panossk•5m ago•0 comments

Big Tech vs. OpenClaw

https://www.jakequist.com/thoughts/big-tech-vs-openclaw/
1•headalgorithm•8m ago•0 comments

Anofox Forecast

https://anofox.com/docs/forecast/
1•marklit•8m ago•0 comments

Ask HN: How do you figure out where data lives across 100 microservices?

1•doodledood•8m ago•0 comments

Motus: A Unified Latent Action World Model

https://arxiv.org/abs/2512.13030
1•mnming•8m ago•0 comments

Rotten Tomatoes Desperately Claims 'Impossible' Rating for 'Melania' Is Real

https://www.thedailybeast.com/obsessed/rotten-tomatoes-desperately-claims-impossible-rating-for-m...
2•juujian•10m ago•1 comments

The protein denitrosylase SCoR2 regulates lipogenesis and fat storage [pdf]

https://www.science.org/doi/10.1126/scisignal.adv0660
1•thunderbong•12m ago•0 comments

Los Alamos Primer

https://blog.szczepan.org/blog/los-alamos-primer/
1•alkyon•14m ago•0 comments

NewASM Virtual Machine

https://github.com/bracesoftware/newasm
1•DEntisT_•16m ago•0 comments

Terminal-Bench 2.0 Leaderboard

https://www.tbench.ai/leaderboard/terminal-bench/2.0
2•tosh•17m ago•0 comments

I vibe coded a BBS bank with a real working ledger

https://mini-ledger.exe.xyz/
1•simonvc•17m ago•1 comments

The Path to Mojo 1.0

https://www.modular.com/blog/the-path-to-mojo-1-0
1•tosh•20m ago•0 comments

Show HN: I'm 75, building an OSS Virtual Protest Protocol for digital activism

https://github.com/voice-of-japan/Virtual-Protest-Protocol/blob/main/README.md
4•sakanakana00•23m ago•0 comments

Show HN: I built Divvy to split restaurant bills from a photo

https://divvyai.app/
3•pieterdy•25m ago•0 comments

Hot Reloading in Rust? Subsecond and Dioxus to the Rescue

https://codethoughts.io/posts/2026-02-07-rust-hot-reloading/
3•Tehnix•26m ago•1 comments

Skim – vibe review your PRs

https://github.com/Haizzz/skim
2•haizzz•27m ago•1 comments

Show HN: Open-source AI assistant for interview reasoning

https://github.com/evinjohnn/natively-cluely-ai-assistant
4•Nive11•28m ago•6 comments

Tech Edge: A Living Playbook for America's Technology Long Game

https://csis-website-prod.s3.amazonaws.com/s3fs-public/2026-01/260120_EST_Tech_Edge_0.pdf?Version...
2•hunglee2•31m ago•0 comments

Golden Cross vs. Death Cross: Crypto Trading Guide

https://chartscout.io/golden-cross-vs-death-cross-crypto-trading-guide
3•chartscout•34m ago•0 comments

Hoot: Scheme on WebAssembly

https://www.spritely.institute/hoot/
3•AlexeyBrin•37m ago•0 comments

What the longevity experts don't tell you

https://machielreyneke.com/blog/longevity-lessons/
2•machielrey•38m ago•1 comments

Monzo wrongly denied refunds to fraud and scam victims

https://www.theguardian.com/money/2026/feb/07/monzo-natwest-hsbc-refunds-fraud-scam-fos-ombudsman
3•tablets•43m ago•1 comments

They were drawn to Korea with dreams of K-pop stardom – but then let down

https://www.bbc.com/news/articles/cvgnq9rwyqno
2•breve•45m ago•0 comments

Show HN: AI-Powered Merchant Intelligence

https://nodee.co
1•jjkirsch•47m ago•0 comments

Bash parallel tasks and error handling

https://github.com/themattrix/bash-concurrent
2•pastage•47m ago•0 comments

Let's compile Quake like it's 1997

https://fabiensanglard.net/compile_like_1997/index.html
2•billiob•48m ago•0 comments

Reverse Engineering Medium.com's Editor: How Copy, Paste, and Images Work

https://app.writtte.com/read/gP0H6W5
2•birdculture•54m ago•0 comments