Offline fault diagnosis assistant for the AgiBot X2 Ultra humanoid robot
Project description
manastone-diag
Offline fault diagnosis assistant for the AgiBot X2 Ultra humanoid robot — drop in a log package, describe the symptom, and get a three-round reviewed diagnosis report. Every verified case feeds an experience library that makes the next diagnosis better.
Docs: Quickstart · Spec · 中文文档 · Changelog · Sources
What it does
A humanoid robot falls over in the field. Someone hands you a 1 GB tar of
logs. manastone-diag turns that into a diagnosis:
- Ingest —
log_ingestorstreams.log/.yaml/.json/.mcap/.atopfiles into a compact structured event stream (privacy-stripped,1 GB safe).
- Match —
fault_librarymatches symptoms and log keywords against 11 fault rules (Chinese + English), and runs temporal causal inference over the event timeline (6 causal rules). - Review — an LLM agent walks you through a three-round review (data collection → analysis → report), pausing for your confirmation at each round.
- Learn — every diagnosis is archived; field verification feedback updates the experience library (sharded storage, WAL-protected; measured: 15 ms in-process search over 5,000 entries).
The heavy lifting is deterministic Python — the LLM orchestrates and explains. Everything runs locally; no network access is required for diagnosis.
Quick start
git clone https://github.com/zengury/manastone-diag.git
cd manastone-diag
pip install -r requirements.txt
# Sanity check (should end with all green)
python3 tools/verify_all.py
# Try the bundled sample incident (a stand-mode fall)
python3 tools/log_ingestor.py examples/sample-incident --robot agibot_x2 --output /tmp/diag-out
Five-minute walkthrough with the sample incident: docs/QUICKSTART.md.
Running with an LLM agent
The project is agent-framework-agnostic: the assets are the knowledge base
(knowledge/), the tool chain (tools/), and the diagnosis playbook
(AGENTS.md). Any coding-agent framework that reads project instructions and
can run shell commands works:
- pi —
./install.shinstalls pi and amanastone-diaglauncher;.pi/ships skill files and the system prompt. - Others (Hermes, Claude Code, …) — point the agent at the repo root;
AGENTS.mdcontains the full three-round diagnosis procedure.
Data sources
| Source | Formats | Notes |
|---|---|---|
| Text logs | .log (incl. sliced .log_N), .txt |
fall detection, mode switches, fault codes |
| ROS2 bags | .mcap |
sensor/joint time series; joint asymmetry analysis |
| Config / state dumps | .yaml, .json |
status snapshots, hardware config |
| System monitor | .atop |
CPU/memory (requires atop, via WSL on Windows) |
Knowledge base
knowledge/ ships 8 YAML files: 11 fault rules with repair guidance,
12 keyword-match entries (Chinese + English), 10 log event patterns,
6 temporal causal rules, plus hardware/interface ontologies and a
capability-boundary list documenting known platform blind spots.
All numbers above are enforced by CI against the actual YAML contents.
Multi-user / shared experience
Set MANASTONE_DATA_DIR to a shared folder to pool the experience library
across a team, or import a colleague's data folder with
python3 tools/experience_manager.py import <path> (GUI: tools/import_tool.py).
Scope and boundaries
- Offline by design. Diagnosis consumes exported log packages only. The tool does not connect to robots, and it contains no code from the (private) Manastone runtime kernel. The only sanctioned online interface is the runtime's public ledger read API — unused in this version. See SOURCES.md.
- Robot-specific knowledge currently targets the AgiBot X2 Ultra. The schema and pipeline are robot-agnostic; see docs/SPEC.md to add another robot.
License
Licensed under the Apache License, Version 2.0 (Apache-2.0).
Copyright 2026 zengury. Modifications in v2.x (MCAP joint parsing, experience shards, archive dashboard) by thomastang237.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file manastone_diag-2.2.0.tar.gz.
File metadata
- Download URL: manastone_diag-2.2.0.tar.gz
- Upload date:
- Size: 85.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0486ee146afc11d8a70eded2c24252bb739fbb6568d4f5f07cb20cecc4bbb79f
|
|
| MD5 |
9a4c2609ef6c491f6839f8d0f437aa48
|
|
| BLAKE2b-256 |
1ec75b4115aa5ace65d151d9bc86f625ea6d43e2b2abe487d7b37aeb5c34b2d1
|
File details
Details for the file manastone_diag-2.2.0-py3-none-any.whl.
File metadata
- Download URL: manastone_diag-2.2.0-py3-none-any.whl
- Upload date:
- Size: 95.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f27fd9c5e7145aeafb9a2e3e0b6302e6ae25bdef671756a136521f36773ebed7
|
|
| MD5 |
0aa19238aafb047a0c568ecbbf837cdb
|
|
| BLAKE2b-256 |
420f6efcc3a0f2812e95b83439ee5e4b48f24a4f9de0f1568c1c6d73a6fc4769
|