/**
 * tracedPort — instrument any port implementation with OTel spans.
 *
 * Sprint-460 — ships uniform observability for BrainPort / OutcomePort /
 * DbPort / any host-injected async surface. Wraps every function-valued
 * method of the impl in a span rooted at the active context; attributes
 * follow OpenTelemetry Semantic Conventions for GenAI operations where
 * applicable (gen_ai.system, gen_ai.operation.name).
 *
 * Usage:
 *   const raw: BrainPort = buildHttpBrain(...);
 *   const traced = tracedPort(raw, { portName: "brain", tracerName: "vauban-agent-sdk" });
 *   // traced.archiveKnowledge(...) emits a span per call.
 *
 * Transparent: the proxy's type is identical to T. Non-function fields
 * are forwarded unchanged. Sync methods still get a span (they complete
 * within the synchronous call frame).
 *
 * Opt-out: if no tracer is configured (getTracer returns the noop tracer,
 * which is the OTel default when no SDK is installed), spans become
 * no-ops — zero runtime cost for consumers who don't want tracing.
 */
import type { Span } from "@opentelemetry/api";
export interface TracedPortOptions {
    /**
     * Short port identifier, e.g. "brain", "outcome", "db". Emitted as
     * `gen_ai.system` attribute and used in span names.
     */
    portName: string;
    /**
     * OTel tracer name. Defaults to "vauban-agent-sdk".
     */
    tracerName?: string;
    /**
     * Optional hook to enrich the span with impl-specific attributes
     * before it completes. Receives the span, method name, and the
     * args/return-value of the call.
     */
    attributeHook?: (ctx: {
        span: Span;
        method: string;
        args: readonly unknown[];
        result?: unknown;
    }) => void;
}
/**
 * Wrap a port impl. Returns a proxy with the same type, instrumented.
 */
export declare function tracedPort<T extends object>(impl: T, options: TracedPortOptions): T;
//# sourceMappingURL=traced-port.d.ts.map