lionagi 0.0.208__py3-none-any.whl → 0.0.210__py3-none-any.whl
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.
- lionagi/__init__.py +4 -6
- lionagi/api_service/base_endpoint.py +65 -0
- lionagi/api_service/base_rate_limiter.py +121 -0
- lionagi/api_service/base_service.py +146 -0
- lionagi/api_service/chat_completion.py +6 -0
- lionagi/api_service/embeddings.py +6 -0
- lionagi/api_service/payload_package.py +47 -0
- lionagi/api_service/status_tracker.py +29 -0
- lionagi/core/__init__.py +5 -9
- lionagi/core/branch.py +1191 -0
- lionagi/core/flow.py +423 -0
- lionagi/core/{instruction_set/instruction_set.py → instruction_set.py} +3 -3
- lionagi/core/session.py +872 -0
- lionagi/schema/__init__.py +5 -8
- lionagi/schema/base_schema.py +821 -0
- lionagi/{_services → services}/base_service.py +4 -4
- lionagi/{_services → services}/oai.py +4 -4
- lionagi/structures/graph.py +1 -1
- lionagi/structures/relationship.py +1 -1
- lionagi/structures/structure.py +1 -1
- lionagi/tools/tool_manager.py +0 -163
- lionagi/tools/tool_util.py +2 -1
- lionagi/utils/__init__.py +7 -14
- lionagi/utils/api_util.py +63 -2
- lionagi/utils/core_utils.py +338 -0
- lionagi/utils/sys_util.py +3 -3
- lionagi/version.py +1 -1
- {lionagi-0.0.208.dist-info → lionagi-0.0.210.dist-info}/METADATA +28 -29
- lionagi-0.0.210.dist-info/RECORD +56 -0
- lionagi/_services/anthropic.py +0 -79
- lionagi/_services/anyscale.py +0 -0
- lionagi/_services/azure.py +0 -1
- lionagi/_services/bedrock.py +0 -0
- lionagi/_services/everlyai.py +0 -0
- lionagi/_services/gemini.py +0 -0
- lionagi/_services/gpt4all.py +0 -0
- lionagi/_services/huggingface.py +0 -0
- lionagi/_services/litellm.py +0 -33
- lionagi/_services/localai.py +0 -0
- lionagi/_services/openllm.py +0 -0
- lionagi/_services/openrouter.py +0 -44
- lionagi/_services/perplexity.py +0 -0
- lionagi/_services/predibase.py +0 -0
- lionagi/_services/rungpt.py +0 -0
- lionagi/_services/vllm.py +0 -0
- lionagi/_services/xinference.py +0 -0
- lionagi/agents/planner.py +0 -1
- lionagi/agents/prompter.py +0 -1
- lionagi/agents/scorer.py +0 -1
- lionagi/agents/summarizer.py +0 -1
- lionagi/agents/validator.py +0 -1
- lionagi/bridge/__init__.py +0 -22
- lionagi/bridge/langchain.py +0 -195
- lionagi/bridge/llama_index.py +0 -266
- lionagi/core/branch/__init__.py +0 -0
- lionagi/core/branch/branch.py +0 -841
- lionagi/core/branch/cluster.py +0 -1
- lionagi/core/branch/conversation.py +0 -787
- lionagi/core/core_util.py +0 -0
- lionagi/core/flow/__init__.py +0 -0
- lionagi/core/flow/flow.py +0 -19
- lionagi/core/flow/flow_util.py +0 -62
- lionagi/core/instruction_set/__init__.py +0 -0
- lionagi/core/messages/__init__.py +0 -0
- lionagi/core/sessions/__init__.py +0 -0
- lionagi/core/sessions/session.py +0 -504
- lionagi/datastores/__init__.py +0 -1
- lionagi/datastores/chroma.py +0 -1
- lionagi/datastores/deeplake.py +0 -1
- lionagi/datastores/elasticsearch.py +0 -1
- lionagi/datastores/lantern.py +0 -1
- lionagi/datastores/pinecone.py +0 -1
- lionagi/datastores/postgres.py +0 -1
- lionagi/datastores/qdrant.py +0 -1
- lionagi/loaders/__init__.py +0 -18
- lionagi/loaders/chunker.py +0 -166
- lionagi/loaders/load_util.py +0 -240
- lionagi/loaders/reader.py +0 -122
- lionagi/models/__init__.py +0 -0
- lionagi/models/base_model.py +0 -0
- lionagi/models/imodel.py +0 -53
- lionagi/schema/async_queue.py +0 -158
- lionagi/schema/base_condition.py +0 -1
- lionagi/schema/base_node.py +0 -422
- lionagi/schema/base_tool.py +0 -44
- lionagi/schema/data_logger.py +0 -126
- lionagi/schema/data_node.py +0 -88
- lionagi/schema/status_tracker.py +0 -37
- lionagi/tests/test_utils/test_encrypt_util.py +0 -323
- lionagi/utils/encrypt_util.py +0 -283
- lionagi/utils/url_util.py +0 -55
- lionagi-0.0.208.dist-info/RECORD +0 -106
- lionagi/{agents → api_service}/__init__.py +0 -0
- lionagi/core/{branch/branch_manager.py → branch_manager.py} +0 -0
- lionagi/core/{messages/messages.py → messages.py} +3 -3
- /lionagi/{_services → services}/__init__.py +0 -0
- /lionagi/{_services → services}/mistralai.py +0 -0
- /lionagi/{_services → services}/mlx_service.py +0 -0
- /lionagi/{_services → services}/ollama.py +0 -0
- /lionagi/{_services → services}/services.py +0 -0
- /lionagi/{_services → services}/transformers.py +0 -0
- {lionagi-0.0.208.dist-info → lionagi-0.0.210.dist-info}/LICENSE +0 -0
- {lionagi-0.0.208.dist-info → lionagi-0.0.210.dist-info}/WHEEL +0 -0
- {lionagi-0.0.208.dist-info → lionagi-0.0.210.dist-info}/top_level.txt +0 -0
lionagi/utils/encrypt_util.py
DELETED
@@ -1,283 +0,0 @@
|
|
1
|
-
import base64
|
2
|
-
import binascii
|
3
|
-
import hashlib
|
4
|
-
import os
|
5
|
-
import zipfile
|
6
|
-
from base64 import urlsafe_b64encode
|
7
|
-
from cryptography.fernet import Fernet, InvalidToken
|
8
|
-
from cryptography.hazmat.backends import default_backend
|
9
|
-
from cryptography.hazmat.primitives import hashes
|
10
|
-
from cryptography.hazmat.primitives.kdf.pbkdf2 import PBKDF2HMAC
|
11
|
-
from typing import Optional
|
12
|
-
|
13
|
-
|
14
|
-
class EncrytionUtil:
|
15
|
-
"""
|
16
|
-
A utility class for handling encryption, decryption, file operations, and password strength checking.
|
17
|
-
"""
|
18
|
-
|
19
|
-
@staticmethod
|
20
|
-
def password_strength_checker(password: str) -> bool:
|
21
|
-
"""
|
22
|
-
Check the strength of a password.
|
23
|
-
|
24
|
-
Args:
|
25
|
-
password (str): The password to check.
|
26
|
-
|
27
|
-
Returns:
|
28
|
-
bool: True if the password is strong, False otherwise.
|
29
|
-
|
30
|
-
Examples:
|
31
|
-
>>> password_strength_checker("Weakpass")
|
32
|
-
False
|
33
|
-
>>> password_strength_checker("Strongpass1")
|
34
|
-
True
|
35
|
-
"""
|
36
|
-
if len(password) < 8 or not any(char.isdigit() for char in password) or not any(char.isupper() for char in password):
|
37
|
-
return False
|
38
|
-
return True
|
39
|
-
|
40
|
-
@staticmethod
|
41
|
-
def generate_encryption_key(password: Optional[str] = None, salt: Optional[bytes] = None) -> str:
|
42
|
-
"""
|
43
|
-
Generate an encryption key from a password and salt.
|
44
|
-
|
45
|
-
Args:
|
46
|
-
password (Optional[str]): The password to derive the key from. If None, a random key is generated.
|
47
|
-
salt (Optional[bytes]): A salt for the key derivation. If None, a random salt is used.
|
48
|
-
|
49
|
-
Returns:
|
50
|
-
str: The generated encryption key as a URL-safe base64-encoded string.
|
51
|
-
|
52
|
-
Raises:
|
53
|
-
ValueError: If the password is too weak.
|
54
|
-
|
55
|
-
Examples:
|
56
|
-
>>> key = generate_encryption_key("Strongpass1")
|
57
|
-
>>> isinstance(key, str)
|
58
|
-
True
|
59
|
-
"""
|
60
|
-
if password:
|
61
|
-
if not EncrytionUtil.password_strength_checker(password):
|
62
|
-
raise ValueError("Password is too weak.")
|
63
|
-
if not salt:
|
64
|
-
salt = os.urandom(16)
|
65
|
-
kdf = PBKDF2HMAC(
|
66
|
-
algorithm=hashes.SHA256(),
|
67
|
-
length=32,
|
68
|
-
salt=salt,
|
69
|
-
iterations=100000,
|
70
|
-
backend=default_backend()
|
71
|
-
)
|
72
|
-
key = kdf.derive(password.encode())
|
73
|
-
return urlsafe_b64encode(key).decode()
|
74
|
-
else:
|
75
|
-
return Fernet.generate_key().decode()
|
76
|
-
|
77
|
-
@staticmethod
|
78
|
-
def encrypt(data: str, key: str) -> str:
|
79
|
-
"""
|
80
|
-
Encrypt the provided data using the provided key.
|
81
|
-
|
82
|
-
Args:
|
83
|
-
data (str): The data to encrypt.
|
84
|
-
key (str): The encryption key.
|
85
|
-
|
86
|
-
Returns:
|
87
|
-
str: The encrypted data.
|
88
|
-
|
89
|
-
Example:
|
90
|
-
>>> encrypt("This is some test data.", "esvCExTuhddRb8kSobU_gnNRYObyTRTI2LJF4nYai5I=")
|
91
|
-
'gAAAAABloX9m_S_G1VUtbfGUDB7ooHJNt8sPiSCwnp1ehe6dExvMEqtw_ua2ELk_uUbLoB6a1XkbKLOkM4UBvwmk6sMoY-yNvE-Lv-w-VNnfzf89zH82rgI='
|
92
|
-
"""
|
93
|
-
fernet = Fernet(key.encode())
|
94
|
-
return fernet.encrypt(data.encode()).decode()
|
95
|
-
|
96
|
-
@staticmethod
|
97
|
-
def decrypt(data: str, key: str) -> str:
|
98
|
-
"""
|
99
|
-
Decrypt the provided data using the provided key.
|
100
|
-
|
101
|
-
Args:
|
102
|
-
data (str): The data to decrypt.
|
103
|
-
key (str): The encryption key.
|
104
|
-
|
105
|
-
Returns:
|
106
|
-
str: The decrypted data.
|
107
|
-
|
108
|
-
Example:
|
109
|
-
>>> decrypt('gAAAAABloX9m_S_G1VUtbfGUDB7ooHJNt8sPiSCwnp1ehe6dExvMEqtw_ua2ELk_uUbLoB6a1XkbKLOkM4UBvwmk6sMoY-yNvE-Lv-w-VNnfzf89zH82rgI=', "esvCExTuhddRb8kSobU_gnNRYObyTRTI2LJF4nYai5I=")
|
110
|
-
'This is some test data.'
|
111
|
-
"""
|
112
|
-
fernet = Fernet(key.encode())
|
113
|
-
return fernet.decrypt(data.encode()).decode()
|
114
|
-
|
115
|
-
@staticmethod
|
116
|
-
def encrypt_file(file_path: str, key: str, output_path: str = None):
|
117
|
-
"""
|
118
|
-
Encrypt a file.
|
119
|
-
|
120
|
-
Args:
|
121
|
-
file_path (str): The path of the file to encrypt.
|
122
|
-
key (str): The encryption key.
|
123
|
-
output_path (str, optional): The path to save the encrypted file. If not provided, '.enc' is appended to the input file path.
|
124
|
-
|
125
|
-
Example:
|
126
|
-
>>> encrypt_file("test_file.txt", "esvCExTuhddRb8kSobU_gnNRYObyTRTI2LJF4nYai5I=")
|
127
|
-
"""
|
128
|
-
if not output_path:
|
129
|
-
output_path = file_path + '.enc'
|
130
|
-
with open(file_path, 'rb') as file_to_encrypt:
|
131
|
-
encrypted_data = EncrytionUtil.encrypt(file_to_encrypt.read().decode(), key)
|
132
|
-
with open(output_path, 'wb') as encrypted_file:
|
133
|
-
encrypted_file.write(encrypted_data.encode())
|
134
|
-
|
135
|
-
@staticmethod
|
136
|
-
def decrypt_file(encrypted_file_path: str, key: str, output_path: str = None):
|
137
|
-
"""
|
138
|
-
Decrypt a file.
|
139
|
-
|
140
|
-
Args:
|
141
|
-
encrypted_file_path (str): The path of the file to decrypt.
|
142
|
-
key (str): The encryption key.
|
143
|
-
output_path (str, optional): The path to save the decrypted file. If not provided, '.enc' is removed from the input file path.
|
144
|
-
|
145
|
-
Example:
|
146
|
-
>>> decrypt_file("test_file.txt.enc", "esvCExTuhddRb8kSobU_gnNRYObyTRTI2LJF4nYai5I=")
|
147
|
-
"""
|
148
|
-
if not output_path:
|
149
|
-
output_path = encrypted_file_path.replace('.enc', '')
|
150
|
-
with open(encrypted_file_path, 'rb') as encrypted_file:
|
151
|
-
decrypted_data = EncrytionUtil.decrypt(encrypted_file.read().decode(), key)
|
152
|
-
with open(output_path, 'wb') as decrypted_file:
|
153
|
-
decrypted_file.write(decrypted_data.encode())
|
154
|
-
|
155
|
-
@staticmethod
|
156
|
-
def is_encrypted(file_path: str, key: str) -> bool:
|
157
|
-
"""
|
158
|
-
Check if a file is encrypted.
|
159
|
-
|
160
|
-
Args:
|
161
|
-
file_path (str): The path of the file to check.
|
162
|
-
key (str): The encryption key.
|
163
|
-
|
164
|
-
Returns:
|
165
|
-
bool: True if the file is encrypted, False otherwise.
|
166
|
-
|
167
|
-
Example:
|
168
|
-
>>> is_encrypted("test_file.txt.enc", "esvCExTuhddRb8kSobU_gnNRYObyTRTI2LJF4nYai5I=")
|
169
|
-
True
|
170
|
-
"""
|
171
|
-
try:
|
172
|
-
EncrytionUtil.decrypt_file(file_path, key, "temp_decrypted_file")
|
173
|
-
os.remove("temp_decrypted_file")
|
174
|
-
return True
|
175
|
-
except InvalidToken:
|
176
|
-
return False
|
177
|
-
|
178
|
-
@staticmethod
|
179
|
-
def decompress_file(file_path: str, output_path: str = None):
|
180
|
-
"""
|
181
|
-
Decompress a file.
|
182
|
-
|
183
|
-
Args:
|
184
|
-
file_path (str): The path of the file to decompress.
|
185
|
-
output_path (str, optional): The path to save the decompressed file. If not provided, the file is decompressed in the same directory.
|
186
|
-
|
187
|
-
Example:
|
188
|
-
>>> decompress_file("test_file.txt.zip")
|
189
|
-
"""
|
190
|
-
if not output_path:
|
191
|
-
output_path = os.path.dirname(file_path)
|
192
|
-
with zipfile.ZipFile(file_path, 'r') as zipf:
|
193
|
-
zipf.extractall(output_path)
|
194
|
-
|
195
|
-
@staticmethod
|
196
|
-
def compress_file(file_path: str, output_path: str = None):
|
197
|
-
"""
|
198
|
-
Compress a file.
|
199
|
-
|
200
|
-
Args:
|
201
|
-
file_path (str): The path of the file to compress.
|
202
|
-
output_path (str, optional): The path to save the compressed file. If not provided, '.zip' is appended to the input file path.
|
203
|
-
|
204
|
-
Example:
|
205
|
-
>>> compress_file("test_file.txt")
|
206
|
-
"""
|
207
|
-
if not output_path:
|
208
|
-
output_path = file_path + '.zip'
|
209
|
-
with zipfile.ZipFile(output_path, 'w', zipfile.ZIP_DEFLATED) as zipf:
|
210
|
-
zipf.write(file_path)
|
211
|
-
|
212
|
-
@staticmethod
|
213
|
-
def binary_to_hex(data: bytes) -> str:
|
214
|
-
"""
|
215
|
-
Convert binary data to a hexadecimal string representation.
|
216
|
-
|
217
|
-
Args:
|
218
|
-
data: A bytes object containing binary data.
|
219
|
-
|
220
|
-
Returns:
|
221
|
-
A string containing the hexadecimal representation of the binary data.
|
222
|
-
|
223
|
-
Examples:
|
224
|
-
>>> binary_to_hex(b'\x00\x0F')
|
225
|
-
'000f'
|
226
|
-
>>> binary_to_hex(b'hello')
|
227
|
-
'68656c6c6f'
|
228
|
-
"""
|
229
|
-
return binascii.hexlify(data).decode()
|
230
|
-
|
231
|
-
@staticmethod
|
232
|
-
def create_hash(data: str, algorithm: str = 'sha256') -> str:
|
233
|
-
"""
|
234
|
-
Create a hash of the given data using the specified algorithm.
|
235
|
-
|
236
|
-
Args:
|
237
|
-
data: The string to hash.
|
238
|
-
algorithm: The hashing algorithm to use (default is 'sha256').
|
239
|
-
|
240
|
-
Returns:
|
241
|
-
The hexadecimal digest of the hash.
|
242
|
-
|
243
|
-
Examples:
|
244
|
-
>>> create_hash('hello')
|
245
|
-
'2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824'
|
246
|
-
"""
|
247
|
-
hasher = hashlib.new(algorithm)
|
248
|
-
hasher.update(data.encode())
|
249
|
-
return hasher.hexdigest()
|
250
|
-
|
251
|
-
@staticmethod
|
252
|
-
def decode_base64(data: str) -> str:
|
253
|
-
"""
|
254
|
-
Decode a base64 encoded string.
|
255
|
-
|
256
|
-
Args:
|
257
|
-
data: A base64 encoded string.
|
258
|
-
|
259
|
-
Returns:
|
260
|
-
A decoded string.
|
261
|
-
|
262
|
-
Examples:
|
263
|
-
>>> decode_base64('SGVsbG8sIFdvcmxkIQ==')
|
264
|
-
'Hello, World!'
|
265
|
-
"""
|
266
|
-
return base64.b64decode(data).decode()
|
267
|
-
|
268
|
-
@staticmethod
|
269
|
-
def encode_base64(data: str) -> str:
|
270
|
-
"""
|
271
|
-
Encode a string using base64 encoding.
|
272
|
-
|
273
|
-
Args:
|
274
|
-
data: A string to be encoded.
|
275
|
-
|
276
|
-
Returns:
|
277
|
-
A base64 encoded string.
|
278
|
-
|
279
|
-
Examples:
|
280
|
-
>>> encode_base64("Hello, World!")
|
281
|
-
'SGVsbG8sIFdvcmxkIQ=='
|
282
|
-
"""
|
283
|
-
return base64.b64encode(data.encode()).decode()
|
lionagi/utils/url_util.py
DELETED
@@ -1,55 +0,0 @@
|
|
1
|
-
from bs4 import BeautifulSoup
|
2
|
-
import requests
|
3
|
-
|
4
|
-
def get_url_response(url: str, timeout: tuple = (1, 1), **kwargs) -> requests.Response:
|
5
|
-
"""
|
6
|
-
Sends a GET request to a URL and returns the response.
|
7
|
-
|
8
|
-
Args:
|
9
|
-
url (str): The URL to send the GET request to.
|
10
|
-
timeout (tuple): A tuple specifying the connection and read timeouts in seconds.
|
11
|
-
Defaults to (1, 1).
|
12
|
-
**kwargs: Additional keyword arguments to be passed to the requests.get() function.
|
13
|
-
|
14
|
-
Returns:
|
15
|
-
requests.Response: A Response object containing the server's response to the GET request.
|
16
|
-
|
17
|
-
Raises:
|
18
|
-
TimeoutError: If a timeout occurs while requesting or reading the response.
|
19
|
-
Exception: If an error other than a timeout occurs during the request.
|
20
|
-
"""
|
21
|
-
try:
|
22
|
-
response = requests.get(url, timeout=timeout, **kwargs)
|
23
|
-
response.raise_for_status()
|
24
|
-
return response
|
25
|
-
except requests.exceptions.ConnectTimeout:
|
26
|
-
raise TimeoutError(f"Timeout: requesting >{timeout[0]} seconds.")
|
27
|
-
except requests.exceptions.ReadTimeout:
|
28
|
-
raise TimeoutError(f"Timeout: reading >{timeout[1]} seconds.")
|
29
|
-
except Exception as e:
|
30
|
-
raise e
|
31
|
-
|
32
|
-
def get_url_content(url: str) -> str:
|
33
|
-
"""
|
34
|
-
Retrieve and parse the content from a given URL.
|
35
|
-
|
36
|
-
Args:
|
37
|
-
url (str): The URL to fetch and parse.
|
38
|
-
|
39
|
-
Returns:
|
40
|
-
str: The text content extracted from the URL.
|
41
|
-
|
42
|
-
Raises:
|
43
|
-
ValueError: If there is an issue during content retrieval or parsing.
|
44
|
-
"""
|
45
|
-
try:
|
46
|
-
response = requests.get(url)
|
47
|
-
response.raise_for_status()
|
48
|
-
|
49
|
-
soup = BeautifulSoup(response.text, 'html.parser')
|
50
|
-
|
51
|
-
text_content = ' '.join([p.get_text() for p in soup.find_all('p')])
|
52
|
-
return text_content
|
53
|
-
except Exception as e:
|
54
|
-
raise f"Error fetching content for {url}: {e}"
|
55
|
-
|
lionagi-0.0.208.dist-info/RECORD
DELETED
@@ -1,106 +0,0 @@
|
|
1
|
-
lionagi/__init__.py,sha256=pRm9tnfYQnj_ZCan3xr3HQO7tbUeqwRhSBtwOvXJ-o8,886
|
2
|
-
lionagi/version.py,sha256=h353Rt8oXc0TPbWsDOE_dqhFFQbJXj59Oix9Avy62ds,24
|
3
|
-
lionagi/_services/__init__.py,sha256=zU5sxmSI9-Jtp_WsI-Zsb6hmT8y5zF9YtJ7XikAjnbs,60
|
4
|
-
lionagi/_services/anthropic.py,sha256=pLebbnr2H1A41bzXrJrU7yQbZY35swKrSi4mktXoIyk,3195
|
5
|
-
lionagi/_services/anyscale.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
6
|
-
lionagi/_services/azure.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
7
|
-
lionagi/_services/base_service.py,sha256=bbPQ9xTaY5jxrHe6vW_PeyRkoxVaxWmpWlCqQxSfRI8,17314
|
8
|
-
lionagi/_services/bedrock.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
9
|
-
lionagi/_services/everlyai.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
10
|
-
lionagi/_services/gemini.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
11
|
-
lionagi/_services/gpt4all.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
12
|
-
lionagi/_services/huggingface.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
13
|
-
lionagi/_services/litellm.py,sha256=ho_iSwU6Zdez5fZV_UaSMK899iY-5tLRx1kepyOinGY,1118
|
14
|
-
lionagi/_services/localai.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
15
|
-
lionagi/_services/mistralai.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
16
|
-
lionagi/_services/mlx_service.py,sha256=1AF_RcV4KQmpxC67n2E0zRbssSlsTFmdnojydUXdJn4,1285
|
17
|
-
lionagi/_services/oai.py,sha256=Jiuw_TibpYhN6x1PmHYUMi_0Nugrxmi5G1eimAuw21I,3958
|
18
|
-
lionagi/_services/ollama.py,sha256=I2GvWtWA9WMyq_bhLe2JQlrkP_mAeqm2Bhf8ItOpEzQ,1190
|
19
|
-
lionagi/_services/openllm.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
20
|
-
lionagi/_services/openrouter.py,sha256=MuuwoT2ro9FmY7O1jzCenRrL2YfiYUMM8-0kKoGZHAY,1799
|
21
|
-
lionagi/_services/perplexity.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
22
|
-
lionagi/_services/predibase.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
23
|
-
lionagi/_services/rungpt.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
24
|
-
lionagi/_services/services.py,sha256=TwjAizQCTFCv_I8XZbTvpcryJPGt4vQAGYkGdZqJST0,5077
|
25
|
-
lionagi/_services/transformers.py,sha256=nGfQbcECKzA1biHe4i9l01aKCMgULKFQ4LZyqjtvSXk,2934
|
26
|
-
lionagi/_services/vllm.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
27
|
-
lionagi/_services/xinference.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
28
|
-
lionagi/agents/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
29
|
-
lionagi/agents/planner.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
30
|
-
lionagi/agents/prompter.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
31
|
-
lionagi/agents/scorer.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
32
|
-
lionagi/agents/summarizer.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
33
|
-
lionagi/agents/validator.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
34
|
-
lionagi/bridge/__init__.py,sha256=YDKi-pniFEknEXTSEvX6yEe4Y69f0kLvbjvEQ0TdrTU,575
|
35
|
-
lionagi/bridge/langchain.py,sha256=y15hTYUrmvDdEyGCSgaUgrp5OalTvlMfkQb_-XISnEA,7233
|
36
|
-
lionagi/bridge/llama_index.py,sha256=PHoWPXuYuEX8PPfFFW509n7Tzq3RgNAtpu_EuXcryhA,9901
|
37
|
-
lionagi/configs/__init__.py,sha256=QOd4Rs7vjIpNWvIocxWQeU-q-MPRC-AOxh-gM-eBJ2o,142
|
38
|
-
lionagi/configs/oai_configs.py,sha256=Q2ESc5QiMprnRc_w7SeMlaTYUWl_Y4SEzZSE4iOkz4Q,2646
|
39
|
-
lionagi/configs/openrouter_configs.py,sha256=IBQHqb8mo4Jb3kYAm_7NOHSKRPwSdGbPpDJoiwHxLYw,1269
|
40
|
-
lionagi/core/__init__.py,sha256=6uDjq1WCWBahNiCpzGaUCJe7GDg6lwUD_cGNT86GhwM,200
|
41
|
-
lionagi/core/core_util.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
42
|
-
lionagi/core/branch/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
43
|
-
lionagi/core/branch/branch.py,sha256=D6vbbbgAqFvgeYrM0vGAKEzRoibu03_YiIn8oZgcpbM,35691
|
44
|
-
lionagi/core/branch/branch_manager.py,sha256=zA_dECz9XYKLk7kK6zDWfHLs1ttRGYDfyCj4B7XKDqo,4903
|
45
|
-
lionagi/core/branch/cluster.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
46
|
-
lionagi/core/branch/conversation.py,sha256=cuRKo2m0T-HZir0HopozHeBK3nErJ-TPwjp57pGwp5Y,30158
|
47
|
-
lionagi/core/flow/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
48
|
-
lionagi/core/flow/flow.py,sha256=Fd6xVZKgjjpr-rcVAjvuMGP04OxNK4LVkbB9VnEP21k,813
|
49
|
-
lionagi/core/flow/flow_util.py,sha256=OoQ2-ktkpQs9f1m1VI1pucUeq75Mx1aKqz8KdINMt8M,2083
|
50
|
-
lionagi/core/instruction_set/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
51
|
-
lionagi/core/instruction_set/instruction_set.py,sha256=bxrxPxLJdaenvZ2CMaiucNB4fZ_5AWVz49MYs3mG2G8,13682
|
52
|
-
lionagi/core/messages/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
53
|
-
lionagi/core/messages/messages.py,sha256=bokGS8hu4wQxa-4Gsf2Eg7Q99ANccjjixZpE-DC0P7g,6533
|
54
|
-
lionagi/core/sessions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
55
|
-
lionagi/core/sessions/session.py,sha256=ak8Ys9qv7_oPx0aYAmw865Airi0r-An4y8nKzyGW1Kg,20772
|
56
|
-
lionagi/datastores/__init__.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
57
|
-
lionagi/datastores/chroma.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
58
|
-
lionagi/datastores/deeplake.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
59
|
-
lionagi/datastores/elasticsearch.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
60
|
-
lionagi/datastores/lantern.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
61
|
-
lionagi/datastores/pinecone.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
62
|
-
lionagi/datastores/postgres.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
63
|
-
lionagi/datastores/qdrant.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
64
|
-
lionagi/loaders/__init__.py,sha256=vOOwHkdI0yIA_jV_pNyOrdkS5Ghs0k4od75S1U60jJE,451
|
65
|
-
lionagi/loaders/chunker.py,sha256=noh7NagZ3PBYNgUTIjbYvLlHP9UvoLaShTfc843h7Co,6455
|
66
|
-
lionagi/loaders/load_util.py,sha256=4fzhMk3H6OvcQcViUwlLPSTMpcY4alfdel16lJgXz8Y,8358
|
67
|
-
lionagi/loaders/reader.py,sha256=xI1uxw9qGJ_rWev_s3vtW8Ep9YaK-15q7ts-Jy61PGg,4625
|
68
|
-
lionagi/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
69
|
-
lionagi/models/base_model.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
70
|
-
lionagi/models/imodel.py,sha256=VultpAAZ5PBT6_Cps-LjgZqHEyuF-km6eVvT-sEPEgo,1491
|
71
|
-
lionagi/schema/__init__.py,sha256=XRWXK9sztycoIMCTzwLEVMxxc1wgWKNUDRbWTpn5Ie0,208
|
72
|
-
lionagi/schema/async_queue.py,sha256=e_wFyDvCeKTxW6MAIU6Q3jxw24uEQuahaZwNDzZMB4k,5674
|
73
|
-
lionagi/schema/base_condition.py,sha256=chG3GNX2BBDTWIuSVfZUJ_YF_ZVBSoel2d_AN0OChS0,6
|
74
|
-
lionagi/schema/base_node.py,sha256=Ol4Y6gn81Dm8FJb3fdKVkJlq4R-OAGIf891exnVv45I,13211
|
75
|
-
lionagi/schema/base_tool.py,sha256=8LR-MYOGkv9zCHd8tWry296OZNYlbTpYeO1xd-oQcOM,1254
|
76
|
-
lionagi/schema/data_logger.py,sha256=2rNPBYF29_2xgv2m226BzKdTfFIVU1YlzQ0PK8zLAvY,4313
|
77
|
-
lionagi/schema/data_node.py,sha256=k80mv5DCqAHrGNlmaIHAkCA7JF4dkaRaRDh_oku4kUY,2272
|
78
|
-
lionagi/schema/status_tracker.py,sha256=6otnTSMrH5jM0PUDiDeK3zG0VOSKfNBDzNN6Bts2tmA,1236
|
79
|
-
lionagi/structures/__init__.py,sha256=wMPekT2vbWwUkJ5aW5o-lzJC9Fzhta6RHDiFPTNUm_0,120
|
80
|
-
lionagi/structures/graph.py,sha256=dqhRq5j3SOQvelUOanC3_DC4TQ1wRv4qK0QmleoLUZs,7788
|
81
|
-
lionagi/structures/relationship.py,sha256=IgiYHD87bc57hzSAYSo27WqLgtk8pzgGbIxfPYJCI-g,6059
|
82
|
-
lionagi/structures/structure.py,sha256=YyL3LxgeQWgkWDhACRxo8GoDn0IjE7idh7B0r5U3mZ4,3485
|
83
|
-
lionagi/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
84
|
-
lionagi/tests/test_utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
85
|
-
lionagi/tests/test_utils/test_api_util.py,sha256=7Zyc0J1glZrIWI1HrTRSRhzw8jaUW1L2vVLFAlUhI4g,9721
|
86
|
-
lionagi/tests/test_utils/test_call_util.py,sha256=7xmfFaWvniMQfaOyfwasA2enJQVuSlcAwc8gUyAR_7k,26277
|
87
|
-
lionagi/tests/test_utils/test_encrypt_util.py,sha256=hlkbFjQs2jodr8fgtPli6f1MO3doQbTcsZfzGKVrG5k,12652
|
88
|
-
lionagi/tests/test_utils/test_io_util.py,sha256=cFZCT6EikVeuXB13w-UbtO3YceCHBO5RlNXxGICqg_U,11002
|
89
|
-
lionagi/tests/test_utils/test_nested_util.py,sha256=Z1boHufhjZryw51qW2lABOnnyJ1snAFp26KKzzzD8Bs,12612
|
90
|
-
lionagi/tests/test_utils/test_sys_util.py,sha256=TDCkzll-JLa6NuBbN_-ay5Rw9KTa_HcSHHAq62RVwGI,13545
|
91
|
-
lionagi/tools/__init__.py,sha256=ZEck-ReP5Co05nAA2gUXTpKoDN2QZqrL7DvU9Z09gqg,69
|
92
|
-
lionagi/tools/tool_manager.py,sha256=PeGy_F_I4yefbv7YZQupxvPCVTJRFLXZ3rrxCoxktTI,5958
|
93
|
-
lionagi/tools/tool_util.py,sha256=5ln7lnqC_rjhKDDwef10xrBrjP1yLzsQvphllD5crec,9252
|
94
|
-
lionagi/utils/__init__.py,sha256=Lq6XgvQa6iBNveN_LS0leKE2SCipvMw1UDdMjj6S-lM,1059
|
95
|
-
lionagi/utils/api_util.py,sha256=YV-DKPgR4lCKO_riroSKyq6mO-8vz-SilRo_gWtg4Zg,15282
|
96
|
-
lionagi/utils/call_util.py,sha256=nqrqUjRtTAaOSnRoEyLy5j6B7Pauv-MgzApOv9xrVkc,33187
|
97
|
-
lionagi/utils/encrypt_util.py,sha256=iZjZdXVvl0lw4Yw_YNzIWriM3F2qKtzai7PgSQ1TExc,9316
|
98
|
-
lionagi/utils/io_util.py,sha256=xoVsq8sP5JGsosuC80Kad3GkGjm8Qm0OLYyTw-U5ru8,6455
|
99
|
-
lionagi/utils/nested_util.py,sha256=67j-ySQtuMGxtjnC-Ty2mwQgqp2g1gZhXRy1MulUu1U,26656
|
100
|
-
lionagi/utils/sys_util.py,sha256=B4GboyxEEd6h2KCnsXcS62oCG8upQxTJ6LEbEQ2rBdA,15887
|
101
|
-
lionagi/utils/url_util.py,sha256=fu1uRFwSR9D3dO1nfSYVNRD1b1BZVClcbpgF7tA_U4s,1864
|
102
|
-
lionagi-0.0.208.dist-info/LICENSE,sha256=TBnSyG8fs_tMRtK805GzA1cIyExleKyzoN_kuVxT9IY,11358
|
103
|
-
lionagi-0.0.208.dist-info/METADATA,sha256=4UDo6ioLE1sfEvzRdoMxDYgXB_N9-e9WR2bc94zul6A,17894
|
104
|
-
lionagi-0.0.208.dist-info/WHEEL,sha256=oiQVh_5PnQM0E3gPdiz09WCNmwiHDMaGer_elqB3coM,92
|
105
|
-
lionagi-0.0.208.dist-info/top_level.txt,sha256=szvch_d2jE1Lu9ZIKsl26Ll6BGfYfbOgt5lm-UpFSo4,8
|
106
|
-
lionagi-0.0.208.dist-info/RECORD,,
|
File without changes
|
File without changes
|
@@ -1,10 +1,10 @@
|
|
1
|
+
import json
|
1
2
|
from typing import Any, Dict, Optional
|
2
|
-
|
3
|
+
|
3
4
|
|
4
5
|
from lionagi.utils.sys_util import strip_lower
|
5
6
|
from lionagi.utils.nested_util import nget
|
6
|
-
|
7
|
-
import json
|
7
|
+
from lionagi.schema.base_node import BaseNode
|
8
8
|
|
9
9
|
|
10
10
|
class Message(BaseNode):
|
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
|