ワンクリックで
kube-agents-observability
Audit, monitor, and debug the logging, tracing, metrics, and API/dashboard observability of the Platform Agent.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Audit, monitor, and debug the logging, tracing, metrics, and API/dashboard observability of the Platform Agent.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Autonomously poll, triage, investigate, and resolve unaddressed open issues on our target GitHub repository strictly within authorized scope.
Configures, optimizes, and troubleshoots GKE ComputeClasses. Use when configuring Spot VMs with on-demand fallback, targeting specific accelerators (GPUs/TPUs) or machine families, restricting ComputeClass access, or debugging pending pods related to node pool auto-creation. Do not use for cluster-level Node Auto Provisioning configuration or general GKE cluster creation.
Standard Operating Procedure (SOP) for generating and updating secure, compliant, and cost-effective GKE manifests.
Systematic Standard Operating Procedure (SOP) for diagnosing GKE workload failures, crash loops, resource OOMs, mounting errors, and connectivity timeouts.
Reviews Kubernetes Pod security contexts for workload-level isolation and privilege escalation risks.
Propose declarative configuration updates securely by committing file changes and submitting GitHub Pull Requests (PRs) for SRE review.
| name | kube-agents-observability |
| description | Audit, monitor, and debug the logging, tracing, metrics, and API/dashboard observability of the Platform Agent. |
Audit, verify, and troubleshoot the logging, metrics, and distributed tracing observability of the Platform Agent.
[!TIP] The provided Python scripts in the
scripts/subdirectory are parameterized reference implementations. When troubleshooting, you can run them directly, customize their parameters, or write custom just-in-time scripts/commands to query more specific metrics, endpoints, or time ranges as required by the task context.
/opt/data/logs/*.log.kubectl exec <pod-name> -c <agent-container-name> -n agent-system -- tail -n 100 /opt/data/logs/agent.log
fluent-bit sidecar container tails the log directory and streams to standard output:
kubectl logs <pod-name> -c fluent-bit -n agent-system --tail=100
kubectl get configmap <agent-name>-fluent-bit-config -n agent-system -o yaml
/opt/data volume is mounted to both the agent and Fluent-bit containers:
kubectl get pod <pod-name> -n agent-system -o jsonpath='{.spec.containers[*].volumeMounts}'
To determine which users have interacted with the system via Google Chat in the last 24 hours (or a custom window):
Run the packaged Python helper script to automatically query and parse the GKE container logs from Google Cloud Logging:
python3 /opt/hermes/skills/kube-agents-observability/scripts/get_chat_users.py --project-id <PROJECT_ID> [--hours <HOURS>]
Alternatively, search Cloud Logging manually (via console or gcloud CLI) for the custom GChat event format emitted by the hermes session store:
gcloud logging read 'resource.type="k8s_container" "Logging incoming GChat event"' --project=<PROJECT_ID> --limit=1000 --format="json"
Look for log lines containing the format: Logging incoming GChat event: User=<email>, Session=<session_id>.
[!NOTE] LLM token and operational metrics are conditional on the LLM proxy or inference server used.
- LiteLLM: The scripts below query custom LiteLLM metrics. See the LiteLLM Prometheus Documentation for a complete list of metrics.
- vLLM: Exposes different Prometheus metrics (e.g.,
vllm:num_requests_waiting). See the vLLM Metrics Documentation for details.- Other providers: Query names will vary based on the specific provider's exporter.
kubectl get pods -n gmp-system
kubectl get deployment <agent-deployment-name> -n agent-system -o yaml
kubectl top pod -l app=<agent-name> -n agent-system
python3 /opt/hermes/skills/kube-agents-observability/scripts/check_token_usage.py --project-id <project-id>
python3 /opt/hermes/skills/kube-agents-observability/scripts/get_metric_descriptors.py --project-id <project-id>
[!NOTE] The system relies on GKE Managed OpenTelemetry for distributed tracing.
- Harness Agents: Emit traces natively via the
hermes_otelplugin.- LiteLLM: Emits trace spans via its OTLP callback system.
- Visualization: Exported traces are stored in Google Cloud Trace and can be searched/analyzed in the Trace Explorer console.
hermes_otel plugin is enabled in /opt/data/config.yaml or /opt/defaults/config.yaml.http://opentelemetry-collector.gke-managed-otel.svc.cluster.local:4318/v1/traceskubectl exec <pod-name> -c <agent-container-name> -n agent-system -- curl -i -s -o /dev/null -w "%{http_code}" -X POST http://opentelemetry-collector.gke-managed-otel.svc.cluster.local:4318/v1/traces
kubectl logs <pod-name> -c <agent-container-name> -n agent-system --tail=500 | grep -iE "(otel|trace|exporter|export)"
To list recent traces or analyze span latency distributions to locate performance bottlenecks (such as slow tool executions or model calls):
Run the trace latency analyzer script:
python3 /opt/hermes/skills/kube-agents-observability/scripts/analyze_trace_latency.py --project-id <project-id> [--hours <hours>] [--limit <limit>]
Example Output:
Retrieving the last 3 traces...
======================================================================
Trace ID: 0006344377aac15d1baede1a41e88a2c
Total Duration: 0.647 seconds | Total Spans: 3
Breakdown of spans:
- POST /v1/chat/completions : 0.646s (99.9%)
- chat model-default : 0.627s (97.0%)
- auth /v1/chat/completions : 0.001s ( 0.1%)
Alternatively, run the raw trace list script:
python3 /opt/hermes/skills/kube-agents-observability/scripts/fetch_traces.py --project-id <project-id> --hours 24
kubectl get pods -n agent-system -l app=<agent-name> -o wide
8642) and Dashboard port (9119):
kubectl get service platform-agent -n agent-system -o yaml
kubectl port-forward svc/<agent-service-name> -n agent-system 9119:9119
kubectl exec <pod-name> -c <agent-container-name> -n agent-system -- ls -la /opt/data/memory/
kubectl exec <pod-name> -c <agent-container-name> -n agent-system -- cat /opt/data/memory/heartbeat-state.json