A Bash command that answers questions about text
Pipe text in, read the answer out, and branch on the exit code.
Install
| Channel | Note |
|---|---|
curl -fsSL https://thinkthen.dev/install.sh | sh | Download script. |
brew install botassembly/thinkthen/thinkthen | Homebrew, an option on a Mac. |
Set THINKTHEN_API_KEY in the environment.
A first call
question="Does the customer ask for a refund?"
cat <<'EOF' |
I renewed once this morning, but my card shows two charges.
Please refund the duplicate.
EOF
thinkthen decide "$question"true
Not sure comes back as null, and exit code 3. Branch on it and send those cases to a person.
Run facts
--facts prints one line of run facts on standard error, after the answers.
Jev, Liquid d1 and Ollama from Bash
--backend NAME names the backend for one run. THINKTHEN_BACKEND names it for every run in the shell. Each backend page shows its runs.
- TypeSafe Jev:
--backend typesafe - Liquid d1:
--backend liquid - Ollama:
--backend ollama
The configuration file's backend names a default backend for every run. The Configuration page shows the file.
OpenAI Decisions API from Bash
OpenAI announced its Decisions API on 2026-09-29 in its DevDay 2026 recap. OpenAI has published no address, schema or price, so ThinkThen cannot call it. The OpenAI Decisions API page says what ThinkThen knows.
What is different in Bash
- Standard input carries the evidence. Standard output carries the answer and nothing else.
- On one piece of evidence, the exit code is the answer.
ifandcaseread it directly. --jobssets how many requests run at once.--planprints the plan and needs no key.
On GitHub: github.com/botassembly/thinkthen