This commit is contained in:
salmanap 2026-01-07 19:21:18 +00:00
parent 7d5ac51905
commit a3643ae04a
36 changed files with 1274 additions and 13 deletions

View file

@ -1,6 +1,6 @@
Plano Docs v0.4.1
llms.txt (auto-generated)
Generated (UTC): 2026-01-07T16:45:10.576143+00:00
Generated (UTC): 2026-01-07T19:21:15.065859+00:00
Table of contents
- Agents (concepts/agents)
@ -11,6 +11,7 @@ Table of contents
- Model Aliases (concepts/llm_providers/model_aliases)
- Supported Providers & Configuration (concepts/llm_providers/supported_providers)
- Prompt Target (concepts/prompt_target)
- Signals™ (concepts/signals)
- Intro to Plano (get_started/intro_to_plano)
- Overview (get_started/overview)
- Quickstart (get_started/quickstart)
@ -2277,6 +2278,445 @@ By carefully designing prompt targets as deterministic, task-specific entry poin
---
Signals™
--------
Doc: concepts/signals
-*- coding: utf-8 -*-
Signals™
Agentic Signals are behavioral and executions quality indicators that act as early warning signs of agent performance—highlighting both brilliant successes and severe failures. These signals are computed directly from conversation traces without requiring manual labeling or domain expertise, making them practical for production observability at scale.
The Problem: Knowing Whats “Good”
One of the hardest parts of building agents is measuring how well they perform in the real world.
Offline testing relies on hand-picked examples and happy-path scenarios, missing the messy diversity of real usage. Developers manually prompt models, evaluate responses, and tune prompts by guesswork—a slow, incomplete feedback loop.
Production debugging floods developers with traces and logs but provides little guidance on which interactions actually matter. Finding failures means painstakingly reconstructing sessions and manually labeling quality issues.
You cant score every response with an LLM-as-judge (too expensive, too slow) or manually review every trace (doesnt scale). What you need are behavioral signals—fast, economical proxies that dont label quality outright but dramatically shrink the search space, pointing to sessions most likely to be broken or brilliant.
What Are Behavioral Signals?
Behavioral signals are canaries in the coal mine—early, objective indicators that something may have gone wrong (or gone exceptionally well). They dont explain why an agent failed, but they reliably signal where attention is needed.
These signals emerge naturally from the rhythm of interaction:
A user rephrasing the same request
Sharp increases in conversation length
Frustrated follow-up messages (ALL CAPS, “this doesnt work”, excessive !!!/???)
Agent repetition / looping
Expressions of gratitude or satisfaction
Requests to speak to a human / contact support
Individually, these clues are shallow; together, they form a fingerprint of agent performance. Embedded directly into traces, they make it easy to spot friction as it happens: where users struggle, where agents loop, and where escalations occur.
Signals vs Response Quality
Behavioral signals and response quality are complementary.
Response Quality
Domain-specific correctness: did the agent do the right thing given business rules, user intent, and operational context? This often requires subject-matter experts or outcome instrumentation and is time-intensive but irreplaceable.
Behavioral Signals
Observable patterns that correlate with quality: high repair frequency, excessive turns, frustration markers, repetition, escalation, and positive feedback. Fast to compute and valuable for prioritizing which traces deserve inspection.
Used together, signals tell you where to look, and quality evaluation tells you what went wrong (or right).
How It Works
Signals are computed automatically by the gateway and emitted as OpenTelemetry trace attributes to your existing observability stack (Jaeger, Honeycomb, Grafana Tempo, etc.). No additional libraries or instrumentation required—just configure your OTEL collector endpoint.
Each conversation trace is enriched with signal attributes that you can query, filter, and visualize in your observability platform. The gateway analyzes message content (performing text normalization, Unicode handling, and pattern matching) to compute behavioral signals in real-time.
OTEL Trace Attributes
Signal data is exported as structured span attributes:
signals.quality - Overall assessment (Excellent/Good/Neutral/Poor/Severe)
signals.turn_count - Total number of turns in the conversation
signals.efficiency_score - Efficiency metric (0.0-1.0)
signals.repair.count - Number of repair attempts detected (when present)
signals.repair.ratio - Ratio of repairs to user turns (when present)
signals.frustration.count - Number of frustration indicators detected
signals.frustration.severity - Frustration level (0-3)
signals.repetition.count - Number of repetition instances detected
signals.escalation.requested - Boolean escalation flag (“true” when present)
signals.positive_feedback.count - Number of positive feedback indicators
Visual Flag Marker
When concerning signals are detected (frustration, looping, escalation, or poor/severe quality), the flag marker 🚩 is automatically appended to the spans operation name, making problematic traces easy to spot in your trace visualizations.
Querying in Your Observability Platform
Example queries:
Find all severe interactions: signals.quality = "Severe"
Find flagged traces: search for 🚩 in span names
Find long conversations: signals.turn_count > 10
Find inefficient interactions: signals.efficiency_score < 0.5
Find high repair rates: signals.repair.ratio > 0.3
Find frustrated users: signals.frustration.severity >= 2
Find looping agents: signals.repetition.count >= 3
Find positive interactions: signals.positive_feedback.count >= 2
Find escalations: signals.escalation.requested = "true"
Core Signal Types
The signals system tracks six categories of behavioral indicators.
Turn Count & Efficiency
What it measures
Number of userassistant exchanges.
Why it matters
Long conversations often indicate unclear intent resolution, confusion, or inefficiency. Very short conversations can correlate with crisp resolution.
Key metrics
Total turn count
Warning thresholds (concerning: >7 turns, excessive: >12 turns)
Efficiency score (0.01.0)
Efficiency scoring
Baseline expectation is ~5 turns (tunable). Efficiency stays at 1.0 up to the baseline, then declines with an inverse penalty as turns exceed baseline:
efficiency = 1 / (1 + 0.3 * (turns - baseline))
Follow-Up & Repair Frequency
What it measures
How often users clarify, correct, or rephrase requests. This is a user signal tracking query reformulation behavior—when users must repair or rephrase their requests because the agent didnt understand or respond appropriately.
Why it matters
High repair frequency is a proxy for misunderstanding or intent drift. When users repeatedly rephrase the same request, it indicates the agent is failing to grasp or act on the users intent.
Key metrics
Repair count and ratio (repairs / user turns)
Concerning threshold: >30% repair ratio
Detected repair phrases (exact or fuzzy)
Common patterns detected
Explicit corrections: “I meant”, “correction”
Negations: “No, I…”, “thats not”
Rephrasing: “let me rephrase”, “to clarify”
Mistake acknowledgment: “my mistake”, “I was wrong”
“Similar rephrase” heuristic based on token overlap (with stopwords downweighted)
User Frustration
What it measures
Observable frustration indicators and emotional escalation.
Why it matters
Catching frustration early enables intervention before users abandon or escalate.
Detection patterns
Complaints: “this doesnt work”, “not helpful”, “waste of time”
Confusion: “I dont understand”, “makes no sense”, “Im confused”
Tone markers:
ALL CAPS (>=10 alphabetic chars and >=80% uppercase)
Excessive punctuation (>=3 exclamation marks or >=3 question marks)
Profanity: token-based (avoids substring false positives like “absolute” -> “bs”)
Severity levels
None (0): no indicators
Mild (1): 12 indicators
Moderate (2): 34 indicators
Severe (3): 5+ indicators
Repetition & Looping
What it measures
Assistant repetition / degenerative loops. This is an assistant signal tracking when the agent repeats itself, fails to follow instructions, or gets stuck in loops—indicating the agent is not making progress or adapting its responses.
Why it matters
Often indicates missing state tracking, broken tool integration, prompt issues, or the agent ignoring user corrections. High repetition means the agent is not learning from the conversation context.
Detection method
Compare assistant messages using bigram Jaccard similarity
Classify:
Exact: similarity >= 0.85
Near-duplicate: similarity >= 0.50
Looping is flagged when repetition instances exceed 2 in a session.
Severity levels
None (0): 0 instances
Mild (1): 12 instances
Moderate (2): 34 instances
Severe (3): 5+ instances
Positive Feedback
What it measures
User expressions of satisfaction, gratitude, and success.
Why it matters
Strong positive signals identify exemplar traces for prompt engineering and evaluation.
Detection patterns
Gratitude: “thank you”, “appreciate it”
Satisfaction: “thats great”, “awesome”, “love it”
Success confirmation: “got it”, “that worked”, “perfect”
Confidence scoring
1 indicator: 0.6
2 indicators: 0.8
3+ indicators: 0.95
Escalation Requests
What it measures
Requests for human help/support or threats to quit.
Why it matters
Escalation is a strong signal that the agent failed to resolve the interaction.
Detection patterns
Human requests: “speak to a human”, “real person”, “live agent”
Support: “contact support”, “customer service”, “help desk”
Quit threats: “Im done”, “forget it”, “I give up”
Overall Quality Assessment
Signals are aggregated into an overall interaction quality on a 5-point scale.
Excellent
Strong positive signals, efficient resolution, low friction.
Good
Mostly positive with minor clarifications; some back-and-forth but successful.
Neutral
Mixed signals; neither clearly good nor bad.
Poor
Concerning negative patterns (high friction, multiple repairs, moderate frustration). High abandonment risk.
Severe
Critical issues—escalation requested, severe frustration, severe looping, or excessive turns (>12). Requires immediate attention.
This assessment uses a scoring model that weighs positive factors (efficiency, positive feedback) against negative ones (frustration, repairs, repetition, escalation).
Sampling and Prioritization
In production, trace data is overwhelming. Signals provide a lightweight first layer of analysis to prioritize which sessions deserve review.
Workflow:
Gateway captures conversation messages and computes signals
Signal attributes are emitted to OTEL spans automatically
Your observability platform ingests and indexes the attributes
Query/filter by signal attributes to surface outliers (poor/severe and exemplars)
Review high-information traces to identify improvement opportunities
Update prompts, routing, or policies based on findings
Redeploy and monitor signal metrics to validate improvements
This creates a reinforcement loop where traces become both diagnostic data and training signal.
Trace Filtering and Telemetry
Signal attributes are automatically added to OpenTelemetry spans, making them immediately queryable in your observability platform.
Visual Filtering
When concerning signals are detected, the flag marker 🚩 (U+1F6A9) is automatically appended to the spans operation name. This makes flagged sessions immediately visible in trace visualizations without requiring attribute filtering.
Example Span Attributes:
# Span name: "POST /v1/chat/completions gpt-4 🚩"
signals.quality = "Severe"
signals.turn_count = 15
signals.efficiency_score = 0.234
signals.repair.count = 4
signals.repair.ratio = 0.571
signals.frustration.severity = 3
signals.frustration.count = 5
signals.escalation.requested = "true"
signals.repetition.count = 4
Building Dashboards
Use signal attributes to build monitoring dashboards in Grafana, Honeycomb, Datadog, etc.:
Quality distribution: Count of traces by signals.quality
P95 turn count: 95th percentile of signals.turn_count
Average efficiency: Mean of signals.efficiency_score
High repair rate: Percentage where signals.repair.ratio > 0.3
Frustration rate: Percentage where signals.frustration.severity >= 2
Escalation rate: Percentage where signals.escalation.requested = "true"
Looping rate: Percentage where signals.repetition.count >= 3
Positive feedback rate: Percentage where signals.positive_feedback.count >= 1
Creating Alerts
Set up alerts based on signal thresholds:
Alert when severe interaction count exceeds threshold in 1-hour window
Alert on sudden spike in frustration rate (>2x baseline)
Alert when escalation rate exceeds 5% of total conversations
Alert on degraded efficiency (P95 turn count increases >50%)
Best Practices
Start simple:
Alert or page on Severe sessions (or on spikes in Severe rate)
Review Poor sessions within 24 hours
Sample Excellent sessions as exemplars
Combine multiple signals to infer failure modes:
Looping: repetition severity >= 2 + excessive turns
User giving up: frustration severity >= 2 + escalation requested
Misunderstood intent: repair ratio > 30% + excessive turns
Working well: positive feedback + high efficiency + no frustration
Limitations and Considerations
Signals dont capture:
Task completion / real outcomes
Factual or domain correctness
Silent abandonment (user leaves without expressing frustration)
Non-English nuance (pattern libraries are English-oriented)
Mitigation strategies:
Periodically sample flagged sessions and measure false positives/negatives
Tune baselines per use case and user population
Add domain-specific phrase libraries where needed
Combine signals with non-text metrics (tool failures, disconnects, latency)
Behavioral signals complement—but do not replace—domain-specific response quality evaluation. Use signals to prioritize which traces to inspect, then apply domain expertise and outcome checks to diagnose root causes.
The flag marker in the span name provides instant visual feedback in trace UIs, while the structured attributes (signals.quality, signals.frustration.severity, etc.) enable powerful querying and aggregation in your observability platform.
See Also
../guides/observability/tracing - Distributed tracing for agent systems
../guides/observability/monitoring - Metrics and dashboards
../guides/observability/access_logging - Request/response logging
../guides/observability/observability - Complete observability guide
---
Intro to Plano
--------------
Doc: get_started/intro_to_plano
@ -2342,7 +2782,7 @@ Doc: get_started/overview
Overview
Plano is delivery infrastructure for agentic apps. A models-native proxy server and data plane designed to help you build agents faster, and deliver them reliably to production.
Plano is delivery infrastructure for agentic apps. A smart proxy server and data plane designed to help you build agents faster, and deliver them reliably to production.
Plano pulls out the rote plumbing work (the “hidden AI middleware”) and decouples you from brittle, everchanging framework abstractions. It centralizes what shouldnt be bespoke in every codebase like agent routing and orchestration, rich agentic signals and traces for continuous improvement, guardrail filters for safety and moderation, and smart LLM routing APIs for UX and DX agility. Use any language or AI framework, and ship agents to production faster with Plano.
@ -3395,6 +3835,130 @@ tools.
Understanding Plano Traces
Plano creates structured traces that capture the complete flow of requests through your AI system. Each trace consists of multiple spans representing different stages of processing.
Inbound Request Handling
When a request enters Plano, it creates an inbound span (plano(inbound)) that represents the initial request reception and processing. This span captures:
HTTP request details (method, path, headers)
Request payload size
Initial validation and authentication
Orchestration & Routing
For agent systems, Plano performs intelligent routing through orchestration spans:
Agent Orchestration (plano(orchestrator)): When multiple agents are available, Plano uses an LLM to analyze the users intent and select the most appropriate agent. This span captures the orchestration decision-making process.
LLM Routing (plano(routing)): For direct LLM requests, Plano determines the optimal endpoint based on your routing strategy (round-robin, least-latency, cost-optimized). This span includes:
Routing strategy used
Selected upstream endpoint
Route determination time
Fallback indicators (if applicable)
Agent Processing
When requests are routed to agents, Plano creates spans for agent execution:
Agent Filter Chains (plano(filter)): If filters are configured (guardrails, context enrichment, query rewriting), each filter execution is captured in its own span, showing the transformation pipeline.
Agent Execution (plano(agent)): The main agent processing span that captures the agents work, including any tools invoked and intermediate reasoning steps.
Outbound LLM Calls
All LLM calls—whether from Planos routing layer or from agents—are traced with LLM spans (plano(llm)) that capture:
Model name and provider (e.g., gpt-4, claude-3-sonnet)
Request parameters (temperature, max_tokens, top_p)
Token usage (prompt_tokens, completion_tokens)
Streaming indicators and time-to-first-token
Response metadata
Example Span Attributes:
# LLM call span
llm.model = "gpt-4"
llm.provider = "openai"
llm.usage.prompt_tokens = 150
llm.usage.completion_tokens = 75
llm.duration_ms = 1250
llm.time_to_first_token = 320
Handoff to Upstream Services
When Plano forwards requests to upstream services (agents, APIs, or LLM providers), it creates handoff spans (plano(handoff)) that capture:
Upstream endpoint URL
Request/response sizes
HTTP status codes
Upstream response times
This creates a complete end-to-end trace showing the full request lifecycle through all system components.
Behavioral Signals in Traces
Plano automatically enriches OpenTelemetry traces with ../../concepts/signals — behavioral quality indicators computed from conversation patterns. These signals are attached as span attributes, providing immediate visibility into interaction quality.
What Signals Provide
Signals act as early warning indicators embedded in your traces:
Quality Assessment: Overall interaction quality (Excellent/Good/Neutral/Poor/Severe)
Efficiency Metrics: Turn count, efficiency scores, repair frequency
User Sentiment: Frustration indicators, positive feedback, escalation requests
Agent Behavior: Repetition detection, looping patterns
Visual Flag Markers
When concerning signals are detected (frustration, looping, escalation, or poor/severe quality), Plano automatically appends a flag marker 🚩 to the spans operation name. This makes problematic traces immediately visible in your tracing UI without requiring additional queries.
Example Span with Signals:
# Span name: "POST /v1/chat/completions gpt-4 🚩"
# Standard LLM attributes:
llm.model = "gpt-4"
llm.usage.total_tokens = 225
# Behavioral signal attributes:
signals.quality = "Severe"
signals.turn_count = 15
signals.efficiency_score = 0.234
signals.frustration.severity = 3
signals.escalation.requested = "true"
Querying Signal Data
In your observability platform (Jaeger, Grafana Tempo, Datadog, etc.), filter traces by signal attributes:
Find severe interactions: signals.quality = "Severe"
Find frustrated users: signals.frustration.severity >= 2
Find inefficient flows: signals.efficiency_score < 0.5
Find escalations: signals.escalation.requested = "true"
For complete details on all available signals, detection methods, and best practices, see the ../../concepts/signals guide.
Benefits of Using Traceparent Headers
Standardization: The W3C Trace Context standard ensures compatibility across ecosystem tools, allowing
@ -4826,7 +5390,7 @@ Welcome to Plano!
Plano is delivery infrastructure for agentic apps. A models-native proxy server and data plane designed to help you build agents faster, and deliver them reliably to production.
Plano is delivery infrastructure for agentic apps. A smart proxy server and data plane designed to help you build agents faster, and deliver them reliably to production.
Plano pulls out the rote plumbing work (aka “hidden AI middleware”) and decouples you from brittle, everchanging framework abstractions. It centralizes what shouldnt be bespoke in every codebase like agent routing and orchestration, rich agentic signals and traces for continuous improvement, guardrail filters for safety and moderation, and smart LLM routing APIs for UX and DX agility. Use any language or AI framework, and ship agents to production faster with Plano.