Logo kdeps

kdeps

Tổ chức
kdeps

AI Appliance Builder - YAML-defined AI agents and workflow pipelines. Ship as Docker, K8s, ISO, or a single binary.

Nhà phát hànhkdeps
Kho mãkdeps
Ngôn ngữGo
Bản fork
5
Sao
37
Công cụ có sẵn
0
Phương thức truyền tảistdio
Danh mục
Giấy phépApache-2.0
Liên kết
  • Kết nối công cụ với quy trình làm việc AI

    kdeps cung cấp các khả năng MCP mà ứng dụng khách và tác nhân AI tương thích có thể sử dụng.

  • 0 công cụ có sẵn

    Xem các thao tác có thể gọi bên dưới, kèm tên và mô tả nếu máy chủ cung cấp.

  • Cấu hình sẵn để sao chép

    Dùng các đoạn cấu hình cài đặt mẫu để thiết lập máy chủ này trong ứng dụng khách MCP bạn muốn dùng.

  • Chỉ số quan tâm đến mã nguồn mở

    37 sao và 5 bản fork từ kho mã được liên kết.

kdeps

Build and Test Coverage Release Go License CodeQL Docs Documentation Registry GitHub stars

Before moving on, please consider giving us a GitHub star ⭐️. Thank you!

Git-native AI Appliance Builder - your agent is YAML in your repo; ship the workflow, tools, and model as one self-contained deployment that runs anywhere.

kdeps packages an AI workload - agent or deterministic API, not a chatbot - into a unit you can run as a terminal REPL, an HTTP API, a Docker image, Kubernetes manifests, a bootable ISO, or a single binary. The definition is text you commit: reviewed as a pull request, versioned by git tag, built reproducibly from a commit in CI. Change the YAML, and the appliance behaves differently - your git history is the changelog of the agent's behavior. One YAML file replaces a Python script wiring together an LLM SDK, a web server, retry logic, and a Dockerfile. It runs open-source, self-hosted models by default, so the built appliance has no per-token cost and no dependency on an external AI service - it works the same on a laptop and inside an air-gapped network. kdeps is a small number of bounded pieces - pick the one you need:

  • kdeps agent - run kdeps and you are in an autonomous AI REPL: tool use, memory, fully offline against a local model. No config, no API key.
  • kdeps workflow - define what the agent does in one workflow.yaml and run it as an HTTP API, a bot, or a file processor. Same file, laptop or server.
  • kdeps agencies - coordinate several specialized agents as one system, delegating work through the agent: resource.
  • kdeps LLM server - provision a standalone OpenAI-compatible inference appliance, no workflow path required.
  • kdeps deploy - ship a workflow unchanged as a Docker image, Kubernetes manifests, a bootable ISO, or a single binary.
  • kdeps registry (optional) - find, install, and publish shared agents and components by name. Not needed to build or run your own.

Quickstart

yaml
# workflow.yaml - a two-resource chat API. No LLM server needed: the default
# model (llama3.2:1b) runs as a local llamafile, downloaded on first run.
apiVersion: kdeps.io/v1
kind: Workflow
metadata:
  name: my-agent
  version: "1.0.0"
  targetActionId: response   # the resource whose output is the HTTP response
settings:
  apiServer:
    portNum: 16395
    routes:
      - path: /api/v1/chat
        methods: [POST]
resources:
  - actionId: llm
    name: LLM Chat
    validations:
      methods: [POST]
      routes: [/api/v1/chat]
      check:
        - get('q') != ''      # 'q' comes from the JSON body
      error:
        code: 400
        message: "'q' is required"
    chat:
      model: llama3.2:1b      # a name, "router"/"auto-router", or "system" (follow ~/.kdeps/config.yaml)
      role: user
      prompt: "{{ get('q') }}"
      timeout: 60s
  - actionId: response
    name: API Response
    requires: [llm]            # runs after 'llm' - the DAG resolves order
    apiResponse:
      success: true
      response:
        answer: get('llm').message.content
bash
# KDEPS_API_AUTH_TOKEN is the HTTP endpoint's bearer token - not an LLM key
export KDEPS_API_AUTH_TOKEN=dev-token
kdeps run workflow.yaml

curl -s -X POST localhost:16395/api/v1/chat \
  -H "Authorization: Bearer $KDEPS_API_AUTH_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"q": "What is entropy, in one sentence?"}'
# {"success": true, "data": {"answer": "Entropy is a measure of disorder..."}}

More examples: kdeps.com/examples (25 walkthroughs, each a working project).

Install

bash
curl -LsSf https://raw.githubusercontent.com/kdeps/kdeps/main/install.sh | sh

Windows (PowerShell):

powershell
irm https://raw.githubusercontent.com/kdeps/kdeps/main/install.ps1 | iex

Or with Homebrew (macOS and Linux):

bash
brew install kdeps/tap/kdeps

How it works

Whichever piece you use, a workflow runs in one of two execution modes - and an agency bundles several workflows into one system.

Workflow mode

DAG-deterministic request/response pipelines. Each resource declares its dependencies via requires: and runs in order, ending in an apiResponse.

The LLM call inside a chat: resource is still probabilistic, but the pipeline around it is not: the same request takes the same path, validation runs before any model call, and the response is shaped to a fixed schema.

Resources cover LLM chat, HTTP, Python, shell, SQL, email, web scraping, browser automation, embeddings, local and web search, and calls to other agents or components. Expressions (get(), output(), set(), plus Jinja2 control flow) wire the steps together.

bash
kdeps run workflow.yaml          # local, instant startup
kdeps run ./my-agent/            # or point at a directory containing workflow.yaml
kdeps run workflow.yaml --dev    # hot reload

Agent loop mode

An autonomous LLM loop. Every workflow becomes a callable tool, and the LLM decides which to call, in what order, to complete the task. Runs as an interactive REPL until you exit (Ctrl+D). Each prompt is rewritten for clarity before the turn (/refine off to disable). Sessions and memory are kept per working directory under ~/.kdeps/; kdeps in a folder with history offers a resume picker.

bash
kdeps                            # bare agent loop REPL (resume picker if this folder has history)
kdeps --new                      # start a clean session, skip the picker
kdeps ./my-agent/ --model llama3.2 --system "You are a DevOps assistant."
kdeps --theme black              # flat legible dark-gray disguise theme (model name abbreviated); also linux, vim, emacs

Agencies

A collection of agents that work together. Each agent is its own workflow.yaml with its own resources, model, and logic, wired together with the agent: resource type - like calling a function, but the function is an entire AI pipeline.

bash
kdeps run agency.yaml

Docs: Workflow mode · Agent loop mode · Agencies · Resources overview

Build and deploy

The workflow you run locally exports unchanged to any target:

bash
kdeps bundle build .        # Docker image
kdeps export iso            # bootable edge ISO
kdeps bundle prepackage     # self-contained binary per arch
kdeps export k8s            # Kubernetes manifests

For a public HTTPS endpoint, add static PEM files or automatic Let's Encrypt to workflow.yaml, point DNS at the host, and open ports 80 and 443:

yaml
settings:
  letsEncrypt:
    domain: api.example.com
    email: ops@example.com
  apiServer:
    hostIp: "0.0.0.0"
    portNum: 443

Docs: Deployment guide · TLS and HTTPS

Reference

  • Registry - kdeps registry search|install|submit for pre-built components. kdeps.io
  • Agent skill - npx skills add https://github.com/kdeps/skill --skill kdeps teaches Claude Code, Cursor, and other agents to scaffold kdeps projects. Docs
  • LLM server appliance - kdeps llm wizard builds a standalone OpenAI-compatible inference server (ollama, llamafile, gguf, vllm, tgi, sglang, and more), no workflow path required. Docs · Commands
  • Global config - machine-local settings (LLM backend, API keys, SQL/SMTP/IMAP connections) live in ~/.kdeps/config.yaml, never in workflow.yaml. kdeps edit to open it, kdeps doctor to check it. Docs
  • Security - when apiServer is set, requests require a bearer token (KDEPS_API_AUTH_TOKEN) and pass through rate-limit, body-size, and concurrency caps before reaching the DAG. Docs
  • Logging - structured JSON via log/slog. KDEPS_LOG_FORMAT=json for production; default level WARN; --verbose (INFO), --debug (DEBUG).
  • Innovation technology - two standalone Go tools built alongside kdeps: kdeps/kartographer (graph library for resolving dependent nodes - powers the requires: DAG and folder/skill graphs) and kdeps/turo (reduces prose to content words to cut LLM input tokens - the optional agent-mode prompt reducer).
  • Book - AI Appliances - Build & Deploy Autonomous AI Agents and Agencies in YAML. Free (PDF, EPUB, web).

Documentation | Registry | Apache 2.0

Cài đặt

TypingMind
{
  "mcpServers": {
    "kdeps": {
      "command": "kdeps",
      "args": [
        "mcp"
      ]
    }
  }
}

Dùng MCP kdeps với nhiều mô hình AI

TypingMind kết nối các công cụ MCP ở cấp không gian làm việc, nên sau khi kết nối kdeps, bạn có thể dùng với nhiều mô hình AI khác nhau trong TypingMind thay vì phải thiết lập riêng cho từng mô hình. MCP này chạy cục bộ thông qua trình kết nối MCP của TypingMind trên thiết bị của bạn.

Hướng dẫn thiết lập để dùng trình kết nối cục bộ

Dùng cách này khi máy chủ MCP cần truy cập các tệp, ứng dụng hoặc tài nguyên riêng tư trên máy tính của bạn.

1

Mở cài đặt MCP

Trong TypingMind, vào Cài đặt, Cài đặt nâng cao, rồi đến Giao thức ngữ cảnh mô hình và chọn Cài trình kết nối.

  1. Mở TypingMind trong trình duyệt của bạn.
  2. Nhấp vào biểu tượng Cài đặt.
  3. Vào Cài đặt nâng cao.
  4. Mở mục Giao thức ngữ cảnh mô hình.
  5. Nhấp vào Cài trình kết nối rồi chọn Thiết bị này.
Màn hình thiết lập trình kết nối MCP của TypingMind với tùy chọn Thiết bị này được chọn
2

Chạy lệnh trình kết nối

Chọn Thiết bị này, sao chép lệnh từ TypingMind và chạy trong Terminal. Giữ tiến trình chạy trong khi bạn dùng MCP.

  1. Sao chép lệnh thiết lập hiển thị trong TypingMind.
  2. Mở Terminal trên macOS hoặc Windows Terminal trên Windows.
  3. Dán và chạy lệnh.
  4. Xác nhận cài đặt gói nếu Terminal hỏi bạn có muốn tiếp tục không.
  5. Giữ tiến trình trong cửa sổ Terminal chạy trong khi dùng các công cụ MCP.
3

Thêm kdeps làm máy chủ

Khi trạng thái trình kết nối là Sẵn sàng, nhấp vào Sửa máy chủ và dán cấu hình máy chủ MCP.

  1. Đợi đến khi trạng thái trình kết nối hiển thị Sẵn sàng.
  2. Nhấp vào Sửa máy chủ.
  3. Dán cấu hình máy chủ MCP của kdeps.
  4. Lưu danh sách máy chủ.
  5. Làm mới nếu bạn muốn xác nhận trình kết nối vẫn sẵn sàng.
Cài đặt MCP của TypingMind hiển thị máy chủ đang hoạt động và nút Sửa máy chủ
{
  "mcpServers": {
    "kdeps": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

Dùng kết nối với nhiều mô hình

Lưu danh sách máy chủ, mở Plugin, bật các công cụ MCP của kdeps, sau đó chọn bất kỳ mô hình AI nào được hỗ trợ trong TypingMind và dùng các công cụ trong cuộc trò chuyện hoặc gán chúng cho một tác nhân AI.

  1. Mở trang Plugin trong TypingMind.
  2. Bật các công cụ MCP của kdeps.
  3. Bắt đầu cuộc trò chuyện và chọn mô hình AI bạn muốn dùng.
  4. Dùng các công cụ MCP trong cuộc trò chuyện hoặc gán chúng cho một tác nhân AI.
  5. Chuyển sang mô hình AI khác bất cứ khi nào cần mà không phải kết nối lại MCP.
Cuộc trò chuyện TypingMind dùng các công cụ MCP đã bật với một mô hình AI được chọn
Bạn có thể dùng kdeps giúp tôi làm việc này không?
kdeps
Được. Tôi đã đọc.
Đây là kết quả tôi tìm được bằng kdeps.

Câu hỏi thường gặp

Máy chủ MCP kdeps dùng để làm gì?

kdeps là máy chủ MCP cho phép các ứng dụng AI tương thích kết nối với công cụ và ngữ cảnh bên ngoài. Trong TypingMind, bạn chỉ cần thêm máy chủ MCP này một lần để các công cụ của nó có sẵn trong không gian làm việc AI của bạn.

Bạn có thể dùng MCP kdeps với nhiều mô hình AI trong TypingMind không?

Có. TypingMind kết nối các công cụ MCP ở cấp không gian làm việc, nên bạn có thể dùng kdeps với nhiều mô hình AI như Claude, ChatGPT, Gemini hoặc các mô hình khác đã cấu hình trong TypingMind mà không cần thiết lập máy chủ MCP riêng cho từng mô hình.

Vì sao nên dùng MCP kdeps với TypingMind?

TypingMind là một trong những giao diện trò chuyện với LLM tốt nhất vì tập hợp nhiều mô hình AI, prompt, plugin, tác nhân AI, khóa API và công cụ MCP vào một không gian làm việc. Khi kết nối kdeps, bạn có thể dùng các công cụ MCP của dịch vụ này với những mô hình ưa thích, đồng thời giữ quy trình trò chuyện gọn gàng trong TypingMind.

Làm cách nào để kết nối MCP kdeps với TypingMind?

kdeps hoạt động thông qua trình kết nối MCP cục bộ của TypingMind. Đây là lựa chọn phù hợp nhất khi máy chủ MCP cần truy cập tệp cục bộ, ứng dụng máy tính, công cụ dòng lệnh hoặc tài nguyên riêng trên máy tính của bạn.

MCP kdeps cung cấp những công cụ nào trong TypingMind?

kdeps cung cấp các chức năng MCP mà bạn có thể bật từ trang Plugin của TypingMind để dùng trong trò chuyện hoặc gán cho tác nhân AI.

Bạn có cần chia sẻ khóa API với TypingMind để dùng MCP kdeps không?

Không. TypingMind ưu tiên xử lý cục bộ và cho phép bạn kiểm soát nhà cung cấp mô hình, khóa API, prompt và cấu hình MCP. Nếu kdeps yêu cầu xác thực, hãy thêm các header, cài đặt OAuth hoặc cấu hình cục bộ cần thiết cho máy chủ MCP đó khi tạo kết nối.

Máy chủ MCP liên quan

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇