Skip to content

Conversation

@grypez
Copy link
Contributor

@grypez grypez commented Dec 15, 2025

This PR adds a queue language model service to the monorepo. The implementation is intended for mocking language model behavior where a remote API or local model execution are both unavailable. The intended streaming response is pushed to the model prior to sampling.

Also adds tests to kernel-test which exercise the basic shape of a LanguageModelService.


Note

Adds a queue-based LanguageModelService testing utility and integrates it into kernel tests via new vats, plus updates exports and coverage thresholds.

  • Kernel Language Model Service (packages/kernel-language-model-service):
    • Test Utils: Add queue-based model/service (src/test-utils/queue/*) with makeQueueModel, makeQueueService, whitespaceTokenizer, objectResponseFormatter, and streaming helpers (normalizeToAsyncIterable, mapAsyncIterable, makeAbortableAsyncIterable, makeEmptyStreamWithAbort).
    • Exports: Expose ./test-utils entry in package.json and re-export from src/test-utils/index.ts.
    • Tests/Docs: Add unit tests for model, tokenizer, response, utils, and a README.
  • Kernel Test (packages/kernel-test):
    • New Vats: Add vats/lms-queue-vat.js (envatted queue service) and vats/lms-user-vat.js (consumer).
    • Integration Test: Add src/lms-user.test.ts asserting streamed response logging; add dependency on @ocap/kernel-language-model-service.
  • Tooling:
    • Coverage: Update vitest.config.ts coverage thresholds for packages/kernel-language-model-service/**.

Written by Cursor Bugbot for commit 9277005. This will update automatically on new commits. Configure here.

@grypez grypez changed the base branch from main to grypez/exo-disc December 15, 2025 18:13
@socket-security
Copy link

socket-security bot commented Dec 16, 2025

No dependency changes detected. Learn more about Socket for GitHub.

👍 No dependency changes detected in pull request

@grypez grypez changed the base branch from grypez/exo-disc to main December 16, 2025 13:49
@grypez grypez marked this pull request as ready for review December 16, 2025 18:11
@grypez grypez requested a review from a team as a code owner December 16, 2025 18:11
Copy link
Member

@rekmarks rekmarks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of nits.

@grypez grypez force-pushed the grypez/klmsq branch 2 times, most recently from 43ff5aa to 5080e53 Compare December 17, 2025 21:20
Copy link
Member

@rekmarks rekmarks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@grypez grypez enabled auto-merge (squash) December 18, 2025 13:13
@grypez grypez merged commit bdec925 into main Dec 18, 2025
26 checks passed
@grypez grypez deleted the grypez/klmsq branch December 18, 2025 13:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants