@iris-eval/mcp-server 0.1.2 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +92 -108
- package/dist/dashboard/assets/index-CGWlxM5E.js +127 -0
- package/dist/dashboard/assets/{index-DsCtYyvh.css → index-zuWgVxsu.css} +1 -1
- package/dist/dashboard/favicon.svg +4 -3
- package/dist/dashboard/index.html +2 -2
- package/dist/storage/sqlite-adapter.d.ts +6 -1
- package/dist/storage/sqlite-adapter.js +164 -0
- package/dist/transport/http.js +9 -2
- package/dist/types/index.d.ts +1 -1
- package/dist/types/query.d.ts +38 -0
- package/package.json +22 -7
- package/server.json +38 -64
- package/dist/dashboard/assets/index-BgsGBkem.js +0 -127
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -1,41 +1,103 @@
|
|
|
1
|
-
# Iris —
|
|
1
|
+
# Iris — The Agent Eval Standard for MCP
|
|
2
2
|
|
|
3
|
+
[](https://github.com/iris-eval/mcp-server)
|
|
3
4
|
[](https://npmjs.com/package/@iris-eval/mcp-server)
|
|
5
|
+
[](https://npmjs.com/package/@iris-eval/mcp-server)
|
|
4
6
|
[](https://github.com/iris-eval/mcp-server/actions/workflows/ci.yml)
|
|
5
7
|
[](LICENSE)
|
|
6
|
-
[](https://github.com/iris-eval/mcp-server/pkgs/container/mcp-server)
|
|
7
9
|
|
|
8
|
-
Iris is an open-source
|
|
10
|
+
**Know whether your AI agents are actually good enough to ship.** Iris is an open-source MCP server that scores output quality, catches safety failures, and enforces cost budgets across all your agents. Any MCP-compatible agent discovers and uses it automatically — no SDK, no code changes.
|
|
9
11
|
|
|
10
12
|

|
|
11
13
|
|
|
14
|
+
## The Problem
|
|
15
|
+
|
|
16
|
+
Your agents are running in production. Infrastructure monitoring sees `200 OK` and moves on. It has no idea the agent just:
|
|
17
|
+
|
|
18
|
+
- Leaked a social security number in its response
|
|
19
|
+
- Hallucinated an answer with zero factual grounding
|
|
20
|
+
- Burned $0.47 on a single query — 4.7x your budget threshold
|
|
21
|
+
- Made 6 tool calls when 2 would have sufficed
|
|
22
|
+
|
|
23
|
+
Iris evaluates all of it.
|
|
24
|
+
|
|
25
|
+
## What You Get
|
|
26
|
+
|
|
27
|
+
| | |
|
|
28
|
+
|---|---|
|
|
29
|
+
| **Trace Logging** | Hierarchical span trees with per-tool-call latency, token usage, and cost in USD. Stored in SQLite, queryable instantly. |
|
|
30
|
+
| **Output Evaluation** | 12 built-in rules across 4 categories: completeness, relevance, safety, cost. PII detection, prompt injection patterns, hallucination markers. Add custom rules with Zod schemas. |
|
|
31
|
+
| **Cost Visibility** | Aggregate cost across all agents over any time window. Set budget thresholds. Get flagged when agents overspend. |
|
|
32
|
+
| **Web Dashboard** | Real-time dark-mode UI with trace visualization, eval results, and cost breakdowns. |
|
|
33
|
+
|
|
12
34
|
## Quickstart
|
|
13
35
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
36
|
+
Add Iris to your Claude Desktop (or Cursor, Claude Code, Windsurf) MCP config:
|
|
37
|
+
|
|
38
|
+
```json
|
|
39
|
+
{
|
|
40
|
+
"mcpServers": {
|
|
41
|
+
"iris-eval": {
|
|
42
|
+
"command": "npx",
|
|
43
|
+
"args": ["@iris-eval/mcp-server"]
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
17
47
|
```
|
|
18
48
|
|
|
19
|
-
|
|
49
|
+
That's it. Your agent discovers Iris and starts logging traces automatically.
|
|
50
|
+
|
|
51
|
+
Want the dashboard?
|
|
20
52
|
|
|
21
53
|
```bash
|
|
22
|
-
npx @iris-eval/mcp-server
|
|
54
|
+
npx @iris-eval/mcp-server --dashboard
|
|
55
|
+
# Open http://localhost:6920
|
|
23
56
|
```
|
|
24
57
|
|
|
25
|
-
###
|
|
58
|
+
### Other Install Methods
|
|
26
59
|
|
|
27
60
|
```bash
|
|
61
|
+
# Global install
|
|
62
|
+
npm install -g @iris-eval/mcp-server
|
|
63
|
+
iris-mcp --dashboard
|
|
64
|
+
|
|
65
|
+
# Docker
|
|
28
66
|
docker run -p 3000:3000 -v iris-data:/data ghcr.io/iris-eval/mcp-server
|
|
29
67
|
```
|
|
30
68
|
|
|
31
|
-
##
|
|
69
|
+
## MCP Tools
|
|
70
|
+
|
|
71
|
+
Iris registers three tools that any MCP-compatible agent can invoke:
|
|
72
|
+
|
|
73
|
+
- **`log_trace`** — Log an agent execution with spans, tool calls, token usage, and cost
|
|
74
|
+
- **`evaluate_output`** — Score output quality against completeness, relevance, safety, and cost rules
|
|
75
|
+
- **`get_traces`** — Query stored traces with filtering, pagination, and time-range support
|
|
76
|
+
|
|
77
|
+
Full tool schemas and configuration: [iris-eval.com](https://iris-eval.com)
|
|
78
|
+
|
|
79
|
+
## Cloud Tier (Coming Soon)
|
|
80
|
+
|
|
81
|
+
Self-hosted Iris runs on your machine with SQLite. As your team's eval needs grow, the cloud tier adds PostgreSQL, team dashboards, alerting on quality regressions, and managed infrastructure.
|
|
82
|
+
|
|
83
|
+
[Join the waitlist](https://iris-eval.com#waitlist) to get early access.
|
|
84
|
+
|
|
85
|
+
## Examples
|
|
86
|
+
|
|
87
|
+
- [Claude Desktop setup](examples/claude-desktop/) — MCP config for stdio and HTTP modes
|
|
88
|
+
- [TypeScript](examples/typescript/basic-usage.ts) — MCP SDK client usage
|
|
89
|
+
- [LangChain](examples/langchain/observe-agent.py) — Agent instrumentation
|
|
90
|
+
- [CrewAI](examples/crewai/observe-crew.py) — Crew observability
|
|
91
|
+
|
|
92
|
+
## Community
|
|
32
93
|
|
|
33
|
-
|
|
94
|
+
- [GitHub Issues](https://github.com/iris-eval/mcp-server/issues) — Bug reports and feature requests
|
|
95
|
+
- [GitHub Discussions](https://github.com/iris-eval/mcp-server/discussions) — Questions and ideas
|
|
96
|
+
- [Contributing Guide](CONTRIBUTING.md) — How to contribute
|
|
97
|
+
- [Roadmap](docs/roadmap.md) — What's coming next
|
|
34
98
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
3. Environment variables (`IRIS_*`)
|
|
38
|
-
4. CLI arguments
|
|
99
|
+
<details>
|
|
100
|
+
<summary><strong>Configuration & Security</strong></summary>
|
|
39
101
|
|
|
40
102
|
### CLI Arguments
|
|
41
103
|
|
|
@@ -61,107 +123,29 @@ Iris looks for config in this order (later overrides earlier):
|
|
|
61
123
|
| `IRIS_API_KEY` | API key for HTTP authentication |
|
|
62
124
|
| `IRIS_ALLOWED_ORIGINS` | Comma-separated allowed CORS origins |
|
|
63
125
|
|
|
64
|
-
|
|
126
|
+
### Security
|
|
65
127
|
|
|
66
|
-
When using
|
|
128
|
+
When using HTTP transport, Iris includes:
|
|
67
129
|
|
|
68
|
-
-
|
|
69
|
-
-
|
|
70
|
-
-
|
|
71
|
-
-
|
|
72
|
-
-
|
|
73
|
-
-
|
|
74
|
-
-
|
|
75
|
-
- **Structured logging** — JSON logs to stderr via pino. Never writes to stdout (reserved for stdio transport).
|
|
130
|
+
- API key authentication with timing-safe comparison
|
|
131
|
+
- CORS restricted to localhost by default
|
|
132
|
+
- Rate limiting (100 req/min API, 20 req/min MCP)
|
|
133
|
+
- Helmet security headers
|
|
134
|
+
- Zod input validation on all routes
|
|
135
|
+
- ReDoS-safe regex for custom eval rules
|
|
136
|
+
- 1MB request body limits
|
|
76
137
|
|
|
77
138
|
```bash
|
|
78
|
-
# Production deployment
|
|
139
|
+
# Production deployment
|
|
79
140
|
iris-mcp --transport http --port 3000 --api-key "$(openssl rand -hex 32)" --dashboard
|
|
80
141
|
```
|
|
81
142
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
### `log_trace`
|
|
85
|
-
|
|
86
|
-
Log an agent execution trace with spans, tool calls, and metrics.
|
|
87
|
-
|
|
88
|
-
**Input:**
|
|
89
|
-
- `agent_name` (required) — Name of the agent
|
|
90
|
-
- `input` — Agent input text
|
|
91
|
-
- `output` — Agent output text
|
|
92
|
-
- `tool_calls` — Array of tool call records
|
|
93
|
-
- `latency_ms` — Execution time in milliseconds
|
|
94
|
-
- `token_usage` — `{ prompt_tokens, completion_tokens, total_tokens }`
|
|
95
|
-
- `cost_usd` — Total cost in USD
|
|
96
|
-
- `metadata` — Arbitrary key-value metadata
|
|
97
|
-
- `spans` — Array of span objects for detailed tracing
|
|
98
|
-
|
|
99
|
-
### `evaluate_output`
|
|
100
|
-
|
|
101
|
-
Evaluate agent output quality using configurable rules.
|
|
102
|
-
|
|
103
|
-
**Input:**
|
|
104
|
-
- `output` (required) — The text to evaluate
|
|
105
|
-
- `eval_type` — Type: `completeness`, `relevance`, `safety`, `cost`, `custom`
|
|
106
|
-
- `expected` — Expected output for comparison
|
|
107
|
-
- `trace_id` — Link evaluation to a trace
|
|
108
|
-
- `custom_rules` — Array of custom rule definitions
|
|
109
|
-
|
|
110
|
-
### `get_traces`
|
|
111
|
-
|
|
112
|
-
Query stored traces with filters and pagination.
|
|
113
|
-
|
|
114
|
-
**Input:**
|
|
115
|
-
- `agent_name` — Filter by agent name
|
|
116
|
-
- `framework` — Filter by framework
|
|
117
|
-
- `since` — ISO timestamp lower bound
|
|
118
|
-
- `until` — ISO timestamp upper bound
|
|
119
|
-
- `min_score` / `max_score` — Score range filter
|
|
120
|
-
- `limit` — Results per page (default 50)
|
|
121
|
-
- `offset` — Pagination offset
|
|
122
|
-
|
|
123
|
-
## MCP Resources
|
|
124
|
-
|
|
125
|
-
- `iris://dashboard/summary` — Dashboard summary statistics
|
|
126
|
-
- `iris://traces/{trace_id}` — Full trace detail with spans and evals
|
|
127
|
-
|
|
128
|
-
## Claude Desktop
|
|
129
|
-
|
|
130
|
-
Add Iris to your Claude Desktop MCP config:
|
|
131
|
-
|
|
132
|
-
```json
|
|
133
|
-
{
|
|
134
|
-
"mcpServers": {
|
|
135
|
-
"iris-eval": {
|
|
136
|
-
"command": "npx",
|
|
137
|
-
"args": ["@iris-eval/mcp-server"]
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
```
|
|
142
|
-
|
|
143
|
-
Then ask Claude to "log a trace" or "evaluate this output" — Iris tools are automatically available.
|
|
144
|
-
|
|
145
|
-
See [examples/claude-desktop/](examples/claude-desktop/) for more configuration options.
|
|
146
|
-
|
|
147
|
-
## Web Dashboard
|
|
148
|
-
|
|
149
|
-
Start with `--dashboard` flag to enable the web UI at `http://localhost:6920`.
|
|
150
|
-
|
|
151
|
-
## Examples
|
|
152
|
-
|
|
153
|
-
- [Claude Desktop setup](examples/claude-desktop/) — MCP config for stdio and HTTP modes
|
|
154
|
-
- [TypeScript](examples/typescript/basic-usage.ts) — MCP SDK client usage
|
|
155
|
-
- [LangChain](examples/langchain/observe-agent.py) — Agent instrumentation
|
|
156
|
-
- [CrewAI](examples/crewai/observe-crew.py) — Crew observability
|
|
143
|
+
</details>
|
|
157
144
|
|
|
158
|
-
|
|
145
|
+
---
|
|
159
146
|
|
|
160
|
-
|
|
161
|
-
- [GitHub Discussions](https://github.com/iris-eval/mcp-server/discussions) — Questions and ideas
|
|
162
|
-
- [Contributing Guide](CONTRIBUTING.md) — How to contribute
|
|
163
|
-
- [Roadmap](../docs/roadmap.md) — What's coming next
|
|
147
|
+
If Iris is useful to you, [consider starring the repo](https://github.com/iris-eval/mcp-server) — it helps others find it.
|
|
164
148
|
|
|
165
|
-
|
|
149
|
+
[](https://github.com/iris-eval/mcp-server)
|
|
166
150
|
|
|
167
|
-
MIT
|
|
151
|
+
MIT Licensed.
|