Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
4683 commits
Select commit Hold shift + click to select a range
70c61df
mcp correct shutdown
olegklimov Jan 23, 2025
415fd2f
now mcp_fetch() works
olegklimov Jan 23, 2025
a3e6c69
CI should work now
olegklimov Jan 24, 2025
28ea522
supports env in MCP
olegklimov Jan 24, 2025
5c9161e
update settings schema for MCP
olegklimov Jan 29, 2025
f1d3898
make MCP experimental
olegklimov Jan 29, 2025
2e497f8
remove 1 dep
olegklimov Jan 29, 2025
0353c65
chore: better wording
alashchev17 Feb 5, 2025
89098eb
fix: hotfix for getThreadMode
alashchev17 Feb 5, 2025
5410c5f
vllm serve (#581)
mitya52 Feb 5, 2025
ef64325
fixes issue when chat was iterrupted in the middle of a tool call: to…
v4ler11 Dec 27, 2024
64215b7
fixes
olegklimov Feb 6, 2025
f3e3516
fix: checkpoints work in nested repos
humbertoyusta Feb 5, 2025
7ea699e
feat: support for nested shadow repos is working, refactor nested rep…
humbertoyusta Feb 5, 2025
50ee91a
refactor: remove unused untracked flag and move enum to module level …
humbertoyusta Feb 6, 2025
88f013e
feat: MCP args/envs tables & proper parsing of field type
alashchev17 Feb 5, 2025
7dba39d
feat: validating MCP args/envs & sending them to the LSP on form submit
alashchev17 Feb 6, 2025
be79c00
fix(mcp envs): store original order of object props while renaming ke…
alashchev17 Feb 6, 2025
1df2d2b
chore: remove unnecessary comments
alashchev17 Feb 6, 2025
d5f2da1
fix: avoid duplicative code & validate for specific RegExp on form ch…
alashchev17 Feb 6, 2025
cf1c928
fix: avoid type cast and use type guards instead
alashchev17 Feb 6, 2025
ab8780c
fix(types/regexp): fix type check for CI & regexp
alashchev17 Feb 6, 2025
15a6f7d
chore: adjusted typeguard to avoid type casting
alashchev17 Feb 6, 2025
47dd762
fix: showing 'No content' if file content is undefined
alashchev17 Feb 6, 2025
daee88b
fix(trim indent): fixed tests
alashchev17 Feb 6, 2025
1b63fe1
chore: return undefined instead of void 0
alashchev17 Feb 6, 2025
7209e67
fix: disable revert checkpoints button if waiting, streaming or not o…
alashchev17 Feb 6, 2025
ec0c7a7
fix: blacklisted dirs excluded from all repos + refactor open shadow …
humbertoyusta Feb 6, 2025
44f0dcf
fix: do not create abs paths if they are not going to be used, speed …
humbertoyusta Feb 6, 2025
97f6fc2
refactor: rename method
humbertoyusta Feb 6, 2025
3e8b694
vllm serve (#581)
mitya52 Feb 5, 2025
968884b
oleg chore database and mem database
JegernOUTT Jan 15, 2025
0454289
iter1: vecdb without lance
JegernOUTT Jan 15, 2025
a9c9f47
iter2: vecdb without lance
JegernOUTT Jan 15, 2025
6fff26d
iter3: vecdb without lance debug
JegernOUTT Jan 16, 2025
2a9c6f8
iter3: vecdb without lance debug2
JegernOUTT Jan 16, 2025
1dd3275
rm mem-query
JegernOUTT Jan 17, 2025
6544ec9
add vec status to the pubsub sse pipeline
JegernOUTT Jan 17, 2025
91c5c16
Remove trailing comma in SQL query to fix syntax error
JegernOUTT Jan 21, 2025
cfc8a94
init: move compression logic into handler
mitya52 Dec 5, 2024
a8dfeab
trajectory save in memdb
mitya52 Dec 5, 2024
e61fdae
save traj only
mitya52 Dec 6, 2024
4e723d9
Add trajectory identifier "local-compressed-traj" in chat handler and…
JegernOUTT Jan 23, 2025
6238207
Remove unused dependencies from Cargo.toml
JegernOUTT Jan 23, 2025
3601263
Update dependencies and refactor zerocopy usage
JegernOUTT Jan 23, 2025
e8ae19a
Update dependencies and refactor zerocopy usage
JegernOUTT Jan 23, 2025
96d82eb
Remove redundant protobuf installation steps from workflows and Docke…
JegernOUTT Jan 23, 2025
993ccaf
Add vdb_emb_aux module for managing embeddings tables
JegernOUTT Jan 28, 2025
b1286a9
Implement per-workspace embedding tables with auto-cleanup
JegernOUTT Jan 28, 2025
4c151d7
Standardize column data types in SQLite virtual table creation
JegernOUTT Jan 28, 2025
01a837f
Add new parameters to compress_trajectory function calls
JegernOUTT Feb 6, 2025
45605c1
Enable `serde` feature for `chrono` dependency in Cargo.toml
JegernOUTT Feb 6, 2025
50e4e34
- Add memdb sleeping point notification during shutdown
JegernOUTT Feb 6, 2025
5866baa
force http2 support in axum
reymondzzzz Feb 7, 2025
43d1fc4
fixes issue when chat was iterrupted in the middle of a tool call: to…
v4ler11 Dec 27, 2024
8ec6311
fixes
olegklimov Feb 6, 2025
11a840b
fix: checkpoints work in nested repos
humbertoyusta Feb 5, 2025
67ab929
feat: support for nested shadow repos is working, refactor nested rep…
humbertoyusta Feb 5, 2025
4227258
refactor: remove unused untracked flag and move enum to module level …
humbertoyusta Feb 6, 2025
ff6c556
Add tool preservation in trajectory compression
JegernOUTT Feb 7, 2025
0498fc3
Merge branch 'main' into dev
olegklimov Feb 7, 2025
26b73c4
wip: getting icons from the binary
alashchev17 Feb 6, 2025
e18be16
feat: using icons from lsp and using terminal icon for all cmdline/se…
alashchev17 Feb 6, 2025
4f26900
fix(cloud login): set address url when logging in through cloud (#329)
MarcMcIntosh Feb 7, 2025
03c39ac
feat(telemetry): sending telemetry for agent rollback actions
alashchev17 Feb 7, 2025
400536a
2.0.5-alpha.3
alashchev17 Feb 7, 2025
fad41a4
fix: ask model to write 🧩EDITOR in a new line
humbertoyusta Jan 27, 2025
a3c0c8e
feat(patches and diffs): track patch and diff result to send to the i…
MarcMcIntosh Feb 10, 2025
35e515d
fix(callout retry loop): don't retry automatically when dismising the…
MarcMcIntosh Feb 10, 2025
45e76c1
ui: hide uncommitted changes warning when the info or error callout i…
MarcMcIntosh Feb 10, 2025
b8ccf58
change approach for rollback to preview -> apply instead of apply -> …
humbertoyusta Feb 10, 2025
73b2b69
feat: preview first, then apply & error handling
alashchev17 Feb 10, 2025
8f0579f
chore: fixed types in fixtures & stories
alashchev17 Feb 10, 2025
a1fbc61
2.0.5-alpha.4
alashchev17 Feb 10, 2025
830071e
fix(callout retry loop): don't retry automatically when dismising the…
MarcMcIntosh Feb 11, 2025
314486f
Merge branch 'main' into alpha
MarcMcIntosh Feb 11, 2025
6e08a38
2.0.5
MarcMcIntosh Feb 11, 2025
a5971d1
Knowledge db (#196)
MarcMcIntosh Feb 11, 2025
59642e6
2.0.5-alpha.5
MarcMcIntosh Feb 11, 2025
1b245bc
Merge branch 'main' into alpha
MarcMcIntosh Feb 11, 2025
dc935db
2.0.6-alpha.0
MarcMcIntosh Feb 11, 2025
e2bcc4d
fix(package-lock): fix merge conflicts.
MarcMcIntosh Feb 11, 2025
772d1a8
fix(package-lock): merge conflicts.
MarcMcIntosh Feb 11, 2025
22b2f9b
fix(vscode): `Cannot find module 'redux-persist/es/persistReducer' or…
MarcMcIntosh Feb 11, 2025
bfbd031
2.0.6-alpha.1
MarcMcIntosh Feb 11, 2025
b7349cc
fix: support for new textdoc tools from LSP
alashchev17 Feb 10, 2025
8d38348
fix: include text_edit tool to list of all patch-like tools
alashchev17 Feb 11, 2025
9804fe5
chore: removed duplicate hot keys option in main dropdown
alashchev17 Feb 11, 2025
c9bdb03
fix: make reasoner switch available for FREE tier users
alashchev17 Feb 11, 2025
147f86c
Merge branch 'main' into alpha
alashchev17 Feb 11, 2025
168bda3
chore: reasoning listed if user is on FREE tier
alashchev17 Feb 11, 2025
ca4a0f2
Merge branch 'main' into alpha
alashchev17 Feb 11, 2025
21552a6
fix: unnecesary lock maintained for long time
humbertoyusta Feb 10, 2025
14ded9b
add validation for parameters of integration
reymondzzzz Feb 6, 2025
d727314
2.0.6
alashchev17 Feb 12, 2025
ecb19ff
chore: bump version to 2.0.7-alpha.1
alashchev17 Feb 12, 2025
dff991c
fix: filtered out o3-mini from models list
alashchev17 Feb 12, 2025
c768d13
2.0.7
alashchev17 Feb 12, 2025
6862a0c
Merge branch 'main' into alpha
alashchev17 Feb 12, 2025
d79238b
hotfix: rollback disabled for thinking
humbertoyusta Feb 12, 2025
e5b7d76
0.10.12
reymondzzzz Feb 12, 2025
dfa3af9
feat: support http get like http post for internal requests
humbertoyusta Jan 7, 2025
337e7df
check if confirmation needed works inside container
humbertoyusta Jan 7, 2025
ecbb89c
ask list of tools from remote
humbertoyusta Jan 7, 2025
83bd71b
fix: proper filter out tools
humbertoyusta Jan 7, 2025
be26f6e
fix: proper path escapes and linux-like container path handling even …
humbertoyusta Jan 7, 2025
01684c7
fix: use shell quote instead of \", add secrets yaml and not just var…
humbertoyusta Jan 10, 2025
6716453
refactor: methtod to copy to container with shell escape and fix with…
humbertoyusta Jan 10, 2025
ccc1687
init implementation of blocklist mechanism
mitya52 Jan 20, 2025
1dc1281
additional_indexing_dirs and fixes
mitya52 Jan 21, 2025
2ba54df
_ls_files_under_version_control_recursive for additional indexing dir…
mitya52 Jan 22, 2025
6187f93
WorkspaceIndexingSettings -> GlobalIndexingSettings + return on shut …
mitya52 Jan 23, 2025
fcbb7a5
rename
mitya52 Jan 23, 2025
633fede
default indexing yaml
mitya52 Jan 23, 2025
53f1151
move to glob from directory name matching
mitya52 Jan 23, 2025
70e0982
rename, move things around, rewrite comments
olegklimov Jan 30, 2025
ae37642
more renames
olegklimov Jan 30, 2025
ec37fbb
more renames, "how it works" in comments
olegklimov Jan 30, 2025
c307ddd
almost works, now pattern matching is wrong
olegklimov Jan 30, 2025
ec360cd
additional_indexing_dirs works
olegklimov Jan 31, 2025
e5e1396
make DEFAULT_BLOCKLIST_DIRS a base to add to
olegklimov Jan 31, 2025
93b52cb
refactor: indexing for path taking ref not pathbuf
humbertoyusta Feb 10, 2025
fcdea1c
make ignore rules appropiate based on blocklist settings
humbertoyusta Feb 10, 2025
aafb54b
change approach for rollback to preview -> apply instead of apply -> …
humbertoyusta Feb 10, 2025
2290304
fix: unnecesary lock maintained for long time
humbertoyusta Feb 10, 2025
a5ec2df
TODO in blocklist
olegklimov Feb 13, 2025
65ea9c7
feat: updating integration availability values on switch click from g…
alashchev17 Feb 12, 2025
08acc15
feat: error handling & better styling & better code structure
alashchev17 Feb 12, 2025
4ed6c18
fix: handling form fields change in better way
alashchev17 Feb 13, 2025
e63d276
Refactor patch tool to apply_tickets and update related modules
JegernOUTT Jan 29, 2025
a3754ab
Refactor apply_tickets tool to handle single ticket at a time
JegernOUTT Jan 30, 2025
e00d5d3
Rename tool from `apply_ticket` to `apply_edit` for better clarity
JegernOUTT Jan 31, 2025
3b02244
Remove redundant word "any" from project change proposal step in YAML…
JegernOUTT Jan 31, 2025
c983c4e
Add handling for PatchAction::DeleteFile in tool_apply_edit.rs
JegernOUTT Jan 31, 2025
d45c73a
Replace legacy `patch()` with `apply_edit()` and `REPLACE_FILE` with …
JegernOUTT Feb 4, 2025
61cad63
Replace apply_edit tool with text_edit for file manipulation
JegernOUTT Feb 4, 2025
31916d1
Add `file_replace` command and improve text edit tool feedback
JegernOUTT Feb 4, 2025
38822a0
1. Add `replace_multiple` parameter to text_edit tool to allow replac…
JegernOUTT Feb 4, 2025
ca2daef
Normalize line endings during string replacement operations
JegernOUTT Feb 4, 2025
c8be6cb
Add unit tests for text_edit tool and update usage guidelines
JegernOUTT Feb 4, 2025
2ac1a8a
Update terms for ticket descriptions and coding actions
JegernOUTT Feb 8, 2025
3c91acc
Enhance file_manager command description with guidance on str_replace…
JegernOUTT Feb 8, 2025
04a89cf
Refactor and enhance error handling for tool call processing
JegernOUTT Feb 10, 2025
0701ae7
Add AST indexing synchronization to text edit operations
JegernOUTT Feb 10, 2025
8b06a1d
Refactor text editing tools and update tool descriptions
JegernOUTT Feb 10, 2025
6d44fe1
Add ToolUpdateTextDocRegex for regex-based text replacements
JegernOUTT Feb 10, 2025
192b804
Remove outdated guidelines for tool calls and adjust temperature cons…
JegernOUTT Feb 11, 2025
51fcfa8
Remove tool_apply_edit and related components
JegernOUTT Feb 11, 2025
bd4788d
This commit was made almost by agent
JegernOUTT Feb 11, 2025
1f8fa59
Remove deprecated diff and linter modules
JegernOUTT Feb 12, 2025
752af4a
Remove test files for patch functionality
JegernOUTT Feb 12, 2025
4ee5547
Normalize path handling and update result semantics
JegernOUTT Feb 12, 2025
bd3526d
Remove 📍-notation reference and clean up example file
JegernOUTT Feb 12, 2025
e79a823
Refactor file editing tools and simplify diff chunk generation
JegernOUTT Feb 12, 2025
d598a99
Update tool descriptions and parameter names for clarity
JegernOUTT Feb 12, 2025
927e24d
Add file edit dry-run feature and refactor tools with dry-run support
JegernOUTT Feb 14, 2025
7de32e7
single-line completion fix (#583)
JegernOUTT Feb 14, 2025
f7a810a
more readable condition
MDario123 Jan 29, 2025
68338a8
pass slice instead of reference to Vec
MDario123 Jan 29, 2025
f35baf3
collapse else { if cond {} } to else if cond {}
MDario123 Jan 29, 2025
17df2be
no need to have 2 copies, we can just move
MDario123 Jan 29, 2025
007bc2c
pass slice instead of reference to Vec
MDario123 Jan 29, 2025
d208161
reorder to avoid cloning a string
MDario123 Jan 29, 2025
baa1e32
reorder to avoid unnecesary clone
MDario123 Jan 29, 2025
708eca5
avoid cloning all messages again
MDario123 Jan 29, 2025
31110de
fix: end_str previously was being empty when it shouldn't
MDario123 Jan 29, 2025
65ac8ac
fix: declare line_str before
MDario123 Jan 30, 2025
e645d56
delete confusing comment
MDario123 Jan 30, 2025
971e6da
readability over performance
MDario123 Feb 6, 2025
ce66ef1
Implement follow-up message generation and topic change detection
JegernOUTT Feb 14, 2025
e0939e1
Limit processed chat messages to the last 10 and double token limit i…
JegernOUTT Feb 14, 2025
dfd23d9
Fix message iteration order in history generation function
JegernOUTT Feb 14, 2025
58c4781
MCP: setup values should arrive now
olegklimov Feb 12, 2025
1239150
MCP session coroutines and stuff
olegklimov Feb 13, 2025
f7fd9cb
MCP can shutdown processes
olegklimov Feb 14, 2025
50c8314
fix: if threadMode is AGENT or THINKING_AGENT, returning generic AGEN…
alashchev17 Feb 14, 2025
08767e8
chore: remove console statement
alashchev17 Feb 14, 2025
35cc9c8
git init link impl
JegernOUTT Jan 7, 2025
9d81844
Remove unused imports and comment out unused Git initialization logic
JegernOUTT Feb 14, 2025
a759432
fix: merge to pathbuf normalize and canonical path
humbertoyusta Feb 13, 2025
840f6a3
test: windows normalization logic
humbertoyusta Feb 13, 2025
f2cec73
fix: only import windows necessary types in windows
humbertoyusta Feb 13, 2025
54bb453
fix: absolute paths not touching filesystem works on linux
humbertoyusta Feb 13, 2025
0aba350
fix: replace to pathbuf normalize for canonical path
humbertoyusta Feb 14, 2025
a15b3b1
Feature: Suggestion popup to open a new chat (#331)
alashchev17 Feb 14, 2025
958e450
fix: mention o3-mini as reasoning model in switch
alashchev17 Feb 14, 2025
51b55bf
new qwen25 models with tool usage
mitya52 Feb 15, 2025
6d1724c
mistral small model with tool use
mitya52 Feb 16, 2025
d247862
fix: show mcp error to the model
humbertoyusta Feb 14, 2025
579fa57
fix: add warning to use npx.cmd and npm.cmd in Windows
humbertoyusta Feb 14, 2025
6622640
label
olegklimov Feb 16, 2025
1bcc551
fix(prompt): simplified prompt so gpt-4o-mini can understand correctl…
alashchev17 Feb 14, 2025
314f20b
- use shell escape for cmd tool
hamzahasann Feb 7, 2025
b5ff4db
stronger escape for powershell in cmdtool
hamzahasann Feb 11, 2025
ea1de49
deps
olegklimov Feb 16, 2025
4d017ea
Create refact.yaml
ukrolelo Feb 5, 2025
696c14e
rename to bring_your_own_key/refact_self_hosting.yaml
olegklimov Feb 16, 2025
985be53
Merge branch 'main' into dev
olegklimov Feb 17, 2025
774fdd3
move everything to refact-agent/
olegklimov Feb 17, 2025
a830f51
move rustfmt.toml
olegklimov Feb 17, 2025
08df2e0
move everything over to refact-server
olegklimov Feb 17, 2025
163d9ed
move away .github
olegklimov Feb 17, 2025
4d16c06
Merge branch 'oleg_pre_merge_lsp' into oleg_great_merge
olegklimov Feb 17, 2025
01faa64
delete integrations.d for now
olegklimov Feb 17, 2025
16b5ebc
move all files to refact-agent/gui
olegklimov Feb 17, 2025
43b05fc
Merge branch 'oleg_pre_merge_chatjs' into oleg_great_merge
olegklimov Feb 17, 2025
1eb27c9
move rust to engine/
olegklimov Feb 17, 2025
e097791
no "husky install"
olegklimov Feb 17, 2025
0dd2d98
add basic cicd stuff
reymondzzzz Feb 17, 2025
0b41f5d
disable test
reymondzzzz Feb 17, 2025
b35d0f0
fix uploading
reymondzzzz Feb 17, 2025
71b0e8c
quickfix for test13_choredb
olegklimov Feb 18, 2025
edb97fe
fix double build of server
reymondzzzz Feb 18, 2025
4623909
fix vecdb and stats in case of insecure https connection, add notes f…
mitya52 Feb 18, 2025
31b891e
quickfix of stats table
mitya52 Feb 18, 2025
c9f2b6e
debug session 1
olegklimov Feb 18, 2025
65d380e
less messages
olegklimov Feb 19, 2025
ef37843
chore(chaT): sync with changes to alpha, include new patches.
MarcMcIntosh Feb 18, 2025
e688f62
fix(git ignore): git was ignoring __fixtures__ and __tests__ director…
MarcMcIntosh Feb 18, 2025
2e7da6d
chore(chat): update repository url in package.jsson
MarcMcIntosh Feb 18, 2025
b55ece8
fix(chat)): opening an old chat from history without the newer `sugge…
MarcMcIntosh Feb 20, 2025
c6ab7ff
Enable reasoning support for models and remove filtering in hook
JegernOUTT Feb 20, 2025
de36005
Improve error messages in file_edit tools for better clarity
JegernOUTT Feb 20, 2025
1ef4b8b
fix: check if path is absolute for create textdoc before canonicaliza…
humbertoyusta Feb 21, 2025
e5f8dda
fix: static lsp in predictible path instead of configured, and create…
humbertoyusta Feb 17, 2025
14a29af
fix: create network if not exist and get host cache dir
humbertoyusta Feb 17, 2025
0234683
fix: http request with retries so sync workspace can wait for http se…
humbertoyusta Feb 17, 2025
f49dd30
from manuel: impersonate cosmopolitan to fix static build of sqlite vec
humbertoyusta Feb 17, 2025
6d9cde2
fix: move dockerignore to engine, since refact-lsp static binary is b…
humbertoyusta Feb 17, 2025
a19a5b2
oops. sleep only for debug, not needed now
humbertoyusta Feb 18, 2025
6199852
feat: allow `globally_allowed_integrations` to be set in integrations…
humbertoyusta Feb 18, 2025
ae95f5b
fix: include __init__.py
humbertoyusta Feb 18, 2025
db2dbcc
fix: temp fix for auto generate cdp
humbertoyusta Feb 19, 2025
2f4dcaf
fix: replace async tar with tokio tar to not use different async envi…
humbertoyusta Feb 20, 2025
65794a1
fix engine build
reymondzzzz Feb 21, 2025
7f0a9a6
delete rudimental code
reymondzzzz Feb 21, 2025
3efa513
fix: making usage limits for all users (#519)
alashchev17 Feb 21, 2025
87ea2bc
ci: update version bump logic for alpha branch & npm publish in CI (#…
alashchev17 Feb 23, 2025
766a839
refactor: use git2 status show instead of redundant enum, allow to ge…
humbertoyusta Feb 20, 2025
c725df3
uncommited changes warning message separating unstaged and staged
humbertoyusta Feb 20, 2025
fda55a2
remove unused method
humbertoyusta Feb 20, 2025
6dbfe3b
fix: uncommited changes warning, failed integrations links and more s…
humbertoyusta Feb 21, 2025
84c1916
fix: add usage also for delta collector in streaming in python sdk
humbertoyusta Feb 21, 2025
52c8134
fix: count cache tokens for claude
humbertoyusta Feb 21, 2025
56e4add
fix: increase stream limit
humbertoyusta Feb 21, 2025
e95810c
fix: secrets yaml was not used
humbertoyusta Feb 24, 2025
e02d3dd
ci(npm publish): better version bump message (#523)
alashchev17 Feb 24, 2025
e6e37ba
fix: showing usable models if user's plan is not FREE (#522)
alashchev17 Feb 24, 2025
56c5980
feat: version bump [email protected] (#525)
alashchev17 Feb 24, 2025
5a502c9
feat: version bump [email protected] (#526)
alashchev17 Feb 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
8 changes: 8 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
*.skeleton text eol=lf
*.rs text eol=lf
*.cpp text eol=lf
*.java text eol=lf
*.js text eol=lf
*.ts text eol=lf
*.py text eol=lf
tests/emergency_frog_situation/frog.py text eol=*
161 changes: 161 additions & 0 deletions .github/workflows/agent_engine_build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,161 @@
name: Refact Agent Engine CI build (Rust)

on:
# Trigger the workflow on pushes to only the 'main' branch (this avoids duplicate checks being run e.g. for dependabot pull requests)
push:
branches: [main, dev]
paths:
- "refact-agent/engine/**"
- ".github/workflows/agent_engine_*"
# Trigger the workflow on any pull request
pull_request:
paths:
- "refact-agent/engine/**"
- ".github/workflows/agent_engine_*"
workflow_dispatch:
repository_dispatch:
# workflow_run:
# workflows: ["Cache cleanup"]
# types:
# - completed

defaults:
run:
working-directory: refact-agent/engine

env:
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
# RUSTFLAGS: "-D warnings -W unreachable-pub"
RUSTUP_MAX_RETRIES: 10
FETCH_DEPTH: 0 # pull in the tags for the version string
MACOSX_DEPLOYMENT_TARGET: 10.15

jobs:
dist:
strategy:
matrix:
include:
- os: windows-latest
target: x86_64-pc-windows-msvc
code-target: win32-x64
ext: .exe
whl-tag: win_amd64
- os: windows-latest
target: i686-pc-windows-msvc
code-target: win32-ia32
ext: .exe
- os: windows-latest
target: aarch64-pc-windows-msvc
code-target: win32-arm64
ext: .exe
whl-tag: win_arm64
- os: ubuntu-22.04
target: x86_64-unknown-linux-gnu
code-target: linux-x64
whl-tag: manylinux2014_x86_64
cross: true
- os: ubuntu-22.04
target: aarch64-unknown-linux-gnu
code-target: linux-arm64
whl-tag: manylinux2014_aarch64
cross: true
# - os: ubuntu-22.04
# target: arm-unknown-linux-gnueabihf
# code-target: linux-armhf
- os: macos-13
target: x86_64-apple-darwin
code-target: darwin-x64
whl-tag: macosx_13_0_x86_64
- os: macos-14
target: aarch64-apple-darwin
code-target: darwin-arm64
whl-tag: macosx_13_0_arm64

env:
LLM_LS_TARGET: ${{ matrix.target }}

name: dist (${{ matrix.target }})
runs-on: ${{ matrix.os }}
container: ${{ matrix.container }}

steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: ${{ env.FETCH_DEPTH }}

- name: Install Rust toolchain
run: |
rustup update --no-self-update stable
rustup target add ${{ matrix.target }}
rustup component add rust-src

- name: setup cross-rs
if: matrix.cross
run: |
cargo install cross --git https://github.com/cross-rs/cross

- name: Install ARM target toolchain
if: matrix.target == 'arm-unknown-linux-gnueabihf'
run: sudo apt-get install gcc-arm-linux-gnueabihf

- name: Restore cached cargo
uses: swatinem/rust-cache@v2
with:
key: ${{ matrix.os }}-${{ matrix.target }}-cargo
shared-key: ${{ matrix.os }}-${{ matrix.target }}-cargo

- name: Build and test artifact
if: matrix.cross == null && startsWith(matrix.os, 'windows')
run: |
cargo test --release || exit 1
cargo build --release || exit 1
mkdir python_binding_and_cmdline/refact/bin
cp ./target/release/refact-lsp${{ matrix.ext }} python_binding_and_cmdline/refact/bin
cp ./target/release/refact-lsp${{ matrix.ext }} ../..

- name: Build and test artifact
if: matrix.cross == null && !startsWith(matrix.os, 'windows')
run: |
OPENSSL_STATIC=1 cargo test --release --target ${{ matrix.target }} || exit 1
OPENSSL_STATIC=1 cargo build --release --target ${{ matrix.target }} || exit 1
mkdir python_binding_and_cmdline/refact/bin
cp ./target/${{ matrix.target }}/release/refact-lsp${{ matrix.ext }} python_binding_and_cmdline/refact/bin
cp ./target/${{ matrix.target }}/release/refact-lsp${{ matrix.ext }} ../..

- name: build linux-like artifacts
if: matrix.cross
run: |
CROSS_NO_WARNINGS=0 cross test --release --target ${{ matrix.target }} || exit 1
CROSS_NO_WARNINGS=0 cross build --release --target ${{ matrix.target }} || exit 1
mkdir python_binding_and_cmdline/refact/bin
cp ./target/${{ matrix.target }}/release/refact-lsp${{ matrix.ext }} python_binding_and_cmdline/refact/bin
cp ./target/${{ matrix.target }}/release/refact-lsp${{ matrix.ext }} ../..

- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: dist-${{ matrix.target }}
if-no-files-found: ignore
path: |
refact-lsp
refact-lsp.exe

- if: matrix.whl-tag
shell: bash
env:
WHL_TAG: ${{ matrix.whl-tag }}
run: |
version=$(grep '^version' Cargo.toml | sed -E 's/version = "(.*)"/\1/')-dev
sed -i.bak -E "s/version=\"[^\"]+\"/version=\"$version\"/" python_binding_and_cmdline/setup.py

pip install wheel build setuptools
python -m build --wheel --no-isolation python_binding_and_cmdline --outdir artefacts/

- uses: actions/upload-artifact@v4
if: matrix.whl-tag
with:
name: whl-${{ matrix.target }}
if-no-files-found: ignore
path: refact-agent/engine/artefacts/*.whl
175 changes: 175 additions & 0 deletions .github/workflows/agent_engine_release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,175 @@
name: Refact Agent Engine CI Release (Rust)

on:
workflow_dispatch:
push:
tags:
- '*'

defaults:
run:
working-directory: refact-agent/engine

env:
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
# RUSTFLAGS: "-D warnings -W unreachable-pub"
RUSTUP_MAX_RETRIES: 10
FETCH_DEPTH: 0 # pull in the tags for the version string
MACOSX_DEPLOYMENT_TARGET: 10.15

jobs:
dist:
strategy:
matrix:
include:
- os: windows-latest
target: x86_64-pc-windows-msvc
code-target: win32-x64
ext: .exe
whl-tag: win_amd64
- os: windows-latest
target: i686-pc-windows-msvc
code-target: win32-ia32
ext: .exe
- os: windows-latest
target: aarch64-pc-windows-msvc
code-target: win32-arm64
ext: .exe
whl-tag: win_arm64
- os: ubuntu-20.04
target: x86_64-unknown-linux-gnu
code-target: linux-x64
whl-tag: manylinux2014_x86_64
cross: true
- os: ubuntu-20.04
target: aarch64-unknown-linux-gnu
code-target: linux-arm64
whl-tag: manylinux2014_aarch64
cross: true
# - os: ubuntu-22.04
# target: arm-unknown-linux-gnueabihf
# code-target: linux-armhf
- os: macos-13
target: x86_64-apple-darwin
code-target: darwin-x64
whl-tag: macosx_13_0_x86_64
- os: macos-14
target: aarch64-apple-darwin
code-target: darwin-arm64
whl-tag: macosx_13_0_arm64

env:
LLM_LS_TARGET: ${{ matrix.target }}

name: dist (${{ matrix.target }})
runs-on: ${{ matrix.os }}
container: ${{ matrix.container }}

steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: ${{ env.FETCH_DEPTH }}

- name: Install Rust toolchain
run: |
rustup update --no-self-update stable
rustup target add ${{ matrix.target }}
rustup component add rust-src

- name: setup cross-rs
if: matrix.cross
run: |
cargo install cross --git https://github.com/cross-rs/cross

- name: Install ARM target toolchain
if: matrix.target == 'arm-unknown-linux-gnueabihf'
run: sudo apt-get install gcc-arm-linux-gnueabihf

- name: Restore cached cargo
uses: swatinem/rust-cache@v2
with:
key: ${{ matrix.os }}-${{ matrix.target }}-cargo
shared-key: ${{ matrix.os }}-${{ matrix.target }}-cargo

- name: Build and test artifact
if: matrix.cross == null && startsWith(matrix.os, 'windows')
run: |
cargo test --release || exit 1
cargo build --release || exit 1
mkdir python_binding_and_cmdline/refact/bin
cp ./target/release/refact-lsp${{ matrix.ext }} python_binding_and_cmdline/refact/bin
cp ./target/release/refact-lsp${{ matrix.ext }} ../..

- name: Build and test artifact
if: matrix.cross == null && !startsWith(matrix.os, 'windows')
run: |
OPENSSL_STATIC=1 cargo test --release --target ${{ matrix.target }} || exit 1
OPENSSL_STATIC=1 cargo build --release --target ${{ matrix.target }} || exit 1
mkdir python_binding_and_cmdline/refact/bin
cp ./target/${{ matrix.target }}/release/refact-lsp${{ matrix.ext }} python_binding_and_cmdline/refact/bin
cp ./target/${{ matrix.target }}/release/refact-lsp${{ matrix.ext }} ../..

- name: build linux-like artifacts
if: matrix.cross
run: |
CROSS_NO_WARNINGS=0 cross test --release --target ${{ matrix.target }} || exit 1
CROSS_NO_WARNINGS=0 cross build --release --target ${{ matrix.target }} || exit 1
mkdir python_binding_and_cmdline/refact/bin
cp ./target/${{ matrix.target }}/release/refact-lsp${{ matrix.ext }} python_binding_and_cmdline/refact/bin
cp ./target/${{ matrix.target }}/release/refact-lsp${{ matrix.ext }} ../..

- if: matrix.whl-tag
shell: bash
env:
WHL_TAG: ${{ matrix.whl-tag }}
run: |
version=$(grep '^version' Cargo.toml | sed -E 's/version = "(.*)"/\1/')
sed -i.bak -E "s/version=\"[^\"]+\"/version=\"$version\"/" python_binding_and_cmdline/setup.py

pip install wheel build setuptools
python -m build --wheel --no-isolation python_binding_and_cmdline --outdir artefacts/

- name: Upload whl to release
uses: svenstaro/upload-release-action@v2
if: matrix.whl-tag
with:
repo_token: ${{ github.token }}
asset_name: whl-${{ matrix.target }}
file: artefacts/*.whl
tag: ${{ github.ref }}
overwrite: true
file_glob: true

- name: Upload whl pypi
if: matrix.whl-tag
run: |
pip install twine
twine upload -p ${{ secrets.PYPI_TOKEN }} --skip-existing artefacts/*.whl

- name: Package artifact in ZIP (WIN)
uses: vimtor/[email protected]
if: endsWith(matrix.target, 'msvc')
with:
files: refact-lsp.exe
recursive: false
dest: dist-${{ matrix.target }}.zip

- name: Package artifact in ZIP (UNIX)
uses: vimtor/[email protected]
if: ${{ !endsWith(matrix.target, 'msvc') }}
with:
files: refact-lsp
recursive: false
dest: dist-${{ matrix.target }}.zip

- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ github.token }}
asset_name: dist-${{ matrix.target }}
file: dist-${{ matrix.target }}.zip
tag: ${{ github.ref }}
overwrite: true
file_glob: true
Loading
Loading