webscout 6.4__py3-none-any.whl → 6.6__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.

Potentially problematic release.


This version of webscout might be problematic. Click here for more details.

Files changed (116) hide show
  1. webscout/AIutel.py +7 -54
  2. webscout/DWEBS.py +48 -26
  3. webscout/{YTdownloader.py → Extra/YTToolkit/YTdownloader.py} +990 -1103
  4. webscout/Extra/YTToolkit/__init__.py +3 -0
  5. webscout/{transcriber.py → Extra/YTToolkit/transcriber.py} +1 -1
  6. webscout/Extra/YTToolkit/ytapi/__init__.py +6 -0
  7. webscout/Extra/YTToolkit/ytapi/channel.py +307 -0
  8. webscout/Extra/YTToolkit/ytapi/errors.py +13 -0
  9. webscout/Extra/YTToolkit/ytapi/extras.py +45 -0
  10. webscout/Extra/YTToolkit/ytapi/https.py +88 -0
  11. webscout/Extra/YTToolkit/ytapi/patterns.py +61 -0
  12. webscout/Extra/YTToolkit/ytapi/playlist.py +59 -0
  13. webscout/Extra/YTToolkit/ytapi/pool.py +8 -0
  14. webscout/Extra/YTToolkit/ytapi/query.py +37 -0
  15. webscout/Extra/YTToolkit/ytapi/stream.py +60 -0
  16. webscout/Extra/YTToolkit/ytapi/utils.py +62 -0
  17. webscout/Extra/YTToolkit/ytapi/video.py +102 -0
  18. webscout/Extra/__init__.py +2 -1
  19. webscout/Extra/autocoder/autocoder_utiles.py +119 -101
  20. webscout/Extra/autocoder/rawdog.py +679 -680
  21. webscout/Extra/gguf.py +441 -441
  22. webscout/Extra/markdownlite/__init__.py +862 -0
  23. webscout/Extra/weather_ascii.py +2 -2
  24. webscout/Provider/AISEARCH/__init__.py +2 -0
  25. webscout/Provider/AISEARCH/ooai.py +155 -0
  26. webscout/Provider/Amigo.py +70 -85
  27. webscout/Provider/{prefind.py → Jadve.py} +72 -70
  28. webscout/Provider/Netwrck.py +235 -0
  29. webscout/Provider/Openai.py +4 -3
  30. webscout/Provider/PI.py +292 -221
  31. webscout/Provider/PizzaGPT.py +3 -3
  32. webscout/Provider/Reka.py +0 -1
  33. webscout/Provider/TTS/__init__.py +5 -1
  34. webscout/Provider/TTS/deepgram.py +183 -0
  35. webscout/Provider/TTS/elevenlabs.py +137 -0
  36. webscout/Provider/TTS/gesserit.py +151 -0
  37. webscout/Provider/TTS/murfai.py +139 -0
  38. webscout/Provider/TTS/parler.py +134 -107
  39. webscout/Provider/TTS/streamElements.py +360 -275
  40. webscout/Provider/TTS/utils.py +280 -0
  41. webscout/Provider/TTS/voicepod.py +116 -116
  42. webscout/Provider/TeachAnything.py +15 -2
  43. webscout/Provider/Youchat.py +42 -8
  44. webscout/Provider/__init__.py +8 -21
  45. webscout/Provider/meta.py +794 -779
  46. webscout/Provider/multichat.py +230 -0
  47. webscout/Provider/promptrefine.py +2 -2
  48. webscout/Provider/talkai.py +10 -13
  49. webscout/Provider/turboseek.py +5 -4
  50. webscout/Provider/tutorai.py +8 -112
  51. webscout/Provider/typegpt.py +5 -7
  52. webscout/Provider/x0gpt.py +81 -9
  53. webscout/Provider/yep.py +123 -361
  54. webscout/__init__.py +33 -28
  55. webscout/conversation.py +24 -9
  56. webscout/exceptions.py +188 -20
  57. webscout/litprinter/__init__.py +719 -831
  58. webscout/litprinter/colors.py +54 -0
  59. webscout/optimizers.py +420 -270
  60. webscout/prompt_manager.py +279 -279
  61. webscout/scout/__init__.py +8 -0
  62. webscout/scout/core/__init__.py +7 -0
  63. webscout/scout/core/crawler.py +140 -0
  64. webscout/scout/core/scout.py +571 -0
  65. webscout/scout/core/search_result.py +96 -0
  66. webscout/scout/core/text_analyzer.py +63 -0
  67. webscout/scout/core/text_utils.py +277 -0
  68. webscout/scout/core/web_analyzer.py +52 -0
  69. webscout/scout/core.py +884 -0
  70. webscout/scout/element.py +460 -0
  71. webscout/scout/parsers/__init__.py +69 -0
  72. webscout/scout/parsers/html5lib_parser.py +172 -0
  73. webscout/scout/parsers/html_parser.py +236 -0
  74. webscout/scout/parsers/lxml_parser.py +178 -0
  75. webscout/scout/utils.py +38 -0
  76. webscout/update_checker.py +184 -125
  77. webscout/version.py +1 -1
  78. webscout/zeroart/__init__.py +55 -0
  79. webscout/zeroart/base.py +60 -0
  80. webscout/zeroart/effects.py +99 -0
  81. webscout/zeroart/fonts.py +816 -0
  82. webscout/zerodir/__init__.py +225 -0
  83. {webscout-6.4.dist-info → webscout-6.6.dist-info}/METADATA +18 -231
  84. webscout-6.6.dist-info/RECORD +197 -0
  85. webscout-6.6.dist-info/top_level.txt +2 -0
  86. webstoken/__init__.py +30 -0
  87. webstoken/classifier.py +189 -0
  88. webstoken/keywords.py +216 -0
  89. webstoken/language.py +128 -0
  90. webstoken/ner.py +164 -0
  91. webstoken/normalizer.py +35 -0
  92. webstoken/processor.py +77 -0
  93. webstoken/sentiment.py +206 -0
  94. webstoken/stemmer.py +73 -0
  95. webstoken/t.py +75 -0
  96. webstoken/tagger.py +60 -0
  97. webstoken/tokenizer.py +158 -0
  98. webscout/Agents/Onlinesearcher.py +0 -182
  99. webscout/Agents/__init__.py +0 -2
  100. webscout/Agents/functioncall.py +0 -248
  101. webscout/Bing_search.py +0 -251
  102. webscout/Provider/Perplexity.py +0 -599
  103. webscout/Provider/RoboCoders.py +0 -206
  104. webscout/Provider/genspark.py +0 -225
  105. webscout/Provider/perplexitylabs.py +0 -265
  106. webscout/Provider/twitterclone.py +0 -251
  107. webscout/Provider/upstage.py +0 -230
  108. webscout/gpt4free.py +0 -666
  109. webscout/requestsHTMLfix.py +0 -775
  110. webscout/webai.py +0 -2590
  111. webscout-6.4.dist-info/RECORD +0 -154
  112. webscout-6.4.dist-info/top_level.txt +0 -1
  113. /webscout/Provider/{felo_search.py → AISEARCH/felo_search.py} +0 -0
  114. {webscout-6.4.dist-info → webscout-6.6.dist-info}/LICENSE.md +0 -0
  115. {webscout-6.4.dist-info → webscout-6.6.dist-info}/WHEEL +0 -0
  116. {webscout-6.4.dist-info → webscout-6.6.dist-info}/entry_points.txt +0 -0
@@ -1,125 +1,184 @@
1
- """
2
- Webscout Update Checker
3
- A utility to check and compare Webscout versions
4
- """
5
-
6
- import requests
7
- import re
8
- import subprocess
9
- import sys
10
- import os
11
- from packaging import version
12
- from typing import Optional
13
-
14
- from webscout.Litlogger import LitLogger, LogFormat, ColorScheme
15
-
16
- # Initialize logger with custom format
17
- CUSTOM_FORMAT = """{message}"""
18
-
19
- logger = LitLogger(
20
- name="WebscoutUpdate",
21
- format=CUSTOM_FORMAT,
22
- color_scheme=ColorScheme.OCEAN,
23
- level_styles={
24
- "TRACE": "DIM",
25
- "DEBUG": "NORMAL",
26
- "INFO": "BOLD",
27
- "SUCCESS": "BOLD",
28
- "WARNING": "BOLD",
29
- "ERROR": "BOLD",
30
- "CRITICAL": "BOLD"
31
- }
32
- )
33
-
34
- def get_installed_version() -> Optional[str]:
35
- """Get the installed version of webscout"""
36
- try:
37
- import importlib.metadata
38
- return importlib.metadata.version('webscout')
39
- except ImportError:
40
- try:
41
- import pkg_resources
42
- return pkg_resources.get_distribution('webscout').version
43
- except Exception:
44
- logger.error("Could not determine installed version using pkg_resources")
45
- return None
46
- except Exception:
47
- logger.error("Could not determine installed version using importlib.metadata")
48
- return None
49
-
50
- def get_webscout_version() -> Optional[str]:
51
- """Get the current webscout version from CLI"""
52
- try:
53
- result = subprocess.run(['webscout', '--version'],
54
- capture_output=True,
55
- text=True,
56
- timeout=5)
57
- if result.returncode == 0:
58
- version_match = re.search(r'\d+\.\d+\.\d+', result.stdout)
59
- if version_match:
60
- return version_match.group(0)
61
- except (subprocess.TimeoutExpired, subprocess.SubprocessError, FileNotFoundError) as e:
62
- logger.error(f"Failed to get version from CLI: {str(e)}")
63
- return None
64
-
65
- def get_pypi_version() -> Optional[str]:
66
- """Get the latest version from PyPI"""
67
- try:
68
- response = requests.get(
69
- "https://pypi.org/pypi/webscout/json",
70
- timeout=10
71
- )
72
- response.raise_for_status()
73
- return response.json()['info']['version']
74
- except requests.RequestException as e:
75
- logger.error(f"Failed to fetch PyPI version: {str(e)}")
76
- except (KeyError, ValueError) as e:
77
- logger.error(f"Failed to parse PyPI response: {str(e)}")
78
- return None
79
-
80
- def version_compare(v1: str, v2: str) -> int:
81
- """Compare two version strings"""
82
- try:
83
- return -1 if version.parse(v1) < version.parse(v2) else 1
84
- except version.InvalidVersion:
85
- return 0
86
-
87
- def display_version_info(installed: Optional[str], current: Optional[str], latest: Optional[str]) -> None:
88
- """Display version information"""
89
- if installed:
90
- logger.info(f"Currently using Webscout version {installed}")
91
-
92
- if latest and installed:
93
- if version_compare(installed, latest) < 0:
94
- logger.warning(
95
- f"A new version of Webscout is available: {latest}\n"
96
- f"To update, run: pip install --upgrade webscout"
97
- )
98
- else:
99
- logger.success("You're running the latest version!")
100
-
101
- def check_for_updates() -> None:
102
- """Check for Webscout updates"""
103
- logger.info("Checking for Webscout updates...")
104
-
105
- installed_version = get_installed_version()
106
- current_version = get_webscout_version()
107
- latest_version = get_pypi_version()
108
-
109
- if not installed_version:
110
- logger.error("Could not determine installed Webscout version")
111
- return
112
-
113
- if not latest_version:
114
- logger.error("Could not determine latest Webscout version from PyPI")
115
- return
116
-
117
- display_version_info(installed_version, current_version, latest_version)
118
-
119
- if __name__ == "__main__":
120
- try:
121
- check_for_updates()
122
- except KeyboardInterrupt:
123
- logger.warning("Update check cancelled by user")
124
- except Exception as e:
125
- logger.error(f"An unexpected error occurred: {str(e)}")
1
+ """
2
+ Ayy, check it out! 👀
3
+ >>> from webscout import check_for_updates
4
+ >>> check_for_updates()
5
+ 'Yo, new Webscout version just dropped: 2.0.0! 🔥
6
+ Level up with: `pip install --upgrade webscout`'
7
+ """
8
+
9
+ import subprocess
10
+ import sys
11
+ import os
12
+ from typing import Optional
13
+
14
+ import requests
15
+ from packaging import version
16
+ import re
17
+
18
+ from webscout import LitLogger, ColorScheme
19
+ from importlib.metadata import version as get_package_version
20
+ from importlib.metadata import PackageNotFoundError
21
+ from importlib.metadata import metadata as get_package_metadata
22
+
23
+ # Setting up that clean logger format, no cap! 💯
24
+ CUSTOM_FORMAT = """{message}"""
25
+
26
+ logger = LitLogger(
27
+ name="WebscoutUpdate",
28
+ format=CUSTOM_FORMAT,
29
+ color_scheme=ColorScheme.OCEAN,
30
+ level_styles={
31
+ "TRACE": "DIM",
32
+ "DEBUG": "NORMAL",
33
+ "INFO": "BOLD",
34
+ "SUCCESS": "BOLD",
35
+ "WARNING": "BOLD",
36
+ "ERROR": "BOLD",
37
+ "CRITICAL": "BOLD"
38
+ }
39
+ )
40
+
41
+ def get_installed_version() -> Optional[str]:
42
+ """Yo, let's check what version you're running! 🔍
43
+
44
+ What this function's all about:
45
+ - Checking your setup real quick 💨
46
+ - Getting them version deets 📱
47
+ - Handling any problems like a boss 💪
48
+
49
+ Returns:
50
+ Optional[str]: Your version number or None if we can't find it
51
+
52
+ Examples:
53
+ >>> version = get_installed_version()
54
+ >>> print(version)
55
+ '1.2.3'
56
+ """
57
+ try:
58
+ return get_package_version('webscout')
59
+ except PackageNotFoundError:
60
+ return None
61
+ except Exception as e:
62
+ return None
63
+
64
+ def get_pypi_version() -> Optional[str]:
65
+ """Let's see what's fresh on PyPI! 🚀
66
+
67
+ This function's vibe:
68
+ - Hitting up PyPI for the latest drop 🌐
69
+ - Keeping it smooth with timeout handling ⚡
70
+ - Making sure we get good data fr fr 💯
71
+
72
+ Returns:
73
+ Optional[str]: Latest version or None if something's not right
74
+
75
+ Examples:
76
+ >>> latest = get_pypi_version()
77
+ >>> print(latest)
78
+ '2.0.0'
79
+ """
80
+ try:
81
+ response = requests.get(
82
+ "https://pypi.org/pypi/webscout/json",
83
+ timeout=10
84
+ )
85
+ response.raise_for_status()
86
+ return response.json()['info']['version']
87
+ except requests.RequestException as e:
88
+ pass
89
+ except (KeyError, ValueError) as e:
90
+ pass
91
+ except Exception as e:
92
+ pass
93
+ return None
94
+
95
+ def version_compare(v1: str, v2: str) -> int:
96
+ """Time to compare these versions! 💪
97
+
98
+ Args:
99
+ v1: First version we checking
100
+ v2: Second version to compare with
101
+
102
+ Returns:
103
+ int: -1 if v1's older, 1 if v1's newer, 0 if they twins
104
+
105
+ Examples:
106
+ >>> version_compare('1.0.0', '2.0.0')
107
+ -1
108
+ """
109
+ try:
110
+ version1 = version.parse(v1)
111
+ version2 = version.parse(v2)
112
+ if version1 < version2:
113
+ return -1
114
+ if version1 > version2:
115
+ return 1
116
+ return 0
117
+ except version.InvalidVersion as e:
118
+ pass
119
+ return 0
120
+ except Exception as e:
121
+ pass
122
+ return 0
123
+
124
+ def display_version_info(installed: Optional[str], latest: Optional[str]) -> None:
125
+ """Let's break down your version status! 📱
126
+
127
+ What we doing here:
128
+ - Comparing your version with the latest drop 🔄
129
+ - Letting you know if you need to level up ⬆️
130
+ - Keeping you in the loop with style 💯
131
+
132
+ Args:
133
+ installed: What you running rn
134
+ latest: What's fresh out there
135
+
136
+ Examples:
137
+ >>> display_version_info('1.0.0', '2.0.0')
138
+ 'Yo, new Webscout version just dropped: 2.0.0! 🔥'
139
+ """
140
+ if installed:
141
+ pass
142
+
143
+ if latest and installed:
144
+ comparison_result = version_compare(installed, latest)
145
+ if comparison_result < 0:
146
+ logger.warning(
147
+ f"Yo, new Webscout version just dropped: {latest}! 🔥\n"
148
+ f"Level up with: `pip install --upgrade webscout`"
149
+ )
150
+ elif comparison_result > 0:
151
+ logger.success("You already got the latest version, no cap! 💯")
152
+
153
+ def check_for_updates() -> None:
154
+ """Time to check if you're running the latest! 🚀
155
+
156
+ What we doing:
157
+ - Peeking at your current setup 📱
158
+ - Checking what's new out there 🌐
159
+ - Keeping you updated fr fr ⚡
160
+
161
+ Examples:
162
+ >>> check_for_updates()
163
+ # We got you with them version checks fam!
164
+ """
165
+ installed_version = get_installed_version()
166
+ latest_version = get_pypi_version()
167
+
168
+ if not installed_version:
169
+ pass
170
+ return
171
+
172
+ if not latest_version:
173
+ pass
174
+ return
175
+
176
+ display_version_info(installed_version, latest_version)
177
+
178
+ if __name__ == "__main__":
179
+ try:
180
+ check_for_updates()
181
+ except KeyboardInterrupt:
182
+ logger.warning("Update check got cancelled, no worries fam! 🤚")
183
+ except Exception as e:
184
+ logger.error(f"Uh oh, something went wrong: {str(e)} 😔")
webscout/version.py CHANGED
@@ -1,2 +1,2 @@
1
- __version__ = "6.4"
1
+ __version__ = "6.6"
2
2
  __prog__ = "webscout"
@@ -0,0 +1,55 @@
1
+ """
2
+ ZeroArt: A zero-dependency ASCII art text generator
3
+
4
+ Create awesome ASCII art text without external dependencies!
5
+ """
6
+
7
+ from .base import ZeroArtFont
8
+ from .fonts import BlockFont, SlantFont, NeonFont, CyberFont
9
+ from .effects import AsciiArtEffects
10
+
11
+ def figlet_format(text, font='block'):
12
+ """
13
+ Generate ASCII art text
14
+
15
+ :param text: Text to convert
16
+ :param font: Font style (default: 'block')
17
+ :return: ASCII art representation of text
18
+ """
19
+ font_map = {
20
+ 'block': BlockFont(),
21
+ 'slant': SlantFont(),
22
+ 'neon': NeonFont(),
23
+ 'cyber': CyberFont()
24
+ }
25
+
26
+ selected_font = font_map.get(font.lower(), BlockFont())
27
+ return selected_font.render(text)
28
+
29
+ def print_figlet(text, font='block'):
30
+ """
31
+ Print ASCII art text directly
32
+
33
+ :param text: Text to convert and print
34
+ :param font: Font style (default: 'block')
35
+ """
36
+ print(figlet_format(text, font))
37
+
38
+ # Expose additional effects
39
+ rainbow = AsciiArtEffects.rainbow_effect
40
+ glitch = AsciiArtEffects.glitch_effect
41
+ wrap_text = AsciiArtEffects.wrap_text
42
+ outline = AsciiArtEffects.outline_effect
43
+
44
+ __all__ = [
45
+ 'figlet_format',
46
+ 'print_figlet',
47
+ 'rainbow',
48
+ 'glitch',
49
+ 'wrap_text',
50
+ 'outline',
51
+ 'BlockFont',
52
+ 'SlantFont',
53
+ 'NeonFont',
54
+ 'CyberFont'
55
+ ]
@@ -0,0 +1,60 @@
1
+ """
2
+ ZeroArt Base: Core classes and utilities for ASCII art generation
3
+ """
4
+
5
+ class ZeroArtFont:
6
+ """Base class for ASCII art fonts"""
7
+ def __init__(self, name):
8
+ self.name = name
9
+ self.letters = {}
10
+ self.special_chars = {}
11
+
12
+ def add_letter(self, char, art_lines):
13
+ """
14
+ Add a custom letter to the font
15
+
16
+ :param char: Character to add
17
+ :param art_lines: List of art lines representing the character
18
+ """
19
+ self.letters[char.upper()] = art_lines
20
+
21
+ def add_special_char(self, name, art_lines):
22
+ """
23
+ Add a special ASCII art character or design
24
+
25
+ :param name: Name of the special character
26
+ :param art_lines: List of art lines representing the character
27
+ """
28
+ self.special_chars[name] = art_lines
29
+
30
+ def get_letter(self, char):
31
+ """
32
+ Get ASCII art for a specific character
33
+
34
+ :param char: Character to retrieve
35
+ :return: List of art lines or default space
36
+ """
37
+ return self.letters.get(char.upper(), self.letters.get(' ', [' ']))
38
+
39
+ def render(self, text):
40
+ if not text:
41
+ return ""
42
+
43
+ # Get the maximum height of any character in the font
44
+ max_height = max(len(self.get_letter(c)) for c in text)
45
+
46
+ # Initialize art_lines with empty strings
47
+ art_lines = ["" for _ in range(max_height)]
48
+
49
+ # Process each character
50
+ for char in text:
51
+ char_art = self.get_letter(char)
52
+ # Pad shorter characters with empty lines to match max_height
53
+ while len(char_art) < max_height:
54
+ char_art.append(" " * len(char_art[0]))
55
+
56
+ # Add character art to each line
57
+ for i in range(max_height):
58
+ art_lines[i] += char_art[i] + " "
59
+
60
+ return "\n".join(art_lines)
@@ -0,0 +1,99 @@
1
+ """
2
+ ZeroArt Effects: ASCII art text effects and transformations
3
+ """
4
+
5
+ import random
6
+ import textwrap
7
+
8
+ class AsciiArtEffects:
9
+ """Collection of ASCII art text effects"""
10
+
11
+ @staticmethod
12
+ def rainbow_effect(text, font):
13
+ """
14
+ Apply a rainbow-like color effect to ASCII art
15
+
16
+ :param text: Text to render
17
+ :param font: Font to use
18
+ :return: Rainbow-styled ASCII art
19
+ """
20
+ colors = [
21
+ '\033[91m', # Red
22
+ '\033[93m', # Yellow
23
+ '\033[92m', # Green
24
+ '\033[94m', # Blue
25
+ '\033[95m', # Magenta
26
+ ]
27
+
28
+ art = font.render(text)
29
+ art_lines = art.split('\n')
30
+
31
+ colored_lines = []
32
+ for line in art_lines:
33
+ colored_line = ''
34
+ for char in line:
35
+ color = random.choice(colors)
36
+ colored_line += color + char
37
+ colored_lines.append(colored_line + '\033[0m') # Reset color
38
+
39
+ return '\n'.join(colored_lines)
40
+
41
+ @staticmethod
42
+ def glitch_effect(text, font, glitch_intensity=0.1):
43
+ """
44
+ Apply a glitch-like distortion to ASCII art
45
+
46
+ :param text: Text to render
47
+ :param font: Font to use
48
+ :param glitch_intensity: Probability of character distortion
49
+ :return: Glitched ASCII art
50
+ """
51
+ art = font.render(text)
52
+ art_lines = art.split('\n')
53
+
54
+ glitched_lines = []
55
+ glitch_chars = ['~', '^', '`', '¯', '±']
56
+
57
+ for line in art_lines:
58
+ glitched_line = ''
59
+ for char in line:
60
+ if random.random() < glitch_intensity:
61
+ glitched_line += random.choice(glitch_chars)
62
+ else:
63
+ glitched_line += char
64
+ glitched_lines.append(glitched_line)
65
+
66
+ return '\n'.join(glitched_lines)
67
+
68
+ @staticmethod
69
+ def wrap_text(text, width=20):
70
+ """
71
+ Wrap ASCII art text to a specific width
72
+
73
+ :param text: Text to wrap
74
+ :param width: Maximum line width
75
+ :return: Wrapped text
76
+ """
77
+ return textwrap.fill(text, width=width)
78
+
79
+ @staticmethod
80
+ def outline_effect(text, font, outline_char='*'):
81
+ """
82
+ Add an outline effect to ASCII art
83
+
84
+ :param text: Text to render
85
+ :param font: Font to use
86
+ :param outline_char: Character to use for outline
87
+ :return: ASCII art with outline
88
+ """
89
+ art = font.render(text)
90
+ art_lines = art.split('\n')
91
+
92
+ outlined_lines = []
93
+ for line in art_lines:
94
+ outlined_line = outline_char + line + outline_char
95
+ outlined_lines.append(outlined_line)
96
+
97
+ top_bottom_line = outline_char * (len(outlined_lines[0]))
98
+
99
+ return '\n'.join([top_bottom_line] + outlined_lines + [top_bottom_line])