Better Agents

Better Agents is a CLI tool and agent project harness developed by LangWatch. It acts as a standardized reliability layer for building, testing, and evaluating AI agents, serving as a framework-agnostic scaffold that works alongside libraries like Agno, Mastra, LangGraph, and the Vercel AI SDK. Day-to-day development revolves around a structured project layout containing agent runtime code (`app/` or `src/`), scenario-based conversational tests, component evaluations, and version-controlled YAML prompts. Better Agents integrates with coding assistants such as Claude Code, Cursor, and Kilocode via Model Context Protocol configurations (`.mcp.json`) and repository guidelines (`AGENTS.md`), providing the assistant with architectural context and testing standards. Unlike standalone coding agents or isolated agent SDKs, Better Agents functions as an orchestrating harness. It standardizes conversational regression testing using simulated user agents and evaluation judges, verifying multi-turn conversational flows, tool invocations, and state transitions through standard test runners like pytest and Vitest while syncing run metrics directly to the LangWatch platform. The CLI package is distributed freely via npm for local project scaffolding and execution, integrating with LangWatch's hosted and self-hosted tiers for simulation visualization and observability.

Tags: agent harness, ai agent, cli, developer tools, Generative AI

Visit Better Agents

Key features

  • Framework-agnostic scaffolding — Generates standardized agent project layouts compatible with Agno, Mastra, LangGraph, Vercel AI SDK, and custom architectures. - Scenario-based conversational testing — Simulates multi-turn conversations using mock user agents and LLM-as-a-judge evaluators to validate runtime behavior across model updates. - MCP integration for coding assistants — Configures .mcp.json and AGENTS.md context files so coding assistants like Claude Code and Cursor understand project conventions. - Versioned prompt management — Maintains YAML-formatted prompt templates tracked through a local prompts.json registry synced with LangWatch. - Native test runner execution — Executes end-to-end multi-agent simulations and deterministic assertions directly through pytest (Python) or Vitest/npm test (TypeScript). - LangWatch platform synchronization — Automatically streams scenario execution traces, evaluation metrics, and test run outcomes to the LangWatch Simulations dashboard.

Use cases

Use Case: Conversational Regression Testing Validate multi-turn agent workflows against regressions when updating prompts, tools, or underlying LLMs. Developers write automated scenario tests that pair the agent with a simulated user and judge agent to verify compliance and tool call sequences in CI/CD pipelines.

Use Case: Standardizing Agent Architecture for AI Coding Assistants Bootstrap new agent projects with preconfigured MCP connections, structured prompt registries, and repository rule files (AGENTS.md). This provides tools like Claude Code or Cursor with explicit framework best practices and scaffolding rules from the start.

Use Case: Tool Invocation & State Verification Assert specific intermediate state mutations and tool calling patterns during agent execution. Engineers can intercept the conversation state after each turn in TypeScript or Python test scripts to confirm expected function triggers before moving to the next turn.

Who it is for

Designed for AI engineers and software developers building production-grade conversational agents in Python or TypeScript who need structured testing, prompt versioning, and CI/CD validation. It is less relevant for developers looking for an autonomous terminal code-editing agent or teams instrumenting legacy codebases who only need LangWatch's direct observability SDKs.

Install guide

Installation Install the Better Agents CLI globally using npm: bash npm install -g @langwatch/better-agents Alternatively, you can initialize a project directly using npx without a global installation: bash npx @langwatch/better-agents init my-agent-project

First Run 1. Initialize a new project directory and follow the interactive prompts to configure your language (Python/TypeScript), framework, and LLM provider: bash better-agents init my-better-agent cd my-better-agent 2. Configure your environment variables in .env with your LLM provider API keys and LangWatch API credentials: bash cp .env.example .env # Populate OPENAI_API_KEY, ANTHROPIC_API_KEY, and LANGWATCH_API_KEY

Example Session Run the pre-generated scenario test suite using your standard test runner to verify agent interactions: bash # For Python projects pytest tests/scenarios/ -v # For TypeScript projects npm test

Part of CLI Coding Agents

Categories: AI Coding Agents, Chatbot Development, Developer Tools

Related CLI agents

  • Agentlas-OS — Agentlas-OS is an open-source agent runtime fabric and orchestrator developed by Agentlas AI. It is designed to standardize, coordinate, and…
  • DeepAgents — DeepAgents is an open-source agentic coding framework and CLI tooling suite maintained by LangChain (langchain-ai). Designed to bring autonomous agent…
  • SWE-agent — SWE-agent is an open-source autonomous software engineering agent harness built and maintained by researchers from Princeton University and Stanford University.…
  • Stratless — Stratless is an open-source agent harness and execution orchestrator developed by the Stratless AI team. It provides a modular infrastructure…
  • Ona — Ona (formerly Gitpod's agentic platform, now part of OpenAI) is an enterprise-grade cloud agent orchestration platform that manages and runs…
  • Hivelore — Hivelore is an open-source agent harness and contextual memory orchestrator created by Doucs91. It provides persistent project memory, decision tracking,…
  • AI Tools
  • Categories
  • Industries
  • CLI Coding Agents
  • MCP Servers
  • MCP Categories