Skip to content
This site is under heavy WIP, so contributions on GitHub are much appreciated! You've most likely been pointed to this site to point towards a concept, or something. Either way, take at least some of the info on this page with a grain of salt, and also don't expect much info since it's very incomplete on content.

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:

  1. Clone the repository above:

    Terminal window
    git clone https://github.com/Pasu4/neuro-api-tony.git
  2. Navigate into the directory:

    Terminal window
    cd neuro-api-tony
  3. Install dependencies. For the purposes of using, you have as many package managers as there are that support a pyproject.toml file. For this page, we will list only 2.

    Terminal window
    uv sync
  4. Run the program:

    Terminal window
    uv run neuro-api-tony

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/result with 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 context commands, the description of actions, the state and query of actions/force commands, and the message of action/result commands. Silent contexts are displayed in gray and ephemeral contexts in light blue. It has the following tags:
    • Context: Message is from a context command.
    • Silent: Message is from a silent context command.
    • State: Message is the state of an actions/force command.
    • Query: Message is the query of an actions/force command.
    • Ephemeral: Message is the query or state of an actions/force command with ephemeral context.
    • Action: Message is the description of an action, logged at registration.
    • Result: Message is from an action/result command. The color denotes whether the result indicates success (green) or failure (red).
  • 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.

Before startup you can configure Tony using these CLI flags:

  • (-a | --addr | --address) <address> - The address the WebSocket server is on. By default it’s localhost which 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 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/force commands immediately.
  • Automatically answer actions/force commands 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.

  • 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/maxLength is specified with pattern.