--- id: questo version: "0.4.2" license: MIT license_treatment: permissive maintenance: active --- # questo — A library of extensible and modular CLI prompt elements License: permissive · Maintenance: active · Downloads: 91.3K/mo ## What it is and what it does Questo is a library for building interactive CLI prompts and selections in Python. It differs from higher-level prompt libraries by exposing the underlying state machine, event loop, and rendering functions, giving you direct control over how keypresses are handled and how elements appear on screen. You provide your own event loop (typically using python-yakh for key capture), update the element's state in response to each keypress, and render the result—this architecture lets you integrate prompts seamlessly into existing terminal applications or add custom behavior without fighting against library abstractions. The library includes two main elements: Prompt for text input with completion and cursor navigation support, and Select for single or multi-select lists with filtering and pagination. Both are built on a consistent pattern of state dataclasses, key handlers, and renderer functions. Dependencies are minimal—just python-yakh for cross-platform key input and rich for terminal rendering—making it lightweight to add to existing projects. Use it for: - Build interactive CLI tools that need text input or menu selection without being locked into a single prompt library's design. - Integrate custom terminal UI elements into existing event-driven applications by controlling the render loop yourself. - Create terminal UIs with non-standard appearance or behavior by providing custom renderer and key-handler functions. - Add pagination and filtering to large option lists in interactive selection prompts. - Prototype or test CLI interactions by manipulating state directly without running a full event loop. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Questo provides modular, extensible CLI prompt elements (text input and list selection) that expose internal state and rendering for full customization within your own event loop. Yes, if you need customizable CLI prompts and are comfortable managing your own event loop. The low install friction, active maintenance, permissive license, and no known vulnerabilities make it a safe choice. Not ideal if you want a batteries-included prompt library that handles the event loop for you—consider it when you need fine-grained control over terminal interaction. ## Install pip install questo uv add questo poetry add questo ## Installing questo Before you install: Low friction: pure Python wheel with only two runtime dependencies (python-yakh and rich). Active maintenance with recent commits and no known vulnerabilities. License in practice: MIT license is permissive; you can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions. Quickstart: pip install questo from yakh import get_key from questo import prompt p = prompt.Prompt() p.state = prompt.PromptState(title="Your name?") with p.displayed(): while True: key = get_key() p.state = prompt.key_handler(p.state, key) if p.state.exit or p.state.abort: break print(p.result) Requires a terminal that supports raw key input; python-yakh handles platform-specific key capture. Verify before relying: - Whether custom renderers can integrate with rich markup beyond the built-in examples shown. - Performance characteristics when handling large option lists in Select elements. - Exact behavior of pagination and filtering in Select with edge cases. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 91.3K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags CLI prompt library, terminal input elements, interactive CLI prompts, customizable terminal UI, text input and selection, event loop CLI, terminal prompt toolkit, interactive-cli, terminal-ui [View on SkillFed](https://skillfed.io/packages/questo) · [View on PyPI](https://pypi.org/project/questo/)