Generate TDengine Historian Demos with EasyUse

This procedure describes how to use the IDMP EasyUse skill to create an AI-generated demo for your use case. This scenario includes not just data ingestion, but also data modeling and asset tree construction, panel configuration, and analysis and event generation.

Before You Begin

  • This procedure is verified to work on macOS as well as Ubuntu and Debian GNU/Linux. Other mainstream Linux distributions are likely usable.
  • For Windows users, the procedure can be run in Windows Subsystem for Linux (WSL), but TDengine Historian must be deployed in Docker.
  • The Windows OpenCode desktop application is not supported.
  • A large-language model is required to run this procedure.
  • The entire demo generation procedure will take about 45 minutes.

Procedure

  1. Deploy TDengine TSDB and TDengine IDMP as described in the documentation.
  2. Activate TDengine IDMP.
  3. In a terminal, create a directory for this procedure and open it. For example:

    mkdir myproject
    cd myproject
  4. In your project directory, create the .opencode directory.

    mkdir .opencode
  5. In the .opencode directory, create a file named login.txt containing the following information:

    TDengine IDMP:
      host: 127.0.0.1
      port: 6042
      user: your-idmp-user
      password: your-idmp-password
    TDengine TSDB:
      host: 127.0.0.1
      port: 6041
      user: root
      password: taosdata

    Under TDengine IDMP, enter an existing user name and password for your deployment.

  6. Download the skills to your local machine and decompress them to the .opencode directory. The path should be .opencode/skills
  7. Install OpenCode:

    • Linux:

      sudo apt install npm
      sudo npm install -g opencode-ai
    • macOS:

      curl -fsSL https://opencode.ai/install | bash
  8. Run OpenCode:

    opencode
  9. In the OpenCode console displayed, connect an LLM:

    /connect

    A list of supported LLMs is displayed. Configure your LLM as prompted. For example, to use a ChatGPT account, select OpenAI > ChatGPT (Browser) and enter your ChatGPT user name and password in the browser that is opened automatically.

  10. Display the list of loaded skills:

    /skills
  11. Run the IDMP EasyUse skill and prompt it to create the demo that you want for a wide variety of use cases. Make sure to include the location of login.txt so that the AI can log in to TDengine. For example:

    /idmp-easyuse Create a smart manufacturing demo and use the TDengine credentials provided in .opencode/login.txt

Your demo scenario is generated and loaded into TDengine Historian. This process may take around 45 minutes to complete.

Once OpenCode has finished, log in to TDengine IDMP and view the elements, panels, and analyses created by the AI to verify whether the demo has generated successfully.