Class BowireAiOptions

Namespace
Kuestenlogik.Bowire.Ai
Assembly
Kuestenlogik.Bowire.Ai.dll

Configuration knobs for the optional Kuestenlogik.Bowire.Ai package (#25). Bound from Bowire:Ai; the CLI's --ai-provider / --ai-endpoint / --ai-model / --ai-api-key flags feed the same keys via the in-memory configuration overlay.

public sealed class BowireAiOptions
Inheritance
BowireAiOptions
Inherited Members

Remarks

Opt-in by construction. The package is only present if the host added Kuestenlogik.Bowire.Ai as a PackageReference. The standalone CLI bundles it; embedded hosts pick it up explicitly. Without the package, none of these options exist and the AI tab's hint engine stays the only AI surface.

Privacy stance per the ADR. The default provider is ollama against http://localhost:11434 — nothing leaves the machine. BYOK cloud providers (Phase 3: openai / anthropic / openrouter) require ApiKey; the key stays on the user's machine (persisted in ai-config.json) and is never proxied through Küstenlogik infrastructure. The MCP-client-reversal provider (Phase 4: mcp) routes prompts through a user-controlled MCP host — same local-first stance, no Bowire egress.

Constructors

BowireAiOptions()

public BowireAiOptions()

Properties

ApiKey

BYOK API key for the cloud providers. Required for "openai" / "anthropic" / "openrouter" — the provider's own SDK reads it. Ignored for local providers ("ollama" / "lmstudio") and the MCP path. Stored in ai-config.json next to the rest of the options; never proxied through Küstenlogik infrastructure.

public string? ApiKey { get; set; }

Property Value

string

AutoDetectLocal

Auto-detect Ollama + LM Studio on the standard ports during the GET /api/ai/probe-local call. Defaults true; privacy-paranoid users can disable.

public bool AutoDetectLocal { get; set; }

Property Value

bool

Endpoint

Base URL of the provider endpoint. For Ollama: http://localhost:11434; LM Studio: http://localhost:1234; OpenAI: https://api.openai.com/v1; OpenRouter: https://openrouter.ai/api/v1; Anthropic uses the SDK's built-in endpoint and ignores this field. For "mcp" the value is either an absolute MCP-over-HTTP URL (http://localhost:3845/mcp) or a stdio:-prefixed command line (stdio:claude mcp serve). Empty falls back to the provider's own default where one exists.

public string Endpoint { get; set; }

Property Value

string

Model

Model id the provider serves under (e.g. "llama3.2:3b", "qwen2.5:7b", "gpt-4o-mini", "claude-opus-4-7"). Bowire doesn't validate the name — the provider returns its own error if the model isn't loaded. For "mcp" the value is the model id the upstream MCP host should route the sampling request to.

public string Model { get; set; }

Property Value

string

ProviderId

Active provider id. "ollama" (default), "lmstudio", the BYOK cloud ids "openai" / "anthropic" / "openrouter", or "mcp" for the MCP-client-reversal path. Compared case-insensitively.

public string ProviderId { get; set; }

Property Value

string