┌─The default CLI for PentaCMD-47M─┐
PentashellPentashell

One instruction. One command.
Your approval.

Pentashell turns plain English into a terminal command — it suggests one, shows it clearly, and runs it only when you say so. Fully local, no GPU, powered by a 47M-parameter model built from scratch.

Get running in under a minute

Quickstart
$ git clone https://github.com/Sumandebnath943/pentashell-cli
$ cd pentashell-cli && pip install -r requirements.txt
$ pip install -e .
$ pentacmd "undo my last commit"
The Pentashell REPL — families, modes, the safety gate, and a sample session, on the neon command-line interface

The real interface — no mockup. Pentashell v0.2.0, powered by PentaCMD-47M.

One instructionOne commandYour approvalFully localNo GPU47M parametersFive familiesDefault · NoNames the risk~86.7% exact-matchBuilt from scratchOne instructionOne commandYour approvalFully localNo GPU47M parametersFive familiesDefault · NoNames the risk~86.7% exact-matchBuilt from scratch
[ 01 ]// live · verified examples only

Watch it think.

Type what you want. Pentashell names the family it detected, suggests one command, then stops at the approval gate. Every pair below is a real example run locally on CPU.

pentacmd — interactive session

pentacmd> 

[ 02 ]// one shared path

How it thinks.

Every instruction travels the same six steps — and the single most important detail is the prompt format with no trailing space after the command marker (a trailing space made the model drop the first word).

01

Plain English

"undo my last commit"

02

Decide family

flag wins · else auto-detect

03

Exact prompt

### Task · ### Command

04

PentaCMD-47M

greedy decode · stop token

05

Extract command

git revert HEAD

06

Approval gate

[y/N] · then run

One implementation. The interactive loop and pentacmd "…" share the exact same path.

// the most important part

Nothing runs without your yes.

A model that can be wrong must never run a command you didn’t approve — and must be extra careful with anything destructive. Two gates enforce it.

Normal command

$ git switch -c payments

Run this? [y/N]

  • Default is No. Empty input = No.
  • Runs only on an explicit y / yes.
⚠ Destructive command

$ git reset --hard HEAD~3

Warning — names the risk

This permanently discards commits and changes.

Type yes to proceed

A bare y is rejected — a single keystroke can never trigger it by accident.

0 / 10

dangerous commands caught

in the detector's unit tests

0 / 7

false positives in tests

safe commands never flagged

0

command families covered

bash · git · npm · python · powershell

Safe commands like npm install, git add and Format-Table are correctly never flagged.

[ 04 ]// transparent auto-detection

Five families, one guess you can trust.

g

git

--git

Version control — the strongest family (100% exact-match in training).

High-signal keywords

commitbranchmergerebasestashremote
pentacmd · git

pentacmd> create a branch called payments and switch to it

detected · git

git switch -c payments

The decision is always shown — and an explicit flag is a guaranteed override. No keyword match falls back to bash, and says so.

[ 05 ]// the engine inside

The model under the hood.

Pentashell is the tool. PentaCMD-47M is the model it wraps — a decoder-only transformer trained from scratch on a 16 GB-RAM, no-GPU laptop. The weights travel with the package, so the CLI stays self-contained.

Meet PentaCMD-47M, the SLM

Parameters

47.2M

47,233,280

Architecture

Decoder-only

nanoGPT-style transformer

Layers · Heads · Width

8 · 10 · 640

weight-tied embeddings

Context length

256

tokens

Vocabulary

12,000

byte-level BPE

Validation exact-match

~86.7%

100% on git

[ 06 ]// six tested increments

How it was built — and what each step taught.

Deliberately built in small, individually-tested steps. Each one earned its place — and a real lesson came out of every increment.

01

Core inference wrapper

Load the model once, format the exact trained prompt, greedy-decode, print the command.

Lesson · Preserve the prompt format with no trailing space after “### Command:” — a trailing space made the model drop the first word of every command.

02

Callable from anywhere

Turn the script into an installable package with a pentacmd entry point on PATH.

Lesson · Let the usage decide the architecture — because users install it, the weights have to travel with the package.

03

Family handling

Explicit flags plus transparent keyword auto-detection, with the choice always shown.

Lesson · Match whole words and weight phrases — “tar” was matching inside “start”, and a generic word beat a specific phrase.

04

Approval & execution

Run this? [y/N], default No. Destructive commands get a stronger, risk-naming gate.

Lesson · Safety is logic to be verified, not a vibe — unit-tested for both catches and false positives.

05

Interactive UI polish

rich colour, a typing-reveal animation, and a REPL loop with the model kept warm between turns.

Lesson · Small platform details bite — plain print mangled an em-dash on the Windows console; rich fixed the encoding for free.

06

Documentation & packaging

A portfolio-ready README, MIT licence, project bible, and this report.

Lesson · Separate human output from machine output — notes go to stderr, the bare command to stdout, so piping stays clean.

[ 07 ]// kept visible on purpose

Honest by design.

No overselling. These limits shape correct use — and they are exactly why the approval gate exists in the first place.

!

It can be confidently wrong

A 47M model can return a plausible-but-incorrect command. That is exactly why the approval step exists — read every command before approving.

!

Auto-detection is deliberately simple

Keyword matching, not magic. Ambiguous phrasing can fall to the default bash family — a flag or family: prefix steers it.

!

Execution is Windows-first

Commands run through PowerShell on Windows. The macOS/Linux bash path is implemented but untested on the build machine.

!

It is not an agent

One instruction → one command → approve → run. No multi-step planning, no chaining, no acting on output. That is by design.

[ 08 ]// python ≥ 3.9 · local · no GPU

Use it.

Clone, install the editable package, and the pentacmd command works from any terminal, in any folder.

Install
# weights ship with the repo via Git LFS
$ git clone https://github.com/Sumandebnath943/pentashell-cli
$ cd pentashell-cli
$ pip install -r requirements.txt
$ pip install -e .
Run it
# interactive — model loads once, then instant
$ pentacmd
# one-shot — family auto-detected
$ pentacmd "make a virtual environment with venv"
→ python -m venv venv
# print only, never run
$ pentacmd -n "install the requests package with pip"

Command reference

  • pentacmdinteractive loop — model loads once, then instant
  • pentacmd "…"one-shot — family auto-detected
  • pentacmd --git "…"force a family (bash · git · npm · python · powershell)
  • pentacmd -n "…"print the command only — never runs
  • family: …inside the loop, prefix to force a family

Prefer not to clone the 180 MB weights? They’re also published as a separate release asset / Hugging Face download — point the CLI at them and skip the LFS pull. Built on torch (CPU), tokenizers and rich.

PyTorch (CPU)

Runs the 47M model — no GPU required

tokenizers

Byte-level BPE encode / decode

rich

Colour, panels, typing reveal, UTF-8 on Windows

argparse

Flags, family overrides, one-shot vs interactive

Python 3.9+

Built on 3.12.7, per-user install

PowerShell / bash

The execution shell, streamed live

open source · MIT · built from scratch

One instruction. One command.
Your approval.

Clone the repo, install with pip, and ask in plain English. Read every command before you approve — that’s the whole point.

Pentashell · the default CLI for PentaCMD-47M · MIT · built from scratch by Suman Debnath