Complete the Common Lisp-only runtime migration #85

Open
nsaspy wants to merge 18 commits from feature/cl-native-bulk-infill into main
Owner

Architecture correction

This finishes the zero-Python migration and makes the repository's maintained implementation Common Lisp + Nix/shell glue.

Runtime

  • deletes llm_log/, tests/, pyproject.toml, the Python Nix package, and Python CI workflows
  • makes packages.default the Common Lisp runtime
  • live HTTP forwarding, raw events.jsonl capture, header redaction, model/token extraction, analytics API, quota telemetry, and expert infill are all Common Lisp
  • the proxy owns one in-process Common Lisp/Tek9/SWI expert host; local operations do not use HTTP or a subprocess adapter

50GB+ corpus paths

  • llm-log bulk-load: binary streaming, one JSONL row at a time, direct CL -> Tek9/SWI, byte-offset checkpoints, bounded source fingerprint
  • llm-log infill: requires/resumes the same checkpoint and consumes only appended bytes
  • live captures call the same CL projection directly after raw append
  • bulk-load builds durable Tek9 analytics aggregates in the same pass so API/widget reads do not rescan raw JSONL

Remote deployment

  • retains HTTP only for a separately deployed expert host
  • llm-log-expert serve --http is implemented in Common Lisp/Woo
  • typed /v1/expert/rpc and bounded /v1/expert/batch
  • non-loopback binds require LLM_LOG_EXPERT_HTTP_TOKEN

Language invariant

  • CI fails if tracked Python source or pyproject.toml reappears
  • embedded Prolog rule files are marked vendored for GitHub language accounting

Verification

The PR adds a CL integration contract for bulk-load -> restart -> zero-work infill -> append -> one-record infill, including durable token analytics. Nix/SBCL exact-head CI is the merge authority.

## Architecture correction This finishes the zero-Python migration and makes the repository's maintained implementation Common Lisp + Nix/shell glue. ### Runtime - deletes `llm_log/`, `tests/`, `pyproject.toml`, the Python Nix package, and Python CI workflows - makes `packages.default` the Common Lisp runtime - live HTTP forwarding, raw `events.jsonl` capture, header redaction, model/token extraction, analytics API, quota telemetry, and expert infill are all Common Lisp - the proxy owns one in-process Common Lisp/Tek9/SWI expert host; local operations do not use HTTP or a subprocess adapter ### 50GB+ corpus paths - `llm-log bulk-load`: binary streaming, one JSONL row at a time, direct CL -> Tek9/SWI, byte-offset checkpoints, bounded source fingerprint - `llm-log infill`: requires/resumes the same checkpoint and consumes only appended bytes - live captures call the same CL projection directly after raw append - bulk-load builds durable Tek9 analytics aggregates in the same pass so API/widget reads do not rescan raw JSONL ### Remote deployment - retains HTTP only for a separately deployed expert host - `llm-log-expert serve --http` is implemented in Common Lisp/Woo - typed `/v1/expert/rpc` and bounded `/v1/expert/batch` - non-loopback binds require `LLM_LOG_EXPERT_HTTP_TOKEN` ### Language invariant - CI fails if tracked Python source or `pyproject.toml` reappears - embedded Prolog rule files are marked vendored for GitHub language accounting ## Verification The PR adds a CL integration contract for bulk-load -> restart -> zero-work infill -> append -> one-record infill, including durable token analytics. Nix/SBCL exact-head CI is the merge authority.
Some checks failed
Common Lisp runtime / common-lisp (pull_request) Failing after 3s
This pull request has changes conflicting with the target branch.
  • flake.nix
  • llm_log/cli.py
  • llm_log/proxy.py
  • llm_log/recorder.py
  • proxy/config.lisp
  • proxy/transport.lisp
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin feature/cl-native-bulk-infill:feature/cl-native-bulk-infill
git switch feature/cl-native-bulk-infill

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch main
git merge --no-ff feature/cl-native-bulk-infill
git switch feature/cl-native-bulk-infill
git rebase main
git switch main
git merge --ff-only feature/cl-native-bulk-infill
git switch feature/cl-native-bulk-infill
git rebase main
git switch main
git merge --no-ff feature/cl-native-bulk-infill
git switch main
git merge --squash feature/cl-native-bulk-infill
git switch main
git merge --ff-only feature/cl-native-bulk-infill
git switch main
git merge feature/cl-native-bulk-infill
git push origin main
Sign in to join this conversation.
No description provided.