Skip to main content

stackai

An interactive AI agent in your terminal — like Claude Code, for StackAI.

Installation

pip install stackai

This installs the stack command.

The interactive agent

Just run stack (or stack chat) to start an interactive session:

stack

On a real terminal this opens a full-screen app (scrolling transcript + anchored input, à la Claude Code). Piped/non-interactive input falls back to a line REPL automatically; force it with stack chat --classic.

You get a streaming chat loop with tool use — the agent can read files, list directories, and run shell commands (with your approval) to help answer your questions. Responses render as Markdown with syntax-highlighted code blocks; extended thinking is streamed inline.

› what does pyproject.toml configure?

stack ⚙ read_file pyproject.toml
      … reads the file, then explains it

Slash commands

Command Description
/help show available commands
/clear reset the conversation
/tools list the tools the agent can call
/backend <name> switch backend (anthropic | stackai)
/exit, /quit leave

Backends

The agent is backend-pluggable. Default is Anthropic (Claude); you can also point it at a deployed StackAI workflow.

Anthropic (default) — set a key and go:

export ANTHROPIC_API_KEY=sk-ant-...
stack                          # or: stack chat -b anthropic -m claude-opus-4-8

StackAI — call one of your deployed workflows:

stack config set backend stackai
stack config set stackai_url  https://api.stack-ai.com/inference/v0/run/<org>/<flow>
stack config set stackai_api_key <key>
stack

Config is stored at ~/.config/stackai/config.json. Relevant keys: backend, model, anthropic_api_key, stackai_url, stackai_api_key, stackai_input_field (default in-0), stackai_output_field (default outputs).

Other commands

stack --version
stack hello [name]
stack config set|get|list|path

Development

This project uses uv.

uv sync                   # install deps into a local venv
uv run stack              # run the agent from source
uv run pytest             # run the test suite

Building & publishing

uv build                  # produces wheel + sdist in dist/
uv publish                # upload to PyPI

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

stackai-0.4.0.tar.gz (18.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

stackai-0.4.0-py3-none-any.whl (21.4 kB view details)

Uploaded Python 3

File details

Details for the file stackai-0.4.0.tar.gz.

File metadata

  • Download URL: stackai-0.4.0.tar.gz
  • Upload date:
  • Size: 18.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.28 {"installer":{"name":"uv","version":"0.11.28","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for stackai-0.4.0.tar.gz
Algorithm Hash digest
SHA256 9335b98371ee6b561a9210961b8f65b5663ba6eb540fc1c0801cb788d5fbc620
MD5 1153e877b6e99b89d5a01b2f92a86cfc
BLAKE2b-256 fc76defe9a03913d8cadad217301a5e86aff3533f95c78178bfd8c459505716d

See more details on using hashes here.

File details

Details for the file stackai-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: stackai-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 21.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.28 {"installer":{"name":"uv","version":"0.11.28","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for stackai-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 20dacbd655c6d4dfa89b91d28eedb8e39c17dac9bbccc44f76ac6df3a9bb5f0d
MD5 a0d3eeb137e4d7ec774cf1d6d351d506
BLAKE2b-256 748127ef0fe163db11d9885c63754fed9662ff8d82418b4e230db07cdecff783

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page