persona-sdk-python 0.2.5__tar.gz → 0.2.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/PKG-INFO +22 -2
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/README.md +21 -1
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/agents.py +12 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/pyproject.toml +1 -1
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/.gitignore +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/DEPLOY.md +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/bitbucket-pipelines.yml +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/__init__.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/__init__.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/credentials.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/features.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/knowledge_bases.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/missions.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/projects.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/service_prices.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/sessions.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/triggers.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/api/workflows.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/auth/__init__.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/auth/api_key_auth.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/auth/base.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/auth/bearer_token_auth.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/client.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/runners/__init__.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/runners/agent_runner.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/runners/resource_retriever.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/runners/tool_invoker.py +0 -0
- {persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/uv.lock +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: persona-sdk-python
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.6
|
|
4
4
|
Summary: Async Python SDK for the Persona AI platform
|
|
5
5
|
Project-URL: Homepage, https://persona.applica.guru
|
|
6
6
|
Project-URL: Repository, https://bitbucket.org/applicaguru/persona-sdk-python
|
|
@@ -123,7 +123,7 @@ The `PersonaSdk` instance exposes one client per resource:
|
|
|
123
123
|
|
|
124
124
|
| Attribute | Description |
|
|
125
125
|
|-----------|-------------|
|
|
126
|
-
| `sdk.agents` | Agent management (CRUD, voices) |
|
|
126
|
+
| `sdk.agents` | Agent management (CRUD, voices, AI instructions, architect) |
|
|
127
127
|
| `sdk.projects` | Project management and subscriptions |
|
|
128
128
|
| `sdk.sessions` | Sessions, messages, usage |
|
|
129
129
|
| `sdk.knowledge_bases` | Knowledge bases, documents, chunk search |
|
|
@@ -168,6 +168,26 @@ await sdk.agents.update(agent["id"], fetched)
|
|
|
168
168
|
await sdk.agents.delete(agent["id"])
|
|
169
169
|
```
|
|
170
170
|
|
|
171
|
+
## AI System Instructions Generation
|
|
172
|
+
|
|
173
|
+
Generate system instructions for an agent using the project's AI architect:
|
|
174
|
+
|
|
175
|
+
```python
|
|
176
|
+
# Generate from a description
|
|
177
|
+
instructions = await sdk.agents.generate_system_instructions(
|
|
178
|
+
"Create a customer support agent that handles billing inquiries"
|
|
179
|
+
)
|
|
180
|
+
|
|
181
|
+
# Multi-turn refinement with session ID
|
|
182
|
+
instructions = await sdk.agents.generate_system_instructions(
|
|
183
|
+
"Add a rule to always ask for the order number first",
|
|
184
|
+
session_id="my-session-id",
|
|
185
|
+
)
|
|
186
|
+
|
|
187
|
+
# Get the project's architect agent configuration
|
|
188
|
+
architect = await sdk.agents.get_architect()
|
|
189
|
+
```
|
|
190
|
+
|
|
171
191
|
## Pagination
|
|
172
192
|
|
|
173
193
|
List endpoints accept `keyword`, `page`, and `size`:
|
|
@@ -99,7 +99,7 @@ The `PersonaSdk` instance exposes one client per resource:
|
|
|
99
99
|
|
|
100
100
|
| Attribute | Description |
|
|
101
101
|
|-----------|-------------|
|
|
102
|
-
| `sdk.agents` | Agent management (CRUD, voices) |
|
|
102
|
+
| `sdk.agents` | Agent management (CRUD, voices, AI instructions, architect) |
|
|
103
103
|
| `sdk.projects` | Project management and subscriptions |
|
|
104
104
|
| `sdk.sessions` | Sessions, messages, usage |
|
|
105
105
|
| `sdk.knowledge_bases` | Knowledge bases, documents, chunk search |
|
|
@@ -144,6 +144,26 @@ await sdk.agents.update(agent["id"], fetched)
|
|
|
144
144
|
await sdk.agents.delete(agent["id"])
|
|
145
145
|
```
|
|
146
146
|
|
|
147
|
+
## AI System Instructions Generation
|
|
148
|
+
|
|
149
|
+
Generate system instructions for an agent using the project's AI architect:
|
|
150
|
+
|
|
151
|
+
```python
|
|
152
|
+
# Generate from a description
|
|
153
|
+
instructions = await sdk.agents.generate_system_instructions(
|
|
154
|
+
"Create a customer support agent that handles billing inquiries"
|
|
155
|
+
)
|
|
156
|
+
|
|
157
|
+
# Multi-turn refinement with session ID
|
|
158
|
+
instructions = await sdk.agents.generate_system_instructions(
|
|
159
|
+
"Add a rule to always ask for the order number first",
|
|
160
|
+
session_id="my-session-id",
|
|
161
|
+
)
|
|
162
|
+
|
|
163
|
+
# Get the project's architect agent configuration
|
|
164
|
+
architect = await sdk.agents.get_architect()
|
|
165
|
+
```
|
|
166
|
+
|
|
147
167
|
## Pagination
|
|
148
168
|
|
|
149
169
|
List endpoints accept `keyword`, `page`, and `size`:
|
|
@@ -25,3 +25,15 @@ class AgentsApi:
|
|
|
25
25
|
|
|
26
26
|
async def get_voices(self, synthesizer_type: str) -> dict:
|
|
27
27
|
return await self._client.get(f"/values/synthesizers/{synthesizer_type}/voices")
|
|
28
|
+
|
|
29
|
+
async def generate_system_instructions(self, prompt: str, session_id: str = None) -> str:
|
|
30
|
+
"""Generate system instructions using the project's AI architect agent."""
|
|
31
|
+
body = {"prompt": prompt}
|
|
32
|
+
if session_id:
|
|
33
|
+
body["sessionId"] = session_id
|
|
34
|
+
result = await self._client.post("/agents/system-instructions", json=body)
|
|
35
|
+
return result.get("instructions", "")
|
|
36
|
+
|
|
37
|
+
async def get_architect(self) -> dict:
|
|
38
|
+
"""Get or create the project's architect agent configuration."""
|
|
39
|
+
return await self._client.get("/agents/architect")
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{persona_sdk_python-0.2.5 → persona_sdk_python-0.2.6}/persona_sdk/runners/resource_retriever.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|