HomeCoding & DevelopmentAgents-Flex

Agents-Flex Product Information

Agents-Flex

Agents-Flex is a Java framework for building and deploying large language model (LLM) applications. It aims to be lightweight, simple, and elegant, providing a cohesive set of components to dock, orchestrate, and extend LLM capabilities across various models and data sources.


Overview

  • Supports common large language models on the market.
  • Compatible with the Ollama deployment model.
  • Built-in rich network protocols (HTTP, SSE, WS) for docking diverse models.
  • Designed for easy integration and extension by developers.

Core Capabilities

Model Docking and Protocols

  • Flexible model docking across multiple LLM providers.
  • Networking support via HTTP, Server-Sent Events (SSE), and WebSockets (WS) to communicate with models and services.

Prompt Framework and Templates

  • Provides a wealth of LLM development templates.
  • Supports a variety of Prompt Frameworks such as FEW-SHOT, CRISPE, BROKE, ICIO, etc.
  • Customizable Prompt Templates to fit unique content and workflows.

Function Calling

  • Advanced Function Calling component with support for:
  • Local method definitions
  • Parsing and callbacks through LLMs
  • Executing local methods to obtain results

Document Processing

  • Document loading, parsing, and splitting through dedicated components.
  • Multiple implementations to load data from the web, local files, databases, and various data types.

Memory and Context

  • Memory module split into MessageMemory (chat messages) and ContextMemory (chain execution contexts).
  • Extendable via inheritance to enable richer functionality.

Embeddings and Vector Stores

  • Extensive embedding capabilities with extensible architecture.
  • Developers can implement their own Embedding interface to integrate private embedding algorithms.
  • Supports multiple vector databases and allows custom VectorStore implementations.

Chains and Orchestration

  • Chain components support Sequential Chains, Asynchronous Chains, and Loop Chains.
  • Facilitates handling of complex workflows and multi-step reasoning in LLM applications.

Licensing

  • Released under the Apache License.
  • Copyright © 2022–present Agents-Flex.

How to Use (High-Level)

  1. Choose and dock a desired LLM model using the built-in docking capabilities (HTTP/SSE/WS).
  2. Define prompts using the available Prompt Templates or create custom templates.
  3. Implement or hook functions via the Function Calling component for local operations.
  4. Load and preprocess documents if needed, then embed and store vectors in a Vector Store.
  5. Build an execution Chain (Sequential, Async, or Loop) to orchestrate tasks and model invocations.
  6. Use Memory modules to manage dialogue state and execution contexts.

Core Features

  • Lightweight, simple, and elegant Java framework for LLM applications
  • Flexible model docking with HTTP, SSE, and WebSocket protocols
  • Rich Prompt Framework support (FEW-SHOT, CRISPE, BROKE, ICIO, etc.) with customizable templates
  • Advanced Function Calling with local method execution and LLM callbacks
  • Comprehensive Document Loader, Parser, and Splitter components for diverse data sources
  • Distinct Memory modules: MessageMemory and ContextMemory, with extensibility
  • Extensible Embedding and Vector Store integration for private embeddings and databases
  • Chain components: Sequential, Asynchronous, and Loop Chains for complex workflows
  • Apache License with ongoing development and support