shotgun-sh 0.1.0.dev22__py3-none-any.whl → 0.1.0.dev24__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 shotgun-sh might be problematic. Click here for more details.
- shotgun/agents/agent_manager.py +95 -15
- shotgun/agents/common.py +143 -25
- shotgun/agents/conversation_history.py +56 -0
- shotgun/agents/conversation_manager.py +105 -0
- shotgun/agents/export.py +5 -2
- shotgun/agents/models.py +16 -7
- shotgun/agents/plan.py +2 -1
- shotgun/agents/research.py +2 -1
- shotgun/agents/specify.py +2 -1
- shotgun/agents/tasks.py +5 -2
- shotgun/agents/tools/file_management.py +67 -2
- shotgun/codebase/core/ingestor.py +1 -1
- shotgun/codebase/core/manager.py +106 -4
- shotgun/codebase/models.py +4 -0
- shotgun/codebase/service.py +60 -2
- shotgun/main.py +9 -1
- shotgun/prompts/agents/export.j2 +14 -11
- shotgun/prompts/agents/partials/common_agent_system_prompt.j2 +6 -9
- shotgun/prompts/agents/plan.j2 +9 -13
- shotgun/prompts/agents/research.j2 +11 -14
- shotgun/prompts/agents/specify.j2 +9 -12
- shotgun/prompts/agents/state/system_state.j2 +27 -5
- shotgun/prompts/agents/tasks.j2 +12 -12
- shotgun/sdk/codebase.py +26 -2
- shotgun/sdk/services.py +0 -14
- shotgun/tui/app.py +9 -4
- shotgun/tui/screens/chat.py +80 -19
- shotgun/tui/screens/chat_screen/command_providers.py +1 -1
- shotgun/tui/screens/chat_screen/history.py +6 -0
- shotgun/tui/utils/mode_progress.py +111 -78
- {shotgun_sh-0.1.0.dev22.dist-info → shotgun_sh-0.1.0.dev24.dist-info}/METADATA +8 -9
- {shotgun_sh-0.1.0.dev22.dist-info → shotgun_sh-0.1.0.dev24.dist-info}/RECORD +35 -54
- shotgun/agents/artifact_state.py +0 -58
- shotgun/agents/tools/artifact_management.py +0 -481
- shotgun/artifacts/__init__.py +0 -17
- shotgun/artifacts/exceptions.py +0 -89
- shotgun/artifacts/manager.py +0 -530
- shotgun/artifacts/models.py +0 -334
- shotgun/artifacts/service.py +0 -463
- shotgun/artifacts/templates/__init__.py +0 -10
- shotgun/artifacts/templates/loader.py +0 -252
- shotgun/artifacts/templates/models.py +0 -136
- shotgun/artifacts/templates/plan/delivery_and_release_plan.yaml +0 -66
- shotgun/artifacts/templates/research/market_research.yaml +0 -585
- shotgun/artifacts/templates/research/sdk_comparison.yaml +0 -257
- shotgun/artifacts/templates/specify/prd.yaml +0 -331
- shotgun/artifacts/templates/specify/product_spec.yaml +0 -301
- shotgun/artifacts/utils.py +0 -76
- shotgun/prompts/agents/partials/artifact_system.j2 +0 -32
- shotgun/prompts/agents/state/artifact_templates_available.j2 +0 -20
- shotgun/prompts/agents/state/existing_artifacts_available.j2 +0 -25
- shotgun/sdk/artifact_models.py +0 -186
- shotgun/sdk/artifacts.py +0 -448
- {shotgun_sh-0.1.0.dev22.dist-info → shotgun_sh-0.1.0.dev24.dist-info}/WHEEL +0 -0
- {shotgun_sh-0.1.0.dev22.dist-info → shotgun_sh-0.1.0.dev24.dist-info}/entry_points.txt +0 -0
- {shotgun_sh-0.1.0.dev22.dist-info → shotgun_sh-0.1.0.dev24.dist-info}/licenses/LICENSE +0 -0
|
@@ -3,17 +3,25 @@
|
|
|
3
3
|
import random
|
|
4
4
|
from pathlib import Path
|
|
5
5
|
|
|
6
|
-
from shotgun.agents.
|
|
7
|
-
from shotgun.artifacts.models import AgentMode
|
|
6
|
+
from shotgun.agents.models import AgentType
|
|
8
7
|
from shotgun.utils.file_system_utils import get_shotgun_base_path
|
|
9
8
|
|
|
10
9
|
|
|
11
10
|
class ModeProgressChecker:
|
|
12
|
-
"""Checks progress across different agent modes based on
|
|
11
|
+
"""Checks progress across different agent modes based on file contents."""
|
|
13
12
|
|
|
14
13
|
# Minimum file size in characters to consider a mode as "started"
|
|
15
14
|
MIN_CONTENT_SIZE = 20
|
|
16
15
|
|
|
16
|
+
# Map agent types to their corresponding files (in workflow order)
|
|
17
|
+
MODE_FILES = {
|
|
18
|
+
AgentType.RESEARCH: "research.md",
|
|
19
|
+
AgentType.SPECIFY: "specification.md",
|
|
20
|
+
AgentType.PLAN: "plan.md",
|
|
21
|
+
AgentType.TASKS: "tasks.md",
|
|
22
|
+
AgentType.EXPORT: "exports/", # Export mode creates files in exports folder
|
|
23
|
+
}
|
|
24
|
+
|
|
17
25
|
def __init__(self, base_path: Path | None = None):
|
|
18
26
|
"""Initialize the progress checker.
|
|
19
27
|
|
|
@@ -22,34 +30,46 @@ class ModeProgressChecker:
|
|
|
22
30
|
"""
|
|
23
31
|
self.base_path = base_path or get_shotgun_base_path()
|
|
24
32
|
|
|
25
|
-
def has_mode_content(self, mode: AgentType
|
|
26
|
-
"""Check if a mode
|
|
33
|
+
def has_mode_content(self, mode: AgentType) -> bool:
|
|
34
|
+
"""Check if a mode has meaningful content.
|
|
27
35
|
|
|
28
36
|
Args:
|
|
29
37
|
mode: The agent mode to check.
|
|
30
38
|
|
|
31
39
|
Returns:
|
|
32
|
-
True if the mode has
|
|
40
|
+
True if the mode has a file with >20 characters.
|
|
33
41
|
"""
|
|
34
|
-
|
|
35
|
-
|
|
42
|
+
if mode not in self.MODE_FILES:
|
|
43
|
+
return False
|
|
36
44
|
|
|
37
|
-
|
|
45
|
+
file_or_dir = self.MODE_FILES[mode]
|
|
46
|
+
|
|
47
|
+
# Special handling for export mode (checks directory)
|
|
48
|
+
if mode == AgentType.EXPORT:
|
|
49
|
+
export_path = self.base_path / file_or_dir
|
|
50
|
+
if export_path.exists() and export_path.is_dir():
|
|
51
|
+
# Check if any files exist in exports directory
|
|
52
|
+
for item in export_path.glob("*"):
|
|
53
|
+
if item.is_file() and not item.name.startswith("."):
|
|
54
|
+
try:
|
|
55
|
+
content = item.read_text(encoding="utf-8")
|
|
56
|
+
if len(content.strip()) > self.MIN_CONTENT_SIZE:
|
|
57
|
+
return True
|
|
58
|
+
except (OSError, UnicodeDecodeError):
|
|
59
|
+
continue
|
|
38
60
|
return False
|
|
39
61
|
|
|
40
|
-
# Check
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
content = item.read_text(encoding="utf-8")
|
|
45
|
-
# Check if file has meaningful content
|
|
46
|
-
if len(content.strip()) > self.MIN_CONTENT_SIZE:
|
|
47
|
-
return True
|
|
48
|
-
except (OSError, UnicodeDecodeError):
|
|
49
|
-
# Skip files that can't be read
|
|
50
|
-
continue
|
|
62
|
+
# Check single file for other modes
|
|
63
|
+
file_path = self.base_path / file_or_dir
|
|
64
|
+
if not file_path.exists() or not file_path.is_file():
|
|
65
|
+
return False
|
|
51
66
|
|
|
52
|
-
|
|
67
|
+
try:
|
|
68
|
+
content = file_path.read_text(encoding="utf-8")
|
|
69
|
+
# Check if file has meaningful content
|
|
70
|
+
return len(content.strip()) > self.MIN_CONTENT_SIZE
|
|
71
|
+
except (OSError, UnicodeDecodeError):
|
|
72
|
+
return False
|
|
53
73
|
|
|
54
74
|
def get_next_suggested_mode(self, current_mode: AgentType) -> AgentType | None:
|
|
55
75
|
"""Get the next suggested mode based on current progress.
|
|
@@ -128,97 +148,110 @@ class PlaceholderHints:
|
|
|
128
148
|
# Tasks mode
|
|
129
149
|
AgentType.TASKS: {
|
|
130
150
|
False: [
|
|
131
|
-
"
|
|
132
|
-
"
|
|
133
|
-
"
|
|
134
|
-
"
|
|
135
|
-
"
|
|
151
|
+
"Break down your project into actionable tasks (SHIFT+TAB for modes)",
|
|
152
|
+
"Task creation time! Define your implementation steps (SHIFT+TAB to switch)",
|
|
153
|
+
"Ready to get tactical? Create your task list (SHIFT+TAB for mode options)",
|
|
154
|
+
"Task command center: Organize your work items (SHIFT+TAB to navigate)",
|
|
155
|
+
" ✅ Task mode activated! Break it down into bite-sized pieces (SHIFT+TAB)",
|
|
136
156
|
],
|
|
137
157
|
True: [
|
|
138
|
-
"Tasks
|
|
139
|
-
"Task list
|
|
140
|
-
"
|
|
141
|
-
"
|
|
142
|
-
"
|
|
158
|
+
"Tasks defined! Ready to export or cycle back (SHIFT+TAB)",
|
|
159
|
+
"Task list complete! Export your work (SHIFT+TAB to Export)",
|
|
160
|
+
"All tasks created! Time to export (SHIFT+TAB for Export mode)",
|
|
161
|
+
"Implementation plan ready! Export everything (SHIFT+TAB to Export)",
|
|
162
|
+
" 🎊 Tasks complete! Export your masterpiece (SHIFT+TAB)",
|
|
143
163
|
],
|
|
144
164
|
},
|
|
145
165
|
# Export mode
|
|
146
166
|
AgentType.EXPORT: {
|
|
147
167
|
False: [
|
|
148
|
-
"Export
|
|
149
|
-
"Ready to
|
|
150
|
-
"Export
|
|
151
|
-
"Time to
|
|
152
|
-
"
|
|
168
|
+
"Export your complete project documentation (SHIFT+TAB for modes)",
|
|
169
|
+
"Ready to package everything? Export time! (SHIFT+TAB to switch)",
|
|
170
|
+
"Export station: Generate deliverables (SHIFT+TAB for mode menu)",
|
|
171
|
+
"Time to share your work! Export documents (SHIFT+TAB to navigate)",
|
|
172
|
+
" 📦 Export mode! Package and share your creation (SHIFT+TAB)",
|
|
153
173
|
],
|
|
154
174
|
True: [
|
|
155
|
-
"
|
|
156
|
-
"
|
|
157
|
-
"
|
|
158
|
-
"
|
|
159
|
-
"
|
|
175
|
+
"Exported! Start new research or continue refining (SHIFT+TAB)",
|
|
176
|
+
"Export complete! New cycle begins (SHIFT+TAB to Research)",
|
|
177
|
+
"All exported! Ready for another round (SHIFT+TAB for Research)",
|
|
178
|
+
"Documents exported! Start fresh (SHIFT+TAB to Research mode)",
|
|
179
|
+
" 🎉 Export complete! Begin a new adventure (SHIFT+TAB)",
|
|
160
180
|
],
|
|
161
181
|
},
|
|
162
|
-
# Plan mode
|
|
182
|
+
# Plan mode
|
|
163
183
|
AgentType.PLAN: {
|
|
164
184
|
False: [
|
|
165
|
-
"Create
|
|
166
|
-
"
|
|
167
|
-
"
|
|
168
|
-
"
|
|
169
|
-
"
|
|
185
|
+
"Create a strategic plan for your project (SHIFT+TAB for modes)",
|
|
186
|
+
"Planning phase: Map out your roadmap (SHIFT+TAB to switch)",
|
|
187
|
+
"Time to strategize! Create your project plan (SHIFT+TAB for options)",
|
|
188
|
+
"Plan your approach and milestones (SHIFT+TAB to navigate)",
|
|
189
|
+
" 🗺️ Plan mode! Chart your course to success (SHIFT+TAB)",
|
|
170
190
|
],
|
|
171
191
|
True: [
|
|
172
|
-
"Plan complete!
|
|
173
|
-
"
|
|
174
|
-
"
|
|
175
|
-
"
|
|
176
|
-
"
|
|
192
|
+
"Plan complete! Move to Tasks mode (SHIFT+TAB)",
|
|
193
|
+
"Strategy ready! Time for tasks (SHIFT+TAB to Tasks mode)",
|
|
194
|
+
"Roadmap done! Create task list (SHIFT+TAB for Tasks)",
|
|
195
|
+
"Planning complete! Break into tasks (SHIFT+TAB to Tasks)",
|
|
196
|
+
" ⚡ Plan ready! Advance to Tasks mode (SHIFT+TAB)",
|
|
177
197
|
],
|
|
178
198
|
},
|
|
179
199
|
}
|
|
180
200
|
|
|
181
201
|
def __init__(self, base_path: Path | None = None):
|
|
182
|
-
"""Initialize
|
|
202
|
+
"""Initialize placeholder hints with progress checker.
|
|
183
203
|
|
|
184
204
|
Args:
|
|
185
|
-
base_path: Base path for .
|
|
205
|
+
base_path: Base path for checking progress. Defaults to current directory.
|
|
186
206
|
"""
|
|
187
207
|
self.progress_checker = ModeProgressChecker(base_path)
|
|
188
|
-
self.
|
|
208
|
+
self._cached_hints: dict[tuple[AgentType, bool], str] = {}
|
|
209
|
+
self._hint_indices: dict[tuple[AgentType, bool], int] = {}
|
|
189
210
|
|
|
190
|
-
def
|
|
191
|
-
"""Get a
|
|
211
|
+
def get_hint(self, current_mode: AgentType, force_refresh: bool = False) -> str:
|
|
212
|
+
"""Get a dynamic hint based on current mode and progress.
|
|
192
213
|
|
|
193
214
|
Args:
|
|
194
|
-
|
|
195
|
-
|
|
215
|
+
current_mode: The current agent mode.
|
|
216
|
+
force_refresh: Force recalculation of progress state.
|
|
196
217
|
|
|
197
218
|
Returns:
|
|
198
|
-
A
|
|
219
|
+
A contextual hint string for the placeholder.
|
|
199
220
|
"""
|
|
221
|
+
# Default hint if mode not configured
|
|
222
|
+
if current_mode not in self.HINTS:
|
|
223
|
+
return f"Enter your {current_mode.value} mode prompt (SHIFT+TAB to switch modes)"
|
|
224
|
+
|
|
200
225
|
# Determine if mode has content
|
|
201
|
-
has_content = self.progress_checker.has_mode_content(
|
|
226
|
+
has_content = self.progress_checker.has_mode_content(current_mode)
|
|
202
227
|
|
|
203
|
-
# Get
|
|
204
|
-
|
|
205
|
-
state_hints = mode_hints.get(has_content, [])
|
|
228
|
+
# Get hint variations for this mode and state
|
|
229
|
+
hints_list = self.HINTS[current_mode][has_content]
|
|
206
230
|
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
return (
|
|
210
|
-
f"Type your message for {mode.value} mode (SHIFT+TAB to switch modes)"
|
|
211
|
-
)
|
|
231
|
+
# Cache key for this mode and state
|
|
232
|
+
cache_key = (current_mode, has_content)
|
|
212
233
|
|
|
213
|
-
#
|
|
214
|
-
cache_key
|
|
234
|
+
# Force refresh or first time
|
|
235
|
+
if force_refresh or cache_key not in self._cached_hints:
|
|
236
|
+
# Initialize index for this cache key if not exists
|
|
237
|
+
if cache_key not in self._hint_indices:
|
|
238
|
+
self._hint_indices[cache_key] = random.randint(0, len(hints_list) - 1) # noqa: S311
|
|
215
239
|
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
240
|
+
# Get hint at current index
|
|
241
|
+
hint_index = self._hint_indices[cache_key]
|
|
242
|
+
self._cached_hints[cache_key] = hints_list[hint_index]
|
|
219
243
|
|
|
220
|
-
|
|
221
|
-
hint = random.choice(state_hints) # noqa: S311 - random is fine for UI hints
|
|
222
|
-
self._last_hints[cache_key] = hint
|
|
244
|
+
return self._cached_hints[cache_key]
|
|
223
245
|
|
|
224
|
-
|
|
246
|
+
def get_placeholder_for_mode(self, current_mode: AgentType) -> str:
|
|
247
|
+
"""Get placeholder text for a given mode.
|
|
248
|
+
|
|
249
|
+
This is an alias for get_hint() to maintain compatibility.
|
|
250
|
+
|
|
251
|
+
Args:
|
|
252
|
+
current_mode: The current agent mode.
|
|
253
|
+
|
|
254
|
+
Returns:
|
|
255
|
+
A contextual hint string for the placeholder.
|
|
256
|
+
"""
|
|
257
|
+
return self.get_hint(current_mode)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: shotgun-sh
|
|
3
|
-
Version: 0.1.0.
|
|
3
|
+
Version: 0.1.0.dev24
|
|
4
4
|
Summary: AI-powered research, planning, and task management CLI tool
|
|
5
5
|
Project-URL: Homepage, https://shotgun.sh/
|
|
6
6
|
Project-URL: Repository, https://github.com/shotgun-sh/shotgun
|
|
@@ -16,12 +16,11 @@ Classifier: Intended Audience :: Developers
|
|
|
16
16
|
Classifier: License :: OSI Approved :: MIT License
|
|
17
17
|
Classifier: Operating System :: OS Independent
|
|
18
18
|
Classifier: Programming Language :: Python :: 3
|
|
19
|
-
Classifier: Programming Language :: Python :: 3.10
|
|
20
19
|
Classifier: Programming Language :: Python :: 3.11
|
|
21
20
|
Classifier: Programming Language :: Python :: 3.12
|
|
22
21
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
23
22
|
Classifier: Topic :: Utilities
|
|
24
|
-
Requires-Python: >=3.
|
|
23
|
+
Requires-Python: >=3.11
|
|
25
24
|
Requires-Dist: anthropic>=0.39.0
|
|
26
25
|
Requires-Dist: google-generativeai>=0.8.5
|
|
27
26
|
Requires-Dist: httpx>=0.27.0
|
|
@@ -177,7 +176,7 @@ The update command automatically detects and uses the appropriate method:
|
|
|
177
176
|
|
|
178
177
|
### Requirements
|
|
179
178
|
|
|
180
|
-
- **Python 3.
|
|
179
|
+
- **Python 3.11+** (3.13 recommended)
|
|
181
180
|
- **uv** - Fast Python package installer and resolver
|
|
182
181
|
- **actionlint** (optional) - For GitHub Actions workflow validation
|
|
183
182
|
|
|
@@ -289,17 +288,17 @@ go install github.com/rhysd/actionlint/cmd/actionlint@latest
|
|
|
289
288
|
|
|
290
289
|
### Python Version Management
|
|
291
290
|
|
|
292
|
-
The project supports **Python 3.
|
|
291
|
+
The project supports **Python 3.11+**. The `.python-version` file specifies Python 3.11 to ensure development against the minimum supported version.
|
|
293
292
|
|
|
294
293
|
If using **pyenv**:
|
|
295
294
|
```bash
|
|
296
|
-
pyenv install 3.
|
|
295
|
+
pyenv install 3.11
|
|
297
296
|
```
|
|
298
297
|
|
|
299
298
|
If using **uv** (recommended):
|
|
300
299
|
```bash
|
|
301
|
-
uv python install 3.
|
|
302
|
-
uv sync --python 3.
|
|
300
|
+
uv python install 3.11
|
|
301
|
+
uv sync --python 3.11
|
|
303
302
|
```
|
|
304
303
|
|
|
305
304
|
### Commit Message Convention
|
|
@@ -350,7 +349,7 @@ uv run cz commit
|
|
|
350
349
|
|
|
351
350
|
GitHub Actions automatically:
|
|
352
351
|
- Runs on pull requests and pushes to main
|
|
353
|
-
- Tests with Python 3.
|
|
352
|
+
- Tests with Python 3.11
|
|
354
353
|
- Validates code with ruff, ruff-format, and mypy
|
|
355
354
|
- Ensures all checks pass before merge
|
|
356
355
|
|
|
@@ -1,21 +1,22 @@
|
|
|
1
1
|
shotgun/__init__.py,sha256=P40K0fnIsb7SKcQrFnXZ4aREjpWchVDhvM1HxI4cyIQ,104
|
|
2
2
|
shotgun/build_constants.py,sha256=RXNxMz46HaB5jucgMVpw8a2yCJqjbhTOh0PddyEVMN8,713
|
|
3
3
|
shotgun/logging_config.py,sha256=qWPTKu6IhaA_qiHQFhx8zTphm6oHMZFXox2nieyV32M,6795
|
|
4
|
-
shotgun/main.py,sha256=
|
|
4
|
+
shotgun/main.py,sha256=dW8eqWZM7NAmzkuglZWdJeAzHiKbLKnnUw5V698X4GM,5112
|
|
5
5
|
shotgun/posthog_telemetry.py,sha256=7drAXtedvZmpPqq4_9dI19kJ_xEHGk7XKXQk797QvCM,4954
|
|
6
6
|
shotgun/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
7
7
|
shotgun/sentry_telemetry.py,sha256=3r9on0GQposn9aX6Dkb9mrfaVQl_dIZzhu9BjE838AU,2854
|
|
8
8
|
shotgun/telemetry.py,sha256=aBwCRFU97oiIK5K13OhT7yYCQUAVQyrvnoG-aX3k2ZE,3109
|
|
9
9
|
shotgun/agents/__init__.py,sha256=8Jzv1YsDuLyNPFJyckSr_qI4ehTVeDyIMDW4omsfPGc,25
|
|
10
|
-
shotgun/agents/agent_manager.py,sha256=
|
|
11
|
-
shotgun/agents/
|
|
12
|
-
shotgun/agents/
|
|
13
|
-
shotgun/agents/
|
|
14
|
-
shotgun/agents/
|
|
15
|
-
shotgun/agents/
|
|
16
|
-
shotgun/agents/
|
|
17
|
-
shotgun/agents/
|
|
18
|
-
shotgun/agents/
|
|
10
|
+
shotgun/agents/agent_manager.py,sha256=ApRzriE3mvAms5144rQ4Vjv1JWvRS89DruTtBvgVPdg,20235
|
|
11
|
+
shotgun/agents/common.py,sha256=z4MOOHXpGWVpnxfGbOmfz-gYX9r8gjzcPPIOAJ9-2hc,15704
|
|
12
|
+
shotgun/agents/conversation_history.py,sha256=vw7LMOCmpkidQGAidPIxPly2sh1k1K-5NF3iYkXOAAU,1815
|
|
13
|
+
shotgun/agents/conversation_manager.py,sha256=fxAvXbEl3Cl2ugJ4N9aWXaqZtkrnfj3QzwjWC4LFXwI,3514
|
|
14
|
+
shotgun/agents/export.py,sha256=Zke952DbJ_lOBUmN-TPHw7qmjbfqsFu1uycBRQI_pkg,2969
|
|
15
|
+
shotgun/agents/models.py,sha256=MzQJFHZ7F_q2VEl48LDzuwroi0bvPR74g9qq5Zkqkq4,7339
|
|
16
|
+
shotgun/agents/plan.py,sha256=s-WfILBOW4l8kY59RUOVtX5MJSuSzFm1nGp6b17If78,3030
|
|
17
|
+
shotgun/agents/research.py,sha256=lYG7Rytcitop8mXs3isMI3XvYzzI3JH9u0VZz6K9zfo,3274
|
|
18
|
+
shotgun/agents/specify.py,sha256=7MoMxfIn34G27mw6wrp_F0i2O5rid476L3kHFONDCd0,3137
|
|
19
|
+
shotgun/agents/tasks.py,sha256=nk8zIl24o01hfzOGyWSbeVWeke6OGseO4Ppciurh13U,2999
|
|
19
20
|
shotgun/agents/config/__init__.py,sha256=Fl8K_81zBpm-OfOW27M_WWLSFdaHHek6lWz95iDREjQ,318
|
|
20
21
|
shotgun/agents/config/constants.py,sha256=c1k7LFvx29rzQCUXxyfr2PukwS5ol8rH8AXQaxALPVM,526
|
|
21
22
|
shotgun/agents/config/manager.py,sha256=kwMbPjz0kEH_WCQAamESGjHdE8d_P-ztel4NL4FWNUw,10662
|
|
@@ -31,8 +32,7 @@ shotgun/agents/history/message_utils.py,sha256=S7wqix4W3uvC8rChs6TMxp7yjnjr8a2Aq
|
|
|
31
32
|
shotgun/agents/history/token_counting.py,sha256=RasWy84eNjbmqyQDTGAzj1Q1I9ml_G_9R-maWN7gr8s,13839
|
|
32
33
|
shotgun/agents/history/token_estimation.py,sha256=iNqhDSqFzG0YYxGijMRzj54GALFglOp0qVMB6G59RhU,4690
|
|
33
34
|
shotgun/agents/tools/__init__.py,sha256=QaN80IqWvB5qEcjHqri1-PYvYlO74vdhcwLugoEdblo,772
|
|
34
|
-
shotgun/agents/tools/
|
|
35
|
-
shotgun/agents/tools/file_management.py,sha256=6ru6DXAl-S6DiCt2HLGTDrK2rJBJpn-t6RkSHzYbxc4,4571
|
|
35
|
+
shotgun/agents/tools/file_management.py,sha256=XvRBwz7KmlwqQlAbYraDCo9murk5oko1zLo2g2fGeOA,7100
|
|
36
36
|
shotgun/agents/tools/user_interaction.py,sha256=b3ncEpvoD06Cz4hwsS-ppVbQajQj640iWnVfA5WBjAA,1236
|
|
37
37
|
shotgun/agents/tools/codebase/__init__.py,sha256=ceAGkK006NeOYaIJBLQsw7Q46sAyCRK9PYDs8feMQVw,661
|
|
38
38
|
shotgun/agents/tools/codebase/codebase_shell.py,sha256=9b7ZStAVFprdGqp1O23ZgwkToMytlUdp_R4MhvmENhc,8584
|
|
@@ -46,20 +46,6 @@ shotgun/agents/tools/web_search/anthropic.py,sha256=IEcSujX5F7-b-87HZqcCHfp3C_E0
|
|
|
46
46
|
shotgun/agents/tools/web_search/gemini.py,sha256=hXjWUF-aTX3B9ViaKe5aF2aHXlaoBA5am40cgilinGE,2981
|
|
47
47
|
shotgun/agents/tools/web_search/openai.py,sha256=V8GeqwUAi5wrbRuU41Y38schpXRdyeIfw85-CT5rAhY,3415
|
|
48
48
|
shotgun/agents/tools/web_search/utils.py,sha256=GLJ5QV9bT2ubFMuFN7caMN7tK9OTJ0R3GD57B-tCMF0,532
|
|
49
|
-
shotgun/artifacts/__init__.py,sha256=FMgUfa1XzmLVMyYdTFWN1NpQDB9LfmJdnvhRvbVZaDA,494
|
|
50
|
-
shotgun/artifacts/exceptions.py,sha256=iaGYlTw7iOqjyzunrSvZS8FZXtL_BZHJmKMkZKqRZoI,3074
|
|
51
|
-
shotgun/artifacts/manager.py,sha256=DtL0P8SldF4Qb8lL8lg-WRdSvdK0DDJEIjVHxtzSh1E,19533
|
|
52
|
-
shotgun/artifacts/models.py,sha256=RjqLBKnymgXrT-FqvzgzDW7IHUO--L1ODuSQF6lXNew,12291
|
|
53
|
-
shotgun/artifacts/service.py,sha256=EJR9F8UcGI9qjOzq_SzF7J0qHTrPBML3cYk9RA6bcMA,14546
|
|
54
|
-
shotgun/artifacts/utils.py,sha256=UNz1hkPH2qaHJsS2KWMT0BUcSaDydIKmQPrVtNiLWHg,2176
|
|
55
|
-
shotgun/artifacts/templates/__init__.py,sha256=X0qT2IofYOdotDMi7a7JGbgKOLCRWksHS7Pcz81vHRk,246
|
|
56
|
-
shotgun/artifacts/templates/loader.py,sha256=qLAOibYH55l1kF3Yd3GU5uLVfF0CDUml-vtqgTZ9YhA,8742
|
|
57
|
-
shotgun/artifacts/templates/models.py,sha256=Y4BhTNhbjZJvBHsf5op569meRq96imggrt5ZjnkeaDg,4879
|
|
58
|
-
shotgun/artifacts/templates/plan/delivery_and_release_plan.yaml,sha256=HOdOCvVpEu9Qnrf5gll0oqY9v-_vapczyfmaB6c8cAg,3289
|
|
59
|
-
shotgun/artifacts/templates/research/market_research.yaml,sha256=uoOw5s6kUVwSBhhk6LfcCqZQZUC4BNUQnkeEYEYQ1VE,24744
|
|
60
|
-
shotgun/artifacts/templates/research/sdk_comparison.yaml,sha256=grQe52wbGZqdnHx_6gJc88dBdByeWkAtzU3G7HhmyGA,11074
|
|
61
|
-
shotgun/artifacts/templates/specify/prd.yaml,sha256=LTtTOERjYe1iGV7Wj-WJEExcbHp-zb3LMgweuboXmiM,10784
|
|
62
|
-
shotgun/artifacts/templates/specify/product_spec.yaml,sha256=BAubivc75VnNZVRqGK9kX1TxZDn-e2_eYbuZGaKvk2U,13953
|
|
63
49
|
shotgun/cli/__init__.py,sha256=_F1uW2g87y4bGFxz8Gp8u7mq2voHp8vQIUtCmm8Tojo,40
|
|
64
50
|
shotgun/cli/config.py,sha256=LbjxDNPdetYJiwlcyOYLnqwzALfgU-m54cfstUshbrs,8715
|
|
65
51
|
shotgun/cli/export.py,sha256=3hIwK2_OM1MFYSTfzBxsGuuBGm5fo0XdxASfQ5Uqb3Y,2471
|
|
@@ -74,32 +60,29 @@ shotgun/cli/codebase/__init__.py,sha256=rKdvx33p0i_BYbNkz5_4DCFgEMwzOOqLi9f5p7XT
|
|
|
74
60
|
shotgun/cli/codebase/commands.py,sha256=zvcM9gjHHO6styhXojb_1bnpq-Cozh2c77ZOIjw4B8s,6683
|
|
75
61
|
shotgun/cli/codebase/models.py,sha256=B9vs-d-Bq0aS6FZKebhHT-9tw90Y5f6k_t71VlZpL8k,374
|
|
76
62
|
shotgun/codebase/__init__.py,sha256=QBgFE2Abd5Vl7_NdYOglF9S6d-vIjkb3C0cpIYoHZEU,309
|
|
77
|
-
shotgun/codebase/models.py,sha256=
|
|
78
|
-
shotgun/codebase/service.py,sha256=
|
|
63
|
+
shotgun/codebase/models.py,sha256=hxjbfDUka8loTApXq9KTvkXKt272fzdjr5u2ImYrNtk,4367
|
|
64
|
+
shotgun/codebase/service.py,sha256=IK7h6IW84cblpHZVx5z9ulLDqJImGg6L9aZJimijBu8,6804
|
|
79
65
|
shotgun/codebase/core/__init__.py,sha256=GWWhJEqChiDXAF4omYCgzgoZmJjwsAf6P1aZ5Bl8OE0,1170
|
|
80
66
|
shotgun/codebase/core/change_detector.py,sha256=kWCYLWzRzb3IGGOj71KBn7UOCOKMpINJbOBDf98aMxE,12409
|
|
81
67
|
shotgun/codebase/core/code_retrieval.py,sha256=_JVyyQKHDFm3dxOOua1mw9eIIOHIVz3-I8aZtEsEj1E,7927
|
|
82
|
-
shotgun/codebase/core/ingestor.py,sha256=
|
|
68
|
+
shotgun/codebase/core/ingestor.py,sha256=H_kVCqdOKmnQpjcXvUdPFpep8OC2AbOhhE-9HKr_XZM,59836
|
|
83
69
|
shotgun/codebase/core/language_config.py,sha256=vsqHyuFnumRPRBV1lMOxWKNOIiClO6FyfKQR0fGrtl4,8934
|
|
84
|
-
shotgun/codebase/core/manager.py,sha256=
|
|
70
|
+
shotgun/codebase/core/manager.py,sha256=6gyjfACbC5n1Hdy-JQIEDH2aNAlesUS9plQP_FHoJ94,59277
|
|
85
71
|
shotgun/codebase/core/nl_query.py,sha256=iV6NbsyDd1SQpT9U9BtgxcZPsNoEW3OHrkk475r_jAY,11410
|
|
86
72
|
shotgun/codebase/core/parser_loader.py,sha256=LZRrDS8Sp518jIu3tQW-BxdwJ86lnsTteI478ER9Td8,4278
|
|
87
73
|
shotgun/prompts/__init__.py,sha256=RswUm0HMdfm2m2YKUwUsEdRIwoczdbI7zlucoEvHYRo,132
|
|
88
74
|
shotgun/prompts/loader.py,sha256=jy24-E02pCSmz2651aCT2NgHfRrHAGMYvKrD6gs0Er8,4424
|
|
89
75
|
shotgun/prompts/agents/__init__.py,sha256=YRIJMbzpArojNX1BP5gfxxois334z_GQga8T-xyWMbY,39
|
|
90
|
-
shotgun/prompts/agents/export.j2,sha256=
|
|
91
|
-
shotgun/prompts/agents/plan.j2,sha256=
|
|
92
|
-
shotgun/prompts/agents/research.j2,sha256=
|
|
93
|
-
shotgun/prompts/agents/specify.j2,sha256=
|
|
94
|
-
shotgun/prompts/agents/tasks.j2,sha256=
|
|
95
|
-
shotgun/prompts/agents/partials/artifact_system.j2,sha256=kaqkMU-t2x3M7z-4HU4KffSFug1WM5VDsin6tCkxjHg,1528
|
|
76
|
+
shotgun/prompts/agents/export.j2,sha256=YPZPm50l-e57m9kyYJ6EIDFwBhrjNe2ly8cBLyOuS60,4475
|
|
77
|
+
shotgun/prompts/agents/plan.j2,sha256=4dAKUrgP05qiovDRlp2_ljl4eyUz5rwhHOI-V4-BtCc,2289
|
|
78
|
+
shotgun/prompts/agents/research.j2,sha256=TpMn6MEq3sUeCawzFykJovBW6GpNiTEUGl63vMC77zM,2840
|
|
79
|
+
shotgun/prompts/agents/specify.j2,sha256=u6eE3_HE9427n6Z2lTKNjlQmaR80kEaSWWQtijiMXvw,1654
|
|
80
|
+
shotgun/prompts/agents/tasks.j2,sha256=pQjLayZ-CyyUzmqgWxNTTGmXj91vuhV385xyVbVupTo,3632
|
|
96
81
|
shotgun/prompts/agents/partials/codebase_understanding.j2,sha256=7WH-PVd-TRBFQUdOdKkwwn9hAUaJznFZMAGHhO7IGGU,5633
|
|
97
|
-
shotgun/prompts/agents/partials/common_agent_system_prompt.j2,sha256=
|
|
82
|
+
shotgun/prompts/agents/partials/common_agent_system_prompt.j2,sha256=f5cpo2Ds7EceHvXYUHNs_1NoXv_K4BrWduXYcT2PL40,1803
|
|
98
83
|
shotgun/prompts/agents/partials/content_formatting.j2,sha256=MG0JB7SSp8YV5akDWpbs2f9DcdREIYqLp38NnoWLeQ0,1854
|
|
99
84
|
shotgun/prompts/agents/partials/interactive_mode.j2,sha256=9sYPbyc46HXg3k1FT_LugIQvOyNDnMQwsMIgOgN-_aY,1100
|
|
100
|
-
shotgun/prompts/agents/state/
|
|
101
|
-
shotgun/prompts/agents/state/existing_artifacts_available.j2,sha256=gb5gKYeOXcJmIkkDS1JOm68AEymLutlxNow5HTtev7I,739
|
|
102
|
-
shotgun/prompts/agents/state/system_state.j2,sha256=NFuBOo7cGy0tQrnDUs3wGO19oytGNHK2K8tgoG4cw1M,274
|
|
85
|
+
shotgun/prompts/agents/state/system_state.j2,sha256=k7WICOLFCZ7yhH004AzqCBJ1U0MCF56ODSzdb7fe7Ck,905
|
|
103
86
|
shotgun/prompts/agents/state/codebase/codebase_graphs_available.j2,sha256=U-hy-H9bPwV0sYIHTZ5TESxc5EOCtntI8GUZOmJipJw,601
|
|
104
87
|
shotgun/prompts/codebase/__init__.py,sha256=NYuPMtmYM2ptuwf3YxVuotNlJOUq0hnjmwlzKcJkGK4,42
|
|
105
88
|
shotgun/prompts/codebase/cypher_query_patterns.j2,sha256=ufTx_xT3VoS76KcVUbIgGQx-bJoJHx3bBE3dagAXv18,8913
|
|
@@ -112,36 +95,34 @@ shotgun/prompts/history/__init__.py,sha256=wbMLQ8yWmYz1sfXXigEAUlNkFcM50KdQv0kp4
|
|
|
112
95
|
shotgun/prompts/history/incremental_summarization.j2,sha256=GmnNh0pWTjaEaI1sPwKNsGCys5fK8xrzWqalAs_LhJw,2447
|
|
113
96
|
shotgun/prompts/history/summarization.j2,sha256=OYNVHg65zbuWB6_pXzTOs2T2k5qFD2gyfbmr6NP01rs,2268
|
|
114
97
|
shotgun/sdk/__init__.py,sha256=ESV0WM9MigjXG30g9qVjcCMI40GQv-P-MSMGVuOisK4,380
|
|
115
|
-
shotgun/sdk/
|
|
116
|
-
shotgun/sdk/artifacts.py,sha256=YbGPdDFd9ORt1vDWSbbPhGlSZ6MXLS6N0kcucxDDEc4,14818
|
|
117
|
-
shotgun/sdk/codebase.py,sha256=T8QprL7_PKmAFNpo341NjHczJsd1lfptAR2ZQ-oNK3Q,6064
|
|
98
|
+
shotgun/sdk/codebase.py,sha256=EYujvSl1EcQ1WfMjAvrX-h2H5_gHdcnmscQDaUxsCho,6965
|
|
118
99
|
shotgun/sdk/exceptions.py,sha256=qBcQv0v7ZTwP7CMcxZST4GqCsfOWtOUjSzGBo0-heqo,412
|
|
119
100
|
shotgun/sdk/models.py,sha256=X9nOTUHH0cdkQW1NfnMEDu-QgK9oUsEISh1Jtwr5Am4,5496
|
|
120
|
-
shotgun/sdk/services.py,sha256=
|
|
101
|
+
shotgun/sdk/services.py,sha256=J4PJFSxCQ6--u7rb3Ta-9eYtlYcxcbnzrMP6ThyCnw4,705
|
|
121
102
|
shotgun/tui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
122
|
-
shotgun/tui/app.py,sha256=
|
|
103
|
+
shotgun/tui/app.py,sha256=t0IAQbGr0lKKEoBVnp85DcmZ-V92bi79SjyEE2uKpuw,3990
|
|
123
104
|
shotgun/tui/styles.tcss,sha256=ETyyw1bpMBOqTi5RLcAJUScdPWTvAWEqE9YcT0kVs_E,121
|
|
124
105
|
shotgun/tui/commands/__init__.py,sha256=Wy8s8TBSA3twK6agtsf57EFV2VfL8HGvEBF1VOg5-mM,2535
|
|
125
106
|
shotgun/tui/components/prompt_input.py,sha256=Ss-htqraHZAPaehGE4x86ij0veMjc4UgadMXpbdXr40,2229
|
|
126
107
|
shotgun/tui/components/spinner.py,sha256=ovTDeaJ6FD6chZx_Aepia6R3UkPOVJ77EKHfRmn39MY,2427
|
|
127
108
|
shotgun/tui/components/splash.py,sha256=vppy9vEIEvywuUKRXn2y11HwXSRkQZHLYoVjhDVdJeU,1267
|
|
128
109
|
shotgun/tui/components/vertical_tail.py,sha256=kkCH0WjAh54jDvRzIaOffRZXUKn_zHFZ_ichfUpgzaE,1071
|
|
129
|
-
shotgun/tui/screens/chat.py,sha256
|
|
110
|
+
shotgun/tui/screens/chat.py,sha256=UlyFrd3OISB-M62R3fGBb-E9CoD6G4untbMVfDUSV3U,27820
|
|
130
111
|
shotgun/tui/screens/chat.tcss,sha256=2Yq3E23jxsySYsgZf4G1AYrYVcpX0UDW6kNNI0tDmtM,437
|
|
131
112
|
shotgun/tui/screens/directory_setup.py,sha256=lIZ1J4A6g5Q2ZBX8epW7BhR96Dmdcg22CyiM5S-I5WU,3237
|
|
132
113
|
shotgun/tui/screens/provider_config.py,sha256=A_tvDHF5KLP5PV60LjMJ_aoOdT3TjI6_g04UIUqGPqM,7126
|
|
133
114
|
shotgun/tui/screens/splash.py,sha256=E2MsJihi3c9NY1L28o_MstDxGwrCnnV7zdq00MrGAsw,706
|
|
134
115
|
shotgun/tui/screens/chat_screen/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
135
|
-
shotgun/tui/screens/chat_screen/command_providers.py,sha256=
|
|
136
|
-
shotgun/tui/screens/chat_screen/history.py,sha256=
|
|
116
|
+
shotgun/tui/screens/chat_screen/command_providers.py,sha256=55JIH9T8QnyHRsMoXhOi87FiVM-d6o7OKpCe82uDP9I,7840
|
|
117
|
+
shotgun/tui/screens/chat_screen/history.py,sha256=AP8wdXCxQ0uZeZE29WnLF6RCaZjcJzG97tjzqXFceoY,7711
|
|
137
118
|
shotgun/tui/utils/__init__.py,sha256=cFjDfoXTRBq29wgP7TGRWUu1eFfiIG-LLOzjIGfadgI,150
|
|
138
|
-
shotgun/tui/utils/mode_progress.py,sha256=
|
|
119
|
+
shotgun/tui/utils/mode_progress.py,sha256=lseRRo7kMWLkBzI3cU5vqJmS2ZcCjyRYf9Zwtvc-v58,10931
|
|
139
120
|
shotgun/utils/__init__.py,sha256=WinIEp9oL2iMrWaDkXz2QX4nYVPAm8C9aBSKTeEwLtE,198
|
|
140
121
|
shotgun/utils/env_utils.py,sha256=8QK5aw_f_V2AVTleQQlcL0RnD4sPJWXlDG46fsHu0d8,1057
|
|
141
122
|
shotgun/utils/file_system_utils.py,sha256=l-0p1bEHF34OU19MahnRFdClHufThfGAjQ431teAIp0,1004
|
|
142
123
|
shotgun/utils/update_checker.py,sha256=Xf-7w3Pos3etzCoT771gJe2HLkA8_V2GrqWy7ni9UqA,11373
|
|
143
|
-
shotgun_sh-0.1.0.
|
|
144
|
-
shotgun_sh-0.1.0.
|
|
145
|
-
shotgun_sh-0.1.0.
|
|
146
|
-
shotgun_sh-0.1.0.
|
|
147
|
-
shotgun_sh-0.1.0.
|
|
124
|
+
shotgun_sh-0.1.0.dev24.dist-info/METADATA,sha256=mB7WwoiAOFmL6UFlltGz7UR8CD_nhRAgJict5L7i574,11197
|
|
125
|
+
shotgun_sh-0.1.0.dev24.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
126
|
+
shotgun_sh-0.1.0.dev24.dist-info/entry_points.txt,sha256=asZxLU4QILneq0MWW10saVCZc4VWhZfb0wFZvERnzfA,45
|
|
127
|
+
shotgun_sh-0.1.0.dev24.dist-info/licenses/LICENSE,sha256=YebsZl590zCHrF_acCU5pmNt0pnAfD2DmAnevJPB1tY,1065
|
|
128
|
+
shotgun_sh-0.1.0.dev24.dist-info/RECORD,,
|
shotgun/agents/artifact_state.py
DELETED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
"""Utilities for collecting and organizing artifact state information."""
|
|
2
|
-
|
|
3
|
-
from datetime import datetime
|
|
4
|
-
from typing import TypedDict
|
|
5
|
-
|
|
6
|
-
from shotgun.artifacts.models import ArtifactSummary
|
|
7
|
-
from shotgun.artifacts.templates.models import TemplateSummary
|
|
8
|
-
from shotgun.sdk.services import get_artifact_service
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
class ArtifactState(TypedDict):
|
|
12
|
-
"""Type definition for artifact state information."""
|
|
13
|
-
|
|
14
|
-
available_templates: dict[str, list[TemplateSummary]]
|
|
15
|
-
existing_artifacts: dict[str, list[ArtifactSummary]]
|
|
16
|
-
current_date: str
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
def collect_artifact_state() -> ArtifactState:
|
|
20
|
-
"""Collect and organize artifact state information for system context.
|
|
21
|
-
|
|
22
|
-
Returns:
|
|
23
|
-
ArtifactState containing organized templates and artifacts by mode, plus current date
|
|
24
|
-
"""
|
|
25
|
-
artifact_service = get_artifact_service()
|
|
26
|
-
|
|
27
|
-
# Get available templates
|
|
28
|
-
available_templates_list = artifact_service.list_templates()
|
|
29
|
-
|
|
30
|
-
# Group templates by mode for better organization
|
|
31
|
-
templates_by_mode: dict[str, list[TemplateSummary]] = {}
|
|
32
|
-
for template in available_templates_list:
|
|
33
|
-
mode_name = template.template_id.split("/")[0]
|
|
34
|
-
if mode_name not in templates_by_mode:
|
|
35
|
-
templates_by_mode[mode_name] = []
|
|
36
|
-
templates_by_mode[mode_name].append(template)
|
|
37
|
-
|
|
38
|
-
# Get ALL existing artifacts regardless of current agent mode for complete visibility
|
|
39
|
-
existing_artifacts_list = (
|
|
40
|
-
artifact_service.list_artifacts()
|
|
41
|
-
) # No mode filter = all modes
|
|
42
|
-
|
|
43
|
-
# Group artifacts by mode for organized display
|
|
44
|
-
artifacts_by_mode: dict[str, list[ArtifactSummary]] = {}
|
|
45
|
-
for artifact in existing_artifacts_list:
|
|
46
|
-
mode_name = artifact.agent_mode.value
|
|
47
|
-
if mode_name not in artifacts_by_mode:
|
|
48
|
-
artifacts_by_mode[mode_name] = []
|
|
49
|
-
artifacts_by_mode[mode_name].append(artifact)
|
|
50
|
-
|
|
51
|
-
# Get current date for temporal context (month in words for clarity)
|
|
52
|
-
current_date = datetime.now().strftime("%B %d, %Y")
|
|
53
|
-
|
|
54
|
-
return {
|
|
55
|
-
"available_templates": templates_by_mode,
|
|
56
|
-
"existing_artifacts": artifacts_by_mode,
|
|
57
|
-
"current_date": current_date,
|
|
58
|
-
}
|