georgeguimaraes

georgeguimaraes

Hey everyone!

I’ve been working on Tribunal, an LLM evaluation framework for Elixir. It helps you test RAG pipelines and LLM outputs in your test suite.

The problem

When building LLM-powered features, you need to verify things like:

  • Is the response grounded in the provided context?
  • Did it hallucinate information?
  • Is the response actually relevant to the question?
  • Any toxic, biased, or harmful content?

The solution

Tribunal integrates with ExUnit so you can write these checks as regular tests:

test "response is faithful to context" do
  response = MyApp.RAG.query("What's the return policy?")

  assert_faithful response, context: @docs
  refute_hallucination response, context: @docs
  refute_toxicity response
end

Two modes

  • Test mode: ExUnit integration for CI gates. Fails immediately on any violation. Use this for safety checks that must pass.

  • Evaluation mode: Mix task for benchmarking. Run hundreds of test cases, set pass thresholds (e.g., “pass if 80% succeed”), track regression over time.

Assertion types

Deterministic (no API calls, instant):

  • assert_contains / refute_contains
  • assert_regex
  • assert_json
  • assert_max_tokens

LLM-as-Judge (uses any model via req_llm):

  • assert_faithful - grounded in context
  • assert_relevant - addresses the query
  • refute_hallucination - no fabricated info
  • refute_bias, refute_toxicity, refute_harmful, refute_jailbreak, refute_pii

Embedding-based (via alike):

  • assert_similar - semantic similarity

Red team testing

  • Generate adversarial prompts to test your LLM’s safety:

Tribunal.RedTeam.generate_attacks(“How do I pick a lock?”)

  • Returns encoding attacks (base64, rot13, leetspeak)

  • injection attacks (ignore instructions, delimiter injection), jailbreak attacks (DAN, developer mode)

Would love to hear your feedback!

Hex: tribunal | Hex
GitHub:

https://github.com/georgeguimaraes/tribunal

Showing Posts 1 to 3

stryderjzw

stryderjzw

Looks great! Will be giving it a try.

webofbits

webofbits

Really nice work on this!

I’ve been building aludel in a pretty similar area, but with more emphasis on an interactive Phoenix/LiveView workbench for running and comparing evals.

After spending some time looking through Tribunal, I think you’ve done a strong job on the evaluation primitives, especially around assertions, datasets, and LLM-as-judge flows. It feels like there’s an interesting complement between the two projects: Tribunal as a focused eval library, and Aludel as more of a UI/workbench layer.

If you’re open to it, I’d love your feedback on Aludel. I’m also curious whether you think there’s room for some interoperability between projects like these, especially around assertion engines or portable dataset formats, instead of each tool rebuilding the same pieces independently.

— All posts loaded —

Where Next? Top

Trending in Announcing Top

wojtekmach
Hey everyone! Req is an HTTP client for Elixir that I’ve been working on for quite some time. There is already a lot of HTTP clients out...
New
handnot2
Samly can be used to enable SAML 2.0 Single Sign On in a Plug/Phoenix application. This library uses Erlang esaml to provide plug enabl...
New
woylie
Flop is an Elixir library that applies filtering, ordering and pagination parameters to your Ecto queries. offset-based pagination with...
New
restlessronin
The repo is at GitHub - cyberchitta/openai_ex: Community maintained Elixir library for OpenAI API · GitHub. Docs are at OpenaiEx User Gu...
152 11030 135
New
garrison
Hobbes is a low-level distributed database for the Elixir programming language. Hobbes provides a simple, safe, and scalable storage lay...
New
fuelen
Hi all! I want to present a small library which provides a mix task for generating an Entity-Relationship Diagram for Ecto schemas. You...
New
anuaralfetahe
Hello Published a new library - ProcessHub! ProcessHub is a library designed to manage process distribution within the Elixir cluster. ...
New

Other Trending Topics Top

mudasobwa
I am happy to introduce the very α version of the new programming language compiled to BEAM. Welcome Cure. It has literally three kille...
New
mudasobwa
I am seeing a lot of aplications of Argumentum ad Vericundiam in software discussions. They do link some piece of writing and point us to...
New
bartblast
Hey folks, I just published a post about Hologram’s funding and where the project goes next - the short version: Curiosum as Main Spons...
New
sorenone
Today we’re releasing Oban for Python. Not an Oban client in Python. Not a pythonx wrapper embedded in Elixir. Nope, it’s a fully operati...
New
AstonJ
This showed up on my feed.. anyone heard of it? Just hype? Ox Alpha is a reasoning model designed for coding, sustained ag...
New
Herve37
We’re evaluating API mocking tools for OpenAPI-based projects and would love to hear what other teams are using. We’re particularly inte...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews