Skip to main content

Base package for myscalekb agent

Project description

MySaleKB Agent Plugin 使用指南

本使用指南重点介绍如何基于 MyScaleKB Agent Docker 运行环境载入 Plugin 代码。

如何载入 Plugin

MyScaleKB Agent Plugin(SubAgent) 代码的运行依赖于 MyScaleKB Agent Docker 环境。阅读 MyScale KB Agent 平台部署指南 以了解如何在本地部署完整的 MyScaleKB Agent 服务。

在此基础上,Plugin 代码使用 Docker Mount 的方式进行载入。

# 假设目录结构如下
# -- workspace
# ---- myscalekb-agent-plugin
# ---- myscalekb-deployment
cd workspace
git clone https://github.com/myscale/myscalekb-agent-plugin.git

# 以 myscalekb-deployment 为根目录操作 docker-compose
cd myscalekb-deployment

# 使用下面的命令 restart agent service (以 cpu yaml 为例)
docker-compose -f docker-compose-linux-cpu.yaml -v ../myscalekb-agent-plugin/myscalekb_agent_plugin:/app/myscalekb_agent_plugin up -d agent

查看日志

使用下面的命令来验证 Plugin SubAgent 是否正确载入:

docker-compose -f docker-compose-linux-cpu.yaml logs agent --since 10m | grep "PaperRecommendationAgent"

使用下面的命令来查看 Agent Workflow 的执行情况:

docker-compose -f docker-compose-linux-cpu.yaml logs agent --since 10m | grep "QueryTrace"

也可以通过 TraceId 来定位具体的一次请求执行情况,假设 TraceId 为 5dd78e08ae994ef898704052b84447b7a373

docker-compose -f docker-compose-linux-cpu.yaml logs agent --since 10m | grep -F "QueryTrace[5dd78e08ae994ef898704052b84447b7a373]"

如何开发 Plugin

MyScaleKB Agent Plugin 的介绍及开发流程请阅读 MyScaleKB Agent 二次开发用户指南

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

myscalekb_agent_base-0.0.1.tar.gz (13.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

myscalekb_agent_base-0.0.1-py3-none-any.whl (17.0 kB view details)

Uploaded Python 3

File details

Details for the file myscalekb_agent_base-0.0.1.tar.gz.

File metadata

  • Download URL: myscalekb_agent_base-0.0.1.tar.gz
  • Upload date:
  • Size: 13.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.1

File hashes

Hashes for myscalekb_agent_base-0.0.1.tar.gz
Algorithm Hash digest
SHA256 24da3823a6ae66712f027807b6d67918cd441d7da34c917def11e806a61e834b
MD5 d490023941c83776ae080078ce605e9a
BLAKE2b-256 4169368bc98cf2cb6732d48ca154b5aaad912a933085f9686d059dd478508737

See more details on using hashes here.

File details

Details for the file myscalekb_agent_base-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for myscalekb_agent_base-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5561d96eca55086ce487474006960b0cb7d9b046e563e755007fff44ec85b5be
MD5 9b384a23f8afe886c414a9b2969e64fa
BLAKE2b-256 f695e317bc601124486c37f01e33e4041147b4c1c0233d67307f4275294aaa98

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page