# agentkit [Health: Active]

**Category:** 💻 Developer Tools  
**Repository:** https://github.com/Yacine-ai-tech/AgentKit  
**GitHub Stars:** 0  
**Views:** 0  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/agentkit

## Description
Governed MCP server: YAML-declared tools, typed effects, policy-gated and audited calls.

## Tools
Capabilities this server exposes over MCP:

- **query_kpis** — Retrieve historical and real-time Key Performance Indicators (KPIs) from the governed Postgres store.

Fetches structured time-series metrics across enterprise business domains including Finance,
People (HR), Operations, Customer (Sales/Support), Engineering, Growth, Logistics, ESG, IT,
and Security.
- **get_company_health** — Compute composite organizational health scores and diagnostic health index breakdown.

Synthesizes multi-factor business performance indicators into a holistic 0-100 health score
with categorized qualitative interpretations ('Optimal', 'Healthy', 'Warning', 'Critical')
and sub-component scores across growth rate, profit margins, cash runway, and operational efficiency.
- **detect_kpi_anomalies** — Detect statistical anomalies, sudden spikes, and unexpected deviations in KPI time-series history.

Analyzes metric historical distributions within a specified business domain using rigorous
parametric (Z-Score) or non-parametric (IQR - Interquartile Range) anomaly detection algorithms
to identify operational risks, unexpected budget variances, or sudden performance degradation.
- **forecast_metric** — Generate forward-looking time-series forecasts with Monte Carlo confidence intervals for a named KPI.

Applies trend analysis and linear projection mathematical modeling over historical monthly metric data
to predict future trajectory across specified forward horizon periods, providing upper and lower
bound confidence intervals.
- **list_available_metrics** — Discover all supported KPI metrics, business domains, and available historical time periods.

Essential discovery tool for agents to inspect the metadata schema before formulating specific
queries, anomaly detections, or predictive forecasts.
- **get_executive_summary** — Generate a comprehensive one-shot executive briefing synthesizing health, key metrics, and anomalies.

Executes a high-level cross-domain synthesis combining composite organizational health diagnostics,
primary KPI indicators, and active statistical anomalies across Finance, Operations, and Growth into
an actionable briefing for leadership.

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `uvx` (confidence: high):

```json
"mcpServers": {
  "agentkit": {
    "command": "uvx",
    "args": ["agentkit-mcp"],
    "env": {
      "POSTGRES_URL": ""
    }
  }
}
```

**Requires environment variables:** `POSTGRES_URL` — the values above are empty placeholders; fill in real credentials before running (see the repository for what each one is for).

## Documentation

## What agentkit does

agentkit provides an MCP interface for business KPI analysis and governed tool execution. Its bundled reference pack covers Finance, People, Operations, Customer, Engineering, Growth, Logistics, ESG, IT, and Security data. Agents can inspect available metrics, retrieve historical or real-time time-series values, calculate an organizational health score, identify statistical deviations, forecast a named metric, or request a cross-domain executive briefing.

The six core tools are `query_kpis`, `get_company_health`, `detect_kpi_anomalies`, `forecast_metric`, `list_available_metrics`, and `get_executive_summary`. The server can also load additional tools from YAML packs. The bundled annotations pack demonstrates durable metric notes and soft deletion through guarded write and destructive operations.

## How it works

Tool definitions can be declared in YAML rather than implemented in Python, allowing teams to describe operations over their own Postgres or HTTP APIs. Each operation declares an effect: `read`, `write`, or `destructive`. Policy controls are applied independently of the model’s prompt: writes are disabled by default, destructive actions require a human-held approval token, and mutating operations support dry runs.

Every call is recorded in the audit trail, including denied calls and their reasons. The policy view publishes the active capability envelope. The server also registers KPI resources for the seeded domains and a `monthly_executive_briefing` prompt. A REST facade exposes the same tools, policy, audit, and routing views for dashboard or ordinary HTTP callers.

Forecasting uses trend analysis and linear projection over historical monthly data, with Monte Carlo confidence intervals. Anomaly detection supports Z-score and IQR methods. Company health combines indicators such as growth, margins, cash runway, and operational efficiency into a 0–100 score with qualitative categories.

## Setup and configuration

Install the PyPI package with `pip install agentkit-mcp`, then start it with `agentkit-mcp`. The package can also be launched for an MCP client through `uvx agentkit-mcp`. For a source checkout, create a virtual environment, install `requirements.txt`, configure `.env`, and run `python mcp_server.py`.

Claude Desktop configurations must set `MCP_TRANSPORT=stdio` so the server communicates over the spawned process pipes. Without that setting, the script defaults to SSE on a network port. `POSTGRES_URL` points the server at the governed Postgres store. `MCP_AUTH_TOKEN` applies to the SSE or network path; local stdio uses the operating-system process boundary instead.

Set `AGENTKIT_ALLOW_WRITES=true` only when write operations are intended. Destructive annotation retraction additionally requires `AGENTKIT_APPROVAL_TOKEN`. `LOG_LEVEL=DEBUG` enables verbose diagnostics. Anonymous startup telemetry can be disabled with `TELEMETRY_OPT_OUT=true` or `DO_NOT_TRACK=1`, and `TELEMETRY_URL` can redirect it to another collector.

The optional LangGraph workflow and example integrations use LiteLLM model routing. `LLM_REASONING`, `LLM_DEFAULT`, `LLM_JUDGE`, and `LLM_LOCAL` select model routes, while `INFERENCE_MODE=local` enables a local or self-hosted route such as Ollama.

## Tools and capabilities

- `list_available_metrics` exposes supported domains, metrics, and historical periods for discovery.
- `query_kpis` retrieves structured KPI time series from the governed store.
- `get_company_health` returns a composite score, category, and component diagnostics.
- `detect_kpi_anomalies` identifies spikes and deviations using Z-score or IQR analysis.
- `forecast_metric` projects future KPI values with upper and lower confidence bounds.
- `get_executive_summary` combines health, selected metrics, and anomalies into one briefing.
- YAML packs can add read, write, or destructive tools without forking the server.

## Limitations and notes

The six core tools are read-oriented; additional write behavior comes from loaded packs such as `annotations`. Writes remain disabled by default, and destructive operations are not authorized by prompts alone. The bundled KPI domains and periods come from the server’s seeded data, while custom deployments can extend the available tools and resources through configuration and code. The optional demos and research scripts require dependencies beyond the server-only installation.

_Full upstream README: https://allmcps.com/mcp/agentkit/readme_

