LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Agent
  • Middleware
  • Backends
  • Sandboxes
  • Skills
  • Subagents
  • Types
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
  • Vitest
⌘I

LangChain Assistant

Ask a question to get started

Enter to send•Shift+Enter new line

Menu

OverviewAgentMiddlewareBackendsSandboxesSkillsSubagentsTypes
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
Vitest
Language
Theme
JavaScriptdeepagentsprofilesharnessHarnessProfileOptions
Interface●Since v1.10

HarnessProfileOptions

Copy
interface HarnessProfileOptions

Properties

View source on GitHub
property
baseSystemPrompt: string

Replaces the default BASE_AGENT_PROMPT when set.

Use this when a model requires a fundamentally different base prompt rather than an additive suffix. Most profiles should prefer systemPromptSuffix instead.

property
excludedMiddleware: string[]

Middleware names to remove from the assembled middleware stack.

Matched against each middleware's .name property. Cannot include required scaffolding names (FilesystemMiddleware, SubAgentMiddleware) — attempting to do so throws at construction time.

property
excludedTools: string[]

Tool names to remove from the agent's visible tool set.

Applied via a filtering middleware after all tool-injecting middleware have run, so it catches both user-provided and middleware-provided tools.

property
extraMiddleware: AgentMiddleware<any, any, any, readonly ClientTool | ServerTool[]>[] | () => AgentMiddleware<any, any, any, readonly ClientTool | ServerTool[]>[]
property
generalPurposeSubagent: GeneralPurposeSubagentConfig

Configuration for the auto-added general-purpose subagent.

property
systemPromptSuffix: string

Text appended to the assembled base prompt with a blank-line separator (\n\n).

This is the primary mechanism for model-specific prompt tuning. Applied uniformly to the main agent, declarative subagents, and the auto-added general-purpose subagent.

property
toolDescriptionOverrides: Record<string, string>

Per-tool description replacements keyed by tool name.

Allows profiles to rewrite tool descriptions for models that respond better to different phrasing. Keys that don't match any tool in the final tool set are silently ignored.

User-facing options for creating a HarnessProfile.

Accepts plain arrays and records; the factory function converts them to their frozen counterparts. All fields are optional — an empty object produces a no-op profile.

Additional middleware appended to the stack after user middleware.

Can be a static array or a zero-arg factory that returns fresh instances per agent construction (important when middleware carries mutable state).