Skip to content
Open

Dev #281

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ jobs:
# - os: ubuntu-20.04
# target: armv7-unknown-linux-gnueabihf
# code-target: linux-armhf
- os: macos-13
- os: macos-15
target: x86_64-apple-darwin
code-target: darwin-x64
- os: macos-14
- os: macos-15
target: aarch64-apple-darwin
code-target: darwin-arm64

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ jobs:
# - os: ubuntu-20.04
# target: armv7-unknown-linux-gnueabihf
# code-target: linux-armhf
- os: macos-13
- os: macos-15
target: x86_64-apple-darwin
code-target: darwin-x64
- os: macos-14
- os: macos-15
target: aarch64-apple-darwin
code-target: darwin-arm64

Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,5 @@ package.json
images/.DS_Store
.DS_Store
assets/refact-lsp*
.refact/*
.idea/*
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@

## Refact.ai - Your Customizable Open-Source AI Software Engineering Agent

Refact.ai is a free, **open-source** AI Agent that handles engineering tasks end-to-end. It deeply understands your codebases and integrates with your tools, databases, and browsers to automate complex, multi-step tasks.
Refact.ai is the #1 free **open-source** AI Agent on the SWE-bench verified leaderboard. It autonomously handles software engineering tasks end to end. It deeply understands large and complex codebases and integrates with developers’ tools (including MCP), databases, and browsers to automate complex, multi-step tasks.

- Integrate AI Agent with the tools you already use, allowing it to complete tasks for you end-to-end.
- Deploy Refact.ai on-premise and maintain **100% control over your codebase**.
- Access State-of-the-Art Models (Claude 3.7 Sonnet, GPT-4o, o3-mini, etc.)
- Integrate the AI Agent with the tools you already use, allowing it to complete tasks end to end while transparently showing every step it takes.
- Deploy Refact.ai on-premise to maintain **100% control over your codebase**.
- Access state-of-the-art models like Claude 4 Sonnet, GPT-4.1, 4o, Gemini 2.5 Pro, and more.
- Bring your own key (BYOK) - Use your own API keys for external LLMs.
- Stop switching between your IDE and chat—Refact.ai has an integrated chat right in your IDE.
- Get free, unlimited, context-aware auto-completion.
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "codify",
"displayName": "Refact – Open-Source AI Agent, Code Generator & Chat for JavaScript, Python, TypeScript, Java, PHP, Go, and more.",
"description": "Refact.ai is a free, open-source AI Agent that adapts to your workflow. It tracks your cursor to provide instant assistance, connects with tools, databases and browsers, works with debuggers, and runs shell commands. As your AI copilot, it handles code generation, testing, review, and refactoring.",
"description": "Refact.ai is the #1 free open-source AI Agent on the SWE-bench verified leaderboard. It autonomously handles software engineering tasks end to end. It understands large and complex codebases, adapts to your workflow, and connects with the tools developers actually use (including MCP). It tracks your cursor to provide instant help and transparently shows every step the Agent takes. As your AI copilot, it handles code generation, testing, review, refactoring, and more.",
"publisher": "smallcloud",
"icon": "logo-small.png",
"galleryBanner": {
Expand All @@ -18,7 +18,7 @@
"url": "https://github.com/smallcloudai/refact-vscode/issues",
"email": "support@smallcloud.tech"
},
"version": "6.5.8",
"version": "7.0.0",
"dependencies": {
"@types/marked": "^4.0.8",
"@types/vscode": "^1.69.0",
Expand All @@ -27,7 +27,7 @@
"fetch-h2": "^3.0.2",
"json5": "^2.2.3",
"marked": "^4.0.8",
"refact-chat-js": "^2.0.10-alpha.3",
"refact-chat-js": "^7.0.0",
"uuid": "^9.0.1",
"vscode-languageclient": "^7.0.0"
},
Expand Down
42 changes: 32 additions & 10 deletions src/sidebar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -685,11 +685,18 @@
// }

async handleToolEdit(toolCall: TextDocToolCall, toolEdit: ToolEditResult) {
const args = toolCall.function.arguments;
const filePath = 'path' in args ? args.path : undefined;
if (!filePath) {
console.error('Tool call arguments missing path property');
return;
}

if(!toolEdit.file_before && toolEdit.file_after) {
return this.createNewFileWithContent(toolCall.function.arguments.path, toolEdit.file_after);
return this.createNewFileWithContent(filePath, toolEdit.file_after);
}

return this.addDiffToFile(toolCall.function.arguments.path, toolEdit.file_after);
return this.addDiffToFile(filePath, toolEdit.file_after);
}


Expand Down Expand Up @@ -1034,15 +1041,30 @@

if(thread) {
const chat: InitialState["chat"] = {
streaming: false,
error: null,
prevent_send: true,
waiting_for_response: false,
tool_use: thread.tool_use ? thread.tool_use : "explore",
cache: {},
current_thread_id: thread.id,
open_thread_ids: [thread.id],
threads: {

Check failure on line 1046 in src/sidebar.ts

View workflow job for this annotation

GitHub Actions / dist (x86_64-unknown-linux-gnu)

Type '{ [x: string]: { thread: ChatThread; streaming: false; waiting_for_response: false; prevent_send: true; error: null; queued_items: never[]; send_immediately: boolean; attached_images: never[]; confirmation: { ...; }; snapshot_received: false; }; }' is not assignable to type 'Record<string, ChatThreadRuntime | undefined>'.

Check failure on line 1046 in src/sidebar.ts

View workflow job for this annotation

GitHub Actions / dist (aarch64-unknown-linux-gnu)

Type '{ [x: string]: { thread: ChatThread; streaming: false; waiting_for_response: false; prevent_send: true; error: null; queued_items: never[]; send_immediately: boolean; attached_images: never[]; confirmation: { ...; }; snapshot_received: false; }; }' is not assignable to type 'Record<string, ChatThreadRuntime | undefined>'.

Check failure on line 1046 in src/sidebar.ts

View workflow job for this annotation

GitHub Actions / dist (aarch64-apple-darwin)

Type '{ [x: string]: { thread: ChatThread; streaming: false; waiting_for_response: false; prevent_send: true; error: null; queued_items: never[]; send_immediately: boolean; attached_images: never[]; confirmation: { ...; }; snapshot_received: false; }; }' is not assignable to type 'Record<string, ChatThreadRuntime | undefined>'.
[thread.id]: {
thread,
streaming: false,
waiting_for_response: false,
prevent_send: true,
error: null,
queued_items: [],
send_immediately: thread.messages.length > 0,
attached_images: [],
confirmation: {
pause: false,
pause_reasons: [],
status: { wasInteracted: false, confirmationStatus: false },
},
snapshot_received: false,
},
},
system_prompt: {},
send_immediately: thread.messages.length > 0,
thread,
tool_use: thread.tool_use ? thread.tool_use : "explore",
sse_refresh_requested: null,
stream_version: 0,
};
state.chat = chat;
state.pages = [{name: "login page"}, {name: "history"}, {name: "chat"}];
Expand Down
Loading