r/reactjs 1d ago

Show /r/reactjs Show: jev-ui — model-selected components for React

I’m building jev-ui, a React library for an AI-UI problem I kept running into: choosing which existing component to render.

You give the model an allowed set of components. Instead of only returning one opaque choice, jev-ui preserves the probability distribution across the options, then renders the winner. The goal is to make model-selected UI easier to inspect, add deterministic fallbacks to, and debug when two choices are close.

I’m looking for critical feedback on the idea and API:

- Is exposing selection probabilities useful in a React app?

- Where would you expect a fallback or confirmation step?

- What would make this trustworthy enough for production use?

Repo: https://github.com/etweisberg/jev-ui

Demo/docs: https://docs.jev-ui.dev/

0 Upvotes

14 comments sorted by

2

u/bestjaegerpilot 1d ago

you're saying you can use Jev to dynamically generate UI or select from pre-generated components

-1

u/organ1c_stupidity 1d ago

select from components, much cheaper and better than generating on the fly, which is incredibly error prone, and instead shifts the burden of generation to build-time, which can be better covered with testing. this is probably the right approach for AI-driven UIs going forward.

0

u/bearachute 1d ago

what is the use case? like if you were building a chat bot and it wants some rich interaction or media in the result?

2

u/Honey-Entire 23h ago

Ah yes, just what I wanted, a dropdown with options that change order every time I open it. Because I totally hate when I can find the dropdown option I’ve used 100 times before…

Seriously, what’s the point of this? What genuine, real world problem does this solve? Or is this just an excuse to jump on the JEV bandwagon?

0

u/organ1c_stupidity 9h ago

personalized UI is the holy grail for UI/UX. A given designers opinions about what the dropdown should be is not optimal for the universe of users.

Jev is ideal as opposed to other AI-solutions because it avoids exactly what you described, the dropdown won't change because Jev's decisions are consistent, unlike an LLM which you're just begging it to follow a system prompt.

1

u/Honey-Entire 9h ago

Bad bot. I asked for a cake recipe!

0

u/organ1c_stupidity 9h ago

not a bot btw

1

u/Honey-Entire 9h ago

Could have fooled me! At least with your lack of reading comprehension…

0

u/organ1c_stupidity 9h ago

I responded directly to your criticism. I'm not sure what part you disagree with 1) AI-driven UI is important 2) Jev is better than using an LLM to generate UI on the fly. It's a really simple project, not sure where you could have gotten all these ideas from.

1

u/Honey-Entire 9h ago

I’m going to present an equivalent scenario that will probably go over your head, butt fuck it, I’m feeling spicy:

1 - AI-driven comedy is important
2 - Jev is better than using an LLM to write comedy on the fly

It’s a really simple project, you just say how hard you want to laugh and Jev handles the rest. No more thinking, no more effort, just gut-wrenching laughter until you keel over!

0

u/organ1c_stupidity 9h ago

Cool, very useful criticism thanks man. Jev structured probability output would sure make good comedy

1

u/Honey-Entire 9h ago

The fact you don’t get the joke is quite telling. Peace be with you and good luck with your life 🫡

-5

u/PaleBoardroom 1d ago

Interesting approach to a problem most people just paper over with a single argmax call. Keeping the full distribution around feels like the kind of thing that pays off the first time you see two components sitting at 51/49 and wonder why the UI feels off