https://github.com/gurobokum/liman
Declarative YAML-based AgentOps framework for building composable AI agents
https://github.com/gurobokum/liman
ai-agents ai-agents-framework ai-application-development framework
Last synced: 2 months ago
JSON representation
Declarative YAML-based AgentOps framework for building composable AI agents
- Host: GitHub
- URL: https://github.com/gurobokum/liman
- Owner: gurobokum
- Created: 2025-06-17T11:04:13.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2025-10-05T12:33:27.000Z (6 months ago)
- Last Synced: 2025-11-27T18:34:34.154Z (4 months ago)
- Topics: ai-agents, ai-agents-framework, ai-application-development, framework
- Language: Python
- Homepage: https://liman-ai.dev
- Size: 5.07 MB
- Stars: 11
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# Liman
Code-first declarative framework for building composable AI agents using YAML manifests
> ⚠️ **Warning:** This project is in early development phase.
## Features
- **Declarative YAML Configuration**: Define agents using simple YAML manifests
- **Node-based Architecture**: Compose workflows from LLM, Tool, and custom nodes
- **Edge DSL**: Connect nodes with conditional expressions and function references
- **OpenAPI Integration**: Auto-generate tools from OpenAPI specifications
- **Multi-language Support**: Built-in localization for prompts and descriptions
- **Built-in Observability**: OpenTelemetry support with FinOps tracking
- **Multi-runtime**: Python implementation (TS, Go planned)
## Quick Start (python)
```bash
pip install liman
```
Create agent specifications in YAML:
```yaml
# agents/assistant.yaml
kind: LLMNode
name: assistant
description: A conversational AI assistant
prompts:
system: You are a helpful assistant that can check weather.
tools:
- get_weather
```
```yaml
# agents/get_weather_tool.yaml
kind: ToolNode
name: get_weather
description:
en: Get current weather information for a city
func: weather.get_current_weather
arguments:
- name: city
type: str
description:
en: Name of the city to get weather for
```
Create a Python function for the tool:
```python
# weather.py
def get_current_weather(city: str) -> str:
"""Get weather information for a city."""
# Your weather API logic here
return f"The weather in {city} is sunny, 22°C"
```
Run the agent:
```python
# main.py
from langchain_openai.chat_models import ChatOpenAI
from liman import Agent
llm = ChatOpenAI(model="gpt-4o")
agent = Agent(
"./agents", # directory with YAML specs
start_node="assistant",
llm=llm
)
response = agent.step("What's the weather like in London?")
print(response)
```
## Architecture
Liman represents AI agents as graphs of interconnected nodes, similar to Kubernetes manifests with Kustomize-style overlays:
- **LLMNode**: Wraps LLM requests with system prompts and tool integration
- **ToolNode**: Defines function calls for LLM tool integration
- **FunctionNode**: Custom logic nodes for complex workflows
- **Edges**: Connect nodes with conditional execution using custom DSL
## Edge DSL
Liman includes a custom Domain Specific Language (DSL) that defines the logic of executing agents through conditional expressions in node edges. The DSL supports:
### Examples
```yaml
nodes:
# Simple condition
- target: success_handler
when: status == 'complete'
# Complex logical expression
- target: retry_handler
when: (status == 'failed' && retry_count < 3) || priority == 'high'
# Function reference
- target: custom_handler
when: utils.should_process
```
The DSL expressions are parsed at runtime and evaluated against the current execution context.
## Python
### Packages
- [**liman**](python/packages/liman): Main package with executor and agent functionality, should be used as an entry point [](https://codecov.io/gh/gurobokum/liman?components[0]=python/liman)
- [**liman_core**](python/packages/liman_core): Core library with node types and YAML processing [](https://codecov.io/gh/gurobokum/liman?components[0]=python/liman_core)
- [**liman_finops**](python/packages/liman_finops): OpenTelemetry instrumentation and cost tracking.
- [**liman_openapi**](python/packages/liman_openapi): OpenAPI to ToolNode generation [](https://codecov.io/gh/gurobokum/liman?components[0]=python/liman_openapi)
## Resources
- [📖 Documentation](https://liman-ai.vercel.app/docs/poc)
- [🔧 Specification](https://liman-ai.vercel.app/docs/specification/node)
[](https://liman-ai.vercel.app/docs/poc)
[](https://discord.gg/rmucxEzSyY) [](https://x.com/liman_ai)