Skip to main content

A conversational prompting and programming language

Project description

Convo-Lang Python Wrapper (v0.6.0)

A Python wrapper around the Convo-Lang CLI that lets you build conversations in Python and execute them via the official Convo-Lang engine.

Status: 0.6.0 – basic conversation building + single-shot completion via the CLI.

\


Features

  • Minimal, Pythonic API to build conversations (system, user, assistant)
  • One-line complete() to run via Convo-Lang CLI
  • Simple config with env passthrough (e.g., OPENAI_API_KEY) and defaultModel
  • Zero server code required — uses the official Convo-Lang CLI under the hood

Installation

1. Install Node.js and npm

The wrapper depends on the Convo-Lang CLI, which requires Node.js.
Download and install the latest LTS version of Node.js (includes npm):

Verify installation:

node -v
npm -v

2. Install the Convo-Lang CLI

npm i -g @convo-lang/convo-lang-cli

This makes the convo binary available in your PATH.

3. Install the Python wrapper

pip install convo-lang

Quick Start

from convo_lang import Conversation

OPENAI_API_KEY = "sk-proj-EMA"
defaultModel = "gpt-5"
convo = Conversation(
    config={
        "env": {"OPENAI_API_KEY": OPENAI_API_KEY},
        "defaultModel": defaultModel,
    }
)
convo.add_system_message("You are a home automation assistant.")
convo.add_user_message("It's time for bed, can you turn off the lights")
answer = convo.complete()
print("\n--- LAST ASSISTANT ---\n", answer)

Requirements

  • Python 3.8+
  • Node.js 18+ and npm
  • Convo-Lang CLI: npm i -g @convo-lang/convo-lang-cli
  • At least one LLM provider API key in the environment (e.g., OPENAI_API_KEY)

Authors

Maintainers

Project details


Download files

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

Source Distribution

convo_lang-0.6.0.tar.gz (28.8 kB view details)

Uploaded Source

Built Distribution

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

convo_lang-0.6.0-py3-none-any.whl (30.6 kB view details)

Uploaded Python 3

File details

Details for the file convo_lang-0.6.0.tar.gz.

File metadata

  • Download URL: convo_lang-0.6.0.tar.gz
  • Upload date:
  • Size: 28.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.0rc2

File hashes

Hashes for convo_lang-0.6.0.tar.gz
Algorithm Hash digest
SHA256 54cd3ceddf35a98fadd0e67941f74eb76818833f6b593306c72f48c353fa9f33
MD5 13130521fd5757c74e38f2cfe4826cee
BLAKE2b-256 0b2c937bc3f376c92dc4a11a87b00f3f553b848bad786792be4dbf9ce5e44afc

See more details on using hashes here.

File details

Details for the file convo_lang-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: convo_lang-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 30.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.0rc2

File hashes

Hashes for convo_lang-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 45334fe3c0de20460b7d77c4fff8ae368b03166f662369265cdaaed69ce27abd
MD5 b1b4d0d6afb451619f0debe96bc432e5
BLAKE2b-256 8fe977de40bfe26751d54cf5e5fab78711e22122055bb8cbf31342277ad81e6d

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