用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/tomevault-io/skills-registry --skill langchain-agents命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | langchain-agents |
| description | > Use when this capability is needed. |
create_react_agent to create_agentinit_chat_model(), and provider-specific clientscreate_agentcreate_agent for all new agent work.create_react_agent as legacy.ToolNode.init_chat_model() when you need runtime controls like temperature or timeout.ChatOpenAI when you need provider-specific parameters.system_prompt for instructionsSystemMessage only when you need advanced provider features such as prompt caching.prompt parameter.response_format for structured outputToolStrategy(Schema) when tool-calling behavior is required.ProviderStrategy(Schema) when the provider supports native structured output.result["structured_response"].from langchain.agents import create_agent
from langchain.tools import tool
@tool
def search(query: str) -> str:
"""Search the web for information."""
return f"Results for: {query}"
agent = create_agent(
model="gpt-4.1-mini",
tools=[search],
system_prompt="You are a helpful assistant."
)
from langchain.chat_models import init_chat_model
from langchain.agents import create_agent
model = init_chat_model(
model="gpt-4.1",
temperature=0.1,
max_tokens=1000
)
agent = create_agent(
model=model,
tools=[],
system_prompt="You are a helpful assistant."
)
from langchain.agents import create_agent
from pydantic import BaseModel
class ContactInfo(BaseModel):
name: str
email: str
agent = create_agent(
model="gpt-4.1-mini",
tools=[],
response_format=ContactInfo,
system_prompt="Extract contact information."
)
result = agent.invoke({"messages": [{"role": "user", "content": "..."}]})
result["structured_response"] # ContactInfo instance
uv add langchain
Source: ColRuDev/job-candidate-matcher — distributed by TomeVault.