Tony
Tony is a Neuro simulator written in Python. It allows users to simulate Neuro-sama using its GUI, relying (almost) entirely on a human operator.
Tony is maintained by Pasu4, and can be found here.
To setup Tony:
-
Clone the repository above:
Terminal window git clone https://github.com/Pasu4/neuro-api-tony.git -
Navigate into the directory:
Terminal window cd neuro-api-tony -
Install dependencies. For the purposes of using, you have as many package managers as there are that support a
pyproject.tomlfile. For this page, we will list only 2.Terminal window uv syncTerminal window pip install -
Run the program:
Terminal window uv run neuro-api-tonyTerminal window neuro-api-tony
Startup
Section titled “Startup”When starting up Tony, you’ll see a window containg the (currently blank) list of actions to the left, a small log panel to the top-right giving you the ability to see messages sent back and forth.
The log panel gives you the ability to select what mode you want to see them as [“System”, “Commands”, “Context”, “Raw”]. Pulling directly from Tony’s README:
- The system tab logs miscellaneous messages with color-coded tags:
- Debug (gray): Things that usually should be handled internally by an SDK (e.g. action IDs), as well as some internals of the application. Debug messages alone are not a cause for concern.
- Info (blue): Things that will likely not cause problems with Neuro, but might point to some other issue (e.g.
action/resultwith no message). - Warning (yellow): Things that do not comply with the API specification, but which Tony can still tolerate (e.g. trying to register actions before sending
startup). These will likely cause problems with Neuro. - Error (red): Things that make it impossible to process a command (e.g. receiving invalid JSON). These will definitely cause problems with Neuro.
- Critical (dark red): Something went wrong and Tony will likely have to be restarted.
- The commands tab logs incoming and outgoing commands in a more condensed format than the raw tab.
- The context tab shows everything that Neuro would get to read directly, which is the content of
contextcommands, the description of actions, the state and query ofactions/forcecommands, and the message ofaction/resultcommands. Silent contexts are displayed in gray and ephemeral contexts in light blue. It has the following tags:- Context: Message is from a
contextcommand. - Silent: Message is from a silent
contextcommand. - State: Message is the state of an
actions/forcecommand. - Query: Message is the query of an
actions/forcecommand. - Ephemeral: Message is the query or state of an
actions/forcecommand with ephemeral context. - Action: Message is the description of an action, logged at registration.
- Result: Message is from an
action/resultcommand. The color denotes whether the result indicates success (green) or failure (red).
- Context: Message is from a
- The raw tab shows the full data sent over the websocket, as well as who sent that data. If it is valid JSON, it will be formatted for easier viewing.
Credits: Pasu4/neuro-api-tony
Extracted text can be found here.
Actions that are registered to Tony are displayed on the left-hand side. You can select one and then click Execute to execute it, or click the Delete/Delete all buttons to unregister the action(s).
If you’re waiting for an action result, you can click Stop waiting to release the action lock and allow you to execute another command immediately. Note that this is not something Neuro normally does, as is manually unregistering actions.
A new window pops up whenever an actions/force packet is received. This window shows you what actions the packet specifies can be executed to proceed. If necessary, you can close that window and ignore the actions/force - however, be aware that you cannot bring that window back up again.
Configuration
Section titled “Configuration”Before startup
Section titled “Before startup”Before startup you can configure Tony using these CLI flags:
- (
-a|--addr|--address) <address> - The address the WebSocket server is on. By default it’slocalhostwhich prevents it from being exposed to the network. - (
-l|--log|--log-level) <level> - The level of logs you can see. Accepted values:DEBUG,INFO,WARNING,ERROR,CRITICAL. See Startup for which level corresponds to what meaning. - (
-p|--port) <port> - The port to start Tony on. By default it starts at port 8000, matching other simulators.
Other CLI flags:
- (
-h|--help) - Pops up the help menu. - (
-v|--version) - Pops up the current version of Tony.
After startup
Section titled “After startup”After the GUI pops up, there is a small config panel at the bottom right that allows you to configure Tony post-start. The panel allows you to:
- Ignore
actions/forcecommands immediately. - Automatically answer
actions/forcecommands with reasonably(ish) fake data generated (if necessary). - Log microseconds when packets are sent/received.
- Add l*tency before executing each command. Maximum value is 10000ms, and unfortunately, cannot be negative.
- Change the level of logging displayed in the log panel.
Additionally, the config panel allows you to send commands to the connected client that is currently under proposal. For more information, see the Proposed APIs overview.
Known issues
Section titled “Known issues”- The last button on the control panel sometimes does not appear when the app is started, should be fixed by resizing the window.
- Due to a bug in the JSF library, valid strings may not be generated if
minLength/maxLengthis specified withpattern.