Interlock · Experiment E1실험 E1

Writing calls against a teammate's declared signature동료가 선언한 시그니처에 맞춰 호출을 쓰는가

Two agents can each pass their own tests and still break main: one changes a function's signature while the other writes a new call to it. E1 measures whether an agent, never told about the change, writes the call for the signature a teammate has declared. 두 에이전트가 각자 테스트를 통과해도 main은 깨질 수 있습니다. 한쪽이 함수 시그니처를 바꾸는 동안 다른 쪽이 그 함수를 부르는 새 코드를 쓰는 경우입니다. E1은 변경 사실을 듣지 못한 에이전트가 동료가 선언한 시그니처에 맞춰 호출을 쓰는지 측정했습니다.

Run on 2026-10-18 with Interlock V3.0.0 and real Claude Code 2.1.302 sessions: 192 sessions in this experiment, including the first run before fixes.2026-10-18, Interlock V3.0.0과 실제 Claude Code 2.1.302 세션으로 실행. 이 실험의 세션은 수정 전 1차 실행을 포함해 192개입니다. Raw results (JSON)원자료 (JSON)

Method방법

  • Setup: a teammate agent has declared that it will change login(user, password) to login(user, password, otp); the change is not merged. A second agent is not told about it and gets one of four tasks that call login: three in Python (add a function, add a file, change a function) and one in TypeScript. The repository is small (2 to 6 files).설정: 동료 에이전트가 login(user, password)를 login(user, password, otp)로 바꾸겠다고 선언했고, 변경은 병합 전입니다. 다른 에이전트는 이 사실을 듣지 못한 채 login을 부르는 작업 4종 중 하나를 받습니다. Python 3종(함수 추가, 파일 추가, 함수 수정)과 TypeScript 1종이며, 저장소는 작습니다(파일 2~6개).
  • Agent: Claude Code run headless (claude -p), default model Sonnet 5.5. Every run starts from a fresh git repository and a fresh Interlock store. Five runs per task and condition.에이전트: 헤드리스 Claude Code(claude -p), 기본 모델 Sonnet 5.5. 매 실행은 새 git 저장소와 새 Interlock 저장소에서 시작합니다. 작업·조건마다 5회.
  • Conditions: no Interlock; edit check only (edits that break the declared signature are refused, reads are unchanged); Interlock V3 (edit check, and reads show the declared signature).조건: Interlock 없음, 편집 검사만(선언된 시그니처에 맞지 않는 편집은 거부, 읽기는 그대로), Interlock V3(편집 검사 + 읽을 때 선언된 시그니처를 보여줌).
  • Judged by code, not people: each call is bound against the declared signature with the interpreter's argument rules.판정은 사람이 아니라 코드: 각 호출을 언어의 인자 바인딩 규칙으로 선언된 시그니처에 맞춰 판정합니다.

Results결과

Condition조건 Calls fit the declared signature선언된 시그니처에 맞는 호출 Refused at least once한 번 이상 거부됨 Task finished작업 완료 Avg. turns평균 턴 Total cost비용 합
No InterlockInterlock 없음0/200/2020/203.90$1.20
Edit check only편집 검사만19/2020/2019/204.80$1.44
Interlock V320/206/2020/204.05$1.33
  • Without Interlock, all 20 runs wrote the call for the old signature, which breaks once the teammate's change merges.Interlock이 없으면 20번 모두 옛 시그니처로 호출을 썼습니다. 동료의 변경이 병합되면 깨지는 코드입니다.
  • With Interlock V3, all 20 calls fit the declared signature. The 6 runs that were refused once all fixed the call themselves and finished.Interlock V3에서는 20번 모두 선언된 시그니처에 맞았습니다. 한 번 거부된 6번도 모두 스스로 호출을 고쳐 작업을 끝냈습니다.
  • With the edit check alone, every run was refused at least once before writing the right call; showing the declared signature on read is what avoids most refusals.편집 검사만 있으면 모든 실행이 맞는 호출을 쓰기 전에 한 번 이상 거부를 거쳤습니다. 거부 대부분을 없앤 것은 읽을 때 선언된 시그니처를 보여주는 부분입니다.
  • The teammate's own function was left untouched in all 60 runs. Cost was 11% higher and turns 4% higher than without Interlock.동료의 함수는 60번 모두 건드려지지 않았습니다. Interlock이 없을 때보다 비용은 11%, 턴은 4% 늘었습니다.

Before the fixes수정 전 1차 실행

  • The first run of the same setup scored 16/20 with Interlock V3 and 6/20 with the edit check alone. It exposed two defects: calls in a newly created file were not checked, and refused agents often stopped (9 of the 15 refused runs with the edit check alone did not finish).같은 설정의 첫 실행은 Interlock V3 16/20, 편집 검사만 6/20이었습니다. 이때 결함 두 개가 드러났습니다. 새로 만든 파일 안의 호출은 검사하지 않았고, 거부된 에이전트가 자주 멈췄습니다(편집 검사만 조건에서 거부된 15번 중 9번이 작업을 끝내지 못함).
  • We now check the content being written, and the refusal message says how to go on. The table above is the second run, after both fixes; the first run is in the raw data.이제 쓰려는 내용 자체를 검사하고, 거부 메시지에 진행 방법을 알려줍니다. 위 표는 두 결함을 고친 뒤의 2차 실행이며, 1차 실행도 원자료에 들어 있습니다.

Other models and a rerun다른 모델과 재실행

  • Opus 5.5 (three tasks, three runs each, Interlock V3): 9 of 9 calls fit, with no refusals.Opus 5.5(작업 3종 × 3회, Interlock V3): 9번 모두 맞았고 거부는 없었습니다.
  • Haiku 5.5 (same setup): only 2 of 9 fit. 8 runs were refused, and 6 of those stopped to ask the user, because fitting the call meant changing a function signature the user had set.Haiku 5.5(같은 설정): 9번 중 2번만 맞았습니다. 8번이 거부됐고 그중 6번은 사용자가 정한 함수 시그니처를 바꿔야 한다며 사용자에게 묻고 멈췄습니다.
  • Rerun: after an independent review found and fixed 12 more defects, we ran it again with Sonnet 5.5. Interlock V3 fit 12 of 12 alone and 12 of 12 in a side-by-side batch where no Interlock fit 0 of 12. Every refused run finished; in that batch cost was 12% and turns 9% higher.독립 리뷰로 결함 12건을 더 고친 뒤 재실행(Sonnet 5.5): Interlock V3는 단독 12/12, 나란히 비교한 배치에서도 12/12였고 같은 배치의 Interlock 없음은 0/12였습니다. 거부된 실행은 모두 끝까지 마쳤고, 그 배치에서 비용은 12%, 턴은 9% 늘었습니다.

What to watch주의할 점

  • Unrequested parameters: in almost every run whose call fit, the agent also added otp as a parameter of its own new function so it could pass the value on. The user did not ask for this. Interlock's refusal message suggests it as the usual way to go on; whether it is right depends on the codebase.요청하지 않은 매개변수: 호출이 맞은 실행 대부분에서 에이전트가 값을 넘기기 위해 자기 새 함수에도 otp 매개변수를 더했습니다. 사용자가 요청한 변경은 아닙니다. Interlock의 거부 메시지가 이것을 보통의 진행 방법으로 제시하며, 맞는 선택인지는 코드베이스에 따라 다릅니다.
  • Smaller models stop: when the declared signature conflicts with what the user asked for, Haiku asks the user instead of going on (6 of 8 refused runs). That can be the right call, but the task is left unfinished.작은 모델은 멈춘다: 선언된 시그니처가 사용자 지시와 부딪치면 Haiku는 계속하지 않고 사용자에게 묻습니다(거부된 8번 중 6번). 옳은 판단일 수 있지만 작업은 끝나지 않습니다.

Limits한계

  • Small repositories and five runs per cell, so the confidence intervals are wide. The declared change is a single added required argument.저장소가 작고 칸마다 5회라 신뢰구간이 넓습니다. 선언된 변경은 필수 인자 하나를 더하는 경우뿐입니다.
  • Only Anthropic models were used; the Codex and Cursor hooks were not run with live agents.Anthropic 모델만 썼고, Codex·Cursor 훅은 실제 에이전트로 돌리지 않았습니다.
  • E1 is 192 of the 560 live Claude Code sessions in our experiments. The Interlock source and the experiment harness are not public.E1은 전체 실험의 실제 Claude Code 세션 560개 중 192개입니다. Interlock 소스와 실험 도구는 공개하지 않습니다.