copilotagent 0.1.6__tar.gz
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.
- copilotagent-0.1.6/DEPLOYMENT.md +233 -0
- copilotagent-0.1.6/LICENSE +21 -0
- copilotagent-0.1.6/MANIFEST.in +12 -0
- copilotagent-0.1.6/PKG-INFO +616 -0
- copilotagent-0.1.6/README.md +596 -0
- copilotagent-0.1.6/SETUP_COMPLETE.md +293 -0
- copilotagent-0.1.6/pyproject.toml +110 -0
- copilotagent-0.1.6/setup.cfg +4 -0
- copilotagent-0.1.6/src/copilotagent/__init__.py +35 -0
- copilotagent-0.1.6/src/copilotagent/cloud_subagents.py +220 -0
- copilotagent-0.1.6/src/copilotagent/graph.py +192 -0
- copilotagent-0.1.6/src/copilotagent/middleware/__init__.py +15 -0
- copilotagent-0.1.6/src/copilotagent/middleware/filesystem.py +1135 -0
- copilotagent-0.1.6/src/copilotagent/middleware/initial_message.py +88 -0
- copilotagent-0.1.6/src/copilotagent/middleware/patch_tool_calls.py +44 -0
- copilotagent-0.1.6/src/copilotagent/middleware/planner_prompts/drawdoc_awm.md +44 -0
- copilotagent-0.1.6/src/copilotagent/middleware/planner_prompts/itp_princeton.md +61 -0
- copilotagent-0.1.6/src/copilotagent/middleware/planner_prompts/research.md +51 -0
- copilotagent-0.1.6/src/copilotagent/middleware/planning.py +304 -0
- copilotagent-0.1.6/src/copilotagent/middleware/subagents.py +589 -0
- copilotagent-0.1.6/src/copilotagent/py.typed +2 -0
- copilotagent-0.1.6/src/copilotagent.egg-info/PKG-INFO +616 -0
- copilotagent-0.1.6/src/copilotagent.egg-info/SOURCES.txt +24 -0
- copilotagent-0.1.6/src/copilotagent.egg-info/dependency_links.txt +1 -0
- copilotagent-0.1.6/src/copilotagent.egg-info/requires.txt +11 -0
- copilotagent-0.1.6/src/copilotagent.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
# Deployment Guide
|
|
2
|
+
|
|
3
|
+
This guide explains how to deploy new versions of DeepAgents using the automated deployment system.
|
|
4
|
+
|
|
5
|
+
## 🚀 Deployment Rules
|
|
6
|
+
|
|
7
|
+
**IMPORTANT**: Follow these rules for all deployments:
|
|
8
|
+
|
|
9
|
+
1. **Commit message is REQUIRED** - Always describe what changed
|
|
10
|
+
2. **Version type defaults to `patch`** - Most changes should be patches
|
|
11
|
+
3. **Use descriptive commit messages** - They become part of the release notes
|
|
12
|
+
4. **One deployment per change** - Don't batch unrelated changes
|
|
13
|
+
|
|
14
|
+
## 📋 Quick Deployment
|
|
15
|
+
|
|
16
|
+
Use the `deploy.sh` script for automated deployments:
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
# Patch version (DEFAULT) - bug fixes, small changes
|
|
20
|
+
./deploy.sh "Fix SubAgentMiddleware initialization bug"
|
|
21
|
+
|
|
22
|
+
# Same as above (patch is default)
|
|
23
|
+
./deploy.sh "Fix SubAgentMiddleware initialization bug" patch
|
|
24
|
+
|
|
25
|
+
# Minor version - new features, backwards compatible
|
|
26
|
+
./deploy.sh "Add new planning prompt templates" minor
|
|
27
|
+
|
|
28
|
+
# Major version - breaking changes, API changes
|
|
29
|
+
./deploy.sh "Remove deprecated middleware parameter" major
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## 📋 What the Deploy Script Does
|
|
33
|
+
|
|
34
|
+
The script performs these steps **automatically**:
|
|
35
|
+
|
|
36
|
+
1. **Validates input** - Checks commit message is provided and version type is valid
|
|
37
|
+
2. **Commits changes** - Stages and commits all uncommitted changes with your message
|
|
38
|
+
3. **Bumps version** - Updates version number in `pyproject.toml` and `src/copilotagent/__init__.py`
|
|
39
|
+
4. **Pushes changes** - Pushes the commit to remote repository
|
|
40
|
+
5. **Creates and pushes tag** - Creates version tag (e.g., `v0.1.5`) and pushes it
|
|
41
|
+
6. **Creates GitHub release** - Automatically creates a GitHub release (if `gh` CLI available)
|
|
42
|
+
7. **Triggers PyPI deployment** - Release creation triggers automatic PyPI publishing
|
|
43
|
+
|
|
44
|
+
**All in one command!** ✨
|
|
45
|
+
|
|
46
|
+
## 🔄 Automated Workflow
|
|
47
|
+
|
|
48
|
+
### The Process Flow
|
|
49
|
+
|
|
50
|
+
```
|
|
51
|
+
1. Developer runs deploy.sh
|
|
52
|
+
↓
|
|
53
|
+
2. Script commits changes and bumps version
|
|
54
|
+
↓
|
|
55
|
+
3. Script pushes tag (e.g., v0.1.5)
|
|
56
|
+
↓
|
|
57
|
+
4. GitHub Action detects tag push
|
|
58
|
+
↓
|
|
59
|
+
5. Auto-release workflow creates GitHub release
|
|
60
|
+
↓
|
|
61
|
+
6. Release creation triggers PyPI workflow
|
|
62
|
+
↓
|
|
63
|
+
7. Package published to PyPI automatically
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
### GitHub Workflows
|
|
67
|
+
|
|
68
|
+
- **`auto-release.yml`** - Creates releases when version tags are pushed
|
|
69
|
+
- **`pypi.yml`** - Publishes to PyPI when releases are created
|
|
70
|
+
|
|
71
|
+
## 🛠️ Requirements
|
|
72
|
+
|
|
73
|
+
### For deploy.sh script:
|
|
74
|
+
- `bump-my-version` (auto-installed if missing)
|
|
75
|
+
- `gh` CLI (optional, for automatic release creation)
|
|
76
|
+
- Git repository with remote origin
|
|
77
|
+
|
|
78
|
+
### For GitHub Actions:
|
|
79
|
+
- Repository secrets:
|
|
80
|
+
- `PYPI_API_TOKEN` - Your PyPI API token
|
|
81
|
+
|
|
82
|
+
## 📦 Version Types
|
|
83
|
+
|
|
84
|
+
| Type | When to Use | Example Change | Version Change |
|
|
85
|
+
|------|-------------|----------------|----------------|
|
|
86
|
+
| **patch** *(default)* | Bug fixes, small improvements, documentation | Fix initialization bug | 0.1.4 → 0.1.5 |
|
|
87
|
+
| **minor** | New features, backwards compatible changes | Add new middleware | 0.1.4 → 0.2.0 |
|
|
88
|
+
| **major** | Breaking changes, API changes | Remove deprecated feature | 0.1.4 → 1.0.0 |
|
|
89
|
+
|
|
90
|
+
### 🎯 **When in doubt, use `patch`** - it's the safe default for most changes.
|
|
91
|
+
|
|
92
|
+
## 🎯 Usage Examples
|
|
93
|
+
|
|
94
|
+
### Most Common: Bug Fixes & Small Changes (patch - default)
|
|
95
|
+
```bash
|
|
96
|
+
./deploy.sh "Fix SubAgentMiddleware initialization bug"
|
|
97
|
+
./deploy.sh "Update documentation with new examples"
|
|
98
|
+
./deploy.sh "Improve error handling in FilesystemMiddleware"
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
### New Features (minor - requires explicit specification)
|
|
102
|
+
```bash
|
|
103
|
+
./deploy.sh "Add initial_state parameter to PlanningMiddleware" minor
|
|
104
|
+
./deploy.sh "Add new cloud subagent support" minor
|
|
105
|
+
./deploy.sh "Add ITP-Princeton planning prompts" minor
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
### Breaking Changes (major - requires explicit specification)
|
|
109
|
+
```bash
|
|
110
|
+
./deploy.sh "Remove deprecated async_create_deep_agent" major
|
|
111
|
+
./deploy.sh "Refactor middleware API for better usability" major
|
|
112
|
+
./deploy.sh "Change create_deep_agent signature" major
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
### 💡 **Remember**: If you don't specify a version type, it defaults to `patch`!
|
|
116
|
+
|
|
117
|
+
## 🔍 Monitoring Deployments
|
|
118
|
+
|
|
119
|
+
### Check Status
|
|
120
|
+
- **GitHub Actions**: https://github.com/yourusername/copilotagent/actions
|
|
121
|
+
- **PyPI Package**: https://pypi.org/project/copilotagent/
|
|
122
|
+
- **Releases**: https://github.com/yourusername/copilotagent/releases
|
|
123
|
+
|
|
124
|
+
### Verify Deployment
|
|
125
|
+
```bash
|
|
126
|
+
# Check latest version on PyPI
|
|
127
|
+
pip index versions copilotagent
|
|
128
|
+
|
|
129
|
+
# Install latest version
|
|
130
|
+
pip install --upgrade copilotagent
|
|
131
|
+
|
|
132
|
+
# Verify in Python
|
|
133
|
+
python -c "import copilotagent; print(copilotagent.__version__)"
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
## 🚨 Troubleshooting
|
|
137
|
+
|
|
138
|
+
### Common Issues
|
|
139
|
+
|
|
140
|
+
#### 1. Deploy script fails with "Not in a git repository"
|
|
141
|
+
```bash
|
|
142
|
+
# Make sure you're in the project root
|
|
143
|
+
cd /path/to/baseCopilotAgent
|
|
144
|
+
./deploy.sh "Your message"
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
#### 2. PyPI deployment fails
|
|
148
|
+
- Check repository secrets are set correctly
|
|
149
|
+
- Verify PyPI API token in GitHub Settings → Secrets
|
|
150
|
+
|
|
151
|
+
#### 3. GitHub release not created
|
|
152
|
+
- Install GitHub CLI: `brew install gh` (macOS) or download from github.com/cli/cli
|
|
153
|
+
- Login: `gh auth login`
|
|
154
|
+
|
|
155
|
+
#### 4. Version not bumped correctly
|
|
156
|
+
- Check `pyproject.toml` has correct bumpversion configuration
|
|
157
|
+
- Verify both `pyproject.toml` and `src/copilotagent/__init__.py` are updated
|
|
158
|
+
|
|
159
|
+
### Manual Release Creation
|
|
160
|
+
|
|
161
|
+
If automatic release creation fails:
|
|
162
|
+
|
|
163
|
+
1. Go to https://github.com/yourusername/copilotagent/releases/new
|
|
164
|
+
2. Select the tag created by deploy.sh (e.g., `v0.1.5`)
|
|
165
|
+
3. Set title: `Release v0.1.5`
|
|
166
|
+
4. Add release notes
|
|
167
|
+
5. Click "Publish release"
|
|
168
|
+
|
|
169
|
+
This will trigger the PyPI deployment automatically.
|
|
170
|
+
|
|
171
|
+
## 🔧 Script Configuration
|
|
172
|
+
|
|
173
|
+
### Customizing deploy.sh
|
|
174
|
+
|
|
175
|
+
The script can be modified to:
|
|
176
|
+
- Change default branch (currently `main`)
|
|
177
|
+
- Modify release note templates
|
|
178
|
+
- Add additional validation steps
|
|
179
|
+
- Integrate with other tools
|
|
180
|
+
|
|
181
|
+
### Environment Variables
|
|
182
|
+
|
|
183
|
+
```bash
|
|
184
|
+
# Optional: Set default branch
|
|
185
|
+
export DEFAULT_BRANCH="main"
|
|
186
|
+
|
|
187
|
+
# Optional: GitHub repository
|
|
188
|
+
export GITHUB_REPOSITORY="yourusername/copilotagent"
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
## 📝 Best Practices
|
|
192
|
+
|
|
193
|
+
1. **Test before deploying** - Run tests locally first
|
|
194
|
+
2. **Write clear commit messages** - They become release notes
|
|
195
|
+
3. **Use semantic versioning** - Choose version type carefully
|
|
196
|
+
4. **Monitor deployments** - Check GitHub Actions and PyPI
|
|
197
|
+
5. **Keep changelog updated** - The script generates automatic changelogs
|
|
198
|
+
|
|
199
|
+
## 🔄 Rollback Process
|
|
200
|
+
|
|
201
|
+
If you need to rollback a deployment:
|
|
202
|
+
|
|
203
|
+
1. **Remove the tag**:
|
|
204
|
+
```bash
|
|
205
|
+
git tag -d v0.1.5
|
|
206
|
+
git push origin :refs/tags/v0.1.5
|
|
207
|
+
```
|
|
208
|
+
|
|
209
|
+
2. **Delete the release** (optional):
|
|
210
|
+
```bash
|
|
211
|
+
gh release delete v0.1.5
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
3. **Revert version changes**:
|
|
215
|
+
```bash
|
|
216
|
+
git revert HEAD
|
|
217
|
+
git push origin main
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
Note: PyPI packages cannot be deleted, only yanked from the index.
|
|
221
|
+
|
|
222
|
+
---
|
|
223
|
+
|
|
224
|
+
## 🎉 Ready to Deploy!
|
|
225
|
+
|
|
226
|
+
Your automated deployment system is ready. Just run:
|
|
227
|
+
|
|
228
|
+
```bash
|
|
229
|
+
./deploy.sh "Your awesome new feature"
|
|
230
|
+
```
|
|
231
|
+
|
|
232
|
+
And watch the magic happen! 🚀
|
|
233
|
+
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Harrison Chase
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
include LICENSE
|
|
2
|
+
include README.md
|
|
3
|
+
include DEPLOYMENT.md
|
|
4
|
+
include SETUP_COMPLETE.md
|
|
5
|
+
include src/copilotagent/py.typed
|
|
6
|
+
|
|
7
|
+
recursive-include src/copilotagent/middleware/planner_prompts *.md
|
|
8
|
+
|
|
9
|
+
recursive-exclude * __pycache__
|
|
10
|
+
recursive-exclude * *.py[co]
|
|
11
|
+
recursive-exclude * .DS_Store
|
|
12
|
+
|