Skip to content

Commit 18f4f67

Browse files
committed
feat: initial term-executor — remote evaluation server for Basilica
HTTP API for remote evaluation: - POST /evaluate — start async evaluation (agent_code + task_url) - GET /evaluate/{id} — poll evaluation status - DELETE /evaluate/{id} — cancel evaluation - GET /health — health check Architecture: - Downloads swe-forge task archive (workspace.yaml + tests/) - Clones repo, installs deps, runs agent, runs test scripts - Session-based isolation with TTL auto-cleanup - Bearer token auth middleware - Dockerfile with Python 3, Node 20, Go 1.22, common test tools
0 parents  commit 18f4f67

11 files changed

Lines changed: 3892 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
env:
10+
CARGO_TERM_COLOR: always
11+
REGISTRY: ghcr.io
12+
IMAGE_NAME: ${{ github.repository }}
13+
14+
jobs:
15+
build-and-test:
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
- name: Install Rust
21+
uses: dtolnay/rust-toolchain@stable
22+
23+
- name: Cache cargo
24+
uses: actions/cache@v4
25+
with:
26+
path: |
27+
~/.cargo/registry
28+
~/.cargo/git
29+
target
30+
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
31+
32+
- name: Build
33+
run: cargo build --release
34+
35+
- name: Test
36+
run: cargo test
37+
38+
docker:
39+
needs: build-and-test
40+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
41+
runs-on: ubuntu-latest
42+
permissions:
43+
contents: read
44+
packages: write
45+
steps:
46+
- uses: actions/checkout@v4
47+
48+
- name: Log in to GHCR
49+
uses: docker/login-action@v3
50+
with:
51+
registry: ${{ env.REGISTRY }}
52+
username: ${{ github.actor }}
53+
password: ${{ secrets.GITHUB_TOKEN }}
54+
55+
- name: Build and push
56+
uses: docker/build-push-action@v5
57+
with:
58+
context: .
59+
push: true
60+
tags: |
61+
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
62+
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.sha }}

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/target

0 commit comments

Comments
 (0)