Skip to content

[codex] refactor LLM package internals#121

Draft
CorieW wants to merge 2 commits into
mainfrom
codex/refactor-llms-package
Draft

[codex] refactor LLM package internals#121
CorieW wants to merge 2 commits into
mainfrom
codex/refactor-llms-package

Conversation

@CorieW
Copy link
Copy Markdown
Owner

@CorieW CorieW commented May 3, 2026

Summary

  • Split the LLM chat text-generation flow into support-style internal modules for contracts, transcript normalization, default messages, and runtime orchestration.
  • Split the text-generation backend client into internal modules for contracts, request serialization, response validation, and the fetch-backed factory.
  • Kept existing public facades and root exports in place, and updated the package file whitelist so the new internal TypeScript modules are included without publishing AGENTS inventory files.

Impact

This is intended to be a non-breaking internal refactor. Consumers should keep importing the same public names from react-actions-chat-llms.

Validation

  • pnpm exec vitest run --config config/vite.config.ts packages/react-actions-chat-llms/src/__tests__/chatTextGenerationFlow.test.ts packages/react-actions-chat-llms/src/__tests__/textGenerationBackend.test.ts
  • pnpm --filter react-actions-chat-llms typecheck
  • pnpm --filter react-actions-chat-llms lint
  • pnpm --filter react-actions-chat-llms format:check
  • node /Users/coriewatson/.codex/skills/agentsmd-hierarchy/scripts/validate-agents.mjs --check packages/react-actions-chat-llms/src
  • git diff --check
  • pnpm --dir packages/react-actions-chat-llms exec npm pack --dry-run --json

Note: pnpm --filter react-actions-chat-llms test currently runs the broader repo test set through the shared Vite config; that attempt hit timeouts in non-LLM Chat/support tests, while the LLM-specific tests above passed.

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.

1 participant