Ryzenth 1.9.2__py3-none-any.whl → 1.9.5__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.
Ryzenth/__init__.py CHANGED
@@ -19,8 +19,6 @@
19
19
 
20
20
  from . import *
21
21
  from .__version__ import __version__
22
- from ._client import ApiKeyFrom
22
+ from ._client import ApiKeyFrom, UrHellFrom
23
23
 
24
- __all__ = [
25
- "ApiKeyFrom"
26
- ]
24
+ __all__ = [ "ApiKeyFrom", "UrHellFrom"]
Ryzenth/__version__.py CHANGED
@@ -1,4 +1,4 @@
1
- __version__ = "1.9.2"
1
+ __version__ = "1.9.5"
2
2
  __author__ = "TeamKillerX"
3
3
  __title__ = "Ryzenth"
4
4
  __description__ = "Ryzenth Python API Wrapper"
Ryzenth/_asynchisded.py CHANGED
@@ -22,8 +22,8 @@ import logging
22
22
  import httpx
23
23
  from box import Box
24
24
 
25
- from Ryzenth._errors import WhatFuckError
26
- from Ryzenth.helper import (
25
+ from ._errors import WhatFuckError
26
+ from .helper import (
27
27
  FbanAsync,
28
28
  FontsAsync,
29
29
  ImagesAsync,
@@ -31,7 +31,7 @@ from Ryzenth.helper import (
31
31
  WhatAsync,
32
32
  WhisperAsync,
33
33
  )
34
- from Ryzenth.types import DownloaderBy, QueryParameter
34
+ from .types import DownloaderBy, QueryParameter
35
35
 
36
36
  LOGS = logging.getLogger("[Ryzenth] async")
37
37
 
Ryzenth/_client.py CHANGED
@@ -19,8 +19,9 @@
19
19
 
20
20
  import os
21
21
 
22
- from Ryzenth._asynchisded import RyzenthXAsync
23
- from Ryzenth._synchisded import RyzenthXSync
22
+ from ._asynchisded import RyzenthXAsync
23
+ from ._synchisded import RyzenthXSync
24
+ from .helper import Decorators
24
25
 
25
26
 
26
27
  class ApiKeyFrom:
@@ -41,3 +42,11 @@ class ApiKeyFrom:
41
42
 
42
43
  def something(self):
43
44
  pass
45
+
46
+ class UrHellFrom:
47
+ def __init__(self, name: str, only_author=False):
48
+ self.decorators = Decorators(ApiKeyFrom)
49
+ self.ai = self.decorators.send_ai(name=name, only_author=only_author)
50
+
51
+ def something(self):
52
+ pass
@@ -17,6 +17,7 @@
17
17
  # You should have received a copy of the GNU Affero General Public License
18
18
  # along with this program. If not, see <https://www.gnu.org/licenses/>.
19
19
 
20
+ from ._decorators import Decorators
20
21
  from ._federation import FbanAsync, FbanSync
21
22
  from ._fonts import FontsAsync, FontsSync
22
23
  from ._images import ImagesAsync, ImagesSync
@@ -36,5 +37,6 @@ __all__ = [
36
37
  "ModeratorAsync",
37
38
  "ModeratorSync",
38
39
  "FontsAsync",
39
- "FontsSync"
40
+ "FontsSync",
41
+ "Decorators"
40
42
  ]
@@ -0,0 +1,48 @@
1
+ #!/usr/bin/env python
2
+ # -*- coding: utf-8 -*-
3
+ # Copyright 2019-2025 (c) Randy W @xtdevs, @xtsea
4
+ #
5
+ # from : https://github.com/TeamKillerX
6
+ # Channel : @RendyProjects
7
+ # This program is free software: you can redistribute it and/or modify
8
+ # it under the terms of the GNU Affero General Public License as published by
9
+ # the Free Software Foundation, either version 3 of the License, or
10
+ # (at your option) any later version.
11
+ #
12
+ # This program is distributed in the hope that it will be useful,
13
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
+ # GNU Affero General Public License for more details.
16
+ #
17
+ # You should have received a copy of the GNU Affero General Public License
18
+ # along with this program. If not, see <https://www.gnu.org/licenses/>.
19
+
20
+ from functools import wraps
21
+
22
+ from ..types import QueryParameter
23
+
24
+
25
+ class Decorators:
26
+ def __init__(self, class_func):
27
+ self._clients_ai = class_func(..., is_free_from_ryzenth=True)
28
+
29
+ def send_ai(self, name: str, only_author=False):
30
+ def decorator(func):
31
+ @wraps(func)
32
+ async def wrapper(client, message, *args, **kwargs):
33
+ if only_author and message.from_user.id != client.me.id:
34
+ return await message.reply_text(
35
+ "Only Developer can use this command.", **kwargs
36
+ )
37
+ query = message.text.split(maxsplit=1)[1] if len(message.text.split()) > 1 else ""
38
+ if not query:
39
+ return await message.reply_text(
40
+ "Please provide a query after the command.", **kwargs
41
+ )
42
+ result = await self._clients_ai.aio.send_message(
43
+ name, QueryParameter(query=query), dot_access=True
44
+ )
45
+ await message.reply_text(result.results, **kwargs)
46
+ return await func(client, message, query, *args, **kwargs)
47
+ return wrapper
48
+ return decorator
@@ -21,7 +21,7 @@ import logging
21
21
 
22
22
  import httpx
23
23
 
24
- from Ryzenth._errors import WhatFuckError
24
+ from .._errors import WhatFuckError
25
25
 
26
26
  LOGS = logging.getLogger("[Ryzenth]")
27
27
 
Ryzenth/helper/_fonts.py CHANGED
@@ -17,13 +17,11 @@
17
17
  # You should have received a copy of the GNU Affero General Public License
18
18
  # along with this program. If not, see <https://www.gnu.org/licenses/>.
19
19
 
20
- import json
21
20
  import logging
22
- from datetime import datetime as dt
23
21
 
24
22
  import httpx
25
23
 
26
- from Ryzenth._errors import ParamsRequiredError, WhatFuckError
24
+ from .._errors import ParamsRequiredError, WhatFuckError
27
25
 
28
26
  LOGS = logging.getLogger("[Ryzenth]")
29
27
 
Ryzenth/helper/_images.py CHANGED
@@ -21,8 +21,8 @@ import logging
21
21
 
22
22
  import httpx
23
23
 
24
- from Ryzenth._errors import WhatFuckError
25
- from Ryzenth.types import QueryParameter
24
+ from .._errors import WhatFuckError
25
+ from ..types import QueryParameter
26
26
 
27
27
  LOGS = logging.getLogger("[Ryzenth]")
28
28
 
@@ -17,13 +17,11 @@
17
17
  # You should have received a copy of the GNU Affero General Public License
18
18
  # along with this program. If not, see <https://www.gnu.org/licenses/>.
19
19
 
20
- import json
21
20
  import logging
22
- from datetime import datetime as dt
23
21
 
24
22
  import httpx
25
23
 
26
- from Ryzenth._errors import InvalidEmptyError, InvalidVersionError, WhatFuckError
24
+ from .._errors import InvalidVersionError, WhatFuckError
27
25
 
28
26
  LOGS = logging.getLogger("[Ryzenth]")
29
27
 
Ryzenth/helper/_openai.py CHANGED
@@ -21,8 +21,8 @@ import logging
21
21
 
22
22
  import httpx
23
23
 
24
- from Ryzenth._errors import WhatFuckError
25
- from Ryzenth.types import OpenaiWhisper
24
+ from .._errors import WhatFuckError
25
+ from ..types import OpenaiWhisper
26
26
 
27
27
  LOGS = logging.getLogger("[Ryzenth]")
28
28
 
@@ -21,8 +21,8 @@ import logging
21
21
 
22
22
  import httpx
23
23
 
24
- from Ryzenth._errors import WhatFuckError
25
- from Ryzenth.types import QueryParameter
24
+ from .._errors import WhatFuckError
25
+ from ..types import QueryParameter
26
26
 
27
27
  LOGS = logging.getLogger("[Ryzenth]")
28
28
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: Ryzenth
3
- Version: 1.9.2
3
+ Version: 1.9.5
4
4
  Summary: Ryzenth Python Wrapper For Perfomance
5
5
  Author: TeamKillerX
6
6
  License: MIT
@@ -27,7 +27,6 @@ Requires-Dist: typing
27
27
  Requires-Dist: aiohttp
28
28
  Requires-Dist: httpx[http2]
29
29
  Requires-Dist: bs4
30
- Requires-Dist: uvloop
31
30
  Requires-Dist: python-box
32
31
  Provides-Extra: fast
33
32
  Requires-Dist: aiohttp; extra == "fast"
@@ -38,7 +37,6 @@ Requires-Dist: python-box; extra == "fast"
38
37
  Requires-Dist: pydantic; extra == "fast"
39
38
  Requires-Dist: bs4; extra == "fast"
40
39
  Requires-Dist: typing; extra == "fast"
41
- Requires-Dist: uvloop; extra == "fast"
42
40
  Dynamic: author
43
41
  Dynamic: classifier
44
42
  Dynamic: description
@@ -0,0 +1,20 @@
1
+ Ryzenth/__init__.py,sha256=tju93rICOKAx220Z2aSNLXt0HKVd5vRDfeVzrf49WuY,960
2
+ Ryzenth/__version__.py,sha256=GZ_mDGvbB3eoVmc5YXLSsgEoUlanzoUvVZoo3RpdJic,118
3
+ Ryzenth/_asynchisded.py,sha256=B44rz4JD4og3go1ZAcd4R8McxSt9vGo5zIpYtTRY3ms,4888
4
+ Ryzenth/_client.py,sha256=GLNDmDSq6ROiezaLdi-yo2tCWbgSxgpp1DXduxQHapA,1731
5
+ Ryzenth/_errors.py,sha256=PYHmA3xZPZnH8T1Yo0Al6ln2FP8KC9Jk3eN631ve2S4,1236
6
+ Ryzenth/_synchisded.py,sha256=KFO3Smy3qKhOPW9cVQ6uutspDZjiZz79hiLaXFgGRfA,4702
7
+ Ryzenth/helper/__init__.py,sha256=cFM6wA0fkC-KHkaL4jUK6_3zsm_TKpmz3BaW4HJgFiI,1360
8
+ Ryzenth/helper/_decorators.py,sha256=W9Y4N_ehmMYStcJJVsQr60WQsqHzON3n5uNuTp9yvGM,2041
9
+ Ryzenth/helper/_federation.py,sha256=hQ4XIha9j-ohUGmIJyD8HKWMFudBFU0iRLA-12qt_G0,13940
10
+ Ryzenth/helper/_fonts.py,sha256=i-1OlJwv_bTZL7Wewodajgotij5awSE04CNJyY_SXEs,3027
11
+ Ryzenth/helper/_images.py,sha256=bsCLycdlheqEc7I5jm_MVzscrNMX1Q_zmFWm3rhchA8,2297
12
+ Ryzenth/helper/_moderator.py,sha256=p7e1pRUTP8ROmFnRyNWSD5q65CQUKiavgp7yXCstLhk,5197
13
+ Ryzenth/helper/_openai.py,sha256=-VMH15PJXuYEu0UbwvlIus6NOsB-KNWBTMQvBU16EDU,2562
14
+ Ryzenth/helper/_thinking.py,sha256=4V2hH0FwegAGhmlO0YlAeXDH3DS4Omihf6m03YJc-SE,2545
15
+ Ryzenth/types/__init__.py,sha256=3eEOjoRcEPoE5J5oIhXEPH6vbYG7TLasTHFcbWGS-mU,1095
16
+ ryzenth-1.9.5.dist-info/licenses/LICENSE,sha256=C73aiGSgoCAVNzvAHs-TROaf5vV8yCj9nqpGrmfNHHo,1068
17
+ ryzenth-1.9.5.dist-info/METADATA,sha256=mU4rv5N9kyLt0KbYr86Dxzu12SUNeUoExz9Czp9miVs,4120
18
+ ryzenth-1.9.5.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
19
+ ryzenth-1.9.5.dist-info/top_level.txt,sha256=0vIhjOjoQuCxLeZO0of8VCx2jsri-bLHV28nh8wWDnc,8
20
+ ryzenth-1.9.5.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (80.7.1)
2
+ Generator: setuptools (80.9.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -1,19 +0,0 @@
1
- Ryzenth/__init__.py,sha256=CKayGQJ_ZUZF6OHyL9kCdTah05BUikXKWKXL_raAgo8,937
2
- Ryzenth/__version__.py,sha256=ffg5vyeznzjRb1MfQJLgPpJbOmE5CcUnTlYpJvKivpM,118
3
- Ryzenth/_asynchisded.py,sha256=ZNLp1rOJ_4SYcyMeB02ybsSmU38GO0TpHsQHRiR2w6c,4909
4
- Ryzenth/_client.py,sha256=Y-I1ug8Hf2eF74oDY4eICOTP_nuLXdsDSkyZhpdqZy4,1475
5
- Ryzenth/_errors.py,sha256=PYHmA3xZPZnH8T1Yo0Al6ln2FP8KC9Jk3eN631ve2S4,1236
6
- Ryzenth/_synchisded.py,sha256=KFO3Smy3qKhOPW9cVQ6uutspDZjiZz79hiLaXFgGRfA,4702
7
- Ryzenth/helper/__init__.py,sha256=ANx8vCXJ9ReLXIDWUwyhrIbw7jIyUXMdP11qotrWWIE,1308
8
- Ryzenth/helper/_federation.py,sha256=VM1mkuPj4SvlO-VcazIV0T5Ga56RdcpDo7qybXwFCow,13946
9
- Ryzenth/helper/_fonts.py,sha256=vQik0pGeKQGvUYhOfMO0W7MFM6Ig1oi-e_nBW_b6TuA,3081
10
- Ryzenth/helper/_images.py,sha256=AfNQoxae-yI76PDUa-jx7tWBlJa4tRZQFDjeqBLKwVM,2309
11
- Ryzenth/helper/_moderator.py,sha256=GTHTM8klfNrclhQM_gC0FHPLVmLj3n7NviOIX9Tr9bs,5270
12
- Ryzenth/helper/_openai.py,sha256=hUhmwxuKV-AAeEbDFm4RnkasHNJjFROLdw1q2j2t_Mc,2574
13
- Ryzenth/helper/_thinking.py,sha256=BKHvQe16KPOGh7_vev-_Ed8jl6_77_8Ys-g0SDtvlSU,2557
14
- Ryzenth/types/__init__.py,sha256=3eEOjoRcEPoE5J5oIhXEPH6vbYG7TLasTHFcbWGS-mU,1095
15
- ryzenth-1.9.2.dist-info/licenses/LICENSE,sha256=C73aiGSgoCAVNzvAHs-TROaf5vV8yCj9nqpGrmfNHHo,1068
16
- ryzenth-1.9.2.dist-info/METADATA,sha256=SH8DKw3TLkG_J1R4a533-vsBshXpGAEq8AxYqqt4thY,4181
17
- ryzenth-1.9.2.dist-info/WHEEL,sha256=Nw36Djuh_5VDukK0H78QzOX-_FQEo6V37m3nkm96gtU,91
18
- ryzenth-1.9.2.dist-info/top_level.txt,sha256=0vIhjOjoQuCxLeZO0of8VCx2jsri-bLHV28nh8wWDnc,8
19
- ryzenth-1.9.2.dist-info/RECORD,,