DEV Community

Good AI Labs for Good AI Labs

Posted on Originally published at goodailabs.com

Introducing Reflex-1

One pass, many possible decisions

Reflex-1 is a 421M-parameter model for decisions that end in a choice. Give it a textual state, a question, and candidate answers; it scores them in a single forward pass. Candidates can change with every request.

A 28-layer context encoder and a six-layer candidate encoder feed a shared scoring head. The application supplies the choices and executes the result.

Try Reflex-1

Public weights, tokenizers, and inference code are available on Hugging Face. With the dependencies installed:

import torch
from transformers import AutoModel

torch.set_num_threads(1)
model = AutoModel.from_pretrained("gai-labs/reflex-1", trust_remote_code=True)

decision = model.predict(
    state="The customer was charged twice for one card payment.",
    question="Choose the matching issue.",
    options=["duplicate charge", "lost card", "unknown fee", "cash withdrawal"],
)[0]
print(decision.choice)
Enter fullscreen mode Exit fullscreen mode

Top comments (0)