<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/oOUdbVdRj" -->

---
title: 300ms Safety: How TypeSafe Jev Replaces Slow Shell LLMs
description: YOLO-Shell is an open-source Rust CLI safety tool that guards against destructive shell commands using TypeSafe Jev, a 'System One model' that returns strictly...
canonical: https://daily.dev/posts/300ms-safety-how-typesafe-jev-replaces-slow-shell-llms-ooudbvdrj
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: 300ms Safety: How TypeSafe Jev Replaces Slow Shell LLMs | daily.dev
og:description: YOLO-Shell is an open-source Rust CLI safety tool that guards against destructive shell commands using TypeSafe Jev, a 'System One model' that returns strictly...
og:url: https://daily.dev/posts/300ms-safety-how-typesafe-jev-replaces-slow-shell-llms-ooudbvdrj
og:image: https://api.daily.dev/og/posts/oOUdbVdRj.png
og:image:alt: 300ms Safety: How TypeSafe Jev Replaces Slow Shell LLMs
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# 300ms Safety: How TypeSafe Jev Replaces Slow Shell LLMs

**[Rizwanul Islam Rudra](https://daily.dev/sources/xbq-thbbo)** · [@rizwanul](https://daily.dev/rizwanul) · 3 min read · 2 upvotes · 0 comments

## Summary

YOLO-Shell is an open-source Rust CLI safety tool that guards against destructive shell commands using TypeSafe Jev, a 'System One model' that returns strictly typed answers (isdestructive, riskscore, action) instead of generating prose like a typical LLM. This structured approach delivers ~310ms warm latency (~800ms cold) versus multi-second LLM responses, while still reading context like git branch, working directory, and environment variables to make decisions regex can't (e.g., blocking force-push on main, blocking rails db:drop in production). A deterministic rule engine runs alongside Jev as an offline fallback and hard safety floor that the model cannot override for critical commands. The project is MIT licensed on GitHub.

## Content

If you've ever thought about using a Generative AI tool as a terminal guardrail to prevent catastrophic command mistakes, you've probably hit two massive brick walls:

1. **Latency:** Waiting 2–3 seconds before _every single command_ will make you uninstall it before lunch.
2. **Unstructured Output:** Standard LLMs reply with prose. Before your shell can act, it has to parse natural language or messy text into a programmatic decision.

Regex rules are too dumb to understand context, and generative LLMs are far too slow. **YOLO-Shell** takes a different approach using [**TypeSafe Jev**](https://typesafe.ai/blog/introducing-system-one-models-and-jev) - a System One model pattern designed specifically for structured CLI evaluation.

## How It Works: Typed State vs. Text Generation

Instead of prompting a model to "think and respond in text," a System One model evaluates state and returns **strictly typed answers** without a traditional generation step.

When you trigger a command, `yolo-shell` sends a single payload (`POST /v1/systemone`) asking three named questions:

- `isdestructive`_ _(bool)_ - Probability of yes, thresholded at `0.5`
- `riskscore`_ _(score)_ - Position on a 10-level rubric you define
- `action` _(choice)_ - `allowimmediately`_ | _`warnandconfirm`_ | _`blockcompletely`

### Context Awareness Where Regex Fails

The input `state` payload carries the command (with secrets automatically scrubbed), current working directory, git branch, and active environment variables (`AWSPROFILE`_, _`KUBECONTEXT`, `NODE_ENV`).

This context enables dynamic evaluation that static regex patterns simply can't handle:

- `git push --force` -> Triggers a warning prompt on a feature branch, but **hard blocks** on `main`.
- `rails db:drop` -> Allowed in dev, but **completely blocked** when `NODE_ENV=production`.

## Plain English as Your Policy Config

Because evaluation runs against a rubric, tuning security policies means tweaking plain English sentences.

Adding the phrase:

> _"...or rewrites history on a protected branch such as main"_

to a rubric level shifted `git push --force` on `main` from a standard warning prompt (`y/N`) to an immediate hard block - without touching behavior on feature branches.

## Speed & a Deterministic Safety Net

A terminal tool is useless if it hangs your workflow. YOLO-Shell is optimized for fast feedback:

- **Latency:** ~310ms on a warm connection (~800ms cold)
- **Architecture:** Written in **Rust** as a single binary
- **Shell Support:** `zsh`, `bash`, and `fish`

### The Deterministic Floor

Jev doesn't operate in a vacuum. A **deterministic rule engine** runs alongside it:

1. **Offline Fallback:** Evaluates commands instantly if the network drops.
2. **Hard Floor:** Jev can relax rules in lower-risk bands, for example, correctly identifying `rm -rf ./build` as safe, which regex tables often falsely flag - but **it cannot override severe rules**. If the deterministic engine marks a command as critical, no model can override the block.

The project is completely open source under the MIT license:

🔗 **GitHub:** [github.com/riz007/yolo-shell](https://github.com/riz007/yolo-shell)

_What are your thoughts on using lightweight, structured models over heavy LLMs or local rule engines for shell tools? Let's discuss below!_

## Similar posts on daily.dev

- [Jev Doesn't Write Text. It Returns Probabilities.](https://daily.dev/posts/jev-doesn-t-write-text-it-returns-probabilities--3tcrb0ghc) · DEV · 7 upvotes · 0 comments
- [What is Jev? How System One models could change AI agents : fireup.pro](https://daily.dev/posts/what-is-jev-how-system-one-models-could-change-ai-agents-fireup-pro-eqcqub8on) · FireUp · 1 upvotes · 0 comments
- [Laya : Bye Bye TypeScript Jev AI](https://daily.dev/posts/laya-bye-bye-typescript-jev-ai-y5lhaizau) · Medium · 0 upvotes · 0 comments

---

Tags: [#llm](https://daily.dev/tags/llm), [#rust](https://daily.dev/tags/rust), [#cli](https://daily.dev/tags/cli), [#appsec](https://daily.dev/tags/appsec)

[View this post on daily.dev](https://daily.dev/posts/300ms-safety-how-typesafe-jev-replaces-slow-shell-llms-ooudbvdrj)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"DiscussionForumPosting","mainEntityOfPage":"https://daily.dev/posts/300ms-safety-how-typesafe-jev-replaces-slow-shell-llms-ooudbvdrj","headline":"300ms Safety: How TypeSafe Jev Replaces Slow Shell LLMs","text":"YOLO-Shell is an open-source Rust CLI safety tool that guards against destructive shell commands using TypeSafe Jev, a 'System One model' that returns strictly typed answers (isdestructive, riskscore, action) instead of generating prose like a typical LLM. This structured approach delivers ~310ms warm latency (~800ms cold) versus multi-second LLM responses, while still reading context like git branch, working directory, and environment variables to make decisions regex can't (e.g., blocking force-push on main, blocking rails db:drop in production). A deterministic rule engine runs alongside Jev as an offline fallback and hard safety floor that the model cannot override for critical commands. The project is MIT licensed on GitHub.","url":"https://daily.dev/posts/300ms-safety-how-typesafe-jev-replaces-slow-shell-llms-ooudbvdrj","datePublished":"2026-09-20T06:36:06.891Z","dateModified":"2026-09-20T06:36:32.502Z","author":{"@type":"Person","name":"Rizwanul Islam Rudra","url":"https://daily.dev/rizwanul","image":"https://media.daily.dev/image/upload/s--BaXM-_5z--/f_auto/v1734625319/avatars/avatar_xbQ-tHbbo","description":"Software Engineer","interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"EndorseAction"},"userInteractionCount":2680}},"image":"https://media.daily.dev/image/upload/s--CNB0-9BP--/f_auto/v1789886167/posts/oOUdbVdRj?_a=BAMAMicg0","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":2},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"isPartOf":{"@type":"WebPage","url":"https://daily.dev/sources/xbq-thbbo","name":"Rizwanul Islam Rudra"}}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Rizwanul Islam Rudra","item":"https://daily.dev/sources/xbq-thbbo"},{"@type":"ListItem","position":3,"name":"300ms Safety: How TypeSafe Jev Replaces Slow Shell LLMs"}]}
```

