aiecs 1.0.0__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 aiecs might be problematic. Click here for more details.

Files changed (90) hide show
  1. aiecs/__init__.py +75 -0
  2. aiecs/__main__.py +41 -0
  3. aiecs/aiecs_client.py +295 -0
  4. aiecs/application/__init__.py +10 -0
  5. aiecs/application/executors/__init__.py +10 -0
  6. aiecs/application/executors/operation_executor.py +341 -0
  7. aiecs/config/__init__.py +15 -0
  8. aiecs/config/config.py +117 -0
  9. aiecs/config/registry.py +19 -0
  10. aiecs/core/__init__.py +46 -0
  11. aiecs/core/interface/__init__.py +34 -0
  12. aiecs/core/interface/execution_interface.py +150 -0
  13. aiecs/core/interface/storage_interface.py +214 -0
  14. aiecs/domain/__init__.py +20 -0
  15. aiecs/domain/context/__init__.py +28 -0
  16. aiecs/domain/context/content_engine.py +982 -0
  17. aiecs/domain/context/conversation_models.py +306 -0
  18. aiecs/domain/execution/__init__.py +12 -0
  19. aiecs/domain/execution/model.py +49 -0
  20. aiecs/domain/task/__init__.py +13 -0
  21. aiecs/domain/task/dsl_processor.py +460 -0
  22. aiecs/domain/task/model.py +50 -0
  23. aiecs/domain/task/task_context.py +257 -0
  24. aiecs/infrastructure/__init__.py +26 -0
  25. aiecs/infrastructure/messaging/__init__.py +13 -0
  26. aiecs/infrastructure/messaging/celery_task_manager.py +341 -0
  27. aiecs/infrastructure/messaging/websocket_manager.py +289 -0
  28. aiecs/infrastructure/monitoring/__init__.py +12 -0
  29. aiecs/infrastructure/monitoring/executor_metrics.py +138 -0
  30. aiecs/infrastructure/monitoring/structured_logger.py +50 -0
  31. aiecs/infrastructure/monitoring/tracing_manager.py +376 -0
  32. aiecs/infrastructure/persistence/__init__.py +12 -0
  33. aiecs/infrastructure/persistence/database_manager.py +286 -0
  34. aiecs/infrastructure/persistence/file_storage.py +671 -0
  35. aiecs/infrastructure/persistence/redis_client.py +162 -0
  36. aiecs/llm/__init__.py +54 -0
  37. aiecs/llm/base_client.py +99 -0
  38. aiecs/llm/client_factory.py +339 -0
  39. aiecs/llm/custom_callbacks.py +228 -0
  40. aiecs/llm/openai_client.py +125 -0
  41. aiecs/llm/vertex_client.py +186 -0
  42. aiecs/llm/xai_client.py +184 -0
  43. aiecs/main.py +351 -0
  44. aiecs/scripts/DEPENDENCY_SYSTEM_SUMMARY.md +241 -0
  45. aiecs/scripts/README_DEPENDENCY_CHECKER.md +309 -0
  46. aiecs/scripts/README_WEASEL_PATCH.md +126 -0
  47. aiecs/scripts/__init__.py +3 -0
  48. aiecs/scripts/dependency_checker.py +825 -0
  49. aiecs/scripts/dependency_fixer.py +348 -0
  50. aiecs/scripts/download_nlp_data.py +348 -0
  51. aiecs/scripts/fix_weasel_validator.py +121 -0
  52. aiecs/scripts/fix_weasel_validator.sh +82 -0
  53. aiecs/scripts/patch_weasel_library.sh +188 -0
  54. aiecs/scripts/quick_dependency_check.py +269 -0
  55. aiecs/scripts/run_weasel_patch.sh +41 -0
  56. aiecs/scripts/setup_nlp_data.sh +217 -0
  57. aiecs/tasks/__init__.py +2 -0
  58. aiecs/tasks/worker.py +111 -0
  59. aiecs/tools/__init__.py +196 -0
  60. aiecs/tools/base_tool.py +202 -0
  61. aiecs/tools/langchain_adapter.py +361 -0
  62. aiecs/tools/task_tools/__init__.py +82 -0
  63. aiecs/tools/task_tools/chart_tool.py +704 -0
  64. aiecs/tools/task_tools/classfire_tool.py +901 -0
  65. aiecs/tools/task_tools/image_tool.py +397 -0
  66. aiecs/tools/task_tools/office_tool.py +600 -0
  67. aiecs/tools/task_tools/pandas_tool.py +565 -0
  68. aiecs/tools/task_tools/report_tool.py +499 -0
  69. aiecs/tools/task_tools/research_tool.py +363 -0
  70. aiecs/tools/task_tools/scraper_tool.py +548 -0
  71. aiecs/tools/task_tools/search_api.py +7 -0
  72. aiecs/tools/task_tools/stats_tool.py +513 -0
  73. aiecs/tools/temp_file_manager.py +126 -0
  74. aiecs/tools/tool_executor/__init__.py +35 -0
  75. aiecs/tools/tool_executor/tool_executor.py +518 -0
  76. aiecs/utils/LLM_output_structor.py +409 -0
  77. aiecs/utils/__init__.py +23 -0
  78. aiecs/utils/base_callback.py +50 -0
  79. aiecs/utils/execution_utils.py +158 -0
  80. aiecs/utils/logging.py +1 -0
  81. aiecs/utils/prompt_loader.py +13 -0
  82. aiecs/utils/token_usage_repository.py +279 -0
  83. aiecs/ws/__init__.py +0 -0
  84. aiecs/ws/socket_server.py +41 -0
  85. aiecs-1.0.0.dist-info/METADATA +610 -0
  86. aiecs-1.0.0.dist-info/RECORD +90 -0
  87. aiecs-1.0.0.dist-info/WHEEL +5 -0
  88. aiecs-1.0.0.dist-info/entry_points.txt +7 -0
  89. aiecs-1.0.0.dist-info/licenses/LICENSE +225 -0
  90. aiecs-1.0.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,610 @@
1
+ Metadata-Version: 2.4
2
+ Name: aiecs
3
+ Version: 1.0.0
4
+ Summary: AI Execute Services - A middleware framework for AI-powered task execution and tool orchestration
5
+ Author-email: AIECS Team <iretbl@gmail.com>
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://github.com/aiecs-team/aiecs
8
+ Project-URL: Bug Tracker, https://github.com/aiecs-team/aiecs/issues
9
+ Project-URL: Documentation, https://aiecs.readthedocs.io
10
+ Keywords: ai,middleware,llm,orchestration,async,tools
11
+ Classifier: Development Status :: 4 - Beta
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.10
16
+ Classifier: Programming Language :: Python :: 3.11
17
+ Classifier: Programming Language :: Python :: 3.12
18
+ Classifier: Framework :: FastAPI
19
+ Classifier: Framework :: Celery
20
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
21
+ Requires-Python: <3.13,>=3.10
22
+ Description-Content-Type: text/markdown
23
+ License-File: LICENSE
24
+ Requires-Dist: fastapi<0.116.0,>=0.115.12
25
+ Requires-Dist: httpx<0.29.0,>=0.28.1
26
+ Requires-Dist: uvicorn[standard]<0.35.0,>=0.34.2
27
+ Requires-Dist: python-dotenv<2.0.0,>=1.1.0
28
+ Requires-Dist: pydantic<3.0.0,>=2.11.5
29
+ Requires-Dist: pydantic-settings<3.0.0,>=2.9.1
30
+ Requires-Dist: cachetools<6.0.0,>=5.0.0
31
+ Requires-Dist: typing-extensions<5.0.0,>=4.13.2
32
+ Requires-Dist: aiofiles<25.0.0,>=24.1.0
33
+ Requires-Dist: celery<6.0.0,>=5.5.2
34
+ Requires-Dist: redis<7.0.0,>=6.2.0
35
+ Requires-Dist: python-socketio<6.0.0,>=5.13.0
36
+ Requires-Dist: python-engineio<5.0.0,>=4.12.1
37
+ Requires-Dist: tenacity<10.0.0,>=9.1.2
38
+ Requires-Dist: flower<3.0.0,>=2.0.1
39
+ Requires-Dist: openai<1.76.0,>=1.68.2
40
+ Requires-Dist: google-cloud-aiplatform<2.0.0,>=1.71.1
41
+ Requires-Dist: langchain<0.4.0,>=0.3.26
42
+ Requires-Dist: langgraph<0.6.0,>=0.5.3
43
+ Requires-Dist: weasel==0.4.1
44
+ Requires-Dist: spacy<4.0.0,>=3.8.7
45
+ Requires-Dist: rake-nltk<2.0.0,>=1.0.6
46
+ Requires-Dist: numpy<3.0.0,>=2.2.6
47
+ Requires-Dist: pandas<3.0.0,>=2.2.3
48
+ Requires-Dist: scipy<2.0.0,>=1.15.3
49
+ Requires-Dist: scikit-learn<2.0.0,>=1.5.0
50
+ Requires-Dist: statsmodels<0.15.0,>=0.14.4
51
+ Requires-Dist: pyreadstat<2.0.0,>=1.2.9
52
+ Requires-Dist: tabulate<0.10.0,>=0.9.0
53
+ Requires-Dist: python-docx<2.0.0,>=1.1.2
54
+ Requires-Dist: python-pptx<2.0.0,>=1.0.2
55
+ Requires-Dist: openpyxl<4.0.0,>=3.1.5
56
+ Requires-Dist: pdfplumber<0.12.0,>=0.11.7
57
+ Requires-Dist: pdfminer-six==20250506
58
+ Requires-Dist: tika<3.0.0,>=2.6.0
59
+ Requires-Dist: matplotlib<4.0.0,>=3.10.3
60
+ Requires-Dist: seaborn<0.14.0,>=0.13.2
61
+ Requires-Dist: jinja2<4.0.0,>=3.1.6
62
+ Requires-Dist: beautifulsoup4<5.0.0,>=4.13.4
63
+ Requires-Dist: lxml<6.0.0,>=5.4.0
64
+ Requires-Dist: playwright<2.0.0,>=1.52.0
65
+ Requires-Dist: pytesseract<0.4.0,>=0.3.13
66
+ Requires-Dist: pillow<12.0.0,>=11.2.1
67
+ Requires-Dist: scrapy<3.0.0,>=2.13.3
68
+ Requires-Dist: pyyaml<7.0.0,>=6.0.2
69
+ Requires-Dist: markdown<4.0,>=3.8
70
+ Requires-Dist: bleach<7.0.0,>=6.2.0
71
+ Requires-Dist: sqlalchemy<3.0.0,>=2.0.41
72
+ Requires-Dist: asyncpg<1.0.0,>=0.30.0
73
+ Requires-Dist: prometheus-client<1.0.0,>=0.21.1
74
+ Requires-Dist: jaeger-client<5.0.0,>=4.8.0
75
+ Requires-Dist: opentracing<3.0.0,>=2.4.0
76
+ Requires-Dist: psutil<8.0.0,>=7.0.0
77
+ Provides-Extra: dev
78
+ Requires-Dist: pytest>=8.3.5; extra == "dev"
79
+ Requires-Dist: pytest-asyncio>=1.0.0; extra == "dev"
80
+ Requires-Dist: pytest-cov>=4.0.0; extra == "dev"
81
+ Requires-Dist: pytest-xdist>=3.0.0; extra == "dev"
82
+ Requires-Dist: pytest-mock>=3.10.0; extra == "dev"
83
+ Requires-Dist: black>=25.1.0; extra == "dev"
84
+ Requires-Dist: flake8>=7.2.0; extra == "dev"
85
+ Requires-Dist: mypy>=1.15.0; extra == "dev"
86
+ Requires-Dist: bump-pydantic>=0.8.0; extra == "dev"
87
+ Dynamic: license-file
88
+
89
+ # AIECS - AI Execute Services
90
+
91
+ [![Python Version](https://img.shields.io/badge/python-3.10%2B-blue.svg)](https://www.python.org/downloads/)
92
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
93
+ [![PyPI version](https://badge.fury.io/py/aiecs.svg)](https://badge.fury.io/py/aiecs)
94
+
95
+ AIECS (AI Execute Services) is a powerful Python middleware framework for building AI-powered applications with tool orchestration, task execution, and multi-provider LLM support.
96
+
97
+ ## Features
98
+
99
+ - **Multi-Provider LLM Support**: Seamlessly integrate with OpenAI, Google Vertex AI, and xAI
100
+ - **Tool Orchestration**: Extensible tool system for various tasks (web scraping, data analysis, document processing, etc.)
101
+ - **Asynchronous Task Execution**: Built on Celery for scalable task processing
102
+ - **Real-time Communication**: WebSocket support for live updates and progress tracking
103
+ - **Enterprise-Ready**: Production-grade architecture with PostgreSQL, Redis, and Google Cloud Storage integration
104
+ - **Extensible Architecture**: Easy to add custom tools and AI providers
105
+
106
+ ## Installation
107
+
108
+ ### From PyPI (Recommended)
109
+
110
+ ```bash
111
+ pip install aiecs
112
+ ```
113
+
114
+ ### From Source
115
+
116
+ ```bash
117
+ # Clone the repository
118
+ git clone https://github.com/aiecs-team/aiecs.git
119
+ cd aiecs
120
+
121
+ # Install in development mode
122
+ pip install -e .
123
+
124
+ # Or install with development dependencies
125
+ pip install -e ".[dev]"
126
+ ```
127
+
128
+ ### Post-Installation Setup
129
+
130
+ After installation, you can use the built-in tools to set up dependencies and verify your installation:
131
+
132
+ ```bash
133
+ # Check all dependencies
134
+ aiecs-check-deps
135
+
136
+ # Quick dependency check
137
+ aiecs-quick-check
138
+
139
+ # Download required NLP models and data
140
+ aiecs-download-nlp-data
141
+
142
+ # Fix common dependency issues automatically
143
+ aiecs-fix-deps
144
+
145
+ # Apply Weasel library patch (if needed)
146
+ aiecs-patch-weasel
147
+ ```
148
+
149
+ ## Quick Start
150
+
151
+ ### Basic Usage
152
+
153
+ ```python
154
+ from aiecs import AIECS
155
+ from aiecs.domain.task.task_context import TaskContext
156
+
157
+ # Initialize AIECS
158
+ aiecs = AIECS()
159
+
160
+ # Create a task context
161
+ context = TaskContext(
162
+ mode="execute",
163
+ service="default",
164
+ user_id="user123",
165
+ metadata={
166
+ "aiPreference": {
167
+ "provider": "OpenAI",
168
+ "model": "gpt-4"
169
+ }
170
+ },
171
+ data={
172
+ "task": "Analyze this text and extract key points",
173
+ "content": "Your text here..."
174
+ }
175
+ )
176
+
177
+ # Execute task
178
+ result = await aiecs.execute(context)
179
+ print(result)
180
+ ```
181
+
182
+ ### Using Tools
183
+
184
+ ```python
185
+ from aiecs.tools import get_tool
186
+
187
+ # Get a specific tool
188
+ scraper = get_tool("scraper_tool")
189
+
190
+ # Execute tool
191
+ result = await scraper.execute({
192
+ "url": "https://example.com",
193
+ "extract": ["title", "content"]
194
+ })
195
+ ```
196
+
197
+ ### Custom Tool Development
198
+
199
+ ```python
200
+ from aiecs.tools import register_tool
201
+ from aiecs.tools.base_tool import BaseTool
202
+
203
+ @register_tool("my_custom_tool")
204
+ class MyCustomTool(BaseTool):
205
+ """Custom tool for specific tasks"""
206
+
207
+ name = "my_custom_tool"
208
+ description = "Does something specific"
209
+
210
+ async def execute(self, params: dict) -> dict:
211
+ # Your tool logic here
212
+ return {"result": "success"}
213
+ ```
214
+
215
+ ## Configuration
216
+
217
+ Create a `.env` file with the following variables:
218
+
219
+ ```env
220
+ # LLM Providers
221
+ OPENAI_API_KEY=your_openai_key
222
+ VERTEX_PROJECT_ID=your_gcp_project
223
+ VERTEX_LOCATION=us-central1
224
+ GOOGLE_APPLICATION_CREDENTIALS=/path/to/credentials.json
225
+ XAI_API_KEY=your_xai_key
226
+
227
+ # Database
228
+ DB_HOST=localhost
229
+ DB_USER=postgres
230
+ DB_PASSWORD=your_password
231
+ DB_NAME=aiecs_db
232
+ DB_PORT=5432
233
+
234
+ # Redis (for Celery)
235
+ CELERY_BROKER_URL=redis://localhost:6379/0
236
+
237
+ # Google Cloud Storage
238
+ GOOGLE_CLOUD_PROJECT_ID=your_project_id
239
+ GOOGLE_CLOUD_STORAGE_BUCKET=your_bucket_name
240
+
241
+ # CORS
242
+ CORS_ALLOWED_ORIGINS=http://localhost:3000,https://yourdomain.com
243
+ ```
244
+
245
+ ## Command Line Tools
246
+
247
+ AIECS provides several command-line tools for setup and maintenance:
248
+
249
+ ### Dependency Management
250
+
251
+ ```bash
252
+ # Check all dependencies (comprehensive)
253
+ aiecs-check-deps
254
+
255
+ # Quick dependency check
256
+ aiecs-quick-check
257
+
258
+ # Automatically fix missing dependencies
259
+ aiecs-fix-deps --non-interactive
260
+
261
+ # Fix dependencies interactively (default)
262
+ aiecs-fix-deps
263
+ ```
264
+
265
+ ### Setup and Configuration
266
+
267
+ ```bash
268
+ # Download required NLP models and data
269
+ aiecs-download-nlp-data
270
+
271
+ # Apply Weasel library patch (fixes validator conflicts)
272
+ aiecs-patch-weasel
273
+ ```
274
+
275
+ ### Main Application
276
+
277
+ ```bash
278
+ # Start the AIECS server
279
+ aiecs
280
+
281
+ # Or start with custom configuration
282
+ aiecs --host 0.0.0.0 --port 8000
283
+ ```
284
+
285
+ ## Running as a Service
286
+
287
+ ### Start the API Server
288
+
289
+ ```bash
290
+ # Using the aiecs command (recommended)
291
+ aiecs
292
+
293
+ # Using uvicorn directly
294
+ uvicorn aiecs.main:app --host 0.0.0.0 --port 8000
295
+
296
+ # Or using the Python module
297
+ python -m aiecs
298
+ ```
299
+
300
+ ### Start Celery Workers
301
+
302
+ ```bash
303
+ # Start worker
304
+ celery -A aiecs.tasks.worker.celery_app worker --loglevel=info
305
+
306
+ # Start beat scheduler (for periodic tasks)
307
+ celery -A aiecs.tasks.worker.celery_app beat --loglevel=info
308
+
309
+ # Start Flower (Celery monitoring)
310
+ celery -A aiecs.tasks.worker.celery_app flower
311
+ ```
312
+
313
+ ## API Endpoints
314
+
315
+ - `GET /health` - Health check
316
+ - `GET /api/tools` - List available tools
317
+ - `GET /api/services` - List available AI services
318
+ - `GET /api/providers` - List LLM providers
319
+ - `POST /api/execute` - Execute a task
320
+ - `GET /api/task/{task_id}` - Get task status
321
+ - `DELETE /api/task/{task_id}` - Cancel a task
322
+
323
+ ## WebSocket Events
324
+
325
+ Connect to the WebSocket endpoint for real-time updates:
326
+
327
+ ```javascript
328
+ const socket = io('http://localhost:8000');
329
+
330
+ socket.on('connect', () => {
331
+ console.log('Connected to AIECS');
332
+
333
+ // Register user for updates
334
+ socket.emit('register', { user_id: 'user123' });
335
+ });
336
+
337
+ socket.on('progress', (data) => {
338
+ console.log('Task progress:', data);
339
+ });
340
+ ```
341
+
342
+ ## Available Tools
343
+
344
+ AIECS comes with a comprehensive set of pre-built tools:
345
+
346
+ - **Web Tools**: Web scraping, search API integration
347
+ - **Data Analysis**: Pandas operations, statistical analysis
348
+ - **Document Processing**: PDF, Word, PowerPoint handling
349
+ - **Image Processing**: OCR, image manipulation
350
+ - **Research Tools**: Academic research, report generation
351
+ - **Chart Generation**: Data visualization tools
352
+
353
+ ## Architecture
354
+
355
+ AIECS follows a clean architecture pattern with clear separation of concerns:
356
+
357
+ ```
358
+ aiecs/
359
+ ├── domain/ # Core business logic
360
+ ├── application/ # Use cases and application services
361
+ ├── infrastructure/ # External services and adapters
362
+ ├── llm/ # LLM provider implementations
363
+ ├── tools/ # Tool implementations
364
+ ├── config/ # Configuration management
365
+ └── main.py # FastAPI application entry point
366
+ ```
367
+
368
+ ## Development
369
+
370
+ ### Setting up Development Environment
371
+
372
+ ```bash
373
+ # Clone the repository
374
+ git clone https://github.com/yourusername/aiecs.git
375
+ cd aiecs
376
+
377
+ # Install dependencies
378
+ pip install -e ".[dev]"
379
+
380
+ # Run tests
381
+ pytest
382
+
383
+ # Run linting
384
+ flake8 aiecs/
385
+ mypy aiecs/
386
+ ```
387
+
388
+ ### Contributing
389
+
390
+ 1. Fork the repository
391
+ 2. Create a feature branch (`git checkout -b feature/amazing-feature`)
392
+ 3. Commit your changes (`git commit -m 'Add amazing feature'`)
393
+ 4. Push to the branch (`git push origin feature/amazing-feature`)
394
+ 5. Open a Pull Request
395
+
396
+ ## Troubleshooting
397
+
398
+ ### Common Issues
399
+
400
+ 1. **Missing Dependencies**: Use the built-in dependency checker and fixer:
401
+ ```bash
402
+ # Check what's missing
403
+ aiecs-check-deps
404
+
405
+ # Automatically fix issues
406
+ aiecs-fix-deps --non-interactive
407
+ ```
408
+
409
+ 2. **Weasel Library Validator Error**: If you encounter duplicate validator function errors:
410
+ ```bash
411
+ aiecs-patch-weasel
412
+ ```
413
+
414
+ 3. **Missing NLP Models**: Download required models and data:
415
+ ```bash
416
+ aiecs-download-nlp-data
417
+ ```
418
+
419
+ 4. **Database Connection Issues**: Ensure PostgreSQL is running and credentials are correct
420
+
421
+ 5. **Redis Connection Issues**: Verify Redis is running for Celery task queue
422
+
423
+ ### Dependency Check Output
424
+
425
+ The dependency checker provides detailed information about:
426
+ - ✅ Available dependencies
427
+ - ❌ Missing critical dependencies
428
+ - ⚠️ Missing optional dependencies
429
+ - 📦 System-level requirements
430
+ - 🤖 AI models and data files
431
+
432
+ Example output:
433
+ ```
434
+ 🔍 AIECS Quick Dependency Check
435
+ ==================================================
436
+
437
+ 📦 Critical Dependencies:
438
+ ✅ All critical dependencies are available
439
+
440
+ 🔧 Tool-Specific Dependencies:
441
+ ✅ Image Tool
442
+ ✅ Classfire Tool
443
+ ✅ Office Tool
444
+ ✅ Stats Tool
445
+ ✅ Report Tool
446
+ ✅ Scraper Tool
447
+
448
+ ✅ All dependencies are satisfied!
449
+ ```
450
+
451
+ ## Development and Packaging
452
+
453
+ ### Building the Package
454
+
455
+ To build the distribution packages:
456
+
457
+ ```bash
458
+ # Clean previous builds
459
+ rm -rf build/ dist/ *.egg-info/
460
+
461
+ # Build both wheel and source distribution
462
+ python3 -m build --sdist --wheel
463
+ ```
464
+
465
+ ### Environment Cleanup
466
+
467
+ For development and before releasing, you may want to clean up the environment completely. Here's the comprehensive cleanup process:
468
+
469
+ #### 1. Clean Python Cache and Build Files
470
+
471
+ ```bash
472
+ # Remove Python cache files
473
+ find . -name "__pycache__" -type d -exec rm -rf {} + 2>/dev/null || true
474
+ find . -name "*.pyc" -delete 2>/dev/null || true
475
+ find . -name "*.pyo" -delete 2>/dev/null || true
476
+
477
+ # Remove build and packaging artifacts
478
+ rm -rf build/ *.egg-info/ .eggs/
479
+
480
+ # Remove test and coverage cache
481
+ rm -rf .pytest_cache/ .coverage*
482
+ ```
483
+
484
+ #### 2. Clean Log and Temporary Files
485
+
486
+ ```bash
487
+ # Remove log files
488
+ rm -f *.log dependency_report.txt
489
+
490
+ # Remove temporary directories
491
+ rm -rf /tmp/wheel_*
492
+
493
+ # Remove backup files
494
+ find . -name "*.backup.*" -delete 2>/dev/null || true
495
+ ```
496
+
497
+ #### 3. Uninstall AIECS Package (if installed)
498
+
499
+ ```bash
500
+ # Uninstall the package completely
501
+ pip uninstall aiecs -y
502
+
503
+ # Verify removal
504
+ pip list | grep aiecs || echo "✅ aiecs package completely removed"
505
+ ```
506
+
507
+ #### 4. Clean Downloaded NLP Data and Models
508
+
509
+ If you've used the AIECS NLP tools, you may want to remove downloaded data:
510
+
511
+ ```bash
512
+ # Remove NLTK data (stopwords, punkt, wordnet, etc.)
513
+ rm -rf ~/nltk_data
514
+
515
+ # Remove spaCy models
516
+ pip uninstall en-core-web-sm zh-core-web-sm spacy-pkuseg -y 2>/dev/null || true
517
+
518
+ # Verify spaCy models removal
519
+ python3 -c "import spacy; print('spaCy models:', spacy.util.get_installed_models())" 2>/dev/null || echo "✅ spaCy models removed"
520
+ ```
521
+
522
+ #### 5. Complete Cleanup Script
523
+
524
+ For convenience, here's a complete cleanup script:
525
+
526
+ ```bash
527
+ #!/bin/bash
528
+ echo "🧹 Starting complete AIECS environment cleanup..."
529
+
530
+ # Python cache and build files
531
+ echo "📁 Cleaning Python cache and build files..."
532
+ find . -name "__pycache__" -type d -exec rm -rf {} + 2>/dev/null || true
533
+ find . -name "*.pyc" -delete 2>/dev/null || true
534
+ find . -name "*.pyo" -delete 2>/dev/null || true
535
+ rm -rf build/ *.egg-info/ .eggs/ .pytest_cache/ .coverage*
536
+
537
+ # Log and temporary files
538
+ echo "📝 Cleaning log and temporary files..."
539
+ rm -f *.log dependency_report.txt
540
+ rm -rf /tmp/wheel_*
541
+ find . -name "*.backup.*" -delete 2>/dev/null || true
542
+
543
+ # Uninstall package
544
+ echo "🗑️ Uninstalling AIECS package..."
545
+ pip uninstall aiecs -y 2>/dev/null || true
546
+
547
+ # Clean NLP data
548
+ echo "🤖 Cleaning NLP data and models..."
549
+ rm -rf ~/nltk_data
550
+ pip uninstall en-core-web-sm zh-core-web-sm spacy-pkuseg -y 2>/dev/null || true
551
+
552
+ # Verify final state
553
+ echo "✅ Cleanup complete! Final package state:"
554
+ ls -la dist/ 2>/dev/null || echo "No dist/ directory found"
555
+ echo "Environment is now clean and ready for release."
556
+ ```
557
+
558
+ #### What Gets Preserved
559
+
560
+ The cleanup process preserves:
561
+ - ✅ Source code files
562
+ - ✅ Test files and coverage reports (for maintenance)
563
+ - ✅ Configuration files (`.gitignore`, `pyproject.toml`, etc.)
564
+ - ✅ Documentation files
565
+ - ✅ Final distribution packages in `dist/`
566
+
567
+ #### What Gets Removed
568
+
569
+ The cleanup removes:
570
+ - ❌ Python cache files (`__pycache__/`, `*.pyc`)
571
+ - ❌ Build artifacts (`build/`, `*.egg-info/`)
572
+ - ❌ Log files (`*.log`, `dependency_report.txt`)
573
+ - ❌ Installed AIECS package and command-line tools
574
+ - ❌ Downloaded NLP data and models (~110MB)
575
+ - ❌ Temporary and backup files
576
+
577
+ ### Release Preparation
578
+
579
+ After cleanup, your `dist/` directory should contain only:
580
+
581
+ ```
582
+ dist/
583
+ ├── aiecs-1.0.0-py3-none-any.whl # Production-ready wheel package
584
+ └── aiecs-1.0.0.tar.gz # Production-ready source package
585
+ ```
586
+
587
+ These packages are ready for:
588
+ - PyPI publication: `twine upload dist/*`
589
+ - GitHub Releases
590
+ - Private repository distribution
591
+
592
+ ## License
593
+
594
+ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
595
+
596
+ ## Acknowledgments
597
+
598
+ - Built with FastAPI, Celery, and modern Python async patterns
599
+ - Integrates with leading AI providers
600
+ - Inspired by enterprise-grade middleware architectures
601
+
602
+ ## Support
603
+
604
+ - Documentation: [https://aiecs.readthedocs.io](https://aiecs.readthedocs.io)
605
+ - Issues: [GitHub Issues](https://github.com/yourusername/aiecs/issues)
606
+ - Discussions: [GitHub Discussions](https://github.com/yourusername/aiecs/discussions)
607
+
608
+ ---
609
+
610
+ Made with ❤️ by the AIECS Team
@@ -0,0 +1,90 @@
1
+ aiecs/__init__.py,sha256=KRDxAtJkyuZ6cJD8J_A_zgCpoBw8vM6ASGMyZodm-eM,1859
2
+ aiecs/__main__.py,sha256=AfQpzy3SgwWuP4DuymYcm4MISMuzqwhxxGSYo53PBvY,1035
3
+ aiecs/aiecs_client.py,sha256=gJbCY6zuHR9TZPCgHhxd-d4CwCW9P_lUrtTSC5-ADWE,10527
4
+ aiecs/main.py,sha256=Cqae4VgROn3F6kvrS9ggwjOkoFjorqNAUReDK33TGKM,9306
5
+ aiecs/application/__init__.py,sha256=NkmrUH1DqxJ3vaVC8QwscNdlWqHfC7ZagL4k3nZ_qz4,192
6
+ aiecs/application/executors/__init__.py,sha256=WIl7L9HBsEhNfbNtJdvBvFUJXzESvNZVaiAA6tdtJcs,191
7
+ aiecs/application/executors/operation_executor.py,sha256=-7mFo1hUnWdehVPg0fnSiRhW3LACpIiyLSH-iu7bX4U,13818
8
+ aiecs/config/__init__.py,sha256=HykU6FgZrUx0w8V1_kAjP9NpXZTddZ9M3xo0fmBwMU8,336
9
+ aiecs/config/config.py,sha256=vWkbWpRLxkRDdsl8hwgNpTKdvOhlxXiNh7oLQZBse-U,4993
10
+ aiecs/config/registry.py,sha256=5CPJcjeMu3FLc_keuCtJT60DtUxF6w-I68uIoxpcdq8,637
11
+ aiecs/core/__init__.py,sha256=H0ZIk96q0KHKivcobnUCVJdJZmewucVJ9MKhRgUxmk0,1037
12
+ aiecs/core/interface/__init__.py,sha256=soI7zdoN3eQynVb9uiwmgXkM5E75JYffTILktHb48x8,688
13
+ aiecs/core/interface/execution_interface.py,sha256=6bXruts8dyAg647lxPDQkF-cdJG1W8ZqpxFQ6hjVrd4,4810
14
+ aiecs/core/interface/storage_interface.py,sha256=F7GQEZ_ZiRWeen7oZO6A4S0nW0VORYsygk2BYLw5aiY,5680
15
+ aiecs/domain/__init__.py,sha256=a_cGb8TCaa-azcNpetGHvTFprPb6SlcJt-tfJ5GC2N8,397
16
+ aiecs/domain/context/__init__.py,sha256=ljKpQg1THBPRM61vVCEc97-bJl7z5qaP8pQs-lXlBzA,863
17
+ aiecs/domain/context/content_engine.py,sha256=1Ex2sMI7wRpFrvHE6srkk2JQBaNAau75ZzQVmSxEbIA,36045
18
+ aiecs/domain/context/conversation_models.py,sha256=HoxMXoZGyhMXbk8AcA-vMa-G--ulY4yew2VeGFHxgZU,13006
19
+ aiecs/domain/execution/__init__.py,sha256=usXYgPcS-j0CFBN5K1v1WuxQUHsgap3tsaZnDCcKVXs,216
20
+ aiecs/domain/execution/model.py,sha256=GEQLo8t6V4tvbY0mMuWb_YCNLfi809q_T_x16ZfoNQQ,1453
21
+ aiecs/domain/task/__init__.py,sha256=WtU0MPg3xpkKa4RUTbSEkppUxGdvn-ai_3UCRvMjLR8,226
22
+ aiecs/domain/task/dsl_processor.py,sha256=3QUxUK63BbUf1KG3ybcu_XkKXt-U8BuYvFjxDwVmpPs,20352
23
+ aiecs/domain/task/model.py,sha256=NLzXpNuVN1R08UP5wD--mnPi7CZEhvEVPbZCgpw2K2U,1670
24
+ aiecs/domain/task/task_context.py,sha256=waYuAKsdNZTg2orB_6cLbx0ZC-OBxvJLd-gj9bicKyY,10788
25
+ aiecs/infrastructure/__init__.py,sha256=dE-T4IQ0sQTekkMJGqX3HkaaWKJ4gSbq7IN1o8PMHYw,684
26
+ aiecs/infrastructure/messaging/__init__.py,sha256=KOEywSnktNWEN4O8_GE4KSopjMNEyfYhfUaTOkMxLUE,299
27
+ aiecs/infrastructure/messaging/celery_task_manager.py,sha256=yEKJdO_N9hYb3wlOnoVkBzWahvRj637tOkn4geIjPP0,12984
28
+ aiecs/infrastructure/messaging/websocket_manager.py,sha256=HhhLQw2hRV5Scc5HNMMZbAQGQp9QZBYPJQHulKwaeiI,11280
29
+ aiecs/infrastructure/monitoring/__init__.py,sha256=fQ13Q1MTIJTNlh35BSCqXpayCTM_kYvvPTMRzQfPymA,256
30
+ aiecs/infrastructure/monitoring/executor_metrics.py,sha256=z8KJpq6tfCOEArfR-YJ4UClTsef2mNMFuSDHrP51Aww,6040
31
+ aiecs/infrastructure/monitoring/structured_logger.py,sha256=iI895YHmPoaLdXjxHxd952PeTfGw6sh-yUDCnF8R7NY,1657
32
+ aiecs/infrastructure/monitoring/tracing_manager.py,sha256=g4u6paNCZCYdGDEMZiv4bYv_GTG0s8oug-BJgFmkDp0,13449
33
+ aiecs/infrastructure/persistence/__init__.py,sha256=7M0Z58QsSC6PJlZoLfBEiYQJh6t62P5QtwjiqBU0rEs,238
34
+ aiecs/infrastructure/persistence/database_manager.py,sha256=ryagZj92O_6yok23zep-IXYzRAUVKSs9Dc5ZljYHKd0,11793
35
+ aiecs/infrastructure/persistence/file_storage.py,sha256=d3tcV7Wg_-TGsbw3PY9ttNANntR5rIo7mBgE0CGXKZQ,23321
36
+ aiecs/infrastructure/persistence/redis_client.py,sha256=CqPtYFP8-KHl3cJG9VHun9YFFSp3kCc3ZaZbW7GlqUU,5791
37
+ aiecs/llm/__init__.py,sha256=EsOIu25eDnhEYKZDb1h_O9RxYIF7vaiORUZSUipzhsM,1084
38
+ aiecs/llm/base_client.py,sha256=xjirSGpLSsiWEhiTbKEFHNqbZanwJxBji9yVxegu77w,3193
39
+ aiecs/llm/client_factory.py,sha256=Ysa3NYJIwgqBfFomTfG-G8z3cIElLPcv_vFM4D1IyCc,13566
40
+ aiecs/llm/custom_callbacks.py,sha256=DyEbd1iSwiD8rN3cn96thCxFqk0JFwpBJLZdHijRv7I,9916
41
+ aiecs/llm/openai_client.py,sha256=Dmuo_91AiuM_57QuDiqkFdWFD3Jr-m4xJ89gKihivCs,4388
42
+ aiecs/llm/vertex_client.py,sha256=r_geBuF800g0CyUUAGmxYRjjTd9_X-H8rJ1vGeIvZ6U,8592
43
+ aiecs/llm/xai_client.py,sha256=CMCDdHh7uBGlFdYqTo4EKp7ZenjZIawtL5oWVVvLVCY,6800
44
+ aiecs/scripts/DEPENDENCY_SYSTEM_SUMMARY.md,sha256=K6V1Ugbxx-I-2w1GfS9y7wA4Spgb0mvC3qApBfUgpoc,5865
45
+ aiecs/scripts/README_DEPENDENCY_CHECKER.md,sha256=pE-ISxRycwUvn2EZeOzbtfSTVQPs2ui-_PGJAR50JRQ,6002
46
+ aiecs/scripts/README_WEASEL_PATCH.md,sha256=h0e3Xy6FArLgjika3pRZRhZRbyuj6iLzTU-AhHkWE7M,3581
47
+ aiecs/scripts/__init__.py,sha256=cVxQ5iqym520eDQSpV7B6hWolndCLMOVdvhC_D280PE,66
48
+ aiecs/scripts/dependency_checker.py,sha256=VKvUAkua7IdskGBf5pipf9b0cet_2jZariecQzXnh-c,32647
49
+ aiecs/scripts/dependency_fixer.py,sha256=0X8Eojf9N0yba2znEYrIwa7kWCKzZbV1OlnRwlrjq-Y,13961
50
+ aiecs/scripts/download_nlp_data.py,sha256=P2ObKS2P7oGCQU257mByU8Ca4-UXpfH8ZrgOUYT12Ys,10985
51
+ aiecs/scripts/fix_weasel_validator.py,sha256=w_s2VTIAgWPi-3VUXlrINBkLm9765QHdRf4g5RzBUug,4073
52
+ aiecs/scripts/fix_weasel_validator.sh,sha256=XqV3Yx1wi23dWXDbofFK6_SU0BVLr9E1HaIudIuem7Q,2736
53
+ aiecs/scripts/patch_weasel_library.sh,sha256=5mF6G2uL_K5zU4Sgf28W3c3-JI5lR-xuVk181LtWdVc,5489
54
+ aiecs/scripts/quick_dependency_check.py,sha256=-Foin8lz6LN6pV6Gxzd3N7UcQA9_rkM3SJdQLErA8uU,9827
55
+ aiecs/scripts/run_weasel_patch.sh,sha256=bwyFyeaITwDmG2_3HsTd7PHeexahh6MhEZwUuAC_85c,1233
56
+ aiecs/scripts/setup_nlp_data.sh,sha256=CqO-bLVc_mLhNpsSoXZjvJKhtLUbA_gYBqfp3nzUuRI,5843
57
+ aiecs/tasks/__init__.py,sha256=__xkKqXWQ24FkySb8xtsCCJYLKnqmHKbAnojxeELEiE,90
58
+ aiecs/tasks/worker.py,sha256=5cBeP2IyvwDe6tIhkiv6LfyQz41IFZ1S3Fr6IdNKP6Q,4298
59
+ aiecs/tools/__init__.py,sha256=LwXSVLYP67Sa6fYpVSYPaUF5tvbX4I9zm3cW2JGHI1U,6285
60
+ aiecs/tools/base_tool.py,sha256=1dndT1M5PAU3Cw-gE9vAIKACiq6na6CAUPIefAeALc4,6901
61
+ aiecs/tools/langchain_adapter.py,sha256=Yn8kOuaF8hoXAYBWUSfagHbzF8ecvQGbYrp-q0E3b_E,13316
62
+ aiecs/tools/temp_file_manager.py,sha256=_ipPCMKT5twYjtLJucOnhIyqtKEtSquKqx-xasKu_ks,4679
63
+ aiecs/tools/task_tools/__init__.py,sha256=hzsGoRmqX_gZcutXKynCLi6esBPXCx--cRkZVxaXAIA,2693
64
+ aiecs/tools/task_tools/chart_tool.py,sha256=C7fM8WvBkyQgNCg5xGndXUF6nNfY7lQjYj8l9DnPAq0,26442
65
+ aiecs/tools/task_tools/classfire_tool.py,sha256=UKlnRD3KjbU3ZhWuplP6BTuv6wcjt-7XBftlGZF6hcE,31950
66
+ aiecs/tools/task_tools/image_tool.py,sha256=0VgFSKIeX4tXge7GnJQoouvECjJJQmRBIn0aponlrMg,15024
67
+ aiecs/tools/task_tools/office_tool.py,sha256=FW9EUnCHmT_YiT9wfWrbgvmaOrALXYNJrqI2bvEu6lM,23169
68
+ aiecs/tools/task_tools/pandas_tool.py,sha256=762Nz-2s3l5sdDXFRriK2F22I_k_nkELaX1sDAtCpwk,24892
69
+ aiecs/tools/task_tools/report_tool.py,sha256=ZoETHFpO3UOD_JH7LBZZlyZY8A7DHHgSbYY8QPT95Wk,23567
70
+ aiecs/tools/task_tools/research_tool.py,sha256=JXPmC5Gg2SbZWG56e3fkZo-lYgG3h_XfYJUjEtXOceQ,15557
71
+ aiecs/tools/task_tools/scraper_tool.py,sha256=tlnPYFgS_Nbil05yuTZsooggDU1B3nnQ3LhA9pT8ffY,24712
72
+ aiecs/tools/task_tools/search_api.py,sha256=NIqZE5jaEKUIGTjSToxYzVfTB4xMmFX4yYNgp5tOm_w,217
73
+ aiecs/tools/task_tools/stats_tool.py,sha256=IUAhs5wUi1dknEha8twCT_m3MF4ZTqod3TDAFslfaF8,24300
74
+ aiecs/tools/tool_executor/__init__.py,sha256=gxuujSlQFj8DQ9ejCisO_cYqk5GQkJnwv0sJERd80CM,711
75
+ aiecs/tools/tool_executor/tool_executor.py,sha256=fuoKQahLBgRT6AQbHuOCLzG53w4UAD-QTraGjraEEsw,19496
76
+ aiecs/utils/LLM_output_structor.py,sha256=zKkOhrg6smToD0NTCqj3OepBQDTZXgPK4VsKJEFgxyg,15793
77
+ aiecs/utils/__init__.py,sha256=PkukDzRaeeAJUmfm9vA9ez1l3tjvhDRnWZCqzWI6nNw,562
78
+ aiecs/utils/base_callback.py,sha256=UpNrOZZ1RCmiVPnuhjFNde_m29yWg1ID16vzfzBMk7U,1661
79
+ aiecs/utils/execution_utils.py,sha256=uQoUcLKAbmkcMhucdhngrAfeXE6DvuG26qIx4wyx2fo,5871
80
+ aiecs/utils/logging.py,sha256=kvZ9OjFChfLN_2MEGvIDBK3trPAhikkh87rK49vN3bU,29
81
+ aiecs/utils/prompt_loader.py,sha256=cBS2bZXpYQOWSiOGkhwIzyy3_bETqwIblRi_9qQT9iQ,423
82
+ aiecs/utils/token_usage_repository.py,sha256=cSu2lQq7obNrjYBdtvqkCeWeApscHVcYa9JNgl3T3gU,10206
83
+ aiecs/ws/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
84
+ aiecs/ws/socket_server.py,sha256=j_9idVY_rWlTsF51FgmuhWCWFVt7_gAHL8vNg3IxV5g,1476
85
+ aiecs-1.0.0.dist-info/licenses/LICENSE,sha256=_1YRaIS0eZu1pv6xfz245UkU0i1Va2B841hv3OWRwqg,12494
86
+ aiecs-1.0.0.dist-info/METADATA,sha256=Xze89EZqwZMCyqauhsOZb-Ss3RtLsUsV7vmyXsH87_A,16388
87
+ aiecs-1.0.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
88
+ aiecs-1.0.0.dist-info/entry_points.txt,sha256=0Bj2pSaZM-ADKTktbCQ0KQxRe0s8mQFKVsg3IGDJGqA,342
89
+ aiecs-1.0.0.dist-info/top_level.txt,sha256=22IlUlOqh9Ni3jXlQNMNUqzbW8dcxXPeR_EQ-BJVcV8,6
90
+ aiecs-1.0.0.dist-info/RECORD,,
@@ -0,0 +1,5 @@
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (80.9.0)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+