mcp-souschef 3.5.2__py3-none-any.whl → 4.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.
- {mcp_souschef-3.5.2.dist-info → mcp_souschef-4.0.0.dist-info}/METADATA +136 -8
- {mcp_souschef-3.5.2.dist-info → mcp_souschef-4.0.0.dist-info}/RECORD +17 -10
- souschef/core/ai_schemas.py +6 -1
- souschef/github/__init__.py +17 -0
- souschef/github/agent_control.py +459 -0
- souschef/server.py +193 -0
- souschef/storage/__init__.py +39 -0
- souschef/storage/blob.py +331 -0
- souschef/storage/config.py +163 -0
- souschef/storage/database.py +1182 -0
- souschef/ui/app.py +17 -4
- souschef/ui/pages/chef_server_settings.py +411 -2
- souschef/ui/pages/cookbook_analysis.py +352 -6
- souschef/ui/pages/history.py +964 -0
- {mcp_souschef-3.5.2.dist-info → mcp_souschef-4.0.0.dist-info}/WHEEL +0 -0
- {mcp_souschef-3.5.2.dist-info → mcp_souschef-4.0.0.dist-info}/entry_points.txt +0 -0
- {mcp_souschef-3.5.2.dist-info → mcp_souschef-4.0.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mcp-souschef
|
|
3
|
-
Version:
|
|
3
|
+
Version: 4.0.0
|
|
4
4
|
Summary: AI-powered MCP server for Chef to Ansible conversion
|
|
5
5
|
License: MIT
|
|
6
6
|
License-File: LICENSE
|
|
@@ -23,13 +23,16 @@ Classifier: Topic :: System :: Systems Administration
|
|
|
23
23
|
Classifier: Topic :: Utilities
|
|
24
24
|
Provides-Extra: ai
|
|
25
25
|
Provides-Extra: all
|
|
26
|
+
Provides-Extra: storage
|
|
26
27
|
Provides-Extra: ui
|
|
27
28
|
Requires-Dist: anthropic (>=0.75.0) ; extra == "ai" or extra == "all"
|
|
29
|
+
Requires-Dist: boto3 (>=1.26.0) ; extra == "storage" or extra == "all"
|
|
28
30
|
Requires-Dist: click (>=8.1.0)
|
|
29
31
|
Requires-Dist: mcp (>=1.25.0)
|
|
30
32
|
Requires-Dist: openai (>=1.0.0) ; extra == "ai" or extra == "all"
|
|
31
33
|
Requires-Dist: pandas (>=2.0.0) ; extra == "ui" or extra == "all"
|
|
32
34
|
Requires-Dist: plotly (>=5.17.0,<7.0) ; extra == "ui" or extra == "all"
|
|
35
|
+
Requires-Dist: psycopg[binary] (>=3.1.19) ; extra == "storage" or extra == "all"
|
|
33
36
|
Requires-Dist: pydantic (>=2.0.0)
|
|
34
37
|
Requires-Dist: python-dotenv (>=1.2.1)
|
|
35
38
|
Requires-Dist: pyyaml (>=6.0.0)
|
|
@@ -56,17 +59,17 @@ An AI-powered MCP (Model Context Protocol) server that provides comprehensive Ch
|
|
|
56
59
|
|
|
57
60
|
## Overview - Chef to Ansible features
|
|
58
61
|
|
|
59
|
-
SousChef is a complete enterprise-grade migration platform with **
|
|
62
|
+
SousChef is a complete enterprise-grade migration platform with **40 primary MCP tools** organised across **12 major capability areas** to facilitate Chef-to-Ansible AWX/AAP migrations. From cookbook analysis to deployment pattern conversion, including Chef Habitat to containerised deployments, Chef Server integration, CI/CD pipeline generation, and GitHub Copilot agent control, SousChef provides everything needed for a successful infrastructure automation migration.
|
|
60
63
|
|
|
61
64
|
### About Tool Counts
|
|
62
65
|
|
|
63
|
-
**Why
|
|
66
|
+
**Why 40 tools in the documentation but more in the server?**
|
|
64
67
|
|
|
65
|
-
The MCP server provides **
|
|
68
|
+
The MCP server provides **43 total tools**. This documentation focuses on the **40 primary user-facing tools** that cover the main migration capabilities. The remaining 3 tools are low-level filesystem operations used internally by the main tools.
|
|
66
69
|
|
|
67
70
|
As a user, you'll primarily interact with the documented tools. Your AI assistant may use the additional tools automatically when needed, but you don't need to know about them for successful migrations.
|
|
68
71
|
|
|
69
|
-
> **For developers:** See `souschef/server.py` for the complete list of all
|
|
72
|
+
> **For developers:** See `souschef/server.py` for the complete list of all 43 registered tools.
|
|
70
73
|
|
|
71
74
|
## Model Agnostic - Works with Any AI Model
|
|
72
75
|
|
|
@@ -87,6 +90,7 @@ As a user, you'll primarily interact with the documented tools. Your AI assistan
|
|
|
87
90
|
|
|
88
91
|
- **[Terraform Provider](terraform-provider/README.md)** - Manage migrations with infrastructure-as-code
|
|
89
92
|
- **[User Guide](docs/user-guide/)** - Complete documentation
|
|
93
|
+
- **[Data Persistence Guide](docs/user-guide/data-persistence.md)** - History, caching, and storage backends
|
|
90
94
|
- **[API Reference](docs/api-reference/)** - Detailed tool documentation
|
|
91
95
|
- **[Migration Guide](docs/migration-guide/)** - Step-by-step migration process
|
|
92
96
|
|
|
@@ -226,7 +230,27 @@ Automatically detects and converts:
|
|
|
226
230
|
- **Cookstyle/Foodcritic** → Lint stages
|
|
227
231
|
- Multiple test suites → Parallel execution strategies
|
|
228
232
|
|
|
229
|
-
|
|
233
|
+
### 11. GitHub Copilot Agent Control
|
|
234
|
+
|
|
235
|
+
Manage GitHub Copilot agents working on repository issues with full pause/stop/resume capabilities:
|
|
236
|
+
|
|
237
|
+
- **assign_github_copilot_to_issue** - Assign Copilot agent to implement an issue
|
|
238
|
+
- **pause_github_copilot_agent** - Pause a running agent (can be resumed)
|
|
239
|
+
- **stop_github_copilot_agent** - Stop and cancel an agent assignment
|
|
240
|
+
- **resume_github_copilot_agent** - Resume a paused agent with optional new instructions
|
|
241
|
+
- **check_github_copilot_agent_status** - Check current agent state and activity
|
|
242
|
+
|
|
243
|
+
**Agent lifecycle management:**
|
|
244
|
+
|
|
245
|
+
1. **Assign** - Start Copilot working on an issue
|
|
246
|
+
2. **Monitor** - Check status and review progress
|
|
247
|
+
3. **Pause** - Temporarily pause for review or changes
|
|
248
|
+
4. **Resume** - Continue with optional new guidance
|
|
249
|
+
5. **Stop** - Cancel if requirements change
|
|
250
|
+
|
|
251
|
+
State is tracked via issue labels and comments, providing full visibility and control.
|
|
252
|
+
|
|
253
|
+
#### Example Usage - CI/CD Pipelines
|
|
230
254
|
|
|
231
255
|
```bash
|
|
232
256
|
# Generate Jenkins Declarative pipeline
|
|
@@ -241,12 +265,58 @@ souschef generate-gitlab-ci ./mycookbook
|
|
|
241
265
|
# Generate GitHub Actions workflow
|
|
242
266
|
souschef generate-github-workflow ./mycookbook
|
|
243
267
|
|
|
244
|
-
#
|
|
268
|
+
# Customise with options
|
|
245
269
|
souschef generate-gitlab-ci ./mycookbook --no-cache --no-artifacts
|
|
246
270
|
souschef generate-github-workflow ./mycookbook --workflow-name "My CI" --no-cache
|
|
247
271
|
```
|
|
248
272
|
|
|
249
|
-
####
|
|
273
|
+
#### Example Usage - GitHub Agent Control
|
|
274
|
+
|
|
275
|
+
```python
|
|
276
|
+
# From an AI assistant with SousChef MCP
|
|
277
|
+
|
|
278
|
+
# Assign Copilot to work on an issue
|
|
279
|
+
assign_github_copilot_to_issue(
|
|
280
|
+
owner="myorg",
|
|
281
|
+
repo="my-ansible-repo",
|
|
282
|
+
issue_number=42,
|
|
283
|
+
base_ref="main",
|
|
284
|
+
custom_instructions="Focus on idempotency and error handling"
|
|
285
|
+
)
|
|
286
|
+
|
|
287
|
+
# Check agent status
|
|
288
|
+
check_github_copilot_agent_status(
|
|
289
|
+
owner="myorg",
|
|
290
|
+
repo="my-ansible-repo",
|
|
291
|
+
issue_number=42
|
|
292
|
+
)
|
|
293
|
+
|
|
294
|
+
# Pause for review
|
|
295
|
+
pause_github_copilot_agent(
|
|
296
|
+
owner="myorg",
|
|
297
|
+
repo="my-ansible-repo",
|
|
298
|
+
issue_number=42,
|
|
299
|
+
reason="Need to review approach before continuing"
|
|
300
|
+
)
|
|
301
|
+
|
|
302
|
+
# Resume with new guidance
|
|
303
|
+
resume_github_copilot_agent(
|
|
304
|
+
owner="myorg",
|
|
305
|
+
repo="my-ansible-repo",
|
|
306
|
+
issue_number=42,
|
|
307
|
+
additional_instructions="Also add role dependencies"
|
|
308
|
+
)
|
|
309
|
+
|
|
310
|
+
# Stop if no longer needed
|
|
311
|
+
stop_github_copilot_agent(
|
|
312
|
+
owner="myorg",
|
|
313
|
+
repo="my-ansible-repo",
|
|
314
|
+
issue_number=42,
|
|
315
|
+
reason="Requirements changed - manual implementation needed"
|
|
316
|
+
)
|
|
317
|
+
```
|
|
318
|
+
|
|
319
|
+
#### Command Line Usage - CI/CD Pipelines
|
|
250
320
|
|
|
251
321
|
**MCP Tool Usage:**
|
|
252
322
|
|
|
@@ -475,6 +545,7 @@ Interactive web-based interface for Chef-to-Ansible migration planning and visua
|
|
|
475
545
|
- **Dependency Mapping**: Visual dependency graphs showing cookbook relationships and migration ordering
|
|
476
546
|
- **Validation Reports**: Conversion validation results with syntax checking and best practice compliance
|
|
477
547
|
- **Progress Tracking**: Real-time migration progress with completion metrics and bottleneck identification
|
|
548
|
+
- **History and Persistence**: Stored analysis history, cached results, and downloadable artefacts (SQLite or PostgreSQL, plus S3-compatible storage)
|
|
478
549
|
|
|
479
550
|
**Launch the UI:**
|
|
480
551
|
|
|
@@ -595,8 +666,59 @@ STREAMLIT_SERVER_HEADLESS=true
|
|
|
595
666
|
- `SOUSCHEF_AI_MAX_TOKENS` - Maximum tokens to generate (optional, default: 4000)
|
|
596
667
|
- `SOUSCHEF_ALLOWED_HOSTNAMES` - Comma-separated list of allowed hostnames for outbound API requests (optional)
|
|
597
668
|
|
|
669
|
+
**Persistent Storage Configuration (Docker Compose):**
|
|
670
|
+
|
|
671
|
+
All persistent storage paths are configurable via environment variables. Add these to your `.env` file to customise where data is stored:
|
|
672
|
+
|
|
673
|
+
```dotenv
|
|
674
|
+
# Docker Compose Volume Configuration (optional)
|
|
675
|
+
SOUSCHEF_DATA_DIR=./data/souschef # SQLite database and analysis history
|
|
676
|
+
SOUSCHEF_STORAGE_DIR=./data/storage # Generated artefacts and conversions
|
|
677
|
+
POSTGRES_DATA_DIR=./data/postgres # PostgreSQL database files
|
|
678
|
+
MINIO_DATA_DIR=./data/minio # MinIO object storage data
|
|
679
|
+
```
|
|
680
|
+
|
|
681
|
+
The storage paths default to `./data/` subdirectories (relative to docker-compose.yml) but can be set to any absolute or relative path. This allows you to:
|
|
682
|
+
- Store data on different volumes or network storage
|
|
683
|
+
- Easily backup and restore data by copying directories
|
|
684
|
+
- Share data between development and production environments
|
|
685
|
+
|
|
686
|
+
See [Docker Deployment Guide](docs/docker-deployment.md#persistent-storage-configuration) for detailed configuration options.
|
|
687
|
+
|
|
598
688
|
**Docker Compose (recommended for development):**
|
|
599
689
|
|
|
690
|
+
```bash
|
|
691
|
+
# Using PostgreSQL (default, production-ready)
|
|
692
|
+
docker compose up
|
|
693
|
+
|
|
694
|
+
# Or if you prefer SQLite (lightweight, local storage only):
|
|
695
|
+
# 1. Set in .env: SOUSCHEF_DB_BACKEND=sqlite
|
|
696
|
+
# 2. Run normally: docker compose up
|
|
697
|
+
```
|
|
698
|
+
|
|
699
|
+
**Database Options:**
|
|
700
|
+
|
|
701
|
+
- **PostgreSQL** (default):
|
|
702
|
+
- Robust, production-ready database server
|
|
703
|
+
- Recommended for all deployments
|
|
704
|
+
- Better concurrency and performance
|
|
705
|
+
- Data stored in `./data/postgres/`
|
|
706
|
+
|
|
707
|
+
- **SQLite**:
|
|
708
|
+
- Lightweight, embedded database
|
|
709
|
+
- Good for development and testing
|
|
710
|
+
- Set `SOUSCHEF_DB_BACKEND=sqlite` in .env
|
|
711
|
+
- Data stored in `./data/souschef/`
|
|
712
|
+
|
|
713
|
+
**Example with SQLite:**
|
|
714
|
+
```bash
|
|
715
|
+
# In .env, set:
|
|
716
|
+
SOUSCHEF_DB_BACKEND=sqlite
|
|
717
|
+
# Then start normally:
|
|
718
|
+
docker compose up
|
|
719
|
+
```
|
|
720
|
+
|
|
721
|
+
**Example with PostgreSQL (default):**
|
|
600
722
|
```yaml
|
|
601
723
|
version: '3.8'
|
|
602
724
|
services:
|
|
@@ -611,6 +733,12 @@ services:
|
|
|
611
733
|
- STREAMLIT_SERVER_ADDRESS=0.0.0.0
|
|
612
734
|
- STREAMLIT_SERVER_PORT=9999
|
|
613
735
|
- STREAMLIT_SERVER_HEADLESS=true
|
|
736
|
+
- SOUSCHEF_DB_BACKEND=postgres
|
|
737
|
+
- SOUSCHEF_DB_HOST=postgres
|
|
738
|
+
- SOUSCHEF_DB_PORT=5432
|
|
739
|
+
- SOUSCHEF_DB_NAME=souschef
|
|
740
|
+
- SOUSCHEF_DB_USER=souschef
|
|
741
|
+
- SOUSCHEF_DB_PASSWORD=souschef
|
|
614
742
|
restart: unless-stopped
|
|
615
743
|
```
|
|
616
744
|
|
|
@@ -13,7 +13,7 @@ souschef/converters/playbook.py,sha256=F_6tSFyrlT55vLdi632g7Yd5rkNRPlq4pnb5HSMrs
|
|
|
13
13
|
souschef/converters/resource.py,sha256=NYMcp1-obg_ad_XPuYDuUH_0j65agRbAeWzXPfbSi5c,13570
|
|
14
14
|
souschef/converters/template.py,sha256=sXMLm2egA2dSOY-SLoKjXOYH1dHK_ozj67YC89sg8dc,9268
|
|
15
15
|
souschef/core/__init__.py,sha256=PXiZSEfXw77te3SvMRKy0_g0CwQqworbgFLca89u7wA,1969
|
|
16
|
-
souschef/core/ai_schemas.py,sha256=
|
|
16
|
+
souschef/core/ai_schemas.py,sha256=Rp48Z1KLKFizZkUBORKUx2jfSJWuwf5SCoKIf6FNc9E,2964
|
|
17
17
|
souschef/core/constants.py,sha256=AyIpc9cJjQEDc1yOcoKc_2-cJB4PekSpPKEK2S9jDl8,5122
|
|
18
18
|
souschef/core/errors.py,sha256=zj_LHDRxUvHmcs-nZjOWu4B_MhY5WVq2okyZOxyycCI,8605
|
|
19
19
|
souschef/core/http_client.py,sha256=f7laiNsIAX95-fVyAfnQXUdOL-Cv7ZWxi5xLnmTAkF4,12873
|
|
@@ -28,6 +28,8 @@ souschef/filesystem/__init__.py,sha256=2H7Pdeedz0MfmgpRlmii_vx61qr0jtxFndT0APPm6
|
|
|
28
28
|
souschef/filesystem/operations.py,sha256=OMMozBfV_o70b47KioiZ2i6HViiUQPE5mVBeKcKFepo,1654
|
|
29
29
|
souschef/generators/__init__.py,sha256=T_XShFRPEceciUCq3q0EzYkAloN7CtoCq63kWzpQPW4,254
|
|
30
30
|
souschef/generators/repo.py,sha256=RUc8uCHPF5SXFWn43eSRph1hAZwQxLKLwYbnZN0CdcQ,18851
|
|
31
|
+
souschef/github/__init__.py,sha256=X2uQrnidm5-cTYbcXnLd3RPamDEws03u4Tx3xxK5JfU,392
|
|
32
|
+
souschef/github/agent_control.py,sha256=iwRVvPjO7IGtBfenP4npyw-QkLJs0JCPjrqR7W_NhKo,14012
|
|
31
33
|
souschef/parsers/__init__.py,sha256=gF-vPslzs9iLxsaDzFnWDPpYFDAIwyAifjUwzYurPLg,1104
|
|
32
34
|
souschef/parsers/attributes.py,sha256=ss0H7QAPAZEf2YPrln7yXVHWQIjV4vqlcmLR8ZZXiNo,18250
|
|
33
35
|
souschef/parsers/habitat.py,sha256=n2mb5ydcIqday4TH_bmp6Nka0VxoMpKM5doaCh8ClY0,10494
|
|
@@ -37,16 +39,21 @@ souschef/parsers/recipe.py,sha256=PNGQKVv0wwqj_q8WYT2NjsSavLA9WXdo2C9bp6pY9qc,71
|
|
|
37
39
|
souschef/parsers/resource.py,sha256=WcKsUjP3yZx2-2nsTUTLPxIxtfwEihHVNkv3OC6bBHs,5359
|
|
38
40
|
souschef/parsers/template.py,sha256=v51BMUHmr9FYwE7zDNFA01dsClWHLrc_YD3rCM-2lqc,10543
|
|
39
41
|
souschef/profiling.py,sha256=a6Pn57CZR3UPR1YIY8gfbuTPRuPkFrfIFBmctOcaZgY,17315
|
|
40
|
-
souschef/server.py,sha256=
|
|
42
|
+
souschef/server.py,sha256=styEzpiXyI2hBwInp_hk4WjrNtkSDI4OHcLOQhyLzB4,131100
|
|
43
|
+
souschef/storage/__init__.py,sha256=HExdGjXDmVv_m4OC0q3_VV5R1Dk94NtycP-RlM9qmo4,846
|
|
44
|
+
souschef/storage/blob.py,sha256=bTobqw8zC4hTYKK_YNwKGQ2alFUduckGVG31Q_ZkHN4,10907
|
|
45
|
+
souschef/storage/config.py,sha256=7L9_QGGt174OweJvl5yDn5A1N4DayEXhc4P3TSxHEwo,4571
|
|
46
|
+
souschef/storage/database.py,sha256=z9oujKyKZJTNCQATSWi2LJj8vm_Yb60jShKN6IlwGac,38988
|
|
41
47
|
souschef/ui/__init__.py,sha256=U3W6X4ww7CxQVuetcocObWn5iY6lUFiNX7WoDBJeD34,195
|
|
42
|
-
souschef/ui/app.py,sha256=
|
|
48
|
+
souschef/ui/app.py,sha256=zK2R4M5hxR_X0GCnG9k_GiOpZoRSIhF7O-pBCKxaTZI,102760
|
|
43
49
|
souschef/ui/health_check.py,sha256=mEzec8L6XPRekOBAXngqQz5dnzal-a4p3D70mkPriiA,903
|
|
44
50
|
souschef/ui/pages/ai_settings.py,sha256=AevsSuiRcfYuQqtYcu1ijp8x3G3PYAUBXzxLmSSVp2c,22105
|
|
45
|
-
souschef/ui/pages/chef_server_settings.py,sha256=
|
|
46
|
-
souschef/ui/pages/cookbook_analysis.py,sha256=
|
|
51
|
+
souschef/ui/pages/chef_server_settings.py,sha256=7Q1k7rsIv4p91i0yx3g0svD2qWgXZwAYrVGUr3T2jeM,21882
|
|
52
|
+
souschef/ui/pages/cookbook_analysis.py,sha256=XZvPGzkye3zW6hE7noNuYePACVmtFPaS5L-s23vhYL0,161175
|
|
53
|
+
souschef/ui/pages/history.py,sha256=g935hpkdJlXqBZibiqkG82gF7XRn13xDFfj90ggADrg,31241
|
|
47
54
|
souschef/ui/pages/validation_reports.py,sha256=R3xHTJb_y2b0tI8N0qPF1oS4f9ZVb539_82dj5nmmxA,7593
|
|
48
|
-
mcp_souschef-
|
|
49
|
-
mcp_souschef-
|
|
50
|
-
mcp_souschef-
|
|
51
|
-
mcp_souschef-
|
|
52
|
-
mcp_souschef-
|
|
55
|
+
mcp_souschef-4.0.0.dist-info/METADATA,sha256=35ng6in7gceAJqcrsBTV4HBHG2dT-4awdbbbsniDQYo,51653
|
|
56
|
+
mcp_souschef-4.0.0.dist-info/WHEEL,sha256=kJCRJT_g0adfAJzTx2GUMmS80rTJIVHRCfG0DQgLq3o,88
|
|
57
|
+
mcp_souschef-4.0.0.dist-info/entry_points.txt,sha256=NVSk61tLG4W0xEkWGOMXAVCIUyodyZCY_j3Z_0m6rkQ,80
|
|
58
|
+
mcp_souschef-4.0.0.dist-info/licenses/LICENSE,sha256=t31dYSuvYYNw6trj-coWSsLK-Tg_Iyl8ObcolQcrUKM,1078
|
|
59
|
+
mcp_souschef-4.0.0.dist-info/RECORD,,
|
souschef/core/ai_schemas.py
CHANGED
|
@@ -30,7 +30,12 @@ class AnsibleTask(BaseModel):
|
|
|
30
30
|
None, description="List of tags for task categorization"
|
|
31
31
|
)
|
|
32
32
|
become: bool | None = Field(None, description="Whether to use privilege escalation")
|
|
33
|
-
|
|
33
|
+
register_var: str | None = Field(
|
|
34
|
+
None,
|
|
35
|
+
validation_alias="register",
|
|
36
|
+
serialization_alias="register",
|
|
37
|
+
description="Variable name to store task result",
|
|
38
|
+
)
|
|
34
39
|
|
|
35
40
|
|
|
36
41
|
class AnsibleHandler(BaseModel):
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"""GitHub integration utilities."""
|
|
2
|
+
|
|
3
|
+
from souschef.github.agent_control import (
|
|
4
|
+
assign_copilot_agent_to_issue,
|
|
5
|
+
check_copilot_agent_status,
|
|
6
|
+
pause_copilot_agent,
|
|
7
|
+
resume_copilot_agent,
|
|
8
|
+
stop_copilot_agent,
|
|
9
|
+
)
|
|
10
|
+
|
|
11
|
+
__all__ = [
|
|
12
|
+
"assign_copilot_agent_to_issue",
|
|
13
|
+
"pause_copilot_agent",
|
|
14
|
+
"stop_copilot_agent",
|
|
15
|
+
"resume_copilot_agent",
|
|
16
|
+
"check_copilot_agent_status",
|
|
17
|
+
]
|