Skip to main content

Python SDK for Dialetica AI - Multi-agent conversational AI platform

Project description

Dialetica AI Python SDK

Official Python SDK for the Dialetica AI platform - a multi-agent conversational AI system.

Installation

pip install dialetica

Quick Start

from dialetica import Dialetica, AgentRequest, ContextRequest, MessageRequest

# Initialize the client
client = Dialetica(api_key="dai_your_api_key_here")
# Or use environment variable: DIALETICA_AI_API_KEY

# Create an agent
agent = client.agents.create(AgentRequest(
    name="Assistant",
    description="Helpful assistant",
    instructions=["Be helpful and concise"],
    model="gpt-4o"
))

# Create a context
context = client.contexts.create(ContextRequest(
    name="Support Chat",
    agents=[agent.id]
))

# Send a message
message = MessageRequest(
    role="user",
    sender_name="User",
    content="Hello!"
)

# Get response
responses = client.contexts.run(context, [message])
for response in responses:
    print(f"{response.sender_name}: {response.content}")

Features

  • Multi-Agent Conversations: Create contexts with multiple AI agents
  • Knowledge Management: Store and query knowledge using semantic search
  • Streaming Support: Real-time streaming responses with SSE
  • Type-Safe: Full Pydantic models for request/response validation
  • Simple API: Clean, intuitive interface following industry best practices

Building and Publishing

To build the package:

cd backend
python -m build

To publish to PyPI (test first with TestPyPI):

# Test on TestPyPI first
python -m twine upload --repository testpypi dist/*

# Then publish to PyPI
python -m twine upload dist/*

Documentation

For full documentation, visit https://docs.dialetica-ai.com

License

MIT License

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

dialetica-1.0.22.tar.gz (16.0 kB view details)

Uploaded Source

Built Distribution

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

dialetica-1.0.22-py3-none-any.whl (12.7 kB view details)

Uploaded Python 3

File details

Details for the file dialetica-1.0.22.tar.gz.

File metadata

  • Download URL: dialetica-1.0.22.tar.gz
  • Upload date:
  • Size: 16.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for dialetica-1.0.22.tar.gz
Algorithm Hash digest
SHA256 d0b0725f9f29ef4eea7704d49d9631380718fc3ac5fef8acda079ae37b693cef
MD5 861d91b8ec2ee6368b613320aee853ef
BLAKE2b-256 2e0406236f6391f31be6730fdb099482206619c15b84af2cf874c96add6868d7

See more details on using hashes here.

File details

Details for the file dialetica-1.0.22-py3-none-any.whl.

File metadata

  • Download URL: dialetica-1.0.22-py3-none-any.whl
  • Upload date:
  • Size: 12.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for dialetica-1.0.22-py3-none-any.whl
Algorithm Hash digest
SHA256 7a0997f695f48d653a98dd188086347e3584c634c90c093a580f3bec12c5a994
MD5 ae46659a60ae1d8953f9b698e2b0faae
BLAKE2b-256 a165793a8629f36698ca45509d236c403b047d602700663db91b31b58dcb2046

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