From d6856131b6f2d6432e267c634a09077127bf4f9e Mon Sep 17 00:00:00 2001 From: Lance Martin <122662504+rlancemartin@users.noreply.github.com> Date: Sun, 23 Mar 2025 17:59:14 -0700 Subject: [PATCH] Fix broken links in ntbks (#3993) A number of Anthropic links recently changed --- docs/docs/concepts/high_level.md | 2 +- docs/docs/concepts/memory.md | 2 +- .../langgraph_code_assistant.ipynb | 2 +- docs/docs/tutorials/workflows/index.md | 16 ++++++++-------- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/docs/docs/concepts/high_level.md b/docs/docs/concepts/high_level.md index d17912829..525926417 100644 --- a/docs/docs/concepts/high_level.md +++ b/docs/docs/concepts/high_level.md @@ -2,7 +2,7 @@ ## LLM applications -LLMs make it possible to embed intelligence into a new class of applications. There are many patterns for building applications that use LLMs. [Workflows](https://www.anthropic.com/research/building-effective-agents) have scaffolding of predefined code paths around LLM calls. LLMs can direct the control flow through these predefined code paths, which some consider to be an "[agentic system](https://www.anthropic.com/research/building-effective-agents)". In other cases, it's possible to remove this scaffolding, creating autonomous agents that can [plan](https://huyenchip.com/2025/01/07/agents.html), take actions via [tool calls](https://python.langchain.com/docs/concepts/tool_calling/), and directly respond [to the feedback from their own actions](https://research.google/blog/react-synergizing-reasoning-and-acting-in-language-models/) with further actions. +LLMs make it possible to embed intelligence into a new class of applications. There are many patterns for building applications that use LLMs. [Workflows](https://www.anthropic.com/engineering/building-effective-agents) have scaffolding of predefined code paths around LLM calls. LLMs can direct the control flow through these predefined code paths, which some consider to be an "[agentic system](https://www.anthropic.com/engineering/building-effective-agents)". In other cases, it's possible to remove this scaffolding, creating autonomous agents that can [plan](https://huyenchip.com/2025/01/07/agents.html), take actions via [tool calls](https://python.langchain.com/docs/concepts/tool_calling/), and directly respond [to the feedback from their own actions](https://research.google/blog/react-synergizing-reasoning-and-acting-in-language-models/) with further actions. ![Agent Workflow](img/agent_workflow.png) diff --git a/docs/docs/concepts/memory.md b/docs/docs/concepts/memory.md index cdcd8ae5b..341d51b76 100644 --- a/docs/docs/concepts/memory.md +++ b/docs/docs/concepts/memory.md @@ -275,7 +275,7 @@ See this how-to [video](https://www.youtube.com/watch?v=37VaU7e7t5o) for example [Procedural memory](https://en.wikipedia.org/wiki/Procedural_memory), in both humans and AI agents, involves remembering the rules used to perform tasks. In humans, procedural memory is like the internalized knowledge of how to perform tasks, such as riding a bike via basic motor skills and balance. Episodic memory, on the other hand, involves recalling specific experiences, such as the first time you successfully rode a bike without training wheels or a memorable bike ride through a scenic route. For AI agents, procedural memory is a combination of model weights, agent code, and agent's prompt that collectively determine the agent's functionality. -In practice, it is fairly uncommon for agents to modify their model weights or rewrite their code. However, it is more common for agents to [modify their own prompts](https://docs.anthropic.com/en/docs/build-with-claude/prompt-engineering/prompt-generator). +In practice, it is fairly uncommon for agents to modify their model weights or rewrite their code. However, it is more common for agents to modify their own prompts. One effective approach to refining an agent's instructions is through ["Reflection"](https://blog.langchain.dev/reflection-agents/) or meta-prompting. This involves prompting the agent with its current instructions (e.g., the system prompt) along with recent conversations or explicit user feedback. The agent then refines its own instructions based on this input. This method is particularly useful for tasks where instructions are challenging to specify upfront, as it allows the agent to learn and adapt from its interactions. diff --git a/docs/docs/tutorials/code_assistant/langgraph_code_assistant.ipynb b/docs/docs/tutorials/code_assistant/langgraph_code_assistant.ipynb index 2e774a9b7..fc747fb81 100644 --- a/docs/docs/tutorials/code_assistant/langgraph_code_assistant.ipynb +++ b/docs/docs/tutorials/code_assistant/langgraph_code_assistant.ipynb @@ -125,7 +125,7 @@ "\n", "### Code solution\n", "\n", - "First, we will try OpenAI and [Claude3](https://docs.anthropic.com/en/docs/about-claude/models) with function calling.\n", + "First, we will try OpenAI and [Claude3](https://docs.anthropic.com/en/docs/about-claude/models/all-models) with function calling.\n", "\n", "We will create a `code_gen_chain` w/ either OpenAI or Claude and test them here." ] diff --git a/docs/docs/tutorials/workflows/index.md b/docs/docs/tutorials/workflows/index.md index d3c61eee3..381666aed 100644 --- a/docs/docs/tutorials/workflows/index.md +++ b/docs/docs/tutorials/workflows/index.md @@ -1,6 +1,6 @@ # Workflows and Agents -This guide reviews common patterns for agentic systems. In describing these systems, it can be useful to make a distinction between "workflows" and "agents". One way to think about this difference is nicely explained [here](https://www.anthropic.com/research/building-effective-agents) by Anthropic: +This guide reviews common patterns for agentic systems. In describing these systems, it can be useful to make a distinction between "workflows" and "agents". One way to think about this difference is nicely explained [here](https://www.anthropic.com/engineering/building-effective-agents) by Anthropic: > Workflows are systems where LLMs and tools are orchestrated through predefined code paths. > Agents, on the other hand, are systems where LLMs dynamically direct their own processes and tool usage, maintaining control over how they accomplish tasks. @@ -9,7 +9,7 @@ Here is a simple way to visualize these differences: ![Agent Workflow](../../concepts/img/agent_workflow.png) -When building agents and workflows, LangGraph [offers a number of benefits](https://langchain-ai.github.io/langgraph/concepts/high_level/) including persistence, streaming, and support for debugging as well as deployment. +When building agents and workflows, LangGraph [offers a number of benefits](https://www.anthropic.com/engineering/building-effective-agents) including persistence, streaming, and support for debugging as well as deployment. ## Set up @@ -41,7 +41,7 @@ llm = ChatAnthropic(model="claude-3-5-sonnet-latest") ## Building Blocks: The Augmented LLM -LLM have [augmentations](https://www.anthropic.com/research/building-effective-agents) that support building workflows and agents. These include [structured outputs](https://python.langchain.com/docs/concepts/structured_outputs/) and [tool calling](https://python.langchain.com/docs/concepts/tool_calling/), as shown in this image from the Anthropic [blog](https://www.anthropic.com/research/building-effective-agents): +LLM have [augmentations](https://www.anthropic.com/engineering/building-effective-agents) that support building workflows and agents. These include [structured outputs](https://python.langchain.com/docs/concepts/structured_outputs/) and [tool calling](https://python.langchain.com/docs/concepts/tool_calling/), as shown in this image from the Anthropic [blog](https://www.anthropic.com/engineering/building-effective-agents): ![augmented_llm.png](./img/augmented_llm.png) @@ -81,7 +81,7 @@ msg.tool_calls In prompt chaining, each LLM call processes the output of the previous one. -As noted in the [Anthropic blog](https://www.anthropic.com/research/building-effective-agents): +As noted in the [Anthropic blog](https://www.anthropic.com/engineering/building-effective-agents): > Prompt chaining decomposes a task into a sequence of steps, where each LLM call processes the output of the previous one. You can add programmatic checks (see "gate” in the diagram below) on any intermediate steps to ensure that the process is still on track. @@ -392,7 +392,7 @@ With parallelization, LLMs work simultaneously on a task: ## Routing -Routing classifies an input and directs it to a followup task. As noted in the [Anthropic blog](https://www.anthropic.com/research/building-effective-agents): +Routing classifies an input and directs it to a followup task. As noted in the [Anthropic blog](https://www.anthropic.com/engineering/building-effective-agents): > Routing classifies an input and directs it to a specialized followup task. This workflow allows for separation of concerns, and building more specialized prompts. Without this workflow, optimizing for one kind of input can hurt performance on other inputs. @@ -603,7 +603,7 @@ Routing classifies an input and directs it to a followup task. As noted in the [ ## Orchestrator-Worker -With orchestrator-worker, an orchestrator breaks down a task and delegates each sub-task to workers. As noted in the [Anthropic blog](https://www.anthropic.com/research/building-effective-agents): +With orchestrator-worker, an orchestrator breaks down a task and delegates each sub-task to workers. As noted in the [Anthropic blog](https://www.anthropic.com/engineering/building-effective-agents): > In the orchestrator-workers workflow, a central LLM dynamically breaks down tasks, delegates them to worker LLMs, and synthesizes their results. @@ -948,7 +948,7 @@ In the evaluator-optimizer workflow, one LLM call generates a response while ano **Examples** - [Here](https://github.com/langchain-ai/research-rabbit) is an assistant that uses evaluator-optimizer to improve a report. See our video [here](https://www.youtube.com/watch?v=XGuTzHoqlj8). + [Here](https://github.com/langchain-ai/local-deep-researcher) is an assistant that uses evaluator-optimizer to improve a report. See our video [here](https://www.youtube.com/watch?v=XGuTzHoqlj8). [Here](https://langchain-ai.github.io/langgraph/tutorials/rag/langgraph_adaptive_rag_local/) is a RAG workflow that grades answers for hallucinations or errors. See our video [here](https://www.youtube.com/watch?v=bq1Plo2RhYI). @@ -1012,7 +1012,7 @@ In the evaluator-optimizer workflow, one LLM call generates a response while ano ## Agent -Agents are typically implemented as an LLM performing actions (via tool-calling) based on environmental feedback in a loop. As noted in the [Anthropic blog](https://www.anthropic.com/research/building-effective-agents): +Agents are typically implemented as an LLM performing actions (via tool-calling) based on environmental feedback in a loop. As noted in the [Anthropic blog](https://www.anthropic.com/engineering/building-effective-agents): > Agents can handle sophisticated tasks, but their implementation is often straightforward. They are typically just LLMs using tools based on environmental feedback in a loop. It is therefore crucial to design toolsets and their documentation clearly and thoughtfully.