Skip to content

wdhitchc/langgraph-AIOT

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FUNCTIONAL BUT IN PROGRESs

  • TODO ITEMS:
  • Add more tests
  • fix configuration (specifically max iterations)
  • Fix Prompting issues
  • Refactor state for more efficient prompt history calculation

IoT Langgraph Implementation

This project was build using the template: https://github.com/langchain-ai/new-langgraph-project

CI Integration Tests Open in - LangGraph Studio

Graph view in LangGraph studio UI

The core logic is defined in src/agent/graph.py AIOT

What it does

This is a basic langgraph implementation of https://arxiv.org/abs/2409.12618. With Several modications.

I have not validated it performs as well as the official implementation here https://github.com/AgnostiqHQ/multi-agent-llm

I have added several modifications to the original implementation:

  • Final Answer Synthesis

Getting Started

Assuming you have already installed LangGraph Studio, to set up:

  1. Create a .env file.
cp .env.example .env
  1. Define required API keys in your .env file.
  1. Customize the code as needed.
  2. Open the folder in LangGraph Studio!

How to customize

  1. Modify the system prompt: The default system prompt is defined in configuration.py. You can easily update this via configuration in the studio to change the chatbot's personality or behavior.
  2. Select a different model: We default to Anthropic's Claude 3 Sonnet. You can select a compatible chat model using provider/model-name via configuration. Example: openai/gpt-4-turbo-preview.
  3. Extend the graph: The core logic of the chatbot is defined in graph.py. You can modify this file to add new nodes, edges, or change the flow of the conversation.

You can also quickly extend this template by:

  • Adding custom tools or functions to enhance the chatbot's capabilities.
  • Implementing additional logic for handling specific types of user queries or tasks.
  • Integrating external APIs or databases to provide more dynamic responses.

Development

While iterating on your graph, you can edit past state and rerun your app from previous states to debug specific nodes. Local changes will be automatically applied via hot reload. Try experimenting with:

  • Modifying the system prompt to give your chatbot a unique personality.
  • Adding new nodes to the graph for more complex conversation flows.
  • Implementing conditional logic to handle different types of user inputs.

Follow-up requests will be appended to the same thread. You can create an entirely new thread, clearing previous history, using the + button in the top right.

For more advanced features and examples, refer to the LangGraph documentation. These resources can help you adapt this template for your specific use case and build more sophisticated conversational agents.

LangGraph Studio also integrates with LangSmith for more in-depth tracing and collaboration with teammates, allowing you to analyze and optimize your chatbot's performance.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages