Skip to content
Cette page a été générée et traduite avec l'aide de l'IA. Si vous remarquez des inexactitudes, n'hésitez pas à contribuer. Modifier sur GitHub

Diagnostics

This page covers advanced diagnostic procedures for investigating PRX issues that are pas resolved par le basic troubleshooting steps.

Diagnostic Commands

prx doctor

The comprehensive health check:

bash
prx doctor

Output includes:

  • Configuration validation results
  • Provider connectivity tests
  • System dependency checks
  • Resource usage summary

prx debug

Enable debug-level logging for detailed operation traces:

bash
PRX_LOG=debug prx daemon

Or set in config:

toml
[observability]
log_level = "debug"

prx info

Display system information:

bash
prx info

Shows:

  • PRX version and build info
  • OS and architecture
  • Configured fournisseurs and their status
  • Memory backend type and size
  • Plugin count and status

Log Analysis

PRX logs are structured JSON (when log_format = "json"). Key fields to look for:

ChampDescription
levelLog level (debug, info, warn, error)
targetRust module path
session_idAssociated session ID
fournisseurLLM fournisseur involved
duration_msOperation duration
errorError details (if applicable)

Network Diagnostics

Test fournisseur connectivity:

bash
# Test Anthropic API
prx provider test anthropic

# Test all configured providers
prx provider test --all

# Check network from sandbox
prx sandbox test-network

Performance Profiling

Enable the metrics endpoint and use Prometheus/Grafana for performance analysis:

toml
[observability.metrics]
enabled = true
bind = "127.0.0.1:9090"

Key metrics to monitor:

  • prx_llm_request_duration_seconds -- LLM latency
  • prx_sessions_active -- concurrent sessions
  • prx_memory_usage_bytes -- memory consumption

Voir aussi Pages

Released under the Apache-2.0 License.