How to Build Your Own TEN Agent Locally

Apr 11, 2024 | Educational

Welcome to the exciting world of AI development with the TEN Agent! This guide will help you set up TEN Agent locally so you can harness the power of real-time multimodal AI interactions.

Overview of TEN Agent

The TEN Agent is an open-source multimodal framework that enables high-performance audio-visual AI applications. It supports multiple programming languages and platforms, making it incredibly versatile for developers.

Getting Started with TEN Agent

Before diving into the installation process, make sure you have the following prerequisites:

Prerequisites

Installation Requirements

Ensure your system meets the minimum requirements:

  • CPU: 2 Core
  • RAM: 4 GB

Configuring Docker on Apple Silicon

If you’re using an Apple Silicon device, remember to uncheck “Use Rosetta for x86_64/amd64 emulation” in your Docker settings.

Docker Setting

Setting Up TEN Agent

Now let’s jump into the setup process. Follow these steps carefully:

1. Modify Configuration Files

Navigate to the root of the project and create a .env file from the example:

bash
cp .env.example .env

2. Setup API Keys

Open the .env file and fill in your API keys and regions:

bash
# Agora App ID and Agora App Certificate
AGORA_APP_ID=
AGORA_APP_CERTIFICATE=
# Azure STT key and region
AZURE_STT_KEY=
AZURE_STT_REGION=
# Azure TTS key and region
AZURE_TTS_KEY=
AZURE_TTS_REGION=
# OpenAI API key
OPENAI_API_KEY=

3. Start Agent Development Containers

In the same directory, run the docker compose command:

bash
docker compose up

4. Enter Container and Build Agent

Open a new terminal window, enter the container, and build the agent:

bash
docker exec -it astra_agents_dev bash
make build

5. Start the Server

Once the build is done, run the server on port 8080:

bash
make run-server

Testing Your TEN Agent

Navigate to http://localhost:3000 to access and test the TEN Agent. To utilize the Graph Designer, go to http://localhost:3001 which allows you to create, connect, and edit extensions on the canvas.

TEN Graph Designer

Troubleshooting

If you encounter issues during installation or while using your TEN Agent, consider these troubleshooting tips:

  • Check your API keys to ensure they are entered correctly in the `.env` file.
  • Verify that all dependencies are installed as per the prerequisites.
  • If the server does not start, review the terminal logs for any error messages that can guide you to the problem.

For more insights, updates, or to collaborate on AI development projects, stay connected with fxis.ai.

Conclusion

By following these steps, you should now have a functional TEN Agent running on your local machine. At fxis.ai, we believe that advancements like these are crucial for the future of AI, enabling more comprehensive and effective solutions. Our team is continually exploring new methodologies to push the envelope in artificial intelligence, ensuring that our clients benefit from the latest technological innovations.

Stay Informed with the Newest F(x) Insights and Blogs

Tech News and Blog Highlights, Straight to Your Inbox