wcgw 3.0.7__tar.gz → 4.1.0__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.
Potentially problematic release.
This version of wcgw might be problematic. Click here for more details.
- {wcgw-3.0.7 → wcgw-4.1.0}/.github/workflows/python-tests.yml +1 -2
- wcgw-4.1.0/CLAUDE.md +41 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/PKG-INFO +39 -20
- {wcgw-3.0.7 → wcgw-4.1.0}/README.md +38 -18
- {wcgw-3.0.7 → wcgw-4.1.0}/gpt_action_json_schema.json +39 -116
- {wcgw-3.0.7 → wcgw-4.1.0}/gpt_instructions.txt +12 -11
- {wcgw-3.0.7 → wcgw-4.1.0}/pyproject.toml +1 -2
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/bash_state/bash_state.py +184 -13
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/diff-instructions.txt +29 -15
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/file_ops/diff_edit.py +44 -47
- wcgw-4.1.0/src/wcgw/client/file_ops/search_replace.py +195 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/mcp_server/server.py +7 -3
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/memory.py +5 -2
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/modes.py +19 -10
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/repo_ops/display_tree.py +3 -3
- wcgw-4.1.0/src/wcgw/client/repo_ops/file_stats.py +152 -0
- wcgw-4.1.0/src/wcgw/client/repo_ops/repo_context.py +289 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/tool_prompts.py +14 -16
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/tools.py +496 -81
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/relay/serve.py +8 -53
- wcgw-4.1.0/src/wcgw/types_.py +233 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw_cli/anthropic_client.py +1 -1
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw_cli/openai_client.py +1 -1
- wcgw-4.1.0/static/workflow-demo.gif +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/tests/test_edit.py +149 -19
- wcgw-4.1.0/tests/test_file_range_tracking.py +144 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/tests/test_mcp_server.py +6 -7
- wcgw-4.1.0/tests/test_readfiles.py +89 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/tests/test_tools.py +91 -12
- {wcgw-3.0.7 → wcgw-4.1.0}/uv.lock +1 -12
- wcgw-3.0.7/src/wcgw/client/file_ops/search_replace.py +0 -160
- wcgw-3.0.7/src/wcgw/client/repo_ops/repo_context.py +0 -148
- wcgw-3.0.7/src/wcgw/types_.py +0 -146
- {wcgw-3.0.7 → wcgw-4.1.0}/.github/workflows/python-publish.yml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/.github/workflows/python-types.yml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/.gitignore +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/.gitmodules +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/.python-version +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/.vscode/settings.json +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/Dockerfile +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/LICENSE +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/openai.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.git +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.github/workflows/main-checks.yml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.github/workflows/publish-pypi.yml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.github/workflows/pull-request-checks.yml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.github/workflows/shared.yml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.gitignore +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/.python-version +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/CODE_OF_CONDUCT.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/CONTRIBUTING.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/LICENSE +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/README.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/RELEASE.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/SECURITY.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/README.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-prompt/.python-version +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-prompt/README.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-prompt/mcp_simple_prompt/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-prompt/mcp_simple_prompt/__main__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-prompt/mcp_simple_prompt/server.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-prompt/pyproject.toml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-resource/.python-version +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-resource/README.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-resource/mcp_simple_resource/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-resource/mcp_simple_resource/__main__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-resource/mcp_simple_resource/server.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-resource/pyproject.toml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-tool/.python-version +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-tool/README.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-tool/mcp_simple_tool/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-tool/mcp_simple_tool/__main__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-tool/mcp_simple_tool/server.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/examples/servers/simple-tool/pyproject.toml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/pyproject.toml +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/client/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/client/__main__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/client/session.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/client/sse.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/client/stdio.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/py.typed +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/server/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/server/__main__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/server/models.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/server/session.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/server/sse.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/server/stdio.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/server/websocket.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/shared/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/shared/context.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/shared/exceptions.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/shared/memory.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/shared/progress.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/shared/session.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/shared/version.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/src/mcp_wcgw/types.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/client/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/client/test_session.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/client/test_stdio.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/conftest.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/server/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/server/test_session.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/server/test_stdio.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/shared/test_memory.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/tests/test_types.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/mcp_wcgw_fork/uv.lock +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/common.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/encoder/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/mcp_server/Readme.md +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/mcp_server/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/repo_ops/path_prob.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/repo_ops/paths_model.vocab +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/client/repo_ops/paths_tokens.model +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/py.typed +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/relay/client.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw/relay/static/privacy.txt +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw_cli/__init__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw_cli/__main__.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw_cli/cli.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/src/wcgw_cli/openai_utils.py +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/static/claude-ss.jpg +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/static/computer-use.jpg +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/static/example.jpg +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/static/rocket-icon.png +0 -0
- {wcgw-3.0.7 → wcgw-4.1.0}/static/ss1.png +0 -0
|
@@ -28,8 +28,7 @@ jobs:
|
|
|
28
28
|
uv venv --python "${{ matrix.python-version }}"
|
|
29
29
|
- name: Run tests with coverage
|
|
30
30
|
run: |
|
|
31
|
-
uv
|
|
32
|
-
uv run pytest --cov=wcgw --cov-report=xml --cov-report=term-missing
|
|
31
|
+
uv run --python "${{ matrix.python-version }}" pytest --cov=wcgw --cov-report=xml --cov-report=term-missing
|
|
33
32
|
- name: Upload coverage reports to Codecov
|
|
34
33
|
uses: codecov/codecov-action@v4
|
|
35
34
|
if: success()
|
wcgw-4.1.0/CLAUDE.md
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# Alignment instructions to contribute to this repository
|
|
2
|
+
|
|
3
|
+
## Hard rules
|
|
4
|
+
|
|
5
|
+
- Make sure mypy --strict passes for these two folders `uv run mypy --strict src/wcgw src/wcgw_cli`.
|
|
6
|
+
- Use `list` directly for typing like `list[str]` no need to import `List`. Same thing for `tuple`, `set`, etc.
|
|
7
|
+
- No optional parameters in a function with default values. All parameters must be passed by a caller.
|
|
8
|
+
- This library uses `uv` as package manager. To add a package `uv add numpy`. To run pytest `uv run pytest` and so on.
|
|
9
|
+
|
|
10
|
+
## Coding mantras
|
|
11
|
+
|
|
12
|
+
### Reduce states and dependencies between the states
|
|
13
|
+
|
|
14
|
+
- Don't introduce any state unless really necessary.
|
|
15
|
+
- If anything can be derived, avoid storing it or passing it.
|
|
16
|
+
|
|
17
|
+
#### Python `Exception` guideline 1
|
|
18
|
+
|
|
19
|
+
- Exception thrown inside functions are their hidden extra state which should be avoided.
|
|
20
|
+
- Parse don't validate: avoid throwing validation errors by letting the types avoid bad values to be passed in the first place.
|
|
21
|
+
|
|
22
|
+
### Put burden on type checker not the code reader
|
|
23
|
+
|
|
24
|
+
- No hidden contracts and assumptions.
|
|
25
|
+
- Don't assume any relationship between two states unless it's encoded in the type of the state.
|
|
26
|
+
- Any contract should be enforced by the way types are constructed.
|
|
27
|
+
- If it's just not possible due to complexity to type in such a way to avoid hidden contract, add in docstring details.
|
|
28
|
+
|
|
29
|
+
#### Python `Exception` guideline 2
|
|
30
|
+
|
|
31
|
+
- When you can't avoid it, instead of enforcing the hidden contract as hard failure during runtime, try to return some sensible value instead.
|
|
32
|
+
_Example_
|
|
33
|
+
In PIL adding boxes outside image bounds don't do anything, but they don't fail either, making it a cleaner experience to deal with edge cases.
|
|
34
|
+
|
|
35
|
+
- A functions signature (along with types) should be enough to understand its purpose.
|
|
36
|
+
- This can be achieved by typing the parameters to only take narrow types
|
|
37
|
+
|
|
38
|
+
### Functions should be as pure as possible
|
|
39
|
+
|
|
40
|
+
- Avoid mutating mutable input parameters, instead return newly derived values in the output and leave upto the caller to update the state if required.
|
|
41
|
+
- It should be clear from function signature what the function computes, this should also enforce the previous point of not updating mutable input parameters.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: wcgw
|
|
3
|
-
Version:
|
|
3
|
+
Version: 4.1.0
|
|
4
4
|
Summary: Shell and coding agent on claude and chatgpt
|
|
5
5
|
Project-URL: Homepage, https://github.com/rusiaaman/wcgw
|
|
6
6
|
Author-email: Aman Rusia <gapypi@arcfu.com>
|
|
@@ -17,7 +17,6 @@ Requires-Dist: pyte>=0.8.2
|
|
|
17
17
|
Requires-Dist: python-dotenv>=1.0.1
|
|
18
18
|
Requires-Dist: rich>=13.8.1
|
|
19
19
|
Requires-Dist: semantic-version>=2.10.0
|
|
20
|
-
Requires-Dist: shell>=1.0.1
|
|
21
20
|
Requires-Dist: syntax-checker>=0.3.0
|
|
22
21
|
Requires-Dist: tokenizers>=0.21.0
|
|
23
22
|
Requires-Dist: toml>=0.10.2
|
|
@@ -30,8 +29,8 @@ Description-Content-Type: text/markdown
|
|
|
30
29
|
|
|
31
30
|
Empowering chat applications to code, build and run on your local machine.
|
|
32
31
|
|
|
33
|
-
- Claude -
|
|
34
|
-
- Chatgpt - Allows custom gpt to talk to your shell via a relay server. (linux
|
|
32
|
+
- Claude - MCP server with tightly integrated shell and code editing tools.
|
|
33
|
+
- Chatgpt - Allows custom gpt to talk to your shell via a relay server. (linux, mac, windows on wsl)
|
|
35
34
|
|
|
36
35
|
⚠️ Warning: do not allow BashCommand tool without reviewing the command, it may result in data loss.
|
|
37
36
|
|
|
@@ -39,10 +38,16 @@ Empowering chat applications to code, build and run on your local machine.
|
|
|
39
38
|
[](https://github.com/rusiaaman/wcgw/actions/workflows/python-types.yml)
|
|
40
39
|
[](https://github.com/rusiaaman/wcgw/actions/workflows/python-publish.yml)
|
|
41
40
|
[](https://codecov.io/gh/rusiaaman/wcgw)
|
|
42
|
-
[](https://www.reddit.com/r/wcgw_mcp/)
|
|
42
|
+
|
|
43
|
+
## Demo
|
|
44
|
+
|
|
45
|
+

|
|
43
46
|
|
|
44
47
|
## Updates
|
|
45
48
|
|
|
49
|
+
- [24 Mar 2025] Improved writing and editing experience for sonnet 3.7, CLAUDE.md gets loaded automatically.
|
|
50
|
+
|
|
46
51
|
- [16 Feb 2025] You can now attach to the working terminal that the AI uses. See the "attach-to-terminal" section below.
|
|
47
52
|
|
|
48
53
|
- [15 Jan 2025] Modes introduced: architect, code-writer, and all powerful wcgw mode.
|
|
@@ -53,11 +58,10 @@ Empowering chat applications to code, build and run on your local machine.
|
|
|
53
58
|
|
|
54
59
|
- [9 Dec 2024] [Vscode extension to paste context on Claude app](https://marketplace.visualstudio.com/items?itemName=AmanRusia.wcgw)
|
|
55
60
|
|
|
56
|
-
|
|
57
61
|
## 🚀 Highlights
|
|
58
62
|
|
|
59
63
|
- ⚡ **Create, Execute, Iterate**: Ask claude to keep running compiler checks till all errors are fixed, or ask it to keep checking for the status of a long running command till it's done.
|
|
60
|
-
- ⚡ **Large file edit**: Supports large file incremental edits to avoid token limit issues.
|
|
64
|
+
- ⚡ **Large file edit**: Supports large file incremental edits to avoid token limit issues. Smartly selects when to do small edits or large rewrite based on % of change needed.
|
|
61
65
|
- ⚡ **Syntax checking on edits**: Reports feedback to the LLM if its edits have any syntax errors, so that it can redo it.
|
|
62
66
|
- ⚡ **Interactive Command Handling**: Supports interactive commands using arrow keys, interrupt, and ansi escape sequences.
|
|
63
67
|
- ⚡ **File protections**:
|
|
@@ -96,6 +100,8 @@ Empowering chat applications to code, build and run on your local machine.
|
|
|
96
100
|
|
|
97
101
|
## Claude setup (using mcp)
|
|
98
102
|
|
|
103
|
+
### Mac and linux
|
|
104
|
+
|
|
99
105
|
First install `uv` using homebrew `brew install uv`
|
|
100
106
|
|
|
101
107
|
(**Important:** use homebrew to install uv. Otherwise make sure `uv` is present in a global location like /usr/bin/)
|
|
@@ -131,18 +137,33 @@ _If there's an error in setting up_
|
|
|
131
137
|
- Try using `uv` version `0.6.0` for which this tool was tested.
|
|
132
138
|
- Debug the mcp server using `npx @modelcontextprotocol/inspector@0.1.7 uv tool run --from wcgw@latest --python 3.12 wcgw_mcp`
|
|
133
139
|
|
|
134
|
-
###
|
|
140
|
+
### Windows on wsl
|
|
135
141
|
|
|
136
|
-
|
|
142
|
+
This mcp server works only on wsl on windows.
|
|
137
143
|
|
|
138
|
-
|
|
144
|
+
To set it up, [install uv](https://docs.astral.sh/uv/getting-started/installation/)
|
|
139
145
|
|
|
140
|
-
|
|
141
|
-
npx -y @smithery/cli install wcgw --client claude
|
|
142
|
-
```
|
|
146
|
+
Then add or update the claude config file `%APPDATA%\Claude\claude_desktop_config.json` with the following
|
|
143
147
|
|
|
144
|
-
|
|
145
|
-
|
|
148
|
+
```json
|
|
149
|
+
{
|
|
150
|
+
"mcpServers": {
|
|
151
|
+
"wcgw": {
|
|
152
|
+
"command": "wsl.exe",
|
|
153
|
+
"args": [
|
|
154
|
+
"uv",
|
|
155
|
+
"tool",
|
|
156
|
+
"run",
|
|
157
|
+
"--from",
|
|
158
|
+
"wcgw@latest",
|
|
159
|
+
"--python",
|
|
160
|
+
"3.12",
|
|
161
|
+
"wcgw_mcp"
|
|
162
|
+
]
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
```
|
|
146
167
|
|
|
147
168
|
### Usage
|
|
148
169
|
|
|
@@ -174,6 +195,7 @@ There are three built-in modes. You may ask Claude to run in one of the modes, l
|
|
|
174
195
|
Note: in code-writer mode either all commands are allowed or none are allowed for now. If you give a list of allowed commands, Claude is instructed to run only those commands, but no actual check happens. (WIP)
|
|
175
196
|
|
|
176
197
|
#### Attach to the working terminal to investigate
|
|
198
|
+
|
|
177
199
|
If you've `screen` command installed, wcgw runs on a screen instance automatically. If you've started wcgw mcp server, you can list the screen sessions:
|
|
178
200
|
|
|
179
201
|
`screen -ls`
|
|
@@ -184,7 +206,7 @@ You can then attach to the session using `screen -x 93358.wcgw.235521`
|
|
|
184
206
|
|
|
185
207
|
You may interrupt any running command safely.
|
|
186
208
|
|
|
187
|
-
You can interact with the terminal but beware that the AI might be running in parallel and it may conflict with what you're doing. It's recommended to keep your interactions to minimum.
|
|
209
|
+
You can interact with the terminal but beware that the AI might be running in parallel and it may conflict with what you're doing. It's recommended to keep your interactions to minimum.
|
|
188
210
|
|
|
189
211
|
You shouldn't exit the session using `exit `or Ctrl-d, instead you should use `ctrl+a+d` to safely detach without destroying the screen session.
|
|
190
212
|
|
|
@@ -204,12 +226,12 @@ Read here: https://github.com/rusiaaman/wcgw/blob/main/openai.md
|
|
|
204
226
|
|
|
205
227
|

|
|
206
228
|
|
|
207
|
-
|
|
208
229
|
## Using mcp server over docker
|
|
209
230
|
|
|
210
231
|
First build the docker image `docker build -t wcgw https://github.com/rusiaaman/wcgw.git`
|
|
211
232
|
|
|
212
233
|
Then you can update `/Users/username/Library/Application Support/Claude/claude_desktop_config.json` to have
|
|
234
|
+
|
|
213
235
|
```
|
|
214
236
|
{
|
|
215
237
|
"mcpServers": {
|
|
@@ -228,8 +250,6 @@ Then you can update `/Users/username/Library/Application Support/Claude/claude_d
|
|
|
228
250
|
}
|
|
229
251
|
```
|
|
230
252
|
|
|
231
|
-
|
|
232
|
-
|
|
233
253
|
## [Optional] Local shell access with openai API key or anthropic API key
|
|
234
254
|
|
|
235
255
|
### Openai
|
|
@@ -281,4 +301,3 @@ The server provides the following MCP tools:
|
|
|
281
301
|
- Parameters: `id` (string), `project_root_path` (string), `description` (string), `relevant_file_globs` (string[])
|
|
282
302
|
|
|
283
303
|
All tools support absolute paths and include built-in protections against common errors. See the [MCP specification](https://modelcontextprotocol.io/) for detailed protocol information.
|
|
284
|
-
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Empowering chat applications to code, build and run on your local machine.
|
|
4
4
|
|
|
5
|
-
- Claude -
|
|
6
|
-
- Chatgpt - Allows custom gpt to talk to your shell via a relay server. (linux
|
|
5
|
+
- Claude - MCP server with tightly integrated shell and code editing tools.
|
|
6
|
+
- Chatgpt - Allows custom gpt to talk to your shell via a relay server. (linux, mac, windows on wsl)
|
|
7
7
|
|
|
8
8
|
⚠️ Warning: do not allow BashCommand tool without reviewing the command, it may result in data loss.
|
|
9
9
|
|
|
@@ -11,10 +11,16 @@ Empowering chat applications to code, build and run on your local machine.
|
|
|
11
11
|
[](https://github.com/rusiaaman/wcgw/actions/workflows/python-types.yml)
|
|
12
12
|
[](https://github.com/rusiaaman/wcgw/actions/workflows/python-publish.yml)
|
|
13
13
|
[](https://codecov.io/gh/rusiaaman/wcgw)
|
|
14
|
-
[](https://www.reddit.com/r/wcgw_mcp/)
|
|
15
|
+
|
|
16
|
+
## Demo
|
|
17
|
+
|
|
18
|
+

|
|
15
19
|
|
|
16
20
|
## Updates
|
|
17
21
|
|
|
22
|
+
- [24 Mar 2025] Improved writing and editing experience for sonnet 3.7, CLAUDE.md gets loaded automatically.
|
|
23
|
+
|
|
18
24
|
- [16 Feb 2025] You can now attach to the working terminal that the AI uses. See the "attach-to-terminal" section below.
|
|
19
25
|
|
|
20
26
|
- [15 Jan 2025] Modes introduced: architect, code-writer, and all powerful wcgw mode.
|
|
@@ -25,11 +31,10 @@ Empowering chat applications to code, build and run on your local machine.
|
|
|
25
31
|
|
|
26
32
|
- [9 Dec 2024] [Vscode extension to paste context on Claude app](https://marketplace.visualstudio.com/items?itemName=AmanRusia.wcgw)
|
|
27
33
|
|
|
28
|
-
|
|
29
34
|
## 🚀 Highlights
|
|
30
35
|
|
|
31
36
|
- ⚡ **Create, Execute, Iterate**: Ask claude to keep running compiler checks till all errors are fixed, or ask it to keep checking for the status of a long running command till it's done.
|
|
32
|
-
- ⚡ **Large file edit**: Supports large file incremental edits to avoid token limit issues.
|
|
37
|
+
- ⚡ **Large file edit**: Supports large file incremental edits to avoid token limit issues. Smartly selects when to do small edits or large rewrite based on % of change needed.
|
|
33
38
|
- ⚡ **Syntax checking on edits**: Reports feedback to the LLM if its edits have any syntax errors, so that it can redo it.
|
|
34
39
|
- ⚡ **Interactive Command Handling**: Supports interactive commands using arrow keys, interrupt, and ansi escape sequences.
|
|
35
40
|
- ⚡ **File protections**:
|
|
@@ -68,6 +73,8 @@ Empowering chat applications to code, build and run on your local machine.
|
|
|
68
73
|
|
|
69
74
|
## Claude setup (using mcp)
|
|
70
75
|
|
|
76
|
+
### Mac and linux
|
|
77
|
+
|
|
71
78
|
First install `uv` using homebrew `brew install uv`
|
|
72
79
|
|
|
73
80
|
(**Important:** use homebrew to install uv. Otherwise make sure `uv` is present in a global location like /usr/bin/)
|
|
@@ -103,18 +110,33 @@ _If there's an error in setting up_
|
|
|
103
110
|
- Try using `uv` version `0.6.0` for which this tool was tested.
|
|
104
111
|
- Debug the mcp server using `npx @modelcontextprotocol/inspector@0.1.7 uv tool run --from wcgw@latest --python 3.12 wcgw_mcp`
|
|
105
112
|
|
|
106
|
-
###
|
|
113
|
+
### Windows on wsl
|
|
107
114
|
|
|
108
|
-
|
|
115
|
+
This mcp server works only on wsl on windows.
|
|
109
116
|
|
|
110
|
-
|
|
117
|
+
To set it up, [install uv](https://docs.astral.sh/uv/getting-started/installation/)
|
|
111
118
|
|
|
112
|
-
|
|
113
|
-
npx -y @smithery/cli install wcgw --client claude
|
|
114
|
-
```
|
|
119
|
+
Then add or update the claude config file `%APPDATA%\Claude\claude_desktop_config.json` with the following
|
|
115
120
|
|
|
116
|
-
|
|
117
|
-
|
|
121
|
+
```json
|
|
122
|
+
{
|
|
123
|
+
"mcpServers": {
|
|
124
|
+
"wcgw": {
|
|
125
|
+
"command": "wsl.exe",
|
|
126
|
+
"args": [
|
|
127
|
+
"uv",
|
|
128
|
+
"tool",
|
|
129
|
+
"run",
|
|
130
|
+
"--from",
|
|
131
|
+
"wcgw@latest",
|
|
132
|
+
"--python",
|
|
133
|
+
"3.12",
|
|
134
|
+
"wcgw_mcp"
|
|
135
|
+
]
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
```
|
|
118
140
|
|
|
119
141
|
### Usage
|
|
120
142
|
|
|
@@ -146,6 +168,7 @@ There are three built-in modes. You may ask Claude to run in one of the modes, l
|
|
|
146
168
|
Note: in code-writer mode either all commands are allowed or none are allowed for now. If you give a list of allowed commands, Claude is instructed to run only those commands, but no actual check happens. (WIP)
|
|
147
169
|
|
|
148
170
|
#### Attach to the working terminal to investigate
|
|
171
|
+
|
|
149
172
|
If you've `screen` command installed, wcgw runs on a screen instance automatically. If you've started wcgw mcp server, you can list the screen sessions:
|
|
150
173
|
|
|
151
174
|
`screen -ls`
|
|
@@ -156,7 +179,7 @@ You can then attach to the session using `screen -x 93358.wcgw.235521`
|
|
|
156
179
|
|
|
157
180
|
You may interrupt any running command safely.
|
|
158
181
|
|
|
159
|
-
You can interact with the terminal but beware that the AI might be running in parallel and it may conflict with what you're doing. It's recommended to keep your interactions to minimum.
|
|
182
|
+
You can interact with the terminal but beware that the AI might be running in parallel and it may conflict with what you're doing. It's recommended to keep your interactions to minimum.
|
|
160
183
|
|
|
161
184
|
You shouldn't exit the session using `exit `or Ctrl-d, instead you should use `ctrl+a+d` to safely detach without destroying the screen session.
|
|
162
185
|
|
|
@@ -176,12 +199,12 @@ Read here: https://github.com/rusiaaman/wcgw/blob/main/openai.md
|
|
|
176
199
|
|
|
177
200
|

|
|
178
201
|
|
|
179
|
-
|
|
180
202
|
## Using mcp server over docker
|
|
181
203
|
|
|
182
204
|
First build the docker image `docker build -t wcgw https://github.com/rusiaaman/wcgw.git`
|
|
183
205
|
|
|
184
206
|
Then you can update `/Users/username/Library/Application Support/Claude/claude_desktop_config.json` to have
|
|
207
|
+
|
|
185
208
|
```
|
|
186
209
|
{
|
|
187
210
|
"mcpServers": {
|
|
@@ -200,8 +223,6 @@ Then you can update `/Users/username/Library/Application Support/Claude/claude_d
|
|
|
200
223
|
}
|
|
201
224
|
```
|
|
202
225
|
|
|
203
|
-
|
|
204
|
-
|
|
205
226
|
## [Optional] Local shell access with openai API key or anthropic API key
|
|
206
227
|
|
|
207
228
|
### Openai
|
|
@@ -253,4 +274,3 @@ The server provides the following MCP tools:
|
|
|
253
274
|
- Parameters: `id` (string), `project_root_path` (string), `description` (string), `relevant_file_globs` (string[])
|
|
254
275
|
|
|
255
276
|
All tools support absolute paths and include built-in protections against common errors. See the [MCP specification](https://modelcontextprotocol.io/) for detailed protocol information.
|
|
256
|
-
|
|
@@ -10,16 +10,16 @@
|
|
|
10
10
|
}
|
|
11
11
|
],
|
|
12
12
|
"paths": {
|
|
13
|
-
"/v1/
|
|
13
|
+
"/v1/file_write_or_edit": {
|
|
14
14
|
"post": {
|
|
15
15
|
"x-openai-isConsequential": false,
|
|
16
|
-
"summary": "
|
|
17
|
-
"operationId": "
|
|
16
|
+
"summary": "File Write Or Edit",
|
|
17
|
+
"operationId": "file_write_or_edit_v1_file_write_or_edit_post",
|
|
18
18
|
"requestBody": {
|
|
19
19
|
"content": {
|
|
20
20
|
"application/json": {
|
|
21
21
|
"schema": {
|
|
22
|
-
"$ref": "#/components/schemas/
|
|
22
|
+
"$ref": "#/components/schemas/FileWriteOrEdithUUID"
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
25
|
},
|
|
@@ -32,47 +32,7 @@
|
|
|
32
32
|
"application/json": {
|
|
33
33
|
"schema": {
|
|
34
34
|
"type": "string",
|
|
35
|
-
"title": "Response
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
},
|
|
40
|
-
"422": {
|
|
41
|
-
"description": "Validation Error",
|
|
42
|
-
"content": {
|
|
43
|
-
"application/json": {
|
|
44
|
-
"schema": {
|
|
45
|
-
"$ref": "#/components/schemas/HTTPValidationError"
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
},
|
|
53
|
-
"/v1/full_file_edit": {
|
|
54
|
-
"post": {
|
|
55
|
-
"x-openai-isConsequential": false,
|
|
56
|
-
"summary": "File Edit Find Replace",
|
|
57
|
-
"operationId": "file_edit_find_replace_v1_full_file_edit_post",
|
|
58
|
-
"requestBody": {
|
|
59
|
-
"content": {
|
|
60
|
-
"application/json": {
|
|
61
|
-
"schema": {
|
|
62
|
-
"$ref": "#/components/schemas/FileEditWithUUID"
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
},
|
|
66
|
-
"required": true
|
|
67
|
-
},
|
|
68
|
-
"responses": {
|
|
69
|
-
"200": {
|
|
70
|
-
"description": "Successful Response",
|
|
71
|
-
"content": {
|
|
72
|
-
"application/json": {
|
|
73
|
-
"schema": {
|
|
74
|
-
"type": "string",
|
|
75
|
-
"title": "Response File Edit Find Replace V1 Full File Edit Post"
|
|
35
|
+
"title": "Response File Write Or Edit V1 File Write Or Edit Post"
|
|
76
36
|
}
|
|
77
37
|
}
|
|
78
38
|
}
|
|
@@ -288,10 +248,7 @@
|
|
|
288
248
|
},
|
|
289
249
|
"additionalProperties": false,
|
|
290
250
|
"type": "object",
|
|
291
|
-
"required": [
|
|
292
|
-
"allowed_globs",
|
|
293
|
-
"allowed_commands"
|
|
294
|
-
],
|
|
251
|
+
"required": ["allowed_globs", "allowed_commands"],
|
|
295
252
|
"title": "CodeWriterMode"
|
|
296
253
|
},
|
|
297
254
|
"Command": {
|
|
@@ -303,9 +260,7 @@
|
|
|
303
260
|
},
|
|
304
261
|
"additionalProperties": false,
|
|
305
262
|
"type": "object",
|
|
306
|
-
"required": [
|
|
307
|
-
"command"
|
|
308
|
-
],
|
|
263
|
+
"required": ["command"],
|
|
309
264
|
"title": "Command"
|
|
310
265
|
},
|
|
311
266
|
"CommandWithUUID": {
|
|
@@ -328,7 +283,7 @@
|
|
|
328
283
|
"$ref": "#/components/schemas/SendAscii"
|
|
329
284
|
}
|
|
330
285
|
],
|
|
331
|
-
"title": "
|
|
286
|
+
"title": "Action Json"
|
|
332
287
|
},
|
|
333
288
|
"wait_for_seconds": {
|
|
334
289
|
"anyOf": [
|
|
@@ -349,10 +304,7 @@
|
|
|
349
304
|
},
|
|
350
305
|
"additionalProperties": false,
|
|
351
306
|
"type": "object",
|
|
352
|
-
"required": [
|
|
353
|
-
"action_json",
|
|
354
|
-
"user_id"
|
|
355
|
-
],
|
|
307
|
+
"required": ["action_json", "user_id"],
|
|
356
308
|
"title": "CommandWithUUID"
|
|
357
309
|
},
|
|
358
310
|
"ContextSaveWithUUID": {
|
|
@@ -393,15 +345,19 @@
|
|
|
393
345
|
],
|
|
394
346
|
"title": "ContextSaveWithUUID"
|
|
395
347
|
},
|
|
396
|
-
"
|
|
348
|
+
"FileWriteOrEdithUUID": {
|
|
397
349
|
"properties": {
|
|
398
350
|
"file_path": {
|
|
399
351
|
"type": "string",
|
|
400
352
|
"title": "File Path"
|
|
401
353
|
},
|
|
402
|
-
"
|
|
354
|
+
"percentage_to_change": {
|
|
355
|
+
"type": "integer",
|
|
356
|
+
"title": "Percentage To Change"
|
|
357
|
+
},
|
|
358
|
+
"file_content_or_search_replace_blocks": {
|
|
403
359
|
"type": "string",
|
|
404
|
-
"title": "File
|
|
360
|
+
"title": "File Content Or Search Replace Blocks"
|
|
405
361
|
},
|
|
406
362
|
"user_id": {
|
|
407
363
|
"type": "string",
|
|
@@ -413,10 +369,11 @@
|
|
|
413
369
|
"type": "object",
|
|
414
370
|
"required": [
|
|
415
371
|
"file_path",
|
|
416
|
-
"
|
|
372
|
+
"percentage_to_change",
|
|
373
|
+
"file_content_or_search_replace_blocks",
|
|
417
374
|
"user_id"
|
|
418
375
|
],
|
|
419
|
-
"title": "
|
|
376
|
+
"title": "FileWriteOrEdithUUID"
|
|
420
377
|
},
|
|
421
378
|
"HTTPValidationError": {
|
|
422
379
|
"properties": {
|
|
@@ -460,11 +417,7 @@
|
|
|
460
417
|
},
|
|
461
418
|
"mode_name": {
|
|
462
419
|
"type": "string",
|
|
463
|
-
"enum": [
|
|
464
|
-
"wcgw",
|
|
465
|
-
"architect",
|
|
466
|
-
"code_writer"
|
|
467
|
-
],
|
|
420
|
+
"enum": ["wcgw", "architect", "code_writer"],
|
|
468
421
|
"title": "Mode Name"
|
|
469
422
|
},
|
|
470
423
|
"code_writer_config": {
|
|
@@ -504,6 +457,17 @@
|
|
|
504
457
|
"type": "array",
|
|
505
458
|
"title": "File Paths"
|
|
506
459
|
},
|
|
460
|
+
"show_line_numbers_reason": {
|
|
461
|
+
"anyOf": [
|
|
462
|
+
{
|
|
463
|
+
"type": "string"
|
|
464
|
+
},
|
|
465
|
+
{
|
|
466
|
+
"type": "null"
|
|
467
|
+
}
|
|
468
|
+
],
|
|
469
|
+
"title": "Show Line Numbers Reason"
|
|
470
|
+
},
|
|
507
471
|
"user_id": {
|
|
508
472
|
"type": "string",
|
|
509
473
|
"format": "uuid",
|
|
@@ -512,10 +476,7 @@
|
|
|
512
476
|
},
|
|
513
477
|
"additionalProperties": false,
|
|
514
478
|
"type": "object",
|
|
515
|
-
"required": [
|
|
516
|
-
"file_paths",
|
|
517
|
-
"user_id"
|
|
518
|
-
],
|
|
479
|
+
"required": ["file_paths", "user_id"],
|
|
519
480
|
"title": "ReadFileWithUUID"
|
|
520
481
|
},
|
|
521
482
|
"SendAscii": {
|
|
@@ -530,9 +491,7 @@
|
|
|
530
491
|
},
|
|
531
492
|
"additionalProperties": false,
|
|
532
493
|
"type": "object",
|
|
533
|
-
"required": [
|
|
534
|
-
"send_ascii"
|
|
535
|
-
],
|
|
494
|
+
"required": ["send_ascii"],
|
|
536
495
|
"title": "SendAscii"
|
|
537
496
|
},
|
|
538
497
|
"SendSpecials": {
|
|
@@ -547,8 +506,7 @@
|
|
|
547
506
|
"Key-left",
|
|
548
507
|
"Key-right",
|
|
549
508
|
"Ctrl-c",
|
|
550
|
-
"Ctrl-d"
|
|
551
|
-
"Ctrl-z"
|
|
509
|
+
"Ctrl-d"
|
|
552
510
|
]
|
|
553
511
|
},
|
|
554
512
|
"type": "array",
|
|
@@ -557,9 +515,7 @@
|
|
|
557
515
|
},
|
|
558
516
|
"additionalProperties": false,
|
|
559
517
|
"type": "object",
|
|
560
|
-
"required": [
|
|
561
|
-
"send_specials"
|
|
562
|
-
],
|
|
518
|
+
"required": ["send_specials"],
|
|
563
519
|
"title": "SendSpecials"
|
|
564
520
|
},
|
|
565
521
|
"SendText": {
|
|
@@ -571,9 +527,7 @@
|
|
|
571
527
|
},
|
|
572
528
|
"additionalProperties": false,
|
|
573
529
|
"type": "object",
|
|
574
|
-
"required": [
|
|
575
|
-
"send_text"
|
|
576
|
-
],
|
|
530
|
+
"required": ["send_text"],
|
|
577
531
|
"title": "SendText"
|
|
578
532
|
},
|
|
579
533
|
"StatusCheck": {
|
|
@@ -586,9 +540,7 @@
|
|
|
586
540
|
},
|
|
587
541
|
"additionalProperties": false,
|
|
588
542
|
"type": "object",
|
|
589
|
-
"required": [
|
|
590
|
-
"status_check"
|
|
591
|
-
],
|
|
543
|
+
"required": ["status_check"],
|
|
592
544
|
"title": "StatusCheck"
|
|
593
545
|
},
|
|
594
546
|
"ValidationError": {
|
|
@@ -617,38 +569,9 @@
|
|
|
617
569
|
}
|
|
618
570
|
},
|
|
619
571
|
"type": "object",
|
|
620
|
-
"required": [
|
|
621
|
-
"loc",
|
|
622
|
-
"msg",
|
|
623
|
-
"type"
|
|
624
|
-
],
|
|
572
|
+
"required": ["loc", "msg", "type"],
|
|
625
573
|
"title": "ValidationError"
|
|
626
|
-
},
|
|
627
|
-
"WriteIfEmptyWithUUID": {
|
|
628
|
-
"properties": {
|
|
629
|
-
"file_path": {
|
|
630
|
-
"type": "string",
|
|
631
|
-
"title": "File Path"
|
|
632
|
-
},
|
|
633
|
-
"file_content": {
|
|
634
|
-
"type": "string",
|
|
635
|
-
"title": "File Content"
|
|
636
|
-
},
|
|
637
|
-
"user_id": {
|
|
638
|
-
"type": "string",
|
|
639
|
-
"format": "uuid",
|
|
640
|
-
"title": "User Id"
|
|
641
|
-
}
|
|
642
|
-
},
|
|
643
|
-
"additionalProperties": false,
|
|
644
|
-
"type": "object",
|
|
645
|
-
"required": [
|
|
646
|
-
"file_path",
|
|
647
|
-
"file_content",
|
|
648
|
-
"user_id"
|
|
649
|
-
],
|
|
650
|
-
"title": "WriteIfEmptyWithUUID"
|
|
651
574
|
}
|
|
652
575
|
}
|
|
653
576
|
}
|
|
654
|
-
}
|
|
577
|
+
}
|
|
@@ -33,23 +33,24 @@ Instructions for `BashCommand`:
|
|
|
33
33
|
|
|
34
34
|
Instructions for `Read Files`
|
|
35
35
|
- Read full file content of one or more files.
|
|
36
|
-
- Provide absolute
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
-
|
|
40
|
-
|
|
41
|
-
|
|
36
|
+
- Provide absolute paths only (~ allowed)
|
|
37
|
+
- Only if the task requires line numbers understanding:
|
|
38
|
+
- You may populate "show_line_numbers_reason" with your reason, by default null/empty means no line numbers are shown.
|
|
39
|
+
- You may extract a range of lines. E.g., `/path/to/file:1-10` for lines 1-10. You can drop start or end like `/path/to/file:1-` or `/path/to/file:-10`
|
|
40
|
+
|
|
41
|
+
Instructions for `FileWriteOrEdit`
|
|
42
|
+
- Writes or edits a file based on the percentage of changes.
|
|
43
|
+
- Use absolute path only (~ allowed).
|
|
44
|
+
- First write down percentage of lines that need to be replaced in the file (between 0-100) in percentage_to_change
|
|
45
|
+
- percentage_to_change should be low if mostly new code is to be added. It should be high if a lot of things are to be replaced.
|
|
46
|
+
- If percentage_to_change > 50, provide full file content in file_content_or_search_replace_blocks
|
|
47
|
+
- If percentage_to_change <= 50, file_content_or_search_replace_blocks should be search/replace blocks.
|
|
42
48
|
|
|
43
49
|
Instructions for `ContextSave`
|
|
44
50
|
- Saves provided description and file contents of all the relevant file paths or globs in a single text file.
|
|
45
51
|
- Provide random unqiue id or whatever user provided.
|
|
46
52
|
- Leave project path as empty string if no project path
|
|
47
53
|
|
|
48
|
-
Instructions for `FileEdit`:
|
|
49
|
-
- Use absolute file path only.
|
|
50
|
-
- Use SEARCH/REPLACE blocks to edit the file.
|
|
51
|
-
Only edit the files using the following SEARCH/REPLACE blocks.
|
|
52
|
-
|
|
53
54
|
```
|
|
54
55
|
<<<<<<< SEARCH
|
|
55
56
|
def hello():
|