Toolkit
tcc-ironl is the language layer of TCC-IRoNL as a standalone Python package. It contains the system prompt, the LLM providers, the action parser and the destination resolver that the ROS nodes use, so whatever you try here behaves the same on the robot. It needs no ROS, Gazebo or GPU.
pip install "tcc-ironl[all]"
Command line
Command |
What it does |
|---|---|
|
Parse action text into action dictionaries, offline. |
|
Send a request to the configured LLM with the TCC-IRoNL prompt and parse the answer. Needs an API key. |
|
Match a place name to a configured destination. |
|
List the configured destinations and their coordinates. |
|
Download a SAM checkpoint from Meta (`–model vit_b |
|
Check the Python version, API key, CUDA, SAM weights and ROS. |
|
Print the path of the bundled |
Every command that reads configuration takes --config path/to/config.yaml, and the tcc_ros/config/config.yaml is used otherwise. Add --json for machine-readable output.
$ tcc-ironl parse "Move forward 1.5 meters at 0.2 m/s; Turn left 90 degrees; Navigate to the kitchen; STOP."
1. {'action': 'FORWARD', 'distance': 1.5, 'speed': 0.2}
2. {'action': 'TURN_LEFT', 'angle': 90.0}
3. {'action': 'NAVIGATE_TO_DESTINATION', 'destination_name': 'kitchen'}
4. {'action': 'STOP'}
$ tcc-ironl resolve "restroom" --no-embeddings
{'phrase': 'restroom', 'destination': 'toilet', 'match': 'exact'}
chat uses models/llm_provider and models/llm_name from the config; override them with --provider and --model:
export ANTHROPIC_API_KEY=...
tcc-ironl chat --provider claude "Pause for 15 seconds, then drive in a circle at 0.3 m/s"
Python API
from tcc_ironl import CommandParser, DestinationResolver, load_config
from tcc_ironl.interface import LLMInterface
from tcc_ironl.config import resolve_api_key, default_config_path
parser = CommandParser() # patterns from action_dictionary.json
parser.parse_actions("Action 1: Turn right 45 degrees.\nAction 2: Report coordinates.")
# [{'action': 'TURN_RIGHT', 'angle': 45.0}, {'action': 'REPORT_COORDINATES'}]
resolver = DestinationResolver(default_config_path())
resolver.resolve("restroom") # ('toilet', 'exact'); typos and synonyms fall back to fuzzy and embedding matching
llm = LLMInterface(
api_key=resolve_api_key("gemini"),
destinations={"Kitchen": "kitchen", "Elevator": "elevator"},
provider="gemini",
)
reply = llm.process_input("Head to the kitchen at 0.5 m/s")
if reply["type"] == "ACTIONS":
print(parser.parse_actions(reply["content"]))
The full reference is in the API section.
How it relates to the ROS package
The modules in tcc_ros/src/tcc_ros/ (llm_provider.py, llm_node.py, commands_parser.py, destination_resolver.py, data_logger.py) are thin wrappers that read ROS parameters and then call tcc_ironl. The toolkit bundles copies of config.yaml and action_dictionary.json from tcc_ros/config/ so that it works without the ROS package; the tests fail if the copies drift apart, and --config points the CLI at your own file. install_python_deps.sh installs the toolkit in editable mode into the ROS virtualenv.