MCPAPI Reference

Choose documentation 3

latest

Current version

latest
English

Prerelease This site documents an alpha of libtmux. Its structure, URLs and APIs are subject to change.

LibTmux.Mcp.ServerPolicy

API reference · Markdown

struct LibTmux.Mcp.ServerPolicy
struct [source]

What this server will do, and how much of it at once.

Description#

Every knob is resolved once at startup from the environment. A bad or out-of-range value is clamped and logged rather than refused: an operator who mistypes a ceiling gets a working server and a warning, not a client that fails to start with nothing to read.

Discussed in C# MCP API

Members

WaitCeiling

WaitCeiling : TimeSpan
property [source]

Gets the longest a single wait may block before reporting a timeout.

Description#

The ceiling bounds the model's turn rather than the transport: waits await throughout, so a long one does not stall other calls. What an unbounded wait costs is the turn itself — a badly chosen pattern would spend all of it with nothing to show. Client-managed MCP tasks cover work that legitimately outlives one synchronous request.

MaxLines

MaxLines : int
property [source]

Gets the line budget a capture uses when the caller names none.

MaxBytes

MaxBytes : int
property [source]

Gets the byte budget one content-bearing result may carry.

AllowPollingFallback

AllowPollingFallback : bool
property [source]

Gets whether pane text waits may poll when control observation is unavailable.

Description#

Disabled by default. Results disclose activation; command completion still uses tmux wait channels.

FromEnvironment

FromEnvironment ( read : Func<string, string?> , logger : ILogger? ) → ServerPolicy
methodstatic [source]

Reads the policy out of a set of environment variables.

Parameters
  • read ( Func<string, string?> ) – Answers an environment variable, or null when it is unset.

  • logger ( ILogger? ) – Records a clamped or unreadable value.

Returns

The resolved policy.

EffectiveTimeout

EffectiveTimeout ( requested : TimeSpan? ) → TimeSpan
method [source]

Lowers a caller's timeout to the ceiling this policy sets.

Description#

An over-large request is honoured at the ceiling rather than refused, and the result reports the value used, so a model learns the policy from what came back instead of from a failed call.

Parameters
  • requested ( TimeSpan? ) – What the caller asked for, or null for the ceiling.

Returns

The duration a wait will actually use.

Esc

Type to search.