Add skillos-langchain: LangChain toolkit for Curator#13
Open
skillos-bot wants to merge 1 commit into
Open
Conversation
Introduces the skillos-langchain package mirroring skillos-strands: - LangChainCurator: a Curator backed by langchain.agents.create_agent that formats conversation history (LangChain BaseMessage and dict styles) and drives skill-management tools. - create_skill_tools: LangChain @tool wrappers around SkillRepo (list/read/insert/update/delete) that record applied/failed mutations into a Changelog. - _CuratorCallbackHandler / LangChainCurator.callback(): the LangChain equivalent of a Strands hook provider. It hooks the agent lifecycle and curates the conversation when the root run completes. Also sets pytest --import-mode=importlib so packages can share test file basenames, and lists the new package in the README. https://claude.ai/code/session_019cNC4hjVdpJKAJofeY6SBy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds the
skillos-langchainpackage, mirroring the existingskillos-strandspackage, so the Curator can run on LangChain.LangChainCurator— aCuratorbacked bylangchain.agents.create_agent. It formats conversation history (handling both LangChainBaseMessageobjects and OpenAI-style dicts) and drives skill-management tools, returning aChangelog.create_skill_tools— LangChain@toolwrappers aroundSkillRepo(list_skills,read_skill,insert_skill,update_skill,delete_skill) that record each mutation as an applied/failedChangein aChangelog.LangChainCurator.callback()— the LangChain equivalent of a Strands hook provider. Returns a_CuratorCallbackHandler(AsyncCallbackHandler) that hooks the agent lifecycle and curates the conversation when the root run completes (on_chain_endwith no parent run). Use it viaagent.ainvoke(..., config={"callbacks": [curator.callback()]}).Other changes
--import-mode=importlibso packages can share test-file basenames (e.g.test_tools.py).Testing
uv run pytest— 120 passed (35 new tests covering tools, curator, the callback handler, and an end-to-end test where a real user agent run triggers the callback and creates a skill).uv run ruff check,uv run ruff format --check, anduv run ty checkall pass.https://claude.ai/code/session_019cNC4hjVdpJKAJofeY6SBy
Generated by Claude Code