Skip to content

Add LangChain & LlamaIndex adapters, runnable examples, and CI smoke tests#25

Merged
HiveForensicsAI merged 1 commit intocodex/restructure-knolo-repository-for-monorepofrom
codex/implement-langchain-and-llamaindex-adapters
Feb 21, 2026
Merged

Add LangChain & LlamaIndex adapters, runnable examples, and CI smoke tests#25
HiveForensicsAI merged 1 commit intocodex/restructure-knolo-repository-for-monorepofrom
codex/implement-langchain-and-llamaindex-adapters

Conversation

@HiveForensicsAI
Copy link
Contributor

Motivation

  • Make KnoLo adoption-frictionless by providing production-ready adapters for LangChain and LlamaIndex so developers can drop KnoLo in as a retriever with minimal friction.
  • Provide minimal, runnable ecosystem examples and CI smoke tests to guarantee an end-to-end developer flow completes quickly and reliably.
  • Keep adapters as thin wrappers around @knolo/core without introducing new LLM logic or speculative APIs.

Description

  • Implemented @knolo/langchain with KnoLoRetriever that loads a pack via mountPack (or accepts a pack) and returns LangChain-style Document objects populated with score, source, namespace, and id metadata via query from @knolo/core.
  • Implemented @knolo/llamaindex with KnoLoRetriever exposing retrieve(query) that returns NodeWithScore-like objects { node: { text, metadata }, score } using mountPack + query.
  • Added unit tests for both adapters under packages/langchain/test and packages/llamaindex/test to validate returned structures and metadata population, and extended create-knolo-app tests to run a generated-project knolo build to assert indexing.
  • Added runnable examples in examples/ (langchain-basic, llamaindex-basic, node-cli-rag, nextjs-rag-chat), updated the root README.md with quickstarts and adapter snippets, and wired a CI workflow (.github/workflows/ci.yml) to run npm ci, npm run build, and npm test on PRs and pushes.

Testing

  • Ran full workspace validation: npm install, npm run build, and npm test, and all automated tests passed successfully.
  • Verified adapter unit tests passed when running npm test for @knolo/langchain and @knolo/llamaindex and they return the expected document/node shapes and metadata.
  • Executed the examples smoke flows: examples/langchain-basic (npm install && npm run start), examples/llamaindex-basic (npm install && npm run start), examples/node-cli-rag (npm install && npm run build-pack && npm run query), and examples/nextjs-rag-chat (npm install && npm run start), and each completed successfully in this environment.

Codex Task

@HiveForensicsAI HiveForensicsAI merged commit dd546a2 into codex/restructure-knolo-repository-for-monorepo Feb 21, 2026
0 of 2 checks passed
@HiveForensicsAI HiveForensicsAI deleted the codex/implement-langchain-and-llamaindex-adapters branch February 21, 2026 17:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant