Skip to content

About

Small example using python, langchain and Anthropic tool use

Resources

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

 

History

2 Commits

Folders and files

Repository files navigation

python-langchain-anthropic-tool-use-example

This is a demonstration on how to use the Anthropic tool or function call API with Python and Langchain.

There is a very simple, user prompt and feedback loop to interact with Claude.

The single configured tool is just a mock implementation that returns a fixed string per location.

See also

I have a Typescript example using the Anthropic SDK here: typescript-anthropic-tool-use-example

Installation

pip install -r requirements.txt
cp .env.example .env

Then add your API keys to the .env file.

Usage

python main.py

About

Small example using python, langchain and Anthropic tool use

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages