Skip to content

yugoccp/hello-langchain4j

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hello Langchain4J

Sample project to start using the power of Langchain for Java!

Specially created for The Developer's Conference 2023 Future edition.

Requirements

  • Java 17
  • Maven 3
  • OpenAI account

Usage

  1. Create a copy of .env.example and rename to .env
  2. Fill the .env file with the OpenAI API token and organization ID
  3. Export .env file to make env vars available:
export $(cat .env | xargs)
  1. Build the application from the source code:
./mvnw clean package
  1. Use the following commands to run each example:
./mvnw exec:java -D'exec.mainClass=_00_Model'

./mvnw exec:java -D'exec.mainClass=_01_Prompt'

./mvnw exec:java -D'exec.mainClass=_02_Memory'

./mvnw exec:java -D'exec.mainClass=_03_Retrieval'

./mvnw exec:java -D'exec.mainClass=_04_Agents'

References

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages