frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Show HN: Conduit: One Swift interface for every AI provider, on-device and cloud

https://github.com/christopherkarani/Conduit
1•ckarani•1h ago
I built Conduit because I was tired of writing the same streaming boilerplate five times for five different AI providers, then rewriting it every time a new one became interesting. So I stopped. The core idea: one protocol hierarchy, every provider. Switch from Claude to a local Llama model running on Apple Silicon with a one-line change. No vendor lock-in at the call site.

The interesting decision was going actor-first from day one. Every provider is a Swift actor. You get data-race freedom enforced at compile time, not by convention. Swift 6.2's strict concurrency makes this a hard guarantee, not a README promise. LangChain can't say that.

The part I'm most proud of — @Generable

@Generable struct FlightSearch { @Guide(description: "Origin airport code") let origin: String

    @Guide(description: "Departure date", .format(.date))
    let date: Date
    
    @Guide(.range(1...9))
    let passengers: Int
}

let result = try await provider.generate( "Book me a flight to Tokyo next Friday", model: .claude3_5Sonnet, returning: FlightSearch.self )

The macro expands at compile time (via swift-syntax) to generate JSON Schema, streaming partial types, and all conversion boilerplate. The API is deliberately aligned with Apple's new Foundation Models framework — so the same struct works against on-device Apple models on iOS 26 and against Claude or GPT-4 with zero changes.

On-device is a first-class citizen, not an afterthought Most Swift AI SDKs treat cloud as the primary path and shim local models in awkwardly. Conduit treats MLX, llama.cpp, Core ML, and Apple's Foundation Models as fully equal providers. A ChatSession configured with an MLX Llama model and one configured with GPT-4o are indistinguishable at the call site.

Trait-based compilation keeps binary size sane

AsyncThrowingStream all the way down. Cancellation works via standard Swift task cancellation — no special teardown protocol. Back-pressure is handled naturally by the async iterator.

12 providers, one interface Anthropic, OpenAI, Azure OpenAI, Ollama, OpenRouter, Kimi, MiniMax, HuggingFace Hub, MLX, llama.cpp, Core ML, Foundation Models. The OpenAI-compatible ones share a single OpenAIProvider actor — the named variants are thin configuration wrappers, not code forks.

https://github.com/christopherkarani/Conduit Happy to dig into the actor model approach, the macro expansion strategy, or why wrapping LangChain was never an option.

Multi-Language MCP Server Performance Benchmark

https://www.tmdevlab.com/mcp-server-performance-benchmark.html
1•oshanz•35s ago•1 comments

Stop building generic AI chatbots: 45% of support leaders are ahead

https://ideatolaunch.co/blog/why-the-world-doesn-t-need-another-generic-ai-chatbot-and-how-to-bui...
1•DonAj•2m ago•0 comments

A Local-Algebraic Route to Emergent Gravity (100 Pages)

1•berndtzl•6m ago•1 comments

Cultivating Praxia

https://tasshin.com/blog/cultivating-praxia/
1•tasshin•9m ago•0 comments

Managing Docker Composes via GitOps

1•anuragxd•11m ago•0 comments

An update on upki

https://discourse.ubuntu.com/t/an-update-on-upki/77063
3•pabs3•17m ago•0 comments

Google trying to recover footage from other Guthrie home cameras

https://www.youtube.com/watch?v=658FsUNHZ0Q
1•busymom0•24m ago•1 comments

Way to Understand the Irish Economy

https://stephenkinsella.substack.com/p/the-best-way-to-understand-the-irish
1•paulpauper•27m ago•0 comments

Mature Cultural Desire

https://www.overcomingbias.com/p/mature-cultural-desire
1•paulpauper•28m ago•0 comments

Technology has changed the world in my lifetime

https://www.noahpinion.blog/p/how-technology-has-already-changed
1•paulpauper•28m ago•0 comments

Evolution of Computers [video]

https://www.youtube.com/watch?v=aa6YISbAJEA
1•measurablefunc•29m ago•0 comments

OpenClaw Partners with VirusTotal for Skill Security

https://openclaw.ai/blog/virustotal-partnership
1•thanthtet•29m ago•0 comments

Show HN: AI pentester – verified exploits, $999/assessment

1•gauravbsinghal•30m ago•2 comments

PEP 814 – Add frozendict built-in type

https://peps.python.org/pep-0814/
2•azhenley•32m ago•0 comments

Show HN: Rot – Financial Intelligence MCP Server

https://web-production-71423.up.railway.app/mcp-server
2•Shmungus•32m ago•0 comments

Unauthorized Immigration Effects on Local Labor Markets

https://www.frbsf.org/research-and-insights/publications/economic-letter/2026/02/unauthorized-imm...
4•johntfella•34m ago•1 comments

ChatGPT promised to help her find her soulmate. Then it betrayed her

https://www.npr.org/2026/02/14/nx-s1-5711441/ai-chatgpt-openai-love-betrayal-delusion-chatbot
1•andsoitis•34m ago•0 comments

A fluid can store solar energy and then release it as heat months later

https://arstechnica.com/science/2026/02/dna-inspired-molecule-breaks-records-for-storing-solar-heat/
3•apparent•34m ago•1 comments

GLM-5 Technical Report

https://arxiv.org/abs/2602.15763
1•meetpateltech•37m ago•0 comments

Learning Low-Level Computing and C++ by Making a Game Boy Emulator

https://byteofmelon.com/blog/2026/making-of-gamebyte
2•PaulHoule•40m ago•0 comments

I Built a Roguelike RPG Card Game with Compose Multiplatform

https://medium.com/@cliffrob25/how-i-built-a-roguelike-rpg-with-compose-multiplatform-and-skipped...
1•farmerbb•41m ago•0 comments

Show HN: I built yawdl a tiny language that compiles in the browser

https://chersbobers.github.io/posts/yawdl
1•chersbobers•42m ago•0 comments

"Vendoring" is a vile anti-pattern (2014)

https://gist.github.com/datagrok/8577287
1•todsacerdoti•42m ago•1 comments

BGP in 2025 – Geoff Huston [video]

https://www.youtube.com/watch?v=Sm1HjdmoeeA
1•Unearned5161•44m ago•0 comments

Peter Thiel knows about the AntiChrist

1•zerosizedweasle•47m ago•2 comments

Charting market dynamics in India's underground ticket resale WhatsApp groups

https://aftereod.substack.com/p/stress-fractures-indias-concert-boom
1•huwsername•48m ago•0 comments

Claimcheck: Narrowing the Gap Between Proof and Intent

https://midspiral.com/blog/claimcheck-narrowing-the-gap-between-proof-and-intent/
3•todsacerdoti•50m ago•0 comments

Show HN: Instrumental Model from Scratch (With Demo)

https://instr.io/?view=model
1•day6•52m ago•0 comments

Tell HN: Ramadan Mubarak

10•Sayyidalijufri•55m ago•4 comments

Personal Agents with David Singleton and Hugo Barra [video]

https://www.youtube.com/watch?v=1tK_x_vxGWs
1•jairojair•55m ago•0 comments