entari-plugin-hyw 0.3.5__py3-none-any.whl → 4.0.0rc14__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 entari-plugin-hyw might be problematic. Click here for more details.

Files changed (78) hide show
  1. entari_plugin_hyw/Untitled-1 +1865 -0
  2. entari_plugin_hyw/__init__.py +979 -116
  3. entari_plugin_hyw/filters.py +83 -0
  4. entari_plugin_hyw/history.py +251 -0
  5. entari_plugin_hyw/misc.py +214 -0
  6. entari_plugin_hyw/search_cache.py +154 -0
  7. entari_plugin_hyw-4.0.0rc14.dist-info/METADATA +118 -0
  8. entari_plugin_hyw-4.0.0rc14.dist-info/RECORD +72 -0
  9. {entari_plugin_hyw-0.3.5.dist-info → entari_plugin_hyw-4.0.0rc14.dist-info}/WHEEL +1 -1
  10. {entari_plugin_hyw-0.3.5.dist-info → entari_plugin_hyw-4.0.0rc14.dist-info}/top_level.txt +1 -0
  11. hyw_core/__init__.py +94 -0
  12. hyw_core/agent.py +768 -0
  13. hyw_core/browser_control/__init__.py +63 -0
  14. hyw_core/browser_control/assets/card-dist/index.html +425 -0
  15. hyw_core/browser_control/assets/card-dist/logos/anthropic.svg +1 -0
  16. hyw_core/browser_control/assets/card-dist/logos/cerebras.svg +9 -0
  17. hyw_core/browser_control/assets/card-dist/logos/deepseek.png +0 -0
  18. hyw_core/browser_control/assets/card-dist/logos/gemini.svg +1 -0
  19. hyw_core/browser_control/assets/card-dist/logos/google.svg +1 -0
  20. hyw_core/browser_control/assets/card-dist/logos/grok.png +0 -0
  21. hyw_core/browser_control/assets/card-dist/logos/huggingface.png +0 -0
  22. hyw_core/browser_control/assets/card-dist/logos/microsoft.svg +15 -0
  23. hyw_core/browser_control/assets/card-dist/logos/minimax.png +0 -0
  24. hyw_core/browser_control/assets/card-dist/logos/mistral.png +0 -0
  25. hyw_core/browser_control/assets/card-dist/logos/nvida.png +0 -0
  26. hyw_core/browser_control/assets/card-dist/logos/openai.svg +1 -0
  27. hyw_core/browser_control/assets/card-dist/logos/openrouter.png +0 -0
  28. hyw_core/browser_control/assets/card-dist/logos/perplexity.svg +24 -0
  29. hyw_core/browser_control/assets/card-dist/logos/qwen.png +0 -0
  30. hyw_core/browser_control/assets/card-dist/logos/xai.png +0 -0
  31. hyw_core/browser_control/assets/card-dist/logos/xiaomi.png +0 -0
  32. hyw_core/browser_control/assets/card-dist/logos/zai.png +0 -0
  33. hyw_core/browser_control/assets/card-dist/vite.svg +1 -0
  34. hyw_core/browser_control/assets/index.html +5691 -0
  35. hyw_core/browser_control/assets/logos/anthropic.svg +1 -0
  36. hyw_core/browser_control/assets/logos/cerebras.svg +9 -0
  37. hyw_core/browser_control/assets/logos/deepseek.png +0 -0
  38. hyw_core/browser_control/assets/logos/gemini.svg +1 -0
  39. hyw_core/browser_control/assets/logos/google.svg +1 -0
  40. hyw_core/browser_control/assets/logos/grok.png +0 -0
  41. hyw_core/browser_control/assets/logos/huggingface.png +0 -0
  42. hyw_core/browser_control/assets/logos/microsoft.svg +15 -0
  43. hyw_core/browser_control/assets/logos/minimax.png +0 -0
  44. hyw_core/browser_control/assets/logos/mistral.png +0 -0
  45. hyw_core/browser_control/assets/logos/nvida.png +0 -0
  46. hyw_core/browser_control/assets/logos/openai.svg +1 -0
  47. hyw_core/browser_control/assets/logos/openrouter.png +0 -0
  48. hyw_core/browser_control/assets/logos/perplexity.svg +24 -0
  49. hyw_core/browser_control/assets/logos/qwen.png +0 -0
  50. hyw_core/browser_control/assets/logos/xai.png +0 -0
  51. hyw_core/browser_control/assets/logos/xiaomi.png +0 -0
  52. hyw_core/browser_control/assets/logos/zai.png +0 -0
  53. hyw_core/browser_control/engines/__init__.py +15 -0
  54. hyw_core/browser_control/engines/base.py +13 -0
  55. hyw_core/browser_control/engines/default.py +166 -0
  56. hyw_core/browser_control/engines/duckduckgo.py +171 -0
  57. hyw_core/browser_control/landing.html +172 -0
  58. hyw_core/browser_control/manager.py +173 -0
  59. hyw_core/browser_control/renderer.py +446 -0
  60. hyw_core/browser_control/service.py +940 -0
  61. hyw_core/config.py +154 -0
  62. hyw_core/core.py +462 -0
  63. hyw_core/crawling/__init__.py +18 -0
  64. hyw_core/crawling/completeness.py +437 -0
  65. hyw_core/crawling/models.py +88 -0
  66. hyw_core/definitions.py +104 -0
  67. hyw_core/image_cache.py +274 -0
  68. hyw_core/pipeline.py +502 -0
  69. hyw_core/search.py +171 -0
  70. hyw_core/stages/__init__.py +21 -0
  71. hyw_core/stages/base.py +95 -0
  72. hyw_core/stages/summary.py +191 -0
  73. entari_plugin_hyw/agent.py +0 -419
  74. entari_plugin_hyw/compressor.py +0 -59
  75. entari_plugin_hyw/tools.py +0 -236
  76. entari_plugin_hyw/vision.py +0 -35
  77. entari_plugin_hyw-0.3.5.dist-info/METADATA +0 -112
  78. entari_plugin_hyw-0.3.5.dist-info/RECORD +0 -9
@@ -0,0 +1,154 @@
1
+ """
2
+ Search Result Cache
3
+
4
+ Caches search results in memory for 10 minutes to support
5
+ deep query operations on search results.
6
+ """
7
+
8
+ import time
9
+ from dataclasses import dataclass, field
10
+ from typing import Dict, List, Any, Optional
11
+
12
+
13
+ @dataclass
14
+ class CacheEntry:
15
+ """A cached search result entry."""
16
+ results: List[Dict[str, Any]]
17
+ query: str
18
+ timestamp: float = field(default_factory=time.time)
19
+
20
+
21
+ class SearchResultCache:
22
+ """
23
+ In-memory cache for search results with TTL-based expiration.
24
+
25
+ Cleanup is lazy - performed at the end of each request.
26
+ """
27
+
28
+ def __init__(self, ttl_seconds: float = 600.0): # 10 minutes default
29
+ self._cache: Dict[str, CacheEntry] = {}
30
+ self.ttl_seconds = ttl_seconds
31
+
32
+ def store(self, message_id: str, results: List[Dict[str, Any]], query: str):
33
+ """
34
+ Store search results associated with a message ID.
35
+
36
+ Args:
37
+ message_id: The sent message ID that contains the search results image
38
+ results: List of search result dicts with url, title, content, etc.
39
+ query: The original search query
40
+ """
41
+ self._cache[message_id] = CacheEntry(
42
+ results=results,
43
+ query=query,
44
+ timestamp=time.time()
45
+ )
46
+
47
+ def get(self, message_id: str) -> Optional[CacheEntry]:
48
+ """
49
+ Get cached search results for a message ID.
50
+
51
+ Returns None if not found or expired.
52
+ """
53
+ entry = self._cache.get(message_id)
54
+ if entry is None:
55
+ return None
56
+
57
+ # Check expiration
58
+ if time.time() - entry.timestamp > self.ttl_seconds:
59
+ del self._cache[message_id]
60
+ return None
61
+
62
+ return entry
63
+
64
+ def cleanup(self):
65
+ """
66
+ Remove all expired entries.
67
+
68
+ Called lazily at the end of each request.
69
+ """
70
+ now = time.time()
71
+ expired_keys = [
72
+ k for k, v in self._cache.items()
73
+ if now - v.timestamp > self.ttl_seconds
74
+ ]
75
+ for k in expired_keys:
76
+ del self._cache[k]
77
+
78
+ def __len__(self) -> int:
79
+ return len(self._cache)
80
+
81
+
82
+ def parse_single_index(text: str) -> Optional[int]:
83
+ """
84
+ Parse a single index from text like "1" or "3".
85
+
86
+ Args:
87
+ text: The text to parse
88
+
89
+ Returns:
90
+ 0-based index or None if not a valid single index
91
+ """
92
+ if not text:
93
+ return None
94
+ text = text.strip()
95
+ if text.isdigit():
96
+ idx = int(text)
97
+ if 1 <= idx <= 10: # 1-based, max 10 results
98
+ return idx - 1 # Convert to 0-based
99
+ return None
100
+
101
+
102
+ def parse_multi_indices(text: str, max_count: int = 3) -> Optional[List[int]]:
103
+ """
104
+ Parse multiple indices from text like "1-2", "1,2,3", "1、2、5".
105
+
106
+ Supports:
107
+ - Range: "1-2", "2-4"
108
+ - Comma separated: "1,2,3", "1, 2, 3"
109
+ - Chinese comma: "1、2、5"
110
+ - Space separated: "1 2 3"
111
+
112
+ Args:
113
+ text: The text to parse
114
+ max_count: Maximum number of indices allowed (default 3), returns None if exceeded
115
+
116
+ Returns:
117
+ List of 0-based indices, or None if empty/invalid/exceeds max_count
118
+ """
119
+ import re
120
+
121
+ if not text:
122
+ return None
123
+
124
+ text = text.strip()
125
+ if not text:
126
+ return None
127
+
128
+ indices = set()
129
+
130
+ # Check for range pattern: "1-3"
131
+ range_match = re.match(r'^(\d+)\s*[-–]\s*(\d+)$', text)
132
+ if range_match:
133
+ start, end = int(range_match.group(1)), int(range_match.group(2))
134
+ if 1 <= start <= 10 and 1 <= end <= 10 and start <= end:
135
+ indices.update(range(start - 1, end)) # 0-based
136
+ if len(indices) > max_count:
137
+ return None # Exceeds max
138
+ return sorted(indices)
139
+ return None
140
+
141
+ # Split by comma, Chinese comma, or space
142
+ parts = re.split(r'[,、\s]+', text)
143
+ for part in parts:
144
+ part = part.strip()
145
+ if part.isdigit():
146
+ idx = int(part)
147
+ if 1 <= idx <= 10:
148
+ indices.add(idx - 1) # 0-based
149
+
150
+ if indices:
151
+ if len(indices) > max_count:
152
+ return None # Exceeds max
153
+ return sorted(indices)
154
+ return None
@@ -0,0 +1,118 @@
1
+ Metadata-Version: 2.4
2
+ Name: entari_plugin_hyw
3
+ Version: 4.0.0rc14
4
+ Summary: Use large language models to interpret chat messages
5
+ Author-email: kumoSleeping <zjr2992@outlook.com>
6
+ License: MIT
7
+ Project-URL: Homepage, https://github.com/kumoSleeping/entari-plugin-hyw
8
+ Project-URL: Repository, https://github.com/kumoSleeping/entari-plugin-hyw
9
+ Project-URL: Issue Tracker, https://github.com/kumoSleeping/entari-plugin-hyw/issues
10
+ Keywords: entari,llm,ai,bot,chat
11
+ Classifier: Development Status :: 3 - Alpha
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: License :: OSI Approved :: MIT License
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Requires-Python: <3.13,>=3.10
18
+ Description-Content-Type: text/markdown
19
+ Requires-Dist: arclet-entari[full]>=0.16.5
20
+ Requires-Dist: openai
21
+ Requires-Dist: httpx
22
+ Requires-Dist: markdown>=3.10
23
+ Requires-Dist: DrissionPage>=4.1.1.2
24
+ Requires-Dist: trafilatura>=1.6.0
25
+ Requires-Dist: json-repair>=0.55.0
26
+ Provides-Extra: dev
27
+ Requires-Dist: entari-plugin-server>=0.5.0; extra == "dev"
28
+ Requires-Dist: satori-python-adapter-onebot11>=0.2.5; extra == "dev"
29
+ Requires-Dist: noneprompt; extra == "dev"
30
+ Requires-Dist: rich; extra == "dev"
31
+
32
+ # Entari Plugin HYW
33
+
34
+ [![PyPI version](https://badge.fury.io/py/entari-plugin-hyw.svg)](https://badge.fury.io/py/entari-plugin-hyw)
35
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
36
+ [![Python Versions](https://img.shields.io/pypi/pyversions/entari-plugin-hyw.svg)](https://pypi.org/project/entari-plugin-hyw/)
37
+
38
+ **English** | [简体中文](docs/README_CN.md)
39
+
40
+ **Entari Plugin HYW** is an advanced agentic chat plugin for the [Entari](https://github.com/entari-org/entari) framework. It leverages Large Language Models (LLMs) to provide intelligent, context-aware, and multi-modal responses within instant messaging environments (OneBot 11, Satori).
41
+
42
+ The plugin implements a three-stage pipeline (**Vision**, **Instruct**, **Agent**) to autonomously decide when to search the web, crawl pages, or analyze images to answer user queries effectively.
43
+
44
+ <p align="center">
45
+ <img src="docs/demo_mockup.svg" width="800" />
46
+ </p>
47
+
48
+ ## Features
49
+
50
+ - 📖 **Agentic Workflow**
51
+ Autonomous decision-making process to search, browse, and reason.
52
+
53
+ - 🎑 **Multi-Modal Support**
54
+ Native support for image analysis using Vision Language Models (VLMs).
55
+
56
+ - 🔍 **Web Search & Crawling**
57
+ Integrated **DuckDuckGo** and **Crawl4AI** for real-time information retrieval.
58
+
59
+ - 🎨 **Rich Rendering**
60
+ Responses are rendered as images containing Markdown, syntax-highlighted code, LaTeX math, and citation badges.
61
+
62
+ - 🔌 **Protocol Support**
63
+ Deep integration with OneBot 11 and Satori protocols, handling reply context and JSON cards perfectly.
64
+
65
+ ## Installation
66
+
67
+ ```bash
68
+ pip install entari-plugin-hyw
69
+ ```
70
+
71
+ ## Configuration
72
+
73
+ Configure the plugin in your `entari.yml`.
74
+
75
+ ### Minimal Configuration
76
+
77
+ ```yaml
78
+ plugins:
79
+ entari_plugin_hyw:
80
+ model_name: google/gemini-2.0-flash-exp
81
+ api_key: "your-or-api-key-here"
82
+ # Rendering Configuration
83
+ render_timeout_ms: 6000 # Browser wait timeout
84
+ render_image_timeout_ms: 3000 # Image load wait timeout
85
+ ```
86
+
87
+ ## Usage
88
+
89
+ ### Commands
90
+
91
+ - **Text Query**
92
+ ```text
93
+ /q What's the latest news on Rust 1.83?
94
+ ```
95
+
96
+ - **Image Analysis**
97
+ *(Send an image with command, or reply to an image)*
98
+ ```text
99
+ /q [Image] Explain this error.
100
+ ```
101
+ - **Quote Query**
102
+ ```text
103
+ [quote: User Message] /q
104
+ ```
105
+
106
+ - **Follow-up**
107
+ *Reply to the bot's message to continue the conversation.*
108
+
109
+ ## Documentation for AI/LLMs
110
+
111
+ - [Instruction Guide (English)](docs/README_LLM_EN.md)
112
+ - [指导手册 (简体中文)](docs/README_LLM_CN.md)
113
+
114
+ ---
115
+
116
+ ## License
117
+
118
+ This project is licensed under the MIT License.
@@ -0,0 +1,72 @@
1
+ entari_plugin_hyw/Untitled-1,sha256=wbsr5i9iorqBMIYK4aAnpNTek3mXbhvyo2YOYw38pE4,30187
2
+ entari_plugin_hyw/__init__.py,sha256=0q-i4F_xm--klgtp__r7cx_xPK7rV164aRzISEmVO7o,39053
3
+ entari_plugin_hyw/filters.py,sha256=sQnLaiqqZ2NkykcH4QgzFImP-JW3uVU7l6iuAAyUsJg,3080
4
+ entari_plugin_hyw/history.py,sha256=0XJwbfvXH5T1EPt4G1J5wWMJsKi0FfmajY5cvw8CQWE,12065
5
+ entari_plugin_hyw/misc.py,sha256=5IqF5Z2C_6Ufy5TI89uX5hX5fVYcXOTZIQUIu_tvf54,6855
6
+ entari_plugin_hyw/search_cache.py,sha256=7MIhTm5_YnZjc0aBaX7AE4AJp0VT8eU6ObR6mTkoerc,4285
7
+ hyw_core/__init__.py,sha256=Jlr9Ic-BLOPTnff6OctUCdjDMdK4nssTF_vHie4QKTo,1958
8
+ hyw_core/agent.py,sha256=lyGwJI0SiRGYdpPPL7mtzHj569UNIgm-s4P_xz1MNGc,33096
9
+ hyw_core/config.py,sha256=DHxwToUVLm1nT88gG05e3hVzSLxXMk9BjgjAnhGCADk,4918
10
+ hyw_core/core.py,sha256=_jN4831OeHQ_aM7sIlzcwYb5_Lp82kp2XmqpJD_tsLA,16097
11
+ hyw_core/definitions.py,sha256=pH46L-N25pSuPaIiN7l7yfoD6oHK6BLHigE0eYLFmJQ,4270
12
+ hyw_core/image_cache.py,sha256=t8pr1kgH2ngK9IhrBAhzUqhBWERNztUywMzgCFZEtQk,9899
13
+ hyw_core/pipeline.py,sha256=ZWwF0DHa29-65lUMU1_Fem3xQmxl7X_vgeni0ErOb8Q,22826
14
+ hyw_core/search.py,sha256=VvfNSb9Hf7ZQWlNtnZfYe2eO9qPjYtwJxVlud6OdeCQ,7787
15
+ hyw_core/browser_control/__init__.py,sha256=IeMErRC6fbq1PJWNK3klSbarSrUwOM4yyd_kJ6uWCPM,1406
16
+ hyw_core/browser_control/landing.html,sha256=wgqldumdylz69T83pvOkrigT1Mdb9GY0_KU0ceLGwdY,4642
17
+ hyw_core/browser_control/manager.py,sha256=-dHb0FamRsLfuU3jqX5cKaDo8DOOFV32zY912GuMdXU,6048
18
+ hyw_core/browser_control/renderer.py,sha256=s-QNIU-NMVQGLd_drLmeERgHsTm6C9XYm78CObt2KXc,17409
19
+ hyw_core/browser_control/service.py,sha256=_TcRRQuSei8PCsZs8hYU_DJ4DRMQ6jAFNqWmwca35Tc,43984
20
+ hyw_core/browser_control/assets/index.html,sha256=BpbM0vD9OYicE5MBHSVLo3j_y-MpULI82PMqmBKpWT8,2328623
21
+ hyw_core/browser_control/assets/card-dist/index.html,sha256=Xw-hQ5ctdQkK-1jV8_gqMdgVGNZDwWZvIAqNrh2eK7g,2210054
22
+ hyw_core/browser_control/assets/card-dist/vite.svg,sha256=SnSK_UQ5GLsWWRyDTEAdrjPoeGGrXbrQgRw6O0qSFPs,1497
23
+ hyw_core/browser_control/assets/card-dist/logos/anthropic.svg,sha256=ASsy1ypo3osNc3n-B0R81tk_dIFsVgg7qQORrd5T2kA,558
24
+ hyw_core/browser_control/assets/card-dist/logos/cerebras.svg,sha256=bpmiiYTODwc06knTmPj3GQ7NNtosMog5lkggvB_Z-7M,44166
25
+ hyw_core/browser_control/assets/card-dist/logos/deepseek.png,sha256=KWWAr9aeYMc6I07U_1qo7zcXO6e7-kfd9S2XjQumnf4,25338
26
+ hyw_core/browser_control/assets/card-dist/logos/gemini.svg,sha256=H74CoVmx5opcCtr3Ay3M09dpqL9cd9Whkx-M6an3t7s,599
27
+ hyw_core/browser_control/assets/card-dist/logos/google.svg,sha256=H74CoVmx5opcCtr3Ay3M09dpqL9cd9Whkx-M6an3t7s,599
28
+ hyw_core/browser_control/assets/card-dist/logos/grok.png,sha256=uSulvvDVqoA4RUOW0ZAkdvBVM2rpyGJRZIbn5dEFspw,362
29
+ hyw_core/browser_control/assets/card-dist/logos/huggingface.png,sha256=8eAudeftUDO11jf0coOscPeRkskCb7l9TNMx78q61mY,24564
30
+ hyw_core/browser_control/assets/card-dist/logos/microsoft.svg,sha256=-am_6N3UEQYSzldDg-xrdGYjTWsagH-3v4Q_eia1ymE,684
31
+ hyw_core/browser_control/assets/card-dist/logos/minimax.png,sha256=tWqVlMdFNPpP8zWWX9tvIsWXI9q76P7O3t3CEZO7NU0,1525
32
+ hyw_core/browser_control/assets/card-dist/logos/mistral.png,sha256=0vv7jPmPKiBRYVYYJxVL_wIH_qa_ZssIdV3NDO5vbmk,869
33
+ hyw_core/browser_control/assets/card-dist/logos/nvida.png,sha256=JMITdcyjR9Lz6Gub0n1_30d0ynvV1ZSCJRcjy23qgrA,1607
34
+ hyw_core/browser_control/assets/card-dist/logos/openai.svg,sha256=LhVwCR4qaXj6qHm31qniQTCkJ-FX932JLSycUis5kao,1692
35
+ hyw_core/browser_control/assets/card-dist/logos/openrouter.png,sha256=exxfjWGDWpYH-Vc8xJDbhNVeXFEVxnu6TMxYIBc1WmY,1665
36
+ hyw_core/browser_control/assets/card-dist/logos/perplexity.svg,sha256=mHWZFoeWmDYXOIDzm9pj6_sRotaI8xNy5Lkeg5Vzu70,555
37
+ hyw_core/browser_control/assets/card-dist/logos/qwen.png,sha256=eqLbnIPbjh2_PsODU_mmqjeD82xXj8fV_kN0fDrNaD0,38419
38
+ hyw_core/browser_control/assets/card-dist/logos/xai.png,sha256=uSulvvDVqoA4RUOW0ZAkdvBVM2rpyGJRZIbn5dEFspw,362
39
+ hyw_core/browser_control/assets/card-dist/logos/xiaomi.png,sha256=WHxlDFGU5FCjb-ure3ngdGG18-efYZUUfqA3_lqCUN0,4084
40
+ hyw_core/browser_control/assets/card-dist/logos/zai.png,sha256=K-gnabdsjMLInppHA1Op7Nyt33iegrx1x-yNlvCZ0Tc,2351
41
+ hyw_core/browser_control/assets/logos/anthropic.svg,sha256=ASsy1ypo3osNc3n-B0R81tk_dIFsVgg7qQORrd5T2kA,558
42
+ hyw_core/browser_control/assets/logos/cerebras.svg,sha256=bpmiiYTODwc06knTmPj3GQ7NNtosMog5lkggvB_Z-7M,44166
43
+ hyw_core/browser_control/assets/logos/deepseek.png,sha256=KWWAr9aeYMc6I07U_1qo7zcXO6e7-kfd9S2XjQumnf4,25338
44
+ hyw_core/browser_control/assets/logos/gemini.svg,sha256=H74CoVmx5opcCtr3Ay3M09dpqL9cd9Whkx-M6an3t7s,599
45
+ hyw_core/browser_control/assets/logos/google.svg,sha256=H74CoVmx5opcCtr3Ay3M09dpqL9cd9Whkx-M6an3t7s,599
46
+ hyw_core/browser_control/assets/logos/grok.png,sha256=uSulvvDVqoA4RUOW0ZAkdvBVM2rpyGJRZIbn5dEFspw,362
47
+ hyw_core/browser_control/assets/logos/huggingface.png,sha256=8eAudeftUDO11jf0coOscPeRkskCb7l9TNMx78q61mY,24564
48
+ hyw_core/browser_control/assets/logos/microsoft.svg,sha256=-am_6N3UEQYSzldDg-xrdGYjTWsagH-3v4Q_eia1ymE,684
49
+ hyw_core/browser_control/assets/logos/minimax.png,sha256=tWqVlMdFNPpP8zWWX9tvIsWXI9q76P7O3t3CEZO7NU0,1525
50
+ hyw_core/browser_control/assets/logos/mistral.png,sha256=0vv7jPmPKiBRYVYYJxVL_wIH_qa_ZssIdV3NDO5vbmk,869
51
+ hyw_core/browser_control/assets/logos/nvida.png,sha256=JMITdcyjR9Lz6Gub0n1_30d0ynvV1ZSCJRcjy23qgrA,1607
52
+ hyw_core/browser_control/assets/logos/openai.svg,sha256=LhVwCR4qaXj6qHm31qniQTCkJ-FX932JLSycUis5kao,1692
53
+ hyw_core/browser_control/assets/logos/openrouter.png,sha256=exxfjWGDWpYH-Vc8xJDbhNVeXFEVxnu6TMxYIBc1WmY,1665
54
+ hyw_core/browser_control/assets/logos/perplexity.svg,sha256=mHWZFoeWmDYXOIDzm9pj6_sRotaI8xNy5Lkeg5Vzu70,555
55
+ hyw_core/browser_control/assets/logos/qwen.png,sha256=eqLbnIPbjh2_PsODU_mmqjeD82xXj8fV_kN0fDrNaD0,38419
56
+ hyw_core/browser_control/assets/logos/xai.png,sha256=uSulvvDVqoA4RUOW0ZAkdvBVM2rpyGJRZIbn5dEFspw,362
57
+ hyw_core/browser_control/assets/logos/xiaomi.png,sha256=WHxlDFGU5FCjb-ure3ngdGG18-efYZUUfqA3_lqCUN0,4084
58
+ hyw_core/browser_control/assets/logos/zai.png,sha256=K-gnabdsjMLInppHA1Op7Nyt33iegrx1x-yNlvCZ0Tc,2351
59
+ hyw_core/browser_control/engines/__init__.py,sha256=01-jOjvtQcqWIwwY56ql3j00oSHGE2XhDHjkIi1Ij3Q,284
60
+ hyw_core/browser_control/engines/base.py,sha256=q5y4SM1G6xS7-6TQ-nZz9iTWw3XonjJn01fWzoTxr6c,414
61
+ hyw_core/browser_control/engines/default.py,sha256=BlHCQI4-rN9cEzLLfqvRD4bvhyP2G2KUGlo92J4kFNw,6092
62
+ hyw_core/browser_control/engines/duckduckgo.py,sha256=QVYj1I6Fw6--2-f3DYdHVlOmeLPzet9qG4HUT7ynrSE,6789
63
+ hyw_core/crawling/__init__.py,sha256=W5Be02uQueAyADFhPXVbDAFpNUJ_W7KdMtMr923_N24,437
64
+ hyw_core/crawling/completeness.py,sha256=OKdS8XlYYWDU1Vl1k-u7yEFqppukuJv-YQB0Px5KC2Q,16371
65
+ hyw_core/crawling/models.py,sha256=pCKe0k9xT3taSAlTlh0PazcLV0xYsm8p3XIkLHGf-LM,2353
66
+ hyw_core/stages/__init__.py,sha256=W89cWpq-HBLi2FprtJQSjQNLzpbhM8ZCkqPG61D_imE,521
67
+ hyw_core/stages/base.py,sha256=EfnTkISXbBNxjARykqIhmMrVqw2tqZl7ozJbJEbRnhI,2806
68
+ hyw_core/stages/summary.py,sha256=sgHCm_Leq_pkJ4YcgQuf8croiOP1oKz171TnzJwRwVs,7080
69
+ entari_plugin_hyw-4.0.0rc14.dist-info/METADATA,sha256=aOkMfm8FTTHNF_2ZkwNRw47sjLPlLNxu_MU8uoAFGX0,3845
70
+ entari_plugin_hyw-4.0.0rc14.dist-info/WHEEL,sha256=qELbo2s1Yzl39ZmrAibXA2jjPLUYfnVhUNTlyF1rq0Y,92
71
+ entari_plugin_hyw-4.0.0rc14.dist-info/top_level.txt,sha256=ah76OrufRX0okOl4Fv8MO6PXiT0IaZ1oG0eDrdAPoNo,27
72
+ entari_plugin_hyw-4.0.0rc14.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (80.9.0)
2
+ Generator: setuptools (80.10.1)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
hyw_core/__init__.py ADDED
@@ -0,0 +1,94 @@
1
+ """
2
+ hyw-core - Core LLM Pipeline and Browser Automation
3
+
4
+ This package provides:
5
+ - HywCore: Main service class with unified query interface
6
+ - HywCoreConfig: Configuration management with standalone/passthrough support
7
+ - QueryRequest/QueryResponse: Request/response data classes
8
+ - SearchService: Web search abstraction
9
+ - ModularPipeline: LLM pipeline orchestration
10
+ - browser_control: Browser automation subpackage
11
+
12
+ Usage:
13
+ from hyw_core import HywCore, HywCoreConfig, QueryRequest
14
+
15
+ # Standalone usage with YAML config
16
+ config = HywCoreConfig.from_yaml("config.yaml")
17
+ core = HywCore(config)
18
+
19
+ response = await core.query(QueryRequest(
20
+ user_input="What is Python?",
21
+ images=[],
22
+ conversation_history=[]
23
+ ))
24
+
25
+ # Passthrough from parent package
26
+ config = HywCoreConfig.from_dict({
27
+ "model_name": parent_config.model_name,
28
+ "api_key": parent_config.api_key,
29
+ ...
30
+ })
31
+ """
32
+
33
+ __version__ = "4.0.0-rc8"
34
+
35
+ # Core classes
36
+ from .core import HywCore, QueryRequest, QueryResponse
37
+
38
+ # Configuration
39
+ from .config import HywCoreConfig, ModelConfig
40
+
41
+ # Pipeline components
42
+ from .pipeline import ModularPipeline
43
+ from .search import SearchService
44
+
45
+ # Stage components
46
+ from .stages import (
47
+ BaseStage,
48
+ StageContext,
49
+ StageResult,
50
+
51
+ SummaryStage,
52
+ )
53
+
54
+ # Definitions
55
+ from .definitions import (
56
+ SUMMARY_REPORT_SP,
57
+ get_refuse_answer_tool,
58
+ )
59
+
60
+ # Browser control is available as subpackage
61
+ from . import browser_control
62
+
63
+ __all__ = [
64
+ # Version
65
+ "__version__",
66
+
67
+ # Core
68
+ "HywCore",
69
+ "QueryRequest",
70
+ "QueryResponse",
71
+
72
+ # Configuration
73
+ "HywCoreConfig",
74
+ "ModelConfig",
75
+
76
+ # Pipeline
77
+ "ModularPipeline",
78
+ "SearchService",
79
+
80
+ # Stages
81
+ "BaseStage",
82
+ "StageContext",
83
+ "StageResult",
84
+
85
+ "SummaryStage",
86
+
87
+ # Definitions
88
+ "SUMMARY_REPORT_SP",
89
+ "get_refuse_answer_tool",
90
+
91
+
92
+ # Subpackage
93
+ "browser_control",
94
+ ]