mdepolli

mdepolli

Hi everyone!

I’ve just released Cite 0.1.0. It checks documents against rules you write, and every answer points to the exact passages it came from.

The problem

You have a document and rules for what to look for in it:

  • Which lines of this log are failures, and of what kind?
  • Where are the sponsor reads in this video’s captions?
  • Which allergens does this recipe contain?
  • Did the support agent verify the customer before the refund?

You want answers you can check against the text, not a model’s summary.

The solution

Declare what to look for in a Spark DSL, hand over the passages you already have, and Cite returns findings that cite those passages exactly as you gave them:

defmodule Riddles do
  use Cite.Policy

  concern :riddle do
    detect do
      question "Does {passage} pose a riddle?"
      yes "A question asked to be puzzled over, whether or not it has an answer."
      no "A plain question, a statement, or a remark."
    end
  end
end

source = Cite.source(["Why is a raven like a writing-desk?", "Take some more tea."])
Cite.judge(client, source, Riddles)
# one :riddle finding, citing "Why is a raven like a writing-desk?"

The model is Jev, TypeSafe’s decision model. It answers with a probability, a level or a choice, never with prose, so nothing is generated and nothing can be misquoted.

How it works

  • Two fixed rounds: a screen of every passage, then one judgment per finding with all of its passages in view.
  • Gathering is plain Elixir: fixed rules, no model calls between the rounds.
  • Verdicts: :holds, :review (a person decides) or :fails. A failed request never counts as a “no”.
  • Policy mistakes are compile errors.

Tutorials

Each policy was built on a real public dataset, tuned on one split, and checked on held-out data against a keyword baseline.

Notes

  • It needs a TypeSafe API key. Providers are a behaviour, so Cite isn’t tied to Jev. I’m not affiliated with TypeSafe.
  • By design, it asks nothing about the whole document and cites only passages you gave it.

I’d especially like to hear:

  • Whether the DSL reads well, and what you’d rename;
  • Which model provider you’d want next;
  • What you’d point it at.

Hex: cite | Hex
Docs: Cite v0.1.0 — Documentation

Where Next? Top

Trending in Announcing Top

restlessronin
The repo is at GitHub - cyberchitta/openai_ex: Community maintained Elixir library for OpenAI API · GitHub. Docs are at OpenaiEx User Gu...
152 12366 136
New
type1fool
WebAuthnLiveComponent WebAuthnComponents See this post about renaming the package. Passwordless authentication for Phoenix LiveView app...
New
GenericJam
Edit: 2026 May 15 - This post is archived. Mob is alive!! Main docs: mob v0.7.11 — Documentation A bit of explanation for the slightly c...
New
woylie
I released Doggo, a collection of unstyled Phoenix components. https://github.com/woylie/doggo Features Unstyled Phoenix components....
New
garrison
Hobbes is a low-level distributed database for the Elixir programming language. Hobbes provides a simple, safe, and scalable storage lay...
New
kip
I’ll shortly be launching Text, a nascent text analysis library. Current functionality In this early version (not ready for prime time) ...
New
kip
Following on from my CLDR lbraries I started work on Unicode transforms. But like everything related to CLDR there is a lot of yak-shavin...
New

Other Trending Topics Top

CodeSync
We have 4 in-person tickets to Code BEAM Europe 2026 (21-22 October, PHIL Haarlem) to give away: 1 diversity ticket (sponsored by AppSi...
New
gus
Happy Friday, all! :slight_smile: Our October meetup is coming up next week - Wednesday, October 14th at 19h CET via Zoom! This month we...
New
budgie
A little off-topic, but I feel like people here have a good head on their shoulders. I used to be quite good at making software. Was luc...
New
KristerV
Hey. Is there anyone here who creates agents in their apps? Not talking about using agents, but creating them. I’m finding it pretty diff...
New
juhalehtonen
There has been a thread to discuss the Stack Overflow Developer Survey on this forum every year since 2018, so here’s yet another one for...
New
budgie
I love Elixir. It’s one of 2 programming languages I’ve ever fallen in love with. But I don’t use it anymore. Serverless was the promis...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews