Professional Python SDK for AutoAgents AI platform, providing intuitive APIs for intelligent conversation, file processing, knowledge base management, and more.
Table of Contents
- Why AutoAgents AI Python SDK?
- Quick Start
- Core Features
- API Reference
- Configuration
- Examples
- Contributing
- License
Why AutoAgents AI Python SDK?
AutoAgents AI Python SDK is a comprehensive toolkit that transforms how developers interact with AI-powered automation systems. Built for modern Python applications, it provides seamless integration with the AutoAgents AI platform.
Core Features
Intelligent Conversation
- Streaming Chat: Real-time conversation with multi-turn interactions
- Reasoning Process: Display AI thinking and decision-making steps
- Multi-modal Support: Handle text, images, and files in unified interface
File Processing
- Multi-format Support: Automatic processing of PDF, Word, images, and more
- Smart Analysis: Extract insights and content from documents
- Batch Operations: Handle multiple files efficiently
Knowledge Base Management
- Complete CRUD Operations: Create, read, update, delete knowledge bases
- Advanced Search: Semantic search and content retrieval
- Content Organization: Structured storage and management
Pre-built Agents
- PowerPoint Generation: Create presentations from templates and data
- React Agents: Interactive problem-solving agents
- Workflow Automation: Complex multi-step task orchestration
- Data Science Tools: Analytics and visualization capabilities
Modern Architecture
- Async Support: High-performance asynchronous API calls
- Type Safety: Full Pydantic type validation
- Extensible Design: Modular components for custom solutions
Why Choose AutoAgents AI Python SDK?
- Developer-First: Intuitive APIs designed for modern Python development
- Production-Ready: Battle-tested in enterprise environments
- Comprehensive: Everything needed for AI automation in one package
- Well-Documented: Extensive examples and clear API documentation
Quick Start
Prerequisites
- Python 3.11+
- AutoAgents AI platform account
Installation
pip install autoagentsai
Or install from source:
git clone https://github.com/your-repo/autoagents-python-sdk.git
cd autoagents-python-sdk
pip install -e .
Get API Keys
- Log in to AutoAgents AI platform
- Navigate to Profile → Personal Keys
- Copy your
personal_auth_keyandpersonal_auth_secret
First Conversation
from autoagentsai.client import ChatClient
# Initialize client
client = ChatClient(
agent_id="your_agent_id",
personal_auth_key="your_auth_key",
personal_auth_secret="your_auth_secret"
)
# Start conversation
for event in client.invoke("Hello, please introduce artificial intelligence"):
if event['type'] == 'token':
print(event['content'], end='', flush=True)
elif event['type'] == 'finish':
break
File Processing
# Upload and analyze files
for event in client.invoke(
prompt="Please analyze the main content of this document",
files=["document.pdf"]
):
if event['type'] == 'token':
print(event['content'], end='', flush=True)
Knowledge Base Management
from autoagentsai.client import KbClient
# Initialize knowledge base client
kb_client = KbClient(
personal_auth_key="your_auth_key",
personal_auth_secret="your_auth_secret"
)
# Create knowledge base
result = kb_client.create_kb(
name="Technical Documentation",
description="Store technical documents"
)
# Query knowledge base list
kb_list = kb_client.query_kb_list()
Slide Generation
from autoagentsai.slide import SlideAgent
# Create slide agent
slide_agent = SlideAgent()
# Generate presentation
slide_agent.fill(
prompt="Create a presentation about AI development",
template_file_path="template.pptx",
output_file_path="output.pptx"
)
Advanced Workflow Automation
from autoagentsai.graph import FlowGraph
# Create workflow graph
graph = FlowGraph(
personal_auth_key="your_auth_key",
personal_auth_secret="your_auth_secret"
)
# Add workflow nodes and compile
graph.add_node("chat_node", "chat", {"prompt": "Analyze this data"})
graph.add_node("ppt_node", "slide", {"template": "report.pptx"})
graph.add_edge("chat_node", "ppt_node")
# Deploy workflow
graph.compile(workflow_name="data_analysis_pipeline")
API Reference
ChatClient
Main conversation client supporting streaming chat and multimodal input.
Methods
invoke(prompt, images=None, files=None)- Start conversationhistory()- Get conversation history
Event Types
start_bubble- New response bubble startstoken- Text fragment (for typewriter effect)reasoning_token- AI reasoning processend_bubble- Response bubble endsfinish- Conversation complete
KbClient
Knowledge base management client.
Methods
create_kb(name, description)- Create knowledge basequery_kb_list()- Query knowledge base listget_kb_detail(kb_id)- Get knowledge base detailsdelete_kb(kb_id)- Delete knowledge base
FlowGraph
Workflow automation and orchestration.
Methods
add_node(node_id, module_type, inputs)- Add workflow nodeadd_edge(source, target)- Connect nodescompile(workflow_name)- Deploy workflow
Configuration
Environment Settings
# Development environment (default)
base_url = "https://uat.agentspro.cn"
# Production environment
base_url = "https://agentspro.cn"
API Keys Setup
Set your credentials as environment variables:
export AUTOAGENTS_AUTH_KEY="your_auth_key"
export AUTOAGENTS_AUTH_SECRET="your_auth_secret"
Or pass them directly when initializing clients:
client = ChatClient(
personal_auth_key="your_auth_key",
personal_auth_secret="your_auth_secret"
)
Getting Agent ID
- Open Agent details page
- Click "Share" → "API"
- Copy Agent ID
Examples
Explore the playground/ directory for comprehensive examples:
playground/client/- Chat and API examplesplayground/slide/- PowerPoint generation examplesplayground/kb/- Knowledge base managementplayground/react/- React Agent examplesplayground/graph/- Workflow automationplayground/datascience/- Data analysis tools
Contributing
We welcome contributions! Please feel free to submit issues and pull requests.
Development Setup
git clone https://github.com/your-repo/autoagents-python-sdk.git
cd autoagents-python-sdk
pip install -e .[dev]
License
MIT License
Support
- Email: forhheart5532@gmail.com
- Documentation: AutoAgents AI Official Docs
- Issues: GitHub Issues
Metadata
Release files for autoagentsai 0.1.36
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| autoagentsai-0.1.36.tar.gz | 19.7 MB | Without provenance | Details for autoagentsai-0.1.36.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| autoagentsai-0.1.36-py3-none-any.whl | Python 3 | none | any | Details for autoagentsai-0.1.36-py3-none-any.whl |
Total release size: 33.5 MB
Release files / autoagentsai-0.1.36.tar.gz
| Download URL | autoagentsai-0.1.36.tar.gz |
|---|---|
| Size | 19.7 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
67bcd44f1f0ba03036acda411ed11b37271802e7d0128a098c1a5f006ca1db49
|
|
BLAKE2b-256 checksum How to use checksums |
e740f46825555fde21c70ae63b02fccaea5452c732633236c17a76c54fb5fa6c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.7.9
|
Release files / autoagentsai-0.1.36-py3-none-any.whl
| Download URL | autoagentsai-0.1.36-py3-none-any.whl |
|---|---|
| Size | 13.9 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
47a2d686d3bf136e0a7b85ca7950dd8cd70788161cfe46c903dae627118ec905
|
|
BLAKE2b-256 checksum How to use checksums |
439203580e665afda1f19c6ad38785295fece3860611b78d1f0716ceef4e8cde
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.7.9
|
Security for autoagentsai 0.1.36
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.