Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions dimos/robot/cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,19 @@ To avoid having so many runfiles, I created a common script to run any blueprint
For example, to run the standard Unitree Go2 blueprint run:

```bash
dimos-robot run unitree-go2
dimos run unitree-go2
```

For the one with agents run:

```bash
dimos-robot run unitree-go2-agentic
dimos run unitree-go2-agentic
```

You can dynamically connect additional modules. For example:

```bash
dimos-robot run unitree-go2 --extra-module llm_agent --extra-module human_input --extra-module navigation_skill
dimos run unitree-go2 --extra-module llm_agent --extra-module human_input --extra-module navigation_skill
```

## Definitions
Expand Down Expand Up @@ -61,5 +61,5 @@ For environment variables/`.env` values, you have to prefix the name with `DIMOS
For the command line, you call it like this:

```bash
dimos-robot --simulation run unitree-go2
dimos --simulation run unitree-go2
```
46 changes: 43 additions & 3 deletions dimos/robot/cli/dimos_robot.py → dimos/robot/cli/dimos.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

from enum import Enum
import inspect
import sys
from typing import Optional, get_args, get_origin

import typer
Expand All @@ -25,7 +26,10 @@

RobotType = Enum("RobotType", {key.replace("-", "_").upper(): key for key in all_blueprints.keys()})

main = typer.Typer()
main = typer.Typer(
help="Dimensional CLI",
no_args_is_help=True,
)


def create_dynamic_callback():
Expand Down Expand Up @@ -103,7 +107,7 @@ def run(
[], "--extra-module", help="Extra modules to add to the blueprint"
),
) -> None:
"""Run the robot with the specified configuration."""
"""Start a robot blueprint"""
config: GlobalConfig = ctx.obj
pubsub.lcm.autoconf()
blueprint = get_blueprint_by_name(robot_type.value)
Expand All @@ -118,7 +122,7 @@ def run(

@main.command()
def show_config(ctx: typer.Context) -> None:
"""Show current configuration status."""
"""Show current config settings and their values."""
config: GlobalConfig = ctx.obj

for field_name, value in config.model_dump().items():
Expand All @@ -133,5 +137,41 @@ def list() -> None:
typer.echo(blueprint_name)


@main.command(context_settings={"allow_extra_args": True, "ignore_unknown_options": True})
def lcmspy(ctx: typer.Context) -> None:
"""LCM spy tool for monitoring LCM messages."""
from dimos.utils.cli.lcmspy.run_lcmspy import main as lcmspy_main

sys.argv = ["lcmspy", *ctx.args]
lcmspy_main()


@main.command(context_settings={"allow_extra_args": True, "ignore_unknown_options": True})
def skillspy(ctx: typer.Context) -> None:
"""Skills spy tool for monitoring skills."""
from dimos.utils.cli.skillspy.skillspy import main as skillspy_main

sys.argv = ["skillspy", *ctx.args]
skillspy_main()


@main.command(context_settings={"allow_extra_args": True, "ignore_unknown_options": True})
def agentspy(ctx: typer.Context) -> None:
"""Agent spy tool for monitoring agents."""
from dimos.utils.cli.agentspy.agentspy import main as agentspy_main

sys.argv = ["agentspy", *ctx.args]
agentspy_main()


@main.command(context_settings={"allow_extra_args": True, "ignore_unknown_options": True})
def humancli(ctx: typer.Context) -> None:
"""Interface interacting with agents."""
from dimos.utils.cli.human.humanclianim import main as humancli_main

sys.argv = ["humancli", *ctx.args]
humancli_main()


if __name__ == "__main__":
main()
2 changes: 1 addition & 1 deletion dimos/robot/cli/test_dimos_robot_e2e.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def __init__(self) -> None:

def start(self):
self.process = subprocess.Popen(
["dimos-robot", "run", "demo-skill"],
["dimos", "run", "demo-skill"],
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
)
Expand Down
4 changes: 2 additions & 2 deletions docker/navigation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,8 +143,8 @@ In the container to run the full navigation stack you must run both the dimensio

For the Unitree G1
```bash
dimos-robot run unitree-g1
ROBOT_IP=XX.X.X.XXX dimos-robot run unitree-g1 # If ROBOT_IP env variable is not set in .env
dimos run unitree-g1
ROBOT_IP=XX.X.X.XXX dimos run unitree-g1 # If ROBOT_IP env variable is not set in .env
```

#### Navigation Stack
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ foxglove-bridge = "dimos.utils.cli.foxglove_bridge.run_foxglove_bridge:main"
skillspy = "dimos.utils.cli.skillspy.skillspy:main"
agentspy = "dimos.utils.cli.agentspy.agentspy:main"
humancli = "dimos.utils.cli.human.humanclianim:main"
dimos-robot = "dimos.robot.cli.dimos_robot:main"
dimos = "dimos.robot.cli.dimos:main"

[project.optional-dependencies]
manipulation = [
Expand Down
Loading